summaryrefslogtreecommitdiff
path: root/elisp
diff options
context:
space:
mode:
authorJose Antonio Ortega Ruiz <jao@gnu.org>2010-12-28 03:39:28 +0100
committerJose Antonio Ortega Ruiz <jao@gnu.org>2010-12-28 03:39:28 +0100
commit19d70712975f093a13f19d9fb5b6eb30ebcb0076 (patch)
treed05ad273e860679f63b7a9bea5b55b2dce60890c /elisp
parentcb3e923097d5910d89be09eb19a7be5a51ff57c1 (diff)
downloadgeiser-19d70712975f093a13f19d9fb5b6eb30ebcb0076.tar.gz
geiser-19d70712975f093a13f19d9fb5b6eb30ebcb0076.tar.bz2
Avoiding autodoc interfering with an active minibuffer
A piece of eldoc advice shamelessly lifted from slime.
Diffstat (limited to 'elisp')
-rw-r--r--elisp/geiser-autodoc.el11
1 files changed, 11 insertions, 0 deletions
diff --git a/elisp/geiser-autodoc.el b/elisp/geiser-autodoc.el
index 9d7bfe5..1befb74 100644
--- a/elisp/geiser-autodoc.el
+++ b/elisp/geiser-autodoc.el
@@ -216,6 +216,17 @@ displayed in the minibuffer."
(eldoc-mode geiser-autodoc-mode)
(message "Geiser Autodoc %s" (if geiser-autodoc-mode "enabled" "disabled")))
+(defadvice eldoc-display-message-no-interference-p
+ (after geiser-autodoc--message-ok-p)
+ (when geiser-autodoc-mode
+ (setq ad-return-value
+ (and ad-return-value
+ ;; Display arglist only when the minibuffer is
+ ;; inactive, e.g. not on `C-x C-f'. Lifted from slime.
+ (not (active-minibuffer-window)))))
+ ad-return-value)
+
+
(provide 'geiser-autodoc)
;;; geiser-autodoc.el ends here