public class GTextArea extends GComponent implements KeyListener, GDisplay, GClear, GTextAreaInterface
GComponent.CopyPasteOperation, GComponent.DisplayIndicatorStatus, GComponent.ItemType, GComponent.OperationNAME_ATTRIBUTE| Constructor and Description |
|---|
GTextArea()
Constructor.
|
GTextArea(String widgetId)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
append(String text)
Appends the text to the text area.
|
void |
appendLine(String line)
Adds the text to the text area with adding a carriage return at the end.
|
void |
appendNewLine()
Adds an empty new line to the text area.
|
void |
clear()
Called when the element is to be cleared, so it can perform the actions required to return to the last
saved/loaded values.
|
void |
display()
Called when the element is to be displayed, so it can perform the actions required for its display, and
the display of its inmmediate descendants.
|
Component |
getComponent()
Returns the low level Swing Component encapsulated by the class if any, otherwise returns
null.
|
JTextArea |
getJTextArea()
Get the JTextArea associated with the component.
|
String |
getText()
Get the string of text area.
|
boolean |
isCursorPositionAtBottom()
Get if the cursor shall be always at the bottom.
|
boolean |
isEditable()
Returns the boolean indicating whether this TextComponent is editable or not.
|
void |
keyPressed(KeyEvent e) |
void |
keyReleased(KeyEvent e) |
void |
keyTyped(KeyEvent ev) |
void |
reset()
Called when the element is to be reset, so it can perform the actions required to return to inital
state.
|
void |
setCursorPositionAtBottom(boolean flag)
Set if the cursor shall be always at the bottom.
|
void |
setDefaultText(String text)
Set the default string of text area.
|
void |
setEditable(boolean b)
Sets the specified boolean to indicate whether or not this TextComponent should be editable.
|
void |
setEnabled(boolean flag)
Set the enable status of the component.
|
void |
setLineWrap(boolean flag)
Sets the specified boolean to indicate whether the lines are wrapped in the widget or not.
|
void |
setText(String text)
Set the string of text area.
|
void |
setToolTipText(String text)
Set the tooltip text for the entry's label.
|
activateConstraintsByType, attachCopyPasteMenu, attachCopyPasteMenu, beginOfElement, beginOfElement, beginOfElement, beginOfElement, clearAllInnerDescendantConstraint, clearConstraint, clearInnerDescendantContraint, composeWidgetId, doDisplay, endOfElement, getCommentInConfigFile, getConstraint, getCurrentOperation, getDisplayIndicatorStatus, getDisplayIsModifiedIndicator, getElement, getGClassName, getGPanel, getGParent, getGUnitInConfigFile, getInnerDescendantConstraint, getName, getNameInConfigFile, getOperationSaveValue, getPathInConfigFile, getSimpleWidgetId, getStatus, getStringConstraint, getSubComponent, getWidgetId, handleCopyPasteEvent, handleCopyPasteEvent, handleProcessEventException, isCopyPasteEvent, isEnabled, isForcedStatus, isModified, launchInvalidPositionException, mouseWheelMoved, parseSimpleConstraint, processGEvent, processMouseWheelEvent, setBusyCursor, setCommentInConfigFile, setConstraint, setCopyPasteMenuEnabled, setCurrentOperation, setDataForConstraintsByType, setDefaultConstraints, setDisplayIsModifiedIndicator, setElement, setForcedStatus, setGPanel, setGParent, setGUnitInConfigFile, setInnerDescendantConstraint, setName, setNameAndCommentInConfigFile, setNameInConfigFile, setPathInConfigFile, setStatus, setStringConstraint, setWidgetId, setWidth, setWindowBusyCursor, updateIsModifiedIndicator, writeCollection, writeCollection, writeCollection, writeCollection, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItempublic GTextArea()
public GTextArea(String widgetId)
widgetId - widget identifier.public void keyTyped(KeyEvent ev)
keyTyped in interface KeyListenerpublic void keyPressed(KeyEvent e)
keyPressed in interface KeyListenerpublic void keyReleased(KeyEvent e)
keyReleased in interface KeyListenerpublic void appendLine(String line)
appendLine in interface GTextAreaInterfaceline - to be appended to the text area.public void appendNewLine()
public void setEditable(boolean b)
setEditable in interface GTextAreaInterfaceb - the boolean to be setpublic boolean isEditable()
public void append(String text)
text - to be appended to the text area.public void setEnabled(boolean flag)
setEnabled in class GComponentflag - new enable status of the component.public void display()
public Component getComponent()
getComponent in class GComponentpublic JTextArea getJTextArea()
getJTextArea in interface GTextAreaInterfacepublic void setText(String text)
text - the string of text area.public void setLineWrap(boolean flag)
setLineWrap in interface GTextAreaInterfaceflag - true if the lines shall be wrapped, false otherwise.public void setDefaultText(String text)
text - the string of text area.public String getText()
public void clear()
public void setToolTipText(String text)
setToolTipText in class GComponenttext - the tooltip text for the entry's label.public void setCursorPositionAtBottom(boolean flag)
setCursorPositionAtBottom in interface GTextAreaInterfaceflag - true it the cursor shall always be at the bottom of the text view, false otherwise.public boolean isCursorPositionAtBottom()
public void reset()
reset in interface GTextAreaInterfaceCopyright © 2024. All rights reserved.