org.tigris.toolbutton
Class DecoratedIcon
java.lang.Object
|
+--javax.swing.ImageIcon
|
+--org.tigris.toolbutton.DecoratedIcon
- All Implemented Interfaces:
- javax.accessibility.Accessible, javax.swing.Icon, java.io.Serializable
- Direct Known Subclasses:
- DropDownIcon
- public abstract class DecoratedIcon
- extends javax.swing.ImageIcon
The base class for any decorated icon. The icon to decorate is supplied
as the constructor and the decoration defined as a pattern buffer in
the concrete class.
- Author:
- Bob Tarling
- See Also:
- Serialized Form
Fields inherited from class javax.swing.ImageIcon |
component, tracker |
Method Summary |
protected void |
init(int[][] buffer)
|
void |
paintIcon(java.awt.Component c,
java.awt.Graphics g,
int x,
int y)
Paints the icon. |
Methods inherited from class javax.swing.ImageIcon |
getAccessibleContext, getDescription, getIconHeight, getIconWidth, getImage, getImageLoadStatus, getImageObserver, loadImage, setDescription, setImage, setImageObserver, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ROLLOVER
public static final int ROLLOVER
- See Also:
- Constant Field Values
STANDARD
public static final int STANDARD
- See Also:
- Constant Field Values
_buffer
protected int[][] _buffer
_popupIconWidth
protected int _popupIconWidth
_popupIconHeight
protected int _popupIconHeight
init
protected void init(int[][] buffer)
paintIcon
public void paintIcon(java.awt.Component c,
java.awt.Graphics g,
int x,
int y)
- Paints the icon. The top-left corner of the icon is drawn at the point
(x, y) in the coordinate space of the graphics context g. If this icon has
no image observer, this method uses the c component as the observer.
- Specified by:
paintIcon
in interface javax.swing.Icon
- Overrides:
paintIcon
in class javax.swing.ImageIcon
- Parameters:
c
- the component to be used as the observer if this icon has no image observerg
- the graphics contextx
- the X coordinate of the icon's top-left cornery
- the Y coordinate of the icon's top-left corner