< User:Watchout

103,861pages on
this wiki

Edit Box Edit

A user can input text into the edit box which can then be retrieved using the EditBox:GetText() function.

When you declare an edit box object make sure that you include a FontString element which defines the Font which is used to display the text inputted into the EditBox. Otherwise EditBox will not display any text or being able to receive text input from the user, instead it would just display a portion of the blinking cursor (when focused)

<EditBox name="TestEditBox">
      .. Size
      .. Anchors
      .. Layers
      .. ecc.
      <FontString inherits="GameFontNormal"/>

On multi-line and EditBox:SetHeight() Edit

Note that multi-line EditBoxes will ignore any attempts to set its height via :SetHeight() or via Dimension attributes in XML. They will start out the height of a single line of text, and keep expanding their area as needed. This effect becomes visible if the editbox has a backdrop set, or a texture anchored to its corners.

Explicitly setting the top and bottom anchors with :SetPoint() will however size it like expected, but the text will still expand below the borders. (The effect will be similar to html elements positioned absolutely with width/height restricted)

XML Edit


Attributes Edit

  • letters (int; default=0)
  • blinkSpeed (float; default=0.5)
  • numeric (boolean; default=false)
  • password (boolean; default=false)
  • multiline (boolean; default=false)
  • historyLines (int; default=0)
  • autoFocus (boolean; default=true)
  • ignoreArrows (boolean; default=false)

Elements Edit


Methods Edit

Event Handlers Edit

Around Wikia's network

Random Wiki