Question #184255 on Sikuli changed: https://answers.launchpad.net/sikuli/+question/184255
dinev proposed the following answer: Below is some sample code to draw rectangle and triangle in paint Hope this help. -------------------------------------------------------------------- start_point= "start_point.png" def drawRect(): mLoc=Env.getMouseLocation().offset(100,100) mouseMove(mLoc) mouseDown(Button.LEFT) mouseMove(mLoc.offset(200,0)) mouseMove(mLoc.offset(200,100)) mouseMove(mLoc.offset(0,100)) mouseMove(mLoc.offset(0,0)) mouseUp() def drawTriang(): mLoc=Env.getMouseLocation().offset(300,300) mouseMove(mLoc) mouseDown(Button.LEFT) mouseMove(mLoc.offset(200,0)) mouseMove(mLoc.offset(100,100)) mouseMove(mLoc.offset(0,0)) mouseUp() sleep(1) switchApp("Paint") mouseMove(start_point) drawTriang() mouseMove(start_point) drawRect() -- You received this question notification because you are a member of Sikuli Drivers, which is an answer contact for Sikuli. _______________________________________________ Mailing list: https://launchpad.net/~sikuli-driver Post to : sikuli-driver@lists.launchpad.net Unsubscribe : https://launchpad.net/~sikuli-driver More help : https://help.launchpad.net/ListHelp