java.lang.Object
net.minecraft.client.gui.components.AbstractWidget
org.hiedacamellia.immersiveui.client.gui.component.widget.tree.TreeEntryWidget<T>
所有已实现的接口:
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, net.neoforged.neoforge.client.extensions.IAbstractWidgetExtension
直接已知子类:
DebugTreeEntryWidget, WheelTreeEntryWidget

public class TreeEntryWidget<T> extends net.minecraft.client.gui.components.AbstractWidget
  • 嵌套类概要

    从接口继承的嵌套类/接口 net.minecraft.client.gui.narration.NarratableEntry

    net.minecraft.client.gui.narration.NarratableEntry.NarrationPriority
  • 字段概要

    字段
    修饰符和类型
    字段
    说明
    protected List<TreeEntryWidget<T>>
     
    protected T
     
    protected boolean
     
    protected final net.minecraft.network.chat.Component
     
    protected int
     
    protected net.minecraft.client.gui.Font
     
    protected boolean
     
    protected TreeEntryWidget<T>
     
    protected int
     
    protected int
     
     
    protected final net.minecraft.network.chat.Component
     

    从类继承的字段 net.minecraft.client.gui.components.AbstractWidget

    active, alpha, height, isHovered, packedFGColor, UNSET_FG_COLOR, visible, width

    从接口继承的字段 net.minecraft.client.gui.components.events.GuiEventListener

    DOUBLE_CLICK_THRESHOLD_MS
  • 构造器概要

    构造器
    构造器
    说明
    TreeEntryWidget(net.minecraft.network.chat.Component message, net.minecraft.client.gui.Font font)
     
  • 方法概要

    修饰符和类型
    方法
    说明
    void
     
    void
    addChild(int index, TreeEntryWidget<T> child)
     
    void
     
    void
     
    getAt(double mouseX, double mouseY)
     
     
     
    getWidgetAt(double mouseX, double mouseY)
     
    boolean
     
    void
     
    boolean
    isHovered(double mouseX, double mouseY)
     
    boolean
     
    boolean
    mouseClicked(double mouseX, double mouseY, int button)
     
    void
    moveChild(TreeEntryWidget<T> child, int index)
     
    static <T> TreeEntryWidget<T>
    of(T data, net.minecraft.network.chat.Component component, net.minecraft.client.gui.Font font)
     
    void
     
    protected void
    renderChildren(net.minecraft.client.gui.GuiGraphics guiGraphics, int mouseX, int mouseY, float v)
     
    protected void
    renderWidget(net.minecraft.client.gui.GuiGraphics guiGraphics, int mouseX, int mouseY, float v)
     
    void
    setData(T data)
     
    boolean
    shouldAccept(double mouseX, double mouseY)
     
    boolean
    shouldChangeFold(double mouseX, double mouseY, int button)
     
    void
     
    void
     
    void
     
    protected void
    updateWidgetNarration(net.minecraft.client.gui.narration.NarrationElementOutput narrationElementOutput)
     

    从类继承的方法 net.minecraft.client.gui.components.AbstractWidget

    clearFGColor, clicked, createNarrationMessage, defaultButtonNarrationText, getBottom, getFGColor, getHeight, getMessage, getRectangle, getRight, getTabOrderGroup, getTooltip, getWidth, getX, getY, isActive, isFocused, isHovered, isHoveredOrFocused, isMouseOver, isValidClickButton, mouseDragged, mouseReleased, narrationPriority, nextFocusPath, onClick, onDrag, onRelease, playDownSound, render, renderScrollingString, renderScrollingString, renderScrollingString, setAlpha, setFGColor, setFocused, setHeight, setMessage, setRectangle, setSize, setTabOrderGroup, setTooltip, setTooltipDelay, setWidth, setX, setY, updateNarration, visitWidgets, wrapDefaultNarrationMessage

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    从接口继承的方法 net.minecraft.client.gui.components.events.GuiEventListener

    charTyped, getCurrentFocusPath, keyPressed, keyReleased, mouseMoved, mouseScrolled

    从接口继承的方法 net.neoforged.neoforge.client.extensions.IAbstractWidgetExtension

    onClick

    从接口继承的方法 net.minecraft.client.gui.layouts.LayoutElement

    setPosition
  • 字段详细资料

    • font

      protected net.minecraft.client.gui.Font font
    • fold

      protected boolean fold
    • parent

      protected TreeEntryWidget<T> parent
    • children

      protected List<TreeEntryWidget<T>> children
    • data

      protected T data
    • isRoot

      protected boolean isRoot
    • tree

      protected TreeWidget<T,TreeEntryWidget<T>> tree
    • selfWidth

      protected int selfWidth
    • selfHeight

      protected int selfHeight
    • foldWidth

      protected int foldWidth
    • foldComponent

      protected final net.minecraft.network.chat.Component foldComponent
    • unfoldComponent

      protected final net.minecraft.network.chat.Component unfoldComponent
  • 构造器详细资料

    • TreeEntryWidget

      public TreeEntryWidget(net.minecraft.network.chat.Component message, net.minecraft.client.gui.Font font)
  • 方法详细资料

    • tree

      public void tree(TreeWidget<T,TreeEntryWidget<T>> tree)
    • getTree

      public TreeWidget<T,TreeEntryWidget<T>> getTree()
    • isRoot

      public boolean isRoot()
    • insert

      public void insert(TreeEntryWidget<T> widget)
    • getAt

      public TreeEntryWidget<T> getAt(double mouseX, double mouseY)
    • getWidgetAt

      public TreeEntryWidget<T> getWidgetAt(double mouseX, double mouseY)
    • shouldAccept

      public boolean shouldAccept(double mouseX, double mouseY)
    • accept

      public void accept(TreeEntryWidget<T> widget)
    • of

      public static <T> TreeEntryWidget<T> of(T data, net.minecraft.network.chat.Component component, net.minecraft.client.gui.Font font)
    • addChild

      public void addChild(int index, TreeEntryWidget<T> child)
    • addChild

      public void addChild(TreeEntryWidget<T> child)
    • removeChild

      public void removeChild(TreeEntryWidget<T> child)
    • moveChild

      public void moveChild(TreeEntryWidget<T> child, int index)
    • hasChild

      public boolean hasChild()
    • setData

      public void setData(T data)
    • getData

      public T getData()
    • fold

      public void fold()
    • unfold

      public void unfold()
    • updateWidget

      public void updateWidget()
    • shouldChangeFold

      public boolean shouldChangeFold(double mouseX, double mouseY, int button)
    • mouseClicked

      public boolean mouseClicked(double mouseX, double mouseY, int button)
      指定者:
      mouseClicked 在接口中 net.minecraft.client.gui.components.events.GuiEventListener
      覆盖:
      mouseClicked 在类中 net.minecraft.client.gui.components.AbstractWidget
    • isHovered

      public boolean isHovered(double mouseX, double mouseY)
    • renderWidget

      protected void renderWidget(net.minecraft.client.gui.GuiGraphics guiGraphics, int mouseX, int mouseY, float v)
      指定者:
      renderWidget 在类中 net.minecraft.client.gui.components.AbstractWidget
    • renderChildren

      protected void renderChildren(net.minecraft.client.gui.GuiGraphics guiGraphics, int mouseX, int mouseY, float v)
    • updateWidgetNarration

      protected void updateWidgetNarration(net.minecraft.client.gui.narration.NarrationElementOutput narrationElementOutput)
      指定者:
      updateWidgetNarration 在类中 net.minecraft.client.gui.components.AbstractWidget