public abstract class StateIcon extends ScalableIcon implements ResizableFlexWidthIcon
Modifier and Type | Class and Description |
---|---|
static class |
StateIcon.State
Possible states.
|
Constructor and Description |
---|
StateIcon(StateIcon.State stateIn)
Creates a new StateIcon.
|
Modifier and Type | Method and Description |
---|---|
void |
paintImage(Graphics2D g,
int w,
int h)
Builds the image.
|
abstract void |
paintMainIcon(Graphics2D g,
int x,
int y,
int w,
int h)
Paints the main part of the icon.
|
void |
setHeight(int h)
Sets the icon height.
|
getIconHeight, getIconWidth, getImage, paintIcon, setup
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getIconHeight, getIconWidth, paintIcon
public StateIcon(StateIcon.State stateIn)
stateIn
- the icon state.public void paintImage(Graphics2D g, int w, int h)
paintImage
in class ScalableIcon
g
- the graphics onto which the image should be painted.w
- the image width.h
- the image height.public abstract void paintMainIcon(Graphics2D g, int x, int y, int w, int h)
g
- the graphics on which to paint.x
- x position of the icon.y
- y position of the icon.w
- the icon width.h
- the icon height.public void setHeight(int h)
setHeight
in interface ResizableFlexWidthIcon
h
- the new icon height.