sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #31634
[Question #264958]: Count number of same images that are horizontally parallel in the screen
New question #264958 on Sikuli:
https://answers.launchpad.net/sikuli/+question/264958
I would like to count the number of same images that are horizontally parallel in the screen and sort them so the foremost left is 0 (first) and the foremost right is -1 (last)
right know Im using this
count = 0
try:
matches = list(findAll(Pattern("1425879837185.png").exact()))
count = len(matches)
except FindFailed:
pass #nothing to do
print "found:", count
if count > 0:
sortedMatches = sorted(matches, key=lambda m:m.y) # sorts top to bottom
hover(sortedMatches[-1]) # take the last one
but don't know why it does not click in the lastone
Thanks advanced
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.