emacs-diffs
[Top][All Lists]
Advanced

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

master ef711b1: Make hexl scrolling commands work more like the normal o


From: Lars Ingebrigtsen
Subject: master ef711b1: Make hexl scrolling commands work more like the normal ones
Date: Tue, 8 Dec 2020 11:57:20 -0500 (EST)

branch: master
commit ef711b1556f83c9aa841fec9927672245408fc9c
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>

    Make hexl scrolling commands work more like the normal ones
    
    * lisp/hexl.el (hexl-scroll-down):
    (hexl-scroll-up): Heed `next-screen-context-lines' (bug#7031).
---
 etc/NEWS     | 6 ++++++
 lisp/hexl.el | 6 ++++--
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/etc/NEWS b/etc/NEWS
index f2fd9fb..83fe7a3 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -1371,6 +1371,12 @@ This new command (bound to 'C-c C-l') regenerates the 
current hunk.
 ** Miscellaneous
 
 ---
+*** 'hexl-mode' scrolling commands now heed 'next-screen-context-lines'.
+Previously, 'hexl-scroll-down' and 'hexl-scroll-up' would scroll
+up/down an entire window, but they now work more like the standard
+scrolling commands.
+
+---
 *** Errors in 'kill-emacs-hook' no longer prevent Emacs from shutting down.
 If a function in that hook signals an error in an interactive Emacs,
 the user will be prompted on whether to continue.  If the user doesn't
diff --git a/lisp/hexl.el b/lisp/hexl.el
index fa514a5..1fe9aad 100644
--- a/lisp/hexl.el
+++ b/lisp/hexl.el
@@ -724,7 +724,8 @@ With prefix arg N, puts point N bytes of the way from the 
true beginning."
   (setq arg (if (null arg)
                 (- (window-height)
                    1
-                   (if ruler-mode 1 0))
+                   (if ruler-mode 1 0)
+                   next-screen-context-lines)
               (prefix-numeric-value arg)))
   (hexl-scroll-up (- arg)))
 
@@ -735,7 +736,8 @@ If there's no byte at the target address, move to the first 
or last line."
   (setq arg (if (null arg)
                 (- (window-height)
                    1
-                   (if ruler-mode 1 0))
+                   (if ruler-mode 1 0)
+                   next-screen-context-lines)
               (prefix-numeric-value arg)))
   (let* ((movement (* arg 16))
         (address (hexl-current-address))



reply via email to

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