ZoomPanBehavior class Null safety

Customizes the zooming options.

Customize the various zooming actions such.toDouble()tapZooming, selectionZooming, zoomPinch. In selection you can long press and drag to select a range on the chart to be zoomed in and also zooming you can customize the selection rectangle using Borderwidth,color and RectColor.

zoomPinching can be performed by moving two fingers over the chartDefault mode is ZoomMode.xy. Zooming will be stopped after reaching maximumZoomLevel.

Note: This is only applicable for SfCartesianChart.


ZoomPanBehavior({bool enablePinching = false, bool enableDoubleTapZooming = false, bool enablePanning = false, bool enableSelectionZooming = false, bool enableMouseWheelZooming = false, ZoomMode zoomMode = ZoomMode.xy, double? maximumZoomLevel, double selectionRectBorderWidth = 1, Color? selectionRectBorderColor, Color? selectionRectColor})
Creating an argument constructor of ZoomPanBehavior class.


enableDoubleTapZooming bool
Enables or disables the double tap zooming. [...]
enableMouseWheelZooming bool
Enables or disables the mouseWheelZooming. [...]
enablePanning bool
Enables or disables the panning. [...]
enablePinching bool
Enables or disables the pinch zooming. [...]
enableSelectionZooming bool
Enables or disables the selection zooming. [...]
hashCode int
The hash code for this object. [...]
read-only, inherited
maximumZoomLevel double?
Maximum zoom level. [...]
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
selectionRectBorderColor Color?
Border color of the selection zooming rectangle. [...]
selectionRectBorderWidth double
Border width of the selection zooming rectangle. [...]
selectionRectColor Color?
Color of the selection zooming rectangle. [...]
zoomMode ZoomMode
By default, both the x and y-axes in the chart can be zoomed. [...]


noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
panToDirection(String direction) → void
Pans the plot area for given left, right, top, and bottom directions. [...]
reset() → void
Returns the plot area back to its original position after zooming.
toString() String
A string representation of this object. [...]
zoomByFactor(double zoomFactor) → void
Changes the zoom level using zoom factor. [...]
zoomByRect(Rect rect) → void
Zooms the chart for a given rectangle value. [...]
zoomIn() → void
Increases the magnification of the plot area.
zoomOut() → void
Decreases the magnification of the plot area.
zoomToSingleAxis(ChartAxis axis, double zoomPosition, double zoomFactor) → void
Change the zoom level of an appropriate axis. [...]


operator ==(Object other) bool
The equality operator. [...]