
CHAPTER 25
Thejavax.swing.color chooser Package
The classes and interfaces of the javax.swing .colorchooser package support the JColor-
Chooser component of the javax.swing package and allow customization of that com-
ponent. Figure 25-1 shows the class hierarchy of this package.
extends implements
KEY
CLASS INTERFACEABSTRACT CLASS
ColorChooserComponentFactory
javax.swing.colorchooser
java.lang
Serializable
Object
java.io
DefaultColorSelectionModel
ColorSelectionModel
AbstractColorChooserPanel
javax.swing
JPanel
Figur e 25−1: The javax.swing.color chooser package
AbstractColorChooserPanel Ja va 1.2
javax.swing .colorchooser serializable accessible swing component
This abstract subclass of JPanel pr ovides the basic framework for creating new color
selection panels for the JColorChooser component. The default color selection panels pro-
vided by the JColorChooser ar e adequate for most applications. If you want to add a cus-
tom panel, you must subclass this class and provide implementations for the abstract
methods. The buildChooser() method should create the GUI components that your color
javax.swing.
colorchooser
527
14 September 1999 10:24