emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master 413cd29: Don't let window start override window poi


From: Martin Rudalics
Subject: [Emacs-diffs] master 413cd29: Don't let window start override window point in `window-state-put' (Bug#24240)
Date: Thu, 18 Aug 2016 08:28:17 +0000 (UTC)

branch: master
commit 413cd292f6f0b63e62e6a84b3f866f2d482a582a
Author: Andreas Politz <address@hidden>
Commit: Martin Rudalics <address@hidden>

    Don't let window start override window point in `window-state-put' 
(Bug#24240)
    
    * lisp/window.el (window--state-put-2): Set 'noforce argument
    when restoring a window's start position.  This avoids that the
    effect of `set-window-point' gets overidden by that of
    `set-window-start' (Bug#24240).
---
 lisp/window.el |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lisp/window.el b/lisp/window.el
index 11d7a4e..4699e2c 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -5497,7 +5497,9 @@ value can be also stored on disk and read back in a new 
session."
                ;; Install positions (maybe we should do this after all
                ;; windows have been created and sized).
                (ignore-errors
-                 (set-window-start window (cdr (assq 'start state)))
+                  ;; Set 'noforce argument to avoid that window start
+                  ;; overrides window point set below (Bug#24240).
+                 (set-window-start window (cdr (assq 'start state)) 'noforce)
                  (set-window-point window (cdr (assq 'point state))))
                ;; Select window if it's the selected one.
                (when (cdr (assq 'selected state))



reply via email to

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