keymap diff
1 removal
Words removed | 1 |
Total words | 2565 |
Words removed (%) | 0.04 |
536 lines
1 addition
Words added | 1 |
Total words | 2565 |
Words added (%) | 0.04 |
536 lines
/* Copyright 2020 Boardsource
/* Copyright 2020 Boardsource
*
*
* This program is free software: you can redistribute it and/or modify
* 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
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
* (at your option) any later version.
*
*
* This program is distributed in the hope that it will be useful,
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
*/
// sdgudev branch
// sdgukeymaps branch
/* @@@@@ maybe implement @@@@@
/* @@@@@ maybe implement @@@@@
- similarly, explore what combos to use for numbers for reason as above
- similarly, explore what combos to use for numbers for reason as above
- how does chording work for combos? any time you press multiple keys, it check if it's a combo? look into how layer independent combos work
- how does chording work for combos? any time you press multiple keys, it check if it's a combo? look into how layer independent combos work
- maybe leader key on outer columns, maybe leader key for selecting words/lines
- maybe leader key on outer columns, maybe leader key for selecting words/lines
- maybe only have shift for combo and use modtaps for the other three
- maybe only have shift for combo and use modtaps for the other three
- make more use of keyboard shortcuts for navigation
- make more use of keyboard shortcuts for navigation
- look into vim more
- look into vim more
- block out tab on raise layers and such
- block out tab on raise layers and such
- maybe have the enter slot be trns on all layers, so that all layers can access enter. would need to move delete on raise
- maybe have the enter slot be trns on all layers, so that all layers can access enter. would need to move delete on raise
- consider numpad number layout
- consider numpad number layout
- macro for control+/
- macro for control+/
- < and > in symbol layer?
- < and > in symbol layer?
- oneshot setup for some things
- oneshot setup for some things
- tap dance on num layer for parens and braces (instead of having another layer)
- tap dance on num layer for parens and braces (instead of having another layer)
- combo for underscore on main layer FOR_TYPING_THESE_THINGS
- combo for underscore on main layer FOR_TYPING_THESE_THINGS
- double shift to deactivate cap word, or block double shift while in caps word (currently can cause issues if trying to double shift during caps word)
- double shift to deactivate cap word, or block double shift while in caps word (currently can cause issues if trying to double shift during caps word)
- shift combo custom key release to type one of the letters (type the letter that you let go or the letter still held?)
- shift combo custom key release to type one of the letters (type the letter that you let go or the letter still held?)
- combos for parens/brackets with key release (or key still held) determining which to send
- combos for parens/brackets with key release (or key still held) determining which to send
- move gui combo since it gets accidentally double hit a lot
- move gui combo since it gets accidentally double hit a lot
- macro for "w" and "r"
- macro for "w" and "r"
- TD_DOT: Double tap the dot key to produce . space One-Shot Shift to quickly flow from one sentence to another. (from precondition)
- TD_DOT: Double tap the dot key to produce . space One-Shot Shift to quickly flow from one sentence to another. (from precondition)
- or, steno period. ,.cr for period with space and next letter cap
- or, steno period. ,.cr for period with space and next letter cap
- need a fix for typing .., like going up one directory
- need a fix for typing .., like going up one directory
- control + + and control + - macros (zooming)
- control + + and control + - macros (zooming)
- clean up organization of other files
- clean up organization of other files
- indicator if oneshot shift (or other oneshot mods?) is on
- indicator if oneshot shift (or other oneshot mods?) is on
- multi-shot key (activate one-shot after using it, can string keypresses on another layer together, like if numbers are on a different layer) https://discord.com/channels/440868230475677696/869812721552601088/918251721791258686
- multi-shot key (activate one-shot after using it, can string keypresses on another layer together, like if numbers are on a different layer) https://discord.com/channels/440868230475677696/869812721552601088/918251721791258686
- one key alt tab? https://beta.docs.qmk.fm/using-qmk/advanced-keycodes/feature_macros#super-alt-tab
- one key alt tab? https://beta.docs.qmk.fm/using-qmk/advanced-keycodes/feature_macros#super-alt-tab
- backspace on raise layer that does not require lifting thumb
- backspace on raise layer that does not require lifting thumb
- holding space while typing something automatically surrounds with space https://discord.com/channels/440868230475677696/869812721552601088/920066139806138409
- holding space while typing something automatically surrounds with space https://discord.com/channels/440868230475677696/869812721552601088/920066139806138409
- delete for left hand (so can use mouse and delete easier)
- delete for left hand (so can use mouse and delete easier)
- shift + hrm quickly results in unshifted hrm key to be sent, don't want this
- shift + hrm quickly results in unshifted hrm key to be sent, don't want this
- one handed experimental mirror layout, but automatically switch to a normal one if rhside of keyboard is used
- one handed experimental mirror layout, but automatically switch to a normal one if rhside of keyboard is used
- misc
- misc
@@@@@ addressed @@@@@
@@@@@ addressed @@@@@
- look into decreasing combo term since "e a" rolls can sometimes trigger "7" --- not relevant anymore since not using combos for numbers
- look into decreasing combo term since "e a" rolls can sometimes trigger "7" --- not relevant anymore since not using combos for numbers
- "s t" rolls also sometimes trigger "7" on the right hand --- not relevant anymore (see above)
- "s t" rolls also sometimes trigger "7" on the right hand --- not relevant anymore (see above)
- look into why KC_NO behaves like LOWER --- seems fixed
- look into why KC_NO behaves like LOWER --- seems fixed
- light indicator for CAPS LOCK --- done as a part of implementing caps word
- light indicator for CAPS LOCK --- done as a part of implementing caps word
- keep another LALT as a thumb key since it is easier for alt tab that way --- done
- keep another LALT as a thumb key since it is easier for alt tab that way --- done
- control (k and m) often hit the modded versions, while shift (j and w) often sends the non-mod plus the key --- this has been explored with PERMISSIVE_HOLD and HOLD_ON_OTHER_KEY_PRESS, no longer relevant because not using mod taps
- control (k and m) often hit the modded versions, while shift (j and w) often sends the non-mod plus the key --- this has been explored with PERMISSIVE_HOLD and HOLD_ON_OTHER_KEY_PRESS, no longer relevant because not using mod taps
- column combo (home and top row) mods --- does not work well for shift
- column combo (home and top row) mods --- does not work well for shift
- try shift on index fingers -- not relevant anymore since not using hrm
- try shift on index fingers -- not relevant anymore since not using hrm
- symbol layer (combo?) --- just a MO from raise layer
- symbol layer (combo?) --- just a MO from raise layer
- colon on numbers layer (for i in 1:10) --- done
- colon on numbers layer (for i in 1:10) --- done
- combos on raise layer for control and shift, so i don't have to mod first before changing layers --- done with using #define COMBO_ONLY_FROM_LAYER 0
- combos on raise layer for control and shift, so i don't have to mod first before changing layers --- done with using #define COMBO_ONLY_FROM_LAYER 0
- braces and parens on raise (number) layer, or a layer accessible from raise (symbolv2 or something) --- done
- braces and parens on raise (number) layer, or a layer accessible from raise (symbolv2 or something) --- done
- add toggles on outer columns (or combos) to number layer and such for one handed usage (layer tap toggle TT) --- done with TT on regular positions
- add toggles on outer columns (or combos) to number layer and such for one handed usage (layer tap toggle TT) --- done with TT on regular positions
- page up and page down --- done, along with home and end
- page up and page down --- done, along with home and end
- layer for nav, printscreen, etc --- moved printscreen, nav is on raise layer
- layer for nav, printscreen, etc --- moved printscreen, nav is on raise layer
- combo from layer 0, except when on steno layer --- disable combos when in steno layer, as any in alphas would interfere
- combo from layer 0, except when on steno layer --- disable combos when in steno layer, as any in alphas would interfere
- fix: if I type _ while in caps word mode and don't intend to type any more, I can't get out of it --- fixed, by using caps lock in caps word implementation, I can just designate those keys to not exit caps word and not worry about having to not shift them
- fix: if I type _ while in caps word mode and don't intend to type any more, I can't get out of it --- fixed, by using caps lock in caps word implementation, I can just designate those keys to not exit caps word and not worry about having to not shift them
- potentially disable permissive_hold as I can unintentionally trigger that
- potentially disable permissive_hold as I can unintentionally trigger that
- macro for macos screenshotting
- macro for macos screenshotting
*/
*/
#include QMK_KEYBOARD_H
#include QMK_KEYBOARD_H
#include "keymap_steno.h"
#include "keymap_steno.h"
#include "features/caps_word.h"
#include "features/caps_word.h"
#include "keymap.h"
#include "keymap.h"
enum layers {
enum layers {
_MAIN,
_MAIN,
_LOWER,
_LOWER,
_RAISE,
_RAISE,
_SYMBOL,
_SYMBOL,
_SYMBOL2,
_SYMBOL2,
_MISCFUNCS,
_MISCFUNCS,
_PLOVER,
_PLOVER,
_ADJUST,
_ADJUST,
};
};
enum custom_keycodes {
enum custom_keycodes {
LOWER = SAFE_RANGE,
LOWER = SAFE_RANGE,
RAISE,
RAISE,
SYMBOL,
SYMBOL,
SYMBOL2,
SYMBOL2,
PLOVER,
PLOVER,
ADJUST,
ADJUST,
EXT_PLV,
EXT_PLV,
MAC_PSCRR,
MAC_PSCRR,
MAC_PSCR,
MAC_PSCR,
};
};
enum combo_events {
enum combo_events {
GRVCOMBO,
GRVCOMBO,
EQLCOMBO,
EQLCOMBO,
BRIEFAND,
BRIEFAND,
// BRIEFFUNCTION,
// BRIEFFUNCTION,
RHNUMPADLAYERCOMBO,
RHNUMPADLAYERCOMBO,
LHCTRL,
LHCTRL,
LHSHFT,
LHSHFT,
LHALT,
LHALT,
LHGUI,
LHGUI,
LHALTSHFT,
LHALTSHFT,
RHCTRL,
RHCTRL,
RHSHFT,
RHSHFT,
RHALT,
RHALT,
RHGUI,
RHGUI,
RHALTSHFT,
RHALTSHFT,
NEXTSENTDOT,
NEXTSENTDOT,
// LH1,
// LH1,
// LH2,
// LH2,
// LH3,
// LH3,
// LH4,
// LH4,
// LH5,
// LH5,
// LH6,
// LH6,
// LH7,
// LH7,
// LH8,
// LH8,
// LH9,
// LH9,
// LH0,
// LH0,
// RH1,
// RH1,
// RH2,
// RH2,
// RH3,
// RH3,
// RH4,
// RH4,
// RH5,
// RH5,
// RH6,
// RH6,
// RH7,
// RH7,
// RH8,
// RH8,
// RH9,
// RH9,
// RH0,
// RH0,
COMBOLENGTH,
COMBOLENGTH,
};
};
uint16_t COMBO_LEN = COMBOLENGTH;
uint16_t COMBO_LEN = COMBOLENGTH;
#define ST_BOLT QK_STENO_BOLT
#define ST_BOLT QK_STENO_BOLT
#define ST_GEM QK_STENO_GEMINI
#define ST_GEM QK_STENO_GEMINI
#define GUI_SC LGUI_T(KC_SCLN)
#define GUI_SC LGUI_T(KC_SCLN)
#define ALT_Q LALT_T(KC_Q)
#define ALT_Q LALT_T(KC_Q)
#define SHFT_J LSFT_T(KC_J)
#define SHFT_J LSFT_T(KC_J)
#define CTRL_P LCTL_T(KC_P)
#define CTRL_P LCTL_T(KC_P)
#define GUI_Z RGUI_T(KC_Z)
#define GUI_Z RGUI_T(KC_Z)
#define ALT_V RALT_T(KC_V)
#define ALT_V RALT_T(KC_V)
#define SHFT_W RSFT_T(KC_W)
#define SHFT_W RSFT_T(KC_W)
#define CTRL_G RCTL_T(KC_G)
#define CTRL_G RCTL_T(KC_G)
// this is for other stuff in precondition's keymap
// this is for other stuff in precondition's keymap
uint16_t last_keycode = KC_NO;
uint16_t last_keycode = KC_NO;
// ',.p lrcg
// ',.p lrcg
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// no hrm
// no hrm
// [_MAIN] = LAYOUT_ortho_4x12(
// [_MAIN] = LAYOUT_ortho_4x12(
// KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLSH,
// KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLSH,
// XXXXXXX, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_ENT,
// XXXXXXX, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_ENT,
// XXXXXXX, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, XXXXXXX,
// XXXXXXX, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, XXXXXXX,
// XXXXXXX, KC_CAPS, XXXXXXX, KC_LALT, TT(_LOWER), KC_SPC, KC_BSPC, TT(_RAISE), XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
// XXXXXXX, KC_CAPS, XXXXXXX, KC_LALT, TT(_LOWER), KC_SPC, KC_BSPC, TT(_RAISE), XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
// ),
// ),
[_MAIN] = LAYOUT_ortho_4x12(
[_MAIN] = LAYOUT_ortho_4x12(
KC_TAB, KC_QUOT, KC_COMM, KC_DOT, CTRL_P, KC_Y, KC_F, CTRL_G, KC_C, KC_R, KC_L, KC_SLSH,
KC_TAB, KC_QUOT, KC_COMM, KC_DOT, CTRL_P, KC_Y, KC_F, CTRL_G, KC_C, KC_R, KC_L, KC_SLSH,
XXXXXXX, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_ENT,
XXXXXXX, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_ENT,
XXXXXXX, GUI_SC, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, GUI_Z, XXXXXXX, \
XXXXXXX, GUI_SC, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, GUI_Z, XXXXXXX, \
XXXXXXX, KC_CAPS, XXXXXXX, KC_LALT, TT(_LOWER), KC_SPC, KC_BSPC, TT(_RAISE), KC_RALT, XXXXXXX, XXXXXXX, XXXXXXX
XXXXXXX, KC_CAPS, XXXXXXX, KC_LALT, TT(_LOWER), KC_SPC, KC_BSPC, TT(_RAISE), KC_RALT, XXXXXXX, XXXXXXX, XXXXXXX
),
),
[_LOWER] = LAYOUT_ortho_4x12(
[_LOWER] = LAYOUT_ortho_4x12(
KC_ESC, LCTL(KC_C), LCTL(KC_V), LCTL(KC_X), LCTL(KC_S), LCTL(KC_Z), LCTL(KC_Y), _______, _______, _______, _______, KC_BSLS, \
KC_ESC, LCTL(KC_C), LCTL(KC_V), LCTL(KC_X), LCTL(KC_S), LCTL(KC_Z), LCTL(KC_Y), _______, _______, _______, _______, KC_BSLS, \
_______, LCTL(KC_A), KC_LBRC, KC_LCBR, KC_LPRN, KC_MINS, _______, KC_RPRN, KC_RCBR, KC_RBRC, _______, _______, \
_______, LCTL(KC_A), KC_LBRC, KC_LCBR, KC_LPRN, KC_MINS, _______, KC_RPRN, KC_RCBR, KC_RBRC, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
),
[_RAISE] = LAYOUT_ortho_4x12(
[_RAISE] = LAYOUT_ortho_4x12(
_______, KC_1, KC_2, KC_3, KC_4, KC_5, KC_PLUS, SYMBOL, SYMBOL2, _______, _______, _______, \
_______, KC_1, KC_2, KC_3, KC_4, KC_5, KC_PLUS, SYMBOL, SYMBOL2, _______, _______, _______, \
_______, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_DEL, \
_______, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_DEL, \
_______, KC_COLN, KC_COMM, KC_DOT, _______, KC_ENT, KC_SLSH, KC_HOME, KC_PGDN, KC_PGUP, KC_END, _______, \
_______, KC_COLN, KC_COMM, KC_DOT, _______, KC_ENT, KC_SLSH, KC_HOME, KC_PGDN, KC_PGUP, KC_END, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
),
[_SYMBOL] = LAYOUT_ortho_4x12(
[_SYMBOL] = LAYOUT_ortho_4x12(
_______, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, _______, _______, _______, _______, _______, KC_PIPE, \
_______, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, _______, _______, _______, _______, _______, KC_PIPE, \
_______, KC_CIRC, KC_AMPR, KC_ASTR, _______, KC_UNDS, _______, _______, _______, _______, _______, _______, \
_______, KC_CIRC, KC_AMPR, KC_ASTR, _______, KC_UNDS, _______, _______, _______, _______, _______, _______, \
_______, KC_COLN, KC_COMM, KC_DOT, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, KC_COLN, KC_COMM, KC_DOT, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
),
[_SYMBOL2] = LAYOUT_ortho_4x12(
[_SYMBOL2] = LAYOUT_ortho_4x12(
_______, _______, KC_RBRC, KC_RCBR, KC_RPRN, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, KC_RBRC, KC_RCBR, KC_RPRN, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, KC_LBRC, KC_LCBR, KC_LPRN, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, KC_LBRC, KC_LCBR, KC_LPRN, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
),
[_MISCFUNCS] = LAYOUT_ortho_4x12(
[_MISCFUNCS] = LAYOUT_ortho_4x12(
_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, _______, MAC_PSCRR, MAC_PSCR, _______, KC_PSCR, KC_INS, \
_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, _______, MAC_PSCRR, MAC_PSCR, _______, KC_PSCR, KC_INS, \
_______, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, _______, _______, _______, _______, _______, _______, \
_______, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, _______, _______, _______, _______, _______, _______, \
_______, KC_F11, KC_F12, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, KC_F11, KC_F12, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
),
[_ADJUST] = LAYOUT_ortho_4x12(
[_ADJUST] = LAYOUT_ortho_4x12(
_______, PLOVER, KC_MPRV, KC_MNXT, KC_MPLY, _______, _______, _______, _______, ST_GEM, ST_BOLT, RESET, \
_______, PLOVER, KC_MPRV, KC_MNXT, KC_MPLY, _______, _______, _______, _______, ST_GEM, ST_BOLT, RESET, \
_______, EXT_PLV, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, _______, _______, _______, _______, _______, \
_______, EXT_PLV, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, _______, _______, _______, _______, _______, \
_______, CMB_TOG, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, CMB_TOG, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
RGB_TOG, _______, _______, _______, _______, _______, _______, _______, _______, STN_PWR, STN_RE1, STN_RE2
RGB_TOG, _______, _______, _______, _______, _______, _______, _______, _______, STN_PWR, STN_RE1, STN_RE2
),
),
[_PLOVER] = LAYOUT_ortho_4x12(
[_PLOVER] = LAYOUT_ortho_4x12(
KC_TAB, STN_S1, STN_TL, STN_PL, STN_HL, STN_ST1, STN_ST3, STN_FR, STN_PR, STN_LR, STN_TR, STN_DR, \
KC_TAB, STN_S1, STN_TL, STN_PL, STN_HL, STN_ST1, STN_ST3, STN_FR, STN_PR, STN_LR, STN_TR, STN_DR, \
KC_LCTL, STN_S2, STN_KL, STN_WL, STN_RL, STN_ST2, STN_ST4, STN_RR, STN_BR, STN_GR, STN_SR, STN_ZR, \
KC_LCTL, STN_S2, STN_KL, STN_WL, STN_RL, STN_ST2, STN_ST4, STN_RR, STN_BR, STN_GR, STN_SR, STN_ZR, \
KC_LSFT, STN_N1, STN_N2, STN_N3, STN_N4, STN_N5, STN_N6, STN_N7, STN_N8, STN_N9, STN_NA, STN_NB, \
KC_LSFT, STN_N1, STN_N2, STN_N3, STN_N4, STN_N5, STN_N6, STN_N7, STN_N8, STN_N9, STN_NA, STN_NB, \
LOWER, KC_LSFT, KC_LGUI, KC_LALT, STN_A, STN_O, STN_E, STN_U, KC_BSPC, XXXXXXX, STN_NC, RAISE
LOWER, KC_LSFT, KC_LGUI, KC_LALT, STN_A, STN_O, STN_E, STN_U, KC_BSPC, XXXXXXX, STN_NC, RAISE
),
),
};
};
// void matrix_init_user() {
// void matrix_init_user() {
// steno_set_mode(STENO_MODE_GEMINI); // or STENO_MODE_BOLT
// steno_set_mode(STENO_MODE_GEMINI); // or STENO_MODE_BOLT
// }
// }
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
if (!process_caps_word(keycode, record)) { return false; }
if (!process_caps_word(keycode, record)) { return false; }
switch (keycode) {
switch (keycode) {
case LOWER:
case LOWER:
if (record->event.pressed) {
if (record->event.pressed) {
layer_on(_LOWER);
layer_on(_LOWER);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
} else {
} else {
layer_off(_LOWER);
layer_off(_LOWER);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
}
}
return false;
return false;
break;
break;
case RAISE:
case RAISE:
if (record->event.pressed) {
if (record->event.pressed) {
layer_on(_RAISE);
layer_on(_RAISE);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
} else {
} else {
layer_off(_RAISE);
layer_off(_RAISE);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
}
}
return false;
return false;
break;
break;
case SYMBOL:
case SYMBOL:
if (record->event.pressed) {
if (record->event.pressed) {
layer_on(_SYMBOL);
layer_on(_SYMBOL);
} else {
} else {
layer_off(_SYMBOL);
layer_off(_SYMBOL);
}
}
return false;
return false;
break;
break;
case SYMBOL2:
case SYMBOL2:
if (record->event.pressed) {
if (record->event.pressed) {
layer_on(_SYMBOL2);
layer_on(_SYMBOL2);
} else {
} else {
layer_off(_SYMBOL2);
layer_off(_SYMBOL2);
}
}
return false;
return false;
break;
break;
case ADJUST:
case ADJUST:
if (record->event.pressed) {
if (record->event.pressed) {
layer_on(_ADJUST);
layer_on(_ADJUST);
} else {
} else {
layer_off(_ADJUST);
layer_off(_ADJUST);
}
}
return false;
return false;
break;
break;
case PLOVER:
case PLOVER:
if (!record->event.pressed) {
if (!record->event.pressed) {
#ifdef AUDIO_ENABLE
#ifdef AUDIO_ENABLE
stop_all_notes();
stop_all_notes();
PLAY_SONG(plover_song);
PLAY_SONG(plover_song);
#endif
#endif
layer_on(_PLOVER);
layer_on(_PLOVER);
combo_disable();
combo_disable();
}
}
return false;
return false;
break;
break;
case EXT_PLV:
case EXT_PLV:
if (record->event.pressed) {
if (record->event.pressed) {
#ifdef AUDIO_ENABLE
#ifdef AUDIO_ENABLE
PLAY_SONG(plover_gb_song);
PLAY_SONG(plover_gb_song);
#endif
#endif
layer_off(_PLOVER);
layer_off(_PLOVER);
combo_enable();
combo_enable();
}
}
return false;
return false;
break;
break;
case MAC_PSCRR:
case MAC_PSCRR:
if (record->event.pressed) {
if (record->event.pressed) {
SEND_STRING(SS_LCTL(SS_LSFT(SS_LGUI("4"))));
SEND_STRING(SS_LCTL(SS_LSFT(SS_LGUI("4"))));
} else {
} else {
}
}
return false;
return false;
break;
break;
case MAC_PSCR:
case MAC_PSCR:
if (record->event.pressed) {
if (record->event.pressed) {
SEND_STRING(SS_LCTL(SS_LSFT("4")));
SEND_STRING(SS_LCTL(SS_LSFT("4")));
} else {
} else {
}
}
return false;
return false;
break;
break;
}
}
return true;
return true;
}
}
// bool gl_isadjuston = false;
// bool gl_isadjuston = false;
// void matrix_scan_user(void) {
// void matrix_scan_user(void) {
// if (!gl_isadjuston && IS_LAYER_ON(_LOWER) && IS_LAYER_ON(_RAISE))
// if (!gl_isadjuston && IS_LAYER_ON(_LOWER) && IS_LAYER_ON(_RAISE))
// {
// {
// layer_on(_ADJUST);
// layer_on(_ADJUST);
// gl_isadjuston = true;
// gl_isadjuston = true;
// }
// }
// if (gl_isadjuston && !(IS_LAYER_ON(_LOWER) && IS_LAYER_ON(_RAISE)))
// if (gl_isadjuston && !(IS_LAYER_ON(_LOWER) && IS_LAYER_ON(_RAISE)))
// {
// {
// layer_off(_ADJUST);
// layer_off(_ADJUST);
// gl_isadjuston = false;
// gl_isadjuston = false;
// }
// }
// }
// }
layer_state_t layer_state_set_user(layer_state_t state) {
layer_state_t layer_state_set_user(layer_state_t state) {
// switch (get_highest_layer(state)) {
// switch (get_highest_layer(state)) {
// case _MAIN:
// case _MAIN:
// rgb_matrix_sethsv_noeeprom(188, 255, 196); // 0, 170, 196
// rgb_matrix_sethsv_noeeprom(188, 255, 196); // 0, 170, 196
// break;
// break;
// case _RAISE:
// case _RAISE:
// rgb_matrix_sethsv_noeeprom(12, 171, 238); // 0, 255, 0 -> 238, 108, 77
// rgb_matrix_sethsv_noeeprom(12, 171, 238); // 0, 255, 0 -> 238, 108, 77
// break;
// break;
// case _LOWER:
// case _LOWER:
// rgb_matrix_sethsv_noeeprom(155, 74, 83); // 255, 0, 0 -> 59, 82, 73
// rgb_matrix_sethsv_noeeprom(155, 74, 83); // 255, 0, 0 -> 59, 82, 73
// break;
// break;
// case _ADJUST:
// case _ADJUST:
// rgb_matrix_sethsv_noeeprom(36, 43, 255); // 255, 238, 212
// rgb_matrix_sethsv_noeeprom(36, 43, 255); // 255, 238, 212
// break;
// break;
// case _PLOVER:
// case _PLOVER:
// rgb_matrix_sethsv_noeeprom(290, 82, 143); // 135, 97, 143
// rgb_matrix_sethsv_noeeprom(290, 82, 143); // 135, 97, 143
// break;
// break;
// default: // for any other layers, or the default layer
// default: // for any other layers, or the default layer
// rgb_matrix_sethsv_noeeprom(0, 0, 0);
// rgb_matrix_sethsv_noeeprom(0, 0, 0);
// break;
// break;
// }
// }
// return state;
// return state;
return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
}
}
void rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
void rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
if (host_keyboard_led_state().caps_lock) {
if (host_keyboard_led_state().caps_lock) {
for (uint8_t i = led_min; i <= led_max; i++) {
for (uint8_t i = led_min; i <= led_max; i++) {
// if the led position has the flag for keylight
// if the led position has the flag for keylight
if (g_led_config.flags[i] & LED_FLAG_KEYLIGHT) {
if (g_led_config.flags[i] & LED_FLAG_KEYLIGHT) {
rgb_matrix_set_color(i, 0, 170, 196);
rgb_matrix_set_color(i, 0, 170, 196);
}
}
}
}
}
}
}
}
// add briefs. 'for', 'that', 'this' etc.
// add briefs. 'for', 'that', 'this' etc.
// add some programming briefs like 'function'?
// add some programming briefs like 'function'?
const uint16_t PROGMEM grvcombo[] = {KC_TAB, KC_QUOT, COMBO_END};
const uint16_t PROGMEM grvcombo[] = {KC_TAB, KC_QUOT, COMBO_END};
const uint16_t PROGMEM eqlcombo[] = {KC_L, KC_SLSH, COMBO_END};
const uint16_t PROGMEM eqlcombo[] = {KC_L, KC_SLSH, COMBO_END};
const uint16_t PROGMEM rhnumpadlayercombo[] = {KC_BSPC, TT(_RAISE), COMBO_END};
const uint16_t PROGMEM rhnumpadlayercombo[] = {KC_BSPC, TT(_RAISE), COMBO_END};
// const uint16_t PROGMEM lhnumpadlayer[] = {KC_SPC, LOWER, COMBO_END};
// const uint16_t PROGMEM lhnumpadlayer[] = {KC_SPC, LOWER, COMBO_END};
// const uint16_t PROGMEM lh1[] = {KC_QUOT, KC_COMM, COMBO_END};
// const uint16_t PROGMEM lh1[] = {KC_QUOT, KC_COMM, COMBO_END};
// const uint16_t PROGMEM lh2[] = {KC_QUOT, KC_DOT, COMBO_END};
// const uint16_t PROGMEM lh2[] = {KC_QUOT, KC_DOT, COMBO_END};
// const uint16_t PROGMEM lh3[] = {KC_QUOT, KC_P, COMBO_END};
// const uint16_t PROGMEM lh3[] = {KC_QUOT, KC_P, COMBO_END};
// const uint16_t PROGMEM lh4[] = {KC_COMM, KC_DOT, COMBO_END};
// const uint16_t PROGMEM lh4[] = {KC_COMM, KC_DOT, COMBO_END};
// const uint16_t PROGMEM lh5[] = {KC_COMM, KC_P, COMBO_END};
// const uint16_t PROGMEM lh5[] = {KC_COMM, KC_P, COMBO_END};
// const uint16_t PROGMEM lh6[] = {KC_A, KC_O, COMBO_END};
// const uint16_t PROGMEM lh6[] = {KC_A, KC_O, COMBO_END};
// const uint16_t PROGMEM lh7[] = {KC_A, KC_E, COMBO_END};
// const uint16_t PROGMEM lh7[] = {KC_A, KC_E, COMBO_END};
// const uint16_t PROGMEM lh8[] = {KC_A, KC_U, COMBO_END};
// const uint16_t PROGMEM lh8[] = {KC_A, KC_U, COMBO_END};
// const uint16_t PROGMEM lh9[] = {KC_O, KC_E, COMBO_END};
// const uint16_t PROGMEM lh9[] = {KC_O, KC_E, COMBO_END};
// const uint16_t PROGMEM lh0[] = {KC_O, KC_U, COMBO_END};
// const uint16_t PROGMEM lh0[] = {KC_O, KC_U, COMBO_END};
// const uint16_t PROGMEM rh1[] = {KC_L, KC_R, COMBO_END};
// const uint16_t PROGMEM rh1[] = {KC_L, KC_R, COMBO_END};
// const uint16_t PROGMEM rh2[] = {KC_L, KC_C, COMBO_END};
// const uint16_t PROGMEM rh2[] = {KC_L, KC_C, COMBO_END};
// const uint16_t PROGMEM rh3[] = {KC_L, KC_G, COMBO_END};
// const uint16_t PROGMEM rh3[] = {KC_L, KC_G, COMBO_END};
// const uint16_t PROGMEM rh4[] = {KC_C, KC_R, COMBO_END};
// const uint16_t PROGMEM rh4[] = {KC_C, KC_R, COMBO_END};
// const uint16_t PROGMEM rh5[] = {KC_G, KC_R, COMBO_END};
// const uint16_t PROGMEM rh5[] = {KC_G, KC_R, COMBO_END};
// const uint16_t PROGMEM rh6[] = {KC_S, KC_N, COMBO_END};
// const uint16_t PROGMEM rh6[] = {KC_S, KC_N, COMBO_END};
// const uint16_t PROGMEM rh7[] = {KC_S, KC_T, COMBO_END};
// const uint16_t PROGMEM rh7[] = {KC_S, KC_T, COMBO_END};
// const uint16_t PROGMEM rh8[] = {KC_S, KC_H, COMBO_END};
// const uint16_t PROGMEM rh8[] = {KC_S, KC_H, COMBO_END};
// const uint16_t PROGMEM rh9[] = {KC_T, KC_N, COMBO_END};
// const uint16_t PROGMEM rh9[] = {KC_T, KC_N, COMBO_END};
// const uint16_t PROGMEM rh0[] = {KC_N, KC_H, COMBO_END};
// const uint16_t PROGMEM rh0[] = {KC_N, KC_H, COMBO_END};
const uint16_t PROGMEM lhctrl[] = {KC_U, KC_P, COMBO_END};
const uint16_t PROGMEM lhctrl[] = {KC_U, KC_P, COMBO_END};
const uint16_t PROGMEM lhshft[] = {KC_O, KC_DOT, COMBO_END};
const uint16_t PROGMEM lhshft[] = {KC_O, KC_DOT, COMBO_END};
const uint16_t PROGMEM lhalt[] = {KC_O, KC_COMM, COMBO_END};
const uint16_t PROGMEM lhalt[] = {KC_O, KC_COMM, COMBO_END};
const uint16_t PROGMEM lhgui[] = {KC_A, KC_QUOT, COMBO_END};
const uint16_t PROGMEM lhgui[] = {KC_A, KC_QUOT, COMBO_END};
const uint16_t PROGMEM lhaltshft[] = {KC_O, KC_COMM, KC_DOT, COMBO_END};
const uint16_t PROGMEM lhaltshft[] = {KC_O, KC_COMM, KC_DOT, COMBO_END};
const uint16_t PROGMEM rhctrl[] = {KC_H, KC_G, COMBO_END};
const uint16_t PROGMEM rhctrl[] = {KC_H, KC_G, COMBO_END};
const uint16_t PROGMEM rhshft[] = {KC_N, KC_C, COMBO_END};
const uint16_t PROGMEM rhshft[] = {KC_N, KC_C, COMBO_END};
const uint16_t PROGMEM rhalt[] = {KC_N, KC_R, COMBO_END};
const uint16_t PROGMEM rhalt[] = {KC_N, KC_R, COMBO_END};
const uint16_t PROGMEM rhgui[] = {KC_S, KC_L, COMBO_END};
const uint16_t PROGMEM rhgui[] = {KC_S, KC_L, COMBO_END};
const uint16_t PROGMEM rhaltshft[] = {KC_N, KC_R, KC_C, COMBO_END};
const uint16_t PROGMEM rhaltshft[] = {KC_N, KC_R, KC_C, COMBO_END};
const uint16_t PROGMEM briefand[] = {KC_A, KC_O, KC_DOT, COMBO_END};
const uint16_t PROGMEM briefand[] = {KC_A, KC_O, KC_DOT, COMBO_END};
const uint16_t PROGMEM nextsentdot[] = {KC_COMM, KC_DOT, KC_C, KC_R, COMBO_END};
const uint16_t PROGMEM nextsentdot[] = {KC_COMM, KC_DOT, KC_C, KC_R, COMBO_END};
// const uint16_t PROGMEM brieffunction[] = {KC_COMM, KC_DOT, KC_M, KC_T, KC_N, KC_S, COMBO_END};
// const uint16_t PROGMEM brieffunction[] = {KC_COMM, KC_DOT, KC_M, KC_T, KC_N, KC_S, COMBO_END};
combo_t key_combos[] = {
combo_t key_combos[] = {
[GRVCOMBO] = COMBO(grvcombo, KC_GRV),
[GRVCOMBO] = COMBO(grvcombo, KC_GRV),
[EQLCOMBO] = COMBO(eqlcombo, KC_EQL),
[EQLCOMBO] = COMBO(eqlcombo, KC_EQL),
[RHNUMPADLAYERCOMBO] = COMBO(rhnumpadlayercombo, MO(_MISCFUNCS)),
[RHNUMPADLAYERCOMBO] = COMBO(rhnumpadlayercombo, MO(_MISCFUNCS)),
// [LHCTRL] = COMBO(lhctrl, KC_LCTL),
// [LHCTRL] = COMBO(lhctrl, KC_LCTL),
[LHSHFT] = COMBO(lhshft, OSM(MOD_LSFT)),
[LHSHFT] = COMBO(lhshft, OSM(MOD_LSFT)),
// [LHALT] = COMBO(lhalt, KC_LALT),
// [LHALT] = COMBO(lhalt, KC_LALT),
// [LHGUI] = COMBO(lhgui, KC_LGUI),
// [LHGUI] = COMBO(lhgui, KC_LGUI),
// [LHALTSHFT] = COMBO_ACTION(lhaltshft),
// [LHALTSHFT] = COMBO_ACTION(lhaltshft),
// [RHCTRL] = COMBO(rhctrl, KC_RCTL),
// [RHCTRL] = COMBO(rhctrl, KC_RCTL),
[RHSHFT] = COMBO(rhshft, OSM(MOD_RSFT)),
[RHSHFT] = COMBO(rhshft, OSM(MOD_RSFT)),
// [RHALT] = COMBO(rhalt, KC_RALT),
// [RHALT] = COMBO(rhalt, KC_RALT),
// [RHGUI] = COMBO(rhgui, KC_RGUI),
// [RHGUI] = COMBO(rhgui, KC_RGUI),
// [RHALTSHFT] = COMBO_ACTION(rhaltshft),
// [RHALTSHFT] = COMBO_ACTION(rhaltshft),
[NEXTSENTDOT] = COMBO_ACTION(nextsentdot),
[NEXTSENTDOT] = COMBO_ACTION(nextsentdot),
// [LH1] = COMBO(lh1, KC_1),
// [LH1] = COMBO(lh1, KC_1),
// [LH2] = COMBO(lh2, KC_2),
// [LH2] = COMBO(lh2, KC_2),
// [LH3] = COMBO(lh3, KC_3),
// [LH3] = COMBO(lh3, KC_3),
// [LH4] = COMBO(lh4, KC_4),
// [LH4] = COMBO(lh4, KC_4),
// [LH5] = COMBO(lh5, KC_5),
// [LH5] = COMBO(lh5, KC_5),
// [LH6] = COMBO(lh6, KC_6),
// [LH6] = COMBO(lh6, KC_6),
// [LH7] = COMBO(lh7, KC_7),
// [LH7] = COMBO(lh7, KC_7),
// [LH8] = COMBO(lh8, KC_8),
// [LH8] = COMBO(lh8, KC_8),
// [LH9] = COMBO(lh9, KC_9),
// [LH9] = COMBO(lh9, KC_9),
// [LH0] = COMBO(lh0, KC_0),
// [LH0] = COMBO(lh0, KC_0),
// [RH1] = COMBO(rh1, KC_1),
// [RH1] = COMBO(rh1, KC_1),
// [RH2] = COMBO(rh2, KC_2),
// [RH2] = COMBO(rh2, KC_2),
// [RH3] = COMBO(rh3, KC_3),
// [RH3] = COMBO(rh3, KC_3),
// [RH4] = COMBO(rh4, KC_4),
// [RH4] = COMBO(rh4, KC_4),
// [RH5] = COMBO(rh5, KC_5),
// [RH5] = COMBO(rh5, KC_5),
// [RH6] = COMBO(rh6, KC_6),
// [RH6] = COMBO(rh6, KC_6),
// [RH7] = COMBO(rh7, KC_7),
// [RH7] = COMBO(rh7, KC_7),
// [RH8] = COMBO(rh8, KC_8),
// [RH8] = COMBO(rh8, KC_8),
// [RH9] = COMBO(rh9, KC_9),
// [RH9] = COMBO(rh9, KC_9),
// [RH0] = COMBO(rh0, KC_0),
// [RH0] = COMBO(rh0, KC_0),
// [BRIEFAND] = COMBO_ACTION(briefand),
// [BRIEFAND] = COMBO_ACTION(briefand),
// [BRIEFFUNCTION] = COMBO_ACTION(brieffunction),
// [BRIEFFUNCTION] = COMBO_ACTION(brieffunction),
// COMBO(lhnumpadlayer, MO(_MISCFUNCS)),
// COMBO(lhnumpadlayer, MO(_MISCFUNCS)),
};
};
void process_combo_event(uint16_t combo_index, bool pressed) {
void process_combo_event(uint16_t combo_index, bool pressed) {
switch(combo_index) {
switch(combo_index) {
case NEXTSENTDOT:
case NEXTSENTDOT:
if (pressed) {
if (pressed) {
if (!(get_mods() & MOD_MASK_SHIFT)) {
if (!(get_mods() & MOD_MASK_SHIFT)) {
tap_code(KC_DOT);
tap_code(KC_DOT);
tap_code(KC_SPC);
tap_code(KC_SPC);
/* Internal code of OSM(MOD_LSFT) */
/* Internal code of OSM(MOD_LSFT) */
add_oneshot_mods(MOD_BIT(KC_LSHIFT));
add_oneshot_mods(MOD_BIT(KC_LSHIFT));
} else {
} else {
// send ">" (KC_DOT + shift → ">")
// send ">" (KC_DOT + shift → ">")
tap_code(KC_DOT);
tap_code(KC_DOT);
}
}
}
}
break;
break;
case LHALTSHFT:
case LHALTSHFT:
if (pressed) {
if (pressed) {
register_code(KC_LSFT);
register_code(KC_LSFT);
register_code(KC_LALT);
register_code(KC_LALT);
} else {
} else {
unregister_code(KC_LALT);
unregister_code(KC_LALT);
unregister_code(KC_LSFT);
unregister_code(KC_LSFT);
}
}
break;
break;
case RHALTSHFT:
case RHALTSHFT:
if (pressed) {
if (pressed) {
register_code(KC_RSFT);
register_code(KC_RSFT);
register_code(KC_RALT);
register_code(KC_RALT);
} else {
} else {
unregister_code(KC_RALT);
unregister_code(KC_RALT);
unregister_code(KC_RSFT);
unregister_code(KC_RSFT);
}
}
break;
break;
case BRIEFAND:
case BRIEFAND:
if (pressed) {
if (pressed) {
SEND_STRING(" and");
SEND_STRING(" and");
}
}
break;
break;
// case BRIEFFUNCTION:
// case BRIEFFUNCTION:
// if (pressed) {
// if (pressed) {
// SEND_STRING("function");
// SEND_STRING("function");
// }
// }
// break;
// break;
}
}
}
}
void keyboard_post_init_user(void) {
void keyboard_post_init_user(void) {
// rgb_matrix_disable_noeeprom(); // disables Rgb, without saving settings
// rgb_matrix_disable_noeeprom(); // disables Rgb, without saving settings
rgb_matrix_mode_noeeprom(RGB_MATRIX_SOLID_COLOR);
rgb_matrix_mode_noeeprom(RGB_MATRIX_SOLID_COLOR);
rgb_matrix_sethsv_noeeprom(0, 0, 0);
rgb_matrix_sethsv_noeeprom(0, 0, 0);
}
}