← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #236034]: NameError: global name 'Rectangle' is not defined

 

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

    Status: Open => Answered

RaiMan proposed the following answer:
Sorry, using Java in Jython is not my daily business ;-)

from java.awt import Rectangle

with Sikuli:
img1 = capture(region1)
img2 = capture(region2)

f = Finder(img1)
f.find(Pattern(img2).exact())

if (f.hasNext())
    print "equal"
else
   print "not equal"

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