AxisDragModifierBase

StockSharp.Xaml.Charting.ChartModifiers

Provides base class for dragging operations on axes

継承元: ChartModifierBase

コンストラクター

AxisDragModifierBase()

Initializes a new instance of the AxisDragModifierBase class.

プロパティ

AxisId : string

Defines which YAxis to bind the YAxisDragModifier to, matching by string Id

DragMode : AxisDragModes

Gets or sets the DragMode of the YAxisDragModifier. This modifier may be used to scale the VisibleRange or pan the VisibleRange creating a scrolling or vertical pan effect.

IsDragging : bool

Gets a value indicating whether the user is currently dragging the axis

MinTouchArea : double

Gets or sets minimal area of recognition (min height for horizontal axis or min width for vertical), where user click or touch triggers zoom behavior.

メソッド

CalculateRelativeRange(IRange, IAxis) : DoubleRange

When overriden in a derived class, calculates an output IRange to apply to the associated AxisBaseAxis, given the input parameters.

fromRange
The input range, expecting a VisibleRange
axis
The axis being operated on

戻り値: The output IRange which can then be applied to the GrowBy property to get the same affect as applying the input visible-range

CalculateScaledRange(Point, Point, bool, IAxis) : IRange

When overriden in a derived class, calculates an output IRange to apply to the associated AxisBaseAxis, given the input parameters

currentPoint
The current mouse position
lastPoint
The last mouse position
isSecondHalf
A flag, which determines how the scale operates, e.g. which half of the axis (top or bottom, left or right) was dragged
axis
The axis being operated on

戻り値: The output IRange

GetCurrentAxis() : IAxis

Gets the IAxis instance, which current modifier is associated with, on the parent UltrachartSurface

GetIsSecondHalf(Point, Rect, bool) : bool

Gets whether the specified mouse point is within the second (right-most or top-most) half of the Axis bounds

point
The mouse point
axisBounds
The axis bounds
isHorizontalAxis
Value, which indicates whether current axis is horizontal or not

戻り値: True if the point is within the second (right-most or top-most) half of the axis bounds, else false

GetUsedCursor(IAxis) : Cursor

Depending on axis orientation, returns a Cursor to show during mouse-over of the axis

axis
The axis instance
OnAttached()

Called when the Chart Modifier is attached to the Chart Surface

OnDetached()

Called immediately before the Chart Modifier is detached from the Chart Surface

OnIsEnabledChanged()

Called when the IsEnabled property changes on this ChartModifierBase instance

OnModifierMouseDown(ModifierMouseArgs)

Called when a Mouse Button is pressed on the parent UltrachartSurface

e
Arguments detailing the mouse button operation
OnModifierMouseMove(ModifierMouseArgs)

Called when the Mouse is moved on the parent UltrachartSurface

e
Arguments detailing the mouse move operation
OnModifierMouseUp(ModifierMouseArgs)

Called when a Mouse Button is released on the parent UltrachartSurface

e
Arguments detailing the mouse button operation
PerformPan(Point, Point)

Peforms a pan on the assocaited AxisBase. The pan is considered to be a drag from to

currentPoint
The current mouse point
lastPoint
The last mouse point
PerformScale(Point, Point, bool)

Performs a Scale on the associated AxisBase. The scale is considered to be a drag from to

currentPoint
The current mouse point
lastPoint
The last mouse point
isSecondHalf
Boolean flag to determine which side of the axis is scaled
SetAxisCursor(Cursor)

Sets passed cursor on current axis, or default cursor returned by IAxis)

フィールド

AxisIdProperty : DependencyProperty

Defines the YAxisId DependencyProperty

DragModeProperty : DependencyProperty

Defines the DragMode DependencyProperty

MinTouchAreaProperty : DependencyProperty

Defines the MinTouchArea DependencyProperty