LineStyle

data class LineStyle(    val brush: Brush? = null,     val arrowHeadType: ArrowHeadType? = null,     val width: Dp = Dp.Unspecified,     val miter: Dp = Dp.Unspecified,     val cap: StrokeCap? = null,     val join: StrokeJoin? = null,     val dashIntervals: Pair<Dp, Dp>? = null)

Properties that control how lines and arrows are rendered.

Parameters

brush

The Brush used to draw lines and arrows.

arrowHeadType

The ArrowHeadType of arrows, when appropriate.

width

The width of the stroke, in Dp. See Stroke.width.

miter

The miter of the stroke, in Dp. See Stroke.miter.

cap

The cap of the stroke. See Stroke.cap.

join

The join of the stroke. See Stroke.join.

dashIntervals

If non-null, lines will be drawn as dashed lines, with the first element of the pair Dp on, and the second element off. E.g. 10.dp to 10.dp is equivalent to dashedPathEffect(floatArrayOf(10.dp.toPx(), 10.dp.toPx())).

Constructors

Link copied to clipboard
fun LineStyle(    brush: Brush? = null,     arrowHeadType: ArrowHeadType? = null,     width: Dp = Dp.Unspecified,     miter: Dp = Dp.Unspecified,     cap: StrokeCap? = null,     join: StrokeJoin? = null,     dashIntervals: Pair<Dp, Dp>? = null)

Functions

Link copied to clipboard
fun fillMissingFrom(other: LineStyle?): LineStyle

Returns a LineStyle that is a copy of this instance, with any unspecified properties set from their corresponding properties in other.

Properties

Link copied to clipboard
val arrowHeadType: ArrowHeadType? = null
Link copied to clipboard
val brush: Brush? = null
Link copied to clipboard
val cap: StrokeCap? = null
Link copied to clipboard
val dashIntervals: Pair<Dp, Dp>? = null
Link copied to clipboard
val join: StrokeJoin? = null
Link copied to clipboard
val miter: Dp
Link copied to clipboard
val width: Dp

Sources

Link copied to clipboard