Skype热键确实令人讨厌,因为无法从Skype本身禁用它们。最令人讨厌的是Ctrl+ R,它与您选择的任何联系人开始了Skype通话。这已经通过最近更换Ctrl+ Alt+ R。
请参阅http://community.skype.com/t5/Windows-desktop-client/Disable-CTRL-R-on-windows/td-p/2877763
不幸的是,发生在我身上的是AltGr+R作为“è”字符的映射键(使用Microsoft keybord创建器)。因此,在我所有的应用程序中,我都可以使用美式键盘愉快地用法语书写,并始终使用AltGr+r表示“è”字符。现在,除了Skype中。
阅读上面的链接,我创建了一个AutoKey脚本,以禁用Skype的热键:
#IfWinActive, ahk_exe Skype.exe ; utilizes this script for Skype only
!^r:: ; replace [ctrl][alt][r] with nothing
#If ; closes IfWinActive condition, needed if more code comes after this
但是,尽管这会禁用Skype热键,但会阻止在Skype讨论中正常输入“è”字符。很好,但不是最好,因为现在我的打字已在Skype中全部搞乱了。
我尝试了其他选择,但无济于事:
#IfWinActive, ahk_exe Skype.exe ; utilizes this script for Skype only
!^r::
Send è
return
#If ; closes IfWinActive condition, needed if more code comes after this
或者
#IfWinActive, ahk_exe Skype.exe ; utilizes this script for Skype only
!^r::
SendInput {Raw}è
return
#If ; closes IfWinActive condition, needed if more code comes after this
但是只要不严格禁用!^ r,它便会发起Skype呼叫。
任何对AutoHotKey和/或Skype有更多经验的人可以帮助我吗?
谢谢。
请注意
#IfWinActive, ...
!^r::
#If
没有有效停用热键:附加return
关键字,因此为!^r::return
。否则,在按alt ctrl r之后,还将执行下面进一步的任何代码。
另外,如果您只想重新映射AltGr热键,则应<^>!r::
按照文档中的建议将其用作触发器。这样,自然alt+ctrl+r
行为将得以保留,在这种情况下进行呼叫。
我无法完全重现您的问题。
#IfWinActive, ahk_exe Skype.exe
<^>!r::
send a
return
#ifWinActive
对我来说效果很好,并且在Skype中不会呼叫我的活动联系人。AltGr
被正确覆盖。但是,如果我更改send a
为send è
,脚本将开始奇怪地运行。它仅在第一次使用时有效:此后,我必须Alt手动按下一次才能è
再次发送。在我看来,这似乎是个虫子。
解决方法可能是
#IfWinActive, ahk_exe Skype.exe
<^>!r::
send è
keywait, alt
send {alt}
return
#ifWinActive
或者
#IfWinActive, ahk_exe Skype.exe
<^>!r::
keywait, alt
send è
return
#ifWinActive
。但这仍然无法è
在按住的同时发送多个altGr
。您必须AltGr
在每次之后释放è
。
编辑-我找到了100%有效的解决方案:
#IfWinActive, ahk_exe Skype.exe
<^>!r::
SendUnicodeChar(0x00E8)
return
#ifWinActive
; SOURCE for the following: http://www.autohotkey.com/board/topic/16404-inserting-unicode-special-characters/
SendUnicodeChar(charCode)
{
VarSetCapacity(ki, 28 * 2, 0)
EncodeInteger(&ki + 0, 1)
EncodeInteger(&ki + 6, charCode)
EncodeInteger(&ki + 8, 4)
EncodeInteger(&ki +28, 1)
EncodeInteger(&ki +34, charCode)
EncodeInteger(&ki +36, 4|2)
DllCall("SendInput", "UInt", 2, "UInt", &ki, "Int", 28)
}
EncodeInteger(ref, val)
{
DllCall("ntdll\RtlFillMemoryUlong", "Uint", ref, "Uint", 4, "Uint", val)
}
与上面相同,但不是使用send è
或send {ASC 0232}
,而是使用unicode格式。
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句