public interface DrawAnnotationScope : DrawScope
Receiver scope for DrawAnnotation callbacks that draws behind or over a character range in laid-out text.
Aligns the DrawScope coordinate space with the text layout origin and exposes the measured textLayoutResult along with the resolved `start, end) character offsets for the annotated range. Call [TextLayoutResult.getBoundingBoxesForRange or TextLayoutResult.fillPathForRange with start and end` to obtain per-line bounding boxes or contour paths.
Properties
textLayoutResult
public val textLayoutResult: TextLayoutResult
Measured TextLayoutResult for the text being drawn.
start
public val start: Int
Inclusive start character offset of the annotated range, clamped to the text length.
end
public val end: Int
Exclusive end character offset of the annotated range, clamped to `start, text.length`.