This might be a silly question, but I'm trying to handle keyboard event in a gtk program. And I can't find in the documentation ( https://git.gnome.org/browse/gtk+/plain/gdk/gdkkeysyms.h )the keyval for keypad/numpad keys such as '+' or '-'.
The GDK_KEY_plus and GDK_KEY_minus are reffering to the '+' and '-' at the top of the keyboard, not those on the numpad.
Thanks for reading.
ps : I'm using an azerty keyboard.
答案 0 :(得分:3)
小键盘常量是GDK_KEY_KP_*
(代表小键盘)常量。 GDK_KEY_plus
为GDK_KEY_KP_Add
,GDK_KEY_minus
为GDK_KEY_KP_Subtract
。