StarPainter constructor
const
StarPainter({})
Creates a star painter.
points is the number of points of the star (minimum 3).
outerRadius is the outer radius of the star in logical pixels.
innerRadius is the inner radius of the star in logical pixels.
color is the fill color of the star.
strokeWidth is the width of the star's border. If null, no border is drawn.
strokeColor is the color of the star's border.
rotation is the rotation angle in radians. Defaults to 0.
Implementation
const StarPainter({
required this.points,
required this.outerRadius,
required this.innerRadius,
required this.color,
this.strokeWidth,
this.strokeColor,
this.rotation = 0.0,
}) : assert(points >= 3, 'Star must have at least 3 points'),
assert(outerRadius > innerRadius,
'Outer radius must be greater than inner radius');