Interface ResponsiveGridLayout.Row
- All Superinterfaces:
ResponsiveGridLayout.GridElement
- All Known Implementing Classes:
ResponsiveGridLayoutImpl.RowImpl
- Enclosing interface:
- ResponsiveGridLayout
ResponsiveGridLayout.Column
s with the ability to provide content alignment.
Corresponds to the <div class="row">
element.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addAlignItems
(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.AlignItems alignItems) Adds information regarding how columns are laid out along the cross axis on the current row at the given breakpoint.Creates a newResponsiveGridLayout.Column
and adds it to this row.addColumn
(int index) Creates a newResponsiveGridLayout.Column
and adds it to the given position in this row.void
addJustifyContent
(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.JustifyContent justifyContent) Adds information regarding how columns are laid out along the main axis on the current row at the given breakpoint.void
addRowColumns
(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.RowColumnsValue columnsValue) Adds information regarding what number of columns in the row will be at the given breakpoint.Returns the map that contains information regarding how columns are laid out along the cross axis on the current row at a specific breakpoint.float
Returns the height of this row.Returns the height property units.Returns the map that contains information regarding how columns are laid out along the main axis on the current row at a specific breakpoint.Returns the map that contains information regarding what number of columns in the row will be at a specific breakpoint.boolean
void
removeAlignItems
(ResponsiveGridLayout.Breakpoint breakpoint) Removes the mapping of how columns are laid out along the cross axis on the current row for the given breakpoint if it is present.void
Removes all columns from this row.void
Removes the given column from this row.void
removeJustifyContent
(ResponsiveGridLayout.Breakpoint breakpoint) Removes the mapping of how columns are laid out along the main axis on the current row for the given breakpoint if it is present.void
removeRowColumns
(ResponsiveGridLayout.Breakpoint breakpoint) Removes the mapping of the number of columns in the row for the given breakpoint if it is present.default void
setAlignItems
(ResponsiveGridLayout.AlignItems alignItems) Sets a new mapping of how columns are laid out along the cross axis on the current row at all breakpoints, i.e.default void
setAlignItems
(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.AlignItems alignItems) Sets a new mapping of how columns are laid out along the cross axis on the current row with the specified breakpoint.void
Sets a new mapping of how columns are laid out along the cross axis on the current row with corresponding breakpoints.void
setGuttersEnabled
(boolean guttersEnabled) Sets whether gutters are enabled.void
Sets the height of the component using String presentation.default void
Sets row height toComponent.AUTO_SIZE
.default void
Sets row height toComponent.FULL_SIZE
.default void
setJustifyContent
(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.JustifyContent justifyContent) Sets a new mapping of how columns are laid out along the main axis on the current row with the specified breakpoint.default void
setJustifyContent
(ResponsiveGridLayout.JustifyContent justifyContent) Sets a new mapping of how columns are laid out along the main axis on the current row at all breakpoints, i.e.void
setJustifyContent
(Map<ResponsiveGridLayout.Breakpoint, ResponsiveGridLayout.JustifyContent> justifyContent) Sets a new mapping of how columns are laid out along the main axis on the current row with corresponding breakpoints.default void
setRowColumns
(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.RowColumnsValue columnsValue) Sets a new mapping of the number of columns in the row with the specified breakpoint.default void
setRowColumns
(ResponsiveGridLayout.RowColumnsValue columnsValue) Sets a new mapping of the number of columns in the row that will be applied for all breakpoints, i.e.void
Sets a new mapping of the number of columns in the row with corresponding breakpoints.Methods inherited from interface io.jmix.ui.component.ResponsiveGridLayout.GridElement
addStyleName, getId, getStyleName, removeStyleName, setId, setStyleName
-
Method Details
-
addColumn
ResponsiveGridLayout.Column addColumn()Creates a newResponsiveGridLayout.Column
and adds it to this row.- Returns:
- the created column
- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
addColumn
Creates a newResponsiveGridLayout.Column
and adds it to the given position in this row.- Parameters:
index
- the position of the new column. The columns that are currently in and after the position are shifted forwards- Returns:
- the created column
- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
removeColumn
Removes the given column from this row.- Parameters:
column
- the column to be removed- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
removeAllColumns
void removeAllColumns()Removes all columns from this row.- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
getColumns
List<ResponsiveGridLayout.Column> getColumns()- Returns:
- a list of contained columns
-
isGuttersEnabled
boolean isGuttersEnabled()- Returns:
- whether gutters are enabled
-
setGuttersEnabled
Sets whether gutters are enabled. Gutters are enabled by default.If set to
false
, the.no-gutters
style will be added to this row. It removes the negative margins from the row and the horizontal padding from all immediate children columns.- Parameters:
guttersEnabled
- a boolean value specifying if the row should have gutters or not- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
getHeight
float getHeight()Returns the height of this row. A negative number implies unspecified size.- Returns:
- height of the row in units specified by {
getHeightSizeUnit()
} property.
-
getHeightSizeUnit
SizeUnit getHeightSizeUnit()Returns the height property units.- Returns:
- units used in height property.
-
setHeight
Sets the height of the component using String presentation.String presentation is similar to what is used in Cascading Style Sheets. Size can be length or percentage of available size.
The empty string ("") or null will unset the height and set the units to pixels.
- Parameters:
height
- the height to be set- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
setHeightAuto
default void setHeightAuto()Sets row height toComponent.AUTO_SIZE
.- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
setHeightFull
default void setHeightFull()Sets row height toComponent.FULL_SIZE
.- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
getRowColumns
Map<ResponsiveGridLayout.Breakpoint,ResponsiveGridLayout.RowColumnsValue> getRowColumns()Returns the map that contains information regarding what number of columns in the row will be at a specific breakpoint.Corresponds to the
.row-cols-{breakpoint}-*
responsive styles.- Returns:
- the map that contains information regarding what number of columns in the row will be at a specific breakpoint
-
setRowColumns
@StudioProperty(name="cols", type=INTEGER) default void setRowColumns(ResponsiveGridLayout.RowColumnsValue columnsValue) Sets a new mapping of the number of columns in the row that will be applied for all breakpoints, i.e. starting fromResponsiveGridLayout.Breakpoint.XS
. Clears previous values and creates a map with a single value.- Parameters:
columnsValue
- the instance ofResponsiveGridLayout.RowColumnsValue
to set for all breakpoint- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
setRowColumns
default void setRowColumns(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.RowColumnsValue columnsValue) Sets a new mapping of the number of columns in the row with the specified breakpoint. Clears previous values and creates a map with a single value.- Parameters:
breakpoint
- the breakpoint to start fromcolumnsValue
- the instance ofResponsiveGridLayout.RowColumnsValue
to set- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
setRowColumns
void setRowColumns(Map<ResponsiveGridLayout.Breakpoint, ResponsiveGridLayout.RowColumnsValue> columns) Sets a new mapping of the number of columns in the row with corresponding breakpoints. Overrides previous values.Corresponds to the
.row-cols-{breakpoint}-*
responsive styles.- Parameters:
columns
- the map that contains information regarding what number of columns in the row will be at a specific breakpoint- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
addRowColumns
void addRowColumns(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.RowColumnsValue columnsValue) Adds information regarding what number of columns in the row will be at the given breakpoint. If a mapping for the breakpoint already exist, the old value is replaced by the specifiedResponsiveGridLayout.RowColumnsValue
instance.- Parameters:
breakpoint
- the breakpoint with which the specifiedResponsiveGridLayout.RowColumnsValue
instance is to be associatedcolumnsValue
- theResponsiveGridLayout.RowColumnsValue
instance to be associated with the specified breakpoint- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
removeRowColumns
Removes the mapping of the number of columns in the row for the given breakpoint if it is present.- Parameters:
breakpoint
- the breakpoint for which to remove mapping- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
getAlignItems
Map<ResponsiveGridLayout.Breakpoint,ResponsiveGridLayout.AlignItems> getAlignItems()Returns the map that contains information regarding how columns are laid out along the cross axis on the current row at a specific breakpoint.Corresponds to the
.align-items-{breakpoint}-*
responsive styles.- Returns:
- the map that contains information regarding how columns are laid out along the cross axis on the current row at a specific breakpoint
-
setAlignItems
@StudioProperty(type=ENUMERATION, options={"START","CENTER","END","BASELINE","STRETCH"}) default void setAlignItems(ResponsiveGridLayout.AlignItems alignItems) Sets a new mapping of how columns are laid out along the cross axis on the current row at all breakpoints, i.e. starting fromResponsiveGridLayout.Breakpoint.XS
. Clears previous values and creates a map with a single value.- Parameters:
alignItems
- theResponsiveGridLayout.AlignItems
value to set for all breakpoints- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
setAlignItems
default void setAlignItems(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.AlignItems alignItems) Sets a new mapping of how columns are laid out along the cross axis on the current row with the specified breakpoint. Clears previous values and creates a map with a single value.- Parameters:
breakpoint
- the breakpoint to start fromalignItems
- theResponsiveGridLayout.AlignItems
value to set- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
setAlignItems
Sets a new mapping of how columns are laid out along the cross axis on the current row with corresponding breakpoints. Overrides previous values.Corresponds to the
.align-items-{breakpoint}-*
responsive styles.- Parameters:
alignItems
- the map that contains information regarding how columns are laid out along the cross axis on the current row at a specific breakpoint- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
addAlignItems
void addAlignItems(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.AlignItems alignItems) Adds information regarding how columns are laid out along the cross axis on the current row at the given breakpoint. If a mapping for the breakpoint already exist, the old value is replaced by the specifiedResponsiveGridLayout.AlignItems
value.- Parameters:
breakpoint
- the breakpoint with which the specifiedResponsiveGridLayout.AlignItems
value is to be associatedalignItems
- theResponsiveGridLayout.AlignItems
value to be associated with the specified breakpoint- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
removeAlignItems
Removes the mapping of how columns are laid out along the cross axis on the current row for the given breakpoint if it is present.- Parameters:
breakpoint
- the breakpoint for which to remove mapping- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
getJustifyContent
Map<ResponsiveGridLayout.Breakpoint,ResponsiveGridLayout.JustifyContent> getJustifyContent()Returns the map that contains information regarding how columns are laid out along the main axis on the current row at a specific breakpoint.Corresponds to the
.justify-content-{breakpoint}-*
responsive styles.- Returns:
- the map that contains information regarding how columns are laid out along the main axis on the current row at a specific breakpoint
-
setJustifyContent
@StudioProperty(type=ENUMERATION, options={"AROUND","BETWEEN","CENTER","END","START"}) default void setJustifyContent(ResponsiveGridLayout.JustifyContent justifyContent) Sets a new mapping of how columns are laid out along the main axis on the current row at all breakpoints, i.e. starting fromResponsiveGridLayout.Breakpoint.XS
. Clears previous values and creates a map with a single value.- Parameters:
justifyContent
- theResponsiveGridLayout.JustifyContent
value to set for all breakpoints- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
setJustifyContent
default void setJustifyContent(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.JustifyContent justifyContent) Sets a new mapping of how columns are laid out along the main axis on the current row with the specified breakpoint. Clears previous values and creates a map with a single value.- Parameters:
breakpoint
- the breakpoint to start fromjustifyContent
- theResponsiveGridLayout.JustifyContent
value to set- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
setJustifyContent
void setJustifyContent(Map<ResponsiveGridLayout.Breakpoint, ResponsiveGridLayout.JustifyContent> justifyContent) Sets a new mapping of how columns are laid out along the main axis on the current row with corresponding breakpoints. Overrides previous values.Corresponds to the
.justify-content-{breakpoint}-*
responsive styles.- Parameters:
justifyContent
- the map that contains information regarding how columns are laid out along the main axis on the current row at a specific breakpoint- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-
addJustifyContent
void addJustifyContent(ResponsiveGridLayout.Breakpoint breakpoint, ResponsiveGridLayout.JustifyContent justifyContent) Adds information regarding how columns are laid out along the main axis on the current row at the given breakpoint. If a mapping for the breakpoint already exist, the old value is replaced by the specifiedResponsiveGridLayout.JustifyContent
value.- Parameters:
breakpoint
- the breakpoint with which the specifiedResponsiveGridLayout.AlignItems
value is to be associatedjustifyContent
- theResponsiveGridLayout.JustifyContent
value to be associated with the specified breakpoint- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen- See Also:
-
removeJustifyContent
Removes the mapping of how columns are laid out along the main axis on the current row for the given breakpoint if it is present.- Parameters:
breakpoint
- the breakpoint for which to remove mapping- Throws:
IllegalStateException
- if parent responsive grid layout has been shown on a screen
-