Class TableGridLayout
java.lang.Object
com.inductiveautomation.factorypmi.application.components.calendar.layouts.TableGridLayout
- All Implemented Interfaces:
LayoutManager
,LayoutManager2
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected int
static final String
Components should store their TableGridLayoutConstraint object as a user object with this keyprotected int
protected int
protected int
protected int
protected int
protected int
protected int
-
Constructor Summary
ConstructorsConstructorDescriptionTableGridLayout
(int rows, int cols, int x1offset, int y1offset, int x2offset, int y2offset, int rowTicks, int fakeRows) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addLayoutComponent
(Component component, Object constraint) void
addLayoutComponent
(String name, Component component) protected com.google.common.collect.Multimap<Integer,
TableGridLayout.Entry> Returns a map of Layer indices to Entries for the supplied list of components.float
getLayoutAlignmentX
(Container target) float
getLayoutAlignmentY
(Container target) void
invalidateLayout
(Container target) void
layoutContainer
(Container target) maximumLayoutSize
(Container target) minimumLayoutSize
(Container target) preferredLayoutSize
(Container target) void
removeLayoutComponent
(Component component)
-
Field Details
-
CONSTRAINT_KEY
Components should store their TableGridLayoutConstraint object as a user object with this key- See Also:
-
rows
protected int rows -
cols
protected int cols -
x1offset
protected int x1offset -
y1offset
protected int y1offset -
x2offset
protected int x2offset -
y2offset
protected int y2offset -
rowTicks
protected int rowTicks -
fakeRows
protected int fakeRows
-
-
Constructor Details
-
TableGridLayout
public TableGridLayout() -
TableGridLayout
public TableGridLayout(int rows, int cols, int x1offset, int y1offset, int x2offset, int y2offset, int rowTicks, int fakeRows)
-
-
Method Details
-
preferredLayoutSize
- Specified by:
preferredLayoutSize
in interfaceLayoutManager
-
minimumLayoutSize
- Specified by:
minimumLayoutSize
in interfaceLayoutManager
-
maximumLayoutSize
- Specified by:
maximumLayoutSize
in interfaceLayoutManager2
-
layoutContainer
- Specified by:
layoutContainer
in interfaceLayoutManager
-
getLayers
protected com.google.common.collect.Multimap<Integer,TableGridLayout.Entry> getLayers(List<Component> components) Returns a map of Layer indices to Entries for the supplied list of components. These components should haveTableGridLayoutConstraints
to determine what layer they belong to.- Parameters:
components
- A List of Components withTableGridLayoutConstraints
. May be empty, but not null.- Returns:
- A MultiMap of Layer indices to Entries. May be empty
-
addLayoutComponent
- Specified by:
addLayoutComponent
in interfaceLayoutManager
-
addLayoutComponent
- Specified by:
addLayoutComponent
in interfaceLayoutManager2
-
getLayoutAlignmentX
- Specified by:
getLayoutAlignmentX
in interfaceLayoutManager2
-
getLayoutAlignmentY
- Specified by:
getLayoutAlignmentY
in interfaceLayoutManager2
-
invalidateLayout
- Specified by:
invalidateLayout
in interfaceLayoutManager2
-
removeLayoutComponent
- Specified by:
removeLayoutComponent
in interfaceLayoutManager
-