Class ImageButtonPrefab


public class ImageButtonPrefab extends ImagePrefab
Prefab for image buttons in the UI.
  • Field Details

  • Constructor Details

    • ImageButtonPrefab

      public ImageButtonPrefab(String imagePath)
    • ImageButtonPrefab

      public ImageButtonPrefab(Texture image)
  • Method Details

    • setPadding

      public void setPadding(Dimension x, Dimension y)
    • setPadding

      public void setPadding(DualDimension padding)
    • setClickCallback

      public void setClickCallback(ButtonData.ClickCallback callback)
    • setTextColors

      public void setTextColors(Color normal, Color hover)
    • setTextColor

      public void setTextColor(Color color)
    • setTextHoverColor

      public void setTextHoverColor(Color color)
    • setBackgroundColors

      public void setBackgroundColors(Color normal, Color hover)
    • setBackgroundColor

      public void setBackgroundColor(Color color)
    • setBackgroundHoverColor

      public void setBackgroundHoverColor(Color color)
    • apply

      protected void apply(Entity entity)
      Description copied from class: Prefab
      Adds this prefab's predefined components to a given entity and copies values from this prefab.
      Overrides:
      apply in class ImagePrefab