From: Lars Ingebrigtsen <larsi@gnus.org>
To: Robert Pluim <rpluim@gmail.com>
Cc: 55301@debbugs.gnu.org, Phil Hudson <phil.hudson@iname.com>
Subject: bug#55301: 27.2; RFE: Auto-create defcustom for declared minor mode keymap
Date: Wed, 18 May 2022 13:29:11 +0200 [thread overview]
Message-ID: <87ee0rdqpk.fsf@gnus.org> (raw)
In-Reply-To: <87leuz1fft.fsf@gmail.com> (Robert Pluim's message of "Wed, 18 May 2022 09:13:26 +0200")
Robert Pluim <rpluim@gmail.com> writes:
> Lars> But it'd be nice if a defcustom interface for keymaps existed.
>
> Something like this?
>
> (defcustom keymap-additions nil
> "Alist of bindings to add to keymaps at startup.
> Keys are keymap symbols, values are lists of conses, format
> (key-binding . command)
>
> Where KEY-BINDING is a kbd format key specification, and COMMAND is an
> Emacs command.")
>
> So you could have that be
>
> '((fundamental-mode-map . (("C-a" . mark-whole-buffer)
> ("C-b" . backward-word)))
> (elisp-mode-map . (("C-a" . mark-defun))))
Yes, something like that. But the major work would be to create a
sensible widget that allows people to customise the keymap in question.
It'd be nice if it displayed a graphical keyboard in a buffer, and you
could click on keys to specify what they should output. 😀
Or something simpler, for instance a widget where you ask the user to
enter a chord/key stroke, and then prompt what command to bind that to.
Or... something else. Many possibilities here.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2022-05-18 11:29 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-07 14:07 bug#55301: 27.2; RFE: Auto-create defcustom for declared minor mode keymap Phil Hudson
2022-05-07 15:34 ` Lars Ingebrigtsen
2022-05-07 16:49 ` Phil Hudson
2022-05-08 11:46 ` Lars Ingebrigtsen
2022-05-08 13:47 ` Phil Hudson
2022-05-09 9:34 ` Lars Ingebrigtsen
2022-05-09 9:52 ` Phil Hudson
2022-05-09 9:54 ` Lars Ingebrigtsen
2022-05-09 10:02 ` Phil Hudson
2022-05-09 13:39 ` Robert Pluim
2022-05-09 15:04 ` Phil Hudson
2022-05-17 16:03 ` Phil Hudson
2022-05-17 16:13 ` Robert Pluim
2022-05-17 17:27 ` Lars Ingebrigtsen
2022-05-18 7:13 ` Robert Pluim
2022-05-18 10:59 ` Phil Hudson
2022-05-18 11:29 ` Lars Ingebrigtsen [this message]
2022-05-18 13:39 ` Phil Hudson
2022-05-20 22:32 ` Richard Stallman
2022-05-09 9:55 ` Phil Hudson
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=87ee0rdqpk.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=55301@debbugs.gnu.org \
--cc=phil.hudson@iname.com \
--cc=rpluim@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 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).