superwaba.ext.xplat.html.ui
Class Edit

java.lang.Object
  |
  +--waba.ui.Control
        |
        +--waba.ui.Edit
              |
              +--superwaba.ext.xplat.html.ui.Edit

public class Edit
extends Edit
implements Controllable

Edit extends the Waba Edit control and implements it as a Controllable


Fields inherited from class waba.ui.Edit
alignment, ALL_LOWER, ALL_NORMAL, ALL_UPPER, autoSelect, calculator, calendar, capitalise, CURRENCY, currencyCharsSet, DATE, dateSet, editable, hasBorder, hasCursorWhenNotEditable, KBD_CALCULATOR, KBD_CALENDAR, KBD_DEFAULT, KBD_KEYBOARD, KBD_NONE, kbdType, keyboard, len, mask, maxLength, NORMAL, numbersSet, overwrite, PASSWORD, PASSWORD_ALL, pushedInsertPos, pushedStartSelectPos, pushedxOffset, removeFocusOnAction, validChars
 
Fields inherited from class waba.ui.Control
AFTER, appId, appObj, asContainer, asWindow, backColor, backDis, BEFORE, BOTTOM, CENTER, clearValueInt, clearValueStr, enabled, FILL, FIT, fm, fmH, focusLess, focusTraversable, font, foreColor, foreDis, height, highlightRectsCount, isHighlighting, LEFT, parent, PREFERRED, RANGE, RIGHT, SAME, TOP, uiCE, uiFlat, uiPalm, uiVista, visible, width, x, x2, y, y2
 
Constructor Summary
Edit(java.lang.String name, java.lang.String text, int len, int maxLen)
          Constructor
 
Method Summary
 Graphics createGraphics()
          Override the createGraphics method in order to get the text edit control to be positionned at its place, given the scoll values.
 void getFocus()
          Make this controllable gets the focus
 java.lang.String getName()
          Get the name of this Controllable
 int getPreferredWidth()
          Get the width of this Controllable
 java.lang.String getValue()
          Get the value hold by this Controllable
 void onEvent(Event event)
          Called to process key, pen, control and other posted events.
 void popupKCC()
          user method to popup the keyboard/calendar/calculator for this edit.
 void repaint()
          Marks the control for repaint.
 void reset()
          Resets the control to its original default value.
 void setHtmlContainer(HtmlContainer htmlCnr)
          Set the Html HtmlContainer associated to this Controllable
 
Methods inherited from class waba.ui.Edit
charPos2x, clear, draw, getCursorPos, getKeyboardType, getLength, getPreferredHeight, getText, isCharValid, isEditable, onBoundsChanged, onColorsChanged, onPaint, onWindowPaintFinished, popPosState, pushPosState, setCapitaliseMode, setCursorPos, setEditable, setKeyboard, setMaxLength, setMode, setText, setValidChars, x2charPos
 
Methods inherited from class waba.ui.Control
addTimer, changeHighlighted, contains, drawHighlight, getAbsoluteRect, getBackColor, getFont, getFontMetrics, getForeColor, getNext, getParent, getParentWindow, getPos, getRect, getSize, isDisplayed, isEnabled, isVisible, onFontChanged, postEvent, removeTimer, repaintNow, requestFocus, setBackColor, setBackForeColors, setEnabled, setFocusLess, setFont, setForeColor, setRect, setRect, setRect, setVisible, translateFromOrigin, uiStyleChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Edit

public Edit(java.lang.String name,
            java.lang.String text,
            int len,
            int maxLen)
Constructor
Parameters:
name - name of this Controllable
text - the text displayed in this Edit control
len - length (in characters) of this field; -1 to use default
maxLen - the maximum length of characters of this field; -1 to use default
Method Detail

setHtmlContainer

public void setHtmlContainer(HtmlContainer htmlCnr)
Description copied from interface: Controllable
Set the Html HtmlContainer associated to this Controllable
Specified by:
setHtmlContainer in interface Controllable
Tags copied from interface: Controllable
Parameters:
htmlCnr - the HtmlContainer associated to this Controllable

popupKCC

public void popupKCC()
Description copied from class: Edit
user method to popup the keyboard/calendar/calculator for this edit.
Overrides:
popupKCC in class Edit

onEvent

public void onEvent(Event event)
Description copied from interface: Controllable
Called to process key, pen, control and other posted events.
Specified by:
onEvent in interface Controllable
Overrides:
onEvent in class Edit
Tags copied from interface: Controllable
Parameters:
event - the event to process

getFocus

public void getFocus()
Description copied from interface: Controllable
Make this controllable gets the focus
Specified by:
getFocus in interface Controllable

getPreferredWidth

public int getPreferredWidth()
Description copied from interface: Controllable
Get the width of this Controllable
Specified by:
getPreferredWidth in interface Controllable
Overrides:
getPreferredWidth in class Edit
Tags copied from interface: Controllable
Returns:
the width of this Controllable

getName

public java.lang.String getName()
Description copied from interface: Controllable
Get the name of this Controllable
Specified by:
getName in interface Controllable
Tags copied from interface: Controllable
Returns:
the name of this Controllable

getValue

public java.lang.String getValue()
Description copied from interface: Controllable
Get the value hold by this Controllable
Specified by:
getValue in interface Controllable
Tags copied from interface: Controllable
Returns:
the value hold by this Controllable

repaint

public void repaint()
Description copied from class: Control
Marks the control for repaint. Important note: when you call repaint, the absolute area of the control regarding its parent Window is invalidated (marked for repaint); then, the next time a event (a keypress, a timer, a pen event) occurs, the screen is updated. If you call repaint and the control isn't effectively repainted, you have 2 choices: call Window._doPaint(), or, use Control.repaintNow.
Overrides:
repaint in class Control

createGraphics

public Graphics createGraphics()
Override the createGraphics method in order to get the text edit control to be positionned at its place, given the scoll values.
Overrides:
createGraphics in class Control
Returns:
graphics object for this Edit control.

reset

public void reset()
Description copied from interface: Controllable
Resets the control to its original default value.
Specified by:
reset in interface Controllable