update combo docs
This commit is contained in:
parent
35b1a5843f
commit
80b44b5c1b
@ -14,16 +14,20 @@ corresponding handlers.
|
||||
|
||||
Combos may overlap, i.e. share match keys amongst each other.
|
||||
|
||||
The optional arguments `timeout` and `per_key_timeout` define the time window
|
||||
within which the match has to happen and whether the timeout is renewed after
|
||||
each key press, respectively. These can be customized for every combo
|
||||
individually.
|
||||
|
||||
## Keycodes
|
||||
|New Keycode |Description |
|
||||
|------------|----------------------------------------------------|
|
||||
|`KC.LEADER` | a dummy / convenience key for leader key sequences |
|
||||
|
||||
## Custom Combo Behavior
|
||||
Optional arguments that customize individual combos:
|
||||
* `fast_reset`: If True, allows tapping every key (default for sequences);
|
||||
if False, allows holding at least one key and tapping the rest to repeatedly
|
||||
activate the combo (default for chords).
|
||||
* `per_key_timeout`: If True, reset timeout on every key press (default for
|
||||
sequences).
|
||||
* `timeout`: Set the time window within which the match has to happen in ms.
|
||||
|
||||
## Example Code
|
||||
```python
|
||||
from kmk.keys import KC, make_key
|
||||
@ -40,6 +44,6 @@ combos.combos = [
|
||||
Chord((KC.A, KC.B), KC.LSFT)
|
||||
Chord((KC.A, KC.B, KC.C), KC.LALT)
|
||||
Sequence((KC.LEADER, KC.A, KC.B), KC.C)
|
||||
Sequence((KC.E, KC.F) KC.MYKEY, timeout=500, per_key_timeout=False)
|
||||
Sequence((KC.E, KC.F) KC.MYKEY, timeout=500, per_key_timeout=False, fast_reset=False)
|
||||
]
|
||||
```
|
||||
|
Loading…
x
Reference in New Issue
Block a user