Closed Bertie2011 closed 1 year ago
This is known as a modal keymap. AFAIK there are several implementations of this, but I'll need to find something specific to be more help...
Meanwhile... essentially, you create a layer for the keys that you want to use for the modal keymap (i.e. what keys you'd want to hit after the "one shot" key that activates the layer.)
Then each key in that layer does their thing and switches the keymap layer back to base.
https://github.com/qmk/qmk_firmware/blob/master/keyboards/ergodox_ez/keymaps/vim/vim.h
Step one... see how someone is doing it.
First thing to notice is that any function which is bound to a key can run any sequence of commands or keys.
So you should be able to work out that, switching back to a base layer is easy, and possible from any key in an "upper" layer.
Yeahhhh, I figured you could probably do it using functions or some other workaround like layers.... but I would rather just be able to insert a "basic keycode" into my keymap and have it work right away😅 (without it being specific to a first key or a set of second keys).
.... so it should just kinda figure out what you want.
Wait for the AI QMK.
(no that's not a thing.)
This issue has been automatically marked as stale because it has not had activity in the last 90 days. It will be closed in the next 30 days unless it is tagged properly or other activity occurs.
For maintainers: Please label with bug
, in progress
, on hold
, discussion
or to do
to prevent the issue from being re-flagged.
This issue has been automatically closed because it has not had activity in the last 30 days. If this issue is still valid, re-open the issue and let us know. // [stale-action-closed]
We have one shot keys for modifiers and layers, but it would be nice to have a generic "One Shot" keycode that will hold the next key pressed until another key is pressed. Kind of like key lock keycode, but without having to disable the lock afterwards.
Example: Pressing in order
OS
,F3
,T
-> GeneratesF3 + T
Feature Request Type