From: Philip Kaludercic <philipk@posteo.net>
To: 60161@debbugs.gnu.org
Subject: bug#60161: [PATCH] Allow customising windmove user options with an empty prefix
Date: Sat, 17 Dec 2022 15:04:41 +0000 [thread overview]
Message-ID: <87tu1ugjg6.fsf@posteo.net> (raw)
[-- Attachment #1: Type: text/plain, Size: 813 bytes --]
Tags: patch
I just switched to setopt, and noticed a few errors. Among these was
`windmove-default-keybindings', which didn't want to set
(setopt windmove-default-keybindings '(nil . nil))
while
(setopt windmove-default-keybindings '("C-c" . nil))
is allowed. The mistake appears to be that the option type is
misconfigured, and believes the car must be a keybinding, which hasn't
been the case since Emacs 28. The patch below updates the type,
resolving this issue.
In GNU Emacs 29.0.60 (build 5, x86_64-pc-linux-gnu, GTK+ Version
3.24.35, cairo version 1.16.0) of 2022-12-14 built on quetzal
Repository revision: 622838b957e240d700585050e9ddbd036e690513
Repository branch: emacs-29
System Description: Debian GNU/Linux bookworm/sid
Configured using:
'configure --with-pgtk --with-imagemagick'
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Allow-customising-windmove-user-options-with-an-empt.patch --]
[-- Type: text/patch, Size: 1013 bytes --]
From feca8985392c227ee7caaaa69ac8bdc990a0256b Mon Sep 17 00:00:00 2001
From: Philip Kaludercic <philipk@posteo.net>
Date: Sat, 17 Dec 2022 15:54:40 +0100
Subject: [PATCH] Allow customising windmove user options with an empty prefix
* lisp/windmove.el (windmove--default-keybindings-type): Handle nil
as a prefix value.
---
lisp/windmove.el | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lisp/windmove.el b/lisp/windmove.el
index 00e76df0a0..4311f082de 100644
--- a/lisp/windmove.el
+++ b/lisp/windmove.el
@@ -776,7 +776,8 @@ windmove-swap-states-default-keybindings
(defconst windmove--default-keybindings-type
`(choice (const :tag "Don't bind" nil)
(cons :tag "Bind using"
- (key-sequence :tag "Prefix")
+ (choice (key-sequence :tag "Prefix")
+ (const :tag "No Prefix" nil))
(set :tag "Modifier"
:greedy t
;; See `(elisp) Keyboard Events'
--
2.35.1
next reply other threads:[~2022-12-17 15:04 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-17 15:04 Philip Kaludercic [this message]
2022-12-18 11:23 ` bug#60161: [PATCH] Allow customising windmove user options with an empty prefix Eli Zaretskii
2022-12-18 11:46 ` Philip Kaludercic
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87tu1ugjg6.fsf@posteo.net \
--to=philipk@posteo.net \
--cc=60161@debbugs.gnu.org \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).