Class ColorInputWidget
java.lang.Object
net.minecraft.client.gui.widget.ClickableWidget
net.uku3lig.ukulib.config.option.widget.TextInputWidget
net.uku3lig.ukulib.config.option.widget.ColorInputWidget
- All Implemented Interfaces:
net.minecraft.client.gui.Drawable,net.minecraft.client.gui.Element,net.minecraft.client.gui.Narratable,net.minecraft.client.gui.navigation.Navigable,net.minecraft.client.gui.Selectable,net.minecraft.client.gui.widget.Widget,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 interface net.minecraft.client.gui.Selectable
net.minecraft.client.gui.Selectable.SelectionType -
Field Summary
Fields inherited from class net.minecraft.client.gui.widget.ClickableWidget
active, alpha, height, hovered, 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 TypeMethodDescriptionvoidrenderWidget(net.minecraft.client.gui.DrawContext drawContext, int mouseX, int mouseY, float delta) Methods inherited from class net.uku3lig.ukulib.config.option.widget.TextInputWidget
appendClickableNarrations, charTyped, drawsBackground, eraseCharacters, eraseCharactersTo, eraseWords, getCursor, getInnerWidth, getNarrationMessage, getSelectedText, getText, getWordSkipPosition, isActive, isValid, isVisible, keyPressed, moveCursor, onClick, onDrag, playDownSound, setCursor, setCursorToEnd, setCursorToStart, setFocused, setSelectionEnd, setSelectionStart, setText, setX, setY, writeMethods inherited from class net.minecraft.client.gui.widget.ClickableWidget
appendDefaultNarrations, appendNarrations, drawScrollableText, drawScrollableText, drawScrollableText, forEachChild, getBottom, getHeight, getMessage, getNarrationMessage, getNavigationFocus, getNavigationOrder, getNavigationPath, getRight, getType, getWidth, getX, getY, isFocused, isHovered, isInteractable, isMouseOver, isSelected, isValidClickButton, mouseClicked, mouseDragged, mouseReleased, onRelease, playClickSound, render, setAlpha, setDimensions, setDimensionsAndPosition, setHeight, setMessage, setNavigationOrder, setTooltip, setTooltipDelay, setWidthMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.gui.Element
getBorder, getFocusedPath, isClickable, keyReleased, mouseMoved, mouseScrolledMethods inherited from interface net.minecraft.client.gui.Selectable
getNarratedPartsMethods inherited from interface net.minecraft.client.gui.widget.Widget
setPosition
-
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
-
renderWidget
public void renderWidget(net.minecraft.client.gui.DrawContext drawContext, int mouseX, int mouseY, float delta) - Overrides:
renderWidgetin classnet.uku3lig.ukulib.config.option.widget.TextInputWidget
-