|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.dc.console.components.ComponentFactory
public final class ComponentFactory
This class is the Component holder for the UI. The look and feel, as well as all the other preference are set here
Field Summary | |
---|---|
static int |
_AUDIOCDREQFIELDTABLE
|
static int |
_AUDIOTRACKREQFIELDTABLE
|
static int |
_BOOKCATEGORYCOMBO
|
static int |
_BOOKREQUIREDFIELDTABLE
|
static int |
_CHECKBOX
|
static int |
_FILEFIELD
|
static int |
_FONTSELECTOR
|
static int |
_LONGTEXTFIELD
|
static int |
_MOVIEREQFIELDTABLE
|
static int |
_MP3GENRECOMBO
|
static int |
_MUSICREQFIELDTABLE
|
static int |
_NUMBERFIELD
|
static int |
_PASSWORDFIELD
|
static int |
_PICTUREFIELD
|
static int |
_RATINGCOMBOBOX
|
static int |
_SHORTTEXTFIELD
|
static int |
_SOFTWARECATEGORYCOMBO
|
static int |
_SOFTWAREREQFIELDTABLE
|
static int |
_THEMEFIELD
|
static int |
_TIMEFIELD
|
static int |
_URLFIELD
|
static int |
_YEARCOMBO
|
static int |
_YESNOCOMBO
|
Constructor Summary | |
---|---|
ComponentFactory()
|
Method Summary | |
---|---|
static javax.swing.JComboBox |
getBookCatComboBox()
|
static javax.swing.border.Border |
getBorder()
Returns a standard border |
static javax.swing.JButton |
getButton(javax.swing.ImageIcon icon)
Returns a standard button |
static javax.swing.JButton |
getButton(javax.swing.ImageIcon icon,
java.lang.String buttonText)
Returns a standard button |
static javax.swing.JButton |
getButton(java.lang.String buttonText)
Returns a standard button |
static javax.swing.JButton |
getButton(java.lang.String buttonText,
int length)
Returns a standard button |
static javax.swing.JCheckBox |
getCheckBox(java.lang.String labelText)
Returns a standard checkbox |
static javax.swing.JColorChooser |
getColorChooser()
|
static javax.swing.JComboBox |
getComboBox()
Returns an empty combobox |
static javax.swing.JComboBox |
getComboBox(int length)
Returns an empty combobox |
static javax.swing.JComponent |
getComponent(int componentIndex,
java.lang.String sLabel,
int maxTextLength)
|
static java.lang.Object |
getComponentValue(int fieldType,
javax.swing.JComponent comp)
|
static DCTable |
getDCTable(boolean readonly,
boolean caching)
|
static DCTable |
getDCTable(DCModule module,
boolean readonly,
boolean caching)
|
static java.awt.Color |
getDisabledColor()
Returns the color for displaying disabled fields |
static javax.swing.JEditorPane |
getEditorPane()
Returns a standard editor pane |
static java.awt.Color |
getEvenRowColor()
|
static javax.swing.JComboBox |
getFieldsComboBox(DCObject o)
Returns a combobox with the Software database field names |
static FileField |
getFileField(boolean save,
boolean dirsOnly)
|
static FileField |
getFileField(boolean save,
boolean dirsOnly,
javax.swing.filechooser.FileFilter filter)
|
static FontSelector |
getFontSelector()
|
static javax.swing.Icon |
getIcon(java.lang.String iconLocation)
Returns a standard icon |
static javax.swing.JLabel |
getLabel(javax.swing.ImageIcon icon)
Returns a standard label with an icon |
static javax.swing.JLabel |
getLabel(java.lang.String labelText)
Returns a standard label with a text |
static javax.swing.JLabel |
getLabel(java.lang.String labelText,
javax.swing.ImageIcon icon)
Returns a standard label with a text and an icon |
static javax.swing.JLabel |
getLabel(java.lang.String labelText,
int length)
Returns a standard label with a text |
static javax.swing.JList |
getList(java.util.Collection data)
|
static LongTextField |
getLongTextField(int maxTextLength)
Returns a text area with all the defaults set |
static javax.swing.JMenu |
getMenu(java.lang.String text)
|
static javax.swing.JMenuBar |
getMenuBar()
Returns a standard menubar |
static javax.swing.JMenuItem |
getMenuItem(javax.swing.ImageIcon icon,
java.lang.String text)
|
static javax.swing.JMenuItem |
getMenuItem(java.lang.String text)
|
static javax.swing.JComboBox |
getMP3GenreComboBox()
Returns a combobox with MP3 genres |
static NumberField |
getNumberField()
|
static java.awt.Color |
getOddRowColor()
|
static PasswordField |
getPasswordField()
|
static PictureField |
getPictureField(boolean allowZoom)
|
static PictureField |
getPictureField(boolean scaled,
boolean allowZoom,
boolean thumbnail)
|
static RatingComboBox |
getRatingComboBox()
|
static javax.swing.JComboBox |
getRealYesNoComboBox()
Returns a combobox with the items "yes" and "no", not starting with and empty String |
static java.awt.Color |
getRequiredColor()
Returns the color for displaying required fields |
static java.awt.Color |
getSelectionColor()
|
static ShortTextField |
getShortTextField(int maxTextLength)
|
static javax.swing.JComboBox |
getSoftwareCatComboBox()
|
static java.awt.Font |
getStandardFont()
Returns the default font |
static java.awt.Font |
getSystemFont()
Returns the default font |
static javax.swing.JTabbedPane |
getTabbedPane()
Returns a standard tabbed pane |
static java.awt.Color |
getTableColor()
Returns the color for the background of tables |
static javax.swing.JButton |
getTableHeader(java.lang.String title)
Returns a standard button |
static java.awt.Color |
getTableHeaderColor()
Returns the color for the table header |
static javax.swing.JTextArea |
getTextArea()
Returns a long text field with all the defaults set |
static java.awt.Color |
getTextColor()
|
static javax.swing.JTextField |
getTextField()
Returns a textfield |
static ThemeSelector |
getThemeSelector()
|
static TimeField |
getTimeField()
|
static javax.swing.border.TitledBorder |
getTitleBorder(java.lang.String title)
Returns a standard border with a title |
static javax.swing.JTree |
getTree(javax.swing.tree.DefaultMutableTreeNode model)
|
static java.awt.Font |
getUnreadableFont()
|
static URLField |
getURLField(int maxLength)
|
static javax.swing.JComboBox |
getYearComboBox()
|
static javax.swing.JComboBox |
getYesNoCombo()
Returns a combobox with the items " ", "yes" and "no" |
static void |
setComponentValue(int fieldType,
javax.swing.JComponent comp,
java.lang.Object value)
|
static javax.swing.JComponent |
setUneditable(javax.swing.JComponent comp)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int _SOFTWARECATEGORYCOMBO
public static final int _YESNOCOMBO
public static final int _MP3GENRECOMBO
public static final int _LONGTEXTFIELD
public static final int _YEARCOMBO
public static final int _CHECKBOX
public static final int _NUMBERFIELD
public static final int _SHORTTEXTFIELD
public static final int _URLFIELD
public static final int _PICTUREFIELD
public static final int _FONTSELECTOR
public static final int _SOFTWAREREQFIELDTABLE
public static final int _MUSICREQFIELDTABLE
public static final int _MOVIEREQFIELDTABLE
public static final int _AUDIOCDREQFIELDTABLE
public static final int _AUDIOTRACKREQFIELDTABLE
public static final int _TIMEFIELD
public static final int _THEMEFIELD
public static final int _RATINGCOMBOBOX
public static final int _FILEFIELD
public static final int _PASSWORDFIELD
public static final int _BOOKREQUIREDFIELDTABLE
public static final int _BOOKCATEGORYCOMBO
Constructor Detail |
---|
public ComponentFactory()
Method Detail |
---|
public static final javax.swing.JComponent getComponent(int componentIndex, java.lang.String sLabel, int maxTextLength)
public static final javax.swing.JComponent setUneditable(javax.swing.JComponent comp)
public static final PasswordField getPasswordField()
public static final FontSelector getFontSelector()
public static final ThemeSelector getThemeSelector()
public static final TimeField getTimeField()
public static final FileField getFileField(boolean save, boolean dirsOnly)
public static final FileField getFileField(boolean save, boolean dirsOnly, javax.swing.filechooser.FileFilter filter)
public static final javax.swing.JList getList(java.util.Collection data)
public static final PictureField getPictureField(boolean scaled, boolean allowZoom, boolean thumbnail)
public static final PictureField getPictureField(boolean allowZoom)
public static final URLField getURLField(int maxLength)
public static final javax.swing.JColorChooser getColorChooser()
public static final javax.swing.JTree getTree(javax.swing.tree.DefaultMutableTreeNode model)
public static final NumberField getNumberField()
public static final RatingComboBox getRatingComboBox()
public static final javax.swing.JComboBox getFieldsComboBox(DCObject o)
public static final javax.swing.JComboBox getYearComboBox()
public static final javax.swing.JComboBox getMP3GenreComboBox()
public static final javax.swing.JComboBox getSoftwareCatComboBox()
public static final javax.swing.JComboBox getBookCatComboBox()
public static final javax.swing.JComboBox getComboBox(int length)
length
- length of this fieldpublic static final javax.swing.JComboBox getComboBox()
nameOfField
- name of this field
public static final javax.swing.JComboBox getRealYesNoComboBox()
public static final javax.swing.JCheckBox getCheckBox(java.lang.String labelText)
nameOfField
- name of this field
public static final javax.swing.JMenuItem getMenuItem(java.lang.String text)
public static final javax.swing.JMenuItem getMenuItem(javax.swing.ImageIcon icon, java.lang.String text)
public static final javax.swing.JMenu getMenu(java.lang.String text)
public static final javax.swing.JButton getTableHeader(java.lang.String title)
buttonText
- display String, also used for naming the buttonlength
- length of this button
public static final javax.swing.JButton getButton(java.lang.String buttonText, int length)
buttonText
- display String, also used for naming the buttonlength
- length of this button
public static final javax.swing.JButton getButton(javax.swing.ImageIcon icon)
buttonText
- display String, also used for naming the button
public static final javax.swing.JButton getButton(javax.swing.ImageIcon icon, java.lang.String buttonText)
buttonText
- display String, also used for naming the button
public static final javax.swing.JButton getButton(java.lang.String buttonText)
buttonText
- display String, also used for naming the button
public static final javax.swing.JTextArea getTextArea()
public static final LongTextField getLongTextField(int maxTextLength)
public static final javax.swing.JLabel getLabel(javax.swing.ImageIcon icon)
icon
- public static final javax.swing.JLabel getLabel(java.lang.String labelText, javax.swing.ImageIcon icon)
length
- length of this fieldlabeltext
- display String
public static final javax.swing.JLabel getLabel(java.lang.String labelText, int length)
length
- length of this fieldlabeltext
- display String
public static final javax.swing.JLabel getLabel(java.lang.String labelText)
labeltext
- display String
public static final javax.swing.JEditorPane getEditorPane()
public static final ShortTextField getShortTextField(int maxTextLength)
public static final javax.swing.JTextField getTextField()
public static final javax.swing.JTabbedPane getTabbedPane()
public static final DCTable getDCTable(boolean readonly, boolean caching)
public static final DCTable getDCTable(DCModule module, boolean readonly, boolean caching)
public static final javax.swing.Icon getIcon(java.lang.String iconLocation)
iconLocation
- location of the icon imagepublic static final javax.swing.JMenuBar getMenuBar()
nameOfField
- name of this fieldpublic static final javax.swing.JComboBox getYesNoCombo()
nameOfField
- name of this field
public static final javax.swing.border.Border getBorder()
public static final javax.swing.border.TitledBorder getTitleBorder(java.lang.String title)
title
- display Stringpublic static final java.awt.Font getStandardFont()
public static final java.awt.Font getUnreadableFont()
public static final java.awt.Font getSystemFont()
public static final java.awt.Color getDisabledColor()
public static final java.awt.Color getRequiredColor()
public static final java.awt.Color getTableHeaderColor()
public static final java.awt.Color getOddRowColor()
public static final java.awt.Color getSelectionColor()
public static final java.awt.Color getEvenRowColor()
public static final java.awt.Color getTextColor()
public static final java.awt.Color getTableColor()
public static final void setComponentValue(int fieldType, javax.swing.JComponent comp, java.lang.Object value)
public static java.lang.Object getComponentValue(int fieldType, javax.swing.JComponent comp)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |