Class ColorSwatchConfigurer
java.lang.Object
VASSAL.configure.Configurer
VASSAL.build.module.gamepieceimage.ColorSwatchConfigurer
public class ColorSwatchConfigurer extends Configurer
-
Field Summary
Fields Modifier and Type Field Description protected Box
colorBox
protected ColorConfigurer
config
protected JPanel
p
protected JComboBox<String>
swatches
protected JPanel
swatchPanel
Fields inherited from class VASSAL.configure.Configurer
changeSupport, frozen, key, name, NAME_PROPERTY, noUpdate, value
-
Constructor Summary
Constructors Constructor Description ColorSwatchConfigurer(String key, String name)
ColorSwatchConfigurer(String key, String name, Color color)
ColorSwatchConfigurer(String key, String name, String swatchName)
ColorSwatchConfigurer(String key, String name, ColorSwatch swatch)
-
Method Summary
Modifier and Type Method Description protected void
buildSwatches()
static ColorSwatch
decode(String s)
static String
encode(ColorSwatch f)
Component
getControls()
GUI interface for setting the option in an editing windowColor
getValueColor()
ColorSwatch
getValueColorSwatch()
String
getValueString()
protected void
repack()
void
setValue(String s)
Set the Object value from a Stringprotected void
updateValue()
Methods inherited from class VASSAL.configure.Configurer
addPropertyChangeListener, fireUpdate, getKey, getName, getValue, isFrozen, removePropertyChangeListener, setFrozen, setName, setValue
-
Field Details
-
p
-
swatchPanel
-
swatches
-
colorBox
-
config
-
-
Constructor Details
-
ColorSwatchConfigurer
-
ColorSwatchConfigurer
-
ColorSwatchConfigurer
-
ColorSwatchConfigurer
-
-
Method Details
-
getValueString
- Specified by:
getValueString
in classConfigurer
- Returns:
- a String representation of the Object value
-
getValueColor
-
getValueColorSwatch
-
getControls
Description copied from class:Configurer
GUI interface for setting the option in an editing window- Specified by:
getControls
in classConfigurer
-
buildSwatches
protected void buildSwatches() -
updateValue
protected void updateValue() -
repack
protected void repack() -
setValue
Description copied from class:Configurer
Set the Object value from a String- Specified by:
setValue
in classConfigurer
-
decode
-
encode
-