← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #200106]: selecting the next image in line

 

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

    Status: Open => Answered

RaiMan proposed the following answer:
I understand, that there are some images in a row with some regular distribution and size (thumbnails ?).
You want to click on each one and do some action.

If this is true, the you have to
- position on the first image somehow
- in a loop:
  - do your actions
  - position on the next image somehow

e.g. supposing you have 
- 10 images
- each image is width 100
- the distance between 2 images is 20

firstImage = find("something.png")
nextImage = firstImage
for i in range(10):
    click(nextImage)
    # your actions
    nextImage = nextImage.offset(Location(120,0))

hope it helps ;-)

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