Package io.jmix.ui.component
Interface GridLayout
- All Superinterfaces:
Component
,Component.BelongToFrame
,Component.HasCaption
,Component.HasDescription
,Component.HasIcon
,ComponentContainer
,HasComponents
,HasContextHelp
,HasHtmlCaption
,HasHtmlDescription
,HasHtmlSanitizer
,HasMargin
,HasRequiredIndicator
,HasSpacing
,LayoutClickNotifier
,ShortcutNotifier
- All Known Implementing Classes:
GridLayoutImpl
@StudioComponent(caption="GridLayout",
category="Containers",
xmlElement="gridLayout",
icon="io/jmix/ui/icon/container/gridLayout.svg",
canvasBehaviour=CONTAINER,
containerType=GRID,
documentationURL="https://docs.jmix.io/jmix/%VERSION%/ui/vcl/containers/grid-layout.html")
public interface GridLayout
extends ComponentContainer, HasSpacing, HasMargin, Component.BelongToFrame, Component.HasIcon, Component.HasCaption, HasContextHelp, LayoutClickNotifier, ShortcutNotifier, HasHtmlCaption, HasHtmlDescription, HasRequiredIndicator, HasHtmlSanitizer
A layout where the components are laid out on a grid using cell coordinates.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
Defines a rectangular area of cells in a GridLayout.Nested classes/interfaces inherited from interface io.jmix.ui.component.Component
Component.Alignment, Component.BelongToFrame, Component.Disposable, Component.Editable, Component.Focusable, Component.HasCaption, Component.HasDescription, Component.HasIcon, Component.HasXmlDescriptor, Component.Wrapper
Nested classes/interfaces inherited from interface io.jmix.ui.component.HasContextHelp
HasContextHelp.ContextHelpIconClickEvent
Nested classes/interfaces inherited from interface io.jmix.ui.component.LayoutClickNotifier
LayoutClickNotifier.LayoutClickEvent
-
Field Summary
Fields inherited from interface io.jmix.ui.component.Component
AUTO_SIZE, AUTO_SIZE_PX, FULL_SIZE
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
float
getColumnExpandRatio
(int col) int
getComponent
(int columnIndex, int rowIndex) Gets the Component at given row and column.getComponentArea
(Component component) Returns information about the area where given component is laid in the GridLayout.default Component
getComponentNN
(int columnIndex, int rowIndex) Gets the Component at given row and column.float
getRowExpandRatio
(int row) int
getRows()
void
setColumnExpandRatio
(int col, float ratio) void
setColumns
(int columns) void
setRowExpandRatio
(int row, float ratio) void
setRows
(int rows) Methods inherited from interface io.jmix.ui.component.Component
addStyleName, getAlignment, getHeight, getHeightSizeUnit, getId, getParent, getStyleName, getWidth, getWidthSizeUnit, isEnabled, isEnabledRecursive, isResponsive, isVisible, isVisibleRecursive, removeStyleName, setAlignment, setEnabled, setHeight, setHeightAuto, setHeightFull, setId, setParent, setResponsive, setSizeAuto, setSizeFull, setStyleName, setVisible, setWidth, setWidthAuto, setWidthFull, unwrap, unwrapComposition, unwrapCompositionOrNull, unwrapOrNull, withUnwrapped, withUnwrappedComposition
Methods inherited from interface io.jmix.ui.component.Component.BelongToFrame
getFrame, setFrame
Methods inherited from interface io.jmix.ui.component.Component.HasCaption
getCaption, setCaption
Methods inherited from interface io.jmix.ui.component.Component.HasDescription
getDescription, setDescription
Methods inherited from interface io.jmix.ui.component.Component.HasIcon
getIcon, setIcon, setIconFromSet
Methods inherited from interface io.jmix.ui.component.ComponentContainer
add, add, remove, remove, removeAll
Methods inherited from interface io.jmix.ui.component.HasComponents
focusFirstComponent, getComponent, getComponentNN, getComponents, getOwnComponent, getOwnComponents, getOwnComponentsStream
Methods inherited from interface io.jmix.ui.component.HasContextHelp
getContextHelpIconClickHandler, getContextHelpText, isContextHelpTextHtmlEnabled, setContextHelpIconClickHandler, setContextHelpText, setContextHelpTextHtmlEnabled
Methods inherited from interface io.jmix.ui.component.HasHtmlCaption
isCaptionAsHtml, setCaptionAsHtml
Methods inherited from interface io.jmix.ui.component.HasHtmlDescription
isDescriptionAsHtml, setDescriptionAsHtml
Methods inherited from interface io.jmix.ui.component.HasHtmlSanitizer
isHtmlSanitizerEnabled, setHtmlSanitizerEnabled
Methods inherited from interface io.jmix.ui.component.HasMargin
getMargin, setMargin, setMargin, setMargin
Methods inherited from interface io.jmix.ui.component.HasRequiredIndicator
isRequiredIndicatorVisible, setRequiredIndicatorVisible
Methods inherited from interface io.jmix.ui.component.HasSpacing
getSpacing, setSpacing
Methods inherited from interface io.jmix.ui.component.LayoutClickNotifier
addLayoutClickListener
Methods inherited from interface io.jmix.ui.component.ShortcutNotifier
addShortcutAction, removeShortcutAction
-
Field Details
-
NAME
- See Also:
-
-
Method Details
-
getColumnExpandRatio
float getColumnExpandRatio(int col) -
setColumnExpandRatio
void setColumnExpandRatio(int col, float ratio) -
getRowExpandRatio
float getRowExpandRatio(int row) -
setRowExpandRatio
void setRowExpandRatio(int row, float ratio) -
add
-
add
-
getRows
int getRows() -
setRows
void setRows(int rows) -
getColumns
int getColumns() -
setColumns
void setColumns(int columns) -
getComponent
Gets the Component at given row and column.- Parameters:
columnIndex
- the column index, starting from 0 for the leftmost column.rowIndex
- the row index, starting from 0 for the topmost row.- Returns:
- Component in given cell or null if empty
-
getComponentNN
Gets the Component at given row and column.- Parameters:
columnIndex
- the column index, starting from 0 for the leftmost column.rowIndex
- the row index, starting from 0 for the topmost row.- Returns:
- component. Throws exception if not found.
-
getComponentArea
Returns information about the area where given component is laid in the GridLayout.- Parameters:
component
- the component whose area information is requested.- Returns:
- an Area object that contains information how component is laid in the grid
-