emacs-diffs
[Top][All Lists]
Advanced

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

master a2d62456a7: Fix regression with cursor motion in Magit buffers


From: Eli Zaretskii
Subject: master a2d62456a7: Fix regression with cursor motion in Magit buffers
Date: Sat, 27 Aug 2022 07:06:42 -0400 (EDT)

branch: master
commit a2d62456a7b8da27fb9b64f71b6ce588f2d73287
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>

    Fix regression with cursor motion in Magit buffers
    
    * lisp/simple.el (line-move): Condition movement optimizations on
    presence of very long lines.  (Bug#57433)
---
 lisp/simple.el | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/lisp/simple.el b/lisp/simple.el
index ee765c8a57..d18d54ce16 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -7717,13 +7717,15 @@ not vscroll."
               (not goal-column)
                ;; Lines aren't truncated.
                (not
-                (or truncate-lines
-                    (and (integerp truncate-partial-width-windows)
-                         (< (window-width)
-                            truncate-partial-width-windows))
-                    (and truncate-partial-width-windows
-                         (not (integerp truncate-partial-width-windows))
-                         (not (window-full-width-p)))))
+                (and
+                 (or truncate-lines
+                     (and (integerp truncate-partial-width-windows)
+                          (< (window-total-width)
+                             truncate-partial-width-windows))
+                     (and truncate-partial-width-windows
+                          (not (integerp truncate-partial-width-windows))
+                          (not (window-full-width-p))))
+                 (long-line-optimizations-p)))
               ;; When the text in the window is scrolled to the left,
               ;; display-based motion doesn't make sense (because each
               ;; logical line occupies exactly one screen line).



reply via email to

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