Windows app
摺疊目錄
展開目錄
EN
本內容沒有您的語言版本,但有英文版本。

HorizontalAlignment Enumeration

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

Indicates where an element should be displayed on the horizontal axis relative to the allocated layout slot of the parent element.

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

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

Member nameDescription
LeftAn element aligned to the left of the layout slot for the parent element.
CenterAn element aligned to the center of the layout slot for the parent element.
RightAn element aligned to the right of the layout slot for the parent element.
StretchAn element stretched to fill the entire layout slot of the parent element.

Stretch is the default layout behavior.

Element Height and Width properties that are explicitly set take precedence over the Stretch property value.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

顯示:
© 2016 Microsoft