|
From: | Adam Jiang |
Subject: | Re: How to get the function by the keymap? |
Date: | Mon, 12 Nov 2012 13:27:09 +0900 |
On Sun, Nov 11, 2012 at 12:09 AM, Adam Jiang <jiang.adam@gmail.com> wrote:You don't want to dig through the keymaps yourself. Just take your
> However, (delete-char) never works for me. The reason is another minor mode
> remapped the backspace key to function 'autopair-backspace'. Then, I
> realized that I need a method to fetch the function by given keymap and get
> it called rather thant have hardcoded deletion executed.
>
> How can I do that with elisp code?
minor-mode out of the lookup chain and use `key-binding'.
This is what I do here:
https://github.com/lewang/rebox2/blob/master/rebox2.el#L2363
The deeper problem is that I have a chain of 3 functions from
different minor-modes all bound to backspace. They share the key
happily, but Emacs lacks the mechanism to document this calling chain
when I ask about <BACKSPACE> with C-h k. I described the need to
solve this as a feature request
http://lists.gnu.org/archive/html/help-gnu-emacs/2012-10/msg00465.html
, but there wasn't much interest. :(
--
Le
[Prev in Thread] | Current Thread | [Next in Thread] |