Enum Element.Alignment
- java.lang.Object
-
- java.lang.Enum<Element.Alignment>
-
- be.yildizgames.module.graphic.gui.internal.Element.Alignment
-
- All Implemented Interfaces:
Serializable,Comparable<Element.Alignment>
- Enclosing interface:
- Element
public static enum Element.Alignment extends Enum<Element.Alignment>
Alignment value to set the widgets positions.- Author:
- Van den Borre Grégory
-
-
Enum Constant Summary
Enum Constants Enum Constant Description BOTTOMWidget will be bottom aligned, its top position will be computed from its bottom part.CENTERWidget will be centered its left position will be computed from its half width and the top will be assumed to be its half height.LEFTWidget will be left aligned, its left position will be computed from its left part.RIGHTWidget will be right aligned, its left position will be computed from its right part.TOPWidget will be top aligned, its top position will be computed from its top part.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Element.AlignmentvalueOf(String name)Returns the enum constant of this type with the specified name.static Element.Alignment[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
LEFT
public static final Element.Alignment LEFT
Widget will be left aligned, its left position will be computed from its left part. It is the default behavior.
-
RIGHT
public static final Element.Alignment RIGHT
Widget will be right aligned, its left position will be computed from its right part.
-
TOP
public static final Element.Alignment TOP
Widget will be top aligned, its top position will be computed from its top part. It is the default behavior.
-
BOTTOM
public static final Element.Alignment BOTTOM
Widget will be bottom aligned, its top position will be computed from its bottom part.
-
CENTER
public static final Element.Alignment CENTER
Widget will be centered its left position will be computed from its half width and the top will be assumed to be its half height.
-
-
Method Detail
-
values
public static Element.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 (Element.Alignment c : Element.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 Element.Alignment valueOf(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:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
-