From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Robert Pluim <rpluim@gmail.com>
Cc: Lars Ingebrigtsen <larsi@gnus.org>,
59305@debbugs.gnu.org, Stefan Kangas <stefankangas@gmail.com>
Subject: bug#59305: 29.0.50; keymap-global-set handling of string bindings different from global-set-key
Date: Mon, 06 May 2024 09:24:56 -0400 [thread overview]
Message-ID: <jwva5l33wyg.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <87zft3l0k9.fsf@gmail.com> (Robert Pluim's message of "Mon, 06 May 2024 12:03:18 +0200")
> Stefan> `key-parse` always returns a vector.
> You want us to recommend this?
> (keymap-global-set "C-a" (key-parse "hello"))
Sorry, I was not thinking right. The function you'd need to use to
convert "hello" into the proper form for `keymap-global-set` is either:
- `key-description`: does the "reverse" of `kbd` and `key-parse`.
- `kmacro--to-vector`: turns an old-style string of events to a vector
of events.
> so Iʼd still worry about future regressions caused by `key-parse'
> being changed to enforce `key-valid-p'
Indeed. Not only that, but it'll mis-interpret `C-a` to mean a single
event instead of 3 events.
Stefan
next prev parent reply other threads:[~2024-05-06 13:24 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-16 8:47 bug#59305: 29.0.50; keymap-global-set handling of string bindings different from global-set-key Robert Pluim
2022-11-22 16:58 ` Robert Pluim
2022-11-25 0:14 ` Stefan Kangas
2022-11-25 8:01 ` Robert Pluim
2022-11-25 8:25 ` Stefan Kangas
2022-12-15 8:42 ` Robert Pluim
2024-04-26 14:34 ` Robert Pluim
2024-05-02 9:01 ` Eli Zaretskii
2024-05-02 13:13 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-06 10:03 ` Robert Pluim
2024-05-06 13:24 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2024-05-06 14:34 ` Robert Pluim
2024-05-06 15:20 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
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=jwva5l33wyg.fsf-monnier+emacs@gnu.org \
--to=bug-gnu-emacs@gnu.org \
--cc=59305@debbugs.gnu.org \
--cc=larsi@gnus.org \
--cc=monnier@iro.umontreal.ca \
--cc=rpluim@gmail.com \
--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.