|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.threerings.media.sprite.SpriteIcon
public class SpriteIcon
Implements the icon interface, using a Sprite to render the
icon image.
| Field Summary | |
|---|---|
protected int |
_padding
Used to put a bit of padding around the sprite image. |
protected Sprite |
_sprite
The sprite used to render this icon. |
| Constructor Summary | |
|---|---|
SpriteIcon(Sprite sprite)
Creates a sprite icon that will use the supplied sprite to render itself. |
|
SpriteIcon(Sprite sprite,
int padding)
Creates a sprite icon that will use the supplied sprite to render itself. |
|
| Method Summary | |
|---|---|
int |
getIconHeight()
|
int |
getIconWidth()
|
void |
paintIcon(Component c,
Graphics g,
int x,
int y)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Sprite _sprite
protected int _padding
| Constructor Detail |
|---|
public SpriteIcon(Sprite sprite)
public SpriteIcon(Sprite sprite,
int padding)
sprite - the sprite to render in this label.padding - the number of pixels of blank space to put on all
four sides of the sprite.| Method Detail |
|---|
public void paintIcon(Component c,
Graphics g,
int x,
int y)
paintIcon in interface Iconpublic int getIconWidth()
getIconWidth in interface Iconpublic int getIconHeight()
getIconHeight in interface Icon
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||