added wow layout

This commit is contained in:
Frederik Baerentsen 2020-05-10 21:22:04 +02:00
parent 18615ea76c
commit e225535c8d

View File

@ -139,24 +139,24 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
),
// /*
// * Layer template
// * World of Warcraft
// *
// * ,-------------------------------------------. ,-------------------------------------------.
// * | | | | | | | | | | | | | |
// * | ESC | ` | 1 | 2 | 3 | 4 | | | | | | | |
// * |--------+------+------+------+------+------| |------+------+------+------+------+--------|
// * | | | | | | | | | | | | | |
// * | SHIFT |SHIFT+`| Q | W | E |SHIFT+R| | | | | | | |
// * |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
// * | | | | | | | | | | | | | | | | | |
// * | CTRL | F | A | S | D | F | | | | M | Y | | | | | | |
// * `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
// * | | | | | | | | | | | |
// * | | TAB |SPACE | C | T | | B | I | | . | |
// * | | | | | | | | | | | |
// * `----------------------------------' `----------------------------------'
// */
[WoW] = LAYOUT(
KC_ESC , KC_GRV , KC_1 , KC_2 , KC_3 , KC_4 , _______, _______, _______, _______, _______, _______,
KC_LSFT, _______, KC_Q , KC_W , KC_E , KC_R , _______, _______, _______, _______, _______, _______,
_______, _______, KC_A , KC_S , KC_D , KC_F , _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, KC_TAB , KC_SPC , KC_C , KC_T , _______, _______, _______, KC_DOT , _______
KC_ESC , KC_GRV , KC_1 , KC_2 , KC_3 , KC_4 , _______, _______, _______, _______, _______, _______,
KC_LSFT, LSFT(KC_GRV), KC_Q , KC_W , KC_E , LSFT(KC_R) , _______, _______, _______, _______, _______, _______,
KC_LCTL, KC_F , KC_A , KC_S , KC_D , KC_F , _______, _______, KC_M , KC_Y , _______, _______, _______, _______, _______, _______,
_______, KC_TAB , KC_SPC , KC_C , KC_T , KC_B , KC_I , _______, KC_DOT , _______
),
// /*
@ -333,6 +333,12 @@ layer_state_t layer_state_set_user(layer_state_t state) {
}
bool led_update_user(led_t led_state) {
rgblight_set_layer_state(0, layer_state_cmp(QWERTY, 0));
// rgblight_set_layer_state(1, layer_state_cmp(LOWER, 1));
// rgblight_set_layer_state(2, layer_state_cmp(RAISE, 2));
// rgblight_set_layer_state(3, layer_state_cmp(NAV, 3));
// rgblight_set_layer_state(4, layer_state_cmp(ADJUST, 4));
// rgblight_set_layer_state(5, layer_state_cmp(WoW, 5));
rgblight_set_layer_state(6, led_state.caps_lock);
return true;
}
@ -512,6 +518,7 @@ void oled_task_user(void) {
void encoder_update_user(uint8_t index, bool clockwise) {
if (index == 0) {
switch (biton32(layer_state)) {
case WoW:
case QWERTY:
// Move whole words. Hold shift to select while moving.
if (!clockwise) {