[Top][All Lists]

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

Re: Looking up and CALLING a key binding

From: TheLonelyStar
Subject: Re: Looking up and CALLING a key binding
Date: Tue, 6 Jan 2009 07:14:40 -0800 (PST)


I need this for the following two things:

1. I want to bind a key (the tab key) to a special function which can fail.
If the function fails, I want to call the original  binding of the key
(which is differerent depending on which mode I am in).

2. I want to bind a key to the insertion of a little code snippet.
i.E. { -> to
But since in many modes the "{" and "}" keys are bound to some special
function, I want to call these keybindings for the insertions of the "{" and

Xah Lee-2 wrote:
> On Jan 5, 6:00 am, TheLonelyStar <address@hidden> wrote:
>> Hi,
>> I know very little elisp have basicly no practical expirience with it.
>> I know I can lookup a keybinding with lookup-key and similiar.
>> But how do I look it up and call it (execute it)?
>> Thanks!
>> nathan
> what exactly you want to do?
> are you writing a elisp program? ... or you trying to do something in
> emacs?
> once you know what command the binding is associated with, you can
> just call the command by typing Alt+x commandName.
> if you are writing elisp... once you get the command name, say it is
> forward-word, then you can run it by just (forward-word) ... some
> example of your case would be good to clarify.
>   Xah

View this message in context:
Sent from the Emacs - Help mailing list archive at

reply via email to

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