Skip to main content

rotate

This tool on every surface: CLI · MCP · Python · JavaScript · Go · Java · .NET

Turn two fingers about an element or the middle of the screen. These call app_rotate.

rotate​

public void rotate(double degrees, String target)

Turns two fingers about an element or the screen, positive clockwise. Pass an empty target for the middle of the screen.

Reports that the gesture was delivered and nothing more, and this one is harder still to confirm than a zoom: nothing in either hierarchy reports a rotation, and there is no WebView property to ask either.

@param degrees how far to turn, in degrees, positive clockwise @param target what to turn about: a ref or a locator, or empty for the middle of the screen

Examples​

Turn a map a quarter turn clockwise​

device.rotate(90, "@e2");

On a device​

BeforeAfter
Before: mobium rotate 90 on an Android 15 emulatorAfter: mobium rotate 90 on an Android 15 emulator

mobium rotate 90 on an Android 15 emulator