CartesianChartAnnotation class

This class has the properties of cartesian chart annotation.

Chart supports annotations that allow you to mark the specific area of interest in the chart area. You can add the custom widgets using this annotation feature as depicted below.

The x and y values can be specified with axis units or pixel units, and these can be identified by using coordinateUnit property. When the logical pixel is specified, the annotation will be placed to pixel values whereas the point is specified, then the annotation will be placed to series point values.

Provides the options x, y, coordinateUnit, and widget to customize the cartesian chart annotation.

Annotations

Constructors

CartesianChartAnnotation({Widget? widget, CoordinateUnit coordinateUnit = CoordinateUnit.logicalPixel, AnnotationRegion region = AnnotationRegion.chart, ChartAlignment horizontalAlignment = ChartAlignment.center, ChartAlignment verticalAlignment = ChartAlignment.center, dynamic x = 0, dynamic y = 0, String? xAxisName, String? yAxisName})
Creating an argument constructor of CartesianChartAnnotation class.
const

Properties

coordinateUnit CoordinateUnit
Specifies the coordinate units for placing the annotation in either logicalPixel or point.
final
hashCode int
The hash code for this object.
no setteroverride
horizontalAlignment ChartAlignment
Aligns the annotations horizontally.
final
region AnnotationRegion
Annotations can be placed with respect to either plotArea or chart.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
verticalAlignment ChartAlignment
Aligns the annotations vertically.
final
widget Widget?
Considers any widget as annotation.
final
x → dynamic
Specifies the x-values as pixel, point or percentage values based on the coordinateUnit.
final
xAxisName String?
Specifies the x-axis name to the annotation that should be bound.
final
y → dynamic
Specifies the y-values as pixel, point or percentage values based on the coordinateUnit.
final
yAxisName String?
Specifies the y-axis name to the annotation that should be bound.
final

Methods

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.
override