aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSébastien Dailly <sebastien@dailly.me>2026-07-29 08:32:38 +0200
committerSébastien Dailly <sebastien@dailly.me>2026-08-04 15:40:13 +0200
commitd0f494918c32b391ed0e0feaa69160cccc98f4a6 (patch)
tree6da083d6f538866e1783c355d1f4aaf849e1302b
parent340ddb0390f4b835e6723616a6a9956b206a7433 (diff)
QMK: Uses of custom_data in tap_dance instead of duplicating the code
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/keycodes.c23
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/keycodes.h4
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/keymap.c44
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.c55
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.h22
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/lighting.c53
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/overrides.c3
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/overrides.h1
-rw-r--r--qmk/keyboards/sofle_choc/keymaps/custom/readme.rst48
9 files changed, 145 insertions, 108 deletions
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.c b/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.c
index a3099e4..b0f36a1 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.c
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.c
@@ -17,6 +17,8 @@ static uint32_t key_timer; // timer for last keyboard activity, use
// 32bit value and function to make longer
// idle time possible
+static bool left_part;
+
bool keycodes_process_record(uint16_t keycode, keyrecord_t *record) {
@@ -32,6 +34,8 @@ bool keycodes_process_record(uint16_t keycode, keyrecord_t *record) {
}
}
+ left_part = record->event.key.row < (MATRIX_ROWS / 2);
+
switch (keycode) {
case KC_ESC:
case AL_ENT:
@@ -41,23 +45,20 @@ bool keycodes_process_record(uint16_t keycode, keyrecord_t *record) {
layer_clear();
}
return true;
+
// If a key where released just before, consider we are typing some text
- // and not starting a new sequence
+ // and do not start the tap tempo.
case KEY_F:
- if (record->event.pressed && timer_elapsed32(key_timer) < TAPPING_TERM) {
- if (is_caps_word_on()) {
- add_oneshot_mods(MOD_MASK_SHIFT);
- }
- register_code(KC_F);
+ if (record->event.pressed && left_part && timer_elapsed32(key_timer) < (TAPPING_TERM * 2)) {
+ //register_code(KC_F);
+ tap_code16(KC_F);
return false;
}
return true;
case KEY_J:
- if (record->event.pressed && timer_elapsed32(key_timer) < TAPPING_TERM) {
- if (is_caps_word_on()) {
- add_oneshot_mods(MOD_MASK_SHIFT);
- }
- register_code(KC_J);
+ if (record->event.pressed && !left_part && timer_elapsed32(key_timer) < (TAPPING_TERM * 2)) {
+ //register_code(KC_J);
+ tap_code16(KC_J);
return false;
}
return true;
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.h b/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.h
index 730e89d..3d3f40f 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.h
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/keycodes.h
@@ -1,13 +1,10 @@
#pragma once
#include QMK_KEYBOARD_H
#include "action.h"
-#include "keymap_bepo.h"
enum {
// Transform the key W into SHIFT or CAPSLOCK
TD_CAPSLOCK,
- // Transform the key E into È
- TD_EE,
TD_PRC,
TD_LAYER_KEYPAD,
TD_LAYER_ARROW,
@@ -18,7 +15,6 @@ enum {
LAYER_BASE,
LAYER_KEYPAD, // Layer used mainly on the left side of the keyboard
LAYER_ARROW, // Layer used on the right side of the keyboard
- LAYER_DIACRITIC,
};
#define KEY_APP LT(0, KC_APP)
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/keymap.c b/qmk/keyboards/sofle_choc/keymaps/custom/keymap.c
index 7edbf13..401e262 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/keymap.c
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/keymap.c
@@ -18,7 +18,6 @@
#include "process_tap_dance.h"
#include "process_key_override.h"
-#include "keymap_bepo.h"
#include "keycodes.h"
#include "quad_tapdance.h"
#include "enter_dance.h"
@@ -30,11 +29,10 @@
// Declare the tapdance table here.
// The functions for ACTION_TAP_DANCE_FN_ADVANCED or defined in "quand_dance"
tap_dance_action_t tap_dance_actions[] = {
- [TD_PRC] = ACTION_TAP_DANCE_DOUBLE(BP_EQL, BP_PERC),
+ [TD_PRC] = ACTION_TAP_DANCE_DOUBLE(KC_MINS, KC_EQL),
[TD_CAPSLOCK] = ACTION_TAP_DANCE_FN_ADVANCED_WITH_RELEASE(NULL, right_shift_released, right_shift_finished, right_shift_reset),
- [TD_LAYER_KEYPAD] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, keypad_finished, keypad_reset),
- [TD_LAYER_ARROW] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, arrow_finished, arrow_reset),
- [TD_EE] = ACTION_TAP_DANCE_DOUBLE(BP_COMM, BP_EGRV),
+ [TD_LAYER_KEYPAD] = ACTION_TAP_DANCE_LAYER(LAYER_KEYPAD),
+ [TD_LAYER_ARROW] = ACTION_TAP_DANCE_LAYER(LAYER_ARROW),
[TD_ENTER] = ACTION_TAP_DANCE_FN_ADVANCED_WITH_RELEASE(NULL, enter_released, enter_finished, enter_reset),
};
@@ -42,8 +40,6 @@ tap_dance_action_t tap_dance_actions[] = {
#define LY_KEYPAD TD(TD_LAYER_KEYPAD)
#define LY_ARROW TD(TD_LAYER_ARROW)
-// Activate the layer just for a single key
-#define LY_DIACRITIC OSL(LAYER_DIACRITIC)
#define RGB_UP QK_RGB_MATRIX_VALUE_UP
#define RGB_DOWN QK_RGB_MATRIX_VALUE_DOWN
@@ -51,15 +47,15 @@ tap_dance_action_t tap_dance_actions[] = {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/*
- * BÉPO
+ * QWERTY
* ,-----------------------------------------. ,-----------------------------------------.
- * | ESC | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | `% |
+ * | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | ` |
* |------+------+------+------+------+------| |------+------+------+------+------+------|
- * | $ | B | É | P | O | È | | ! | V | D | L | J | Z |
+ * | ESC | Q | W | E | R | T | | Y | U | I | O | P | Bspc |
* |------+------+------+------+------+------| |------+------+------+------+------+------|
- * | Tab | A | U | I | E | ; |-------. ,-------| CÇ | T | S | R | N | M |
+ * | Tab | A | S | D | F | G |-------. ,-------| H | J | K | L | ; | ' |
* |------+------+------+------+------+------| Mute | | Pause |------+------+------+------+------+------|
- * |LShift| À | Y | X | : | K |-------| |-------| ? | Q | G | H | F | W |
+ * |LShift| Z | X | C | V | B |-------| |-------| N | M | , | . | / |RShift|
* `-----------------------------------------/ / \ \-----------------------------------------'
* | LCTL | LGUI | LCMD | Layer| / Space / \Enter \ | Layer| RCMD | RGUI | RCTL |
* | | | | dwn |/ LALT / \ RALT \ | up | | | |
@@ -68,37 +64,30 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_BASE] = LAYOUT(
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KEY_PRC,
- KC_GRV, KC_Q, KC_W, KC_E, KC_R, KC_T, BP_DCIR, BP_V, BP_D, KC_O, BP_J, BP_Z,
- KC_TAB, KC_A, KC_S, KC_D, KEY_F, KC_G, BP_C, KEY_J, BP_S, BP_R, BP_N, BP_M,
- KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_MUTE, KC_MPLY,BP_QUOT, BP_Q, BP_G, BP_H, BP_F, KEY_LOK,
- KC_LCTL, KC_DELETE,KC_LGUI,LY_ARROW, AL_SPC, TD_ENTR,LY_KEYPAD, KEY_APP, KEY_INS, LY_DIACRITIC
+ KC_GRV, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
+ KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KEY_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_MUTE, KC_MPLY,KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KEY_LOK,
+ KC_LCTL, KC_DELETE,KC_LGUI,LY_ARROW, AL_SPC, TD_ENTR,LY_KEYPAD, KEY_APP, KEY_INS, KC_RCTL
),
// This layer is used to access to the numeric keypad, functions keys, and also provide some keys used with KC_LGUI
[LAYER_KEYPAD] = LAYOUT(
KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
- KC_TRNS, KC_TRNS, KC_P7, KC_P8, KC_P9, KC_BSPC, KC_TRNS, KC_TRNS, KC_PAST, KC_TRNS, KC_TRNS, S(BP_EQL),
+ KC_TRNS, KC_TRNS, KC_P7, KC_P8, KC_P9, KC_BSPC, KC_TRNS, KC_TRNS, KC_PAST, KC_TRNS, KC_TRNS, S(KC_MINS),
KC_TRNS, KC_TRNS, KC_P4, KC_P5, KEY_6, KC_TRNS, KC_TRNS, KC_PPLS, KC_PMNS, KC_PSLS, KC_TRNS, KC_TRNS,
- KC_LSFT, KC_TRNS, KC_P1, KC_P2, KC_P3, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_LSFT, KC_TRNS, KC_P1, KC_P2, KC_P3, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_DEL, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_P0, KC_PDOT, KC_TRNS, KC_TRNS, AL_SPC, AL_ENT, KC_TRNS, KC_TRNS, KC_RGUI, KC_TRNS
),
[LAYER_ARROW] = LAYOUT(
KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_BSPC, KC_TRNS, KC_HOME, KC_UP, KC_END, KC_TRNS, S(BP_EQL),
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_BSPC, KC_TRNS, KC_HOME, KC_UP, KC_END, KC_TRNS, S(KC_MINS),
KC_TRNS, RGB_UP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RIGHT,KC_TRNS, KC_PGUP,
- KC_LSFT, RGB_DOWN,KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MUTE, KC_MPLY, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KEY_PGDN,
+ KC_TRNS, RGB_DOWN,KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MUTE, KC_MPLY, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KEY_PGDN,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, AL_SPC, AL_ENT, KC_TRNS, KC_TRNS, KC_RGUI, KC_TRNS
),
-[LAYER_DIACRITIC] = LAYOUT(
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BP_PERC,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_BSPC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BP_CCED, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
-),
};
#if defined(ENCODER_MAP_ENABLE)
@@ -106,6 +95,5 @@ const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
[LAYER_BASE] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU), ENCODER_CCW_CW(QK_MOUSE_WHEEL_UP, QK_MOUSE_WHEEL_DOWN) },
[LAYER_KEYPAD] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
[LAYER_ARROW] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
- [LAYER_DIACRITIC] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
};
#endif
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.c b/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.c
index d35d31b..31689c5 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.c
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.c
@@ -13,14 +13,13 @@
// The second one is to switch in the layer mode when tapped, in this mode,
// you can go back into the normal layer by a single press on the key.
//
-static td_tap_t keypad_tap_state = {
- .state = TD_NONE
-};
// Functions that control what our tap dance key does
-void keypad_finished(tap_dance_state_t *state, void *user_data) {
- keypad_tap_state.state = cur_dance(state);
- switch (keypad_tap_state.state) {
+void tap_dance_layer_finished(tap_dance_state_t *state, void *user_data) {
+
+ tap_dance_layer_t *tap_layer = (tap_dance_layer_t *)user_data;
+ tap_layer->state = cur_dance(state);
+ switch (tap_layer->state) {
// Remove the layer with a single tap, this way I always have a key to
// remove the the layer, without knowing the previous state I had.
//
@@ -29,49 +28,19 @@ void keypad_finished(tap_dance_state_t *state, void *user_data) {
if (layer_state_is(LAYER_KEYPAD) || layer_state_is(LAYER_ARROW) ) {
layer_clear();
} else {
- layer_on(LAYER_KEYPAD);
- }
- break;
- case TD_SINGLE_HOLD: layer_on(LAYER_KEYPAD); break;
- default: break;
- }
-}
-
-void keypad_reset(tap_dance_state_t *state, void *user_data) {
- // If the key was held down and now is released then switch off the layer
- if (keypad_tap_state.state == TD_SINGLE_HOLD) {
- layer_clear();
- }
- keypad_tap_state.state = TD_NONE;
-}
-
-// Do the same for the arrow layer.
-static td_tap_t arrow_tap_state = {
- .state = TD_NONE
-};
-
-// Functions that control what our tap dance key does
-void arrow_finished(tap_dance_state_t *state, void *user_data) {
- arrow_tap_state.state = cur_dance(state);
- switch (arrow_tap_state.state) {
- // Remove the layer with a single tap, this way I always have a key to
- // remove the the layer, without knowing the previous state I had.
- case TD_SINGLE_TAP:
- if (layer_state_is(LAYER_KEYPAD) || layer_state_is(LAYER_ARROW) ) {
- layer_clear();
- } else {
- layer_on(LAYER_ARROW);
+ layer_on(tap_layer->layer);
}
break;
- case TD_SINGLE_HOLD: layer_on(LAYER_ARROW); break;
+ case TD_SINGLE_HOLD: layer_on(tap_layer->layer); break;
default: break;
}
}
-void arrow_reset(tap_dance_state_t *state, void *user_data) {
+void tap_dance_layer_reset(tap_dance_state_t *state, void *user_data) {
+ tap_dance_layer_t *tap_layer = (tap_dance_layer_t *)user_data;
// If the key was held down and now is released then switch off the layer
- if (arrow_tap_state.state == TD_SINGLE_HOLD) {
- layer_clear();
+ if (tap_layer->state == TD_SINGLE_HOLD) {
+ layer_off(tap_layer->layer);
}
- arrow_tap_state.state = TD_NONE;
+ tap_layer->state = TD_NONE;
}
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.h b/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.h
index bdca598..efa1f7a 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.h
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/layer_dance.h
@@ -1,9 +1,23 @@
#pragma once
#include QMK_KEYBOARD_H
-void keypad_finished(tap_dance_state_t *state, void *user_data);
-void keypad_reset(tap_dance_state_t *state, void *user_data);
+/**
+ * State of the tapdance, hold both the tapdance state, and the layer we need
+ * to activate when the key is activated.
+ */
+typedef struct {
+ td_state_t state;
+ uint8_t layer;
+} tap_dance_layer_t;
+void tap_dance_layer_finished(tap_dance_state_t *state, void *user_data);
+void tap_dance_layer_reset(tap_dance_state_t *state, void *user_data);
-void arrow_finished(tap_dance_state_t *state, void *user_data);
-void arrow_reset(tap_dance_state_t *state, void *user_data);
+/**
+ * Helper for creating the tap_dance key.
+ */
+#define ACTION_TAP_DANCE_LAYER(layer) \
+ { \
+ .fn = {NULL, tap_dance_layer_finished, tap_dance_layer_reset}, \
+ .user_data = (void *)&((tap_dance_layer_t){TD_NONE, layer}), \
+ }
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/lighting.c b/qmk/keyboards/sofle_choc/keymaps/custom/lighting.c
index 827e359..df3b5ec 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/lighting.c
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/lighting.c
@@ -33,6 +33,20 @@ void oneshot_mods_changed_lighting(uint8_t mods) {
one_shot_alt_flag = mods & MOD_MASK_ALT;
}
+uint8_t get_flags(void) {
+ uint8_t flags = 0;
+ if (get_mods() & MOD_MASK_CTRL) {
+ flags |= 0b001;
+ }
+ if (one_shot_alt_flag || (get_mods() & MOD_MASK_ALT)) {
+ flags |= 0b010;
+ }
+ if ((get_mods() & MOD_MASK_SHIFT) || host_keyboard_led_state().caps_lock) {
+ flags |= 0b100;
+ }
+ return flags;
+}
+
void housekeeping_task_lighting(void) {
// Colors for the mods
@@ -47,16 +61,7 @@ void housekeeping_task_lighting(void) {
hsv_of_color(HSV_WHITE), // 111
};
- uint8_t flags = 0;
- if (get_mods() & MOD_MASK_CTRL) {
- flags |= 0b001;
- }
- if (one_shot_alt_flag || (get_mods() & MOD_MASK_ALT)) {
- flags |= 0b010;
- }
- if ((get_mods() & MOD_MASK_SHIFT) || host_keyboard_led_state().caps_lock) {
- flags |= 0b100;
- }
+ uint8_t flags = get_flags();
uint8_t matrix_mode = rgb_matrix_get_mode();
if (matrix_mode != RGB_MATRIX_BREATHING && host_keyboard_led_state().caps_lock) {
@@ -82,6 +87,16 @@ void housekeeping_task_lighting(void) {
bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
// Activate effects depending of mods
+ // Check once if we need to activate the LED. This can be cause either a
+ // layer, or a modifier. If the state is default, exit the function early.
+ uint8_t flags = get_mods();
+ uint8_t current_layer = get_highest_layer(layer_state);
+ // The value `layer_state` is global
+
+ if (! (flags || current_layer || is_star || one_shot_alt_flag)) {
+ return false;
+ }
+
for (uint8_t row = 0; row < MATRIX_ROWS; ++row) {
for (uint8_t col = 0; col < MATRIX_COLS; ++col) {
uint8_t index = g_led_config.matrix_co[row][col];
@@ -96,19 +111,20 @@ bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
set_color(index, 42, 255, 255);
}
- if (layer == 0)
- continue;
+ //if (layer == 0 && ! flags)
+ // continue;
switch (keycode) {
case KC_F1 ... KC_F11:
set_color(index, 0, 0, 128);
break;
case KC_P1 ... KC_P0:
+ case KC_1 ... KC_0:
case KEY_6:
set_color(index, 42, 255, 255);
break;
- case BP_CCED:
- case BP_PERC:
+ case KC_BACKSLASH:
+ case KC_EQUAL:
case KC_PDOT:
case KC_KP_SLASH ... KC_KP_PLUS:
// Add a bit of red for the punction symbol
@@ -124,11 +140,20 @@ bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
break;
case KC_HOME:
case KC_END:
+ case KC_TAB:
set_color(index, HSV_GREEN);
break;
+ case KC_LSFT:
+ case KEY_LOK:
+ set_color(index, HSV_CYAN);
+ break;
case KC_BSPC:
+ case KC_DELETE:
+ set_color(index, HSV_PURPLE);
+ break;
case AL_SPC:
case AL_ENT:
+ case TD_ENTR:
set_color(index, HSV_BLUE);
break;
case QK_RGB_MATRIX_VALUE_UP:
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/overrides.c b/qmk/keyboards/sofle_choc/keymaps/custom/overrides.c
index 4eeaad5..08c101e 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/overrides.c
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/overrides.c
@@ -7,6 +7,3 @@
//
const key_override_t perc_key_override =
ko_make_basic(MOD_MASK_SHIFT, KEY_PRC, LSFT(KC_EQUAL));
-
-const key_override_t e_key_override =
- ko_make_basic(MOD_MASK_CTRL, KEY_F, RCTL(KC_F));
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/overrides.h b/qmk/keyboards/sofle_choc/keymaps/custom/overrides.h
index 5d983ed..be87361 100644
--- a/qmk/keyboards/sofle_choc/keymaps/custom/overrides.h
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/overrides.h
@@ -20,7 +20,6 @@ const key_override_t e_key_override ;
// This globally defines all key overrides to be used
const key_override_t *key_overrides[]= (const key_override_t *[]){
&perc_key_override,
- &e_key_override,
// Override the key GUI + MENU and to map the key desktop
&(ko_make_basic(MOD_MASK_GUI, KEY_APP, MENU)),
diff --git a/qmk/keyboards/sofle_choc/keymaps/custom/readme.rst b/qmk/keyboards/sofle_choc/keymaps/custom/readme.rst
new file mode 100644
index 0000000..075dc97
--- /dev/null
+++ b/qmk/keyboards/sofle_choc/keymaps/custom/readme.rst
@@ -0,0 +1,48 @@
+Effects
+=======
+
+Shift key / CapsLock
+--------------------
+
+The right shift key can be used to switch into capslock if the key is pressed
+without any other key.
+
+The keyboard will exit the mode by either:
+- The `KC_ESCAPE` key
+- The `KC_LSHFT` key
+- another action of the key `KC_RSHFT`
+
+Left and Right Control
+----------------------
+
+The `KC_F` and `KC_J` keys can be used to activate the respective left and right
+control keys.
+
+A mecanism tries to detect if the
+
+Layers
+======
+
+There are two layers, one for the numeric keypad, and one for the navigation
+arrow.
+
+The numeric keypad
+------------------
+
+This layer is mostly located on the left part of the keyboard, and is activated
+with the right layer key.
+
+The navigation arrows layer
+---------------------------
+
+This layer is located on the right part of the keyboard and is activated with
+the left layer key.
+
+Combos with other keys
+----------------------
+
+The navigation layer is automatically activated when the key `KC_LGUI` is
+pressed :
+
+- In windows this allow to move a window automatically (with `KC_LGUI` + arrows)
+- In Linux, this allow to map the key `mod4` + arrows to move between windows