org.jgraph.graph
Class DefaultRealEditor
java.lang.Object
javax.swing.AbstractCellEditor
javax.swing.DefaultCellEditor
org.jgraph.graph.DefaultRealEditor
- All Implemented Interfaces:
- Serializable, CellEditor, TableCellEditor, TreeCellEditor, GraphCellEditor
public class DefaultRealEditor
- extends DefaultCellEditor
- implements GraphCellEditor
The default editor for graph cells.
- Version:
- 1.0 1/1/02
- Author:
- Gaudenz Alder
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultRealEditor
public DefaultRealEditor(JTextField textField)
- Constructs a DefaultCellEditor that uses a text field.
- Parameters:
textField
- a JTextField object ...
DefaultRealEditor
public DefaultRealEditor(JCheckBox checkBox)
- Constructs a DefaultCellEditor object that uses a check box.
- Parameters:
checkBox
- a JCheckBox object ...
DefaultRealEditor
public DefaultRealEditor(JComboBox comboBox)
- Constructs a DefaultCellEditor object that uses a combo box.
- Parameters:
comboBox
- a JComboBox object ...
getGraphCellEditorComponent
public Component getGraphCellEditorComponent(JGraph graph,
Object value,
boolean isSelected)
- Description copied from interface:
GraphCellEditor
- Sets an initial value for the editor. This will cause
the editor to stopEditing and lose any partially edited value
if the editor is editing when this method is called.
Returns the component that should be added to the client's
Component hierarchy. Once installed in the client's hierarchy
this component will then be able to draw and receive user input.
- Specified by:
getGraphCellEditorComponent
in interface GraphCellEditor
- Parameters:
graph
- the JGraph that is asking the editor to edit
This parameter can be null.value
- the value of the cell to be edited.isSelected
- true if the cell is to be rendered with
selection highlighting
- Returns:
- the component for editing