java.lang.Object | ||||
↳ | javax.swing.plaf.ComponentUI | |||
↳ | javax.swing.plaf.ComboBoxUI | |||
↳ | javax.swing.plaf.basic.BasicComboBoxUI | |||
↳ | com.sun.java.swing.plaf.windows.WindowsComboBoxUI |
Windows combo box.
Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence.
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
WindowsComboBoxUI.WindowsComboBoxEditor | Subclassed to highlight selected item in an editable combo box. | ||||||||||
WindowsComboBoxUI.WindowsComboPopup | This class is deprecated. As of Java 2 platform v1.4. |
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
javax.swing.plaf.basic.BasicComboBoxUI
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
The minumum size is the size of the display area plus insets plus the button.
| |||||||||||
Configures the specified component appropriate for the look and feel.
| |||||||||||
Paints the specified component appropriate for the look and feel.
| |||||||||||
If necessary paints the currently selected item.
| |||||||||||
Paints the background of the currently selected item.
| |||||||||||
Reverses configuration which was done on the specified component during
installUI . |
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
This protected method is implementation specific and should be private.
| |||||||||||
Creates an button which will be used as the control to show or hide
the popup portion of the combo box.
| |||||||||||
Creates the default editor that will be used in editable combo boxes.
| |||||||||||
Creates a layout manager for managing the components which make up the
combo box.
| |||||||||||
Creates the popup portion of the combo box.
| |||||||||||
Creates the default renderer that will be used in a non-editiable combo
box.
| |||||||||||
Adds keyboard actions to the JComboBox.
| |||||||||||
Create and install the listeners for the combo box and its model.
| |||||||||||
This protected method is implementation specific and should be private.
| |||||||||||
Remove the installed listeners from the combo box and its model.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
javax.swing.plaf.basic.BasicComboBoxUI
| |||||||||||
From class
javax.swing.plaf.ComboBoxUI
| |||||||||||
From class
javax.swing.plaf.ComponentUI
| |||||||||||
From class
java.lang.Object
|
The minumum size is the size of the display area plus insets plus the button.
c | the component whose minimum size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components |
---|
Dimension
object or null
Configures the specified component appropriate for the look and feel.
This method is invoked when the ComponentUI
instance is being installed
as the UI delegate on the specified component. This method should
completely configure the component for the look and feel,
including the following:
LayoutManager
on the component if necessary.
PropertyChangeListener
on the component in order
to detect and respond to component property changes appropriately.
c | the component where this UI delegate is being installed |
---|
Paints the specified component appropriate for the look and feel.
This method is invoked from the ComponentUI.update
method when
the specified component is being painted. Subclasses should override
this method and use the specified Graphics
object to
render the content of the component.
g | the Graphics context in which to paint |
---|---|
c | the component being painted; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components |
If necessary paints the currently selected item.
g | Graphics to paint to |
---|---|
bounds | Region to paint current value to |
hasFocus | whether or not the JComboBox has focus |
NullPointerException | if any of the arguments are null. |
---|
Paints the background of the currently selected item.
Reverses configuration which was done on the specified component during
installUI
. This method is invoked when this
UIComponent
instance is being removed as the UI delegate
for the specified component. This method should undo the
configuration performed in installUI
, being careful to
leave the JComponent
instance in a clean state (no
extraneous listeners, look-and-feel-specific property objects, etc.).
This should include the following:
c | the component from which this UI delegate is being removed; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components |
---|
This protected method is implementation specific and should be private. do not call or override.
Creates an button which will be used as the control to show or hide the popup portion of the combo box.
Creates the default editor that will be used in editable combo boxes.
A default editor will be used only if an editor has not been
explicitly set with setEditor
.
ComboBoxEditor
used for the combo boxCreates a layout manager for managing the components which make up the combo box.
Creates the popup portion of the combo box.
ComboPopup
Creates the default renderer that will be used in a non-editiable combo
box. A default renderer will used only if a renderer has not been
explicitly set with setRenderer
.
ListCellRender
used for the combo boxAdds keyboard actions to the JComboBox. Actions on enter and esc are already supplied. Add more actions as you need them.
Create and install the listeners for the combo box and its model. This method is called when the UI is installed.
This protected method is implementation specific and should be private. Do not call or override.
Remove the installed listeners from the combo box and its model.
The number and types of listeners removed and in this method should be
the same that was added in installListeners