Class ButtonWidget

All Implemented Interfaces:
Drawable, Element, Narratable, Navigable, Selectable, Widget
Direct Known Subclasses:
LockButtonWidget, MerchantScreen.WidgetButtonPage, PageTurnWidget, PressableTextWidget, RealmsCreateWorldScreen.FrameButton, RealmsWorldSlotButton, TextIconButtonWidget, TexturedButtonWidget

@Environment(CLIENT) public class ButtonWidget extends PressableWidget
Mappings:
Namespace Name
named net/minecraft/client/gui/widget/ButtonWidget
intermediary net/minecraft/class_4185
official foe
  • Field Details

    • DEFAULT_WIDTH_SMALL

      public static final int DEFAULT_WIDTH_SMALL
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named DEFAULT_WIDTH_SMALL Lnet/minecraft/client/gui/widget/ButtonWidget;DEFAULT_WIDTH_SMALL:I
      intermediary field_39499 Lnet/minecraft/class_4185;field_39499:I
      official f Lfoe;f:I
    • DEFAULT_WIDTH

      public static final int DEFAULT_WIDTH
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named DEFAULT_WIDTH Lnet/minecraft/client/gui/widget/ButtonWidget;DEFAULT_WIDTH:I
      intermediary field_39500 Lnet/minecraft/class_4185;field_39500:I
      official m Lfoe;m:I
    • field_49479

      public static final int field_49479
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named field_49479 Lnet/minecraft/client/gui/widget/ButtonWidget;field_49479:I
      intermediary field_49479 Lnet/minecraft/class_4185;field_49479:I
      official n Lfoe;n:I
    • DEFAULT_HEIGHT

      public static final int DEFAULT_HEIGHT
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named DEFAULT_HEIGHT Lnet/minecraft/client/gui/widget/ButtonWidget;DEFAULT_HEIGHT:I
      intermediary field_39501 Lnet/minecraft/class_4185;field_39501:I
      official o Lfoe;o:I
    • field_46856

      public static final int field_46856
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named field_46856 Lnet/minecraft/client/gui/widget/ButtonWidget;field_46856:I
      intermediary field_46856 Lnet/minecraft/class_4185;field_46856:I
      official p Lfoe;p:I
    • DEFAULT_NARRATION_SUPPLIER

      protected static final ButtonWidget.NarrationSupplier DEFAULT_NARRATION_SUPPLIER
      Mappings:
      Namespace Name Mixin selector
      named DEFAULT_NARRATION_SUPPLIER Lnet/minecraft/client/gui/widget/ButtonWidget;DEFAULT_NARRATION_SUPPLIER:Lnet/minecraft/client/gui/widget/ButtonWidget$NarrationSupplier;
      intermediary field_40754 Lnet/minecraft/class_4185;field_40754:Lnet/minecraft/class_4185$class_7841;
      official q Lfoe;q:Lfoe$b;
    • onPress

      protected final ButtonWidget.PressAction onPress
      Mappings:
      Namespace Name Mixin selector
      named onPress Lnet/minecraft/client/gui/widget/ButtonWidget;onPress:Lnet/minecraft/client/gui/widget/ButtonWidget$PressAction;
      intermediary field_22767 Lnet/minecraft/class_4185;field_22767:Lnet/minecraft/class_4185$class_4241;
      official r Lfoe;r:Lfoe$c;
    • narrationSupplier

      protected final ButtonWidget.NarrationSupplier narrationSupplier
      Mappings:
      Namespace Name Mixin selector
      named narrationSupplier Lnet/minecraft/client/gui/widget/ButtonWidget;narrationSupplier:Lnet/minecraft/client/gui/widget/ButtonWidget$NarrationSupplier;
      intermediary field_40755 Lnet/minecraft/class_4185;field_40755:Lnet/minecraft/class_4185$class_7841;
      official s Lfoe;s:Lfoe$b;
  • Constructor Details

    • ButtonWidget

      protected ButtonWidget(int x, int y, int width, int height, Text message, ButtonWidget.PressAction onPress, ButtonWidget.NarrationSupplier narrationSupplier)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/client/gui/widget/ButtonWidget;<init>(IIIILnet/minecraft/text/Text;Lnet/minecraft/client/gui/widget/ButtonWidget$PressAction;Lnet/minecraft/client/gui/widget/ButtonWidget$NarrationSupplier;)V
      intermediary <init> Lnet/minecraft/class_4185;<init>(IIIILnet/minecraft/class_2561;Lnet/minecraft/class_4185$class_4241;Lnet/minecraft/class_4185$class_7841;)V
      official <init> Lfoe;<init>(IIIILxv;Lfoe$c;Lfoe$b;)V
  • Method Details

    • builder

      public static ButtonWidget.Builder builder(Text message, ButtonWidget.PressAction onPress)
      Mappings:
      Namespace Name Mixin selector
      named builder Lnet/minecraft/client/gui/widget/ButtonWidget;builder(Lnet/minecraft/text/Text;Lnet/minecraft/client/gui/widget/ButtonWidget$PressAction;)Lnet/minecraft/client/gui/widget/ButtonWidget$Builder;
      intermediary method_46430 Lnet/minecraft/class_4185;method_46430(Lnet/minecraft/class_2561;Lnet/minecraft/class_4185$class_4241;)Lnet/minecraft/class_4185$class_7840;
      official a Lfoe;a(Lxv;Lfoe$c;)Lfoe$a;
    • onPress

      public void onPress()
      Specified by:
      onPress in class PressableWidget
      Mappings:
      Namespace Name Mixin selector
      named onPress Lnet/minecraft/client/gui/widget/PressableWidget;onPress()V
      intermediary method_25306 Lnet/minecraft/class_4264;method_25306()V
      official b Lfnv;b()V
    • getNarrationMessage

      protected MutableText getNarrationMessage()
      Overrides:
      getNarrationMessage in class ClickableWidget
      Mappings:
      Namespace Name Mixin selector
      named getNarrationMessage Lnet/minecraft/client/gui/widget/ClickableWidget;getNarrationMessage()Lnet/minecraft/text/MutableText;
      intermediary method_25360 Lnet/minecraft/class_339;method_25360()Lnet/minecraft/class_5250;
      official aR_ Lfoc;aR_()Lyj;
    • appendClickableNarrations

      public void appendClickableNarrations(NarrationMessageBuilder builder)
      Specified by:
      appendClickableNarrations in class ClickableWidget
      Mappings:
      Namespace Name Mixin selector
      named appendClickableNarrations Lnet/minecraft/client/gui/widget/ClickableWidget;appendClickableNarrations(Lnet/minecraft/client/gui/screen/narration/NarrationMessageBuilder;)V
      intermediary method_47399 Lnet/minecraft/class_339;method_47399(Lnet/minecraft/class_6382;)V
      official a Lfoc;a(Lfsc;)V