all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Which keybinding was used to call a function?
@ 2010-03-22  4:44 Nathaniel Flath
  2010-03-22  5:04 ` Drew Adams
  2010-03-22  9:21 ` Peter Dyballa
  0 siblings, 2 replies; 3+ messages in thread
From: Nathaniel Flath @ 2010-03-22  4:44 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 274 bytes --]

Is there a way for a function to tell what keybinding it was called with?
I'm trying to modify yasnippet.el to work with multiple trigger keys, but I
need to be able to tell which key it was called with for the fallback
behaviour to work correctly.

Thanks,
Nathaniel Flath

[-- Attachment #2: Type: text/html, Size: 295 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: Which keybinding was used to call a function?
  2010-03-22  4:44 Which keybinding was used to call a function? Nathaniel Flath
@ 2010-03-22  5:04 ` Drew Adams
  2010-03-22  9:21 ` Peter Dyballa
  1 sibling, 0 replies; 3+ messages in thread
From: Drew Adams @ 2010-03-22  5:04 UTC (permalink / raw)
  To: 'Nathaniel Flath', help-gnu-emacs

> Is there a way for a function to tell what keybinding it
> was called with?  I'm trying to modify yasnippet.el to
> work with multiple trigger keys, but I need to be able
> to tell which key it was called with for the fallback
> behaviour to work correctly.

See function `this-command-keys'.





^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Which keybinding was used to call a function?
  2010-03-22  4:44 Which keybinding was used to call a function? Nathaniel Flath
  2010-03-22  5:04 ` Drew Adams
@ 2010-03-22  9:21 ` Peter Dyballa
  1 sibling, 0 replies; 3+ messages in thread
From: Peter Dyballa @ 2010-03-22  9:21 UTC (permalink / raw)
  To: Nathaniel Flath; +Cc: help-gnu-emacs


Am 22.03.2010 um 05:44 schrieb Nathaniel Flath:

> Is there a way for a function to tell what keybinding it was called  
> with?


C-h l – view-lossage might help. C-h b lists all key bindings, listing  
also the function names. C-h f <function name> often lists the keys  
its bound to.

--
Greetings

   Pete

Encryption, n.:
	A powerful algorithmic encoding technique employed in the creation of  
computer manuals.





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-03-22  9:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-22  4:44 Which keybinding was used to call a function? Nathaniel Flath
2010-03-22  5:04 ` Drew Adams
2010-03-22  9:21 ` Peter Dyballa

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.