public class SkinsFactory
extends java.lang.Object
org.jets3t.gui.skins.<skinName>
Skinned classes are specially-named extensions to standard Swing classes, which must have a
constructor of the form public SkinnedJButton(Properties skinProperties, String itemName)
.
This constructor allows skinned GUI elements to change their look or behaviour based on any
skin-specific properties that are provided, or based on the name of a specific GUI element.
The skinned class names supported by this factory include:
Class name | Extends |
---|---|
SkinnedJButton | javax.swing.JButton |
SkinnedJHtmlLabel | org.jets3t.gui.JHtmlLabel |
SkinnedJPanel | javax.swing.JPanel |
SkinnedLookAndFeel | javax.swing.plaf.metal.MetalLookAndFeel |
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
NO_SKIN |
Modifier and Type | Method and Description |
---|---|
javax.swing.JButton |
createSkinnedJButton(java.lang.String itemName) |
javax.swing.JCheckBox |
createSkinnedJCheckBox(java.lang.String itemName) |
javax.swing.JComboBox |
createSkinnedJComboBox(java.lang.String itemName) |
JHtmlLabel |
createSkinnedJHtmlLabel(java.lang.String itemName) |
JHtmlLabel |
createSkinnedJHtmlLabel(java.lang.String itemName,
HyperlinkActivatedListener hyperlinkListener) |
javax.swing.JMenuItem |
createSkinnedJMenuItem(java.lang.String itemName) |
javax.swing.JPanel |
createSkinnedJPanel(java.lang.String itemName) |
javax.swing.JPasswordField |
createSkinnedJPasswordField(java.lang.String itemName) |
javax.swing.JPopupMenu |
createSkinnedJPopupMenu(java.lang.String itemName) |
javax.swing.JProgressBar |
createSkinnedJProgressBar(java.lang.String itemName,
int min,
int max) |
javax.swing.JRadioButton |
createSkinnedJRadioButton(java.lang.String itemName) |
javax.swing.JScrollPane |
createSkinnedJScrollPane(java.lang.String itemName) |
javax.swing.JScrollPane |
createSkinnedJScrollPane(java.lang.String itemName,
java.lang.Object view) |
javax.swing.JTable |
createSkinnedJTable(java.lang.String itemName) |
javax.swing.JTextArea |
createSkinnedJTextArea(java.lang.String itemName) |
javax.swing.JTextField |
createSkinnedJTextField(java.lang.String itemName) |
javax.swing.LookAndFeel |
createSkinnedMetalTheme(java.lang.String itemName) |
static SkinsFactory |
getInstance(java.util.Properties properties)
Provides a skin factory initialised with skin-specific properties from the provided
properties set.
|
public static final java.lang.String NO_SKIN
public static SkinsFactory getInstance(java.util.Properties properties)
skin.<skinName>.
properties
- a set of properties that may contain skin-specific properties.public javax.swing.LookAndFeel createSkinnedMetalTheme(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedLookAndFeel
class implementation for the current skin, or the default
system LookAndFeel if no skin-specific implementation is available.public javax.swing.JButton createSkinnedJButton(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJButton
class implementation for the current skin, or a default
JButton if no skin-specific implementation is available.public javax.swing.JRadioButton createSkinnedJRadioButton(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJRadioButton
class implementation for the current skin, or a default
JRadioButton if no skin-specific implementation is available.public javax.swing.JComboBox createSkinnedJComboBox(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJComboBox
class implementation for the current skin, or a default
JComboBox if no skin-specific implementation is available.public javax.swing.JCheckBox createSkinnedJCheckBox(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJComboBox
class implementation for the current skin, or a default
JComboBox if no skin-specific implementation is available.public javax.swing.JPanel createSkinnedJPanel(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJPanel
class implementation for the current skin, or a default
JPanel if no skin-specific implementation is available.public javax.swing.JTable createSkinnedJTable(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJTable
class implementation for the current skin, or a default
JPanel if no skin-specific implementation is available.public javax.swing.JScrollPane createSkinnedJScrollPane(java.lang.String itemName, java.lang.Object view)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.view
- the client's viewport view to be used.SkinnedJScrollPane
class implementation for the current skin, or a default
JScrollPane if no skin-specific implementation is available.public javax.swing.JScrollPane createSkinnedJScrollPane(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJScrollPane
class implementation for the current skin, or a default
JScrollPane if no skin-specific implementation is available.public JHtmlLabel createSkinnedJHtmlLabel(java.lang.String itemName, HyperlinkActivatedListener hyperlinkListener)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJLabel
class implementation for the current skin, or a default
JHtmlLabel if no skin-specific implementation is available.public JHtmlLabel createSkinnedJHtmlLabel(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJLabel
class implementation for the current skin, or a default
JHtmlLabel if no skin-specific implementation is available.public javax.swing.JPasswordField createSkinnedJPasswordField(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJPasswordField
class implementation for the current skin, or a default
JPasswordField if no skin-specific implementation is available.public javax.swing.JTextField createSkinnedJTextField(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJTextField
class implementation for the current skin, or a default
JTextField if no skin-specific implementation is available.public javax.swing.JTextArea createSkinnedJTextArea(java.lang.String itemName)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJTextArea
class implementation for the current skin, or a default
JTextArea if no skin-specific implementation is available.public javax.swing.JPopupMenu createSkinnedJPopupMenu(java.lang.String itemName)
public javax.swing.JMenuItem createSkinnedJMenuItem(java.lang.String itemName)
public javax.swing.JProgressBar createSkinnedJProgressBar(java.lang.String itemName, int min, int max)
itemName
- the name of this specific item in the GUI, which may be used to determine how the skinned
item should look or behave.SkinnedJProgressBar
class implementation for the current skin, or a default
JProgressBar if no skin-specific implementation is available.