Class MessageDialogBuilder

java.lang.Object
com.googlecode.lanterna.gui2.dialogs.MessageDialogBuilder

public class MessageDialogBuilder extends Object
Dialog builder for the MessageDialog class, use this to create instances of that class and to customize them
  • Field Details

  • Constructor Details

    • MessageDialogBuilder

      public MessageDialogBuilder()
      Default constructor
  • Method Details

    • build

      public MessageDialog build()
      Builds a new MessageDialog from the properties in the builder
      Returns:
      Newly build MessageDialog
    • setTitle

      public MessageDialogBuilder setTitle(String title)
      Sets the title of the MessageDialog
      Parameters:
      title - New title of the message dialog
      Returns:
      Itself
    • setText

      public MessageDialogBuilder setText(String text)
      Sets the main text of the MessageDialog
      Parameters:
      text - Main text of the MessageDialog
      Returns:
      Itself
    • setExtraWindowHints

      public MessageDialogBuilder setExtraWindowHints(Collection<Window.Hint> extraWindowHints)
      Assigns a set of extra window hints that you want the built dialog to have
      Parameters:
      extraWindowHints - Window hints to assign to the window in addition to the ones the builder will put
      Returns:
      Itself
    • addButton

      public MessageDialogBuilder addButton(MessageDialogButton button)
      Adds a button to the dialog
      Parameters:
      button - Button to add to the dialog
      Returns:
      Itself