From: Damien Cassou <damien@cassou.me>
To: Stefan Kangas <stefankangas@gmail.com>, 58800@debbugs.gnu.org
Subject: bug#58800: Mark previous-buffer and next-buffer commands as repeatable
Date: Sun, 30 Oct 2022 07:35:04 +0100 [thread overview]
Message-ID: <87leoxom3r.fsf@cassou.me> (raw)
In-Reply-To: <CADwFkm=2+GkK_5ewzRV7StPYCLdqn2YBFznnjOjtvSoE_Tt=DA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 672 bytes --]
Hi Stefan,
Stefan Kangas <stefankangas@gmail.com> writes:
> Damien Cassou <damien@cassou.me> writes:
> Do we really need to add "Copyright-paperwork-exempt"?
I don't, you are right. Fixed.
>> +(defvar-keymap buffer-navigation-repeat-map
>> + :doc "Keymap to repeat `next-buffer' and `previous-buffer'. Used in `repeat-mode'."
>> + [right] #'next-buffer
>> + [left] #'previous-buffer)
>
> It should be "<right>" and "<left>" here, I think.
You are right. In the meantime, I switched to Emacs 29 so I can test my
own patches. Sorry. Fixed.
--
Damien Cassou
"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Mark-previous-buffer-and-next-buffer-commands-as-rep.patch --]
[-- Type: text/x-patch, Size: 1183 bytes --]
From c09670b9baa5d5333ba2f9396915b01062b1f2a8 Mon Sep 17 00:00:00 2001
From: Damien Cassou <damien@cassou.me>
Date: Wed, 26 Oct 2022 17:12:14 +0200
Subject: [PATCH] Mark `previous-buffer' and `next-buffer' commands as
repeatable
* lisp/bindings.el (buffer-navigation-repeat-map): Add new map.
* lisp/bindings.el (previous-buffer):
(next-buffer): Mark as repeatable.
---
lisp/bindings.el | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/lisp/bindings.el b/lisp/bindings.el
index 2e32128274..bd0bf5afd6 100644
--- a/lisp/bindings.el
+++ b/lisp/bindings.el
@@ -1029,6 +1029,14 @@ ctl-x-map
(define-key global-map [XF86Back] 'previous-buffer)
(put 'previous-buffer :advertised-binding [?\C-x left])
+(defvar-keymap buffer-navigation-repeat-map
+ :doc "Keymap to repeat `next-buffer' and `previous-buffer'. Used in `repeat-mode'."
+ "<right>" #'next-buffer
+ "<left>" #'previous-buffer)
+
+(put 'next-buffer 'repeat-map 'buffer-navigation-repeat-map)
+(put 'previous-buffer 'repeat-map 'buffer-navigation-repeat-map)
+
(let ((map minibuffer-local-map))
(define-key map "\en" 'next-history-element)
(define-key map [next] 'next-history-element)
--
2.36.2
next prev parent reply other threads:[~2022-10-30 6:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-26 15:14 bug#58800: Mark previous-buffer and next-buffer commands as repeatable Damien Cassou
2022-10-26 19:52 ` Stefan Kangas
2022-10-30 6:35 ` Damien Cassou [this message]
2022-10-30 13:25 ` Stefan Kangas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87leoxom3r.fsf@cassou.me \
--to=damien@cassou.me \
--cc=58800@debbugs.gnu.org \
--cc=stefankangas@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.