| 
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.9.1) E67661-01  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
  
oracle.ide.controls.ColorIcon
public final class ColorIcon
The ColorIcon is an Icon implementation that is a simple rectangular shape with a black edge rim, and configurable center fill color. The size of the icon must be specified when it is created, but the fill color may be changed later.
| Field Summary | |
|---|---|
static int | 
DEFAULT_HEIGHTThe default icon height (12) to use if none is specified.  | 
static int | 
DEFAULT_SIZEThe default icon size (square) to use if none is specified.  | 
static int | 
DEFAULT_WIDTHThe default icon width (12) to use if none is specified.  | 
| Constructor Summary | |
|---|---|
ColorIcon(java.awt.Color color)Construct a new ColorIcon with the given fill color and with a default size | 
|
ColorIcon(java.awt.Color color, java.awt.Dimension dimensions)Construct a new ColorIcon with the given fill color and dimensions. | 
|
ColorIcon(java.awt.Color color, int width, int height)Construct a new ColorIcon with the given fill color and dimensions. | 
|
| Method Summary | |
|---|---|
 java.awt.Color | 
getColor()Fetches the color that is currently used to fill the icon.  | 
 int | 
getIconHeight()Returns the icon's height.  | 
 int | 
getIconWidth()Returns the icon's width.  | 
 void | 
paintIcon(java.awt.Component component, java.awt.Graphics graphics, int x, int y)Draw the icon at the specified location.  | 
 void | 
setColor(java.awt.Color color)Changes the color that is used to fill the icon.  | 
 void | 
setSize(int width, int height)Changes the size of the icon.  | 
| Methods inherited from class java.lang.Object | 
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static final int DEFAULT_SIZE
public static final int DEFAULT_WIDTH
public static final int DEFAULT_HEIGHT
| Constructor Detail | 
|---|
public ColorIcon(java.awt.Color color)
ColorIcon with the given fill color and with a default size
color - the fill color to use
public ColorIcon(java.awt.Color color,
                 int width,
                 int height)
ColorIcon with the given fill color and dimensions.
color - the fill color to usewidth - the width to useheight - the height to use
public ColorIcon(java.awt.Color color,
                 java.awt.Dimension dimensions)
ColorIcon with the given fill color and dimensions.
color - the fill color to usedimension - the width and height dimension to use| Method Detail | 
|---|
public java.awt.Color getColor()
public void setColor(java.awt.Color color)
color - the new color to use
public void setSize(int width,
                    int height)
width - the width to useheight - the height to use
public void paintIcon(java.awt.Component component,
                      java.awt.Graphics graphics,
                      int x,
                      int y)
paintIcon in interface javax.swing.Iconpublic int getIconWidth()
getIconWidth in interface javax.swing.Iconpublic int getIconHeight()
getIconHeight in interface javax.swing.Icon
  | 
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.9.1) E67661-01  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||