VerticalLine class

Holds data for drawing extra vertical lines.

LineChart draws some VerticalLine (set by LineChartData.extraLinesData), in below or above of everything, it draws from bottom to top side of the chart.

Inheritance

Constructors

VerticalLine({required double x, VerticalLineLabel? label, Color? color, Gradient? gradient, double strokeWidth = 2, List<int>? dashArray, Image? image, SizedPicture? sizedPicture, StrokeCap strokeCap = StrokeCap.butt})
LineChart draws vertical lines from bottom to top side of the chart in the provided x value, and color it using color. You can define the thickness using strokeWidth

Properties

color Color?
Defines color of the line.
finalinherited
dashArray List<int>?
Defines dash effect of the line.
finalinherited
gradient Gradient?
Defines the gradient of the line.
finalinherited
hashCode int
The hash code for this object.
no setterinherited
image Image?
Use it for any kind of image, to draw it in bottom side of the chart.
getter/setter pair
label VerticalLineLabel
Draws a text label over the line.
final
props List<Object?>
Used for equality check, see EquatableMixin.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sizedPicture SizedPicture?
Use it for vector images, to draw it in bottom side of the chart.
getter/setter pair
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited
strokeCap StrokeCap
if not drawing dash line, then this is the Strokecap for the line. i.e. if the two ends of the line is round or butt or square.
final
strokeWidth double
Defines thickness of the line.
finalinherited
x double
Draws from bottom to top of the chart using the x value.
final

Methods

copyVerticalLineWith({double? x, VerticalLineLabel? label, Color? color, double? strokeWidth, List<int>? dashArray, Image? image, SizedPicture? sizedPicture, StrokeCap? strokeCap}) VerticalLine
Copies current VerticalLine to a new VerticalLine and replaces provided values.
copyWith({Color? color, Gradient? gradient, double? strokeWidth, List<int>? dashArray}) FlLine
Copies current FlLine to a new FlLine, and replaces provided values.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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

Static Methods

lerp(VerticalLine a, VerticalLine b, double t) VerticalLine
Lerps a VerticalLine based on t value, check Tween.lerp.
override