wpf-devexpress-dot-xpf-dot-core-dot-badge-20ef59c4.md
Gets or sets a BadgeControl‘s horizontal anchor point. This is a dependency property.
Namespace : DevExpress.Xpf.Core
Assembly : DevExpress.Xpf.Core.v25.2.dll
NuGet Package : DevExpress.Wpf.Core
public HorizontalAlignment HorizontalAnchor { get; set; }
Public Property HorizontalAnchor As HorizontalAlignment
| Type | Default | Description |
|---|---|---|
| HorizontalAlignment | Center |
The HorizontalAlignment value that specifies the badge’s horizontal anchor point.
|
The following table lists the combinations of the Badge.HorizontalAnchor and Badge.HorizontalAlignment values :
|
|
HorizontalAnchor
| | --- | --- | |
HorizontalAlignment
| | --- | |
Left
|
Center
|
Right
|
Stretch
| |
Left
|
|
|
|
| |
Center
|
|
|
|
| |
Right
|
|
|
|
| |
Stretch
|
|
|
|
|
Note
When Badge.HorizontalAnchor is Stretch , the anchor point gets the value from the Badge.HorizontalAlignment property.
The following code sample sets the Badge.HorizontalAnchor and Badge.HorizontalAlignment properties to Left :
<dx:SimpleButton ...>
<dx:Badge.Badge>
<dx:Badge Content="10" HorizontalAnchor="Left" HorizontalAlignment="Left" />
</dx:Badge.Badge>
</dx:SimpleButton>
See Also
Badge.VerticalAlignment Property