From 786ebf87608dd4d7232cd0e66638382a55ceafa4 Mon Sep 17 00:00:00 2001 From: Ryan Date: Sun, 12 Nov 2023 18:25:46 +1100 Subject: [PATCH] Remove requirement for `keymap_steno.h` include in keymaps (#22423) * Remove requirement for `keymap_steno.h` include in keymaps * Add back keymap_steno.h with a note for the time being --- docs/feature_stenography.md | 6 +- docs/reference_keymap_extras.md | 1 - .../gherkin/keymaps/steno/keymap.c | 1 - .../gherkin/keymaps/talljoe-gherkin/keymap.c | 1 - keyboards/chord/zero/keymaps/default/keymap.c | 1 - keyboards/ergodox_ez/keymaps/steno/keymap.c | 3 - .../babyv/keymaps/bghull/keymap.c | 1 - keyboards/gboards/butterstick/sten.h | 1 - .../georgi/keymaps/colemak-dh/keymap.c | 1 - .../georgi/keymaps/default-flipped/keymap.c | 1 - .../gboards/georgi/keymaps/default/keymap.c | 1 - .../gboards/georgi/keymaps/minimal/keymap.c | 1 - .../gboards/georgi/keymaps/norman/keymap.c | 1 - keyboards/gboards/georgi/sten.h | 1 - .../split_cloud/keymaps/default/keymap.c | 1 - .../keymaps/halfkeyboard/keymap.c | 3 - keyboards/jian/keymaps/advanced/keymap.c | 1 - .../kbdfans/niu_mini/keymaps/yttyx/keymap.c | 1 - .../keebio/levinson/keymaps/dcompact/keymap.c | 2 - .../keebio/levinson/keymaps/steno/keymap.c | 1 - keyboards/lily58/keymaps/narze/keymap.c | 1 - .../mechwild/bbs/keymaps/default/keymap.c | 1 - .../sugarglider/keymaps/default/keymap.c | 1 - keyboards/planck/keymaps/altgr/keymap.c | 3 - keyboards/planck/keymaps/bghull/keymap.c | 1 - keyboards/planck/keymaps/dcompact/keymap.c | 1 - .../planck/keymaps/experimental/keymap.c | 1 - keyboards/planck/keymaps/hiea/keymap.c | 3 - keyboards/planck/keymaps/hieax/keymap.c | 3 - keyboards/planck/keymaps/sdothum/keymap.c | 3 - keyboards/planck/keymaps/steno/keymap.c | 1 - keyboards/planck/keymaps/yttyx/keymap.c | 1 - keyboards/preonic/keymaps/bghull/keymap.c | 1 - .../splitography/keymaps/default/keymap.c | 1 - .../keymap.c | 1 - .../splitography/keymaps/dvorak/keymap.c | 1 - .../splitography/keymaps/jeandeaual/keymap.c | 1 - keyboards/splitography/keymaps/multi/keymap.c | 1 - .../the_uni/keymaps/default/keymap.c | 1 - .../the_uni/keymaps/utility_belt/keymap.c | 1 - .../minivan/keymaps/dcompact/keymap.c | 1 - keyboards/xiudi/xd75/keymaps/raoeus/keymap.c | 1 - quantum/keymap_extras/keymap_steno.h | 119 +----------------- quantum/process_keycode/process_steno.c | 1 - quantum/process_keycode/process_steno.h | 1 + quantum/steno_keycodes.h | 119 ++++++++++++++++++ 46 files changed, 125 insertions(+), 175 deletions(-) create mode 100644 quantum/steno_keycodes.h diff --git a/docs/feature_stenography.md b/docs/feature_stenography.md index df4c9c6ad3..5ca3ea945f 100644 --- a/docs/feature_stenography.md +++ b/docs/feature_stenography.md @@ -104,7 +104,7 @@ After enabling stenography and optionally selecting a protocol, you may also nee !> If you had *explicitly* set `VIRSTER_ENABLE = no`, none of the serial stenography protocols (GeminiPR, TX Bolt) will work properly. You are expected to either set it to `yes`, remove the line from your `rules.mk` or send the steno chords yourself in an alternative way using the [provided interceptable hooks](#interfacing-with-the-code). -In your keymap, create a new layer for Plover, that you can fill in with the [steno keycodes](#keycode-reference) (you will need to include `keymap_steno.h`, see `planck/keymaps/steno/keymap.c` for an example). Remember to create a key to switch to the layer as well as a key for exiting the layer. +In your keymap, create a new layer for Plover, that you can fill in with the [steno keycodes](#keycode-reference). Remember to create a key to switch to the layer as well as a key for exiting the layer. Once you have your keyboard flashed, launch Plover. Click the 'Configure...' button. In the 'Machine' tab, select the Stenotype Machine that corresponds to your desired protocol. Click the 'Configure...' button on this tab and enter the serial port or click 'Scan'. Baud rate is fine at 9600 (although you should be able to set as high as 115200 with no issues). Use the default settings for everything else (Data Bits: 8, Stop Bits: 1, Parity: N, no flow control). @@ -149,8 +149,6 @@ At the end of this scenario given as an example, `chord` would have five bits se ## Keycode Reference :id=keycode-reference -You must include `keymap_steno.h` to your `keymap.c` with `#include "keymap_steno.h"` before you can use these keycodes - > Note: TX Bolt does not support the full set of keys. The TX Bolt implementation in QMK will map the GeminiPR keys to the nearest TX Bolt key so that one key map will work for both. |GeminiPR|TX Bolt|Steno Key| @@ -198,7 +196,7 @@ You must include `keymap_steno.h` to your `keymap.c` with `#include "keymap_sten |`STN_RES2`||(Reset 2)| |`STN_PWR`||(Power)| -If you do not want to hit two keys with one finger combined keycodes can be used. These are also defined in `keymap_steno.h`, and causes both keys to be reported as pressed or released. To use these keycodes define `STENO_COMBINEDMAP` in your `config.h` file. +If you do not want to hit two keys with one finger combined keycodes can be used. These cause both keys to be reported as pressed or released. To use these keycodes define `STENO_COMBINEDMAP` in your `config.h` file. |Combined key | Key1 | Key 2 | |---------------|--------|----------| diff --git a/docs/reference_keymap_extras.md b/docs/reference_keymap_extras.md index b70d505f1f..84751a512c 100644 --- a/docs/reference_keymap_extras.md +++ b/docs/reference_keymap_extras.md @@ -87,6 +87,5 @@ There are also a few which are not quite language-specific, but useful if you ar |Norman |`keymap_norman.h` |`sendstring_norman.h` | |Plover |`keymap_plover.h` | | |Plover (Dvorak) |`keymap_plover_dvorak.h` | | -|Steno |`keymap_steno.h` | | |Workman |`keymap_workman.h` |`sendstring_workman.h` | |Workman (ZXCVM) |`keymap_workman_zxcvm.h` |`sendstring_workman_zxcvm.h` | diff --git a/keyboards/40percentclub/gherkin/keymaps/steno/keymap.c b/keyboards/40percentclub/gherkin/keymaps/steno/keymap.c index 5f78ba1cde..ea473fa25f 100644 --- a/keyboards/40percentclub/gherkin/keymaps/steno/keymap.c +++ b/keyboards/40percentclub/gherkin/keymaps/steno/keymap.c @@ -1,5 +1,4 @@ #include QMK_KEYBOARD_H -#include "keymap_steno.h" const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { LAYOUT_ortho_3x10( diff --git a/keyboards/40percentclub/gherkin/keymaps/talljoe-gherkin/keymap.c b/keyboards/40percentclub/gherkin/keymaps/talljoe-gherkin/keymap.c index 111264c378..927192c63c 100644 --- a/keyboards/40percentclub/gherkin/keymaps/talljoe-gherkin/keymap.c +++ b/keyboards/40percentclub/gherkin/keymaps/talljoe-gherkin/keymap.c @@ -1,5 +1,4 @@ #include QMK_KEYBOARD_H -#include "keymap_steno.h" #define ST_BOLT QK_STENO_BOLT #define ST_GEM QK_STENO_GEMINI diff --git a/keyboards/chord/zero/keymaps/default/keymap.c b/keyboards/chord/zero/keymaps/default/keymap.c index a1edbe0cff..1134f264bc 100644 --- a/keyboards/chord/zero/keymaps/default/keymap.c +++ b/keyboards/chord/zero/keymaps/default/keymap.c @@ -2,7 +2,6 @@ // SPDX-License-Identifier: GPL-2.0-or-later #include QMK_KEYBOARD_H -#include "keymap_steno.h" const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [0] = LAYOUT( diff --git a/keyboards/ergodox_ez/keymaps/steno/keymap.c b/keyboards/ergodox_ez/keymaps/steno/keymap.c index 0e5d7e3a22..84c18fbd95 100644 --- a/keyboards/ergodox_ez/keymaps/steno/keymap.c +++ b/keyboards/ergodox_ez/keymaps/steno/keymap.c @@ -1,7 +1,4 @@ #include QMK_KEYBOARD_H -#include "debug.h" -#include "action_layer.h" -#include "keymap_steno.h" #define BASE 0 // default layer #define SYMB 1 // symbols diff --git a/keyboards/eyeohdesigns/babyv/keymaps/bghull/keymap.c b/keyboards/eyeohdesigns/babyv/keymaps/bghull/keymap.c index 7d22ebc670..7bccc6a46a 100644 --- a/keyboards/eyeohdesigns/babyv/keymaps/bghull/keymap.c +++ b/keyboards/eyeohdesigns/babyv/keymaps/bghull/keymap.c @@ -14,7 +14,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" #include "g/keymap_combo.h" diff --git a/keyboards/gboards/butterstick/sten.h b/keyboards/gboards/butterstick/sten.h index 42ccdd8e69..ca6b03f778 100644 --- a/keyboards/gboards/butterstick/sten.h +++ b/keyboards/gboards/butterstick/sten.h @@ -8,7 +8,6 @@ #pragma once #include QMK_KEYBOARD_H -#include "keymap_steno.h" extern size_t keymapsCount; // Total keymaps extern uint32_t cChord; // Current Chord diff --git a/keyboards/gboards/georgi/keymaps/colemak-dh/keymap.c b/keyboards/gboards/georgi/keymaps/colemak-dh/keymap.c index 9b3365d02f..932d48959c 100644 --- a/keyboards/gboards/georgi/keymaps/colemak-dh/keymap.c +++ b/keyboards/gboards/georgi/keymaps/colemak-dh/keymap.c @@ -12,7 +12,6 @@ #include QMK_KEYBOARD_H #include "sten.h" -#include "keymap_steno.h" // Steno Layers #define FUNCT ( LSD | LK | LP | LH ) diff --git a/keyboards/gboards/georgi/keymaps/default-flipped/keymap.c b/keyboards/gboards/georgi/keymaps/default-flipped/keymap.c index 2e63fe3c7d..19683179f3 100644 --- a/keyboards/gboards/georgi/keymaps/default-flipped/keymap.c +++ b/keyboards/gboards/georgi/keymaps/default-flipped/keymap.c @@ -12,7 +12,6 @@ #include QMK_KEYBOARD_H #include "sten.h" -#include "keymap_steno.h" // Proper Layers #define FUNCT (LSD | LK | LP | LH) diff --git a/keyboards/gboards/georgi/keymaps/default/keymap.c b/keyboards/gboards/georgi/keymaps/default/keymap.c index a9c2d4a47d..955ec0e406 100644 --- a/keyboards/gboards/georgi/keymaps/default/keymap.c +++ b/keyboards/gboards/georgi/keymaps/default/keymap.c @@ -12,7 +12,6 @@ #include QMK_KEYBOARD_H #include "sten.h" -#include "keymap_steno.h" // Proper Layers #define FUNCT (LSD | LK | LP | LH) diff --git a/keyboards/gboards/georgi/keymaps/minimal/keymap.c b/keyboards/gboards/georgi/keymaps/minimal/keymap.c index c4e78033bd..2f089866b2 100644 --- a/keyboards/gboards/georgi/keymaps/minimal/keymap.c +++ b/keyboards/gboards/georgi/keymaps/minimal/keymap.c @@ -12,7 +12,6 @@ #include QMK_KEYBOARD_H #include "sten.h" -#include "keymap_steno.h" // Proper Layers #define FUNCT (LSD | LK | LP | LH) diff --git a/keyboards/gboards/georgi/keymaps/norman/keymap.c b/keyboards/gboards/georgi/keymaps/norman/keymap.c index 870e460e2c..1b53cddd8b 100644 --- a/keyboards/gboards/georgi/keymaps/norman/keymap.c +++ b/keyboards/gboards/georgi/keymaps/norman/keymap.c @@ -12,7 +12,6 @@ #include QMK_KEYBOARD_H #include "sten.h" -#include "keymap_steno.h" // Proper Layers #define FUNCT (LSD | LK | LP | LH) diff --git a/keyboards/gboards/georgi/sten.h b/keyboards/gboards/georgi/sten.h index 44a6472044..e4bc31ef7a 100644 --- a/keyboards/gboards/georgi/sten.h +++ b/keyboards/gboards/georgi/sten.h @@ -7,7 +7,6 @@ #pragma once #include "georgi.h" -#include "keymap_steno.h" extern size_t keymapsCount; // Total keymaps extern uint32_t cChord; // Current Chord diff --git a/keyboards/handwired/split_cloud/keymaps/default/keymap.c b/keyboards/handwired/split_cloud/keymaps/default/keymap.c index f94a112c07..ad7e64e6ad 100644 --- a/keyboards/handwired/split_cloud/keymaps/default/keymap.c +++ b/keyboards/handwired/split_cloud/keymaps/default/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" // clang-format off diff --git a/keyboards/input_club/ergodox_infinity/keymaps/halfkeyboard/keymap.c b/keyboards/input_club/ergodox_infinity/keymaps/halfkeyboard/keymap.c index ca0442103d..35f459fab5 100644 --- a/keyboards/input_club/ergodox_infinity/keymaps/halfkeyboard/keymap.c +++ b/keyboards/input_club/ergodox_infinity/keymaps/halfkeyboard/keymap.c @@ -1,8 +1,5 @@ #include QMK_KEYBOARD_H -#include "debug.h" -#include "action_layer.h" #include "version.h" -#include "keymap_steno.h" #ifndef MIDI_ENABLE #error "Midi is not enabled" #endif diff --git a/keyboards/jian/keymaps/advanced/keymap.c b/keyboards/jian/keymaps/advanced/keymap.c index 4a6fdec063..7702fc20b7 100644 --- a/keyboards/jian/keymaps/advanced/keymap.c +++ b/keyboards/jian/keymaps/advanced/keymap.c @@ -11,7 +11,6 @@ typedef union { user_config_t user_config; #ifdef STENO_ENABLE -#include "keymap_steno.h" #endif // STENO_ENABLE diff --git a/keyboards/kbdfans/niu_mini/keymaps/yttyx/keymap.c b/keyboards/kbdfans/niu_mini/keymaps/yttyx/keymap.c index 55d5a80228..53ed794da8 100644 --- a/keyboards/kbdfans/niu_mini/keymaps/yttyx/keymap.c +++ b/keyboards/kbdfans/niu_mini/keymaps/yttyx/keymap.c @@ -1,6 +1,5 @@ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum layers { _BA, // Base (Balance Twelve mirror variant) diff --git a/keyboards/keebio/levinson/keymaps/dcompact/keymap.c b/keyboards/keebio/levinson/keymaps/dcompact/keymap.c index f501ef7cef..0495649c42 100644 --- a/keyboards/keebio/levinson/keymaps/dcompact/keymap.c +++ b/keyboards/keebio/levinson/keymaps/dcompact/keymap.c @@ -1,7 +1,5 @@ #include QMK_KEYBOARD_H -#include "keymap_steno.h" - // Custom Keycodes and Combinations Used #define DEL_SHF SFT_T(KC_DEL) #define QUAKE LCTL(KC_GRV) diff --git a/keyboards/keebio/levinson/keymaps/steno/keymap.c b/keyboards/keebio/levinson/keymaps/steno/keymap.c index 854ef41999..067e560d1b 100644 --- a/keyboards/keebio/levinson/keymaps/steno/keymap.c +++ b/keyboards/keebio/levinson/keymaps/steno/keymap.c @@ -1,5 +1,4 @@ #include QMK_KEYBOARD_H -#include "keymap_steno.h" extern keymap_config_t keymap_config; diff --git a/keyboards/lily58/keymaps/narze/keymap.c b/keyboards/lily58/keymaps/narze/keymap.c index 7438e72751..0f2764da6a 100644 --- a/keyboards/lily58/keymaps/narze/keymap.c +++ b/keyboards/lily58/keymaps/narze/keymap.c @@ -1,7 +1,6 @@ #include QMK_KEYBOARD_H #include "narze.h" #include "keymap_colemak.h" -#include "keymap_steno.h" #ifdef RGBLIGHT_ENABLE diff --git a/keyboards/mechwild/bbs/keymaps/default/keymap.c b/keyboards/mechwild/bbs/keymaps/default/keymap.c index 1eabdcd540..146099fba7 100644 --- a/keyboards/mechwild/bbs/keymaps/default/keymap.c +++ b/keyboards/mechwild/bbs/keymaps/default/keymap.c @@ -2,7 +2,6 @@ // SPDX-License-Identifier: GPL-2.0-or-later #include QMK_KEYBOARD_H -#include "keymap_steno.h" // Defines names for use in layer keycodes and the keymap enum layer_names { diff --git a/keyboards/mechwild/sugarglider/keymaps/default/keymap.c b/keyboards/mechwild/sugarglider/keymaps/default/keymap.c index ad0470a139..344dabfd2d 100644 --- a/keyboards/mechwild/sugarglider/keymaps/default/keymap.c +++ b/keyboards/mechwild/sugarglider/keymaps/default/keymap.c @@ -2,7 +2,6 @@ // SPDX-License-Identifier: GPL-2.0-or-later #include QMK_KEYBOARD_H -#include "keymap_steno.h" // Defines names for use in layer keycodes and the keymap enum layer_names { diff --git a/keyboards/planck/keymaps/altgr/keymap.c b/keyboards/planck/keymaps/altgr/keymap.c index 3ef9690a0a..f67682d794 100644 --- a/keyboards/planck/keymaps/altgr/keymap.c +++ b/keyboards/planck/keymaps/altgr/keymap.c @@ -67,9 +67,6 @@ #include QMK_KEYBOARD_H -#ifdef STENO_ENABLE -#include "keymap_steno.h" -#endif extern keymap_config_t keymap_config; diff --git a/keyboards/planck/keymaps/bghull/keymap.c b/keyboards/planck/keymaps/bghull/keymap.c index 4e556fc215..55f5c54b67 100644 --- a/keyboards/planck/keymaps/bghull/keymap.c +++ b/keyboards/planck/keymaps/bghull/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" #include "g/keymap_combo.h" #include "muse.h" diff --git a/keyboards/planck/keymaps/dcompact/keymap.c b/keyboards/planck/keymaps/dcompact/keymap.c index a63f86e7a8..f781d1e5c0 100644 --- a/keyboards/planck/keymaps/dcompact/keymap.c +++ b/keyboards/planck/keymaps/dcompact/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" // Custom Keycodes and Combinations Used #define DEL_SHF SFT_T(KC_DEL) diff --git a/keyboards/planck/keymaps/experimental/keymap.c b/keyboards/planck/keymaps/experimental/keymap.c index d5c7425439..6d6752952b 100644 --- a/keyboards/planck/keymaps/experimental/keymap.c +++ b/keyboards/planck/keymaps/experimental/keymap.c @@ -1,6 +1,5 @@ #include QMK_KEYBOARD_H -#include "keymap_steno.h" #include "version.h" extern keymap_config_t keymap_config; diff --git a/keyboards/planck/keymaps/hiea/keymap.c b/keyboards/planck/keymaps/hiea/keymap.c index eed4954096..be138a3eb4 100644 --- a/keyboards/planck/keymaps/hiea/keymap.c +++ b/keyboards/planck/keymaps/hiea/keymap.c @@ -67,9 +67,6 @@ #include QMK_KEYBOARD_H -#ifdef STENO_ENABLE -#include "keymap_steno.h" -#endif extern keymap_config_t keymap_config; diff --git a/keyboards/planck/keymaps/hieax/keymap.c b/keyboards/planck/keymaps/hieax/keymap.c index 80de85b884..4acd526916 100644 --- a/keyboards/planck/keymaps/hieax/keymap.c +++ b/keyboards/planck/keymaps/hieax/keymap.c @@ -67,9 +67,6 @@ #include QMK_KEYBOARD_H -#ifdef STENO_ENABLE -#include "keymap_steno.h" -#endif extern keymap_config_t keymap_config; diff --git a/keyboards/planck/keymaps/sdothum/keymap.c b/keyboards/planck/keymaps/sdothum/keymap.c index 597466ba47..03c605020c 100644 --- a/keyboards/planck/keymaps/sdothum/keymap.c +++ b/keyboards/planck/keymaps/sdothum/keymap.c @@ -67,9 +67,6 @@ #include QMK_KEYBOARD_H -#ifdef STENO_ENABLE -#include "keymap_steno.h" -#endif extern keymap_config_t keymap_config; diff --git a/keyboards/planck/keymaps/steno/keymap.c b/keyboards/planck/keymaps/steno/keymap.c index 9de27e47bf..4d22ee4ff3 100644 --- a/keyboards/planck/keymaps/steno/keymap.c +++ b/keyboards/planck/keymaps/steno/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" extern keymap_config_t keymap_config; diff --git a/keyboards/planck/keymaps/yttyx/keymap.c b/keyboards/planck/keymaps/yttyx/keymap.c index 1201163ac7..b3b39cd919 100644 --- a/keyboards/planck/keymaps/yttyx/keymap.c +++ b/keyboards/planck/keymaps/yttyx/keymap.c @@ -1,6 +1,5 @@ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum layers { _BA, // Base (Balance Twelve mirror variant) diff --git a/keyboards/preonic/keymaps/bghull/keymap.c b/keyboards/preonic/keymaps/bghull/keymap.c index eba6cd4f85..87cb9c6c69 100644 --- a/keyboards/preonic/keymaps/bghull/keymap.c +++ b/keyboards/preonic/keymaps/bghull/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum preonic_layers { _QWERTY, diff --git a/keyboards/splitography/keymaps/default/keymap.c b/keyboards/splitography/keymaps/default/keymap.c index 8fbd541810..9c6c7d6b26 100644 --- a/keyboards/splitography/keymaps/default/keymap.c +++ b/keyboards/splitography/keymaps/default/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum keyboard_layers { _QWERTY = 0, diff --git a/keyboards/splitography/keymaps/default_with_ctl_shft_alt_switched/keymap.c b/keyboards/splitography/keymaps/default_with_ctl_shft_alt_switched/keymap.c index 83874f7760..787f448ffb 100644 --- a/keyboards/splitography/keymaps/default_with_ctl_shft_alt_switched/keymap.c +++ b/keyboards/splitography/keymaps/default_with_ctl_shft_alt_switched/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum keyboard_layers { _QWERTY = 0, diff --git a/keyboards/splitography/keymaps/dvorak/keymap.c b/keyboards/splitography/keymaps/dvorak/keymap.c index 1d9ff41dd1..992cfd0abb 100644 --- a/keyboards/splitography/keymaps/dvorak/keymap.c +++ b/keyboards/splitography/keymaps/dvorak/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum keyboard_layers { _DVORAK = 0, diff --git a/keyboards/splitography/keymaps/jeandeaual/keymap.c b/keyboards/splitography/keymaps/jeandeaual/keymap.c index 9b5c3d554d..6e0f818688 100644 --- a/keyboards/splitography/keymaps/jeandeaual/keymap.c +++ b/keyboards/splitography/keymaps/jeandeaual/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum keyboard_layers { _GEMINI = 0, diff --git a/keyboards/splitography/keymaps/multi/keymap.c b/keyboards/splitography/keymaps/multi/keymap.c index f1a083e03f..42ab737698 100644 --- a/keyboards/splitography/keymaps/multi/keymap.c +++ b/keyboards/splitography/keymaps/multi/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum keyboard_layers { _QWERTY = 0, diff --git a/keyboards/stenokeyboards/the_uni/keymaps/default/keymap.c b/keyboards/stenokeyboards/the_uni/keymaps/default/keymap.c index 74aa207bd5..2240798328 100644 --- a/keyboards/stenokeyboards/the_uni/keymaps/default/keymap.c +++ b/keyboards/stenokeyboards/the_uni/keymaps/default/keymap.c @@ -16,7 +16,6 @@ along with this program. If not, see . */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum uni_layers { _PLOVER, diff --git a/keyboards/stenokeyboards/the_uni/keymaps/utility_belt/keymap.c b/keyboards/stenokeyboards/the_uni/keymaps/utility_belt/keymap.c index 47a89818f6..0962521903 100644 --- a/keyboards/stenokeyboards/the_uni/keymaps/utility_belt/keymap.c +++ b/keyboards/stenokeyboards/the_uni/keymaps/utility_belt/keymap.c @@ -16,7 +16,6 @@ along with this program. If not, see . */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" enum uni_layers { _PLOVER, diff --git a/keyboards/thevankeyboards/minivan/keymaps/dcompact/keymap.c b/keyboards/thevankeyboards/minivan/keymaps/dcompact/keymap.c index a036d563a1..614fe97710 100644 --- a/keyboards/thevankeyboards/minivan/keymaps/dcompact/keymap.c +++ b/keyboards/thevankeyboards/minivan/keymaps/dcompact/keymap.c @@ -15,7 +15,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" // Custom Keycodes and Combinations Used #define DEL_SHF SFT_T(KC_DEL) diff --git a/keyboards/xiudi/xd75/keymaps/raoeus/keymap.c b/keyboards/xiudi/xd75/keymaps/raoeus/keymap.c index 22578350c1..8c57995f2f 100644 --- a/keyboards/xiudi/xd75/keymaps/raoeus/keymap.c +++ b/keyboards/xiudi/xd75/keymaps/raoeus/keymap.c @@ -16,7 +16,6 @@ */ #include QMK_KEYBOARD_H -#include "keymap_steno.h" void matrix_init_user(void) { steno_set_mode(STENO_MODE_GEMINI); diff --git a/quantum/keymap_extras/keymap_steno.h b/quantum/keymap_extras/keymap_steno.h index 852b2f7121..d2635446c6 100644 --- a/quantum/keymap_extras/keymap_steno.h +++ b/quantum/keymap_extras/keymap_steno.h @@ -1,119 +1,6 @@ -/* Copyright 2017 Joseph Wasson - * - * 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 - * the Free Software Foundation, either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ +// Copyright 2023 QMK +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once -#include "keycodes.h" - -// List of keycodes for the steno keyboard. To prevent -// errors, this must be <= 42 total entries in order to -// support the GeminiPR protocol. -enum steno_keycodes { - STN__MIN = QK_STENO, - STN_FN = STN__MIN, - STN_NUM, - STN_N1 = STN_NUM, - STN_N2, - STN_N3, - STN_N4, - STN_N5, - STN_N6, - STN_SL, - STN_S1 = STN_SL, - STN_S2, - STN_TL, - STN_KL, - STN_PL, - STN_WL, - STN_HL, - STN_RL, - STN_A, - STN_O, - STN_STR, - STN_ST1 = STN_STR, - STN_ST2, - STN_RES1, - STN_RE1 = STN_RES1, - STN_RES2, - STN_RE2 = STN_RES2, - STN_PWR, - STN_ST3, - STN_ST4, - STN_E, - STN_U, - STN_FR, - STN_RR, - STN_PR, - STN_BR, - STN_LR, - STN_GR, - STN_TR, - STN_SR, - STN_DR, - STN_N7, - STN_N8, - STN_N9, - STN_NA, - STN_NB, - STN_NC, - STN_ZR, - STN__MAX = STN_ZR, // must be less than QK_STENO_BOLT -}; - -#ifdef STENO_COMBINEDMAP -enum steno_combined_keycodes { - STN_S3 = QK_STENO_COMB, - STN_TKL, - STN_PWL, - STN_HRL, - STN_FRR, - STN_PBR, - STN_LGR, - STN_TSR, - STN_DZR, - STN_AO, - STN_EU, - STN_COMB_MAX = STN_EU, -}; -#endif - -#ifdef STENO_ENABLE_BOLT -// TxBolt Codes -# define TXB_NUL 0 -# define TXB_S_L 0b00000001 -# define TXB_T_L 0b00000010 -# define TXB_K_L 0b00000100 -# define TXB_P_L 0b00001000 -# define TXB_W_L 0b00010000 -# define TXB_H_L 0b00100000 -# define TXB_R_L 0b01000001 -# define TXB_A_L 0b01000010 -# define TXB_O_L 0b01000100 -# define TXB_STR 0b01001000 -# define TXB_E_R 0b01010000 -# define TXB_U_R 0b01100000 -# define TXB_F_R 0b10000001 -# define TXB_R_R 0b10000010 -# define TXB_P_R 0b10000100 -# define TXB_B_R 0b10001000 -# define TXB_L_R 0b10010000 -# define TXB_G_R 0b10100000 -# define TXB_T_R 0b11000001 -# define TXB_S_R 0b11000010 -# define TXB_D_R 0b11000100 -# define TXB_Z_R 0b11001000 -# define TXB_NUM 0b11010000 -#endif // STENO_ENABLE_BOLT +#pragma message("keymap_steno.h include is no longer required") diff --git a/quantum/process_keycode/process_steno.c b/quantum/process_keycode/process_steno.c index af26d4ca86..bd4361580b 100644 --- a/quantum/process_keycode/process_steno.c +++ b/quantum/process_keycode/process_steno.c @@ -16,7 +16,6 @@ #include "process_steno.h" #include "quantum_keycodes.h" #include "eeconfig.h" -#include "keymap_steno.h" #include #ifdef VIRTSER_ENABLE # include "virtser.h" diff --git a/quantum/process_keycode/process_steno.h b/quantum/process_keycode/process_steno.h index 0dd2103218..5529980b71 100644 --- a/quantum/process_keycode/process_steno.h +++ b/quantum/process_keycode/process_steno.h @@ -19,6 +19,7 @@ #include #include #include "action.h" +#include "steno_keycodes.h" #define BOLT_STROKE_SIZE 4 #define GEMINI_STROKE_SIZE 6 diff --git a/quantum/steno_keycodes.h b/quantum/steno_keycodes.h new file mode 100644 index 0000000000..852b2f7121 --- /dev/null +++ b/quantum/steno_keycodes.h @@ -0,0 +1,119 @@ +/* Copyright 2017 Joseph Wasson + * + * 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 + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include "keycodes.h" + +// List of keycodes for the steno keyboard. To prevent +// errors, this must be <= 42 total entries in order to +// support the GeminiPR protocol. +enum steno_keycodes { + STN__MIN = QK_STENO, + STN_FN = STN__MIN, + STN_NUM, + STN_N1 = STN_NUM, + STN_N2, + STN_N3, + STN_N4, + STN_N5, + STN_N6, + STN_SL, + STN_S1 = STN_SL, + STN_S2, + STN_TL, + STN_KL, + STN_PL, + STN_WL, + STN_HL, + STN_RL, + STN_A, + STN_O, + STN_STR, + STN_ST1 = STN_STR, + STN_ST2, + STN_RES1, + STN_RE1 = STN_RES1, + STN_RES2, + STN_RE2 = STN_RES2, + STN_PWR, + STN_ST3, + STN_ST4, + STN_E, + STN_U, + STN_FR, + STN_RR, + STN_PR, + STN_BR, + STN_LR, + STN_GR, + STN_TR, + STN_SR, + STN_DR, + STN_N7, + STN_N8, + STN_N9, + STN_NA, + STN_NB, + STN_NC, + STN_ZR, + STN__MAX = STN_ZR, // must be less than QK_STENO_BOLT +}; + +#ifdef STENO_COMBINEDMAP +enum steno_combined_keycodes { + STN_S3 = QK_STENO_COMB, + STN_TKL, + STN_PWL, + STN_HRL, + STN_FRR, + STN_PBR, + STN_LGR, + STN_TSR, + STN_DZR, + STN_AO, + STN_EU, + STN_COMB_MAX = STN_EU, +}; +#endif + +#ifdef STENO_ENABLE_BOLT +// TxBolt Codes +# define TXB_NUL 0 +# define TXB_S_L 0b00000001 +# define TXB_T_L 0b00000010 +# define TXB_K_L 0b00000100 +# define TXB_P_L 0b00001000 +# define TXB_W_L 0b00010000 +# define TXB_H_L 0b00100000 +# define TXB_R_L 0b01000001 +# define TXB_A_L 0b01000010 +# define TXB_O_L 0b01000100 +# define TXB_STR 0b01001000 +# define TXB_E_R 0b01010000 +# define TXB_U_R 0b01100000 +# define TXB_F_R 0b10000001 +# define TXB_R_R 0b10000010 +# define TXB_P_R 0b10000100 +# define TXB_B_R 0b10001000 +# define TXB_L_R 0b10010000 +# define TXB_G_R 0b10100000 +# define TXB_T_R 0b11000001 +# define TXB_S_R 0b11000010 +# define TXB_D_R 0b11000100 +# define TXB_Z_R 0b11001000 +# define TXB_NUM 0b11010000 +#endif // STENO_ENABLE_BOLT