From: Drew Adams <drew.adams@oracle.com>
To: John Mastro <john.b.mastro@gmail.com>, help-gnu-emacs@gnu.org
Subject: RE: Getting a key's read syntax as a string
Date: Fri, 27 Mar 2015 21:50:21 -0700 (PDT) [thread overview]
Message-ID: <7b185188-bc6c-47f7-8165-95f42dad337d@default> (raw)
In-Reply-To: <CAOj2CQQPkxuqMJN_d2FZ78J4hDZCPX3qqu=jyjfgimgWZ7Gitw@mail.gmail.com>
> Is there a programmatic way to get a string representing a
> key-with-modifier's read syntax, given its integer value?
>
> Perhaps more clearly, I'm looking for something that would work like
> this:
> (key-read-syntax ?\C-a) ;=> "?\C-a" or "C-a"
> (key-read-syntax ?\M-f) ;=> "?\M-f" or "M-f"
> I checked the manual but didn't come across anything.
Not sure what you're asking, but does `single-key-description' or
`key-description' fit?
(single-key-description ?\C-a) ;=> "C-a"
etc.
next prev parent reply other threads:[~2015-03-28 4:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-28 2:22 Getting a key's read syntax as a string John Mastro
2015-03-28 4:50 ` Drew Adams [this message]
2015-03-28 20:05 ` John Mastro
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=7b185188-bc6c-47f7-8165-95f42dad337d@default \
--to=drew.adams@oracle.com \
--cc=help-gnu-emacs@gnu.org \
--cc=john.b.mastro@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.