Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

List acceptable key names #21

Open
SimonDedman opened this issue Mar 30, 2020 · 3 comments
Open

List acceptable key names #21

SimonDedman opened this issue Mar 30, 2020 · 3 comments

Comments

@SimonDedman
Copy link

Hi Michael,

Circling back to this after a long time; from this thread I was hoping to change my keys from + to +, i.e. I don't want to have to switch between numlock on & off every time I want to use pygrid. I tried changing the lines in ~/.config/pygrid.json from

"KP_1": "bottomleft",

to

"1": "bottomleft",

And rebooted but it then does nothing.

Please could you advise?

Thanks!

@lucasmocellin
Copy link

Hey @SimonDedman ,

I want to know the same thing, as I'm using it on my laptop and I don't have a keypad. :-)

looking at the code it seems related to the
def _bind_keys
https://developer.gnome.org/gtk3/stable/gtk3-Keyboard-Accelerators.html#gtk-accelerator-parse

But not sure how to change it. If you get an answer please let me know as well.

thank you guys, awesome program!

@pkkid
Copy link
Owner

pkkid commented Apr 14, 2020

One of the documentation pages states: "The names are the same as those in the gdk/gdkkeysyms.h header file but without the leading “GDK_KEY”."_ So I suspect the best documentation is the file itself.

https://gitlab.gnome.org/GNOME/gtk/blob/master/gdk/gdkkeysyms.h

@SimonDedman
Copy link
Author

Thanks for this folks. Some progress - KP_Left & KP_Right are the same as KP_4 & KP_6 but weirdly they still need the numlock key to be off. So with numlock on, neither "4" nor "KP_4" picks up the keypress of 4 on the numpad. So this is starting to feel like a bug to me to be honest - given there are separate names for the non-numlocked keys (right, insert, etc), that the numlocked keys (KP_1 etc) don't register unless numlock is off seems wrong?

Is anyone with a full keyboard able to verify this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants