Back to Devexpress

How to: Dock an Annotation to a Pane

wpf-116109-controls-and-libraries-charts-suite-chart-control-examples-chart-elements-how-to-dock-an-annotation-to-a-pane.md

latest1.3 KB
Original Source

How to: Dock an Annotation to a Pane

  • Jun 07, 2019

This example shows how to anchor an annotation to a pane.

xaml
<dxc:Annotation.AnchorPoint>
    <dxc:PaneAnchorPoint Pane="{Binding ElementName=defaultPane}">
        <dxc:PaneAnchorPoint.AxisXCoordinate>
            <dxc:AxisXCoordinate Axis="{Binding ElementName=xAxis}" 
                                 AxisValue="2.85"/>
        </dxc:PaneAnchorPoint.AxisXCoordinate>
        <dxc:PaneAnchorPoint.AxisYCoordinate>
            <dxc:AxisYCoordinate Axis="{Binding ElementName=yAxis}" 
                                 AxisValue="-30"/>
        </dxc:PaneAnchorPoint.AxisYCoordinate>
    </dxc:PaneAnchorPoint>
</dxc:Annotation.AnchorPoint>