javax.swing.colorchooser
Interface ColorSelectionModel

All Known Implementing Classes:
DefaultColorSelectionModel

public interface ColorSelectionModel

A model that is used by the JColorChooser component to represent the selected color.


Method Summary
 void addChangeListener(ChangeListener listener)
          Registers a listener to receive ChangeEvent notifications from this model.
 Color getSelectedColor()
          Returns the selected color.
 void removeChangeListener(ChangeListener listener)
          Deregisters a listener so that it no longer receives ChangeEvent notifications from this action.
 void setSelectedColor(Color color)
          Sets the selected color.
 

Method Detail

getSelectedColor

Color getSelectedColor()
Returns the selected color.

Returns:
The selected color.

setSelectedColor

void setSelectedColor(Color color)
Sets the selected color.

Parameters:
color - the selected color.

addChangeListener

void addChangeListener(ChangeListener listener)
Registers a listener to receive ChangeEvent notifications from this model.

Parameters:
listener - the listener.

removeChangeListener

void removeChangeListener(ChangeListener listener)
Deregisters a listener so that it no longer receives ChangeEvent notifications from this action.

Parameters:
listener - the listener.