← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #235440]: Region() example help

 

Question #235440 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/235440

RaiMan proposed the following answer:
One more thing:

region definitions like:
reg = Region(131,154,512,415)

only make sense, if the region will be there in all cases and for
testing.

One should try to define regions relative to some fixed visuals , that
are found on the screen, as soon as possible in script development.

example on this page:
--- I want to restrict to the region in the top right (the framed boxes)
top = find(<image of the box: ask a question ...>)
reg = top.below()

this will always restrict to the boxes area, no matter where on the
screen it is currently.

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.