Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am trying to find what is being called when I press a keyboard shortcut. For example, if I hit Ctrl + Alt + L I block the screen, or when I hit the "mute" key in my keyboard I mute the sound. I can't find where those bindings are stored.

I have found the list of bindings in /usr/share/gnome-control-center/keybindings, but I don't see there the effect of the key, just that it is a shortcut. I am not looking for the window where the shortcuts are listed (1) but I want what the shortcuts are calling.

For example, if I create a new shortcut, which executes a shell script, it's easy to see what it is calling, just clicking on the name (in the said window 1), but if it's a default shortcut, clicking on the name disables the shortcut, so I want to know what the shortcut executes when it's activated.

I'm using Gnome Shell (not Unity) in Ubuntu 12.04

share|improve this question

3 Answers 3

If you have a windows key on your computer hold that down for a couple seconds. hope that helps :P

share|improve this answer
    
It doesn't work. At least not in gnome-shell. –  fawques Dec 1 '12 at 20:14
    
could you tell me what version of Ubuntu you are using? –  DJINDISGUISE Dec 1 '12 at 20:41
    
Ubuntu 12.04, it is written in the question –  fawques Dec 1 '12 at 20:42
    
    
Not exactly what I am looking for. That link is also a list of shortcuts, but it doesn't say what is being called. –  fawques Dec 1 '12 at 20:49

Search for Keyboard Shortcuts in unity. Should help.

share|improve this answer
    
I'm not using Unity, I use Gnome-shell –  fawques Dec 1 '12 at 20:28
    
Isn't there Keyboard Shortcuts in it too? I'm sorry, I dont use it :/ Keyboard Shortcuts is usually found in Settings window. –  SiddharthaRT Dec 1 '12 at 20:30
    
this is how it looks like. –  SiddharthaRT Dec 1 '12 at 20:31
    
yes, there's a window exactly like that, but that only tells me what effect the shortcut has, but I want to find what is being called, if it is a script, or something –  fawques Dec 1 '12 at 20:33
    
Ahh. That was the /usr/share... you were talking about? Well. I dont know anymore. –  SiddharthaRT Dec 1 '12 at 20:40

I don't know if this gives you everything you want to know, but if you run this command:

xmodmap -pke | less

You will get output on what every key on the keyboard does. It's a little cryptic because you don't get names just keycodes.

Excerpt from my machine:

keycode  13 = 4 dollar 4 dollar
keycode  14 = 5 percent 5 percent
keycode  15 = 6 asciicircum 6 asciicircum
keycode  16 = 7 ampersand 7 ampersand
keycode  17 = 8 asterisk 8 asterisk
keycode  18 = 9 parenleft 9 parenleft
keycode  19 = 0 parenright 0 parenright
keycode  20 = minus underscore minus underscore
keycode  21 = equal plus equal plus
keycode  22 = BackSpace BackSpace BackSpace BackSpace
keycode  23 = Tab ISO_Left_Tab Tab ISO_Left_Tab
keycode  24 = q Q q Q
keycode  25 = w W w W
keycode  26 = e E e E
keycode  27 = r R r R
keycode  28 = t T t T
keycode  29 = y Y y Y
keycode  30 = u U u U
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.