Mp3dings 
20100427

de.mospace.swing.icon
Class BlankIcon

java.lang.Object
  extended by de.mospace.swing.icon.BlankIcon
All Implemented Interfaces:
Icon

public class BlankIcon
extends Object
implements Icon

A blank Java icon. Original package: jp.gr.java_conf.tame.swing.icon This class is in the public domain.

Version:
1.0 02/26/99

Constructor Summary
BlankIcon()
          Creates a transparent blank icon that is 11 px wide and 11 px high.
BlankIcon(Color color, int size)
          Creates a new blank icon with the specified color and size.
 
Method Summary
 int getIconHeight()
          Gets the height of this icon.
 int getIconWidth()
          Gets the width of this icon.
 void paintIcon(Component c, Graphics g, int x, int y)
          Paints this icon on the specified graphics object at the specified location.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BlankIcon

public BlankIcon()
Creates a transparent blank icon that is 11 px wide and 11 px high.


BlankIcon

public BlankIcon(Color color,
                 int size)
Creates a new blank icon with the specified color and size.

Parameters:
color - the background color for the icon, if it is null the icon will be transparent
size - the size in pixels for the icon
Method Detail

paintIcon

public void paintIcon(Component c,
                      Graphics g,
                      int x,
                      int y)
Paints this icon on the specified graphics object at the specified location.

Specified by:
paintIcon in interface Icon
Parameters:
c - ignored, may be null
g - the graphics object to paint on
x - the x-offset for this icon
y - the y-offset for this icon

getIconWidth

public int getIconWidth()
Gets the width of this icon.

Specified by:
getIconWidth in interface Icon
Returns:
the width of this icon

getIconHeight

public int getIconHeight()
Gets the height of this icon.

Specified by:
getIconHeight in interface Icon
Returns:
the height of this icon

Mp3dings 
20100427