Class ExperimentsScreen.ScrollArea
java.lang.Object
net.minecraft.client.gui.components.AbstractWidget
net.minecraft.client.gui.components.AbstractScrollArea
net.minecraft.client.gui.components.AbstractContainerWidget
net.minecraft.client.gui.screens.worldselection.ExperimentsScreen.ScrollArea
- All Implemented Interfaces:
ContainerEventHandler
,GuiEventListener
,Renderable
,TabOrderedElement
,LayoutElement
,NarratableEntry
,NarrationSupplier
,IAbstractWidgetExtension
- Enclosing class:
ExperimentsScreen
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.client.gui.narration.NarratableEntry
NarratableEntry.NarrationPriority
-
Field Summary
FieldsFields inherited from class net.minecraft.client.gui.components.AbstractScrollArea
SCROLLBAR_WIDTH
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
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addWidget
(AbstractWidget pWidget) List
<? extends GuiEventListener> children()
protected int
getBorderForArrowNavigation
(ScreenDirection p_388582_) getChildAt
(double p_94730_, double p_94731_) Returns the first event listener that intersects with the mouse coordinates.Collection
<? extends NarratableEntry> boolean
mouseClicked
(double p_313764_, double p_313832_, int p_313688_) Called when a mouse button is clicked within the GUI element.boolean
mouseReleased
(double p_313886_, double p_313935_, int p_313751_) Called when a mouse button is released within the GUI element.protected void
renderWidget
(GuiGraphics p_387127_, int p_388038_, int p_386932_, float p_388026_) protected double
void
setFocused
(GuiEventListener p_387564_) Sets the focus state of the GUI element.void
setX
(int p_388848_) void
setY
(int p_387427_) protected void
updateWidgetNarration
(NarrationElementOutput p_388854_) Methods inherited from class net.minecraft.client.gui.components.AbstractContainerWidget
getFocused, isDragging, isFocused, mouseDragged, nextFocusPath, setDragging, setFocused
Methods inherited from class net.minecraft.client.gui.components.AbstractScrollArea
maxScrollAmount, mouseScrolled, onRelease, refreshScrollAmount, renderScrollbar, scrollAmount, scrollbarVisible, scrollBarX, scrollBarY, scrollerHeight, setScrollAmount, updateScrolling
Methods 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, setHeight, setMessage, setRectangle, setSize, setTabOrderGroup, setTooltip, setTooltipDelay, setWidth, 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.ContainerEventHandler
charTyped, getCurrentFocusPath, keyPressed, keyReleased, mouseScrolled
Methods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
getRectangle, isMouseOver, mouseMoved
Methods inherited from interface net.neoforged.neoforge.client.extensions.IAbstractWidgetExtension
onClick
Methods inherited from interface net.minecraft.client.gui.layouts.LayoutElement
setPosition
Methods inherited from interface net.minecraft.client.gui.components.TabOrderedElement
getTabOrderGroup
-
Field Details
-
children
-
layout
-
-
Constructor Details
-
ScrollArea
-
-
Method Details
-
addWidget
-
contentHeight
protected int contentHeight()- Specified by:
contentHeight
in classAbstractScrollArea
-
scrollRate
protected double scrollRate()- Specified by:
scrollRate
in classAbstractScrollArea
-
renderWidget
- Specified by:
renderWidget
in classAbstractWidget
-
updateWidgetNarration
- Specified by:
updateWidgetNarration
in classAbstractWidget
-
setFocused
Description copied from interface:ContainerEventHandler
Sets the focus state of the GUI element.- Specified by:
setFocused
in interfaceContainerEventHandler
- Overrides:
setFocused
in classAbstractContainerWidget
- Parameters:
p_387564_
- the focused GUI element.
-
getChildAt
Description copied from interface:ContainerEventHandler
Returns the first event listener that intersects with the mouse coordinates. -
mouseClicked
public boolean mouseClicked(double p_313764_, double p_313832_, int p_313688_) Description copied from interface:GuiEventListener
Called when a mouse button is clicked within the GUI element.- Specified by:
mouseClicked
in interfaceContainerEventHandler
- Specified by:
mouseClicked
in interfaceGuiEventListener
- Overrides:
mouseClicked
in classAbstractContainerWidget
- Parameters:
p_313764_
- the X coordinate of the mouse.p_313832_
- the Y coordinate of the mouse.p_313688_
- the button that was clicked.- Returns:
true
if the event is consumed,false
otherwise.
-
mouseReleased
public boolean mouseReleased(double p_313886_, double p_313935_, int p_313751_) Description copied from interface:GuiEventListener
Called when a mouse button is released within the GUI element.- Specified by:
mouseReleased
in interfaceContainerEventHandler
- Specified by:
mouseReleased
in interfaceGuiEventListener
- Overrides:
mouseReleased
in classAbstractContainerWidget
- Parameters:
p_313886_
- the X coordinate of the mouse.p_313935_
- the Y coordinate of the mouse.p_313751_
- the button that was released.- Returns:
true
if the event is consumed,false
otherwise.
-
children
-
setX
public void setX(int p_388848_) - Specified by:
setX
in interfaceLayoutElement
- Overrides:
setX
in classAbstractWidget
-
setY
public void setY(int p_387427_) - Specified by:
setY
in interfaceLayoutElement
- Overrides:
setY
in classAbstractWidget
-
getNarratables
-