GradientStop

sealed interface GradientStop(source)

A color at offset along a gradient.

Inheritors

Types

Link copied to clipboard
data class Fixed(val offset: Float, val color: Color) : GradientStop

A fixed color, drawn as given.

Link copied to clipboard
data class Series(val offset: Float, val alpha: Float) : GradientStop

The color the chart resolves for the shape, such as the bar's color, drawn at alpha. One gradient can then follow every color of a palette.

Properties

Link copied to clipboard
abstract val offset: Float

Where the color sits, from 0 at the gradient's start to 1 at its end.