How to set keyboard shortcuts?

Using applications, configuring, problems
Message
Author
npierce
Posts: 858
Joined: Tue 29 Dec 2009, 01:40

#21 Post by npierce »

p310don wrote:I don't understand the switches after the :aqualung. I.E.
<Key key="XF86AudioPlay">exec:aqualung -N 0 -L</Key> what are the -N 0 -L bits for?
From the Aqualung User's Manual:
3.5. Options for remote cue control

Note that remote controlling of instances is only possible if the instance you want to send a command to is running as the same user as you are when you issue the remote command.

-N, --session <int>
Specify the instance number to send the remote command to. Instances are numbered on a per user basis, starting with 0. Except for the zero-th instance (started first), the instance number is displayed in the title bar of the main window (e.g.: `Aqualung.3'). If you don't use this option, the following options will control the zero-th instance by default, except for -L which defaults to the present instance (so as to be able to start playback immediately from the command line).
-B, --back
Jump to previous track.
-F, --fwd
Jump to next track.
-L, --play
Start playing.
-U, --pause
Pause playback, or resume if already paused.
-T, --stop
Stop playback.
-V, --volume [m|M]|[=]<val>
Adjust the volume. m/M means mute; if = is present, the remote instance's volume control will be set to the value specified, otherwise, the volume will be adjusted by the supplied (signed) value. The values are in dB units.
-Q, --quit
Terminate remote instance.
This can be found at http://aqualung.factorial.hu/manual/aqu ... ml#id81916.

As you have discovered, Songbird does not use this syntax.

Apparently it once was supposed to handle command line arguments, which were added as a result of a request in the thread at the following URL. The syntax is explained in that thread. But the thread also indicates that it was quite buggy.

http://bugzilla.songbirdnest.com/show_bug.cgi?id=2788

So, in theory, if songbird is playing, the following command should pause it.

Code: Select all

songbird --hotkey=playback.playpause
It seems like most of the reports in that thread indicated that running this command caused an error. But if you are lucky, and it works for you, then you should be able to add this line to /root/.jwm/jwmrc-personal :

Code: Select all

<Key key="XF86AudioPlay">songbird --hotkey=playback.playpause</Key>
There is also an extension to Songbird that supposedly adds command line support using a different syntax (for instance, songbird -pause). It also is reported to be buggy, and it is not clear to me if it ever properly supported the Linux flavor of Songbird, although some folks seem to have had good luck with it.

http://addons.songbirdnest.com/addon/1381

As you have noticed, support for Linux in Songbird seems to be an on-again / off-again proposition. Since you have had success with another media player, you are probably better off staying with that.

I never tried Songbird, and know nothing about it except what I've read at the above URLs. So I've not tried any of this. If you feel adventurous, go for it. But be forewarned that the odds of success may be slim.
p310don wrote:Would I be right in the assumption that this media key support in puppy is only possible with programs that are controllable from the command line?
No. Some programs do have native hotkey support. There is no need to set up commands for them. As you have already discovered, Deadbeef has this support with the Global Hotkeys plugin. (It also can be controlled with commands (see deadbeef --help), but that is unnecessary when you use the plugin.) Audacious is another program that is said to have native hotkey support (after adding the hotkey plugin), although I've never tried it.

Post Reply