smile.colors.LinearGradient
See theLinearGradient companion object
case class LinearGradient(start: Pos, end: Pos, fractions: Seq[Float], colors: Seq[Color], cycleMethod: CycleMethod) extends Paint
Represents a linear gradient paint with two or more colors. The start and end points are specified in the local coordinate space of the shape.
Value parameters
- colors
-
A sequence of
Color
objects corresponding to each fraction in the gradient. - cycleMethod
-
The method used to repeat the gradient pattern if the shape to be filled is larger than the gradient defined by the start and end points.
- end
-
The ending position of the gradient.
- fractions
-
A sequence of float values in the range [0.0f, 1.0f] indicating the fractional distances along the gradient at which color changes occur.
- start
-
The starting position of the gradient.
Attributes
- Companion
- object
- Graph
-
- Supertypes
Members list
In this article