public class TextPadButton extends TextPad
Modifier and Type | Field and Description |
---|---|
Color |
activeColor
This is the color the background will be when the control is selected.
|
static String |
defaultMoreMessage |
allowOverwrite, amScrolling, backgroundImage, charWidth, curState, disableCursor, disableTextChanges, dls, dontWantPopup, extraLineSpacing, fitExactNumLines, forcedActualWidth, format, inputState, leftMargin, lineHeight, lines, minXScroll, minYScroll, moreMessage, noCursorMovement, numLines, rightMargin, selectAllOnFocus, spacing, STATE_AUTOTAB, STATE_OVERWRITE, wantReturn, wantTab, wrapToScreenSize
actAsLabel, blinkId, CASE_LOWER, CASE_NORMAL, CASE_NUMBERS, CASE_SENTENCE, CASE_UPPER, colors, conditionalChar, conditionalCharIndex, defaultInputFlags, doingLocalInput, doingNativeInput, FLAG_INPUT_ON_FOCUS, FLAG_KEEP_FOCUS_AFTER_INPUT, FLAG_NEED_FULL_ACTION, FLAG_PASSIVE, FLAG_USE_NATIVE, inFocus, inputFlags, inputMethod, justGotFocus, nothingEnteredText, oldText, pageColor, startNativeOnPaint, textCase, validator
backGround, beforeRemoved, borderColor, borderStyle, borderWidth, children, columns, constraints, curFont, debugModify, debugRepaintNow, disabledBackground, dragging, dragResolution, dragTime, exitKeys, fieldTransfer, font, fontChange, fontFrom, foreGround, height, holdDownPause, holdTick, hotKey, image, lastSelected, listeners, lockPaint, maxHeight, maxWidth, menuState, minHeight, minWidth, modifiers, name, next, parent, penStatus, preferredHeight, preferredWidth, prev, prompt, promptControl, rows, ss, startDragResolution, tags, tail, text, toolTip, width, x, y
clipItems, clipObject, clipOwner, debugControl, debugFlag, doubleBuffer, doubleClickTime, doubleSizedFontHeight, firstPress, globalEditable, globalEnabled, PEN_STATUS_DID_HOLD_DOWN, PEN_STATUS_GOT_PEN_DOWN, PEN_STATUS_PEN_IS_ON, TAG_BOOLEAN_KEEP_BELOW_SIP, TAG_HOVER_TIME_INT, TAG_LAST_USER_DATA, TAG_USER_DATA, TAKE_FIRST_PRESS, unnamed
GoHigher, GoLower, Horizontal, OPTION_INDICATOR_ONLY, PageHigher, PageLower, ScrollHigher, ScrollLower, TrackTo, Vertical
BDR_DOTTED, BDR_INNER, BDR_NOBORDER, BDR_OUTER, BDR_OUTLINE, BDR_RAISEDINNER, BDR_RAISEDOUTER, BDR_SUNKENINNER, BDR_SUNKENOUTER, BF_ABUT_ANY, BF_ABUT_BOTTOM, BF_ABUT_LEFT, BF_ABUT_RIGHT, BF_ABUT_TOP, BF_BOTTOM, BF_BOTTOMLEFT, BF_BOTTOMRIGHT, BF_BUTTON, BF_DIAGONAL, BF_DIAGONAL_ENDBOTTOMLEFT, BF_DIAGONAL_ENDBOTTOMRIGHT, BF_DIAGONAL_ENDTOPLEFT, BF_DIAGONAL_ENDTOPRIGHT, BF_EXACT, BF_FLAT, BF_LEFT, BF_MIDDLE, BF_MONO, BF_PALM, BF_RECT, BF_RIGHT, BF_SOFT, BF_SQUARE, BF_TOP, BF_TOPLEFT, BF_TOPRIGHT, EDGE_BUMP, EDGE_ETCHED, EDGE_RAISED, EDGE_SUNKEN
ALWAYS_STRETCHABLE, BOTTOM, CELLFLAG, CELLMASK, CENTER, CONTROLMASK, DONTCHANGE, DONTFILL, DONTSTRETCH, EAST, FILL, GROW, HCENTER, HCONTRACT, HEXPAND, HFILL, HGROW, HSHRINK, HSTRETCH, INITIALLY_CLOSED, INITIALLY_HIDDEN, INITIALLY_MINIMIZED, INITIALLY_PREFERRED_SIZE, INSETS, LEFT, MAXIMUMSIZE, MINIMUMSIZE, NORTH, NORTHEAST, NORTHWEST, PREFERREDSIZE, RECT, RIGHT, SHRINK, SOUTH, SOUTHEAST, SOUTHWEST, SPAN, STRETCH, TAG_BACKGROUND_IMAGE, TAG_BUSY_DISPLAY, TAG_COLORS, TAG_CONTROL_PAINTER, TAG_EXPOSE_GROUP, TAG_FIXEDSIZE, TAG_GRAY_BACKGROUND, TAG_HIDE_CONTROL_OBJECT, TAG_HIDE_PARENT, TAG_INNER_TEXT_INSETS, TAG_INPUT_STACK_PARENT, TAG_INSETS, TAG_MAKE_VISIBLE, TAG_MAXIMUMSIZE, TAG_MINIMUMSIZE, TAG_PAINT_CONTROL_LIST, TAG_PREFERRED_TEXT_SIZE, TAG_PREFERRED_TEXT_SIZE_HEIGHT, TAG_PREFERRED_TEXT_SIZE_WIDTH, TAG_PREFERREDSIZE, TAG_RECT, TAG_SHADOW_INSETS, TAG_SPAN, TAG_SWIPER, TAG_TEMPORARY_ERROR, TAG_TEXT_INSETS, TAG_TEXTSIZE, TEXTSIZE, TOP, VCENTER, VCONTRACT, VEXPAND, VFILL, VGROW, VSHRINK, VSTRETCH, WEST
All, AlwaysEnabled, AlwaysRecalculateSizes, ByDeferredMouse, ByDeferredPen, ByFrameChange, ByKeyboard, ByMouse, ByPen, ByRequest, CalculatedSizes, ContainerDontPaintChildren, Disabled, DisablePopupMenu, DisplayOnly, DontBuffer, Down, DrawFlat, Flag, ForceResize, HasData, Invisible, KeepImage, KeepSIP, Left, MakeMenuAtLeastAsWide, Maximize, Minimize, ModifiersInheritedFromWindow, MouseSensitive, NoFocus, NotAnEditor, NotEditable, PaintDataOnly, PaintOutsideOnly, PenTransparent, PreferredSizeOnly, Right, SendUpUIEvents, ShowSIP, ShrinkToNothing, SmallControl, TakeChildUIEvents, TakeControlEvents, TakesKeyFocus, Transparent, Up, WantDrag, WantHoldDown
KEEP_VISIBLE
Constructor and Description |
---|
TextPadButton() |
TextPadButton(int rows,
int cols) |
TextPadButton(String text) |
Modifier and Type | Method and Description |
---|---|
Control |
getBestScrollingControl()
Returns the best Control to add to a destination which contains this TextPad and allows it to be scrolled,
or return this TextPad itself if it is not appropriate to scroll the TextPad (e.g. on a Smartphone).
|
protected void |
getColors(boolean hasFocus,
int flags)
Provides the colors to be used for the text and background colors.
|
Control |
getNextKeyFocus(Control sourceChild,
boolean forwards)
Determine which sub-control should receive the keyboard focus.
|
void |
onKeyEvent(KeyEvent ev) |
void |
penPressed(Point where)
Called when the Pen or Mouse button is pressed on the control.
|
acceptsData, addDisplayLine, addDisplayLines, appendText, applySpecialFormat, autoTab, breakLineBefore, calculateSizes, canGo, checkScrolls, checkSipCoverage, clearCursor, clearSelection, countLines, countSplitLines, dataAccepted, dataDraggedOff, dataDraggedOver, dataDroppedOn, dataTransferCancelled, deleteSelection, displayLinesChanged, doPaint, doPaintData, doPaintData, doScroll, doShowMenu, dragged, drawSpecialFormat, ensureBlankLines, fix, fixText, getActual, getAvailableWidth, getBaselineHeight, getCharAt, getCharAt, getCharRect, getCurrent, getCursorPosition, getCursorRect, getFontMetricsForSplitting, getHeightForLines, getIndexLocation, getLeftPosition, getLine, getLine, getLineAt, getLineAt, getLineHeight, getLineLength, getLines, getNumLines, getPenChar, getScreenRows, getScrollablePanel, getSelection, getSelectionRange, getSpecialFormatCount, getState, getText, getTextPadMenu, getTextPositions, getTextPositions, getTextWidth, getTopLine, getTrueCharIndex, getTrueCharIndex, getVisible, gotFocus, hasSelection, lostFocus, needScrollBar, newCursorPos, newCursorPos, noSelection, onEvent, onPenEvent, paintConditionalChar, paintCursor, paintCursor, paintLastChar, paintLastChar, paintLine, paintLine, paintLine, paintLines, paintLinesFrom, penDoubleClicked, penReleased, popupMenuClosed, popupMenuEvent, pushDisplayLine, rearrange, removeDisplayLine, removeSelection, replaceDisplayLines, replaceLines, replaceSelection, resizeTo, resplit, scrollTo, selectAll, setAsStaticDisplay, setNativeInputFlags, setSelectionRange, setSelectionRange, setState, setText, splitLines, splitLines, splitLines, splitLines, splitLines, startDragging, ticked, update, update, updateScrolls
calculateInputFlags, checkInputMethod, dataBeingRemoved, fixCase, getBestPassiveFlags, getNativeInputParameters, hasChanged, inActivePassiveInput, isLabel, keepConditionalChar, nativeInputStopped, onControlEvent, setAsLabel, setConditionalChar, showHoldDownIndicator, startActiveInput, startLocalInput, startNativeInput, takeData, updateData, verifyWantDrag, verifyWantHoldDown
activate, addListener, amOnTopFrame, applyFontChange, baseOnPenEvent, bufferGraphics, bufferGraphics, bufferGraphics, bufferGraphics, bufferGraphics, cache, calculatedSizes, calculateTextSize, calculateTextSize, calculateTextSize, cancelHoldDown, cancelPenPress, canEdit, change, changeDimension, changeTag, checkClipboardOperations, checkExitKey, checkMenu, checkMenuKey, checkModifiers, checkParentInterceptsUIEvent, checkPenTransparent, childrenPainted, clearTag, clipboardToString, clipboardTransfer, closeMenu, contains, contains, createNewMenu, dataDraggedOver, deactivate, defaultTo, deferInWindowThread, doAction, doActionKey, doBackground, doBorder, doHotKey, doMenu, dontAcceptDrop, doPaintChildren, doPaintData, draw, draw, draw, exitEntry, fillBackground, fillBackgroundNotInFrame, findTagInParents, fontChanged, formClosing, free, fromClipboard, fromField, fromField, getAllDescendants, getAllSubControls, getAncestor, getAncestor, getAncestorProperty, getBackground, getCached, getCachedChildren, getCachedDim, getCachedDim, getCachedRect, getCachedRect, getCachedSubControls, getChildAnchor, getChildren, getChildren, getChildrenBackwards, getClipboardMenu, getClipObject, getContentsInsets, getContentsInsets, getContentsRect, getDataToCopy, getDataToDragAndDrop, getDim, getDisplayText, getDragAndDropContext, getFieldTransfer, getFont, getFontMetrics, getFontMetrics, getFontMetricsForSizeCalculations, getForeground, getFrame, getFrameOrContainer, getGraphics, getGraphics, getHeight, getHideParent, getImage, getLastSelected, getLocation, getLock, getMaximumSize, getMenu, getMinimumSize, getModifiedBorderFlags, getModifiers, getNext, getPaintParameters, getParent, getParent, getParent, getParentOrListener, getPasswordCharacter, getPosInFrame, getPosInFrame, getPosInParent, getPosInParent, getPreferredSize, getPreferredSizeByParent, getPreferredTextSize, getPrompt, getPromptText, getRect, getRect, getServer, getSize, getSizes, getSubControls, getSubControls, getTag, getToolTip, getWidth, getWindow, getWindowGraphics, hasModifier, hasPopupFormAttached, hasTag, hide, inheritModifiers, insetToContents, interceptChildUIEvent, isChildOf, isDirectChildOfWindow, isHidden, isModal, isOnMe, isOnMe, isOnMe, isSomeonesHotKey, make, makeFrameTopMost, makeHot, makeHot, makeInvisible, makeVisible, markAsTemporaryError, menuIsActive, menuStateChanged, modify, modifyAll, modifyAll, modifyFlags, mouseHover, newEventThread, notifyAction, notifyDataChange, notifyDataChange, notifyMenuItemSelected, notifyStructureChanged, onLabelPenEvent, paintBackground, paintWithControlPainter, pauseEventThread, penClicked, penHeld, penRightReleased, popupBeep, popupMenuEvent, postEvent, postInWindowThread, postUIEvent, putInside, queueKeyEvent, queuePenEvent, readLock, recalculatePreferredSize, redisplay, refresh, releaseBufferedGraphics, removed, removeListener, repaint, repaint, repaintDataNow, repaintInWindowThread, repaintInWindowThread, repaintNow, repaintNow, repaintNow, repaintNow, requestPaint, requestResizeTo, resetAllCachedProperties, resetCachedProperties, resetRect, restore, restoreBorderModifiers, restoreFlags, resumeEventThread, scrollAndRepaint, sendToListeners, set, setAllFonts, setBackgroundImage, setBorder, setBorderModifiers, setCell, setChildAnchor, setClipObject, setControl, setCursor, setFieldTransfer, setFixedSize, setFont, setFontChange, setFreeDragging, setHidden, setHiddenParent, setHotKey, setHotKey, setLocation, setMaximumSize, setMenu, setMinimumSize, setPreferredSize, setPreferredTextSize, setPreferredTextSize, setPromptControl, setRect, setRect, setScaledBackgroundImage, setServer, setShadow, setSwiping, setTag, setTags, setTextSize, setTiledBackgroundImage, setToolTip, shown, simulateClickOn, simulateKeyPresses, simulateKeyType, standardOnKeyEvent, startDragAndDrop, startDragAndDrop, stopDragging, takeFocus, takeFromClipboard, takePromptControl, testInWindowThread, tipIsDisplayed, toClipboard, toField, toField, toIDString, toString, toTextData, transferPenPress, transferPenPress, tryDragAndDrop, tryGetGraphics, tryNext, tryStartMenu, unhide, unlock, updateDCDuringDD, updateFrom, updateTo, waitEventThread, willAcceptDrop, willShowFrame, windowHasFloatingControls, writeLock
doubleSizeIt, getGuiTextHeight, isDoubleSized, isDoubleSizedFont, loadImage, tryLoadImage
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getServer, setServer
public static String defaultMoreMessage
public Color activeColor
public TextPadButton()
public TextPadButton(int rows, int cols)
public TextPadButton(String text)
protected void getColors(boolean hasFocus, int flags)
EditControl
getColors
in class EditControl
hasFocus
- True if the control currently has the focus.flags
- This is the result of a call to getFlags(true) - which provides an OR'ing of all the flags
of this control and all its parents.public Control getNextKeyFocus(Control sourceChild, boolean forwards)
Control
getNextKeyFocus
in class Control
sourceChild
- the child control from which the call came from, or null if the call
came from the parent of this control, or this control itself.forwards
- true if the user wants to go to the next control, false if the user wants
to go to the previous one.public void penPressed(Point where)
Control
Within this method you can use the Control.Gui.currentPenPress() value to find out more about the PenEvent that caused this - including any modifiers (e.g. SHIFT keys) or determine if the left or right mouse button was pressed.
penPressed
in class TextPad
where
- The point on the Control where the pen was pressed.public void onKeyEvent(KeyEvent ev)
onKeyEvent
in class TextPad
public Control getBestScrollingControl()
getBestScrollingControl
in class TextPad