Class SpriteIconButton
java.lang.Object
net.minecraft.client.gui.components.AbstractWidget
net.minecraft.client.gui.components.AbstractButton
net.minecraft.client.gui.components.Button
net.minecraft.client.gui.components.SpriteIconButton
- All Implemented Interfaces:
GuiEventListener
,Renderable
,TabOrderedElement
,LayoutElement
,NarratableEntry
,NarrationSupplier
- Direct Known Subclasses:
SpriteIconButton.CenteredIcon
,SpriteIconButton.TextAndIcon
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
static class
Nested classes/interfaces inherited from class net.minecraft.client.gui.components.Button
Button.CreateNarration, Button.OnPress
Nested classes/interfaces inherited from interface net.minecraft.client.gui.narration.NarratableEntry
NarratableEntry.NarrationPriority
-
Field Summary
Modifier and TypeFieldDescriptionprotected final ResourceLocation
protected final int
protected final int
Fields inherited from class net.minecraft.client.gui.components.Button
BIG_WIDTH, createNarration, DEFAULT_HEIGHT, DEFAULT_NARRATION, DEFAULT_SPACING, DEFAULT_WIDTH, onPress, SMALL_WIDTH
Fields inherited from class net.minecraft.client.gui.components.AbstractButton
SPRITES, TEXT_MARGIN
Fields inherited from class net.minecraft.client.gui.components.AbstractWidget
active, alpha, height, isHovered, packedFGColor, UNSET_FG_COLOR, visible, width
Fields inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
DOUBLE_CLICK_THRESHOLD_MS
-
Constructor Summary
ConstructorDescriptionSpriteIconButton
(int p_297620_, int p_300275_, Component p_297544_, int p_298263_, int p_299223_, ResourceLocation p_297738_, Button.OnPress p_297736_, Button.CreateNarration p_335316_) -
Method Summary
Modifier and TypeMethodDescriptionstatic SpriteIconButton.Builder
builder
(Component p_299964_, Button.OnPress p_301369_, boolean p_298501_) Methods inherited from class net.minecraft.client.gui.components.Button
builder, createNarrationMessage, onPress, updateWidgetNarration
Methods inherited from class net.minecraft.client.gui.components.AbstractButton
keyPressed, onClick, renderString, renderWidget
Methods inherited from class net.minecraft.client.gui.components.AbstractWidget
clearFGColor, clicked, defaultButtonNarrationText, getBottom, getFGColor, getHeight, getMessage, getRectangle, getRight, getTabOrderGroup, getTooltip, getWidth, getX, getY, isActive, isFocused, isHovered, isHoveredOrFocused, isMouseOver, isValidClickButton, mouseClicked, mouseDragged, mouseReleased, narrationPriority, nextFocusPath, onDrag, onRelease, playDownSound, render, renderScrollingString, renderScrollingString, renderScrollingString, setAlpha, setFGColor, setFocused, setHeight, setMessage, setRectangle, setSize, setTabOrderGroup, setTooltip, setTooltipDelay, setWidth, setX, setY, updateNarration, visitWidgets, wrapDefaultNarrationMessage
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
charTyped, getCurrentFocusPath, keyReleased, mouseMoved, mouseScrolled
Methods inherited from interface net.minecraft.client.gui.layouts.LayoutElement
setPosition
-
Field Details
-
sprite
-
spriteWidth
protected final int spriteWidth -
spriteHeight
protected final int spriteHeight
-
-
Constructor Details
-
SpriteIconButton
SpriteIconButton(int p_297620_, int p_300275_, Component p_297544_, int p_298263_, int p_299223_, ResourceLocation p_297738_, Button.OnPress p_297736_, @Nullable Button.CreateNarration p_335316_)
-
-
Method Details
-
builder
public static SpriteIconButton.Builder builder(Component p_299964_, Button.OnPress p_301369_, boolean p_298501_)
-