Package uk.ac.starlink.ttools.plot
Interface Picture
-
public interface PictureInterface for a self-contained object which can paint itself on a graphics context. It's very like anIcon, but intended for use in contexts which may be headless.- Since:
- 20 Jan 2012
- Author:
- Mark Taylor
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intgetPictureHeight()Get vertical extent.intgetPictureWidth()Get horizontal extent.voidpaintPicture(java.awt.Graphics2D g2)Paint the content of this painting on the given graphics context.
-
-
-
Method Detail
-
getPictureWidth
int getPictureWidth()
Get horizontal extent.- Returns:
- width in pixels
-
getPictureHeight
int getPictureHeight()
Get vertical extent.- Returns:
- height in pixels
-
paintPicture
void paintPicture(java.awt.Graphics2D g2) throws java.io.IOExceptionPaint the content of this painting on the given graphics context. The intended graphics content ought only to extend between 0 and width on the X axis and 0 and height on the Y axis.- Parameters:
g2- graphics context- Throws:
java.io.IOException
-
-