|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
dsto.dfc.swing.controls.ColorSchemePanel
public class ColorSchemePanel
Displays a toggle button with ColorSwatchIcon for each color in the ColorScheme that was passed to it. Collaborates with ColorChooserPanel to display the different schemes.
ColorChooserPanel
,
ColorScheme
,
ColorChooserCombo
,
Serialized FormNested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected Vector |
actionListeners
|
protected ArrayList |
buttonList
|
protected ColorScheme |
colorScheme
|
protected GridLayout |
gridLayout1
|
protected ArrayList |
iconButtonListeners
|
protected Color |
selectedColor
|
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
ColorSchemePanel()
Initializes variables and calls jbInit (). |
Method Summary | |
---|---|
void |
addActionListener(ActionListener l)
Adds an actionListener to the list. |
protected void |
fireActionPerformed(ActionEvent e)
Fires action events to all listeners. |
void |
firePropertyChange(String propertyName,
Object oldValue,
Object newValue)
|
ColorScheme |
getScheme()
Returns the current Scheme. |
protected void |
loadScheme()
Assigns the number of rows required to fit all of the buttons. |
void |
removeActionListener(ActionListener l)
Removes an actionListener from the list. |
void |
retoggle()
Unselectes the toggle buttons. |
void |
setColor(Color c)
Sets the Color. |
void |
setScheme(ColorScheme colorScheme)
Assigns the current scheme and loads it. |
void |
setSelectedButton(Color color)
Sets the "More Colors..." button's icon to the color chosen in the JColorChooser. |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected transient Vector actionListeners
protected GridLayout gridLayout1
protected ArrayList buttonList
protected ArrayList iconButtonListeners
protected ColorScheme colorScheme
protected Color selectedColor
Constructor Detail |
---|
public ColorSchemePanel()
Method Detail |
---|
public void retoggle()
public ColorScheme getScheme()
public void setScheme(ColorScheme colorScheme)
public void removeActionListener(ActionListener l)
public void addActionListener(ActionListener l)
public void setSelectedButton(Color color)
public void setColor(Color c)
protected void loadScheme()
protected void fireActionPerformed(ActionEvent e)
public void firePropertyChange(String propertyName, Object oldValue, Object newValue)
firePropertyChange
in class Component
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |