[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: A simple implementation of context-sensitive keys
From: |
Lennart Borgman (gmail) |
Subject: |
Re: A simple implementation of context-sensitive keys |
Date: |
Sat, 13 Sep 2008 11:32:42 +0200 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.666 |
Tassilo Horn wrote:
> "Lennart Borgman (gmail)" <address@hidden> writes:
>
> Hi Lennart,
>
>>> Here's a q&d implementation of what I thought should do the trick.
>>> It works for me, although only very briefly tested.
>>>
>>> --8<---------------cut here---------------start------------->8---
>>> (defun find-key-commands (key)
>>> (let (list)
>>> (when overriding-terminal-local-map
>>
>> Yes, the structure of the key binding search must be mirrored in the
>> routine. But the problem I tried to solve was rather to find the
>> keymap variable names.
>
> Ok, that's true. You either have the keymap variable name or the mode
> name. In most cases appending "-map" to the mode name makes the keymap
> name. And even it that fails for some modes, I thing something like
>
> TAB ist bound to `do-foo' in `foo-mode'.
>
> is not too bad.
Yes, it might be good to combine the output with this information when
it looks reliable.
>> You do not have those names available anywhere really. You have to
>> guess.
>
> Maybe an adapted version of `apropos-value' might do the trick. As it's
> now it's much too slow
Did you try describe-key-and-map-briefly?
>> But combining the mirrored structure with the routine that guesses the
>> keymap variable name would be the best I think.
>
> Yeah, something like that.
>
> Bye,
> Tassilo
- Re: A simple implementation of context-sensitive keys, (continued)
- Re: A simple implementation of context-sensitive keys, Lennart Borgman (gmail), 2008/09/11
- Re: A simple implementation of context-sensitive keys, Tassilo Horn, 2008/09/11
- Re: A simple implementation of context-sensitive keys, Lennart Borgman (gmail), 2008/09/11
- Re: A simple implementation of context-sensitive keys, Tassilo Horn, 2008/09/12
- Re: A simple implementation of context-sensitive keys, Lennart Borgman (gmail), 2008/09/12
- Re: A simple implementation of context-sensitive keys, Tassilo Horn, 2008/09/12
- Re: A simple implementation of context-sensitive keys, Lennart Borgman, 2008/09/12
- Re: A simple implementation of context-sensitive keys, Tassilo Horn, 2008/09/12
- Re: A simple implementation of context-sensitive keys, Lennart Borgman (gmail), 2008/09/12
- Re: A simple implementation of context-sensitive keys, Tassilo Horn, 2008/09/13
- Re: A simple implementation of context-sensitive keys,
Lennart Borgman (gmail) <=
- Re: A simple implementation of context-sensitive keys, Tassilo Horn, 2008/09/15
- Re: A simple implementation of context-sensitive keys, Lennart Borgman (gmail), 2008/09/15
- Re: A simple implementation of context-sensitive keys, Stefan Monnier, 2008/09/11
- Re: A simple implementation of context-sensitive keys, Lennart Borgman (gmail), 2008/09/11
- Re: A simple implementation of context-sensitive keys, Stefan Monnier, 2008/09/11
- Re: A simple implementation of context-sensitive keys, Lennart Borgman (gmail), 2008/09/12