Skip to content
This repository has been archived by the owner on Sep 18, 2024. It is now read-only.

Commit

Permalink
Remove CapsWord
Browse files Browse the repository at this point in the history
  • Loading branch information
pe committed Sep 18, 2024
1 parent e92ddfd commit f36193e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 22 deletions.
23 changes: 2 additions & 21 deletions keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_MUTE, KC_SNAP, KC_SIRI, KC_F15, KC_F16, KC_MCTL, LCMD(KC_MCTL), MC_LOCK,
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, KC_NUM, KC_PSLS, KC_PAST, KC_PMNS,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_DEL, KC_END, KC_PGDN, KC_P7, KC_P8, KC_P9,
QK_CAPS_WORD_TOGGLE, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, KC_P4, KC_P5, KC_P6, KC_PPLS,
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, KC_P4, KC_P5, KC_P6, KC_PPLS,
KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3,
KC_LCTL, KC_LOPTN, KC_LCMMD, KC_SPC, KC_RCMMD, KC_ROPTN, MO(MAC_FN), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT, KC_PENT),
[MAC_FN] = LAYOUT_iso_110(
Expand Down Expand Up @@ -85,7 +85,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {

bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
// RGB_MATRIX_INDICATOR_SET_COLOR(index, red, green, blue);
if (host_keyboard_led_state().caps_lock || is_caps_word_on()) {
if (host_keyboard_led_state().caps_lock) {
RGB_MATRIX_INDICATOR_SET_COLOR(CAPS_LOCK_LED_INDEX, 255, 0, 0);
} else {
if (!rgb_matrix_get_flags()) {
Expand All @@ -94,22 +94,3 @@ bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
}
return false;
}

bool caps_word_press_user(uint16_t keycode) {
switch (keycode) {
// Keycodes that continue Caps Word, with shift applied.
case KC_A ... KC_Z:
case KC_MINS:
case KC_SLSH: // replaces KC_UNDS because iso
add_weak_mods(MOD_BIT(KC_LSFT)); // Apply shift to next key.
return true;
// Keycodes that continue Caps Word, without shifting.
case KC_1 ... KC_0:
case KC_BSPC:
case KC_DEL:
return true;
// The rest
default:
return false; // Deactivate Caps Word.
}
}
1 change: 0 additions & 1 deletion rules.mk
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
VIA_ENABLE = yes
ENCODER_MAP_ENABLE = yes
CAPS_WORD_ENABLE = yes

VPATH += keyboards/keychron/common
SRC += keychron_common.c

0 comments on commit f36193e

Please sign in to comment.