Send existing modifiers with a key in autohotkey?
autohotkey
Solution
You can do this with the Send, {Blind} mode. Example:
*a::Send, {Blind}{Left}
The `*` accepts all modifiers for a and {Blind} passes the modifiers on to the `Send` command.
Alternatively, you can avoid Send and use:
a::Left
Here all modifiers are automatically passed on to the `Left` command.
Note: As far as I see after testing, neither solution will work with "your" combination keys, only with standard hotkeys.
So your initial solution might be the only one, unless you change the combination keys back to standard hotkeys.
Problem
I'm trying to send pressed modifiers with the Send command, only way I come up with is listing them all: ``` ; (Note: I've remapped using registry the Capslock as F13) F13 & h:: if GetKeyState("Control") && GetKeyState("Shift") { Send +^{Left} return } if GetKeyState("Control") { Send ^{Left} return } if GetKeyState("Shift") { Send +{Left} return } Send {Left} return ``` In Windows if you press ctrl+left it jumps a word left, if I press ctrl+shift+left it selects a word leftwise. Similarily I'd like to send the existing modifiers as in above example, but is there a simpler way? Pseudocode: `F13 & h::Send {CurrentlyPressedModifiers}{Left}`