public class EntryFieldGuiImpl extends FillInGuiImpl
LightweightTextWidget.TextLineSelection| Modifier and Type | Field and Description |
|---|---|
private DisplayFormat |
cbxFormat
Local format used as alternative for comboboxes of other subtype tan DROP-DOWN-LIST.
|
private ComboBoxGuiImpl |
comboBoxRef
Reference to the possible combo-box object.
|
private boolean |
focusTraversable
Local focus traversable flag.
|
private GuiDriver |
gd
Screen driver
|
private static CentralLogger |
LOG
Logger
|
disabledFore, disabledForeFixedColorbrowseColumn, drawLine, editScroller, justActivated, leftAnchor, rightAnchor, selected, skipCursorActivation, useUnderlineconfiglisteners, location, mousePtr, nativeInsets, physicalLocation| Constructor and Description |
|---|
EntryFieldGuiImpl(FillInConfig cfg,
ComboBoxGuiImpl cbbRef)
Special constructor used to restore component using given configuration.
|
EntryFieldGuiImpl(WidgetId id,
FillInConfig cfg)
Special constructor used to restore component using given configuration.
|
| Modifier and Type | Method and Description |
|---|---|
void |
display()
Fills data structures from variable's value.
|
protected void |
drawBorder(GuiColorResolver gcd,
int x,
int y,
NativeDimension dim,
boolean threeDBorder)
Draws the border box around the fill-in.
|
void |
drawCaret()
Draws the caret.
|
protected NativeDimension |
editableNativeDimension()
Determine the portion of the widget's editable part.
|
boolean |
enforceDefaultMousePtr()
Check if the default mouse pointer should be used regardless of
the parent settings
|
boolean |
focusTraversable()
Check if widget is focus traversable.
|
protected boolean |
getDataEntryReturn()
Convenience method to get access to SESSION:DATA-ENTRY-RETURN attribute.
|
Widget |
getLegacyWidget()
Get the legacy widget for this entry-field, its
comboBoxRef. |
protected Theme.TextLookAndFeel |
getTextLookAndFeel(GuiColorResolver gcd,
GuiColorResolver gce)
Returns text look and feel for EntryFieldGuiImpl.
|
Widget |
getTriggerWidget()
For some virtual widgets, the widget where triggers are checked is different (i.e.
|
double |
height()
Get widget height.
|
void |
initialize(WidgetId id,
FillInConfig 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.
|
protected boolean |
isTextSelectionDisplayed()
Tests if the text selection is displayed.
|
boolean |
isThreeD()
The combo editor is never 3D.
|
void |
mousePressed(java.awt.event.MouseEvent e)
Notification of a mouse pressed event occurred for this widget.
|
void |
mouseReleased(java.awt.event.MouseEvent e)
Notification of a mouse clicked event occurred for this widget.
|
void |
processKeyEvent(KeyInput ke)
Process GUI specific keys for combo-box entry field:
SE_VALUE_CHANGED - inform combo-box the value changed.
|
double |
width()
Get widget width.
|
activate, adjustEditScroller, afterConfigUpdate, blankScreenValue, convertToStreamable, createLeftAnchor, createMnemonic, createRightAnchor, draw, drawCaretInt, drawCursor, focusAndSelect, getCursorColumnOffset, getCursorRowOffset, getFontCache, getInitialCursorPos, getInsertMode, getLastOffset, getNativeCursorPos, getScreenText, getScreenText, getScrollColumnOffset, getScrollRowOffset, getSelectedText, getTextSelection, getValidCursorPos, initSelection, invalidateSelection, isAutoResize, isCharacterInGui, isDroppable, isIntegerInGui, isRMBEntrySupported, isZapToBeApplied, mouseActions, mouseClicked, mouseDragged, mouseWheelMoved, moveCursorToLast, nativeHeight, nativeWidth, nativeWidth, processMnemonic, refresh, removeSelectedText, resetCaret, resetEditScroller, selectAll, setCursorOffset, setSelection, setSelection, showPopupMenu, supportsCustomMousePointer, updateCursorOffsetValue, updateSizeactivate, adjustCursor, canMovetoTop, clear, clear, clear, clearWidget, copyState, currentFocus, defaultFocus, draw, fireValueChanged, getBrowse, getCurrentFormat, getCursorOffset, getDrawText, getEditScroller, getFirstInGroup, getFormat, getScreenValue, getText, getText, getTriggerWidget, getValue, getVariable, isAtField, isDrawLine, isFormatCheck, isInAutoReturn, isLeftEdgeWidget, isLinkedToBrowse, isPendingNoZap, isRightAligned, isRightAlignedInt, isRightEdgeWidget, isSelected, isSelectionValid, isZapActive, refresh, requestFocus, reset, setAttrFormat, setBrowseColumn, setCursorOffset, setDataType, setEnabled, setForceLeft, setForceRight, setFormatCheck, setHeaderParm, setInAutoReturn, setInsertMode, setPendingNoZap, setSize, setSkipCursorActivation, setTextGroup, setUnderline, setValue, setValue, setZapMode, setZapMode, silentActivation, toScreenValue, toString, update, updateSize, updateUIAfterValueSet, updateZapState, validateDisplayValueconfig, defaultMousePtr, destroy, getColon, getColumnLabelText, getColumnMnemonic, getLabelInstance, getLabelText, getMnemonic, getTo, isForceLabel, isModified, isNoLabels, 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, 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, setTabItemList, setWidth, startSizeChange, swap, triggerContainerStateRedrawEnabled, unrealize, updateSizeWorker, widgets, widgetsAsList, widgetStateChanged_setHidden, _setVisible, activateDirectManipulation, addFocusListener, addKeyListener, afterConfigUpdateBase, ancestor, ancestorId, autoResize, bounds, clear, 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, 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, isScreenLocationCached, isTabStop, isTotallyObscured, isVisible, isVisible, location, manageSystemActions, mouseEntered, mouseExited, mouseMoved, 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, processMnemonicImpl, processSystemKey, raiseLegacyMouseEvents, reflectSizeChanged, refresh, registerWidgetListener, repaint, repaint, requestSync, resetBitmap, resizeTo, resolveFont, resolvePopupMenuId, resolveTitleFont, screen, screenDimension, screenHeight, screenLocation, screenPhysicalLocation, screenWidth, setBitmap, setCachedScreenLocation, setCachedScreenPhysicalLocation, setDirectManipulationActive, setHighlighted, setLocation, setLocation, setMousePointer, setMousePointer, setParent, setPhysicalLocation, setSensitiveForUIB, setState, setWindow, show, sync, topLevelWindow, translate, triggerLocationChanged, unregisterWidgetListener, updateSystemParent, widgetRealized, windowclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitconvertToStreamableeditPaste, isEditCanUndoacceptsEscAsAnyKey, acceptTrigger, addFocusListener, addKeyListener, ancestor, ancestorId, bounds, completeTrigger, dimension, displayPhysicalLocation, enclosingFrame, findMouseSource, forceCursorOnFocus, forceVisibility, getActualBounds, getCustomMousePointer, getEffectiveMousePointer, getId, getIdForTrigger, getLoadedMousePointer, getMenuMouse, getMouseActions, getMousePosition, getState, getVisiblePart, getZOrderClass, hasFocus, hasFocus, hasTooltip, hidden, hide, highlighted, ignoreEnable, initialHeight, initialWidth, insets, isCurrent, isCurrent, isDirectManipulable, isDirectManipulationActive, isDirectManipulationActiveOrInUIB, isDisplayed, isEnabled, isFocusable, isHeader, isInitialValueLayout, isLegacyFocus, isProcessProgressEvent, isRealized, isRepaintDisabled, isTabStop, 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, raiseLegacyMouseEvents, refreshWidget, registerWidgetListener, repaint, repaint, repaint, requestFocus, requestFocus, requestSync, resizeTo, resolvePopupMenuId, screen, screenLocation, screenPhysicalLocation, setDirectManipulationActive, setHighlighted, setLocation, setLocation, setMousePointer, setMousePointer, setParent, setPhysicalLocation, setSensitiveForUIB, setState, setWindow, show, startTrigger, systemFocusGrabbed, topLevelWindow, unrealize, unregisterWidgetListener, widgetStateChanged, windowgetChangedValuegetMnemonicCharacter, getMnemonicKeyCode, getMnemonicLabel, isMnemonicSupported, updateMnemonicwidgetsAsListprivate static final CentralLogger LOG
private GuiDriver gd
private ComboBoxGuiImpl comboBoxRef
private boolean focusTraversable
private DisplayFormat cbxFormat
public EntryFieldGuiImpl(WidgetId id, FillInConfig cfg)
Call initialize(com.goldencode.p2j.ui.WidgetId, com.goldencode.p2j.ui.FillInConfig) to finish the widget initialization.
id - The widget's ID.cfg - Configuration data.public EntryFieldGuiImpl(FillInConfig cfg, ComboBoxGuiImpl cbbRef)
Call initialize(com.goldencode.p2j.ui.WidgetId, com.goldencode.p2j.ui.FillInConfig) to finish the widget initialization.
cfg - Configuration data.cbbRef - Combo-box reference.public Widget getTriggerWidget()
public Widget getLegacyWidget()
comboBoxRef.public void initialize(WidgetId id, FillInConfig cfg)
This API is called after the widget is created and added to the registry.
initialize in interface WidgetWithConfig<FillInConfig>initialize in class FillInGuiImplid - The widget's ID.cfg - The config used to initialize this widget.public void processKeyEvent(KeyInput ke)
SE_VALUE_CHANGED - inform combo-box the value changed.processKeyEvent in interface Widget<GuiOutputManager>processKeyEvent in class FillInGuiImplke - Key event structure.protected boolean getDataEntryReturn()
getDataEntryReturn in class FillIn<GuiOutputManager,FillInConfig>public boolean focusTraversable()
focusTraversable in interface Widget<GuiOutputManager>focusTraversable in class FillIn<GuiOutputManager,FillInConfig>true if widget is focus traversable.public double width()
width in interface Widget<GuiOutputManager>width in class FillIn<GuiOutputManager,FillInConfig>public double height()
height in interface Widget<GuiOutputManager>height in class FillIn<GuiOutputManager,FillInConfig>public void drawCaret()
drawCaret in interface Widget<GuiOutputManager>drawCaret in class FillInGuiImplpublic void mousePressed(java.awt.event.MouseEvent e)
If the widget is not already focused, it forces the focus to it. After the focus was received, it computes the caret location, based on the mouse position over the widget's content.
mousePressed in interface java.awt.event.MouseListenermousePressed in class FillInGuiImple - The mouse event.public void mouseReleased(java.awt.event.MouseEvent e)
If the widget is not already focused, it forces the focus to it. After the focus was received, it computes the caret location, based on the mouse position over the widget's content.
mouseReleased in interface java.awt.event.MouseListenermouseReleased in class FillInGuiImple - The mouse event.public boolean enforceDefaultMousePtr()
true if the default mouse pointer should always be usedprotected NativeDimension editableNativeDimension()
For GUI widgets, this is the physical dimension without the insets.
editableNativeDimension in class FillInGuiImplprotected Theme.TextLookAndFeel getTextLookAndFeel(GuiColorResolver gcd, GuiColorResolver gce)
getTextLookAndFeel in class FillInGuiImplgcd - The gui color resolver used for normal text.gce - The gui color resolver used for selected text.protected boolean isTextSelectionDisplayed()
isTextSelectionDisplayed in class FillInGuiImplprotected void drawBorder(GuiColorResolver gcd, int x, int y, NativeDimension dim, boolean threeDBorder)
drawBorder in class FillInGuiImplthreeDBorder - Indicates whether 3d or flat border should be drawn.gcd - graphic contextx - the X coordinatey - the Y coordinatedim - the dimentionpublic boolean isThreeD()
isThreeD in interface Widget<GuiOutputManager>isThreeD in class AbstractWidget<GuiOutputManager>public void display()
display in class FillInGuiImpl