browser.window.get#
Functions#
height() #
Get the height of browser window on the screen in pixels.
Returns:
| Type | Description |
|---|---|
int | Height of browser window on the screen in pixels. |
Example
height = browser.window.get.height()
position() #
Get the X and Y coordinates of the top left corner of the browser window on the screen.
Returns:
| Type | Description |
|---|---|
tuple[int, int] | Coordinates of the top left corner of the browser window on the screen. |
Example
How to move the window relatively by getting the current position of the window and move it by 10 pixels in both axes, if possible:
| Python | |
|---|---|
1 2 3 4 5 6 | |
size() #
Get width and height of browser window on the screen in pixels.
Returns:
| Type | Description |
|---|---|
tuple[int, int] | Width and height of browser window on the screen in pixels. |
Example
width, height = browser.window.get.size()
width() #
Get the width of browser window on the screen in pixels.
Returns:
| Type | Description |
|---|---|
int | Width of browser window on the screen in pixels. |
Example
width = browser.window.get.width()