Question #267039 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/267039
Status: Open => Answered
RaiMan proposed the following answer:
works on Windows and Mac.
for Mac
--1: create an App object:
myApp = App("Safari")
--2: make sure it is running with some frontmost window
myApp.open()
... and make sure, the window is visible
since with App.open() not always the window information is already
available:
myApp.focus() # to refresh the title info in doubt
print myApp.getWindow() # should now print the window
-- for debugging purposes:
print myApp
gives you something like
[10498:Safari (Question #267039 : Questions : Sikuli)] Safari
which is
[nPID:executableName (main/frontmost window title)] given text
see:
http://sikulix-2014.readthedocs.org/en/latest/appclass.html#the-application-class-app
the chapter: How to create an App instance
Sorry, more is not yet documented yet ;-)
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 : [email protected]
Unsubscribe : https://launchpad.net/~sikuli-driver
More help : https://help.launchpad.net/ListHelp