|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
ucar.unidata.util.GuiUtils.ColorSwatch
public static class GuiUtils.ColorSwatch
A color swatch panel
| Nested 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.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary |
|---|
| 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 | |
|---|---|
GuiUtils.ColorSwatch(Color c,
String dialogLabel)
Create a new ColorSwatch for the specified color |
|
| Method Summary | |
|---|---|
JButton |
getClearButton()
Get the clear button |
JComponent |
getPanel()
Get the panel |
JButton |
getSetButton()
Get the set button |
JComponent |
getSetPanel()
Get the panel that shows the swatch and the Set button. |
Color |
getSwatchColor()
Get the Color of the swatch |
void |
paint(Graphics g)
Paint this swatch |
void |
popupNameMenu(JButton popupBtn)
Popup the named list menu |
void |
setBackground(Color c)
Set the background to the color |
void |
setColorName(String name)
Set the color based on name |
| 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 |
| Constructor Detail |
|---|
public GuiUtils.ColorSwatch(Color c,
String dialogLabel)
c - ColordialogLabel - label for the dialog| Method Detail |
|---|
public JButton getSetButton()
public JButton getClearButton()
public Color getSwatchColor()
public void setBackground(Color c)
setBackground in class JComponentc - Color for backgroundpublic void paint(Graphics g)
paint in class JComponentg - graphicspublic JComponent getPanel()
public JComponent getSetPanel()
public void popupNameMenu(JButton popupBtn)
popupBtn - Popup near this buttonpublic void setColorName(String name)
name - color name
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||