Create / modify keyboard shortcuts in Gnome under Linux / UNIX

by Vivek Gite · 7 comments

Q. I’m using Ubuntu Linux and I’d like to create or modify keyboard shortcuts in Gnome desktop system? How do I do it?

A. You need to use GConf-Editor or gnome keyboard shortcut tool. GConf-Editor is a tool used for editing the GConf configuration database. It might be useful when the proper configuration utility for some software provides no way of changing some option. The main window consists of a tree showing the GConf configuration database hierarchy, a list of the keys available, and documentation for the selected key. Key values can be changed by either changing them directly in the list, or right clicking on them and selecting Edit key. Changes take immediate effect in running programs. New keys can be added by right clicking in the list and selecting New key.

Easy to use - Keyboard Shortcuts tool

Use the Keyboard Shortcuts preference tool to customize the default keyboard shortcuts to your requirements.

Click on System > Preferences > Keyboard Shortcuts to launch the application and view the preconfigured shortcuts.
Create / modify keyboard shortcuts in Gnome under Linux / UNIX  with Keyboard Shortcuts tool

To edit a keyboard shortcut, perform the following steps:

  1. Click the action in the list. If you are using the the keyboard, use the arrow keys to select the shortcut and press Return.
  2. Press the new key or key combination you want to assign to the action.
  3. To clear a shortcut, press Backspace. The action is now marked as Disabled.
  4. To cancel assigning a shortcut, click elsewhere in the window or press Escape.

Advance keyboard shortcuts tool - gconf-editor (GConf-Editor)

You need to install this tool using any one of the following command (Debian / Ubuntu Linux):
$ sudo apt-get install gconf-editor
Or if you are using Fedora / CentOS /RHEL Linux:
# yum install gconf-editor

Run gconf-editor

Use menus or type a command as follows:
$ gconf-editor &

  • Next double click the "apps" folder
  • Next double click the "metacity" folder
  • Finally click the global_keybindings folder

gconf-editor

Please note that all these keyboard shortcuts and other settings are saved on a user basis (inside a home directory), so each user can create their own custom setup.

Featured Articles:

Want to read Linux tips and tricks, but don't have time to check our blog everyday? Subscribe to our daily email newsletter to make sure you don't miss a single tip/tricks. Subscribe to our weekly newsletter here!

{ 7 comments… read them below or add one }

1 Dan 02.05.08 at 2:25 pm

thanks for that, exactly what i needed, I wanted to set a keyboard shortcut to start a particular program. your gconf-editor tip did it for me.

2 Denis 05.27.08 at 11:58 pm

Very nice topic ! Almoust exactly what i was looking for. I got a problem with shortcuts in Fedora 9. I can not assign the keyboard shotrtcut for HOME directory. It seems to be set in a right way and I also have xml file for this shortcut but it does not works. If you have some idea in mind … I will be thankful.

3 Velu 11.10.08 at 6:37 am

i need fedora 9 32 bit nots from online please

4 Dougle 12.03.08 at 1:41 am

was the key name for my left super (Windows) key, in case any one wondered.

Thanks for the tip Vivek.

5 tipsy 08.03.09 at 6:47 am

global_keybindings (run_command_1 to _10) can be set to keybindings (P, just type it in literally), then set the corresponding command in keybindings_commands (command_1 = pidgin). This way you get to set ten commands without overriding any other keyboard shortcuts.

6 tipsy 08.03.09 at 6:52 am

Hm, there needs to be an %3CALT%3E%3CCTRL%3E in front of that (hope this works :)

7 Gordon 09.06.09 at 1:28 am

What file does the key binding info get stored in?
When I want to do a key combo with the window button e.g. “Mod4(windows) + t” it won’t let me. I’d like to edit the file directly.

Leave a Comment

You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Previous FAQ:

Next FAQ:

nixCraft FAQ PDF Collection Now Available To All