Back to Devexpress

ChartAnchorPoint Class

wpf-devexpress-dot-xpf-dot-charts-3055e43b.md

latest2.5 KB
Original Source

ChartAnchorPoint Class

Settings that indicate the Annotation is anchored to a chart.

Namespace : DevExpress.Xpf.Charts

Assembly : DevExpress.Xpf.Charts.v25.2.dll

NuGet Package : DevExpress.Wpf.Charts

Declaration

csharp
public class ChartAnchorPoint :
    AnnotationAnchorPoint
vb
Public Class ChartAnchorPoint
    Inherits AnnotationAnchorPoint

Remarks

The annotation position relative to the chart’s top and left edges can be specified using the ChartAnchorPoint.X and ChartAnchorPoint.Y properties. These coordinates position an annotation absolutely, meaning that the anchor point doesn’t change when a chart is being resized.

Example

This example demonstrates how to anchor an annotation to a chart surface point as shown in the following image:

To do this, specify the ChartAnchorPoint.X and ChartAnchorPoint.Y properties.

xaml
<dxc:Annotation Content="Annotation #3">
    <dxc:Annotation.AnchorPoint>
        <dxc:ChartAnchorPoint X="100" 
                              Y="220"/>
    </dxc:Annotation.AnchorPoint>
    <dxc:Annotation.ShapePosition>
        <dxc:RelativePosition ConnectorLength="80" 
                              Angle="-20"/>
    </dxc:Annotation.ShapePosition>
</dxc:Annotation>

Inheritance

Object DispatcherObject DependencyObject Freezable ChartDependencyObject AnnotationAnchorPoint ChartAnchorPoint

See Also

ChartAnchorPoint Members

DevExpress.Xpf.Charts Namespace