javax.swing.plaf.metal
Class MetalComboBoxIcon

java.lang.Object
  extended by javax.swing.plaf.metal.MetalComboBoxIcon
All Implemented Interfaces:
Serializable, Icon

public class MetalComboBoxIcon
extends Object
implements Icon, Serializable

An icon used by the MetalComboBoxUI class.

See Also:
Serialized Form

Constructor Summary
MetalComboBoxIcon()
          Creates a new icon.
 
Method Summary
 int getIconHeight()
          Returns the icon height, which for this icon is 5 pixels.
 int getIconWidth()
          Returns the icon width, which for this icon is 10 pixels.
 void paintIcon(Component c, Graphics g, int x, int y)
          Paints the icon at the location (x, y).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MetalComboBoxIcon

public MetalComboBoxIcon()
Creates a new icon.

Method Detail

getIconWidth

public int getIconWidth()
Returns the icon width, which for this icon is 10 pixels.

Specified by:
getIconWidth in interface Icon
Returns:
10.

getIconHeight

public int getIconHeight()
Returns the icon height, which for this icon is 5 pixels.

Specified by:
getIconHeight in interface Icon
Returns:
5.

paintIcon

public void paintIcon(Component c,
                      Graphics g,
                      int x,
                      int y)
Paints the icon at the location (x, y).

Specified by:
paintIcon in interface Icon
Parameters:
c - the combo box (ignored here).
g - the graphics device.
x - the x coordinate.
y - the y coordinate.