Point
Points in Android Macro are fundamental building blocks used to specify screen coordinates and gesture parameters. There are two types of points available: basic Points and SwipePoints.
Types of Points
1. Basic Point
A basic Point represents a single location on the screen using x and y coordinates.
Parameters:
- x: The horizontal coordinate (pixels from left)
- y: The vertical coordinate (pixels from top)
Basic Points are commonly used with click operations:
2. SwipePoint
A SwipePoint extends the basic Point with additional parameters for gesture control.
Parameters:
- x: The horizontal coordinate (pixels from left)
- y: The vertical coordinate (pixels from top)
- holdDuration: How long to hold before starting the swipe (milliseconds)
- swipeDuration: How long the swipe motion should take (milliseconds)
SwipePoints are used in pairs to define swipe gestures:
Tips for Using Points
- Use screen coordinates that are appropriate for your device's resolution
- For swipes, ensure the holdDuration and swipeDuration are long enough to be recognized
- Test points with different coordinate values to ensure reliability
- Consider using variables to store frequently used points
- Remember that (0,0) is at the top-left corner of the screen