public abstract class Editor<O extends OutputManager<?>> extends LabeledDataContainer<O,EditorConfig> implements TextSelection
Besides what was known from Progress manuals, the following facts describe some peculiarities in the redirected output found experimentally:
| Modifier and Type | Class and Description |
|---|---|
protected static class |
Editor.Line
Internal text representation element.
|
protected class |
Editor.LocalFocusListener
Some actions on focus hanging.
|
| Modifier and Type | Field and Description |
|---|---|
protected static char |
CR
Carrage return character.
|
protected boolean |
forceRedraw
Flag indicating if the processed event forced a re-draw.
|
protected boolean |
insert
Insert mode.
|
protected static char |
LF
line feed character
|
protected java.lang.StringBuilder |
lineBuilder
The internal work buffer to do string manipulations.
|
private static int |
MAX_SIZE
Maximum capacity of the editor.
|
protected static java.util.Map<java.lang.Integer,java.lang.Integer> |
maxSizes
Max data size in widget.
|
protected java.util.List<Editor.Line> |
parsedText
Editor content parsed into separate string.
|
private static java.util.regex.Pattern |
RTRIM
trailing spaces
|
private java.lang.String |
savedContent
Saved content of the current screen value.
|
protected static java.lang.String |
SPACE
single space string
|
protected static java.lang.String |
SPACE_LF
space & lf
|
protected boolean |
widgetFocused
Widget in focus flag.
|
configlisteners, location, mousePtr, nativeInsets, physicalLocation| Constructor and Description |
|---|
Editor(WidgetId id,
EditorConfig cfg)
Special constructor used to restore component using given configuration.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract int |
absoluteX()
Get absolute horizontal position in text.
|
protected int |
absoluteY()
Get absolute vertical position in text.
|
protected java.lang.String |
addIndent(java.lang.String line,
int indentSize)
Add indent consisting of spaces to the beginning of the specified line.
|
protected void |
backspace()
Handle BACKSPACE key.
|
protected void |
bell()
Handle BELL event.
|
boolean |
canMovetoTop()
Flag indicating if this widget can be moved to top by a DISPLAY statement when WINDOW:KEEP-FRAME-Z-ORDER
flag is set.
|
protected boolean |
canPlaceChar()
Determine if a character can be placed in the editor.
|
void |
clear()
Clear input variable.
|
int |
contentLength()
Gets the actual content length (not the LENGTH attribute).
|
Widget<O> |
currentFocus()
Returns this component directly because it is not a container (it has no child
components.
|
protected void |
cursorBeginOfLine()
Move cursor to beginning of the line.
|
protected void |
cursorDown()
Move cursor one row down, if possible.
|
protected void |
cursorEndOfLine()
Move cursor to the end of line.
|
protected void |
cursorEndOfPrevLine()
Move the cursor to the end of the previous line.
|
protected void |
cursorHome()
Move cursor to the start position.
|
protected void |
cursorLeft()
Move cursor one char left, if possible.
|
private void |
cursorPageDown()
Scroll one page down.
|
private void |
cursorPageUp()
Scroll one page up.
|
protected void |
cursorPos(int pos)
Split absolute horizontal cursor position into two components - position
of the first visible character and relative cursor position in the
visible region.
|
protected void |
cursorRight()
Move cursor one char right.
|
protected void |
cursorRightTo(int shift)
Shift cursor to the right within current line.
|
protected void |
cursorUp()
Move cursor one row up, if possible.
|
Widget<O> |
defaultFocus()
Returns this component directly because it is not a container (it has no child
components.
|
protected boolean |
deleteCharacter()
Delete character at current cursor position.
|
protected void |
deleteCharacterKey()
Delete character at current cursor position - called by
processKeyEvent(com.goldencode.p2j.ui.client.event.KeyInput). |
boolean |
deleteLine()
Delete the line of text in which the cursor currently resides.
|
private boolean |
deleteLineWorker()
Delete the line of text in which the cursor currently resides.
|
protected boolean |
deleteToEndOfLine()
Delete to end of line.
|
void |
draw()
Draws text.
|
abstract void |
draw(Color color)
Actual drawing routine.
|
void |
drawCaret()
Sets position of terminal's cursor.
|
abstract void |
drawCaretUnconditionally()
Sets position of terminal's cursor unconditionally (even if this editor is not in focus).
|
boolean |
editorReadFile(java.lang.String name)
Loads the file from the client side filesystem.
|
boolean |
editorSaveFile(java.lang.String name)
Save the content in the widgets in the client side filesystem.
|
private int |
findRow(int pos)
Find row number for a position
|
protected void |
fireValueChanged()
No-op for ChUI.
|
boolean |
focusTraversable()
This component will receive an input focus when Tab or Shift-Tab is
pressed.
|
int |
fullHeight()
Returns the number of lines the editor is holding.
|
BaseDataType |
getChangedValue()
Getting the BaseDataType object representing the current value change since last call.
|
int |
getCursorChar()
Gets the cursor in the current line
|
int |
getCursorLine()
Gets the cursor liner
|
int |
getCursorOffset()
Gets the cursor offset
|
protected FocusListener |
getFocusListener()
Get the focus listener instance.
|
protected int |
getIndentSize(java.lang.String line)
Calculate the size of the line indent, which is the number of leading spaces.
|
int |
getLength()
Gets the content length, compatible with the LENGTH attribute.
|
protected Editor.Line |
getLine()
Get reference to the line under absolute cursor position.
|
int |
getLineCount()
Obtain the number of current lines displayed (parsed) by this editor.
|
java.lang.String |
getLineText(int k)
Obtain the text displayed on a specified line.
|
protected int |
getMaxSize()
Maximal size of the content in chars.
|
protected abstract int |
getNextSplitPosition(java.lang.String line,
int splitAfter)
Get the next split position of this line, so that it fits the editor.
|
java.lang.String |
getText()
Get screen representation of the data.
|
BaseDataType |
getValue()
Getting the BaseDataType object representing the current value.
|
protected abstract boolean |
goToNewLine(java.lang.String subtext,
boolean placeChar)
Check if the given text needs to output on a new line.
|
void |
initialize(WidgetId id,
EditorConfig cfg)
Replacement API for the logic which should exist in the widget's c'tor, but the logic
can't be executed as it depends on the widget being registered into the official registry.
|
private int |
inSameLime(int start,
int end)
Check if there are now LFs between positions
|
protected abstract boolean |
insertBlankLineOnLF()
Determine if a blank line needs to be inserted when RETURN key is pressed on a empty line.
|
boolean |
insertFile(java.lang.String fileNameToLoad)
Inserts content of a file at the current cursor position.
|
boolean |
insertString(java.lang.String txt)
Inserts string at the current cursor position.
|
protected int |
lastRow()
Maximal value of the absolute Y coordinate.
|
boolean |
manageSystemActions()
Check if the current widget can manage non-global system actions on its own, and not via the
enclosing event loop.
|
protected abstract void |
mergeLines(int row)
Merge line with subsequent one(s) if possible
|
protected void |
parseContent(java.lang.String source,
int row,
boolean placeChar)
Parse content of the editor and prepare array of displayable values.
|
protected java.util.List<Editor.Line> |
parseContentImpl(java.lang.String source,
int start,
int offset,
boolean placeChar)
Worker to parse content of the editor and prepare array of displayable values.
|
protected void |
placeChar(char ch)
Place character at current cursor position.
|
protected void |
placeChar(char ch,
boolean ignoreReadonly)
Place character at current cursor position.
|
protected void |
placeLF()
Place new line character at current cursor position.
|
private void |
placeStringInt(java.lang.String text)
Place string at current cursor position.
|
private void |
placeStringSegment(java.lang.String text)
Place string at current cursor position for the current line.
|
private void |
placeStringSegmentWrap(java.lang.String text)
Place string at current cursor position for the current line.
|
protected abstract java.lang.String |
processEOLChars(java.lang.String src)
Processing for unusual EOL characters in different UI modes.
|
void |
processKeyEvent(KeyInput ke)
Process KeyEvents for this widget.
|
protected void |
refresh()
Refresh the editor.
|
private boolean |
replaceInterval(int start,
int end,
java.lang.String txt)
Replace subinterval of the editor content
|
boolean |
replaceSelectionText(java.lang.String txt)
Replace selection of the editor content with a given string.
|
boolean |
replaceString(java.lang.String from,
java.lang.String to,
int flag)
Replace given substring of the editor content with a given string
|
void |
requestFocus()
Requesting the focus to the widget.
|
protected java.lang.String |
resolveContent()
Get a string representation of this editor's content.
|
protected java.lang.String |
rtrim(java.lang.String value)
Remove trailing whitespaces
|
java.lang.Boolean |
search(java.lang.String pattern,
int mode)
Searches for a specified string starting from the current text caret position.
|
boolean |
setCursorChar(int pos)
Sets the cursor position in the current line
|
boolean |
setCursorChar(int pos,
boolean redraw)
Sets the cursor position in the current line
|
boolean |
setCursorLine(int line)
Sets the cursor line
|
protected boolean |
setCursorLineAndChar(int line,
int offset)
Sets the cursor line offset
|
boolean |
setCursorOffset(int offset)
Sets the cursor offset.
|
boolean |
setCursorOffset(int offset,
boolean shouldInvalidateSelection)
Sets the cursor offset.
|
boolean |
setSelection(int start,
int end)
Selects text in a widget between start and end points.
|
void |
setValue(BaseDataType value)
Sets the new variable value in the editor.
|
protected void |
splitLine(java.lang.String line,
int row,
int splitAfter)
Replace line, splitting it if necessary
|
protected void |
updateOffset()
Update widget content;
|
afterConfigUpdate, config, copyState, defaultMousePtr, destroy, getColon, getColumnLabelText, getColumnMnemonic, getLabelInstance, getLabelText, getMnemonic, getTo, isForceLabel, isModified, isNoLabels, isRightAligned, postprocessConfig, setColumnMnemonic, setHidden, setLabelInstance, setMnemonic, setNoLabels, setVisible, setWasVisible, wasVisibleminimumSize, requestFocusadd, add, add, addContainerStateListener, addDirectly, belongsTo, checkWidget, childrenLocation, clipping, clipRectangle, currentFocus, cycleFocus, deregisterSelectedWidget, detach, dimension, doLayout, dumpCurrentWidgets, dumpWidgets, endSizeChange, findMouseSource, firstFocus, focus, focusWorker, formatDump, get, getAllSelectedWidgets, getClipRect, getEffectiveScrollableSize, getFocusInt, getIgnoreFocus, getLayout, getScrollableSize, getTabItemList, hasFocusable, height, insets, lastFocus, moveAfterTabItem, moveBeforeTabItem, moveToBottom, moveToBottomInClass, moveToTop, moveToTopInClass, moveToZpos, nextFocus, normalizeZOrder, onWidgetAdded, onWidgetRemoved, paintOnTop, parentOf, prepareWidgets, prevFocus, reflectAncestorChange, reflectLocationChanged, registerSelectedWidget, remove, removeContainerStateListener, repaint, replace, requestFocus, setFocus, setFocusInt, setHeight, setIgnoreFocus, setInsets, setLayout, setPhysicalDimensionInt, setSize, setSize, setTabItemList, setWidth, startSizeChange, swap, triggerContainerStateRedrawEnabled, unrealize, updateSizeWorker, widgets, widgetsAsList, widgetStateChanged, width_setHidden, _setVisible, activateDirectManipulation, addFocusListener, addKeyListener, afterConfigUpdateBase, ancestor, ancestorId, autoResize, bounds, clear, clearWidget, clipRectangle, clipRectangle, clipWith, copyColors, createMouseHoverAction, deactivateDirectManipulation, debug, disable, disableTooltip, displayPhysicalLocation, enable, enableTooltip, enclosingFrame, forceCursorOnFocus, forceVisibility, getActualBounds, getAndResetBitmap, getAndSetBitmap, getBitmapCopy, getCachedScreenLocation, getCachedScreenPhysicalLocation, getCustomMousePointer, getDefaultEvent, getEffectiveMousePointer, getId, getLoadedMousePointer, getMenuMouse, getMouseActions, getMousePosition, getPortableMouseEventCoordinates, getSelectedText, getState, getTextHeight, getTextHeightNative, getTextHeightNative, getTextWidth, getTextWidth, getTextWidthNative, getTextWidthNative, getVisiblePart, getZOrderClass, hasFocus, hasTooltip, hidden, hide, highlighted, ignoreAction, initialHeight, initialWidth, isCurrent, isDirectManipulationActive, isDirectManipulationActiveOrInUIB, isDirectManipulationCapable, isDirectManipulationRequired, isDisplayed, isEnabled, isFocusable, isHeader, isMouseDrag, isRealized, isRepaintDisabled, isRMBEntrySupported, isScreenLocationCached, isTabStop, isThreeD, isTotallyObscured, isVisible, isVisible, location, mouseActions, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, mouseWheelMoved, moveToBottom, moveToTop, name, navigable, oleDoDrop, oleDrag, oleDragging, oleStartDragging, onOleDragging, onOleDropEnd, parent, parent, parentObject, parentOrSelf, parentOrSelfObject, physicalBounds, physicalDimension, physicalLocation, prepParentLocation, preventFocusWhenMouseDownEventDefined, processDirectManipulationEvent, processEvent, processFocusEvent, processKeyEventForSelectableWidget, processKeyListeners, processMnemonic, processMnemonicImpl, processSystemKey, raiseLegacyMouseEvents, reflectSizeChanged, refresh, registerWidgetListener, repaint, repaint, requestSync, resetBitmap, resizeTo, resolveFont, resolvePopupMenuId, resolveTitleFont, screen, screenDimension, screenHeight, screenLocation, screenPhysicalLocation, screenWidth, setBitmap, setCachedScreenLocation, setCachedScreenPhysicalLocation, setDirectManipulationActive, setEnabled, setHighlighted, setLocation, setLocation, setMousePointer, setMousePointer, setParent, setPhysicalLocation, setSensitiveForUIB, setState, setWindow, show, showPopupMenu, supportsCustomMousePointer, sync, topLevelWindow, toString, translate, triggerLocationChanged, unregisterWidgetListener, updateSystemParent, widgetRealized, windowclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waiteditPaste, invalidateSelection, isEditCanUndo, isSelectionValid, removeSelectedTextacceptsEscAsAnyKey, acceptTrigger, addFocusListener, addKeyListener, ancestor, ancestorId, bounds, clearWidget, completeTrigger, dimension, displayPhysicalLocation, enclosingFrame, enforceDefaultMousePtr, findMouseSource, forceCursorOnFocus, forceVisibility, getActualBounds, getCustomMousePointer, getEffectiveMousePointer, getId, getIdForTrigger, getLegacyWidget, getLoadedMousePointer, getMenuMouse, getMouseActions, getMousePosition, getSelectedText, getState, getTriggerWidget, getTriggerWidget, getVisiblePart, getZOrderClass, hasFocus, hasFocus, hasTooltip, height, hidden, hide, highlighted, ignoreEnable, initialHeight, initialWidth, insets, isCurrent, isCurrent, isDirectManipulable, isDirectManipulationActive, isDirectManipulationActiveOrInUIB, isDisplayed, isDroppable, isEnabled, isFocusable, isHeader, isInitialValueLayout, isLegacyFocus, isProcessProgressEvent, isRealized, isRepaintDisabled, isRMBEntrySupported, isTabStop, isThreeD, isTotallyObscured, isVisible, isVisible, location, maySwitchFocus, minimumSize, moveToBottom, moveToTop, name, navigable, oleDrag, parent, parent, parent, parentObject, parentOrSelf, parentOrSelfObject, physicalBounds, physicalDimension, physicalLocation, preventFocusWhenMouseDownEventDefined, processDirectManipulationEvent, processEvent, processFocusEvent, processKeyListeners, processMnemonic, raiseLegacyMouseEvents, refreshWidget, registerWidgetListener, repaint, repaint, repaint, requestFocus, requestFocus, requestSync, resizeTo, resolvePopupMenuId, screen, screenLocation, screenPhysicalLocation, setDirectManipulationActive, setEnabled, setHighlighted, setLocation, setLocation, setMousePointer, setMousePointer, setParent, setPhysicalLocation, setSensitiveForUIB, setState, setWindow, show, startTrigger, supportsCustomMousePointer, systemFocusGrabbed, topLevelWindow, unrealize, unregisterWidgetListener, validateDisplayValue, widgetStateChanged, width, windowmouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleasedcreateMnemonic, getMnemonicCharacter, getMnemonicKeyCode, getMnemonicLabel, isMnemonicSupported, updateMnemonicwidgetsAsListprotected static final char LF
protected static final char CR
protected static final java.lang.String SPACE
protected static final java.lang.String SPACE_LF
private static final java.util.regex.Pattern RTRIM
protected java.util.List<Editor.Line> parsedText
protected boolean widgetFocused
protected static final java.util.Map<java.lang.Integer,java.lang.Integer> maxSizes
protected boolean insert
protected boolean forceRedraw
protected java.lang.StringBuilder lineBuilder
private static int MAX_SIZE
private java.lang.String savedContent
public Editor(WidgetId id, EditorConfig cfg)
Call initialize(com.goldencode.p2j.ui.WidgetId, com.goldencode.p2j.ui.EditorConfig) to finish the widget initialization.
id - The widget's ID.cfg - Configuration data.public abstract void drawCaretUnconditionally()
public abstract void draw(Color color)
color - Color for drawing.protected abstract boolean goToNewLine(java.lang.String subtext,
boolean placeChar)
subtext - The text.placeChar - flag indicating if this call is from placeChar(char).true if the text will output on a new line.protected abstract boolean insertBlankLineOnLF()
protected abstract void mergeLines(int row)
row - line's rowprotected abstract int getNextSplitPosition(java.lang.String line,
int splitAfter)
line - The line to be split.splitAfter - minimal split position.protected abstract int absoluteX()
protected abstract java.lang.String processEOLChars(java.lang.String src)
src - the string to be processed.public boolean canMovetoTop()
canMovetoTop in interface Widget<O extends OutputManager<?>>true.public boolean editorReadFile(java.lang.String name)
name - The file name for the file to be loaded.TRUE if operation successful FALSE otherwise.public boolean editorSaveFile(java.lang.String name)
name - The file name for the file to be written.TRUE if operation successful FALSE otherwise.public void initialize(WidgetId id, EditorConfig cfg)
This API is called after the widget is created and added to the registry.
initialize in interface WidgetWithConfig<EditorConfig>id - The widget's ID.cfg - The config used to initialize this widget.public BaseDataType getChangedValue()
getChangedValue in interface DataContainerpublic BaseDataType getValue()
getValue in interface DataContainerpublic void requestFocus()
requestFocus in interface Widget<O extends OutputManager<?>>requestFocus in class FixedSizeContainer<O extends OutputManager<?>>public void drawCaret()
drawCaret in interface Widget<O extends OutputManager<?>>drawCaret in class AbstractWidget<O extends OutputManager<?>>public void draw()
DisplayFormat.Presentation instance is
rendered into screen value. Screen value is left justified or padded to
the right bound with spaces. Non first lines are filled with spaces. If
widget is focused then after rendering terminal's cursor is set to
appropriate position in the widget.draw in interface Widget<O extends OutputManager<?>>draw in class AbstractContainer<O extends OutputManager<?>>protected void refresh()
public java.lang.String getText()
getText in interface DataContainerpublic void clear()
public boolean focusTraversable()
focusTraversable in interface Widget<O extends OutputManager<?>>focusTraversable in class AbstractContainer<O extends OutputManager<?>>true if this component is enabled and visible.public Widget<O> currentFocus()
currentFocus in interface Container<O extends OutputManager<?>>currentFocus in class AbstractContainer<O extends OutputManager<?>>Container.currentFocus()public Widget<O> defaultFocus()
defaultFocus in interface Container<O extends OutputManager<?>>defaultFocus in class AbstractContainer<O extends OutputManager<?>>Container.defaultFocus()public void setValue(BaseDataType value)
setValue in interface DataContainervalue - New value for the screen buffer.public void processKeyEvent(KeyInput ke)
processKeyEvent in interface Widget<O extends OutputManager<?>>processKeyEvent in class AbstractContainer<O extends OutputManager<?>>ke - Key event structure.public boolean deleteLine()
true if the line was deleted.public boolean setSelection(int start,
int end)
setSelection in interface TextSelectionstart - Starting offset.end - Ending offset.true if the operation succeeded.public boolean setCursorLine(int line)
line - the new cursor line valuetrue if the cursor line is valid and setpublic int getCursorLine()
public boolean setCursorChar(int pos)
pos - the new cursor position valuetrue if the cursor position is valid and setpublic boolean setCursorChar(int pos,
boolean redraw)
pos - The new cursor position value.redraw - Request redraw/sync.true if the cursor position is valid and set.public int getCursorChar()
public boolean setCursorOffset(int offset,
boolean shouldInvalidateSelection)
setCursorOffset in class LabeledDataContainer<O extends OutputManager<?>,EditorConfig>offset - The new offset value. Use -1 to move the caret at the end (MOVE-TO-EOF).shouldInvalidateSelection - The flag that shows if we should invalidate selection.true if the cursor offset is valid and set.public boolean setCursorOffset(int offset)
offset - The new offset value. Use -1 to move the caret at the end (MOVE-TO-EOF).true if the cursor offset is valid and set.protected boolean setCursorLineAndChar(int line,
int offset)
line - the new cursor line valueoffset - the new offset valuetrue if the cursor offset is valid and setpublic int getCursorOffset()
public int getLength()
public int contentLength()
public int getLineCount()
public java.lang.String getLineText(int k)
null is returned.k - The line whose text is requested.k line (0-base).public boolean insertString(java.lang.String txt)
txt - The string to be inserted.true if the string is inserted.public boolean insertFile(java.lang.String fileNameToLoad)
fileNameToLoad - The file to be inserted.true if the file was successfully inserted.public boolean replaceSelectionText(java.lang.String txt)
txt - the replacement stringtrue if the selection is replacedprivate boolean replaceInterval(int start,
int end,
java.lang.String txt)
start - start of the intervalend - end of the intervaltxt - replacement texttrue if replacement done.public boolean replaceString(java.lang.String from,
java.lang.String to,
int flag)
from - the string to be replacedto - the replacement stringflag - the replacement mode flag as described in 4GL EDITOR:REPLACE documentationtrue if the replacement was performedpublic java.lang.Boolean search(java.lang.String pattern,
int mode)
pattern - The string to be search. No wildcard allowed.mode - a combinations of flags that specifies the type of search to be performed. The
following values are accepted:
| Type of search | Flag value |
|---|---|
| EditorWidget.FIND_NEXT_OCCURRENCE | 1 |
| EditorWidget.FIND_PREV_OCCURRENCE | 2 |
| EditorWidget.FIND_CASE_SENSITIVE | 4 |
| EditorWidget.FIND_WRAP_AROUND | 16 |
| EditorWidget.FIND_SELECT | 32 |
false. Objects that extends it will
implement their search and return the result accordingly.private int findRow(int pos)
pos - positionprivate int inSameLime(int start,
int end)
start - first positionend - second positionpublic boolean manageSystemActions()
manageSystemActions in class AbstractWidget<O extends OutputManager<?>>true as the widget has its own event management.private void cursorPageUp()
private void cursorPageDown()
private boolean deleteLineWorker()
true if anything is deleted.protected int lastRow()
protected int getMaxSize()
public int fullHeight()
protected void fireValueChanged()
protected void cursorBeginOfLine()
protected boolean deleteToEndOfLine()
true if text was deleted.protected void bell()
protected void backspace()
protected void cursorEndOfPrevLine()
protected void cursorHome()
protected void cursorEndOfLine()
protected Editor.Line getLine()
Line at current position.protected void cursorPos(int pos)
pos - The new absolute cursor position.protected void cursorDown()
protected void cursorUp()
protected void cursorRight()
protected void cursorRightTo(int shift)
shift - The value to increment the cursor position..protected void cursorLeft()
protected void placeLF()
protected int getIndentSize(java.lang.String line)
line - The line which indent will be calculated.protected java.lang.String addIndent(java.lang.String line,
int indentSize)
line - The line to which an indent will be added.indentSize - The size of the indent.protected boolean canPlaceChar()
true if the editor allows a char to be placed.protected void placeChar(char ch)
ch - Character to place.protected void placeChar(char ch,
boolean ignoreReadonly)
ch - Character to place.ignoreReadonly - If true places the char even when the editor is read-only, otherwise config.readOnly
field is honored.protected void splitLine(java.lang.String line,
int row,
int splitAfter)
line - line's contentrow - line's rowsplitAfter - minimal split positionprotected int absoluteY()
protected void deleteCharacterKey()
processKeyEvent(com.goldencode.p2j.ui.client.event.KeyInput).protected final boolean deleteCharacter()
true if something was deleted.protected void parseContent(java.lang.String source,
int row,
boolean placeChar)
source - Source string to parse.row - Row index to start parsing from.placeChar - Set to true if called from placeChar(char) method in insert mode.protected java.util.List<Editor.Line> parseContentImpl(java.lang.String source, int start, int offset, boolean placeChar)
Sub-classes can override this, to i.e. use cached metrics.
source - Source string to parse.start - Row index to start parsing from.offset - Text offset to start parsing from.placeChar - Set to true if called from placeChar(char) method in insert mode.protected final java.lang.String resolveContent()
protected FocusListener getFocusListener()
protected java.lang.String rtrim(java.lang.String value)
value - the string to be truncatedprotected void updateOffset()
private void placeStringInt(java.lang.String text)
text - String to place.private void placeStringSegmentWrap(java.lang.String text)
text - String to place.private void placeStringSegment(java.lang.String text)
text - String to place.