From: Stefan Kangas <stefan@marxist.se>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Lars Ingebrigtsen <larsi@gnus.org>,
emacs-devel@gnu.org, Sean Whitton <spwhitton@spwhitton.name>
Subject: Re: master a6a5d6a: Move 'revert-buffer' global binding to 'C-x g g'
Date: Tue, 9 Mar 2021 20:56:20 -0800 [thread overview]
Message-ID: <CADwFkmmJkoR-cH8rgDgN8u87sCKe3Eqze6ACJ1rd7K1HjoR3=g@mail.gmail.com> (raw)
In-Reply-To: <jwv1rcnww0n.fsf-monnier+emacs@gnu.org>
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> Usually, you should type ‘n’ and then ‘C-x x g’,
>> to get the latest version of the file, then make the change again.
>>
>> The "C-x x g" part used to be "M-x revert-buffer" and therefore more
>> self-explanatory. (This is due to subsitute-command-keys replacing the
>> "\\[revert-buffer]" with the new keybinding.)
>
> I'm tempted to say that in many cases it would make sense to show both.
> Maybe doing it for \\[...] would be too disruptive, but maybe we should
> introduce a new form which will gets expanded to both the key binding and
> the name of the command.
Sure, why not?
I also see a need for a form that expands to the exact text specified
but adds the `help-key-binding' face (to be used e.g. when there is no
keymap to refer to, as in userlock.el, or when we want to display RET as
C-m as in `help-for-help').
I don't know what notation to use here though. Maybe something like:
\\[cmd] -> works as today
\\[=C-h] -> just adds the formatting to the exact string
\\[+cmd] -> adds both the key binding and its M-x form
(This would of course break for symbols starting with = or +.)
next prev parent reply other threads:[~2021-03-10 4:56 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20210207123046.20692.80429@vcs0.savannah.gnu.org>
[not found] ` <20210207123048.3D5A8211A5@vcs0.savannah.gnu.org>
2021-03-10 2:53 ` master a6a5d6a: Move 'revert-buffer' global binding to 'C-x g g' Stefan Kangas
2021-03-10 3:04 ` Stefan Monnier
2021-03-10 4:56 ` Stefan Kangas [this message]
2021-03-10 17:23 ` Juri Linkov
2021-03-10 18:33 ` Stefan Kangas
2021-03-10 19:13 ` Juri Linkov
2021-03-11 16:19 ` Stefan Kangas
2021-03-11 16:56 ` Dmitry Gutov
2021-03-11 17:22 ` 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
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='CADwFkmmJkoR-cH8rgDgN8u87sCKe3Eqze6ACJ1rd7K1HjoR3=g@mail.gmail.com' \
--to=stefan@marxist.se \
--cc=emacs-devel@gnu.org \
--cc=larsi@gnus.org \
--cc=monnier@iro.umontreal.ca \
--cc=spwhitton@spwhitton.name \
/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).