ChartControl.QueryChartCursor Event
Occurs when there is a request to display the cursor on the chart control.
Namespace: DevExpress.Xpf.Charts
Assembly: DevExpress.Xpf.Charts.v14.2.dll
#Declaration
#Event Data
The QueryChartCursor event's handler receives an argument of the QueryChartCursorEventArgs type. The following properties provide information specific to this event:
Property | Description |
---|---|
Cursor | Gets or sets the mouse cursor currently being shown for the chart. |
Cursor |
Provides an image for the custom cursor. |
Cursor |
Specifies an image offset for a custom cursor on a chart diagram. |
Handled |
Gets or sets a value that indicates the present state of the event handling for a routed event as it travels the route.
Inherited from Routed |
Original |
Gets the original reporting source as determined by pure hit testing, before any possible Source adjustment by a parent class.
Inherited from Routed |
Position | Gets or sets a value that specifies the position of a custom cursor on the chart's diagram. |
Routed |
Gets or sets the Routed |
Source |
Gets or sets a reference to the object that raised the event.
Inherited from Routed |
#Remarks
In the QueryChartCursor event handler, you can provide custom cursors for your chart in various circumstances (e.g. when a chart is being scrolled or zoomed).
#Examples
This example shows how to display a custom cursor when the mouse pointer is hovering over the chart control.
To accomplish this task, handle the ChartControl.QueryChartCursor event and assign your custom image (e.g., a BitmapImage object loaded from application resources) to the QueryChartCursorEventArgs.CursorImage property.
Note that you need to include your image in the project and set the QueryChartCursorEventArgs.Cursor property to None to see the custom image in the chart control.