[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Tweak to key-description for menu bindings

From: Kim F. Storm
Subject: Re: Tweak to key-description for menu bindings
Date: Wed, 02 Mar 2005 00:36:18 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

David Kastrup <address@hidden> writes:

>> New:
>> Options=>Mule (Multilingual Environment)=>Set Coding Systems=>For Next 
>> Command
>> Shall I install this?
> My vote is "yes".  

So far, only two votes in favour -- and one against.

>                    However, I would also want to suggest that such
> pretty-printed key sequences can, as some sort of a general principle,
> be passed to the kbd macro 

Would be nice, but it is very hard to do.

Whereas kbd can easily parse <menu-bar> <bla> <bla> <bla> into a
vector [menu-bar bla bla bla], there is no easy way to parse Bla
This=>Bla That=>Bla Bla into the same vector without actually looking
up those strings in the keymaps -- and we don't currently have C-level
functions to do that, so we would have to implement a lot of the
keymap lookup code in Lisp to support that.

>                            to make a target for define-key, so that
> the developer can be spared having to switch on his brain as often as
> possible.  I don't know how feasible this is as kbd is a macro, and
> the lookup could depend on the keymaps currently active or something.

This is addressed in the patch I posted yesterday:

If you enter C-h k <...select a menu item...> to look at a menu entry,
the resulting *Help* buffer contains a line

Menu binding: <menu-bar> <bla> <bla> <bla>

that the user-with-switched-off-brain can copy/paste into a kbd arg.

Kim F. Storm <address@hidden> http://www.cua.dk

reply via email to

[Prev in Thread] Current Thread [Next in Thread]