java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.ComboBoxUI
javax.swing.plaf.basic.BasicComboBoxUI
javax.swing.plaf.metal.MetalComboBoxUI
Metal UI for JComboBox
 
 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.  As of 1.4, support for long term storage
 of all JavaBeans
 has been added to the java.beans package.
 Please see XMLEncoder.
- See Also:
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionclassThis class should be treated as a "protected" inner class.classDeprecated.As of Java 2 platform v1.4.classThis class should be treated as a "protected" inner class.Nested classes/interfaces declared in class javax.swing.plaf.basic.BasicComboBoxUIBasicComboBoxUI.ComboBoxLayoutManager, BasicComboBoxUI.FocusHandler, BasicComboBoxUI.ItemHandler, BasicComboBoxUI.KeyHandler, BasicComboBoxUI.ListDataHandler, BasicComboBoxUI.PropertyChangeHandler
- 
Field SummaryFields declared in class javax.swing.plaf.basic.BasicComboBoxUIarrowButton, cachedMinimumSize, comboBox, currentValuePane, editor, focusListener, hasFocus, isMinimumSizeDirty, itemListener, keyListener, listBox, listDataListener, padding, popup, popupKeyListener, popupMouseListener, popupMouseMotionListener, propertyChangeListener, squareButton
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidThis protected method is implementation specific and should be private.Creates aPropertyChangeListenerwhich will be added to the combo box.static ComponentUIConstructs an instance ofMetalComboBoxUI.protected voidDeprecated.As of Java 2 platform v1.4.intgetBaseline(JComponent c, int width, int height) Returns the baseline.voidlayoutComboBox(Container parent, MetalComboBoxUI.MetalComboBoxLayoutManager manager) Lays out theJComboBoxin theparentcontainer.voidpaintCurrentValue(Graphics g, Rectangle bounds, boolean hasFocus) If necessary paints the currently selected item.voidpaintCurrentValueBackground(Graphics g, Rectangle bounds, boolean hasFocus) If necessary paints the background of the currently selected item.protected voidDeprecated.As of Java 2 platform v1.4.voidThis protected method is implementation specific and should be private.Methods declared in class javax.swing.plaf.basic.BasicComboBoxUIaddEditor, configureArrowButton, createArrowButton, createEditor, createFocusListener, createItemListener, createKeyListener, createLayoutManager, createListDataListener, createPopup, createRenderer, getBaselineResizeBehavior, getDefaultSize, getDisplaySize, getInsets, getMinimumSize, getSizeForComponent, installComponents, installDefaults, installKeyboardActions, installListeners, isFocusTraversable, isNavigationKey, isPopupVisible, rectangleForCurrentValue, removeEditor, selectNextPossibleValue, selectPreviousPossibleValue, setPopupVisible, toggleOpenClose, unconfigureArrowButton, uninstallComponents, uninstallDefaults, uninstallKeyboardActions, uninstallListenersMethods declared in class javax.swing.plaf.ComponentUIcontains, getAccessibleChild, getAccessibleChildrenCount, getMaximumSize, getPreferredSize, installUI, paint, uninstallUI, update
- 
Constructor Details- 
MetalComboBoxUIpublic MetalComboBoxUI()Constructs aMetalComboBoxUI.
 
- 
- 
Method Details- 
createUIConstructs an instance ofMetalComboBoxUI.- Parameters:
- c- a component
- Returns:
- an instance of MetalComboBoxUI
 
- 
paintCurrentValueIf necessary paints the currently selected item.- Overrides:
- paintCurrentValuein class- BasicComboBoxUI
- Parameters:
- g- Graphics to paint to
- bounds- Region to paint current value to
- hasFocus- whether or not the JComboBox has focus
- Throws:
- NullPointerException- if any of the arguments are null.
- Since:
- 1.5
 
- 
paintCurrentValueBackgroundIf necessary paints the background of the currently selected item.- Overrides:
- paintCurrentValueBackgroundin class- BasicComboBoxUI
- Parameters:
- g- Graphics to paint to
- bounds- Region to paint background to
- hasFocus- whether or not the JComboBox has focus
- Throws:
- NullPointerException- if any of the arguments are null.
- Since:
- 1.5
 
- 
getBaselineReturns the baseline.- Overrides:
- getBaselinein class- BasicComboBoxUI
- Parameters:
- c-- JComponentbaseline is being requested for
- width- the width to get the baseline for
- height- the height to get the baseline for
- Returns:
- baseline or a value < 0 indicating there is no reasonable baseline
- Throws:
- NullPointerException- if- cis- null
- IllegalArgumentException- if width or height is < 0
- Since:
- 1.6
- See Also:
 
- 
createPropertyChangeListenerDescription copied from class:BasicComboBoxUICreates aPropertyChangeListenerwhich will be added to the combo box. If this method returns null then it will not be added to the combo box.- Overrides:
- createPropertyChangeListenerin class- BasicComboBoxUI
- Returns:
- an instance of a PropertyChangeListeneror null
 
- 
editablePropertyChangedDeprecated.As of Java 2 platform v1.4.As of Java 2 platform v1.4 this method is no longer used. Do not call or override. All the functionality of this method is in the MetalPropertyChangeListener.- Parameters:
- e- an instance of- PropertyChangeEvent
 
- 
layoutComboBoxLays out theJComboBoxin theparentcontainer.- Parameters:
- parent- a container
- manager- an instance of- MetalComboBoxLayoutManager
 
- 
removeListenersDeprecated.As of Java 2 platform v1.4.As of Java 2 platform v1.4 this method is no longer used.
- 
configureEditorpublic void configureEditor()Description copied from class:BasicComboBoxUIThis protected method is implementation specific and should be private. do not call or override.- Overrides:
- configureEditorin class- BasicComboBoxUI
- See Also:
 
- 
unconfigureEditorpublic void unconfigureEditor()Description copied from class:BasicComboBoxUIThis protected method is implementation specific and should be private. Do not call or override.- Overrides:
- unconfigureEditorin class- BasicComboBoxUI
- See Also:
 
 
-