evremap icon indicating copy to clipboard operation
evremap copied to clipboard

Inability to use remapped keys to remap more keys

Open drjaska opened this issue 1 year ago • 2 comments

I was considering switching away from keyszer which is an xkeysnail fork to everemap but found issues while migrating my configuration over.

Keys which have been remapped are unable to be remapped again. I found this by trying to remap capslock to F20 and then have other remaps depend on F20 with another key.

Configurations like this would be ideal:

[[remap]]
input = ["KEY_CAPSLOCK"]
output = ["KEY_F20"]

[[remap]]
input = ["KEY_F20", "KEY_W"]
output = ["KEY_HOME"]

[[remap]]
# this "deadnaming" could work for me but would probably be unintuitive for others
input = ["KEY_CAPSLOCK", "KEY_R"]
output = ["KEY_END"]

This would effectively disable capslock while still providing it as a modifier key for other remaps.

I also tried this remap but it sends w and q separately instead of remapping them to numlock.

[[remap]]
input = ["KEY_CAPSLOCK"]
output = ["KEY_W", "KEY_Q"]

[[remap]]
input = ["KEY_W", "KEY_Q"]
output = ["KEY_NUMLOCK"]
[[remap]]
input = ["KEY_CAPSLOCK"]
output = ["KEY_LEFTSHIFT", "KEY_Q"]

[[remap]]
input = ["KEY_LEFTSHIFT", "KEY_Q"]
output = ["KEY_NUMLOCK"]

This last one only types Q (capitalized) into a notepad.

drjaska avatar Dec 17 '23 20:12 drjaska

https://github.com/wez/evremap/blob/d0e8eb231fdeaf9c6457b36c1f04164150a82ad0/src/remapper.rs#L173-L174

This was an intended design decision? Why??

drjaska avatar Dec 17 '23 21:12 drjaska

The thinking was that it was the simplest and least-surprising outcome for most people

wez avatar Jun 09 '24 13:06 wez