alignment property
Alignment of the data label.
The data label can be aligned far, near, or center of the data point position.
Defaults to ChartAlignment.center
.
Also refer ChartAlignment.
Widget build(BuildContext context) {
return Container(
child: SfCartesianChart(
series: <SplineSeries<SalesData, num>>[
SplineSeries<SalesData, num>(
dataLabelSettings: DataLabelSettings(isVisible: true, alignment: ChartAlignment.center),
),
],
));
}
Implementation
final ChartAlignment alignment;