问题
How would you remap Ctrl+P to send Ctrl+↑ (Up) consistently?
Here is what I tried:
capslock::ctrl
^p::send {up}
While holding Ctrl this sends ↑ the first time,
but then P unless I release Ctrl and then press it again.
I found that it also happens with something like this:
OriginKey::DestinationKey
*DestinationKey & normalKey::maptoAnother
Without releasing the artificial modifier it keeps inserting normalKey
NOT maptoAnother
.
回答1:
Here is what I ended up using:
capslock::ctrl
^p::send ^{up}
{blind}
can also be used in this case, because it avoids releasing Ctrl
^p::send {blind}{up}
回答2:
It doesn't directly answer your question, but willwillis suggested XKeymacs for making Emacs-emulating key bindings in this question.
回答3:
Another option if you're using a program where ^Up != Up :
^p::SendPlay {Up}
I think you can also specify the mode for send once and use send after that :
SendMode Play
^p::Send {Up}
I think this is a better solution as you can directly send whatever key you want and are not forced to send ^ as with {Blind}.
来源:https://stackoverflow.com/questions/9560923/autohotkey-issue-after-mapping-capslockctrl