3snowp7im / urn

Split tracker / timer with GTK+ frontend
GNU General Public License v3.0
126 stars 36 forks source link

Names of keys #11

Closed Stewmath closed 9 years ago

Stewmath commented 9 years ago

I'm trying to figure out what certain keys are named in order to map them. For instance, the back quote (`) symbol, or my numpad Enter key. What's a good way to determine their names?

deffi420 commented 9 years ago

From gdkkeysyms.h:

#define GDK_KEY_grave 0x060
#define GDK_KEY_quoteleft 0x060

So try "grave" or "quoteleft". To determine the names programmatically, see https://developer.gnome.org/gtk3/stable/gtk3-Keyboard-Accelerators.html#gtk-accelerator-parse

deffi420 commented 9 years ago
#define GDK_KEY_KP_Enter 0xff8d

"KP_Enter" for mapping numpad enter key.

Stewmath commented 9 years ago

Great, thanks a lot.