Location: outside any screen error although window well within the screen

Asked by Shekhar

I am repeatedly getting Location: outside any screen error although the location in question well within the screen.

To test what exactly is happening, i checked whether sikuli detected my extra monitor and what it figures its bounds to be:-
print(getNumberScreens())
print(Screen(1).getBounds())

Got the following output:-
2 # IDE detects 2 monitors - one laptop and one external - which is correct
java.awt.Rectangle[x=-271,y=-1080,width=1920,height=1080] #IDE detects the dimensions of my external monitor correctly

However, when i try make it perform an action in the region where i was having this trouble with the following line:-
l = Location(1496,705)
hover(l)

It throws the error - [error] Location: outside any screen (1496, 705) - subsequent actions might not work as expected

Why is it finding location (1496, 705) outside any screen? It is well within the bounds of the S1 that it detected in the previous line.

Question information

Language:
English Edit question
Status:
Answered
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
RaiMan (raimund-hocke) said :
#1

should work with SikuliX version 1.1.1

Can you help with this problem?

Provide an answer of your own, or ask Shekhar for more information if necessary.

To post a message you must log in.