Class ColorInputWidget
java.lang.Object
net.minecraft.client.gui.components.AbstractWidget
net.uku3lig.ukulib.config.option.widget.TextInputWidget
net.uku3lig.ukulib.config.option.widget.ColorInputWidget
- All Implemented Interfaces:
net.minecraft.client.gui.components.events.GuiEventListener, net.minecraft.client.gui.components.Renderable, net.minecraft.client.gui.components.TabOrderedElement, net.minecraft.client.gui.layouts.LayoutElement, net.minecraft.client.gui.narration.NarratableEntry, net.minecraft.client.gui.narration.NarrationSupplier, CheckedOption
public class ColorInputWidget
extends net.uku3lig.ukulib.config.option.widget.TextInputWidget
A widget that allows the user to input a color.
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.client.gui.components.AbstractWidget
net.minecraft.client.gui.components.AbstractWidget.WithInactiveMessageNested classes/interfaces inherited from interface net.minecraft.client.gui.narration.NarratableEntry
net.minecraft.client.gui.narration.NarratableEntry.NarrationPriority -
Field Summary
Fields inherited from class net.minecraft.client.gui.components.AbstractWidget
active, alpha, height, isHovered, message, visible, width -
Constructor Summary
ConstructorsConstructorDescriptionColorInputWidget(int x, int y, int width, int height, int initialValue, IntConsumer changedListener, String suggestion, boolean allowAlpha) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoidextractWidgetRenderState(@NotNull net.minecraft.client.gui.GuiGraphicsExtractor graphics, int mouseX, int mouseY, float delta) Methods inherited from class net.uku3lig.ukulib.config.option.widget.TextInputWidget
canConsumeInput, charTyped, createNarrationMessage, drawsBackground, eraseCharacters, eraseCharactersTo, eraseWords, getCursor, getInnerWidth, getSelectedText, getText, getWordSkipPosition, isValid, isVisible, keyPressed, moveCursor, onClick, onDrag, playDownSound, setCursor, setCursorToEnd, setCursorToStart, setFocused, setSelectionEnd, setSelectionStart, setText, setX, setY, updateWidgetNarration, writeMethods inherited from class net.minecraft.client.gui.components.AbstractWidget
defaultButtonNarrationText, extractRenderState, extractScrollingStringOverContents, extractTooltipForNextRenderPass, getAlpha, getBottom, getHeight, getMessage, getRectangle, getRight, getTabOrderGroup, getWidth, getX, getY, handleCursor, isActive, isFocused, isHovered, isHoveredOrFocused, isMouseOver, isValidClickButton, mouseClicked, mouseDragged, mouseReleased, narrationPriority, nextFocusPath, onRelease, playButtonClickSound, setAlpha, setHeight, setMessage, setRectangle, setSize, setTabOrderGroup, setTooltip, setTooltipDelay, setWidth, updateNarration, visitWidgets, wrapDefaultNarrationMessageMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
getBorderForArrowNavigation, getCurrentFocusPath, keyReleased, mouseMoved, mouseScrolled, preeditUpdated, shouldTakeFocusAfterInteractionMethods inherited from interface net.minecraft.client.gui.layouts.LayoutElement
setPositionMethods inherited from interface net.minecraft.client.gui.narration.NarratableEntry
getNarratables
-
Constructor Details
-
ColorInputWidget
public ColorInputWidget(int x, int y, int width, int height, int initialValue, IntConsumer changedListener, String suggestion, boolean allowAlpha) Constructor.- Parameters:
x- the x positiony- the y positionwidth- the widthheight- the heightinitialValue- the initial valuechangedListener- the listener that is called when the value changessuggestion- the suggestionallowAlpha- whether to allow changing the alpha value
-
-
Method Details
-
extractWidgetRenderState
public void extractWidgetRenderState(@NotNull @NotNull net.minecraft.client.gui.GuiGraphicsExtractor graphics, int mouseX, int mouseY, float delta) - Overrides:
extractWidgetRenderStatein classnet.uku3lig.ukulib.config.option.widget.TextInputWidget
-