Class ConfigurationScreen.ConfigurationListScreen.ListLabelWidget
java.lang.Object
net.minecraft.client.gui.components.AbstractWidget
net.minecraft.client.gui.components.AbstractScrollArea
net.minecraft.client.gui.components.AbstractContainerWidget
net.neoforged.neoforge.client.gui.ConfigurationScreen.ConfigurationListScreen.ListLabelWidget
- All Implemented Interfaces:
ContainerEventHandler,GuiEventListener,Renderable,TabOrderedElement,LayoutElement,NarratableEntry,NarrationSupplier,IAbstractWidgetExtension
- Enclosing class:
ConfigurationScreen.ConfigurationListScreen<T>
public class ConfigurationScreen.ConfigurationListScreen.ListLabelWidget
extends AbstractContainerWidget
A widget to be used as a label in a list of configuration values.
It includes buttons for "move element up", "move element down", and "delete element" as well as a label.
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.client.gui.narration.NarratableEntry
NarratableEntry.NarrationPriority -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Buttonprotected final Buttonprotected final intprotected final booleanprotected final booleanprotected final StringWidgetprotected final ButtonFields inherited from class net.minecraft.client.gui.components.AbstractScrollArea
SCROLLBAR_WIDTHFields inherited from class net.minecraft.client.gui.components.AbstractWidget
active, alpha, height, isHovered, packedFGColor, UNSET_FG_COLOR, visible, widthFields inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
DOUBLE_CLICK_THRESHOLD_MS -
Constructor Summary
ConstructorsConstructorDescriptionListLabelWidget(int x, int y, int width, int height, Component labelText, int idx) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidList<? extends GuiEventListener> children()protected int(package private) void(package private) voidprotected voidrenderWidget(GuiGraphics pGuiGraphics, int pMouseX, int pMouseY, float pPartialTick) protected doublevoidsetHeight(int pHeight) voidsetSize(int pWidth, int pHeight) voidsetWidth(int pWidth) voidsetX(int pX) voidsetY(int pY) (package private) voidprotected voidprotected voidupdateWidgetNarration(NarrationElementOutput pNarrationElementOutput) Methods inherited from class net.minecraft.client.gui.components.AbstractContainerWidget
getFocused, isDragging, isFocused, mouseClicked, mouseDragged, mouseReleased, nextFocusPath, setDragging, setFocused, setFocusedMethods inherited from class net.minecraft.client.gui.components.AbstractScrollArea
maxScrollAmount, mouseScrolled, onRelease, refreshScrollAmount, renderScrollbar, scrollAmount, scrollbarVisible, scrollBarX, scrollBarY, scrollerHeight, setScrollAmount, updateScrollingMethods inherited from class net.minecraft.client.gui.components.AbstractWidget
clearFGColor, createNarrationMessage, defaultButtonNarrationText, getBottom, getFGColor, getHeight, getMessage, getRectangle, getRight, getTabOrderGroup, getTooltip, getWidth, getX, getY, isActive, isHovered, isHoveredOrFocused, isMouseOver, isValidClickButton, narrationPriority, onClick, onDrag, playButtonClickSound, playDownSound, render, renderScrollingString, renderScrollingString, renderScrollingString, setAlpha, setFGColor, setMessage, setRectangle, setTabOrderGroup, setTooltip, setTooltipDelay, updateNarration, visitWidgets, wrapDefaultNarrationMessageMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.gui.components.events.ContainerEventHandler
charTyped, getChildAt, getCurrentFocusPath, keyPressed, keyReleased, mouseScrolledMethods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
getBorderForArrowNavigation, getRectangle, isMouseOver, mouseMovedMethods inherited from interface net.neoforged.neoforge.client.extensions.IAbstractWidgetExtension
onClickMethods inherited from interface net.minecraft.client.gui.layouts.LayoutElement
setPositionMethods inherited from interface net.minecraft.client.gui.narration.NarratableEntry
getNarratablesMethods inherited from interface net.minecraft.client.gui.components.TabOrderedElement
getTabOrderGroup
-
Field Details
-
upButton
-
downButton
-
delButton
-
label
-
idx
protected final int idx -
isFirst
protected final boolean isFirst -
isLast
protected final boolean isLast
-
-
Constructor Details
-
ListLabelWidget
-
-
Method Details
-
setX
public void setX(int pX) - Specified by:
setXin interfaceLayoutElement- Overrides:
setXin classAbstractWidget
-
setY
public void setY(int pY) - Specified by:
setYin interfaceLayoutElement- Overrides:
setYin classAbstractWidget
-
setHeight
public void setHeight(int pHeight) - Overrides:
setHeightin classAbstractWidget
-
setWidth
public void setWidth(int pWidth) - Overrides:
setWidthin classAbstractWidget
-
setSize
public void setSize(int pWidth, int pHeight) - Overrides:
setSizein classAbstractWidget
-
updateLayout
protected void updateLayout() -
up
-
down
-
rem
-
children
-
renderWidget
- Specified by:
renderWidgetin classAbstractWidget
-
checkButtons
protected void checkButtons() -
updateWidgetNarration
- Specified by:
updateWidgetNarrationin classAbstractWidget
-
contentHeight
protected int contentHeight()- Specified by:
contentHeightin classAbstractScrollArea
-
scrollRate
protected double scrollRate()- Specified by:
scrollRatein classAbstractScrollArea
-