Package com.vaadin.classic.v8.ui
Class Alignment
java.lang.Object
com.vaadin.classic.v8.ui.Alignment
- All Implemented Interfaces:
Serializable
Legacy version of Alignment that resembles Vaadin 7/8's Alignment API as
closely as possible in order to facilitate migration to newer versions of
Vaadin.
Class containing information about alignment of a component. Use the pre-instantiated classes.
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanintReturns a bitmask representation of the alignment value.Returns string representation of horizontal alignment.Returns string representation of vertical alignment.inthashCode()booleanisBottom()Checks if component is aligned to the bottom of the available space.booleanisCenter()Checks if component is aligned center (horizontally) of the available space.booleanisLeft()Checks if component is aligned to the left of the available space.booleanisMiddle()Checks if component is aligned middle (vertically center) of the available space.booleanisRight()Checks if component is aligned to the right of the available space.booleanisTop()Checks if component is aligned to the top of the available space.toString()
-
Field Details
-
TOP_RIGHT
-
TOP_LEFT
-
TOP_CENTER
-
MIDDLE_RIGHT
-
MIDDLE_LEFT
-
MIDDLE_CENTER
-
BOTTOM_RIGHT
-
BOTTOM_LEFT
-
BOTTOM_CENTER
-
-
Constructor Details
-
Alignment
public Alignment(int bitMask)
-
-
Method Details
-
getBitMask
public int getBitMask()Returns a bitmask representation of the alignment value. Used internally by terminal.- Returns:
- the bitmask representation of the alignment value
-
isTop
public boolean isTop()Checks if component is aligned to the top of the available space.- Returns:
- true if aligned top
-
isBottom
public boolean isBottom()Checks if component is aligned to the bottom of the available space.- Returns:
- true if aligned bottom
-
isLeft
public boolean isLeft()Checks if component is aligned to the left of the available space.- Returns:
- true if aligned left
-
isRight
public boolean isRight()Checks if component is aligned to the right of the available space.- Returns:
- true if aligned right
-
isMiddle
public boolean isMiddle()Checks if component is aligned middle (vertically center) of the available space.- Returns:
- true if aligned bottom
-
isCenter
public boolean isCenter()Checks if component is aligned center (horizontally) of the available space.- Returns:
- true if aligned center
-
getVerticalAlignment
Returns string representation of vertical alignment.- Returns:
- vertical alignment as CSS value
-
getHorizontalAlignment
Returns string representation of horizontal alignment.- Returns:
- horizontal alignment as CSS value
-
equals
-
hashCode
public int hashCode() -
toString
-