TexturedLinePainter class

Draws a polyline to a Canvas from a list of points using the provided SpriteTexture.

Constructors

TexturedLinePainter(List<Offset> _points, List<Color> colors, List<double> widths, SpriteTexture texture, List<double>? textureStops)
Creates a painter that draws a polyline with a texture.

Properties

calculatedTextureStops List<double>
The textureStops used if no explicit texture stops has been provided.
no setter
colors List<Color>
The color of each point on the polyline. The color of the line will be interpolated between the points.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
length double?
The length of the line.
no setter
points List<Offset>
The points that makes up the polyline.
getter/setter pair
removeArtifacts bool
If true, the textured line attempts to remove artifacts at sharp corners on the polyline.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
texture SpriteTexture
The texture this line will be drawn using.
getter/setter pair
textureLoopLength double?
The length, in points, that the texture is stretched to. If the textureLoopLength is shorter than the line, the texture will be looped.
getter/setter pair
textureStopOffset double
The offset of the texture on the line.
getter/setter pair
textureStops List<double>?
Defines the position in the texture for each point on the polyline.
getter/setter pair
transferMode BlendMode
The TransferMode used to draw the line to the Canvas.
getter/setter pair
widths List<double>
The width of the line at each point on the polyline.
getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
paint(Canvas canvas) → void
Paints the line to the canvas.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited