summaryrefslogtreecommitdiff
path: root/keyboards/kyria/keymaps/thomasbaart/keymap.c
diff options
context:
space:
mode:
authorThomas Baart <thomas@splitkb.com>2020-05-21 21:43:39 +0200
committerGitHub <noreply@github.com>2020-05-21 12:43:39 -0700
commit02a8c874f885241306a62e8f43d6ed1f0ef1d3ac (patch)
treea518a6513aa15b5a06b176d4fed398f32cb6a3bb /keyboards/kyria/keymaps/thomasbaart/keymap.c
parentdae6f6b39bead1e5a709e7c07d4c3589fa5e1354 (diff)
downloadqmk_firmware-02a8c874f885241306a62e8f43d6ed1f0ef1d3ac.tar.gz
qmk_firmware-02a8c874f885241306a62e8f43d6ed1f0ef1d3ac.zip
[Keymap] Kyria: Updated personal keymap, added asapjockey's keymap (#8019)
* Updated personal keymap, added asapjockey's keymap * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Fixed layers, brackets * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c * Update keyboards/kyria/keymaps/asapjockey/keymap.c
Diffstat (limited to 'keyboards/kyria/keymaps/thomasbaart/keymap.c')
-rw-r--r--keyboards/kyria/keymaps/thomasbaart/keymap.c47
1 files changed, 36 insertions, 11 deletions
diff --git a/keyboards/kyria/keymaps/thomasbaart/keymap.c b/keyboards/kyria/keymaps/thomasbaart/keymap.c
index ea6ce0a749..6709cd8672 100644
--- a/keyboards/kyria/keymaps/thomasbaart/keymap.c
+++ b/keyboards/kyria/keymaps/thomasbaart/keymap.c
@@ -173,9 +173,20 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
return true;
}
+
+bool is_alt_tab_active = false;
+uint16_t alt_tab_timer = 0;
+
LEADER_EXTERNS();
void matrix_scan_user(void) {
+ if (is_alt_tab_active) {
+ if (timer_elapsed(alt_tab_timer) > 1000) {
+ unregister_code(KC_LALT);
+ is_alt_tab_active = false;
+ }
+ }
+
LEADER_DICTIONARY() {
leading = false;
leader_end();
@@ -192,7 +203,13 @@ void matrix_scan_user(void) {
SEQ_TWO_KEYS(KC_F, KC_P) { // Fusion Projection prefix
SEND_STRING("[Projection] ");
}
- SEQ_TWO_KEYS(KC_E, KC_S) { // Email splitkb
+ SEQ_TWO_KEYS(KC_B, KC_B) { // Basecone invoice description
+ SEND_STRING("[Leveranciersnaam] [Factuurnummer]");
+ }
+ SEQ_TWO_KEYS(KC_E, KC_S) { // Support email splitkb
+ SEND_STRING("support@splitkb.com");
+ }
+ SEQ_TWO_KEYS(KC_E, KC_T) { // Email splitkb
SEND_STRING("thomas@splitkb.com");
}
SEQ_TWO_KEYS(KC_E, KC_P) { // Email personal
@@ -204,15 +221,18 @@ void matrix_scan_user(void) {
SEQ_TWO_KEYS(KC_S, KC_V) { // Splitkb VAT number
SEND_STRING("NL210593349B01");
}
- SEQ_THREE_KEYS(KC_S, KC_D, KC_K) { // Splitkb Kyria build log
- SEND_STRING("https://docs.splitkb.com/docs/kyria-build-log/");
- }
SEQ_TWO_KEYS(KC_B, KC_C) { // Discord bongocat
SEND_STRING(":bongocat:\n");
}
SEQ_TWO_KEYS(KC_C, KC_B) { // Discord code block
SEND_STRING("```c" SS_LSFT("\n\n") "``` " SS_TAP(X_UP));
}
+ SEQ_TWO_KEYS(KC_Y, KC_S) { // Greeting
+ SEND_STRING("Yours sincerely,\n\nThomas Baart");
+ }
+ SEQ_THREE_KEYS(KC_M, KC_V, KC_G) { // Greeting
+ SEND_STRING("Met vriendelijke groet,\n\nThomas Baart");
+ }
}
}
@@ -292,20 +312,25 @@ void encoder_update_user(uint8_t index, bool clockwise) {
if (index == 0) {
switch (biton32(layer_state)) {
case QWERTY:
- // Move whole words. Hold shift to select while moving.
+ // History scrubbing. For Adobe products, hold shift while moving
+ // backward to go forward instead.
if (clockwise) {
- tap_code16(C(KC_RGHT));
+ tap_code16(C(KC_Z));
} else {
- tap_code16(C(KC_LEFT));
+ tap_code16(C(KC_Y));
}
break;
default:
- // History scrubbing. For Adobe products, hold shift while moving
- // backward to go forward instead.
+ // Switch between windows on Windows with alt tab.
if (clockwise) {
- tap_code16(C(KC_Z));
+ if (!is_alt_tab_active) {
+ is_alt_tab_active = true;
+ register_code(KC_LALT);
+ }
+ alt_tab_timer = timer_read();
+ tap_code16(KC_TAB);
} else {
- tap_code16(C(KC_Y));
+ tap_code16(S(KC_TAB));
}
break;
}