This shows you the differences between two versions of the page.

Link to this comparison view

howto:desktop:create-global-shortcut-keys-for-rhythmbox-music-player-in-any-desktop [2018-08-05 04:25] (current)
Line 1: Line 1:
 +creator = Brendan Kidwell
 +&date created = 2008-04-10
 +{{tag>​keyboard linux music rhythmbox}}
 +====== Create Global Shortcut Keys for Rhythmbox Music Player in Any Desktop ======
 +I use Rhythmbox as my primary music player in Ubuntu Linux, but a few months ago I switched from GNOME desktop to KDE. Since Rhythmbox is a GNOME-style program I couldn'​t find an easy way to setup global hotkeys in the KDE desktop that send commands like Pause and Play to the running instance of Rhythmbox. The command-line tool "''​rhythmbox-client''"​ provides a solution:
 +Create a launcher anywhere in your desktop'​s menu system that runs the command you want, for example
 +<code bash>
 +rhythmbox-client --play-pause
 +And then assign a global shortcut key to that launcher, for example <​kbd>​Ctrl-Alt-\</​kbd>​.
 +Here is a list of all the commands rhythmbox-client supports:
 +|''​--no-start'' ​           |Don't start a new instance of Rhythmbox ​       |
 +|''​--quit'' ​               |Quit Rhythmbox ​                                |
 +|''​--no-present'' ​         |Don't present an existing Rhythmbox window ​    |
 +|''​--hide'' ​               |Hide the Rhythmbox window ​                     |
 +|''​--next'' ​               |Jump to next song                              |
 +|''​--previous'' ​           |Jump to previous song                          |
 +|''​--notify'' ​             |Show notification of the playing song          |
 +|''​--play'' ​               |Resume playback if currently paused ​           |
 +|''​--pause'' ​              ​|Pause playback if currently playing ​           |
 +|''​--play-pause'' ​         |Toggle play/pause mode                         |
 +|''​--play-uri=URI to play''​|Play a specified URI, importing it if necessary|
 +|''​--enqueue'' ​            |Add specified tracks to the play queue         |
 +|''​--clear-queue'' ​        ​|Empty the play queue before adding new tracks ​ |
 +|''​--print-playing'' ​      ​|Print the title and artist of the playing song |
 +|''​--print-playing-format''​|Print formatted details of the song            |
 +|''​--set-volume'' ​         |Set the playback volume ​                       |
 +|''​--volume-up'' ​          ​|Increase the playback volume ​                  |
 +|''​--volume-down'' ​        ​|Decrease the playback volume ​                  |
 +|''​--print-volume'' ​       |Print the current playback volume ​             |
 +|''​--mute'' ​               |Mute playback ​                                 |
 +|''​--unmute'' ​             |Unmute playback ​                               |
 +Note that the launcher you create will probably NOT open a terminal by default, so any output that might result from your Rhythmbox command (from the "''​--print-playing''"​ command, for example) will probably be lost.