Class marimba.gui.ColorPickerWidget
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class marimba.gui.ColorPickerWidget

java.lang.Object
   |
   +----marimba.gui.Widget
           |
           +----marimba.gui.ColorPickerWidget

public class ColorPickerWidget
extends Widget
Widget to choose a color
Version:
1.3, 12/19/96
Author:
Carl W. Haynes III

Variable Index

 o blue
The current value of the blue slider.
 o blueImage
The image for the blue slider.
 o filled
A color picker can be filled.
 o green
The current value of the green slider.
 o greenImage
The image for the green slider.
 o red
The current value of the red slider.
 o redImage
The image for the red slider.

Constructor Index

 o ColorPickerWidget()
Default constructor.
 o ColorPickerWidget(Color)
Constructor with color.

Method Index

 o createImages()
Set the colors.
 o drawBlue(Graphics)
Draw the blue selector
 o drawGreen(Graphics)
Draw the green selector
 o drawPreview(Graphics)
Draw the preview selector
 o drawRed(Graphics)
Draw the red selector.
 o drawText(Graphics)
Draw the text
 o getColorValue()
Get the current color, by constructing one using the current red, green and blue settings.
 o getProperties(PropertyList)
Get the properties of this widget.
 o getValue()
Get the current color.
 o handleEvent(Event)
Handle the events.
 o isFilled()
Check whether the color picker is filled.
 o paint(Graphics)
Paint this color picker.
 o setFilled(boolean)
Let the color picker fill itself or not.
 o setProperties(PropertyList)
Set the properties of this widget.
 o setValue(Object)
Set the current color.
 o start()
Create the images.

Variables

 o filled
  public boolean filled
A color picker can be filled.
See Also:
isFilled, setFilled
 o red
  protected int red
The current value of the red slider.
See Also:
getValue, getColorValue
 o green
  protected int green
The current value of the green slider.
See Also:
getValue, getColorValue
 o blue
  protected int blue
The current value of the blue slider.
See Also:
getValue, getColorValue
 o blueImage
  protected Image blueImage
The image for the blue slider.
 o redImage
  protected Image redImage
The image for the red slider.
 o greenImage
  protected Image greenImage
The image for the green slider.

Constructors

 o ColorPickerWidget
  public ColorPickerWidget()
Default constructor.
 o ColorPickerWidget
  public ColorPickerWidget(Color color)
Constructor with color.

Methods

 o getProperties
  public void getProperties(PropertyList list)
Get the properties of this widget.
Overrides:
getProperties in class Widget
 o setProperties
  public void setProperties(PropertyList list)
Set the properties of this widget.
Overrides:
setProperties in class Widget
 o isFilled
  public boolean isFilled()
Check whether the color picker is filled.
See Also:
filled
 o setFilled
  public void setFilled(boolean filled)
Let the color picker fill itself or not.
See Also:
filled
 o start
  public void start()
Create the images.
Overrides:
start in class Widget
 o createImages
  protected void createImages()
Set the colors.
 o setValue
  public void setValue(Object color)
Set the current color.
Overrides:
setValue in class Widget
 o getValue
  public Object getValue()
Get the current color.
Overrides:
getValue in class Widget
See Also:
getColorValue
 o getColorValue
  public Color getColorValue()
Get the current color, by constructing one using the current red, green and blue settings.
See Also:
color
 o paint
  public void paint(Graphics g)
Paint this color picker.
Overrides:
paint in class Widget
 o drawRed
  protected void drawRed(Graphics g)
Draw the red selector.
 o drawGreen
  protected void drawGreen(Graphics g)
Draw the green selector
 o drawBlue
  protected void drawBlue(Graphics g)
Draw the blue selector
 o drawPreview
  protected void drawPreview(Graphics g)
Draw the preview selector
 o drawText
  protected void drawText(Graphics g)
Draw the text
 o handleEvent
  public boolean handleEvent(Event evt)
Handle the events.
Overrides:
handleEvent in class Widget

All Packages  Class Hierarchy  This Package  Previous  Next  Index