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

Sticky layer documentation is unclear #2293

Open
shunlog opened this issue May 3, 2024 · 2 comments
Open

Sticky layer documentation is unclear #2293

shunlog opened this issue May 3, 2024 · 2 comments

Comments

@shunlog
Copy link

shunlog commented May 3, 2024

It is not clear what's meant by "key press" in the sentence "A sticky layer stays pressed until another key is pressed." on the sticky layer page. One would think it means when you physically press any key, but actually the sticky layer is only deactivated when a keycode is sent, so for example it isn't deactivated on a layer toggle, or on caps word activation.

It should be clarified, either by replacing "key pressed" with "keycode sent", or adding an info box or something.

@shunlog
Copy link
Author

shunlog commented May 3, 2024

BTW, can someone explain why would it be desirable for the sticky layer to be disabled only on a keycode sent, instead of on any key-press?

@caksoylar
Copy link
Contributor

caksoylar commented May 3, 2024

A docs update would be welcome. I also had this general thought on sticky keys and opened #2273:

I think we should fix sticky keys/layers pages to be more like hold-tap and mod-taps: There should be an intro to the generic/user-defined behavior-sticky-key in the former, and it should also mention the pre-defined &sk. Sticky layer page should have a note box saying it is just a sticky key with bindings = <&mo>.

BTW, can someone explain why would it be desirable for the sticky layer to be disabled only on a keycode sent, instead of on any key-press?

Historically the reason it works this way is related to above, since sticky layer is simply an instance of sticky key, and sticky keys only listen to keycode change events (rather than "position" change events in ZMK parlance).

I don't know which behavior would be desired, I can see it either way. e.g. you might want to use two sticky layer invocations to toggle a conditional layer, which would require the first sticky key to not be deactivated on toggling the second one. Maybe it should be an option in behavior,sticky-key to get disabled on keycode or position changed event.

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

2 participants