XYDiagram2D.CanZoomIn() Method

Checks whether it is possible to zoom in to a diagram.

Namespace: DevExpress.Xpf.Charts

Assembly: DevExpress.Xpf.Charts.v20.1.dll

Declaration

public bool CanZoomIn()
Public Function CanZoomIn As Boolean

Returns

Type Description
Boolean

true if it is allowed to zoom in; otherwise, false.

Remarks

The following code changes the cursor's appearance when the chart is displayed at the maximum zoom level:

private void chartControl1_QueryChartCursor(object sender, QueryChartCursorEventArgs e) {
    ChartControl chart = (ChartControl)sender;
        XYDiagram2D diagram = (XYDiagram2D)chart.Diagram;
            if (!diagram.CanZoomIn()) {
                e.Cursor = Cursors.None;
                e.CursorImage = new BitmapImage(new Uri(@"/CustomCursor;component/mycursor.png", UriKind.Relative));
    }
}

To zoom in to a diagram, use the XYDiagram2D.ZoomIn method.

See Also