Here is the component.
It has a fixed size of 64 as I couldn't get the [64:personality] rubric to work. I thought that it could be a limitation of userspace components, but I am not sure.
There are a lot more possible key events than you might imagine. Some could be fun to code to hard switches:
wiki.linuxcnc.org/cgi-bin/wiki.pl?Scancodes
I am about to send it to a test branch to see if it compiles on all platforms.