onZooming property Null safety

ChartZoomingCallback? onZooming
final

Occurs when Zoooming event is performed. Here, you can get the axis, current zoom factor, current zoom position, previous zoom factor, and previous zoom position.

Widget build(BuildContext context) {
   return Container(
       child: SfCartesianChart(
           zoomPanBehavior: ZoomPanBehavior(enableSelectionZooming: true),
           onZooming: (ZoomPanArgs args) => zoom(args),
       ));
}
void zoom(ZoomPanArgs args) {
   print(args.currentZoomPosition);
}

Implementation

final ChartZoomingCallback? onZooming;