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

New hold-tap flavor: tap-when-interrupted #2816

Open
amacleod opened this issue Feb 9, 2025 · 0 comments
Open

New hold-tap flavor: tap-when-interrupted #2816

amacleod opened this issue Feb 9, 2025 · 0 comments

Comments

@amacleod
Copy link
Contributor

amacleod commented Feb 9, 2025

Use case: have a &mo momentary layer key that also holds down a modifier while undecided; in some games, holding LALT temporarily enables an informational overlay, so it would be nice to have a key on the main layer that holds LALT while held, but on a keyboard with very few keys, I would want to also use that key for enabling layers (see https://github.com/amacleod/zmk-config/blob/f6ca0f07ecfccd9b5f8c1c47e0586fc050835ce3/config/cradio.keymap#L130-L137 for my attempt, as inspired by @Nick-Munnich)

The hold-tap with tap-preferred and a large tapping term works okay: it holds LALT as intended, and does a tap of the binding in the layer but only after I release the physical key to which my hold-tap is bound (as is normal for tap-preferred hold-taps).

Based on Nick's comments, I propose a new hold-tap flavor, "tap-when-interrupted": when the key is initially pressed, if hold-while-undecided is set, it will activate its hold side, but then the moment there is an interruption, the tap behavior goes off.

For my use case, I would prefer that, when the interrupting key is pressed, things proceed in the following order:

  1. release the hold
  2. press the tap
  3. resolve the on-press portion of the interrupting key's behavior
  4. in any order, release the interrupting key and release the tap
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

1 participant