问题
I am new to Sikuli. I need to do Ctrl+Shift+Down in Sikuli.
I have tried:
type(Key.DOWN, KeyModifier.SHIFT + KeyModifier.CTRL) and type(Key.DOWN, KeyModifier.SHIFT|KeyModifier.CTRL)
but none of them works.Both produce the same effect as pressing Ctrl+Down.
Please help.
回答1:
Due to some bug, Shift combinations do not work if NumLock is on. The solution I used was to toggle it using:
type(Key.NUM_LOCK)
I found the answer here: https://answers.launchpad.net/sikuli/+question/272223
回答2:
How about this:
# Push down keys.
keyDown(Key.CTRL)
keyDown(Key.SHIFT)
type(Key.DOWN)
# Release keys.
keyUp()
回答3:
Try this:
type(Key.DOWN, KeyModifier.SHIFT, KeyModifier.CTRL)
Pay attention that i only use "," not "+".
来源:https://stackoverflow.com/questions/39951920/keymodifier-shift-not-working-in-sikuli