Get the window's position and size. Returns: x, y coordinates and height and width of the current window. Example: `driver.get_window_rect()`
(self)
| 1176 | ) |
| 1177 | |
| 1178 | def get_window_rect(self) -> dict: |
| 1179 | """Get the window's position and size. |
| 1180 | |
| 1181 | Returns: |
| 1182 | x, y coordinates and height and width of the current window. |
| 1183 | |
| 1184 | Example: |
| 1185 | `driver.get_window_rect()` |
| 1186 | """ |
| 1187 | return self.execute(Command.GET_WINDOW_RECT)["value"] |
| 1188 | |
| 1189 | def set_window_rect(self, x=None, y=None, width=None, height=None) -> dict: |
| 1190 | """Set the window's position and size. |