mooz / xkeysnail

Yet another keyboard remapping tool for X environment
891 stars 112 forks source link

Are there any plans to support keyup/keydown events? #93

Open chrisshroba opened 4 years ago

chrisshroba commented 4 years ago

I'd like to be able to use xkeysnail to show information only while a particular key is held. For example:

define_keymap(None, {
    KeyDown("LSuper"): show_information_window(),
    KeyUp("LSuper"):   hide_information_window(),
})

If this seems like an easy task but no one has the time to implement, I'd be happy to take a stab at it if someone can give me some pointers :)

Also, I believe this is a duplicate of #21, but that one is in Japanese so I think it's okay to open a new one.

michael-nhat commented 3 years ago

As far as I know, sxhkd has ability to remap key up event, may be you could learn something from it repos. I love both xkeysnail and sxhkd!

joshgoebel commented 2 years ago

This wouldn't be that difficult to do but it would require added:

This would perhaps be easier after output is enhanced a bit if I get to adding sticky keys (which will track key status and allow holds in the first place - which this kind of thing could be built upon)