- java.lang.Object
-
- java.lang.Enum<LinearLayout.Alignment>
-
- com.googlecode.lanterna.gui2.LinearLayout.Alignment
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<LinearLayout.Alignment>
- Enclosing class:
- LinearLayout
public static enum LinearLayout.Alignment extends java.lang.Enum<LinearLayout.Alignment>
This enum type will decide the alignment of a component on the counter-axis, meaning the horizontal alignment on verticalLinearLayout
s and vertical alignment on horizontalLinearLayout
s.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description Beginning
The component will be placed to the left (for vertical layouts) or top (for horizontal layouts)Center
The component will be placed horizontally centered (for vertical layouts) or vertically centered (for horizontal layouts)End
The component will be placed to the right (for vertical layouts) or bottom (for horizontal layouts)Fill
The component will be forced to take up all the horizontal space (for vertical layouts) or vertical space (for horizontal layouts)
-
Constructor Summary
Constructors Modifier Constructor Description private
Alignment()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static LinearLayout.Alignment
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static LinearLayout.Alignment[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
Beginning
public static final LinearLayout.Alignment Beginning
The component will be placed to the left (for vertical layouts) or top (for horizontal layouts)
-
Center
public static final LinearLayout.Alignment Center
The component will be placed horizontally centered (for vertical layouts) or vertically centered (for horizontal layouts)
-
End
public static final LinearLayout.Alignment End
The component will be placed to the right (for vertical layouts) or bottom (for horizontal layouts)
-
Fill
public static final LinearLayout.Alignment Fill
The component will be forced to take up all the horizontal space (for vertical layouts) or vertical space (for horizontal layouts)
-
-
Method Detail
-
values
public static LinearLayout.Alignment[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (LinearLayout.Alignment c : LinearLayout.Alignment.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static LinearLayout.Alignment valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-