← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #294970]: addHotKey error

 

Question #294970 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/294970

    Status: Open => Answered

masuo proposed the following answer:
Use Key modifiers.
And use Env.addHotkey instead of Key.addHotkey 
http://sikulix-2014.readthedocs.io/en/latest/interaction.html?highlight=addHotkey

[example]
def myHandler(event):
    print "inside message"

Env.addHotkey(Key.F2,KeyModifier.SHIFT+KeyModifier.CTRL,myHandler)
wait(10)

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.