How to emulate mouse wheel

Asked by Gregor Kopka

I am looking for a way to simulate turning of the mousewheel from within sikuli.

Anyone with a hint how to do this?

Question information

Language:
English Edit question
Status:
Solved
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Solved by:
Tsung-Hsiang Chang
Solved:
Last query:
Last reply:
Revision history for this message
Best Tsung-Hsiang Chang (vgod) said :
#1

No official support of emulating a mouse wheel yet. I have added this into the wish list.

A workaround is to use Java robot directly. Try the following example.

from java.awt import Robot
robot = Robot()
robot.mouseWheel(100) # scroll the mouse wheel

Revision history for this message
Gregor Kopka (mailfrom-launchpad-net) said :
#2

Thanks Tsung-Hsiang Chang, that solved my question.