0

From this thread: Vertical Scroll down and scroll up in Selenium WebDriver with java

I understand that scroll(xpos, ypos) needs:

  • positive value - scroll down
  • negative value - scroll up

However, isn't it that in the Cartesian Plane, down is negative for y-axis? enter image description here

If anyone can clarify, that would be great. Thanks!

5
  • 2
    The browser lives on an inverted Cartesian plane. 0,0 is the top left corner ... because we read top to bottom, not bottom to top - in fact, in computer graphics, the Cartesian plane has been inverted in almost every application ever Commented Jan 24, 2018 at 3:53
  • Hi, does that mean giving a negative value to x scrolls to the right in an inverted Cartesian plane? Commented Jan 24, 2018 at 3:59
  • 2
    no, it's inverted, not rotated :p Commented Jan 24, 2018 at 4:00
  • Ah so the x-axis remains the same. If you could post a quick answer, I'd be glad to upvote and accept. :) Commented Jan 24, 2018 at 4:08
  • my comments are opinion, I have no facts to back them up :p Commented Jan 24, 2018 at 4:10

1 Answer 1

0

I think, I have found a highly relevant reading and also proof:

Why is the origin in computer graphics coordinates at the top left?

And since browsers display through a monitor, the same applies.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.