API:TextEditBoxSetAllowEditing
From RoR Wiki
UI Lua API · TextEditBox functions
Version: WAR 1.4.8
Sets whether the player may edit the text of a TextEditBox.
TextEditBoxSetAllowEditing(editBoxName, allowEditing)
Arguments
- editBoxName
string– Name of a TextEditBox window.- allowEditing
boolean–trueto allow editing,falseto make the box read-only.
Returns
Nothing.
Details
- The value is stored in the box's allow-editing flag, which TextEditBoxGetAllowEditing returns.
- If a certain state flag of the box is set when the call is made, the client also updates the box and its child windows right away.
- The stock guild recruiting profile uses it to make its text fields read-only for players who lack the guild's
SET_RECRUITERSpermission. allowEditingmust be a real boolean. Passingnilor a number raises an Invalid Parameters error.- The function needs at least two arguments and only reads the last two.
Errors
These are written to the UI log; the call returns normally.
Error in function call 'TextEditBoxSetAllowEditing': Window %s does not existError in function call 'TextEditBoxSetAllowEditing': Window %s is not a TextEditBox
Example
From ea_guildwindow/source/guildwindowtabrecruitprofile.lua:
-- Brief Description TextEditBoxSetAllowEditing( "GWRecruitProfileDescEditBox", not disabled ) -- Public Summary TextEditBoxSetAllowEditing( "GWRecruitProfileSummaryEditBox", not disabled )
