| org.itsnat.comp.ui.ItsNatTextComponentUI
All known Subclasses: org.itsnat.impl.comp.html.ui.ItsNatHTMLTextBasedUIImpl,
ItsNatTextComponentUI | public interface ItsNatTextComponentUI extends ItsNatElementComponentUI(Code) | | Is the base interface of the User Interface of a text based header.
Current
org.itsnat.comp.ItsNatTextComponent implementations are based on
<input type="text"> and <textarea> elements, in both cases the
value attribute/property is used to save the text as markup
(the textarea version is a bit more complicated because the first value
is set as the element text content too).
author: Jose Maria Arranz Santamaria See Also: ItsNatTextComponent.getItsNatTextComponentUI |
Method Summary | |
public ItsNatTextComponent | getItsNatTextComponent() Returns the associated component object. | public String | getText() Returns the current text saved in markup. | public void | insertString(int where, String str) Inserts the specified string into the markup. | public boolean | isEditable() Returns whether the component user interface is editable or read-only. | public void | removeString(int where, int len) Removes the specified text fragment from the markup. | public void | setEditable(boolean b) Sets the element as editable or read-only. | public void | setText(String text) Renders the specified text to the markup. |
getItsNatTextComponent | public ItsNatTextComponent getItsNatTextComponent()(Code) | | Returns the associated component object.
the component object. |
getText | public String getText()(Code) | | Returns the current text saved in markup.
the current text saved in markup. |
isEditable | public boolean isEditable()(Code) | | Returns whether the component user interface is editable or read-only.
true if the component UI is editable. |
removeString | public void removeString(int where, int len)(Code) | | Removes the specified text fragment from the markup.
Parameters: where - position start of the fragment to remove (0 based). Parameters: len - the number of characters to remove. See Also: ItsNatTextComponentUI.insertString(int,String) See Also: |
setEditable | public void setEditable(boolean b)(Code) | | Sets the element as editable or read-only.
Current implementation calls the methods HTMLInputElement.setReadOnly(boolean)
and HTMLTextAreaElement.setReadOnly(boolean) accordingly.
|
setText | public void setText(String text)(Code) | | Renders the specified text to the markup.
Parameters: text - the new text. |
|
|