Tuesday, March 24, 2009

Python mouse move in 5 lines of code (Linux only)

from Xlib import X, display
d = display.Display()
s = d.screen()
root = s.root
root.warp_pointer(300,300)
d.sync()