CSSLinearGradient constructor
CSSLinearGradient({})
Creates a linear gradient.
The colors
argument must not be null. If stops
is non-null, it must
have the same length as colors
.
Implementation
CSSLinearGradient({
Alignment begin = Alignment.centerLeft,
Alignment end = Alignment.centerRight,
double? angle,
required List<Color> colors,
// A list of values from 0.0 to 1.0 that denote fractions along the gradient.
List<double>? stops,
TileMode tileMode = TileMode.clamp,
GradientTransform? transform,
}) : _angle = angle,
super(begin: begin, end: end, colors: colors, stops: stops, tileMode: tileMode, transform: transform);