1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-28 07:45:00 +00:00

Prevent eldoc from changing the mode line

* lisp/emacs-lisp/eldoc.el (eldoc-minibuffer-message): Don't
change the mode line if it is not displayed.  (Bug#28697)
This commit is contained in:
Nick Helm 2017-10-21 11:41:28 +03:00 committed by Eli Zaretskii
parent c9d71b31bf
commit 035d7ac7e4

View File

@ -264,12 +264,13 @@ Otherwise work like `message'."
(or (window-in-direction 'above (minibuffer-window))
(minibuffer-selected-window)
(get-largest-window)))
(when mode-line-format
(unless (and (listp mode-line-format)
(assq 'eldoc-mode-line-string mode-line-format))
(setq mode-line-format
(list "" '(eldoc-mode-line-string
(" " eldoc-mode-line-string " "))
mode-line-format)))
mode-line-format))))
(setq eldoc-mode-line-string
(when (stringp format-string)
(apply #'format-message format-string args)))