G4P GUI Builder
4.4
Visual GUI designer for the G4P v4.3.1 library
|
Public Member Functions | |
EditorJTextfield () | |
boolean | stopCellEditing () |
Component | getTableCellEditorComponent (JTable table, Object value, boolean isSelected, int row, int column) |
Object | getCellEditorValue () |
Public Member Functions inherited from g4p.tool.gui.propertygrid.EditorBase | |
void | setSelected (Object value) |
Protected Member Functions | |
void | doneWithEditing () |
void | setValidHint (boolean valid) |
Static Protected Attributes | |
static JTextField | component |
static Color | ok = new Color(200,255,200) |
static Color | notok = new Color(255,200,200) |
Private Member Functions | |
boolean | isValid (Object vo) |
Additional Inherited Members | |
Public Attributes inherited from g4p.tool.gui.propertygrid.EditorBase | |
Validator | validator = null |
Public Attributes inherited from g4p.tool.TFileConstants | |
final String | SEP = File.separator |
final String | PDE_TAB_PRETTY_NAME = "gui" |
final String | PDE_TAB_NAME = PDE_TAB_PRETTY_NAME + ".pde" |
final String | CONFIG_FOLDER = "GUI_BUILDER_DATA" |
final String | GUI_MODEL_FILE_FILTER = "gui.ser." |
final String | GUI_MODEL_FILENAME = GUI_MODEL_FILE_FILTER + G4PTool.getCompatibleVersionNo() |
final String | GUI_MODEL_FILE = CONFIG_FOLDER + SEP + GUI_MODEL_FILENAME |
final String | G4P_TOOL_DATA_FOLDER = "tools" + SEP + "##project.name##" + SEP + "data" |
final String | G4P_LIB = "G4P" + SEP + "library" + SEP + "G4P.jar" |
final String | GUI_PDE_BASE = G4P_TOOL_DATA_FOLDER + SEP + "gui_base.txt" |
final String | TAB0_PDE_BASE = G4P_TOOL_DATA_FOLDER + SEP + "tab0.txt" |
Default editor for text and numeric input.
The key to this class is selecting the correct validator.
g4p.tool.gui.propertygrid.EditorJTextfield.EditorJTextfield | ( | ) |
Create an integer editor component that accepts any valid integer.
Object g4p.tool.gui.propertygrid.EditorJTextfield.getCellEditorValue | ( | ) |
This is called when the editor component loses focus and retrieves the final value for the table model
Component g4p.tool.gui.propertygrid.EditorJTextfield.getTableCellEditorComponent | ( | JTable | table, |
Object | value, | ||
boolean | isSelected, | ||
int | row, | ||
int | column | ||
) |
This is called when the table cell gets focus and returns the editor component.
|
private |
See if the user supplied in
vo |
boolean g4p.tool.gui.propertygrid.EditorJTextfield.stopCellEditing | ( | ) |
Get the latest value and make sure it is valid or empty.
If it is invalid then prevent the focus leaving the component.