Xamarin.Forms

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class SFChartZoomPanBehavior

    Show / Hide Table of Contents

    Class SFChartZoomPanBehavior

    This class is used to enable zooming feature in SFChart. An instance of this class need to be added to Behaviors collection.

    Inheritance
    System.Object
    SFChartBehavior
    SFChartZoomPanBehavior
    ChartZoomPanBehaviorHelper
    Inherited Members
    SFChartBehavior.MouseMoved(CGPoint, NSEvent)
    SFChartBehavior.MouseEntered(CGPoint, NSEvent)
    SFChartBehavior.Chart
    SFChartBehavior.AdornmentLayer
    Namespace: Syncfusion.MacOS.Charts.SfChart
    Assembly: Syncfusion.SfChart.XForms.macOS.dll
    Syntax
    public class SFChartZoomPanBehavior : SFChartBehavior

    Constructors

    SFChartZoomPanBehavior()

    Declaration
    public SFChartZoomPanBehavior()

    Properties

    EnableDirectionalZooming

    Gets or sets a value indicating whether directional zooming is enabled.

    Declaration
    public bool EnableDirectionalZooming { get; set; }
    Property Value
    Type Description
    System.Boolean
    Remarks

    If this property is false, zooming is performed based on ZoomMode property. If this property is true, zooming is performed based on pinch direction of the user. This property having effect only with ZoomMode value as XY. This property does not expose in MacOS platform.

    EnableDoubleTap

    Gets or sets the value that indicates whether to zoom the chart on double tap.

    Declaration
    public bool EnableDoubleTap { get; set; }
    Property Value
    Type Description
    System.Boolean

    EnablePanning

    Gets or sets the value that indicates whether to allow panning in the chart, when it is in zoomed state.

    Declaration
    public bool EnablePanning { get; set; }
    Property Value
    Type Description
    System.Boolean

    EnableSelectionZooming

    Gets or sets the value that indicates whether box selection zooming is enabled.

    Declaration
    public bool EnableSelectionZooming { get; set; }
    Property Value
    Type Description
    System.Boolean

    EnableZooming

    Gets or sets the value that indicates whether to allow zooming in chart.

    Declaration
    public bool EnableZooming { get; set; }
    Property Value
    Type Description
    System.Boolean

    MaximumZoomLevel

    Gets or sets the value that determines the maximum zoom level of the chart.

    Declaration
    public double MaximumZoomLevel { get; set; }
    Property Value
    Type Description
    System.Double

    SelectionRectBorderColor

    Gets or sets the border color of the selection rectangle.

    Declaration
    public NSColor SelectionRectBorderColor { get; set; }
    Property Value
    Type Description
    AppKit.NSColor

    SelectionRectBorderDashes

    Gets or sets the dash array for the border of the selection rectangle.

    Declaration
    public NSArray SelectionRectBorderDashes { get; set; }
    Property Value
    Type Description
    Foundation.NSArray

    SelectionRectBorderWidth

    Gets or sets the border width of the selection rectangle.

    Declaration
    public double SelectionRectBorderWidth { get; set; }
    Property Value
    Type Description
    System.Double

    SelectionRectFillColor

    Gets or sets the fill color of the selection rectangle.

    Declaration
    public NSColor SelectionRectFillColor { get; set; }
    Property Value
    Type Description
    AppKit.NSColor

    ZoomMode

    Gets or sets the mode that indicates whether to zooming can be carried out in X, Y and XY axis.

    Declaration
    public SFChartZoomMode ZoomMode { get; set; }
    Property Value
    Type Description
    SFChartZoomMode

    Methods

    Dispose(Boolean)

    Declaration
    protected override void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing

    DrawInContext(CGContext)

    Declaration
    public override void DrawInContext(CGContext context)
    Parameters
    Type Name Description
    CoreGraphics.CGContext context
    Overrides
    SFChartBehavior.DrawInContext(CGContext)

    MouseDown(CGPoint, NSEvent)

    Declaration
    protected override void MouseDown(CGPoint locationInChart, NSEvent theEvent)
    Parameters
    Type Name Description
    CoreGraphics.CGPoint locationInChart
    AppKit.NSEvent theEvent
    Overrides
    SFChartBehavior.MouseDown(CGPoint, NSEvent)

    MouseDragged(CGPoint, NSEvent)

    Declaration
    protected override void MouseDragged(CGPoint locationInChart, NSEvent theEvent)
    Parameters
    Type Name Description
    CoreGraphics.CGPoint locationInChart
    AppKit.NSEvent theEvent
    Overrides
    SFChartBehavior.MouseDragged(CGPoint, NSEvent)

    MouseExited(CGPoint, NSEvent)

    Declaration
    protected override void MouseExited(CGPoint locationInChart, NSEvent theEvent)
    Parameters
    Type Name Description
    CoreGraphics.CGPoint locationInChart
    AppKit.NSEvent theEvent
    Overrides
    SFChartBehavior.MouseExited(CGPoint, NSEvent)

    MouseUp(CGPoint, NSEvent)

    Declaration
    protected override void MouseUp(CGPoint locationInChart, NSEvent theEvent)
    Parameters
    Type Name Description
    CoreGraphics.CGPoint locationInChart
    AppKit.NSEvent theEvent
    Overrides
    SFChartBehavior.MouseUp(CGPoint, NSEvent)

    PinchWithGestureRecognizer(SfPinchGestureRecognizer)

    Respond to a pinch zoom gesture.

    Declaration
    public virtual void PinchWithGestureRecognizer(SfPinchGestureRecognizer pinchGestureRecognizer)
    Parameters
    Type Name Description
    SfPinchGestureRecognizer pinchGestureRecognizer

    Pinch gesture recognizer.

    Reset()

    Resets the zoom level for all the axis.

    Declaration
    public void Reset()

    ScrollWheel(CGPoint, NSEvent)

    Declaration
    protected override void ScrollWheel(CGPoint locationInChart, NSEvent theEvent)
    Parameters
    Type Name Description
    CoreGraphics.CGPoint locationInChart
    AppKit.NSEvent theEvent
    Overrides
    SFChartBehavior.ScrollWheel(CGPoint, NSEvent)

    Zoom(CGRect)

    The marked rect in plot area to display the chart zoom level.

    Declaration
    public void Zoom(CGRect rect)
    Parameters
    Type Name Description
    CoreGraphics.CGRect rect

    The rect of the chart ordinate.

    Zoom(SFAxis, Double, Double)

    This method is used to change the zoom level by using zoom position and zoom factor.

    Declaration
    public void Zoom(SFAxis axis, double zoomPosition, double zoomFactor)
    Parameters
    Type Name Description
    SFAxis axis

    Axis.

    System.Double zoomPosition

    Zoom position.

    System.Double zoomFactor

    Zoom factor.

    Zoom(SFAxis, Object, Object)

    This method is used to change the zoom level by using range of the axis.

    Declaration
    public void Zoom(SFAxis axis, object startRange, object endRange)
    Parameters
    Type Name Description
    SFAxis axis

    Axis.

    System.Object startRange

    Start range.

    System.Object endRange

    End range.

    Zoom(Double)

    This method is used to change the zoom level by using factor.

    Declaration
    public void Zoom(double factor)
    Parameters
    Type Name Description
    System.Double factor

    Factor.

    ZoomIn()

    Zoom-In method is used to increase the centralization zoom level in plot area.

    Declaration
    public void ZoomIn()

    ZoomOut()

    Zoom-Out method is used to decrease the centralization zoom level in plot area.

    Declaration
    public void ZoomOut()

    ZoomWithCumulativeScale(Double, Double, SFAxis)

    Zoom the specified cumulative scale.

    Declaration
    public bool ZoomWithCumulativeScale(double cumulativeScale, double origin, SFAxis axis)
    Parameters
    Type Name Description
    System.Double cumulativeScale

    he cumulative scale of the axis.

    System.Double origin

    The origin of the plot area, its value as 0 to 1.

    SFAxis axis

    Zooming of the axis.

    Returns
    Type Description
    System.Boolean

    true, if with cumulative scale was zoomed, false otherwise.

    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved