Code: Select all
^ö::Send Hello world!
How can this be turned off? #Warn has no option for that.Note: The hotkey ^ö will not be active because it does not exist in the current keyboard layout.
Code: Select all
^ö::Send Hello world!
How can this be turned off? #Warn has no option for that.Note: The hotkey ^ö will not be active because it does not exist in the current keyboard layout.
Code: Select all
If GetKeyVK("ö")
Hotkey, ^ö, LabelA
If GetKeyVK("o")
Hotkey, ^o, LabelB
return
LabelA:
MsgBox Activated ö.
return
LabelB:
MsgBox Activated o.
return
Code: Select all
sc10::MsgBox ; sc10 is a
Code: Select all
Hotkey, ^ö, test, On UseErrorLevel
; if (ErrorLevel <> 2) ; ErrorLevel is set to 2 if "The KeyName parameter specifies one or more keys that are either not recognized or not supported by the current keyboard layout/language."
; MsgBox, 16,, ERROR
return
test:
MsgBox % A_ThisLabel
return
Code: Select all
SetKeyDelay -1
remaps := {base:{__Get:Func("default_get")}
, o:{destinationKey:"z", onDown:Func("callback_Down"), onUp:Func("callback_Up")}
, ö:{destinationKey:"z"}}
for variant, object in remaps {
If GetKeyVK(variant) {
f := Func("fDown").bind(object.destinationKey, object.onDown)
Hotkey, % "*" . variant, % f
f := Func("fUp").bind(object.destinationKey, object.onUp)
Hotkey, % "*" . variant . " Up", % f
}
}
return
fDown(__destinationKey, __onDown) {
Send {Blind}{%__destinationKey% DownTemp}
__onDown.call()
}
fUp(__destinationKey, __onUp) {
Send {Blind}{%__destinationKey% Up}
__onUp.call()
}
callback_Down() {
ToolTip % A_ThisFunc . A_Space . A_ThisHotkey
}
callback_Up() {
ToolTip % A_ThisFunc . A_Space . A_ThisHotkey
}
default_get() {
return Func("dummy")
}
dummy() {
return true
}
I don't understand, you'll always need to specify an origin key to define create a hotkey.Micromegas wrote:I will still need the individual OriginKey:: entries for each
I didn't: as I said I simply quoted the documentation wich states that a script containing a::b actually contains two subroutines for the down and up events, respectively.Micromegas wrote:It's interesting that you split up the functionality into the up and down events.
Unfortunatly, I cannot even reproduce this behavior since I cannot switch keyboard locale in my machina... For example, in order to write let's say μΩς I must use a site like Lexilogos...Micromegas wrote:Does that give you tighter control over the erratic behavior of some keys, which I mentioned at Remapped hotkeys behave strange in other locales, where they keys don't behave as one would expect from the documentation?
Don't worry, there's not much to understand. I simply had at first assumed that your code was complete, and only later realized that the :: entries were missing.A_AhkUser wrote:I don't understand, you'll always need to specify an origin key to define create a hotkey.
Users browsing this forum: todd and 147 guests