<baseedittext>

JavaScript: lz.baseedittext
This component provides the look and feel for user editable text, data binding, and focus events.

Attributes

Name (CSS property) Type (tag) Type (js) Default Category
fontsize expression any 13 read/write
  Font size of the text.
height expression any 20 read/write
  The height of the edit text box.
maxlength number Number null read/write
  The maximum number of chars that can be entered. Default is unlimited.
multiline expression any false read/write
  Set to true for multiple lines.
password expression any false initialize-only
  Set to true for a password field. Text will appear as ****. This attribute cannot be changed at runtime.
pattern string String null read/write
  An expression to restrict the set of characters that are allowed to be entered. For example, [0-9]*, [012]*, [a-zA-Z]*, [0-9A-Z]*. You can restrict the number of characters using maxlength. Default is any character.
text html lz.html   read/write
  The text that appears in the component. Text and value are the same.
value expression any null read/write
  The text that appears in the component. Text and value are the same.
width expression any 106 read/write
  The width of the edit text box.

Attributes inherited from <basevaluecomponent>

type, value

Methods

clearText()
baseedittext.clearText(isinitvalue : Boolean);
Clears the text field.
Parameter Name Type Description
isinitvalue Boolean if true, clear and set empty string as initial value..

doSetValue()
baseedittext.doSetValue(value : String, isinitvalue : Boolean, _ignorecalldown);
Set the value (text) of baseedittext.
Parameter Name Type Description
value String the string to set.
isinitvalue Boolean if the string is an initvalue.
_ignorecalldown    

getSelectionPosition()
baseedittext.getSelectionPosition();
Get the current selection position.

getSelectionSize()
baseedittext.getSelectionSize();
Get the current selection size.

getText()
baseedittext.getText();
Returns the text displayed in this component. The same as calling getValue(false).
Returns Type Description
  String the string displayed.

getValue()
baseedittext.getValue();
Returns string displayed in this component. Also see getText().
Returns Type Description
  String the text string in input box.

setMaxlength()
baseedittext.setMaxlength(n);
Parameter Name Type Description
n    

setPattern()
baseedittext.setPattern(r);
Parameter Name Type Description
r    

setSelection()
baseedittext.setSelection(start : Number, end : Number);
Positions the text selection within the text field. If this object does not already have the focus, this has the ancillary effect of giving it the focus.
Parameter Name Type Description
start Number The beginning of the text selection, or the position for the text cursor if no end is given. The index is 0 based.
end Number (optional) The end of the text selection. If not given, then the text cursor is positioned at the start point, but no text is selected.

setText()
baseedittext.setText(t : String, isinitvalue : Boolean);
Set text. Wraps doSetValue().
Parameter Name Type Description
t String text to set.
isinitvalue Boolean if the text to set is an initvalue.

Methods inherited from lz.Eventable

destroy, setAttribute

Events

Name Description
onpattern  
onvalue Sent when the value of the text changes.

Events inherited from <baseformitem>

onchanged, onvalue

Events inherited from <node>

onconstruct, ondata, oninit

Events inherited from lz.Eventable

ondestroy