Class Checkbox

java.lang.Object
net.mcreator.element.parts.gui.GUIComponent
net.mcreator.element.parts.gui.Checkbox
All Implemented Interfaces:
Comparable<GUIComponent>

public class Checkbox extends GUIComponent
  • Field Details

    • name

      public final String name
    • text

      public final String text
    • isCheckedProcedure

      public final Procedure isCheckedProcedure
  • Constructor Details

  • Method Details

    • getName

      public String getName()
      Description copied from class: GUIComponent
      Returns the name of the component. Name should be Java and registry name compatible.

      The name should be unique for the components that need it.

      Specified by:
      getName in class GUIComponent
      Returns:
      Component name
    • paintComponent

      public void paintComponent(int cx, int cy, WYSIWYGEditor wysiwygEditor, Graphics2D g)
      Specified by:
      paintComponent in class GUIComponent
    • getWidth

      public int getWidth(Workspace workspace)
      Specified by:
      getWidth in class GUIComponent
    • getHeight

      public int getHeight(Workspace workspace)
      Specified by:
      getHeight in class GUIComponent
    • getWeight

      public int getWeight()
      Description copied from class: GUIComponent
      Returns the priority for when this component should be drawn in the UI, to represent how Minecraft draws components in the game.
      Specified by:
      getWeight in class GUIComponent
      Returns:
      The priority of the component (lower means it will be rendered closer to the screen and higher means it will "sink" more behind other components)