I'm using gmusicbrowser on Ubuntu Lucid, and I've had no luck getting keybindings to work.  Is this a known problem?

I've tried adding keybindings via the settings window, and by adding the KeyBindings property to the layout I'm using.  In both cases, I see no response to hitting the configured key.

A couple of layouts included with the package use escape as a keybinding to close the window.  I've tried modifying one of them to look for a different key, and once I do, escape no longer closes the window, but neither does my newly-configured key. 

Here's the test property I added to my own layout:

Keybindings   = Ctrl-n EnqueueSelected

(I know that Ctrl-q will do the EnqueueSelected action--I was just using this as a test.)

What am I doing wrong?

2 things are wrong about that line you added in the layout :
- it's KeyBindings not Keybindings
- the syntax used in the layouts for the keybinding is "c-n" (c for ctrl, a for alt, w for windows key)

Then there are more subtle problems :(

The keybindings only work if there are not used first by the widget that has the focus, it's particularly a problem for keys without modifiers (crtl, alt, win).
But even those with modifiers are sometimes affected, I just noticed that ctrl-n is used in gtk treeviews (used in SongList) to move the row cursor down, so that might explain why it didn't work for you.
I don't know if I should do something about this ctrl-n (and ctrl-p), maybe a way to disable them ? They are not implemented in SongTree btw.
Other keybindings used in SongList/SongTree : ctrl-f, ctrl-g, ctrl-a

Also, there was a bug in v1.0.2 where EnqueueSelected didn't work with SongTree :( it is fixed in the v1.0.x git branch along with a handful of bugs, but I don't know if I'll release a v1.0.3, it is also fixed in v1.1.x. So if you tested that on a layout with a SongTree, that might be the problem

Finally a stupid reason, I sometime forget to click on the "add shortcut" button :)

A precision, these shortcuts only work if a gmb layout window has the focus. For global keybindings, see the FAQ.

Hope that helps.

Thanks for the fast reply!

Quote from: Quentin Sculo on September 09, 2010, 22:13:21
- the syntax used in the layouts for the keybinding is "c-n" (c for ctrl, a for alt, w for windows key)

Ah.  Someone might want to update the layout documentation, which says "Key names are as shown in the key binding tab in the settings dialog." 

Quote from: Quentin Sculo on September 09, 2010, 22:13:21
The keybindings only work if there are not used first by the widget that has the focus, it's particularly a problem for keys without modifiers (crtl, alt, win).
But even those with modifiers are sometimes affected, I just noticed that ctrl-n is used in gtk treeviews (used in SongList) to move the row cursor down, so that might explain why it didn't work for you.
I don't know if I should do something about this ctrl-n (and ctrl-p), maybe a way to disable them ? They are not implemented in SongTree btw.
Other keybindings used in SongList/SongTree : ctrl-f, ctrl-g, ctrl-a

You're getting these from the code?  I couldn't find any other way to determine which keybindings were already present.

Quote from: Quentin Sculo on September 09, 2010, 22:13:21
A precision, these shortcuts only work if a gmb layout window has the focus. For global keybindings, see the FAQ.

What's a gmb layout window?  I'm afraid I don't know GNOME.

Thanks for the help!

Quote from: jdykstra on September 09, 2010, 22:46:47
Ah.  Someone might want to update the layout documentation, which says "Key names are as shown in the key binding tab in the settings dialog."
Oops, I'll fix it.

Quote from: jdykstra on September 09, 2010, 22:46:47
You're getting these from the code?  I couldn't find any other way to determine which keybindings were already present.
I know about ctrl-f (find), ctrl-g (next match), ctrl-a (select all) because there are mostly standard (gtk apps, firefox, ...), and because I had to reimplement them in SongTree.
Others by trying them :)

Quote from: jdykstra on September 09, 2010, 22:46:47
What's a gmb layout window?  I'm afraid I don't know GNOME.
Sorry, gmb is gmusicbrowser, and by "layout window" I mean windows defined by a layout, not the dialogs.

Thanks for the fast replies, and thanks for an incredibly useful and flexible music player.  I really appreciate all of the work that's gone into gmusicbrowser.