|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jurvis.swing.JvSwingFactory
public class JvSwingFactory
A factory for creating Swing components.
| Constructor Summary | |
|---|---|
protected |
JvSwingFactory()
Construct a new JvSwingFactory. |
| Method Summary | |
|---|---|
void |
apply(Component component,
Component parent)
Apply any properties found for the named object object. |
Action |
applyAction(Action action,
Component parent)
Apply any properties and/or factory customizations to an Action. |
Action |
applyAction(Action action,
Component parent,
String name)
Apply any properties and/or factory customizations to an Action. |
JvApplication |
applyApplication(JvApplication application)
Apply any properties to an JvApplication. |
JButton |
applyButton(JButton button,
Component parent,
String name)
Apply any properties to an JButton. |
JCheckBox |
applyCheckBox(JCheckBox checkBox,
Component parent,
String name)
Apply any properties to an JCheckBox. |
JComboBox |
applyComboBox(JComboBox comboBox,
Component parent,
String name)
Apply any properties to an JComboBox. |
JDialog |
applyDialog(JDialog dialog,
Component parent,
String name)
Apply any properties to an JDialog. |
JEditorPane |
applyEditorPane(JEditorPane editorPane,
Component parent,
String name)
Apply any properties to an JEditorPane. |
JFileChooser |
applyFileChooser(JFileChooser fileChooser,
Component parent,
String name)
Apply any properties to an JFileChooser. |
JLabel |
applyLabel(JLabel label,
Component parent,
String name)
Apply any properties to an JLabel. |
JList |
applyList(JList list,
Component parent,
String name)
Apply any properties to an JList. |
JMenu |
applyMenu(JMenu menu,
Component parent,
String name)
Apply any properties to an JMenu. |
JMenuBar |
applyMenuBar(JMenuBar menuBar,
Component parent,
String name)
Apply any properties to an JMenuBar. |
JMenuItem |
applyMenuItem(JMenuItem menuItem,
Component parent,
String name)
Apply any properties to a JMenuItem. |
JOptionPane |
applyOptionPane(JOptionPane optionPane,
Component parent,
String name)
Apply any properties to an JOptionPane. |
JPanel |
applyPanel(JPanel panel,
Component parent,
String name)
Apply any properties to an JPanel. |
JPasswordField |
applyPasswordField(JPasswordField passwordField,
Component parent,
String name)
Apply any properties to an JPasswordField. |
JPopupMenu |
applyPopupMenu(JPopupMenu popupMenu,
Component parent,
String name)
Apply any properties to an JPopupMenu. |
JRadioButton |
applyRadioButton(JRadioButton radioButton,
Component parent,
String name)
Apply any properties to a JRadioButton. |
JScrollPane |
applyScrollPane(JScrollPane scrollPane,
Component parent,
String name)
Apply any properties to an JScrollPane. |
JSplitPane |
applySplitPane(JSplitPane splitPane,
Component parent,
String name)
Apply any properties to an JSplitPane. |
JvStatusBar |
applyStatusBar(JvStatusBar statusBar,
Component parent,
String name)
Apply any properties to an JvStatusBar. |
JTabbedPane |
applyTabbedPane(JTabbedPane tabbedPane,
Component parent,
String name)
Apply any properties to an JTabbedPane. |
JTable |
applyTable(JTable table,
Component parent,
String name)
Apply any properties to an JTable. |
TableColumn |
applyTableColumn(TableColumn tableColumn,
JTable parent,
String name)
Apply any properties to an JTableColumn. |
JTextField |
applyTextField(JTextField textField,
Component parent,
String name)
Apply any properties to an JTextField. |
JToggleButton |
applyToggleButton(JToggleButton toggleButton,
Component parent,
String name)
Apply any properties to an JToggleButton. |
JToolBar |
applyToolBar(JToolBar toolBar,
Component parent,
String name)
Apply any properties to an JToolBar. |
JButton |
applyToolItem(JButton toolItem,
Component parent,
String name)
Apply any properties to a JButton. |
JTree |
applyTree(JTree tree,
Component parent,
String name)
Apply any properties to an JTree. |
JvView |
applyView(JvView view,
Component parent,
String name)
Apply any properties to an NView. |
JDialog |
applyWaitDialog(JDialog dlg,
Component parent,
String name,
String text,
String imageName)
Apply any properties on a JDialog to be used to display a wait message. |
Action |
createAboutAction(Component parent,
String name,
URL aboutURL)
Construct a JvAboutAction with the given name
that controls the specified details pane. |
JvApplication |
createApplication(String name)
Construct an NApplication with the given name. |
JButton |
createButton(Component parent,
Action action)
Construct a JButton based on an Action. |
JButton |
createButton(Component parent,
String name)
Construct a JButton. |
JCheckBox |
createCheckBox(Component parent,
String name)
Construct a JCheckBox. |
JComboBox |
createComboBox(Component parent,
String name,
ComboBoxModel model)
Construct a JComboBox. |
JComboBox |
createComboBox(Component parent,
String name,
Object[] items)
Construct a JComboBox. |
JComboBox |
createComboBox(Component parent,
String name,
Vector items)
Construct a JComboBox. |
protected JvField |
createdField(JvField field,
JComponent fieldComp,
JLabel label,
String propertyName)
Perform any final initialization of the newly created JvField. |
JEditorPane |
createEditorPane(Component parent,
String name,
String contentType)
Construct a JEditorPane. |
JEditorPane |
createEditorPane(Component parent,
String name,
String contentType,
String text)
Construct a JEditorPane. |
JDialog |
createErrorDialog(Component parent,
String name)
Construct a dialog displaying a error message to the user. |
JDialog |
createErrorDialog(Component parent,
String name,
Object[] args)
Construct a dialog displaying a error message to the user. |
JvField |
createField(Container parent,
Class clazz,
String property)
Create a JvField named property to edit the
property of instance of class clazz. |
JvField |
createField(Container parent,
Class clazz,
String property,
Object[] values)
Construct a JvField to edit the property of instance
class clazz. |
JvField |
createField(Container parent,
String name,
Class propertyType)
Create a JvField named name to edit a property of
type propertyType. |
JvField |
createField(Container parent,
String name,
Class clazz,
String property)
Create a JvField named name to edit the
property of instance of class clazz. |
JvField |
createField(Container parent,
String name,
String propertyName,
Class propertyType)
Create a JvField named name to edit a property of
type propertyType. |
JFileChooser |
createFileChooser(Component parent,
String name)
Construct a JFileChooser. |
JMenuItem |
createHelpMenuItem(Component parent,
String name)
Construct a JMenuItem that invokes help and add it to its
parent. |
void |
createHorizontalSpace(Container parent,
GridBagConstraints gbc)
Create a GUI that takes some horizontal space in the parent container. |
ImageIcon |
createIcon(String name)
Finds an icon with the given name. |
JLabel |
createLabel(Component parent,
String name)
Construct a JLabel. |
JComponent |
createLineSeparator(JToolBar parent)
Create a Microsoft Windows-style vertical-line separator for a toolbar. |
JList |
createList(Component parent,
String name,
ListModel model)
Construct a JList. |
JMenu |
createMenu(Component parent,
String name)
Construct a JMenu and add it to its parent. |
JMenuBar |
createMenuBar(Component parent,
String name)
Construct a JMenuBar. |
JMenuItem |
createMenuItem(Component parent,
Action action)
Construct a JMenuItem and add it to its parent. |
JMenuItem |
createMenuItem(Component parent,
String name)
Construct a JMenuItem and add it to it's parent. |
JMenuItem |
createMenuItem(Component parent,
String name,
Action action)
Construct a JMenuItem and add it to it's parent. |
JDialog |
createOptionDialog(Component parent,
JOptionPane optionPane,
String name)
Construct a dialog displaying a JOptionPane to the user. |
JOptionPane |
createOptionPane(Component parent,
String name,
int messageType)
Construct a JOptionPane. |
JOptionPane |
createOptionPane(Component parent,
String name,
int messageType,
int optionType)
Construct a JOptionPane. |
JOptionPane |
createOptionPane(Component parent,
String name,
int messageType,
int optionType,
Object message)
Construct a JOptionPane. |
JOptionPane |
createOptionPane(Component parent,
String name,
int messageType,
int optionType,
Object[] args)
Construct a JOptionPane. |
JPanel |
createPanel(Component parent,
String name)
Construct a JPanel. |
JPanel |
createPanel(Component parent,
String name,
LayoutManager layout)
Construct a JPanel with the specified layout manager. |
JPasswordField |
createPasswordField(Component parent,
String name)
Construct a JPasswordField. |
JPopupMenu |
createPopupMenu(Component parent,
String name)
Construct a JPopupMenu and add it to its parent. |
JRadioButton |
createRadioButton(Component parent,
String name)
Construct a JRadioButton. |
JRadioButtonMenuItem |
createRadioMenuItem(Component parent,
Action action)
Construct a JRadioButtonMenuItem and add it to it's parent. |
JTextField |
createReadOnlyTextField(Component parent,
String name)
Construct a JTextField that is intended for only display
purposes. |
JScrollPane |
createScrollPane(Component parent,
String name,
Component view)
Construct a JScrollPane. |
JComponent |
createSpaceSeparator(JToolBar parent)
Create a space separator for a toolbar. |
JSplitPane |
createSplitPane(Component parent,
String name)
Construct a JSplitPane. |
JvStatusBar |
createStatusBar(Component parent,
String name)
Construct a JvStatusBar. |
void |
createTab(JTabbedPane parent,
Component component)
Construct a new tab for a JTabbedPane. |
void |
createTab(JTabbedPane parent,
String name,
Component component)
Construct a new tab for a JTabbedPane. |
JTabbedPane |
createTabbedPane(Component parent,
String name)
Construct a JTabbedPane. |
JTable |
createTable(Component parent,
String name,
TableModel model)
Construct a JTable. |
TableColumn |
createTableColumn(JTable parent,
String name,
int modelIndex)
Construct a JTableColumn. |
JTextField |
createTextField(Component parent,
String name)
Construct a JTextField. |
JvField |
createTextField(Container parent,
Class clazz,
String property,
int maxLength)
Create a JvField named named to edit the
property of instance of class clazz. |
JToggleButton |
createToggleButton(Component parent,
String name)
Construct a JToggleButton. |
JToolBar |
createToolBar(Component parent,
String name)
Construct a JToolBar. |
JButton |
createToolItem(Component parent,
Action action)
Construct a JButton used in a tool bar and add it to its
parent. |
JTree |
createTree(Component parent,
String name,
TreeModel model)
Construct a JTree. |
Action |
createUnimplementedAction(Component parent,
String name)
Construct a placeholder for an unimplemented action. |
void |
createVerticalSpace(Container parent,
GridBagConstraints gbc)
Create a GUI that takes some vertical space in the parent container. |
Action |
createViewAction(Component parent,
String name,
Component component)
Construct a JvViewAction with the given name that controls
the specified component. |
Action |
createViewDetailsAction(JvExplorer explorer,
String name,
JvExplorerDetails details)
Construct a JvViewExplorerDetailsAction with the given name
that controls the specified details pane. |
JDialog |
createWaitDialog(Component parent,
String name)
Construct a JDialog to be used to display a wait message. |
JDialog |
createWarningDialog(Component parent,
String name)
Construct a dialog displaying a warning message to the user. |
ClassLoader |
getClassLoader()
Return the ClassLoader used by this factory. |
static JvSwingFactory |
getDefault()
Return the default instance of the UI factory. |
static JvSwingFactory |
getFactory(Component component)
Get the factory used to create the given component or the default factory if there isn't one. |
javax.help.HelpBroker |
getHelpBroker()
Return the HelpBroker used to provide online help for the components
created by this factory. |
URL |
getIconURL(String name)
Finds an icon with the given name and returns its URL. |
JvPropertyLocator |
getPropertyLocator()
Return the JvPropertyLocator used by this factory. |
String |
getString(Component component,
String key)
Convience method to retrieve a property using the factory's JvPropertyLocator. |
static void |
setDefault(JvSwingFactory factory)
Set the default factory instance. |
void |
setHelpBroker(javax.help.HelpBroker helpBroker)
Set the HelpBroker used to provide online help for the components
created by this factory. |
void |
showErrorDialog(Component parent,
String name)
Display a dialog containing a error message. |
void |
showErrorDialog(Component parent,
String name,
Object[] args)
Display a dialog containing a error message. |
void |
showErrorDialog(Component parent,
String name,
String message)
Display a dialog containing a error message. |
int |
showOkCancelDialog(Component parent,
String name)
Display a dialog displaying a message with a Ok/Cancel prompt to the user. |
int |
showOkCancelDialog(Component parent,
String name,
Object[] args)
Display a dialog displaying a message with a OK/Cancel prompt to the user. |
int |
showOkDialog(Component parent,
String name)
Display a dialog displaying a message with an Ok prompt to the user. |
int |
showOkDialog(Component parent,
String name,
Object[] args)
Display a dialog displaying a message with an OK prompt to the user. |
int |
showOptionDialog(Component parent,
JOptionPane optionPane,
String name)
Construct and display a modal dialog containing a JOptionPane to the user. |
int |
showOptionDialog(JDialog dialog,
JOptionPane optionPane)
Display a modal dialog containing a JOptionPane to the
user. |
void |
showWarningDialog(Component parent,
String name)
Display a dialog containing a warning message. |
int |
showYesNoCancelDialog(Component parent,
String name)
Display a dialog displaying a message with a Yes/No/Cancel prompt to the user. |
int |
showYesNoCancelDialog(Component parent,
String name,
Object[] args)
Display a dialog displaying a message with a Yes/No/Cancel prompt to the user. |
int |
showYesNoDialog(Component parent,
String name)
Display a dialog displaying a message with a Yes/No prompt to the user. |
int |
showYesNoDialog(Component parent,
String name,
Object[] args)
Display a dialog displaying a message with a Yes/No prompt to the user. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected JvSwingFactory()
JvSwingFactory.
| Method Detail |
|---|
public static void setDefault(JvSwingFactory factory)
factory - the instance to be used by defaultpublic static JvSwingFactory getDefault()
public static JvSwingFactory getFactory(Component component)
component - the component from which to obtain the factory
public javax.help.HelpBroker getHelpBroker()
HelpBroker used to provide online help for the components
created by this factory.
HelpBrokerpublic void setHelpBroker(javax.help.HelpBroker helpBroker)
HelpBroker used to provide online help for the components
created by this factory.
helpBroker - the factory's HelpBrokerpublic final JvPropertyLocator getPropertyLocator()
JvPropertyLocator used by this factory.
JvPropertyLocatorpublic final ClassLoader getClassLoader()
ClassLoader used by this factory.
ClassLoader
public String getString(Component component,
String key)
JvPropertyLocator.
component - the component providing contextkey - the key of the property to return
JvPropertyLocator.getString(java.lang.String)
public void apply(Component component,
Component parent)
object.
This method uses the object's BeanInfo to determine the
object's properties. For each writable property, the property is
searched for using the factories JvPropertyLocator and
within the given parent and name context.
component - the component to modifyparent - the parent of the object
public Action applyAction(Action action,
Component parent)
Action. This method sets the action's name and uses the
factory's JvPropertyLocator to find the action's icon
("name.icon"), tooltip ("name.toolTipText"), accelerator
("name.accelerator"), and mnemonic ("name.mnemonic").
action - the action to customizeparent - the parent of the action
public Action applyAction(Action action,
Component parent,
String name)
Action. This method sets the action's name and uses the
factory's JvPropertyLocator to find the action's icon
("name.icon"), tooltip ("name.toolTipText"), accelerator
("name.accelerator"), and mnemonic ("name.mnemonic").
action - the action to customizeparent - the parent of the actionname - the name of the action
public Action createAboutAction(Component parent,
String name,
URL aboutURL)
JvAboutAction with the given name
that controls the specified details pane.
parent - the parent of the Actionname - the name of the ActionaboutURL - for the application being describe.public JvApplication createApplication(String name)
NApplication with the given name.
name - the name of the applicationpublic JvApplication applyApplication(JvApplication application)
JvApplication.
application - the application to modify
public JButton createButton(Component parent,
String name)
JButton.
parent - the parent of the JButtonname - the name of the JButton
JButton
public JButton createButton(Component parent,
Action action)
JButton based on an Action. The
name of the button is extracted from the Action as well as
the icon, tooltip, and mnemonic.
parent - the parent of the JButtonaction - the action
JButton
public JButton applyButton(JButton button,
Component parent,
String name)
JButton.
button - the button to modifyparent - the parent of the JButtonname - the name of the JButton
public JCheckBox createCheckBox(Component parent,
String name)
JCheckBox.
parent - the parent of the JCheckBoxname - the name of the JCheckBox
JCheckBox
public JCheckBox applyCheckBox(JCheckBox checkBox,
Component parent,
String name)
JCheckBox.
checkBox - the checkBox to modifyparent - the parent of the JCheckBoxname - the name of the JCheckBox
public JRadioButton createRadioButton(Component parent,
String name)
JRadioButton.
parent - the parent of the JRadioButtonname - the name of the JRadioButton
JRadioButton
public JRadioButton applyRadioButton(JRadioButton radioButton,
Component parent,
String name)
JRadioButton.
radioButton - the JRadioButton to modifyparent - the parent of the JRadioButtonname - the name of the JRadioButton
public JComboBox createComboBox(Component parent,
String name,
ComboBoxModel model)
JComboBox.
parent - the parent of the JComboBoxname - the name of the JComboBoxmodel - the ComboBoxModel that provides the
displayed list of items
JComboBox
public JComboBox createComboBox(Component parent,
String name,
Object[] items)
JComboBox.
parent - the parent of the JComboBoxname - the name of the JComboBoxitems - an array of objects to insert into the combo box
JComboBox
public JComboBox createComboBox(Component parent,
String name,
Vector items)
JComboBox.
parent - the parent of the JComboBoxname - the name of the JComboBoxitems - a vector of objects to insert into the combo box
JComboBox
public JComboBox applyComboBox(JComboBox comboBox,
Component parent,
String name)
JComboBox.
comboBox - the comboBox to modifyparent - the parent of the JComboBoxname - the name of the JComboBox
public JDialog applyDialog(JDialog dialog,
Component parent,
String name)
JDialog.
dialog - the dialog to modifyparent - the parent of the JDialogname - the name or message of the JDialog
public JDialog createErrorDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
public JDialog createErrorDialog(Component parent,
String name,
Object[] args)
parent - the parent of the JDialogname - the name or message of the JDialogargs - if non-null, treat the message as a MessageFormat
pattern and use these args to format the message
public void showErrorDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
public void showErrorDialog(Component parent,
String name,
Object[] args)
parent - the parent of the JDialogname - the name or message of the JDialogargs - if non-null, treat the message as a MessageFormat
pattern and use these args to format the message
public void showErrorDialog(Component parent,
String name,
String message)
parent - the parent of the JDialogname - the name of the JDialogmessage - the error message
public JEditorPane createEditorPane(Component parent,
String name,
String contentType)
JEditorPane.
parent - the parent of the JEditorPanename - the name of the JEditorPanecontentType - the content type of the editor pane
JEditorPaneJEditorPane
public JEditorPane createEditorPane(Component parent,
String name,
String contentType,
String text)
JEditorPane.
parent - the parent of the JEditorPanename - the name of the JEditorPanecontentType - the content type of the editor panetext - the text to initialize with
JEditorPaneJEditorPane
public JEditorPane applyEditorPane(JEditorPane editorPane,
Component parent,
String name)
JEditorPane.
editorPane - the editorPane to modifyparent - the parent of the JEditorPanename - the name of the JEditorPane
public JvField createField(Container parent,
Class clazz,
String property)
JvField named property to edit the
property of instance of class clazz.
Introspection is used to determine the type (class) of the property and
find the appropriate PropertyEditor. The actual UI
component used to edit the property depends on the property's type. If
the property is of type JvEnumerator, an JvEnumeratorField
is created to display the enumerated values within a
JComboBox. If the property is of type JvHTMLText, a
JvPropertyEditorField is created to display the text in a
JEditorPane wrapped by a JScrollPane. If the
property is of some other type, a JvPropertyEditorField is
created to display the text in a JTextField.
parent - the UI parent of the created fieldclazz - the class whose property will be editedproperty - the name of the property to be edited
JvField
public JvField createField(Container parent,
String name,
Class clazz,
String property)
JvField named name to edit the
property of instance of class clazz.
Introspection is used to determine the type (class) of the property and
find the appropriate PropertyEditor. The actual UI
component used to edit the property depends on the property's type. If
the property is of type JvEnumerator, an JvEnumeratorField
is created to display the enumerated values within a
JComboBox. If the property is of type JvHTMLText, a
JvPropertyEditorField is created to display the text in a
JEditorPane wrapped by a JScrollPane. If the
property is of some other type, a JvPropertyEditorField is
created to display the text in a JTextField.
parent - the UI parent of the created fieldname - the name of fieldclazz - the class whose property will be editedproperty - the name of the property to be edited
JvField
public JvField createField(Container parent,
String name,
Class propertyType)
JvField named name to edit a property of
type propertyType. The actual UI component used to edit
the property depends on the property's type. If the property is of type
JvEnumerator, an JvEnumeratorField is created to display
the enumerated values within a JComboBox. If the property
is of type JvHTMLText, a JvPropertyEditorField is created
to display the text in a JEditorPane wrapped by a
JScrollPane. If the property is of some other type, a
JvPropertyEditorField is created to display the text in a
JTextField.
parent - the UI parent of the created fieldname - the name of fieldpropertyType - the type of the property to edit
JvField
public JvField createField(Container parent,
String name,
String propertyName,
Class propertyType)
JvField named name to edit a property of
type propertyType. The actual UI component used to edit
the property depends on the property's type. If the property is of type
JvEnumerator, an JvEnumeratorField is created to display
the enumerated values within a JComboBox. If the property
is of type JvHTMLText, a JvPropertyEditorField is created
to display the text in a JEditorPane wrapped by a
JScrollPane. If the property is of some other type, a
JvPropertyEditorField is created to display the text in a
JTextField.
parent - the UI parent of the created fieldname - the name of fieldpropertyName - the name of the property to be edited; may be nullpropertyType - the type of the property to edit
JvField
public JvField createTextField(Container parent,
Class clazz,
String property,
int maxLength)
JvField named named to edit the
property of instance of class clazz.
Introspection is used to determine the type (class) of the property and
find the appropriate PropertyEditor. The actual UI
component used to edit the property depends on the property's type. If
the property is of type JvHTMLText, a JvPropertyEditorField is created to display the text in a
JEditorPane wrapped by a JScrollPane. If the
property is of some other type, a JvPropertyEditorField is
created to display the text in a JTextField. The maximum
allowed length of the value is maxLength.
parent - the UI parent of the created fieldclazz - the class whose property will be editedproperty - the name of the property to be editedmaxLength - the maximum length allowed for the value
JvField
public JvField createField(Container parent,
Class clazz,
String property,
Object[] values)
JvField to edit the property of instance
class clazz. The property may only take one of the values
specified in values. A non-editable JComboBox
is used to display the current value and the choices.
parent - the UI parent of the created fieldclazz - the class whose property will be editedproperty - the name of the property to be editedvalues - the values the property may take
JvField
protected JvField createdField(JvField field,
JComponent fieldComp,
JLabel label,
String propertyName)
JvField.
field - the newly created fieldfieldComp - the main field componentlabel - the label for the fieldpropertyName - the name of the property edited within the field; may be null
public JFileChooser createFileChooser(Component parent,
String name)
JFileChooser.
parent - the parent of the JFileChoosername - the name of the JFileChooser
JFileChooser
public JFileChooser applyFileChooser(JFileChooser fileChooser,
Component parent,
String name)
JFileChooser.
fileChooser - the fileChooser to modifyparent - the parent of the JFileChoosername - the name of the JFileChooser
public void createHorizontalSpace(Container parent,
GridBagConstraints gbc)
parent - the container needing the horizontal spacegbc - GridBagConstraints specifying the location of the spacepublic URL getIconURL(String name)
name - the name of the icon
public ImageIcon createIcon(String name)
name - the name of the icon
public JLabel createLabel(Component parent,
String name)
JLabel.
parent - the parent of the JLabelname - the name of the JLabel
JLabel
public JLabel applyLabel(JLabel label,
Component parent,
String name)
JLabel.
label - the label to modifyparent - the parent of the JLabelname - the name of the JLabelpublic JComponent createLineSeparator(JToolBar parent)
parent - the parent of the separator
public JList createList(Component parent,
String name,
ListModel model)
JList.
parent - the parent of the JListname - the name of the JListmodel - the ListModel to use
JList
public JList applyList(JList list,
Component parent,
String name)
JList.
list - the list to modifyparent - the parent of the JListname - the name of the JList
public JMenu createMenu(Component parent,
String name)
JMenu and add it to its parent.
parent - the parent of the JMenuname - the name of the JMenu
public JMenu applyMenu(JMenu menu,
Component parent,
String name)
JMenu.
menu - the menu to modifyparent - the parent of the JMenuname - the name of the JMenu
public JMenuBar createMenuBar(Component parent,
String name)
JMenuBar.
parent - the parent of the JMenuBarname - the name of the JMenuBar
public JMenuBar applyMenuBar(JMenuBar menuBar,
Component parent,
String name)
JMenuBar.
menuBar - the menu bar to modifyparent - the parent of the JMenuBarname - the name of the JMenuBar
public JMenuItem createMenuItem(Component parent,
String name)
JMenuItem and add it to it's parent.
parent - the parent of the JMenuItemname - the name of the JMenuItem
public JMenuItem createHelpMenuItem(Component parent,
String name)
JMenuItem that invokes help and add it to its
parent.
parent - the parent of the JMenuItemname - the name of the JMenuItem
public JMenuItem createMenuItem(Component parent,
Action action)
JMenuItem and add it to its parent. Use the
name of action as the name of the menu item.
parent - the parent of the JMenuItemaction - the action performed by the menu item
public JMenuItem createMenuItem(Component parent,
String name,
Action action)
JMenuItem and add it to it's parent.
parent - the parent of the JMenuItemname - the name of the JMenuItemaction - the action performed by the menu item
public JMenuItem applyMenuItem(JMenuItem menuItem,
Component parent,
String name)
JMenuItem.
menuItem - the menu item to modifyparent - the parent of the JMenuItemname - the name of the JMenuItem
public JOptionPane createOptionPane(Component parent,
String name,
int messageType)
JOptionPane.
parent - the parent of the JOptionPanename - the name of the JOptionPanemessageType - the type of message that is to be displayed:
ERROR_MESSAGE, INFORMATION_MESSAGE, WARNING_MESSAGE,
QUESTION_MESSAGE, or PLAIN_MESSAGE
JOptionPane
public JOptionPane createOptionPane(Component parent,
String name,
int messageType,
int optionType)
JOptionPane.
parent - the parent of the JOptionPanename - the name of the JOptionPanemessageType - the type of message that is to be displayed:
ERROR_MESSAGE, INFORMATION_MESSAGE, WARNING_MESSAGE,
QUESTION_MESSAGE, or PLAIN_MESSAGEoptionType - an int designating the options available on the dialog:
YES_NO_OPTION, or YES_NO_CANCEL_OPTION
JOptionPane
public JOptionPane createOptionPane(Component parent,
String name,
int messageType,
int optionType,
Object[] args)
JOptionPane.
parent - the parent of the JOptionPanename - the name of the JOptionPanemessageType - the type of message that is to be displayed:
ERROR_MESSAGE, INFORMATION_MESSAGE, WARNING_MESSAGE,
QUESTION_MESSAGE, or PLAIN_MESSAGEoptionType - an int designating the options available on the dialog:
YES_NO_OPTION, or YES_NO_CANCEL_OPTIONargs - if non-null, treat the message as a MessageFormat
pattern and use these args to format the message
JOptionPane
public JOptionPane createOptionPane(Component parent,
String name,
int messageType,
int optionType,
Object message)
JOptionPane.
parent - the parent of the JOptionPanename - the name of the JOptionPanemessageType - the type of message that is to be displayed:
ERROR_MESSAGE, INFORMATION_MESSAGE, WARNING_MESSAGE,
QUESTION_MESSAGE, or PLAIN_MESSAGEoptionType - an int designating the options available on the dialog:
YES_NO_OPTION, or YES_NO_CANCEL_OPTIONmessage - the message of the JOptionPane
JOptionPane
public JOptionPane applyOptionPane(JOptionPane optionPane,
Component parent,
String name)
JOptionPane.
optionPane - the optionPane to modifyparent - the parent of the JOptionPanename - the name or message of the JOptionPane
public JDialog createOptionDialog(Component parent,
JOptionPane optionPane,
String name)
JOptionPane to the user.
parent - the parent of the JDialogoptionPane - the JOptionPanename - the name or message of the JDialog
JDialog
public int showOptionDialog(Component parent,
JOptionPane optionPane,
String name)
JOptionPane to the user. This method does not return until
the user closes the dialog or presses one of the dialog buttons.
parent - the parent of the JDialogoptionPane - the JOptionPanename - the name or message of the JDialog
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public int showOptionDialog(JDialog dialog,
JOptionPane optionPane)
JOptionPane to the
user. This method does not return until the user closes the dialog or
presses one of the dialog buttons.
dialog - the modal dialog to displayoptionPane - the JOptionPane contained within dialog
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public JPanel createPanel(Component parent,
String name)
JPanel.
parent - the parent of the JPanelname - the name of the JPanel
JPanel
public JPanel createPanel(Component parent,
String name,
LayoutManager layout)
JPanel with the specified layout manager.
parent - the parent of the JPanelname - the name of the JPanellayout - the layout manager
JPanel
public JPanel applyPanel(JPanel panel,
Component parent,
String name)
JPanel.
panel - the panel to modifyparent - the parent of the JPanelname - the name of the JPanel
public JPasswordField createPasswordField(Component parent,
String name)
JPasswordField.
parent - the parent of the JPasswordFieldname - the name of the JPasswordField
JPasswordField
public JPasswordField applyPasswordField(JPasswordField passwordField,
Component parent,
String name)
JPasswordField.
passwordField - the passwordField to modifyparent - the parent of the JPasswordFieldname - the name of the JPasswordField
public JPopupMenu createPopupMenu(Component parent,
String name)
JPopupMenu and add it to its parent.
parent - the parent of the JPopupMenuname - the name of the JPopupMenu
public JPopupMenu applyPopupMenu(JPopupMenu popupMenu,
Component parent,
String name)
JPopupMenu.
popupMenu - the popupMenu to modifyparent - the parent of the JPopupMenuname - the name of the JPopupMenu
public int showOkDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public int showOkDialog(Component parent,
String name,
Object[] args)
parent - the parent of the JDialogname - the name or message of the JDialogargs - if non-null, treat the message as a MessageFormat
pattern and use these args to format the message
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public int showOkCancelDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public int showOkCancelDialog(Component parent,
String name,
Object[] args)
parent - the parent of the JDialogname - the name or message of the JDialogargs - if non-null, treat the message as a MessageFormat
pattern and use these args to format the message
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public JRadioButtonMenuItem createRadioMenuItem(Component parent,
Action action)
JRadioButtonMenuItem and add it to it's parent.
parent - the parent of the JMenuRadioButtonItemaction - the Action to be associated with the menu item
JRadioButtonMenuItem
public JTextField createReadOnlyTextField(Component parent,
String name)
JTextField that is intended for only display
purposes. The user will be able to select and copy text from the field
and can scroll within the field, but will not be allowed to modify it.
parent - the parent of the JTextFieldname - the name of the JTextField
JTextField
public JScrollPane createScrollPane(Component parent,
String name,
Component view)
JScrollPane.
parent - the parent of the JScrollPanename - the name of the JScrollPaneview - the component to display in the scrollpanes viewport
JScrollPane
public JScrollPane applyScrollPane(JScrollPane scrollPane,
Component parent,
String name)
JScrollPane.
scrollPane - the scrollPane to modifyparent - the parent of the JScrollPanename - the name of the JScrollPanepublic JComponent createSpaceSeparator(JToolBar parent)
parent - the parent of the separator
public JSplitPane createSplitPane(Component parent,
String name)
JSplitPane.
parent - the parent of the JSplitPanename - the name of the JSplitPane
JSplitPane
public JSplitPane applySplitPane(JSplitPane splitPane,
Component parent,
String name)
JSplitPane.
splitPane - the splitPane to modifyparent - the parent of the JSplitPanename - the name of the JSplitPane
public JvStatusBar createStatusBar(Component parent,
String name)
JvStatusBar.
parent - the parent of the JvStatusBarname - the name of the JvStatusBar
public JvStatusBar applyStatusBar(JvStatusBar statusBar,
Component parent,
String name)
JvStatusBar.
statusBar - the status bar to modifyparent - the parent of the JvStatusBarname - the name of the JvStatusBar
public void createTab(JTabbedPane parent,
Component component)
JTabbedPane. The name of the
component is used for the name of the tab. This method uses the
factory's JvPropertyLocator to find the tab's text
("name.tab").
parent - the parent JTabbedPane of the new tabcomponent - the component to display in the new tab
public void createTab(JTabbedPane parent,
String name,
Component component)
JTabbedPane. This method uses
the factory's JvPropertyLocator to find the tab's text
("name.tab").
parent - the parent JTabbedPane of the new tabname - the name of the new tabcomponent - the component to display in the new tab
public JTabbedPane createTabbedPane(Component parent,
String name)
JTabbedPane.
parent - the parent of the JTabbedPanename - the name of the JTabbedPane
JTabbedPane
public JTabbedPane applyTabbedPane(JTabbedPane tabbedPane,
Component parent,
String name)
JTabbedPane.
tabbedPane - the tabbedPane to modifyparent - the parent of the JTabbedPanename - the name of the JTabbedPane
public JTable createTable(Component parent,
String name,
TableModel model)
JTable.
parent - the parent of the JTablename - the name of the JTablemodel - the TableModel to use
JTable
public JTable applyTable(JTable table,
Component parent,
String name)
JTable.
table - the table to modifyparent - the parent of the JTablename - the name of the JTable
public TableColumn createTableColumn(JTable parent,
String name,
int modelIndex)
JTableColumn.
parent - the parent of the JTableColumnname - the name of the JTableColumn
JTableColumn
public TableColumn applyTableColumn(TableColumn tableColumn,
JTable parent,
String name)
JTableColumn.
tableColumn - the tableColumn to modifyparent - the parent of the JTableColumnname - the name of the JTableColumn
public JTextField createTextField(Component parent,
String name)
JTextField.
parent - the parent of the JTextFieldname - the name of the JTextField
JTextField
public JTextField applyTextField(JTextField textField,
Component parent,
String name)
JTextField.
textField - the textField to modifyparent - the parent of the JTextFieldname - the name of the JTextField
public JToggleButton createToggleButton(Component parent,
String name)
JToggleButton.
parent - the parent of the JToggleButtonname - the name of the JToggleButton
JToggleButton
public JToggleButton applyToggleButton(JToggleButton toggleButton,
Component parent,
String name)
JToggleButton.
toggleButton - the toggleButton to modifyparent - the parent of the JToggleButtonname - the name of the JToggleButton
public JToolBar createToolBar(Component parent,
String name)
JToolBar.
parent - the parent of the JToolBarname - the name of the JToolBar
public JToolBar applyToolBar(JToolBar toolBar,
Component parent,
String name)
JToolBar.
toolBar - the tool bar to modifyparent - the parent of the JToolBarname - the name of the JToolBar
public JButton createToolItem(Component parent,
Action action)
JButton used in a tool bar and add it to its
parent. The name of the button is extracted from action.
parent - the parent of the JButtonaction - the Action to be associated with the button
JButton toolbar itemcreateButton(Component, Action)
public JButton applyToolItem(JButton toolItem,
Component parent,
String name)
JButton.
toolItem - the tool item to modifyparent - the parent of the JButtonname - the name of the JButton
public JTree createTree(Component parent,
String name,
TreeModel model)
JTree.
parent - the parent of the JTreename - the name of the JTreemodel - the TreeModel to use
JTree
public JTree applyTree(JTree tree,
Component parent,
String name)
JTree.
tree - the tree to modifyparent - the parent of the JTreename - the name of the JTree
public Action createUnimplementedAction(Component parent,
String name)
parent - the parent of the Actionname - the name of the Action
public void createVerticalSpace(Container parent,
GridBagConstraints gbc)
parent - the container needing the vertical spacegbc - GridBagConstraints specifying the location of the space
public JvView applyView(JvView view,
Component parent,
String name)
NView.
view - the view to modify
public Action createViewAction(Component parent,
String name,
Component component)
JvViewAction with the given name that controls
the specified component.
parent - the parent of the Actionname - the name of the Actioncomponent - the controlled component
JvViewAction
public Action createViewDetailsAction(JvExplorer explorer,
String name,
JvExplorerDetails details)
JvViewExplorerDetailsAction with the given name
that controls the specified details pane.
explorer - the explorer displaying the details panelname - the name of the Actiondetails - the controlled details panel
JvViewExplorerDetailsAction
public JDialog createWaitDialog(Component parent,
String name)
JDialog to be used to display a wait message.
The name is used to pick up the dialog title, message text and
the image name from the properties file.
parent - the parent of the JDialogname - the name of the JDialog
JDialog
public JDialog applyWaitDialog(JDialog dlg,
Component parent,
String name,
String text,
String imageName)
JDialog to be used to display a wait message.
dlg - a reference to the JDialog objectparent - the parent of the JPanelname - the name of the JPaneltext - the text to be displayed inside the wait dialogimageName - the name of the gif file to be used in the dialog
JDialog
public JDialog createWarningDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
public void showWarningDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
public int showYesNoDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public int showYesNoDialog(Component parent,
String name,
Object[] args)
parent - the parent of the JDialogname - the name or message of the JDialogargs - if non-null, treat the message as a MessageFormat
pattern and use these args to format the message
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public int showYesNoCancelDialog(Component parent,
String name)
parent - the parent of the JDialogname - the name or message of the JDialog
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
public int showYesNoCancelDialog(Component parent,
String name,
Object[] args)
parent - the parent of the JDialogname - the name or message of the JDialogargs - if non-null, treat the message as a MessageFormat
pattern and use these args to format the message
JOptionPane.showOptionDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||