Emacs editing everywhere in Gnome

Quick tip: If you do the majority of your typing in Emacs, it can feel gratingly clumsy to type anywhere else, like in browser text fields and IM windows.

I discovered today that GTK has an option to enable common Emacs editing keys in text fields everywhere on your system. This is amazing–it means no browser extensions or hacks are needed to type over four lines without cursing.

The setting is buried at ‘desktop/gnome/interface/gtk-key-theme’ in the gconf-editor; change its value to “Emacs”, or paste this in a terminal:

gconftool-2 --set /desktop/gnome/interface/gtk_key_theme Emacs --type string

Most common navigation and editing keys work just as they do in terminal emulators: C-{n,p,f,b}, M-{f,b,d}, C-{a,e}, C-k and C-y, C-{w,h,d}.

The CUA keys C-x, C-c and C-v continue to cut, copy and paste respectively.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s