From 24fab25b8471d7967ab1281c826395eb5987b1f9 Mon Sep 17 00:00:00 2001 From: Frieder Schlesier Date: Sun, 24 Sep 2023 18:22:34 +0200 Subject: [PATCH] switch up thumb keys, add umlauts to MouseLayer --- chocofi/README.org | 15 ++++++++--- chocofi/keymap.c | 66 +++++++++++++++++++++++++++++----------------- 2 files changed, 53 insertions(+), 28 deletions(-) diff --git a/chocofi/README.org b/chocofi/README.org index 2571c57..349d228 100644 --- a/chocofi/README.org +++ b/chocofi/README.org @@ -9,8 +9,11 @@ added my choc v1 brown switches. ** The Keymap +Alpha layer is ColemakDH. + + Since a lot of time is spent navigating code I use a locked =NAV= layer, -which makes it easy to move the cursor/screen. Most of my time coding +which makes it easy to move the cursor/screen. Most of my time coding is spent in VSCode. Therefore, often used combos like =Ctrl+f=, =Ctrl+h= (find an replace) and their shifted variants (find/replace in project) are available in the =NAV= layer with single keystrokes. @@ -34,9 +37,10 @@ are available in the =NAV= layer with single keystrokes. ** TODO Missing stuff -- Shift for right hand -- Ctrl for left hand -- Alt on base layer +- activate number layer with a left-hand key +- additional to FUN_NAV layer, create a pure nav layer + - remove HomeRowMods from FUN_NAV layer + - add useful shortcuts to the new PURE_NAV layer (e.g. WM_keys) - backtick key - umlauts and sharp s - euro € key @@ -47,6 +51,9 @@ are available in the =NAV= layer with single keystrokes. - this seems like a great example of composed layers and support for different environments https://github.com/0x64746b/qmk_firmware/blob/chocofi/keyboards/chocofi/keymaps/dtk35/keymap.c - https://github.com/qmk/qmk_firmware/blob/master/layouts/community/ergodox/german-kinergo/keymap.c#L101 +- https://github.com/manna-harbour/miryoku_qmk/blob/miryoku/users/manna-harbour_miryoku/readme.org +- HomeRowMods/BottomRowMods and other ideas: https://www.reddit.com/r/ErgoMechKeyboards/comments/tiejpp/home_row_mods_what_works_for_you/ + - https://precondition.github.io/home-row-mods#implementation - split up =SYM_NUM= layer, move missing symbols (from NAV layer to SYMBOLS layer) - hints for better symbols layers: https://getreuer.info/posts/keyboards/symbol-layer/index.html - make =.= and =,= available in new =NUM= layer for easier number input diff --git a/chocofi/keymap.c b/chocofi/keymap.c index df7d278..87df72a 100644 --- a/chocofi/keymap.c +++ b/chocofi/keymap.c @@ -33,34 +33,52 @@ enum { NUM_LAYERS }; +// Left-hand home row mods +#define HGUI_A LGUI_T(KC_A) +#define HALT_R LALT_T(KC_R) +#define HSFT_S LALT_T(KC_S) +#define HCTL_T LCTL_T(KC_T) + +// Right-hand home row mods +#define HCTL_N RCTL_T(KC_N) +#define HSFT_E RSFT_T(KC_E) +#define HALT_I LALT_T(KC_I) +#define HGUI_O RGUI_T(KC_O) + +// MOUSEMO on right hand index M +#define HMOU_M LT(MOUSEMO, KC_M) const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { - [COLEMAK] = LAYOUT_split_3x5_3( - KC_Q, KC_W, KC_F, KC_P, KC_B, KC_J, KC_L, KC_U, DE_Z, KC_BSPC, - LGUI_T(KC_A), LSFT_T(KC_R), LALT_T(KC_S), LCTL_T(KC_T), KC_G, LT(MOUSEMO,KC_M), RCTL_T(KC_N), LALT_T(KC_E), RSFT_T(KC_I), RGUI_T(KC_O), - DE_Y, KC_X, KC_C, KC_D, KC_V, KC_K, KC_H, DE_COMM, DE_DOT, DE_SLSH, - LSFT_T(KC_DEL), LT(NAV_FUN, KC_SPC), LGUI_T(KC_TAB), CTL_T(KC_ESC), LT(NUM_SYM, KC_ENT), TG(NAV_FUN) - ), + [COLEMAK] = LAYOUT_split_3x5_3 + ( + KC_Q, KC_W, KC_F, KC_P, KC_B, KC_J, KC_L, KC_U, DE_Z, KC_BSPC, + HGUI_A, HALT_R, HSFT_S, HCTL_T, KC_G, HMOU_M, HCTL_N, HSFT_E, HALT_I, HGUI_O, + DE_Y, KC_X, KC_C, KC_D, KC_V, KC_K, KC_H, DE_COMM, DE_DOT, DE_SLSH, + LSFT_T(KC_DEL), LT(NAV_FUN, KC_ESC), LSFT_T(KC_TAB), CTL_T(KC_SPC), LT(NUM_SYM, KC_ENT), TG(NAV_FUN) + ), - [NAV_FUN] = LAYOUT_split_3x5_3( - DE_BSLS, KC_F7, KC_F8, KC_F9, KC_F10, LCTL(KC_F), KC_HOME, KC_END, RCS(KC_F), KC_BSPC, - LGUI_T(DE_AT), LSFT_T(KC_F4), LALT_T(KC_F5), LCTL_T(KC_F6), KC_F11, LT(MOUSEMO, KC_LEFT), KC_DOWN, KC_UP, KC_RIGHT, KC_DEL, - DE_TILD, KC_F1, KC_F2, KC_F3, KC_F12, LCTL(KC_H), KC_PGDN, KC_PGUP, RCS(KC_H), LCTL(KC_P), - _______, _______, _______, _______, _______, _______ - ), + [NAV_FUN] = LAYOUT_split_3x5_3 + ( + DE_BSLS, KC_F7, KC_F8, KC_F9, KC_F10, LCTL(KC_F), KC_HOME, KC_END, RCS(KC_F), KC_BSPC, + LGUI_T(DE_AT), LALT_T(KC_F4), LSFT_T(KC_F5), LCTL_T(KC_F6), KC_F11, LT(MOUSEMO, KC_LEFT), KC_DOWN, KC_UP, KC_RIGHT, KC_DEL, + DE_TILD, KC_F1, KC_F2, KC_F3, KC_F12, LCTL(KC_H), KC_PGDN, KC_PGUP, RCS(KC_H), LCTL(KC_P), + _______, _______, _______, _______, _______, _______ + ), - [NUM_SYM] = LAYOUT_split_3x5_3( - DE_EXLM, DE_DQUO, DE_QUES, DE_PERC, DE_DLR, DE_CIRC, KC_7, KC_8, KC_9, DE_PLUS, - DE_LABK, DE_LCBR, DE_LPRN, DE_LBRC, DE_QUOT, DE_ASTR, KC_4, KC_5, KC_6, DE_MINS, - DE_RABK, DE_RCBR, DE_RPRN, DE_RBRC, DE_HASH, KC_0, KC_1, KC_2, KC_3, DE_EQL, - DE_PIPE, DE_AMPR, DE_AT, _______, _______, DE_DOT - ), + [NUM_SYM] = LAYOUT_split_3x5_3 + ( + DE_EXLM, DE_DQUO, DE_QUES, DE_PERC, DE_DLR, DE_CIRC, KC_7, KC_8, KC_9, DE_PLUS, + DE_LABK, DE_LCBR, DE_LPRN, DE_LBRC, DE_QUOT, DE_ASTR, KC_4, KC_5, KC_6, DE_MINS, + DE_RABK, DE_RCBR, DE_RPRN, DE_RBRC, DE_HASH, KC_0, KC_1, KC_2, KC_3, DE_EQL, + DE_PIPE, DE_AMPR, DE_AT, _______, _______, DE_DOT + ), - [MOUSEMO] = LAYOUT_split_3x5_3( - XXXXXXX, XXXXXXX, KC_MS_U, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, - XXXXXXX, KC_MS_L, KC_MS_D, KC_MS_R, KC_BTN3, _______, KC_VOLD, KC_MUTE, KC_VOLU, XXXXXXX, - XXXXXXX, KC_WH_L, XXXXXXX, KC_WH_R, XXXXXXX, KC_MPRV, KC_MSTP, KC_MPLY, KC_MNXT, XXXXXXX, - _______, KC_BTN1, KC_WH_D, KC_WH_U, KC_BTN2, _______ - ) + [MOUSEMO] = LAYOUT_split_3x5_3 + ( + XXXXXXX, XXXXXXX, KC_MS_U, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, DE_UDIA, XXXXXXX, + DE_ADIA, KC_MS_L, KC_MS_D, KC_MS_R, KC_BTN3, _______, KC_VOLD, KC_MUTE, KC_VOLU, DE_ODIA, + XXXXXXX, KC_WH_L, XXXXXXX, KC_WH_R, XXXXXXX, KC_MPRV, KC_MSTP, KC_MPLY, KC_MNXT, XXXXXXX, + _______, KC_BTN1, KC_WH_D, KC_WH_U, KC_BTN2, _______ + ) };