单击Lalt输出空格,按住不放为LControl,参考网络上的代码如下:
Code: Select all
Lalt::
Send {LControl Down}
KeyWait, Lalt
Send {LControl Up}
If ( A_PriorKey = "Lalt")
{
Send {SPC}
}
return
Moderators: tmplinshi, arcticir
Code: Select all
Lalt::
Send {LControl Down}
KeyWait, Lalt
Send {LControl Up}
If ( A_PriorKey = "Lalt")
{
Send {SPC}
}
return
Code: Select all
; 单击 LAlt 输出空格,按住不放为 LControl
LAlt::
KeyWait, LAlt, T0.3 ; 等待 LAlt 松开, 等待时间 0.3 秒
if ErrorLevel { ; 超时
LAlt::LControl
} else {
Send {Space}
}
Return
Code: Select all
^r::MsgBox Ctrl + r
^!r::MsgBox Alt + Ctrl + r
Lalt::
Send {LControl Down}
KeyWait, Lalt
Send {LControl Up}
If (A_TimeSinceThisHotkey < 300)
{
Send {Space}
}
return
再请教一个问题,根据如上代码,我在使用过程当中发现一个奇怪现象tmplinshi wrote: ↑11 Sep 2020, 03:29Code: Select all
; 单击 LAlt 输出空格,按住不放为 LControl LAlt:: KeyWait, LAlt, T0.3 ; 等待 LAlt 松开, 等待时间 0.3 秒 if ErrorLevel { ; 超时 LAlt::LControl } else { Send {Space} } Return
Users browsing this forum: No registered users and 14 guests