← Back to team overview

sikuli-driver team mailing list archive

[Question #678493]: How to take equal size screenshot

 

New question #678493 on Sikuli:
https://answers.launchpad.net/sikuli/+question/678493

Hi,

I want to know how i can take screenshots of equal size , because i am trying to write some scripts to automate and i want to verify whether the button is enabled or disabled. I tried to take screenshot of disabled button two times, and when i compared  both of them using below code:

img1="path of img1"
img2="path of img2"

f=Finder(img1)
f.find(img2)
if f.hasNext():
  print ("similar")
else:
  print("not similar")

i got result as "not similar", but images are same, the problem is i am unable to take both screenshots of same size, slight difference is making the result false.

Thank you in advance

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.