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
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, widthFields inherited from interface net.minecraft.client.gui.Element
MAX_DOUBLE_CLICK_INTERVAL -
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, eraseCharacters, eraseWords, getCursor, getInnerWidth, getMaxLength, getNarrationMessage, getNavigationPath, getSelectedText, getText, getWordSkipPosition, isInactive, isMouseOver, isValid, isVisible, keyPressed, mouseClicked, moveCursor, setCursor, setCursorToEnd, setCursorToStart, setSelectionEnd, setSelectionStart, setText, writeMethods inherited from class net.minecraft.client.gui.widget.ClickableWidget
appendDefaultNarrations, appendNarrations, clicked, drawScrollableText, drawScrollableText, drawScrollableText, forEachChild, getBottom, getHeight, getMessage, getNarrationMessage, getNavigationFocus, getNavigationOrder, getRight, getTooltip, getType, getWidth, getX, getY, isFocused, isHovered, isNarratable, isSelected, isValidClickButton, mouseDragged, mouseReleased, onClick, onDrag, onRelease, playDownSound, render, setAlpha, setDimensions, setDimensionsAndPosition, setFocused, setHeight, setMessage, setNavigationOrder, setTooltip, setTooltipDelay, setWidth, setX, setYMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.gui.Drawable
renderMethods inherited from interface net.minecraft.client.gui.Element
getFocusedPath, keyReleased, mouseMoved, mouseScrolledMethods 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 classTextInputWidget
-