LiveChartViewModel.GetLineUnderMouse(float, float) method¶
Defined in
Type: LiveChartViewModel
Namespace: CrissCross.WPF.Plot
Assembly: CrissCross.WPF.Plot.dll
Applies to
net10.0-windows10.0.19041, net9.0-windows10.0.19041, net8.0-windows10.0.19041, net481
public AxisLine? GetLineUnderMouse(float x, float y)
Summary: Gets the axis line located under the specified mouse coordinates, if any.
Parameters
| Name | Type | Description |
|---|---|---|
x | float | The x-coordinate of the mouse position, in plot units. |
y | float | The y-coordinate of the mouse position, in plot units. |
Returns: AxisLine? -- An AxisLine representing the axis line under the mouse position, or null if no
axis line is found.
Remarks
This method checks for both horizontal and vertical axis lines near the given coordinates. The search uses a small radius to determine proximity. If multiple axis lines overlap, the first one found is returned.