[Sikuli-driver] [Question #706503]: Помогите написать скрипт

2023-05-03 Thread Елена
New question #706503 on SikuliX:
https://answers.launchpad.net/sikuli/+question/706503

Помогите написать скрипт. На странице есть много фото. Некоторые из них 
повторяются. Их нужно найти и кликнуть по ним. Скрипт не должен останавливаться 
при прокрутке страницы вниз. Остановка скрипта возможна только когда страница 
будет полностью мной прокручена до конца. 
https://drive.google.com/file/d/1xYlUo1XyiesHYZc_eFUVc8rEBdXH_isn/view?usp=sharing

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #706490]: Easy way to take a screenshot and region at the same time (2)

2023-05-03 Thread Mi Me
Question #706490 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/706490

Description changed to:
Hi,
this one was asked before (and answered) 
(https://answers.launchpad.net/sikuli/+question/670985)
but the answer didn't solve my problem:

In Sikulix IDE I can do:
1. take a screenshot without region information or
2. take a region but without a screenshot.

If I do one after another, they most likely aren't pixel perfect.

I would like to take a "screenshot+region" in 1 step, so I could use it
later as:

if region1.exists(image1,0):
click(region1.getLastMatch())
elif region2.exists(image2,0):
click(region2.getLastMatch())

The reason I want to do this is to speed up the find operations.
In my application the images I want to click are always at the same exact 
locations, so I thought if the image matches the region perfectly, the find 
operation should be fastest.

Each image has its own location.
There can be images with the same location.
There can be images which I don't want to click (ignore).

Is there an easy way to do this, or maybe a different approach?

(Edit:)
My current (long) approach is:
1. take a region
2. helper script for saving a screenshot of that region to a file
3. Insert image into main script
4. copy region from helper script to main script

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #706490]: Easy way to take a screenshot and region at the same time (2)

2023-05-03 Thread Mi Me
Question #706490 on SikuliX changed:
https://answers.launchpad.net/sikuli/+question/706490

Description changed to:
Hi,
this one was asked before (and answered) 
(https://answers.launchpad.net/sikuli/+question/670985)
but the answer didn't solve my problem:

In Sikulix IDE I can do:
1. take a screenshot without region information or
2. take a region but without a screenshot.

If I do one after another, they most likely aren't pixel perfect.

I would like to take a "screenshot+region" in 1 step, so I could use it
later as:

if region1.exists(image1,0):
click(region1.getLastMatch())
elif region2.exists(image2,0):
click(region2.getLastMatch())

The reason I want to do this is to speed up the find operations.
In my application the images I want to click are always at the same exact 
locations, so I thought if the image matches the region perfectly, the find 
operation should be fastest.

Each image has its own location.
There can be images with the same location.
There can be images which I don't want to click (ignore).

Is there an easy way to do this, or maybe a different approach?

(Edit:)
My current (long) approach is:
1. take a region
2. script1 for saving a screenshot of that region to a file
3. Insert image into script2
4. copy region from script1 to script2

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Question #706495]: error import

2023-05-03 Thread SHIH-JIE HSU
New question #706495 on SikuliX:
https://answers.launchpad.net/sikuli/+question/706495

When I use the Sikuli-2.0.5(WIN10),
I have the .py want to import.
But he always have the error situation , when i import the py.

 java.lang.IllegalArgumentException ( java.lang.IllegalArgumentException: 
!!WHILE IMPORTING!! java.lang.IllegalArgumentException: Cannot create PyString 
with non-byte value

How can I solve this situation?
I try to put two py in the same folder, but it doesn't work.

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp