RadarDiagram.PointToDiagram(Point) Method
Converts the chart control screen point’s coordinates (in pixels) into an Radar (Polar) Diagram plot area coordinates object.
Namespace: DevExpress.XtraCharts
Assembly: DevExpress.XtraCharts.v24.1.dll
NuGet Package: DevExpress.Charts
Declaration
Parameters
Name | Type | Description |
---|---|---|
p | Point | A point within the Chart Control’s area. |
Returns
Type | Description |
---|---|
DiagramCoordinates | An object that contains information about the point’s argument and value, their scale types, associated axes and pane. |
Remarks
Use the PointToDiagram method to convert a chart control screen point’s coordinates that are indexed from its upper-left corner and measured in pixels to the diagram coordinates in axis measurement units.
To convert a screen coordinate point to a point with chart coordinates, use the ChartControl.PointToClient method.
private void chartControl_MouseMove(object sender, MouseEventArgs e) {
DiagramCoordinates coords = ((RadarDiagram)chartControl.Diagram).PointToDiagram(chartControl.PointToClient(Cursor.Position));
label.Text = string.Format("X:{0}, Y:{1}", coords.NumericalArgument, coords.NumericalValue);
}
Note
Use the RadarDiagram.DiagramToPoint method to convert diagram coordinates to chart coordinates with an overload appropriate to your axes’ scale types.).
With the XY-Diagram type, use the XYDiagram2D.PointToDiagram and XYDiagram2D.DiagramToPoint methods.