From: Tassilo Horn Date: Wed, 15 Jul 2020 16:58:57 +0000 (+0200) Subject: ;Fix eldoc regression bug#42365 X-Git-Tag: emacs-28.0.90~6999 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=85eaa8373bb0a91013af503d333670788ec5a956;p=emacs.git ;Fix eldoc regression bug#42365 --- diff --git a/lisp/emacs-lisp/eldoc.el b/lisp/emacs-lisp/eldoc.el index 1a009bdefac..510dff9ed0b 100644 --- a/lisp/emacs-lisp/eldoc.el +++ b/lisp/emacs-lisp/eldoc.el @@ -495,8 +495,9 @@ Honor most of `eldoc-echo-area-use-multiline-p'." (substitute-command-keys "\\[eldoc-doc-buffer]"))))))))) ((= available 1) ;; Truncate "brutally." ; FIXME: use `eldoc-prefer-doc-buffer' too? - (truncate-string-to-width - (buffer-substring (point-min) (line-end-position 1)) width))))) + (with-current-buffer (eldoc-doc-buffer) + (truncate-string-to-width + (buffer-substring (point-min) (line-end-position 1)) width)))))) (when echo-area-message (eldoc--message echo-area-message))))))