vcl-dxchartcore-dot-tdxchartcrosshairoptions-31df421a.md
Specifies how the Chart control detects target series points for Crosshair Cursor.
property SnapToPointMode: TdxChartCrosshairSnapToPointMode read; write; default TdxChartCrosshairSnapToPointMode.Argument;
| Type | Default | Description |
|---|---|---|
| TdxChartCrosshairSnapToPointMode | Argument |
The active snap to series point mode.
|
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.
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.
|
| |
|
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.
|
| |
|
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.
|
|
The SnapToPointMode property setter changes SnapToSeriesMode and StickyLines property values as follows if the new SnapToPointMode property value is NearestToCursor:
The SnapToPointMode property’s default value is TdxChartCrosshairSnapToPointMode.Argument.
Footnotes
These examples demonstrate all possible SnapToPointMode property values for the same XY diagram with one visible simple Line series under the following conditions:
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