Package net.minecraft.client.gui.layouts
Class LinearLayout
java.lang.Object
net.minecraft.client.gui.layouts.LinearLayout
- All Implemented Interfaces:
Layout
,LayoutElement
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate int
private final LinearLayout.Orientation
private final GridLayout
-
Constructor Summary
ConstructorsModifierConstructorDescriptionLinearLayout
(int width, int height, LinearLayout.Orientation orientation) private
LinearLayout
(LinearLayout.Orientation orientation) -
Method Summary
Modifier and TypeMethodDescription<T extends LayoutElement>
TaddChild
(T child) <T extends LayoutElement>
TaddChild
(T child, Consumer<LayoutSettings> layoutSettingsFactory) <T extends LayoutElement>
TaddChild
(T child, LayoutSettings layoutSettings) void
int
int
getWidth()
int
getX()
int
getY()
static LinearLayout
void
setX
(int x) void
setY
(int y) spacing
(int spacing) static LinearLayout
vertical()
void
visitChildren
(Consumer<LayoutElement> visitor) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.client.gui.layouts.Layout
visitWidgets
Methods inherited from interface net.minecraft.client.gui.layouts.LayoutElement
getRectangle, setPosition
-
Field Details
-
wrapped
-
orientation
-
nextChildIndex
private int nextChildIndex
-
-
Constructor Details
-
LinearLayout
-
LinearLayout
-
-
Method Details
-
spacing
-
newCellSettings
-
defaultCellSetting
-
addChild
-
addChild
-
addChild
public <T extends LayoutElement> T addChild(T child, Consumer<LayoutSettings> layoutSettingsFactory) -
visitChildren
- Specified by:
visitChildren
in interfaceLayout
-
arrangeElements
public void arrangeElements()- Specified by:
arrangeElements
in interfaceLayout
-
getWidth
public int getWidth()- Specified by:
getWidth
in interfaceLayoutElement
-
getHeight
public int getHeight()- Specified by:
getHeight
in interfaceLayoutElement
-
setX
public void setX(int x) - Specified by:
setX
in interfaceLayoutElement
-
setY
public void setY(int y) - Specified by:
setY
in interfaceLayoutElement
-
getX
public int getX()- Specified by:
getX
in interfaceLayoutElement
-
getY
public int getY()- Specified by:
getY
in interfaceLayoutElement
-
vertical
-
horizontal
-