StrokeDrawScope


class StrokeDrawScope


A utility to simplify usage of CanvasStrokeRenderer by automatically calculating the strokeToCanvasTransform parameter of CanvasStrokeRenderer.draw. Obtain an instance of this class using androidx.ink.rendering.android.view.ViewStrokeRenderer, if using android.view.View. Use this scope by calling its drawStroke function.

Summary

Public functions

Unit
drawStroke(stroke: Stroke)

Draw the given Stroke to the Canvas represented by this scope.

Public functions

drawStroke

Added in 1.0.0-alpha01
fun drawStroke(stroke: Stroke): Unit

Draw the given Stroke to the Canvas represented by this scope.