![]() |
Previous | Next |
The horizontalAlignment attribute specifies or retrieves the horizontal alignment of the control when the VIEW or parent SUBVIEW is resized.
Syntax
elementID.horizontalAlignment
Possible Values
This attribute is a read/write String.
Values | Description |
left | Default. Aligns the control to the left of the VIEW or parent SUBVIEW when resized. |
right | Aligns the control to the right of the VIEW or parent SUBVIEW when resized. |
center | Aligns the control to the horizontal center of the VIEW or parent SUBVIEW when resized. |
stretch | Aligns the control to left and right margins of the VIEW or parent SUBVIEW when resized. The control stretches to fit when the VIEW or SUBVIEW is stretched. The actual image does not grow or shrink unless it is resizable, but the clickable area grows or shrinks if not bounded by a clippingImage. |
Remarks
Unless horizontalAlignment is set to “center”, the control retains its original distance from the specified edge, or from both edges if “stretch” is specified and the control is resizable. If the control is not resizable and “stretch” is specified, the clickable region is stretched instead.
You can set any combination of horizontalAlignment and verticalAlignment. For example, if you want to center a control both horizontally and vertically, set horizontalAlignment=“center” verticalAlignment=“center”.
See Also
Previous | Next |