TextAlignment Enumeration
TOC
Collapse the table of content
Expand the table of content

TextAlignment Enumeration

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Specifies whether text is centered, left-aligned, or right-aligned.

Namespace:  System.Windows
Assembly:  System.Windows (in System.Windows.dll)
XMLNS for XAML: Not mapped to an xmlns.

public enum TextAlignment
<object property="enumMemberName"/>

Member nameDescription
CenterText is centered within the container.
LeftText is aligned to the left edge of the container.
RightText is aligned to the right edge of the container.
JustifyText is justified within the container.

Justify is relevant only for certain containers, for example RichTextBox.

Version Notes

Windows Phone

 Justify is not a valid value in Windows Phone.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2017 Microsoft