|
||||||||||
| PREV CLASS Documentation homepage 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
ilog.views.util.swing.color.IlvColorDiskPanel
public class IlvColorDiskPanel
A Panel that contains a HSB Color disk and a brightness ramp. This panel is used in the color chooser. This class might also have a ramp to select the alpha component of the color in the RGBA color model. JDK 1.2. Any class can register itself as an observer on the selection of a color.
IlvColorChooser,
Serialized Form| Nested Class Summary |
|---|
| 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 | |
|---|---|
IlvColorDiskPanel(int disksize)
Creates and initializes a color disk panel. |
|
IlvColorDiskPanel(int disksize,
boolean alpha)
Creates and initializes a color disk panel. |
|
| Method Summary | |
|---|---|
void |
addColorChangedListener(ColorChangedListener listener)
Adds a listener on the modification of the selected color. |
Color |
getColor()
Returns the selected color. |
Dimension |
getMinimumSize()
Returns the minimum size of this component. |
Dimension |
getPreferredSize()
Returns the preferred size of this component. |
void |
init(int disksize)
Initializes a color disk panel. |
void |
paint(Graphics g)
Paints the component. |
protected void |
processMouseEvent(MouseEvent evt)
Processes mouse motion events occurring in this component. |
protected void |
processMouseMotionEvent(MouseEvent evt)
Processes mouse motion events occurring in this component. |
void |
removeColorChangedListener(ColorChangedListener listener)
Removes a listener on the modification of the selected color. |
void |
setColor(Color c)
Changes the selected color. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public IlvColorDiskPanel(int disksize)
disksize - the size of the disk.
public IlvColorDiskPanel(int disksize,
boolean alpha)
disksize - the size of the disk.alpha - if true and if the application is running under JDK1.2 then
this component will also allow to select the alpha component of
the color.| Method Detail |
|---|
public void init(int disksize)
disksize - the size of the disk.protected void processMouseMotionEvent(MouseEvent evt)
processMouseMotionEvent in class JComponentprotected void processMouseEvent(MouseEvent evt)
processMouseEvent in class JComponentpublic Dimension getPreferredSize()
getPreferredSize in class JComponentpublic Dimension getMinimumSize()
getMinimumSize in class JComponentpublic void addColorChangedListener(ColorChangedListener listener)
public void removeColorChangedListener(ColorChangedListener listener)
public void paint(Graphics g)
paint in class JComponentpublic final void setColor(Color c)
c - the new color.public final Color getColor()
|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||