summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--data/constants/keycodes/keycodes_0.0.1_quantum.hjson15
-rw-r--r--docs/keycodes.md10
-rw-r--r--docs/tap_hold.md10
-rw-r--r--quantum/keycodes.h10
-rw-r--r--quantum/process_keycode/process_dynamic_tapping_term.c6
5 files changed, 32 insertions, 19 deletions
diff --git a/data/constants/keycodes/keycodes_0.0.1_quantum.hjson b/data/constants/keycodes/keycodes_0.0.1_quantum.hjson
index 1f3d2c70cd..e3db45be71 100644
--- a/data/constants/keycodes/keycodes_0.0.1_quantum.hjson
+++ b/data/constants/keycodes/keycodes_0.0.1_quantum.hjson
@@ -411,15 +411,24 @@
"0x7C70": {
"group": "quantum",
- "key": "DT_PRNT"
+ "key": "QK_DYNAMIC_TAPPING_TERM_PRINT",
+ "aliases": [
+ "DT_PRNT"
+ ]
},
"0x7C71": {
"group": "quantum",
- "key": "DT_UP"
+ "key": "QK_DYNAMIC_TAPPING_TERM_UP",
+ "aliases": [
+ "DT_UP"
+ ]
},
"0x7C72": {
"group": "quantum",
- "key": "DT_DOWN"
+ "key": "QK_DYNAMIC_TAPPING_TERM_DOWN",
+ "aliases": [
+ "DT_DOWN"
+ ]
},
"0x7C73": {
diff --git a/docs/keycodes.md b/docs/keycodes.md
index 3cde934828..bca0615b64 100644
--- a/docs/keycodes.md
+++ b/docs/keycodes.md
@@ -669,11 +669,11 @@ See also: [Mod-Tap](mod_tap.md)
See also: [Dynamic Tapping Term](tap_hold#dynamic-tapping-term)
-| Key | Description |
-|-------------|------------------------------------------------------------------------------------------------------------------------|
-| `DT_PRNT` | "Dynamic Tapping Term Print": Types the current tapping term, in milliseconds |
-| `DT_UP` | "Dynamic Tapping Term Up": Increases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
-| `DT_DOWN` | "Dynamic Tapping Term Down": Decreases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
+| Key | Aliases | Description |
+|-------------------------------|---------|-------------------------------------------------------------------------------------------|
+|`QK_DYNAMIC_TAPPING_TERM_PRINT`|`DT_PRNT`| Types the current tapping term, in milliseconds |
+|`QK_DYNAMIC_TAPPING_TERM_UP` |`DT_UP` | Increases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
+|`QK_DYNAMIC_TAPPING_TERM_DOWN` |`DT_DOWN`| Decreases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
## RGB Lighting :id=rgb-lighting
diff --git a/docs/tap_hold.md b/docs/tap_hold.md
index c8b708e2c9..8914b730b3 100644
--- a/docs/tap_hold.md
+++ b/docs/tap_hold.md
@@ -42,11 +42,11 @@ uint16_t get_tapping_term(uint16_t keycode, keyrecord_t *record) {
`DYNAMIC_TAPPING_TERM_ENABLE` is a feature you can enable in `rules.mk` that lets you use three special keys in your keymap to configure the tapping term on the fly.
-| Key | Description |
-|-------------|------------------------------------------------------------------------------------------------------------------------|
-| `DT_PRNT` | "Dynamic Tapping Term Print": Types the current tapping term, in milliseconds |
-| `DT_UP` | "Dynamic Tapping Term Up": Increases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
-| `DT_DOWN` | "Dynamic Tapping Term Down": Decreases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
+| Key | Aliases | Description |
+|-------------------------------|---------|-------------------------------------------------------------------------------------------|
+|`QK_DYNAMIC_TAPPING_TERM_PRINT`|`DT_PRNT`| Types the current tapping term, in milliseconds |
+|`QK_DYNAMIC_TAPPING_TERM_UP` |`DT_UP` | Increases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
+|`QK_DYNAMIC_TAPPING_TERM_DOWN` |`DT_DOWN`| Decreases the current tapping term by `DYNAMIC_TAPPING_TERM_INCREMENT`ms (5ms by default) |
Set the tapping term as usual with `#define TAPPING_TERM <value>` in `config.h` and add `DYNAMIC_TAPPING_TERM_ENABLE = yes` in `rules.mk`. Then, place the above three keys somewhere in your keymap and flash the new firmware onto your board.
diff --git a/quantum/keycodes.h b/quantum/keycodes.h
index c27a5a732c..2ef94f5d3e 100644
--- a/quantum/keycodes.h
+++ b/quantum/keycodes.h
@@ -706,9 +706,9 @@ enum qk_keycode_defines {
QK_SECURE_UNLOCK = 0x7C61,
QK_SECURE_TOGGLE = 0x7C62,
QK_SECURE_REQUEST = 0x7C63,
- DT_PRNT = 0x7C70,
- DT_UP = 0x7C71,
- DT_DOWN = 0x7C72,
+ QK_DYNAMIC_TAPPING_TERM_PRINT = 0x7C70,
+ QK_DYNAMIC_TAPPING_TERM_UP = 0x7C71,
+ QK_DYNAMIC_TAPPING_TERM_DOWN = 0x7C72,
QK_CAPS_WORD_TOGGLE = 0x7C73,
QK_AUTOCORRECT_ON = 0x7C74,
QK_AUTOCORRECT_OFF = 0x7C75,
@@ -1088,6 +1088,9 @@ enum qk_keycode_defines {
SE_UNLK = QK_SECURE_UNLOCK,
SE_TOGG = QK_SECURE_TOGGLE,
SE_REQ = QK_SECURE_REQUEST,
+ DT_PRNT = QK_DYNAMIC_TAPPING_TERM_PRINT,
+ DT_UP = QK_DYNAMIC_TAPPING_TERM_UP,
+ DT_DOWN = QK_DYNAMIC_TAPPING_TERM_DOWN,
CW_TOGG = QK_CAPS_WORD_TOGGLE,
AC_ON = QK_AUTOCORRECT_ON,
AC_OFF = QK_AUTOCORRECT_OFF,
@@ -1142,3 +1145,4 @@ enum qk_keycode_defines {
#define IS_BACKLIGHT_KEYCODE(code) ((code) >= BL_ON && (code) <= BL_BRTG)
#define IS_RGB_KEYCODE(code) ((code) >= RGB_TOG && (code) <= RGB_MODE_TWINKLE)
#define IS_QUANTUM_KEYCODE(code) ((code) >= QK_BOOTLOADER && (code) <= QK_AUTOCORRECT_TOGGLE)
+
diff --git a/quantum/process_keycode/process_dynamic_tapping_term.c b/quantum/process_keycode/process_dynamic_tapping_term.c
index b682f34da6..146b9fccd7 100644
--- a/quantum/process_keycode/process_dynamic_tapping_term.c
+++ b/quantum/process_keycode/process_dynamic_tapping_term.c
@@ -35,15 +35,15 @@ static void tapping_term_report(void) {
bool process_dynamic_tapping_term(uint16_t keycode, keyrecord_t *record) {
if (record->event.pressed) {
switch (keycode) {
- case DT_PRNT:
+ case QK_DYNAMIC_TAPPING_TERM_PRINT:
tapping_term_report();
return false;
- case DT_UP:
+ case QK_DYNAMIC_TAPPING_TERM_UP:
g_tapping_term += DYNAMIC_TAPPING_TERM_INCREMENT;
return false;
- case DT_DOWN:
+ case QK_DYNAMIC_TAPPING_TERM_DOWN:
g_tapping_term -= DYNAMIC_TAPPING_TERM_INCREMENT;
return false;
}