all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Restoring Old Key Binding for eval-expression
@ 2016-04-24 20:06 rwgpost
  2016-06-04  9:23 ` Eli Zaretskii
  0 siblings, 1 reply; 2+ messages in thread
From: rwgpost @ 2016-04-24 20:06 UTC (permalink / raw)
  To: help-gnu-emacs

I am just starting to use a current version of Emacs that has eval-expression bound to M-:.  I used to use eval-expression a lot and loved being able to just type Esc Esc to invoke eval-expression.  Is there a way to restore this in my .emacs file?  I've tried several things, like:

 (global-set-key "\M-ESC" 'eval-expression)
 (global-set-key "\M-ESC" 'eval-expression)
 (global-set-key "ESC-ESC" 'eval-expression)

but I can't get any of these to work.  M-: is unwieldy as I have to hit the Meta key, the colon, and the shift key all at the same time.

I really miss Esc Esc, which used to work I guess because the old binding was M-Esc, and Esc-Esc did the same thing.

I've tried googling for help on this but am having trouble finding anything.  When I google "emacs restore m-esc eval-expression' I just get a lot of hits from old documentation on Emacs when it used to have the old key binding...

Thanks,

Robbie


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

* Re: Restoring Old Key Binding for eval-expression
  2016-04-24 20:06 Restoring Old Key Binding for eval-expression rwgpost
@ 2016-06-04  9:23 ` Eli Zaretskii
  0 siblings, 0 replies; 2+ messages in thread
From: Eli Zaretskii @ 2016-06-04  9:23 UTC (permalink / raw)
  To: help-gnu-emacs

> Date: Sun, 24 Apr 2016 13:06:56 -0700 (PDT)
> From: rwgpost@gmail.com
> 
> I am just starting to use a current version of Emacs that has eval-expression bound to M-:.  I used to use eval-expression a lot and loved being able to just type Esc Esc to invoke eval-expression.  Is there a way to restore this in my .emacs file?  I've tried several things, like:
> 
>  (global-set-key "\M-ESC" 'eval-expression)
>  (global-set-key "\M-ESC" 'eval-expression)
>  (global-set-key "ESC-ESC" 'eval-expression)
> 
> but I can't get any of these to work.  M-: is unwieldy as I have to hit the Meta key, the colon, and the shift key all at the same time.
> 
> I really miss Esc Esc, which used to work I guess because the old binding was M-Esc, and Esc-Esc did the same thing.

This should get you off the ground:

  (global-set-key "\e\e" 'eval-expression)

(For the future, you can find out answers to many such questions by
looking at various key bindings in the Emacs sources.)



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

end of thread, other threads:[~2016-06-04  9:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-24 20:06 Restoring Old Key Binding for eval-expression rwgpost
2016-06-04  9:23 ` Eli Zaretskii

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.