diff --git a/keyboards/preonic/keymaps/syepes/keymap.c b/keyboards/preonic/keymaps/syepes/keymap.c index 89437fb68621..cab69b5f4fc5 100644 --- a/keyboards/preonic/keymaps/syepes/keymap.c +++ b/keyboards/preonic/keymaps/syepes/keymap.c @@ -1,4 +1,4 @@ -/* Copyright 2015-2017 Jack Humbert +/* Copyright 2020-2021 Sebastian YEPES FERNANDEZ * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -59,12 +59,20 @@ enum preonic_keycodes { #define TD_VPAS TD(TD_V_PAST) #define TD_ZUDU TD(TD_Z_UNDU) #define TD_YRDU TD(TD_Y_REDU) +#define TD_1 TD(TD_1_EXLM) +#define TD_2 TD(TD_2_AT) +#define TD_3 TD(TD_3_HASH) +#define TD_4 TD(TD_4_DLR) +#define TD_5 TD(TD_5_PERC) +#define TD_6 TD(TD_6_CIRC) +#define TD_7 TD(TD_7_AMPR) +#define TD_8 TD(TD_8_ASTR) +#define TD_9 TD(TD_9_LPRN) +#define TD_0 TD(TD_0_RPRN) /* Sentinel value for invalid tap dance exit */ #define TAP_DANCE_NO_MATCH 64 - - enum tapdance_keycodes { TD_BRACKETS_LEFT, TD_BRACKETS_RIGHT, @@ -81,6 +89,16 @@ enum tapdance_keycodes { TD_V_PAST, TD_Z_UNDU, TD_Y_REDU, + TD_1_EXLM, + TD_2_AT, + TD_3_HASH, + TD_4_DLR, + TD_5_PERC, + TD_6_CIRC, + TD_7_AMPR, + TD_8_ASTR, + TD_9_LPRN, + TD_0_RPRN, }; typedef enum { @@ -108,31 +126,42 @@ void td_brackets_right_reset(qk_tap_dance_state_t *state, void *user_data); /* Tap Dance Definitions */ qk_tap_dance_action_t tap_dance_actions[] = { - /* Tap once for left parenthesis, twice for left bracket, thrice for left brace */ + /* Tap once for Left parenthesis, twice for left bracket, thrice for left brace */ [TD_BRACKETS_LEFT] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, td_brackets_left_finished, td_brackets_left_reset), - /* Tap once for right parenthesis, twice for right bracket, thrice for right brace */ + /* Tap once for Right parenthesis, twice for right bracket, thrice for right brace */ [TD_BRACKETS_RIGHT] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, td_brackets_right_finished, td_brackets_right_reset), - /* Tap once for plus, twice for equals */ + /* Tap once for Plus, twice for equals */ [TD_PLUS_EQUALS] = ACTION_TAP_DANCE_DOUBLE(KC_PLUS, KC_EQUAL), - /* Tap once for single quote, twice for double quote */ + /* Tap once for Single quote, twice for double quote */ [TD_QUOTE_DOUBLEQUOTE] = ACTION_TAP_DANCE_DOUBLE(KC_QUOTE, KC_DOUBLE_QUOTE), - /* Tap once for semicolon, twice for colon */ + /* Tap once for Semicolon, twice for colon */ [TD_SEMICOLON_COLON] = ACTION_TAP_DANCE_DOUBLE(KC_SCOLON, KC_COLON), - /* Tap once for slash, twice for question mark */ + /* Tap once for Slash, twice for question mark */ [TD_SLASH_QUESTION] = ACTION_TAP_DANCE_DOUBLE(KC_SLASH, KC_QUESTION), - /* Tap once for underscore, twice for minus */ + /* Tap once for Underscore, twice for minus */ [TD_UNDERSCORE_MINUS] = ACTION_TAP_DANCE_DOUBLE(KC_UNDERSCORE, KC_MINUS), - /* Tap once for grave, twice for tild */ + /* Tap once for Grave, twice for tild */ [TD_GRAVE_TILDE] = ACTION_TAP_DANCE_DOUBLE(KC_GRV, KC_TILD), /* Tap once for Left Shift, twice for Caps Lock */ [TD_LSFT_CAPS] = ACTION_TAP_DANCE_DOUBLE(KC_LSFT, KC_CAPS), - /* Tap once for letters, twice for Cut, Copy or Past */ + /* Tap once for Letters, twice for Cut, Copy or Past */ [TD_X_CUT] = ACTION_TAP_DANCE_DOUBLE(KC_X, OS_CUT), [TD_C_COPY] = ACTION_TAP_DANCE_DOUBLE(KC_C, OS_COPY), [TD_V_PAST] = ACTION_TAP_DANCE_DOUBLE(KC_V, OS_PAST), - /* Tap once for letters, twice for Undu or Redu */ + /* Tap once for Letters, twice for Undu or Redu */ [TD_Z_UNDU] = ACTION_TAP_DANCE_DOUBLE(KC_Z, OS_UNDU), [TD_Y_REDU] = ACTION_TAP_DANCE_DOUBLE(KC_Y, OS_REDU), + /* Tap once for Mumbers, twice for Chars */ + [TD_1_EXLM] = ACTION_TAP_DANCE_DOUBLE(KC_1, KC_EXLM), + [TD_2_AT] = ACTION_TAP_DANCE_DOUBLE(KC_2, KC_AT), + [TD_3_HASH] = ACTION_TAP_DANCE_DOUBLE(KC_3, KC_HASH), + [TD_4_DLR] = ACTION_TAP_DANCE_DOUBLE(KC_4, KC_DLR), + [TD_5_PERC] = ACTION_TAP_DANCE_DOUBLE(KC_5, KC_PERC), + [TD_6_CIRC] = ACTION_TAP_DANCE_DOUBLE(KC_6, KC_CIRC), + [TD_7_AMPR] = ACTION_TAP_DANCE_DOUBLE(KC_7, KC_AMPR), + [TD_8_ASTR] = ACTION_TAP_DANCE_DOUBLE(KC_8, KC_ASTR), + [TD_9_LPRN] = ACTION_TAP_DANCE_DOUBLE(KC_9, KC_LPRN), + [TD_0_RPRN] = ACTION_TAP_DANCE_DOUBLE(KC_0, KC_RPRN), }; @@ -140,7 +169,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { /* Workman * ,-----------------------------------------------------------------------------------. - * | ` ~ | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp | + * | ` ~ | 1 ! | 2 @ | 3 # | 4 $ | 5 % | 6 ^ | 7 & | 8 * | 9 ( | 0 ) | Bksp | * |------+------+------+------+------+------+------+------+------+------+------+------| * | Tab | Q | D | R | W | B | J | F | U | P | ; : | Del | * |------+------+------+------+------+------+------+------+------+------+------+------| @@ -152,7 +181,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * `-----------------------------------------------------------------------------------' */ [_WORKMAN] = LAYOUT_preonic_grid( - TD_GRTI, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, + TD_GRTI, TD_1, TD_2, TD_3, TD_4, TD_5, TD_6, TD_7, TD_8, TD_9, TD_0, KC_BSPC, KC_TAB, KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, TD_SCOL, KC_DEL, KC_ESC, KC_A, KC_S, KC_H, KC_T, KC_G, TD_YRDU, KC_N, KC_E, KC_O, KC_I, TD_SQDQ, TD_LSCP, TD_ZUDU, TD_XCUT, KC_M, TD_CCOP, TD_VPAS, KC_K, KC_L, KC_COMM, KC_DOT, TD_SLQU, KC_ENT,