|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavamorph.CPictureDecorator
public class CPictureDecorator
Field Summary | |
---|---|
private int |
height
Height of the image in screen pixel units. |
private BufferedImage |
image
Image from file to draw. |
private CFrame |
parent
JComponent to draw the picture to. |
private int |
width
Width of the image in screen pixel units. |
private int |
x
X position of the top left corner in screen pixel units. |
private int |
y
Y position of the top left corner in screen pixel units. |
Constructor Summary | |
---|---|
CPictureDecorator(CFrame parent,
BufferedImage image)
Constructor. |
Method Summary | |
---|---|
Rectangle |
getBounds()
Get function. |
void |
paint(Graphics g)
Draw the picture to the Graphics context of the parent JComponent. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private CFrame parent
private BufferedImage image
private int x
private int y
private int width
private int height
Constructor Detail |
---|
public CPictureDecorator(CFrame parent, BufferedImage image)
parent
- Graphical component to draw the picture to.image
- Input picture of the own side.Method Detail |
---|
public void paint(Graphics g)
paint
in interface IDecorator
g
- Graphics context of the JComponent.public Rectangle getBounds()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |