API Reference
adafruit_anchored_group
A displayio Group that supports placement by anchor_point and anchored_position properties
Author(s): Tim Cocks
Implementation Notes
Hardware:
Software and Dependencies:
Adafruit CircuitPython firmware for the supported boards: https://circuitpython.org/downloads
- class adafruit_anchored_group.AnchoredGroup(*args: Any, **kwargs: Any)
Displayio Group that supports having its positions set by anchor_point and anchored_position properties.
- property anchor_point
The anchor point. tuple containing x and y values ranging from 0.0 to 1.0.
- property anchored_position: Tuple[int, int]
Position relative to the anchor_point. Tuple containing x,y pixel coordinates.
- contains(point: tuple[int, int] | List[int] | List[Dict[str, int]]) bool
Used to determine if a point is contained within this AnchoredGroup. For example,
anchored_group.contains(touch)wheretouchis the touch point on the screen will allow for determining that the group has been touched.
- property height
The height of the Group in pixels, readonly.
:return int width in pixels
- property size
The width and height of the Group in pixels, readonly.
- Returns:
tuple (width, height)
- property width
The width of the Group in pixels, readonly.
- Returns:
int width in pixels