|
JMSLTM Numerical Library 5.0.1 | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.imsl.chart3d.BufferedPaint
public class BufferedPaint
A Paint object cached into an image.
This is used to cache a static image that will be painted into the canvas containing a 3D chart. Since the 3D chart canvas will be repainted many times each second, it is faster to compose the image once.
Constructor Summary | |
---|---|
BufferedPaint(Canvas3DChart.Paint paint,
int x,
int y,
int width,
int height,
Component component)
The paint method in Canvas3DChart.Paint is written
into an image of size width by height . |
Method Summary | |
---|---|
Object |
clone()
|
void |
paint(Graphics g)
Paint the image onto the canvas. |
void |
trim()
Returns a subimage with the white space trimmed off. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BufferedPaint(Canvas3DChart.Paint paint, int x, int y, int width, int height, Component component)
The paint
method in Canvas3DChart.Paint
is written
into an image of size width
by height
.
Any whitespace around the image is trimmed. The trimmed image is then
used to paint onto the canvas.
paint
- is the Canvas3DChart.Paint
object to be cached.x
- is the pixel position in the canvas of the left edge of the image.
If x is negative then |x| is the distance from the right edge of the image
to the right edge of the component.y
- is the pixel position in the canvas of the top edge of the image.
If y is negative then |y| is the distance from the bottom edge of the image
to the bottom edge of the component.width
- is the maximum width of the image.height
- is the maximum height of the image.component
- is the Component
in which the image is to be painted.Method Detail |
---|
public Object clone() throws CloneNotSupportedException
clone
in class Object
CloneNotSupportedException
public void paint(Graphics g)
paint
in interface Canvas3DChart.Paint
g
- is the Graphics
object.public void trim()
|
JMSLTM Numerical Library 5.0.1 | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |