jcreek.cke.controls
Class ArrowIcon
java.lang.Object
jcreek.cke.controls.ArrowIcon
- All Implemented Interfaces:
- javax.swing.Icon, java.io.Serializable
- public class ArrowIcon
- extends java.lang.Object
- implements javax.swing.Icon, java.io.Serializable
A dynamically drawn auto-scaling arrow icon.
- Version:
- $Revision: 1.1 $
- Author:
- Matthew Phillips
- See Also:
- Serialized Form
Constructor Summary |
ArrowIcon(int direction,
int height)
Creates a new icon with the arrow pointing in the direction
specified. |
ArrowIcon(int direction,
int height,
java.awt.Color color)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UP
public static final int UP
- See Also:
- Constant Field Values
DOWN
public static final int DOWN
- See Also:
- Constant Field Values
direction
protected int direction
width
protected int width
height
protected int height
color
protected java.awt.Color color
ArrowIcon
public ArrowIcon(int direction,
int height)
- Creates a new icon with the arrow pointing in the direction
specified.
- Parameters:
direction
- The direction to draw the arrow.
ArrowIcon
public ArrowIcon(int direction,
int height,
java.awt.Color color)
setColor
public void setColor(java.awt.Color color)
getColor
public java.awt.Color getColor()
getHeightForWidth
public static int getHeightForWidth(int width)
paintIcon
public void paintIcon(java.awt.Component component,
java.awt.Graphics graphics,
int x,
int y)
- Draws the icon.
- Specified by:
paintIcon
in interface javax.swing.Icon
getIconWidth
public int getIconWidth()
- Specified by:
getIconWidth
in interface javax.swing.Icon
getIconHeight
public int getIconHeight()
- Specified by:
getIconHeight
in interface javax.swing.Icon
getDirection
public int getDirection()
setIconHeight
public void setIconHeight(int height)
Created at IDI, NTNU by the Artificial Intelligence and Learning group