[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: don't hard-code keys
From: |
Emanuel Berg |
Subject: |
Re: don't hard-code keys |
Date: |
Sun, 02 May 2021 16:44:18 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Tassilo Horn wrote:
>> But the question: how can I avoid hard-coding the C-u key
>> but instead have the keybinding inserted thru a reference
>> to the function, i.e. `universal-argument'?
>
> You mean, in the `message' call? Have a look at
>
> (info "(elisp) Keys in Documentation")
I have it working in docstrings but not in general, for
example this
‘\[COMMAND]’
stands for a key sequence that will invoke COMMAND, or ‘M-x
COMMAND’ if COMMAND has no key bindings.
sounds like what I want but
(substitute-command-keys "\[universal-argument]")
:(
--
underground experts united
https://dataswamp.org/~incal