diff --git a/config/base.keymap b/config/base.keymap index e4b9362..0ad1910 100644 --- a/config/base.keymap +++ b/config/base.keymap @@ -102,6 +102,17 @@ ZMK_BEHAVIOR(hmr, hold_tap, // right-hand HRMs hold-trigger-on-release; // requires PR #1423 ) +// replicate left-hand HRM for repeat combo +ZMK_BEHAVIOR(hml_repeat, hold_tap, + flavor = "balanced"; + tapping-term-ms = <280>; + quick-tap-ms = ; + global-quick-tap-ms = <150>; + bindings = <&kp>, <&key_repeat>; + hold-trigger-key-positions = ; + hold-trigger-on-release; +) + /* Custom behaviors */ // tap: num-word | double-tap: sticky num-layer | hold: num-layer diff --git a/config/combos.dtsi b/config/combos.dtsi index e9e2b88..a2c127d 100644 --- a/config/combos.dtsi +++ b/config/combos.dtsi @@ -14,13 +14,19 @@ #define COMBO_TERM_FAST 20 #define COMBO_TERM_SLOW 35 +// make homerow combos tap-only (so mods can be chorded correctly) +#define HRC_RETURN &hml LA(LCTRL) RETURN +#define HRC_REPEAT &hml_repeat LS(LCTRL) 0 +#define HRC_LPAR &hmr RS(LCTRL) LPAR +#define HRC_RPAR &hmr LA(LCTRL) RPAR + /* Punctuation (horizontal left hand) */ ZMK_COMBO(esc, &kp ESC, LT3 LT2, DEF NAV NUM, COMBO_TERM_FAST) ZMK_COMBO(tab, &kp TAB, LT2 LT1, DEF NAV NUM, COMBO_TERM_FAST) ZMK_COMBO(mouse, &smart_mouse, LT3 LT1, DEF NAV NUM, COMBO_TERM_FAST) -ZMK_COMBO(ret, &kp RETURN, LM3 LM2, DEF NAV NUM, COMBO_TERM_FAST) -ZMK_COMBO(repeat,&key_repeat, LM2 LM1, DEF NAV NUM, COMBO_TERM_FAST) +ZMK_COMBO(ret, HRC_RETURN, LM3 LM2, DEF NAV NUM, COMBO_TERM_FAST) +ZMK_COMBO(repeat,HRC_REPEAT, LM2 LM1, DEF NAV NUM, COMBO_TERM_FAST) ZMK_COMBO(cut, &kp LC(X), LB3 LB1, DEF NAV NUM, COMBO_TERM_SLOW) ZMK_COMBO(copy, &kp LC(INS), LB3 LB2, DEF NAV NUM, COMBO_TERM_FAST) @@ -29,8 +35,8 @@ ZMK_COMBO(paste, &kp LS(INS), LB2 LB1, DEF NAV NUM, COMBO_TERM_FAST) /* Brackets (horizontal right hand) */ ZMK_COMBO(lbrc, &kp LBRC, RT1 RT2, DEF NAV NUM, COMBO_TERM_FAST) ZMK_COMBO(rbrc, &kp RBRC, RT2 RT3, DEF NAV NUM, COMBO_TERM_FAST) -ZMK_COMBO(lpar, &kp LPAR, RM1 RM2, DEF NAV NUM, COMBO_TERM_FAST) -ZMK_COMBO(rpar, &kp RPAR, RM2 RM3, DEF NAV NUM, COMBO_TERM_FAST) +ZMK_COMBO(lpar, HRC_LPAR, RM1 RM2, DEF NAV NUM, COMBO_TERM_FAST) +ZMK_COMBO(rpar, HRC_RPAR, RM2 RM3, DEF NAV NUM, COMBO_TERM_FAST) ZMK_COMBO(lbrk, &kp LBKT, RB1 RB2, DEF NAV NUM, COMBO_TERM_FAST) ZMK_COMBO(rbrk, &kp RBKT, RB2 RB3, DEF NAV NUM, COMBO_TERM_FAST) diff --git a/readme.md b/readme.md index b3a65f5..ac2b0b6 100644 --- a/readme.md +++ b/readme.md @@ -234,9 +234,11 @@ natively that would require complex user-space implementations in QMK). Below are a few remaining issues: - ZMK does not yet support "tap-only" combos - ([#544](https://github.com/zmkfirmware/zmk/issues/544)). As a workaround, one - can pause briefly when chording multiple HRMs together on positions that - otherwise would trigger a combo. But this is at the top of my ZMK-wishlist. + ([#544](https://github.com/zmkfirmware/zmk/issues/544)), requiring a brief pause when + wanting to chord HRMs that overlap with combo positions. As a workaround, I implemented + all homerow combos as homerow-mod-combos. This is good enough for day-to-day, but does + not address all edge cases (eg removing mods from the mix doesn't work well). I am + really hoping for a native solution similar to QMK's "COMBO_MUST_TAP" property. - Another item on my wishlist are adaptive keys ([#1624](https://github.com/zmkfirmware/zmk/issues/1624)). This would open the door for things like spacespace becoming