unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* A way to make Emacs completely disregard a key
@ 2010-07-23  9:49 Deniz Dogan
  2010-07-27  3:54 ` Kevin Rodgers
  0 siblings, 1 reply; 5+ messages in thread
From: Deniz Dogan @ 2010-07-23  9:49 UTC (permalink / raw)
  To: help-gnu-emacs

I have undefined <f2> so that it is unbound. But still I get "<f2> is
undefined" in the echo area and a beep, which I don't want. I know I
can just bind this to a no-op command instead, but is there a smart
way to make Emacs completely disregard any hit of the <f2> key? So
e.g. C-x <f2> C-s would be interpreted as C-x C-s, since <f2> is not
even snapped up by Emacs.

Thanks,
Deniz Dogan



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

* Re: A way to make Emacs completely disregard a key
       [not found] <mailman.4.1279878594.17590.help-gnu-emacs@gnu.org>
@ 2010-07-23 18:35 ` Elena
  2010-07-24  0:06   ` Tim X
  0 siblings, 1 reply; 5+ messages in thread
From: Elena @ 2010-07-23 18:35 UTC (permalink / raw)
  To: help-gnu-emacs

maybe `keyboard-translate' can translate a key to nothingness?


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

* Re: A way to make Emacs completely disregard a key
  2010-07-23 18:35 ` Elena
@ 2010-07-24  0:06   ` Tim X
  2010-07-24 14:10     ` Elena
  0 siblings, 1 reply; 5+ messages in thread
From: Tim X @ 2010-07-24  0:06 UTC (permalink / raw)
  To: help-gnu-emacs

Elena <egarrulo@gmail.com> writes:

> maybe `keyboard-translate' can translate a key to nothingness?

Actually, if your on X11 you can use modmap to do this.

Tim

-- 
tcross (at) rapttech dot com dot au


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

* Re: A way to make Emacs completely disregard a key
  2010-07-24  0:06   ` Tim X
@ 2010-07-24 14:10     ` Elena
  0 siblings, 0 replies; 5+ messages in thread
From: Elena @ 2010-07-24 14:10 UTC (permalink / raw)
  To: help-gnu-emacs

On 24 Lug, 02:06, Tim X <t...@nospam.dev.null> wrote:
> Actually, if your on X11 you can use modmap to do this.

Did you mean `xmodmap'?

On Windows, I think you can achieve such a result using AutoHotKey.


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

* Re: A way to make Emacs completely disregard a key
  2010-07-23  9:49 A way to make Emacs completely disregard a key Deniz Dogan
@ 2010-07-27  3:54 ` Kevin Rodgers
  0 siblings, 0 replies; 5+ messages in thread
From: Kevin Rodgers @ 2010-07-27  3:54 UTC (permalink / raw)
  To: help-gnu-emacs

Deniz Dogan wrote:
> I have undefined <f2> so that it is unbound. But still I get "<f2> is
> undefined" in the echo area and a beep, which I don't want. I know I
> can just bind this to a no-op command instead,

(global-set-key (kbd "<f2>") 'ignore)

> but is there a smart
> way to make Emacs completely disregard any hit of the <f2> key? So
> e.g. C-x <f2> C-s would be interpreted as C-x C-s, since <f2> is not
> even snapped up by Emacs.

(define-key special-event-map (kbd "<f2>") 'ignore)

(info "(elisp)Special Events")

-- 
Kevin Rodgers
Denver, Colorado, USA




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

end of thread, other threads:[~2010-07-27  3:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-23  9:49 A way to make Emacs completely disregard a key Deniz Dogan
2010-07-27  3:54 ` Kevin Rodgers
     [not found] <mailman.4.1279878594.17590.help-gnu-emacs@gnu.org>
2010-07-23 18:35 ` Elena
2010-07-24  0:06   ` Tim X
2010-07-24 14:10     ` Elena

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).