Back to Devexpress

TdxChartCrosshairOptions.SnapToPointMode Property

vcl-dxchartcore-dot-tdxchartcrosshairoptions-31df421a.md

latest6.3 KB
Original Source

TdxChartCrosshairOptions.SnapToPointMode Property

Specifies how the Chart control detects target series points for Crosshair Cursor.

Declaration

delphi
property SnapToPointMode: TdxChartCrosshairSnapToPointMode read; write; default TdxChartCrosshairSnapToPointMode.Argument;

Property Value

TypeDefaultDescription
TdxChartCrosshairSnapToPointModeArgument

The active snap to series point mode.

|

Remarks

Use SnapToPointMode, SnapToSeriesMode, SnapToOutRangePoints, and StickyLines properties to customize crosshair line and label behavior in XY diagrams.

The SnapToPointMode property determines how the Chart control detects target series points for Crosshair Cursor. The SnapToSeriesMode property defines how Crosshair Cursor targets series, and the StickyLines property determines crosshair line behavior.

Note

Crosshair Cursor can target only one point in a series at a time. The SnapToSeriesMode property value defines the number of target series.

Property Value Examples

The following table demonstrates the difference between all snap to point modes under the same conditions:

|

Value

|

Description

|

Example[1]

| | --- | --- | --- | |

Argument ( default )

|

Crosshair Cursor targets a series point near the vertical[2] line that crosses the mouse pointer position within the diagram area.

This mode is compatible with all possible SnapToSeriesMode and StickyLines property values.

|

| |

Value

|

Crosshair Cursor targets a series point near the horizontal[2] line that crosses the mouse pointer position within the diagram area.

This mode is compatible with all possible SnapToSeriesMode and StickyLines property values.

|

| |

NearestToCursor

|

Crosshair Cursor targets a series point near the mouse pointer position within the diagram area.

The SnapToPointMode property setter updates SnapToSeriesMode and StickyLines property values when you enable the NearestToCursor mode because it is incompatible with single-line point targeting modes.

Refer to the following section for details: Property Setter Behavior.

|

|

Property Setter Behavior

The SnapToPointMode property setter changes SnapToSeriesMode and StickyLines property values as follows if the new SnapToPointMode property value is NearestToCursor:

Default Value

The SnapToPointMode property’s default value is TdxChartCrosshairSnapToPointMode.Argument.

Footnotes

  1. These examples demonstrate all possible SnapToPointMode property values for the same XY diagram with one visible simple Line series under the following conditions:

  2. Horizontal and vertical crosshair lines swap places if the Rotated property of an XY diagram is set to True.

See Also

TdxChartCrosshairOptions.HighlightPoints Property

TdxChartCrosshairOptions.Labels Property

TdxChartCrosshairOptions.ShowArgumentLabels Property

TdxChartCrosshairOptions.ShowValueLabels Property

TdxChartCrosshairOptions.SnapToOutRangePoints Property

TdxChartCrosshairOptions Class

TdxChartCrosshairOptions Members

dxChartCore Unit