password

Password Class

The password class extends TextField and adds the ability to set a mask character.

It uses the standard 3 constructors as shown in the Quick Start Guide.

Constructor 1:

/** Parameters:
  * Screen screen,
  * String UID,
  * Vector2f position
  */

Password pw = new Password(screen, "password", new Vector2f(15, 15));

Constructor 2:

/** Additional Parameter:
  * Vector2f dimensions  */

Password pw = new Password(screen, "password", new Vector2f(15, 15),
    new Vector2f(150, 25)
);

Constructor 3:

/** Additional Parameters:
  * Vector4f resizeBorders,
  * String defaultImg
  */

Password pw = new Password(screen, "password", new Vector2f(15, 15), new Vector2f(150, 25),
    new Vector4f(3,3,3,3),
    "tonegod/gui/style/def/TextField/text_field_x.png"
);

Password specific methods:

pw.setMask(char mask);
pw.getMask(); // Returns mask character as a String