Skip to main content

FreePosition.VerticalAlignment Property

Gets or sets how the annotation will be located vertically.

Namespace: DevExpress.Xpf.Charts

Assembly: DevExpress.Xpf.Charts.v24.1.dll

NuGet Package: DevExpress.Wpf.Charts

Declaration

public AnnotationVerticalAlignment VerticalAlignment { get; set; }

Property Value

Type Description
AnnotationVerticalAlignment

A AnnotationVerticalAlignment object specifying vertical alignment.

Available values:

Name Description
Top

The annotation is aligned to the top edge of a parent element.

Center

The annotation is aligned to the center of the vertical within a parent element.

Bottom

The annotation is aligned to the bottom edge of a parent element.

Example

This example demonstrates how to customize the annotation layout when the Annotation.ShapePosition property is specified as the FreePosition type.

To do this, dock the annotation to the required element using the FreePosition.DockTarget property. Then, specify the FreePosition.VerticalAlignment and FreePosition.HorizontalAlignment properties, to configure the annotation position.

<dxc:Annotation.ShapePosition>
    <dxc:FreePosition HorizontalAlignment="Right" 
                      VerticalAlignment="Top" 
                      DockTarget="{Binding ElementName=defaultPane}"/>
</dxc:Annotation.ShapePosition>
See Also