radialGradient static method
Creates a radial gradient with the specified colors and optional center, radius, stops, and tile mode parameters.
colors: A list of colors to be used in the radial gradient.
center: The center point of the gradient. Default is center (0.5, 0.5).
radius: The radius of the radial gradient. Default is 0.5.
stops: A list of positions for each color stop. Default is evenly distributed.
mode: The tile mode that defines how the gradient is repeated. Default is TileMode.clamp.
Returns a RadialGradient instance.
Implementation
static Gradient radialGradient(List<Color> colors,
{AlignmentGeometry? center,
double radius = 0.5,
List<double>? stops,
TileMode mode = TileMode.clamp}) {
return RadialGradient(
colors: colors,
center: center ?? const Alignment(0.5, 0.5),
radius: radius,
stops: stops,
tileMode: mode);
}