public interface

WearArcLayout.ArcLayoutWidget

 androidx.wear.tiles.renderer.WearArcLayout.ArcLayoutWidget

Subclasses:

WearCurvedSpacer, WearCurvedLineView, WearCurvedTextView

Overview

Interface for a widget which knows it is being rendered inside an arc, and will draw itself accordingly. Any widget implementing this interface will receive the full-sized canvas, pre-rotated, in its draw call.

Summary

Methods
public voidcheckInvalidAttributeAsChild()

Check whether the widget contains invalid attributes as a child of WearArcLayout

public floatgetSweepAngleDegrees()

Returns the sweep angle that this widget is drawn with.

public intgetThicknessPx()

Returns the thickness of this widget inside the arc.

public booleaninsideClickArea(float x, float y)

Return true when the given point is in the clickable area of the child widget.

Methods

public float getSweepAngleDegrees()

Returns the sweep angle that this widget is drawn with.

public int getThicknessPx()

Returns the thickness of this widget inside the arc.

public void checkInvalidAttributeAsChild()

Check whether the widget contains invalid attributes as a child of WearArcLayout

public boolean insideClickArea(float x, float y)

Return true when the given point is in the clickable area of the child widget. In particular, the coordinates should be considered as if the child was drawn centered at the default angle (12 o clock).