|
JClass DesktopViews 6.3.0 API Documentation |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--javax.swing.JComponent | +--javax.swing.text.JTextComponent | +--javax.swing.JTextField | +--com.klg.jclass.field.JCTextField | +--com.klg.jclass.field.cell.JCTextFieldCellEditor
JCTextFieldCellEditor
provides an editor using a simple
JCTextField
component.
Nested Class Summary |
Nested classes inherited from class javax.swing.JTextField |
JTextField.AccessibleJTextField |
Nested classes inherited from class javax.swing.text.JTextComponent |
JTextComponent.AccessibleJTextComponent, JTextComponent.KeyBinding |
Nested classes inherited from class javax.swing.JComponent |
JComponent.AccessibleJComponent |
Nested classes inherited from class java.awt.Container |
Container.AccessibleAWTContainer |
Nested classes inherited from class java.awt.Component |
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
protected int |
caretPosition
|
protected Object |
data
This editor can dynamically alter its reserved key list based upon the key the user has last typed. |
protected AWTEvent |
initialEvent
|
protected com.klg.jclass.cell.JCKeyModifier[] |
reservedKeys
|
protected boolean |
selectAll
|
protected com.klg.jclass.cell.JCCellEditorSupport |
support
|
protected com.klg.jclass.cell.validate.ValidateSupport |
validate_support
|
Fields inherited from class com.klg.jclass.field.JCTextField |
field, required, version |
Fields inherited from class javax.swing.JTextField |
notifyAction |
Fields inherited from class javax.swing.text.JTextComponent |
DEFAULT_KEYMAP, FOCUS_ACCELERATOR_KEY |
Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface com.klg.jclass.field.JCFieldComponent |
INVALID, UNDEREDIT, VALID |
Fields inherited from interface javax.swing.SwingConstants |
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
JCTextFieldCellEditor()
Creates a new JCTextFieldCellEditor object. |
|
JCTextFieldCellEditor(Class c,
com.klg.jclass.field.validate.JCValidator v)
Constructs an empty JCTextFieldCellEditor , which expects an object
of the specified class, that uses the specified validator. |
Method Summary | |
void |
addCellEditorListener(com.klg.jclass.cell.JCCellEditorListener l)
Adds a listener to the list that's notified when the editor starts, stops, or cancels editing. |
void |
addValidateListener(com.klg.jclass.cell.validate.JCValidateListener l)
Adds a new ValidateListener to the list. |
void |
cancelCellEditing()
Called when the edit process is cancelled. |
protected boolean |
fireValidated(com.klg.jclass.cell.validate.JCValidateEvent ev)
|
String |
getCellEditorText()
Gets the text for the editor (as a String). |
Object |
getCellEditorValue()
Returns the object to be commited. |
Component |
getComponent()
Returns the JCTextField component. |
Dimension |
getPreferredSize(Graphics gc,
com.klg.jclass.cell.JCCellInfo cellInfo,
Object o)
|
com.klg.jclass.cell.JCKeyModifier[] |
getReservedKeys()
This editor reserves the LEFT and RIGHT arrow keys for its own use. |
boolean |
getSelectAll()
Returns whether this editor will select the text on initialization. |
void |
initialize(AWTEvent ev,
com.klg.jclass.cell.JCCellInfo info,
Object o)
The container calls initialize() before the edit starts to
let the editor know what kind of event started the edit
(via the AWTEvent object). |
boolean |
isModified()
Returns true if the data has been modified. |
void |
keyPressed(KeyEvent e)
|
void |
keyReleased(KeyEvent e)
|
void |
keyTyped(KeyEvent e)
|
void |
mouseClicked(MouseEvent e)
|
void |
mouseEntered(MouseEvent e)
|
void |
mouseExited(MouseEvent e)
|
void |
mousePressed(MouseEvent e)
|
void |
mouseReleased(MouseEvent e)
|
void |
processKeyEvent(KeyEvent e)
Overrides the key event processor. |
void |
removeCellEditorListener(com.klg.jclass.cell.JCCellEditorListener l)
Removes a listener from the list that's notified. |
void |
removeValidateListener(com.klg.jclass.cell.validate.JCValidateListener l)
Removes a ValidateListener from the list. |
void |
selectAllText()
Uses hint from CellInfo to select all the text in the component. |
void |
setCellEditorText(String text)
Sets the text for the editor. |
void |
setVisible(boolean b)
Overrides setVisible in order to control the caret
position. |
boolean |
stopCellEditing()
Called when the edit process is stopped. |
Methods inherited from class com.klg.jclass.field.JCTextField |
addNotify, addPropertyChangeListener, addValueListener, commitEdit, createField, getAbout, getDataProperties, getInvalidInfo, getSelectOnEnter, getState, getValidator, getValue, getValueModel, isRequired, removePropertyChangeListener, removeValueListener, setAbout, setBackground, setDataProperties, setEditable, setForeground, setInvalidInfo, setLocale, setRequired, setSelectOnEnter, setValidator, setValue, setValueModel |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected Object data
protected int caretPosition
protected AWTEvent initialEvent
protected com.klg.jclass.cell.JCCellEditorSupport support
protected boolean selectAll
protected com.klg.jclass.cell.JCKeyModifier[] reservedKeys
protected com.klg.jclass.cell.validate.ValidateSupport validate_support
Constructor Detail |
public JCTextFieldCellEditor()
JCTextFieldCellEditor
object.
public JCTextFieldCellEditor(Class c, com.klg.jclass.field.validate.JCValidator v)
JCTextFieldCellEditor
, which expects an object
of the specified class, that uses the specified validator.
c
- the class type the editor will expectv
- the validator that validates input in the editorMethod Detail |
public void initialize(AWTEvent ev, com.klg.jclass.cell.JCCellInfo info, Object o)
JCCellEditor
initialize()
before the edit starts to
let the editor know what kind of event started the edit
(via the AWTEvent
object).
info.getDrawingArea()
.
Implementors must handle null AWTEvent
s.
initialize
in interface JCCellEditor
ev
- event that initiated the edit operationinfo
- cell that displays information for the editoro
- item to be editedpublic boolean getSelectAll()
getSelectAll
in interface JCCellTextEditor
true
if text is selected on initializationpublic Component getComponent()
JCTextField
component.
getComponent
in interface JCCellEditor
JCTextField
componentpublic Object getCellEditorValue()
getCellEditorValue
in interface JCCellEditor
public String getCellEditorText()
getCellEditorText
in interface JCCellTextEditor
public void setCellEditorText(String text)
setCellEditorText
in interface JCCellTextEditor
text
- the new cell editor text valuepublic boolean isModified()
true
if the data has been modified.
isModified
in interface JCCellEditor
protected boolean fireValidated(com.klg.jclass.cell.validate.JCValidateEvent ev)
public boolean stopCellEditing()
stopCellEditing
in interface JCCellEditor
public void cancelCellEditing()
cancelCellEditing
in interface JCCellEditor
public Dimension getPreferredSize(Graphics gc, com.klg.jclass.cell.JCCellInfo cellInfo, Object o)
public com.klg.jclass.cell.JCKeyModifier[] getReservedKeys()
getReservedKeys
in interface JCCellEditor
public void setVisible(boolean b)
setVisible
in order to control the caret
position.
setVisible
in class JComponent
b
- the new value of visiblepublic void addCellEditorListener(com.klg.jclass.cell.JCCellEditorListener l)
addCellEditorListener
in interface JCCellEditorEventSource
l
- the CellEditorListener
public void removeCellEditorListener(com.klg.jclass.cell.JCCellEditorListener l)
removeCellEditorListener
in interface JCCellEditorEventSource
l
- the CellEditorListener
public void processKeyEvent(KeyEvent e)
processKeyEvent
in interface JCCellTextEditor
processKeyEvent
in class JComponent
e
- the event to passpublic void keyPressed(KeyEvent e)
keyPressed
in interface KeyListener
public void mouseClicked(MouseEvent e)
mouseClicked
in interface MouseListener
public void mouseEntered(MouseEvent e)
mouseEntered
in interface MouseListener
public void mouseExited(MouseEvent e)
mouseExited
in interface MouseListener
public void mousePressed(MouseEvent e)
mousePressed
in interface MouseListener
public void mouseReleased(MouseEvent e)
mouseReleased
in interface MouseListener
public void keyReleased(KeyEvent e)
keyReleased
in interface KeyListener
public void keyTyped(KeyEvent e)
keyTyped
in interface KeyListener
public void selectAllText()
CellInfo
to select all the text in the component.
public void addValidateListener(com.klg.jclass.cell.validate.JCValidateListener l)
ValidateListener
to the list.
addValidateListener
in interface JCValidateInterface
l
- the listener to be addedpublic void removeValidateListener(com.klg.jclass.cell.validate.JCValidateListener l)
ValidateListener
from the list.
removeValidateListener
in interface JCValidateInterface
l
- the listener to be removed
|
Copyright © 2004 Quest Software Inc.. All rights reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |