How do I enable keyboard shortcuts for different GNOME music players?

Asked by Allan Caeg

I went to System->Preferences->Keyboard Shortcuts, then set Win+C as a shortcut for Play/Pause. When I tried to press Win+C, nothing happened. Before I reformatted, I had Win+C as a shortcut for Play/Pause and it was working, the problem since then was, only Rhythmbox was controlled by the shortcut.

Also, there are shortcuts keys set be default such as 0xed, 0xae, 0xb0, etc. What are those keys supposed to be in my typical QWERTY English keyboard?

How do I enable Keyboard shortcuts for different GNOME music players?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Allan Caeg
Solved:
Last query:
Last reply:
Revision history for this message
Allan Caeg (allancaeg) said :
#1

Ohh.. I found out that shortcuts work if I do not use the Win button with them. How do I make the Win button work?

Revision history for this message
Thomas Templin (coastgnu) said :
#2

On Tue, 29. May 2007 15:21:35 wersdaluv wrote:
> Question #7367 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/7367
>
> wersdaluv gave more information on the question:
> Ohh.. I found out that shortcuts work if I do not use the Win button
> with them. How do I make the Win button work?

It depends on the keyboard model you set up for Gnome, see
System->Preferences->Keyboard.

If you choose 'Generic 105-Key (intl) PC' (PC105) the WIN keys are recognized.
If it is a multimedia keyboard there is a list of keyboard models you may
choose from the tab 'Layouts' listed as 'Keyboard Model'.

BTW, you mentioned, 'there are shortcuts keys set be default such as 0xed,
0xae, 0xb0, etc.' in the 'Keyboard-Shortcuts' configuration. This is because
you don't choose a matching keyboard model. E.G. for my keyboard it
shows 'XF86AudioMute' in the 'mute' line for my Logitech Cordless Desktop
keyboard. If I choose a PC105 model I also see the hex notation (0x...) as
you do.
Note: you have to stop the current Gnome session and log in again to have a
      change of the keyboard model work.

regards,
thomas

Revision history for this message
Allan Caeg (allancaeg) said :
#3

I chose the keyboard type that you stated and logged in again, but the 0xae keys are still there. I went to System->Preferences->Keyboard->Keyboard Layouts and saw an "Alt/Win Key behavior" option. I tried different options but the Win key still doesn't work. Any ideas on how I can use the Win key?

Also, why is that, music player shortcuts only work for Rhythmbox. How can I make them work in Banshee and Exaile?

Revision history for this message
Cesare Tirabassi (norsetto) said :
#4

To use the Win key as a modifier you can try two different ways:

1) Using the keyboard shortcuts applet:

- go to Menu->System->Preferences->Keyboard Shortcuts
- press the win-key, _while pressed_ click on the desired action, then hit whatever key you want to modify (for instance c)
- the combination (for instance "Mod4+c") is stored and should work.

2) The win-key can also be manually binded in gconf:

- open gconf: Menu->System Tools->Configuration Editor
- goto /apps/gnome_settings_daemon/keybindings
- manually set your key (for instance select play, right click, choose edit key, type <WIN>c).

Not all applications uses shortcut keys keys, or can be configured to use them.

In Banshee you need to have the multimedia plugin installed.
In Exaile this is not yet implemented (I've seen they changed it recently upstream: http://www.exaile.org/trac/ticket/16).

Revision history for this message
Cesare Tirabassi (norsetto) said :
#5

By the way, it is appreciated if you can close your tickets after you have received a satisfactory answer. You are not helping anyone keeping them open.

Revision history for this message
Best Allan Caeg (allancaeg) said :
#6

I managed to set "Mod4+C" as a shortcut for "Play (or Play/Pause)," but whenever I press "Win+C," nothing happens. When I set "Alt+Z" as the shortcut key, it worked. Why is that?

Revision history for this message
Cesare Tirabassi (norsetto) said :
#7

Check that in Main->System->Preferences->Keyboard in the Layout Options Tab the Alt/Win key behaviour is set to Default.

Revision history for this message
robh (rob-ubrio) said :
#8

Another alternative is to open the gnome-terminal and run "gconf-editor" and browse to /apps/Metacity/ under "global_keybindings" you'll see a bunch of run_command_x (x = 1..12). If you manually edit that to say <Super>c under "run_command_X" then goto the other setting called "keybinding_commands" browse to the same command (ie: "command_X") and type in what you want it to do.

I found this useful for using the win key since the natural system/preferences/keyboard shortcuts way doesn't seem to like using the Win key.

Just a thought :)

-rob

Revision history for this message
sibidiba (sibidiba) said :
#9

There must be a still a bug in gnome hotkez handling.

Even with the keyboard layout and Win key behavior set correctly, the specific keybindings located under /apps/gnome_settings_daemon/keybindings/ (calculator, browser, screen locking etc.) doesn't work with Win+Any keys. Other keybindings work well (open run dialog, open terminal etc.).

See https://bugs.launchpad.net/ubuntu/+source/control-center/+bug/12153 for more details.

Revision history for this message
Flucker (joel-berglund) said :
#10

I know a way to get the play/pause etc. buttons to work with more than one app. Check out the program ReMoot, it handles 18 of the most common linux Multimedia applications. You just map the special keys to remoot via a program like Keytoch, LinEAK or Xmodmap.

ReMoot:
http://www.kde-apps.org/content/show.php/ReMoot?content=63140

Yeah, I know it is KDE-apps, but it works with all Linux dists/windowmanagers and probably most *nix.

Revision history for this message
Mario Chisari (mc-launchpad-sganawa) said :
#11

I got it. Now Gnome incorporates (and launches) Compiz WM to manage all those pretty animations on windows. Compiz is a full-featured window manager, and have accessibility options on its own; those grab some keys combinations, like Win c (center mouse cursor on screen) or Win r (screen magnifier). These functions are active by default, and on a standard Gnome installation, there is no configuration tool for them.
So you have first to install compizconfig-settings-manager package via aptitude or Synaptic; then, on "System"->"Preferences" you will find a new Compiz configuration icon. Just open it, and, under "Accessibility", disable "advanced screen magnifier".
Magically, all key combinations will become usable.