Class Styles.TextButtonStyle

java.lang.Object
com.badlogic.gdx.scenes.scene2d.ui.Button.ButtonStyle
com.github.tommyettinger.textra.Styles.TextButtonStyle
Direct Known Subclasses:
Styles.CheckBoxStyle, Styles.ImageTextButtonStyle
Enclosing class:
Styles

public static class Styles.TextButtonStyle extends com.badlogic.gdx.scenes.scene2d.ui.Button.ButtonStyle
The style for a text button, see TextraButton or TypingButton.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    com.badlogic.gdx.graphics.Color
     
    com.badlogic.gdx.graphics.Color
     
    com.badlogic.gdx.graphics.Color
     
    com.badlogic.gdx.graphics.Color
     
    com.badlogic.gdx.graphics.Color
     
    com.badlogic.gdx.graphics.Color
     
    com.badlogic.gdx.graphics.Color
     
     
    com.badlogic.gdx.graphics.Color
     
    com.badlogic.gdx.graphics.Color
     

    Fields inherited from class com.badlogic.gdx.scenes.scene2d.ui.Button.ButtonStyle

    checked, checkedDown, checkedFocused, checkedOffsetX, checkedOffsetY, checkedOver, disabled, down, focused, over, pressedOffsetX, pressedOffsetY, unpressedOffsetX, unpressedOffsetY, up
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    TextButtonStyle(com.badlogic.gdx.scenes.scene2d.ui.TextButton.TextButtonStyle style)
    Deprecated.
    Create a Font from your BitmapFont once and pass that to constructors instead.
    TextButtonStyle(com.badlogic.gdx.scenes.scene2d.utils.Drawable up, com.badlogic.gdx.scenes.scene2d.utils.Drawable down, com.badlogic.gdx.scenes.scene2d.utils.Drawable checked, com.badlogic.gdx.graphics.g2d.BitmapFont font)
    Deprecated.
    Create a Font from your BitmapFont once and pass that to constructors instead.
    TextButtonStyle(com.badlogic.gdx.scenes.scene2d.utils.Drawable up, com.badlogic.gdx.scenes.scene2d.utils.Drawable down, com.badlogic.gdx.scenes.scene2d.utils.Drawable checked, Font font)
     
     
  • Method Summary

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • font

      @Null public Font font
    • fontColor

      @Null public com.badlogic.gdx.graphics.Color fontColor
    • downFontColor

      @Null public com.badlogic.gdx.graphics.Color downFontColor
    • overFontColor

      @Null public com.badlogic.gdx.graphics.Color overFontColor
    • focusedFontColor

      @Null public com.badlogic.gdx.graphics.Color focusedFontColor
    • disabledFontColor

      @Null public com.badlogic.gdx.graphics.Color disabledFontColor
    • checkedFontColor

      @Null public com.badlogic.gdx.graphics.Color checkedFontColor
    • checkedDownFontColor

      @Null public com.badlogic.gdx.graphics.Color checkedDownFontColor
    • checkedOverFontColor

      @Null public com.badlogic.gdx.graphics.Color checkedOverFontColor
    • checkedFocusedFontColor

      @Null public com.badlogic.gdx.graphics.Color checkedFocusedFontColor
  • Constructor Details

    • TextButtonStyle

      public TextButtonStyle()
    • TextButtonStyle

      public TextButtonStyle(@Null com.badlogic.gdx.scenes.scene2d.utils.Drawable up, @Null com.badlogic.gdx.scenes.scene2d.utils.Drawable down, @Null com.badlogic.gdx.scenes.scene2d.utils.Drawable checked, @Null Font font)
    • TextButtonStyle

      @Deprecated public TextButtonStyle(@Null com.badlogic.gdx.scenes.scene2d.utils.Drawable up, @Null com.badlogic.gdx.scenes.scene2d.utils.Drawable down, @Null com.badlogic.gdx.scenes.scene2d.utils.Drawable checked, @Null com.badlogic.gdx.graphics.g2d.BitmapFont font)
      Deprecated.
      Create a Font from your BitmapFont once and pass that to constructors instead.
      You should almost always avoid calling this constructor directly, because it allocates a new Font object every time (copying information from the given BitmapFont), and it isn't easy to dispose the created Font.
      Parameters:
      up - may be null; drawn when the button is "up"
      down - may be null; drawn when the button is "down"
      checked - may be null; drawn when the button is "checked"
      font - a BitmapFont that will be copied into a new Font
    • TextButtonStyle

      public TextButtonStyle(Styles.TextButtonStyle style)
    • TextButtonStyle

      @Deprecated public TextButtonStyle(com.badlogic.gdx.scenes.scene2d.ui.TextButton.TextButtonStyle style)
      Deprecated.
      Create a Font from your BitmapFont once and pass that to constructors instead.
      You should almost always avoid calling this constructor directly, because it allocates a new Font object every time (copying information from the given style), and it isn't easy to dispose the created Font.
      Parameters:
      style - a Label.LabelStyle that will have its data and BitmapFont copied into this and its Font