Archived Legacy DynamicHUD
  • Dynamic HUD
  • Import using Gradle
  • Widgets
    • Adding Widgets
      • TextWidget
      • ItemWidget
      • ArmorWidget
    • Creating your own Widget class
    • Widget class
    • WidgetManager
    • WidgetBox
  • Saving and Loading
    • Saving and Loading
    • Changing save file name and directory
  • Moveable Screen
    • AbstractMoveableScreen
    • Default Moveable Screen
    • Using the default Moveable Screen
    • Creating and using your own MoveableScreen class
  • ContextMenu
    • ContextMenu class
    • ContextMenuOptionsProvider interface
    • DoubleInputScreen
    • DataInputScreen
  • Slider Widget
    • Slider
  • SliderWidgetBuilder
  • ColorPicker
    • ColorGradientPicker
      • ColorPickerButton
      • GradientBox
      • GradientSlider
  • Helpers
    • ColorHelper
    • DrawHelper
    • TextureHelper
Powered by GitBook
On this page
  • DoubleInputScreen
  • Fields
  • Constructors
  • Methods
  1. ContextMenu

DoubleInputScreen

This page talks about DoubleInputScreen class

PreviousContextMenuOptionsProvider interfaceNextDataInputScreen

DoubleInputScreen

The class extends the Screen class and represents a screen that allows the user to enter a double value.

Fields

  • consumer: The consumer that accepts the entered double value.

  • textField: The text field widget for entering the double value.

  • x, y: The position of the text field widget.

  • parentScreen: The parent screen of this screen.

  • doubleInputOption: The double input option associated with this screen.

Constructors

  • DoubleInputScreen(Consumer<Double> consumer, int x, int y, Screen parentScreen, ContextMenu.DoubleInputOption doubleInputOption): Constructs a DoubleInputScreen object with the given consumer, position, parent screen and double input option.

Methods

  • init(): Initializes this screen by creating a text field widget for entering the double value.

  • keyPressed(int keyCode, int scanCode, int modifiers): Handles key presses on this screen. Closes the screen and passes the entered data to the consumer when the Enter key is pressed.

  • shouldPause(): Returns whether this screen should pause the game.

DoubleInputScreen