displayMode property
Enables the markers in different modes.
- SparkChartMarkerDisplayMode.none does not allow to display a marker on any data points.
- SparkChartMarkerDisplayMode.all allows to display a marker on all the data points.
- SparkChartMarkerDisplayMode.high allows displaying marker only on the highest data points in the spark chart widget.
- SparkChartMarkerDisplayMode.low allows displaying marker only on the lowest data points
- SparkChartMarkerDisplayMode.first allows displaying marker only on the first data points.
- SparkChartMarkerDisplayMode.last allows displaying marker only on the last data points.
Defaults to SparkChartMarkerMode.none
.
@override
Widget build(BuildContext context) {
return Scaffold(
body: Center(
child: SfSparkAreaChart(
marker: SparkChartMarker(
size: 20, displayMode: SparkChartMarkerDisplayMode.all),
data: <double>[18, 24, 30, 14, 28],
)),
);
}
Implementation
final SparkChartMarkerDisplayMode displayMode;