emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 372efa6: Tweak point movement in view-echo-area-mes


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] master 372efa6: Tweak point movement in view-echo-area-messages
Date: Sat, 6 Jul 2019 10:49:08 -0400 (EDT)

branch: master
commit 372efa6a4143561b093dcc49d5f1b7eb0c443131
Author: Drew Adams <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>

    Tweak point movement in view-echo-area-messages
    
    * lisp/help.el (view-echo-area-messages): Move the point to the
    end of the *Messages* buffer even if it's already displayed
    (bug#36343).
---
 lisp/help.el | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/lisp/help.el b/lisp/help.el
index 42ff375..039d0c4 100644
--- a/lisp/help.el
+++ b/lisp/help.el
@@ -417,12 +417,16 @@ With argument, display info only for the selected 
version."
 
 (defun view-echo-area-messages ()
   "View the log of recent echo-area messages: the `*Messages*' buffer.
-The number of messages retained in that buffer
-is specified by the variable `message-log-max'."
+The number of messages retained in that buffer is specified by
+the variable `message-log-max'."
   (interactive)
   (with-current-buffer (messages-buffer)
     (goto-char (point-max))
-    (display-buffer (current-buffer))))
+    (let ((win (display-buffer (current-buffer))))
+      ;; If the buffer is already displayed, we need to forcibly set
+      ;; the window point to scroll to the end of the buffer.
+      (set-window-point win (point))
+      win)))
 
 (defun view-order-manuals ()
   "Display information on how to buy printed copies of Emacs manuals."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]