* bug#21886: 24.5; `dired-next/previous-line' should have a "^" in their interactive specs
@ 2015-11-12 8:14 Eli Barzilay
2015-11-12 8:39 ` Juanma Barranquero
0 siblings, 1 reply; 4+ messages in thread
From: Eli Barzilay @ 2015-11-12 8:14 UTC (permalink / raw)
To: 21886
[-- Attachment #1: message body text --]
[-- Type: text/plain, Size: 207 bytes --]
If I bind the up/down arrow keys to `dired-next/previous-line' in
dired mode, they misbehave wrt shift selection. The following simple
patch fixes this by adding a "^" to their `interactive' declarations.
[-- Attachment #2: 0001-Add-to-the-interactive-specs-of-dired-next-previous-.patch --]
[-- Type: application/octet-stream, Size: 1297 bytes --]
From 195a4881482181443ffcec85e1863881c86edd35 Mon Sep 17 00:00:00 2001
From: Eli Barzilay <eli@barzilay.org>
Date: Thu, 12 Nov 2015 03:07:38 -0500
Subject: [PATCH] Add "^" to the interactive specs of
`dired-next/previous-line'
It makes sense to bind these commands to the arrow keys, and that means
that they work better with a "^" in the `interactive' declaration so
selection works as expected.
---
lisp/dired.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lisp/dired.el b/lisp/dired.el
index 5f0a83a..049d45d 100644
--- a/lisp/dired.el
+++ b/lisp/dired.el
@@ -2031,7 +2031,7 @@ Otherwise, toggle `read-only-mode'."
(defun dired-next-line (arg)
"Move down lines then position at filename.
Optional prefix ARG says how many lines to move; default is one line."
- (interactive "p")
+ (interactive "^p")
(let ((line-move-visual)
(goal-column))
(line-move arg t))
@@ -2044,7 +2044,7 @@ Optional prefix ARG says how many lines to move; default is one line."
(defun dired-previous-line (arg)
"Move up lines then position at filename.
Optional prefix ARG says how many lines to move; default is one line."
- (interactive "p")
+ (interactive "^p")
(dired-next-line (- (or arg 1))))
(defun dired-next-dirline (arg &optional opoint)
--
2.6.3
[-- Attachment #3: .signature --]
[-- Type: text/plain, Size: 151 bytes --]
--
((x=>x(x))(x=>x(x))) Eli Barzilay:
http://barzilay.org/ Maze is Life!
^ permalink raw reply related [flat|nested] 4+ messages in thread
* bug#21886: 24.5; `dired-next/previous-line' should have a "^" in their interactive specs
2015-11-12 8:14 bug#21886: 24.5; `dired-next/previous-line' should have a "^" in their interactive specs Eli Barzilay
@ 2015-11-12 8:39 ` Juanma Barranquero
2015-11-12 8:51 ` Eli Barzilay
0 siblings, 1 reply; 4+ messages in thread
From: Juanma Barranquero @ 2015-11-12 8:39 UTC (permalink / raw)
To: Eli Barzilay; +Cc: 21886-done
[-- Attachment #1: Type: text/plain, Size: 62 bytes --]
Thanks, committed as 851be0f60718795c985f504db4823344508b107d
[-- Attachment #2: Type: text/html, Size: 115 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#21886: 24.5; `dired-next/previous-line' should have a "^" in their interactive specs
2015-11-12 8:39 ` Juanma Barranquero
@ 2015-11-12 8:51 ` Eli Barzilay
2015-11-12 11:44 ` Juanma Barranquero
0 siblings, 1 reply; 4+ messages in thread
From: Eli Barzilay @ 2015-11-12 8:51 UTC (permalink / raw)
To: Juanma Barranquero; +Cc: 21886-done
Does it sound sensible to add the same to `dired-next-dirline' and
`dired-prev-dirline'? (If so, I can do the push.)
On Thu, Nov 12, 2015 at 3:39 AM, Juanma Barranquero <lekktu@gmail.com> wrote:
> Thanks, committed as 851be0f60718795c985f504db4823344508b107d
--
((x=>x(x))(x=>x(x))) Eli Barzilay:
http://barzilay.org/ Maze is Life!
^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#21886: 24.5; `dired-next/previous-line' should have a "^" in their interactive specs
2015-11-12 8:51 ` Eli Barzilay
@ 2015-11-12 11:44 ` Juanma Barranquero
0 siblings, 0 replies; 4+ messages in thread
From: Juanma Barranquero @ 2015-11-12 11:44 UTC (permalink / raw)
To: Eli Barzilay; +Cc: 21886-done
[-- Attachment #1: Type: text/plain, Size: 408 bytes --]
On Thu, Nov 12, 2015 at 9:51 AM, Eli Barzilay <eli@barzilay.org> wrote:
> Does it sound sensible to add the same to `dired-next-dirline' and
> `dired-prev-dirline'?
Well, I think it is as sensible as adding it to
dired-(next|previous)-line...
> (If so, I can do the push.)
Yep, I know. Sorry.
If you do, please write the commit log in a more "ChangeLog"ish style (I
mean, add the file name, etc.). TIA.
[-- Attachment #2: Type: text/html, Size: 613 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-11-12 11:44 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-12 8:14 bug#21886: 24.5; `dired-next/previous-line' should have a "^" in their interactive specs Eli Barzilay
2015-11-12 8:39 ` Juanma Barranquero
2015-11-12 8:51 ` Eli Barzilay
2015-11-12 11:44 ` Juanma Barranquero
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.