Package guideme.document.block
Class LytSlotGrid
java.lang.Object
guideme.document.block.LytNode
guideme.document.block.LytBlock
guideme.document.block.LytBox
guideme.document.block.LytSlotGrid
- All Implemented Interfaces:
LytBlockContainer,LytErrorSink,Styleable
-
Field Summary
Fields inherited from class guideme.document.block.LytBox
children, paddingBottom, paddingLeft, paddingRight, paddingTop -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic LytSlotGridcolumnFromDisplays(List<? extends net.minecraft.world.item.crafting.display.SlotDisplay> displays, boolean skipEmpty) static LytSlotGridcolumnFromIngredients(List<@Nullable net.minecraft.world.item.crafting.Ingredient> ingredients, boolean skipEmpty) static LytSlotGridcolumnFromStacks(List<net.minecraft.world.item.ItemStack> items, boolean skipEmpty) protected LytRectcomputeBoxLayout(LayoutContext context, int x, int y, int availableWidth) booleanvoidrender(RenderContext context) static LytSlotGridrowFromDisplays(List<? extends net.minecraft.world.item.crafting.display.SlotDisplay> displays, boolean skipEmpty) static LytSlotGridrowFromIngredients(List<@Nullable net.minecraft.world.item.crafting.Ingredient> ingredients, boolean skipEmpty) static LytSlotGridrowFromStacks(List<net.minecraft.world.item.ItemStack> items, boolean skipEmpty) voidsetDisplay(int x, int y, net.minecraft.world.item.crafting.display.SlotDisplay display) voidsetIngredient(int x, int y, Optional<net.minecraft.world.item.crafting.Ingredient> ingredient) voidsetIngredient(int x, int y, net.minecraft.world.item.crafting.Ingredient ingredient) voidsetItem(int x, int y, net.minecraft.world.item.ItemStack item) voidsetRenderEmptySlots(boolean renderEmptySlots) Methods inherited from class guideme.document.block.LytBox
append, clearContent, computeLayout, getBackgroundColor, getChildren, onLayoutMoved, removeChild, setBackgroundColor, setPadding, setPaddingBottom, setPaddingLeft, setPaddingRight, setPaddingTopMethods inherited from class guideme.document.block.LytBlock
getBorderBottom, getBorderLeft, getBorderRight, getBorderTop, getBounds, getMarginBottom, getMarginEnd, getMarginLeft, getMarginRight, getMarginStart, getMarginTop, isCulled, isFullWidth, layout, setBorder, setBorderBottom, setBorderLeft, setBorderRight, setBorderTop, setFullWidth, setLayoutPos, setMarginBottom, setMarginLeft, setMarginRight, setMarginTopMethods inherited from class guideme.document.block.LytNode
getDocument, getHoverStyle, getParent, getSourceNode, getStyle, getStylingParent, getTextContent, onMouseEnter, onMouseLeave, pickNode, setHoverStyle, setSourceNode, setStyle, tick, visit, visit, visitChildrenMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface guideme.document.block.LytBlockContainer
appendErrorMethods inherited from interface guideme.style.Styleable
modifyHoverStyle, modifyStyle, resolveHoverStyle, resolveStyle
-
Constructor Details
-
LytSlotGrid
public LytSlotGrid(int width, int height)
-
-
Method Details
-
columnFromStacks
public static LytSlotGrid columnFromStacks(List<net.minecraft.world.item.ItemStack> items, boolean skipEmpty) -
rowFromStacks
public static LytSlotGrid rowFromStacks(List<net.minecraft.world.item.ItemStack> items, boolean skipEmpty) -
columnFromIngredients
public static LytSlotGrid columnFromIngredients(List<@Nullable net.minecraft.world.item.crafting.Ingredient> ingredients, boolean skipEmpty) -
rowFromIngredients
public static LytSlotGrid rowFromIngredients(List<@Nullable net.minecraft.world.item.crafting.Ingredient> ingredients, boolean skipEmpty) -
columnFromDisplays
public static LytSlotGrid columnFromDisplays(List<? extends net.minecraft.world.item.crafting.display.SlotDisplay> displays, boolean skipEmpty) -
rowFromDisplays
public static LytSlotGrid rowFromDisplays(List<? extends net.minecraft.world.item.crafting.display.SlotDisplay> displays, boolean skipEmpty) -
isRenderEmptySlots
public boolean isRenderEmptySlots() -
setRenderEmptySlots
public void setRenderEmptySlots(boolean renderEmptySlots) -
computeBoxLayout
- Specified by:
computeBoxLayoutin classLytBox
-
setItem
public void setItem(int x, int y, net.minecraft.world.item.ItemStack item) -
setIngredient
public void setIngredient(int x, int y, net.minecraft.world.item.crafting.Ingredient ingredient) -
setIngredient
public void setIngredient(int x, int y, Optional<net.minecraft.world.item.crafting.Ingredient> ingredient) -
setDisplay
public void setDisplay(int x, int y, net.minecraft.world.item.crafting.display.SlotDisplay display) -
render
-