aboutsummaryrefslogtreecommitdiffstats
path: root/docs/feature_macros.md
diff options
context:
space:
mode:
authorfauxpark <fauxpark@gmail.com>2019-11-26 18:16:58 +1100
committerDrashna Jaelre <drashna@live.com>2019-11-25 23:16:58 -0800
commit5a6737a778cfa828e4fdb5d382a84a41e5210d8e (patch)
tree0c746428a46df925b30675990aca209f59db2d9d /docs/feature_macros.md
parenta2cedf4555ab417d849cbacf9562fd92407d5d71 (diff)
downloadfirmware-5a6737a778cfa828e4fdb5d382a84a41e5210d8e.tar.gz
firmware-5a6737a778cfa828e4fdb5d382a84a41e5210d8e.tar.bz2
firmware-5a6737a778cfa828e4fdb5d382a84a41e5210d8e.zip
Send string keycode tweaks (#7471)
Diffstat (limited to 'docs/feature_macros.md')
-rw-r--r--docs/feature_macros.md19
1 files changed, 11 insertions, 8 deletions
diff --git a/docs/feature_macros.md b/docs/feature_macros.md
index d81c3c655..c13ae8206 100644
--- a/docs/feature_macros.md
+++ b/docs/feature_macros.md
@@ -67,14 +67,14 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
case QMKURL:
if (record->event.pressed) {
// when keycode QMKURL is pressed
- SEND_STRING("https://qmk.fm/" SS_TAP(X_ENTER));
+ SEND_STRING("https://qmk.fm/\n");
} else {
// when keycode QMKURL is released
}
break;
case MY_OTHER_MACRO:
if (record->event.pressed) {
- SEND_STRING(SS_LCTRL("ac")); // selects all and copies
+ SEND_STRING(SS_LCTL("ac")); // selects all and copies
}
break;
}
@@ -109,18 +109,21 @@ Which would send "VE" followed by a `KC_HOME` tap, and "LO" (spelling "LOVE" if
There's also a couple of mod shortcuts you can use:
-* `SS_LCTRL(string)`
-* `SS_LGUI(string)`
-* `SS_LALT(string)`
+* `SS_LCTL(string)`
* `SS_LSFT(string)`
-* `SS_RALT(string)`
+* `SS_LALT(string)`
+* `SS_LGUI(string)`, `SS_LCMD(string)` or `SS_LWIN(string)`
+* `SS_RCTL(string)`
+* `SS_RSFT(string)`
+* `SS_RALT(string)` or `SS_ALGR(string)`
+* `SS_RGUI(string)`, `SS_RCMD(string)` or `SS_RWIN(string)`
These press the respective modifier, send the supplied string and then release the modifier.
They can be used like this:
- SEND_STRING(SS_LCTRL("a"));
+ SEND_STRING(SS_LCTL("a"));
-Which would send LCTRL+a (LCTRL down, a, LCTRL up) - notice that they take strings (eg `"k"`), and not the `X_K` keycodes.
+Which would send Left Control+`a` (Left Control down, `a`, Left Control up) - notice that they take strings (eg `"k"`), and not the `X_K` keycodes.
### Alternative Keymaps