com.lowagie.text.rtf.graphic
public class RtfImage extends RtfElement
Version: $Revision: 1.23 $
| Field Summary | |
|---|---|
| int | alignment
The alignment of this picture |
| float | height
The height of this picutre |
| byte[] | image
The actual image. |
| int | imageType
The type of image this is. |
| float | plainHeight
The intended display height of this picture |
| float | plainWidth
The intended display width of this picture |
| static byte[] | PICTURE
Constant for a picture |
| static byte[] | PICTURE_BMP
Constant for a bmp image |
| static byte[] | PICTURE_GROUP
Constant for the shape/picture group |
| static byte[] | PICTURE_HEIGHT
Constant for the picture height |
| static byte[] | PICTURE_JPEG
Constant for a jpeg image |
| static byte[] | PICTURE_PNG
Constant for a png image |
| static byte[] | PICTURE_SCALED_HEIGHT
Constant for the picture height scale |
| static byte[] | PICTURE_SCALED_WIDTH
Constant for the picture width scale |
| static byte[] | PICTURE_WIDTH
Constant for the picture width |
| static byte[] | PICTURE_WMF
Constant for a wmf image |
| boolean | topLevelElement
Whether this RtfImage is a top level element and should
be an extra paragraph. |
| float | width
The width of this picture |
| Constructor Summary | |
|---|---|
| RtfImage(RtfDocument doc, Image image)
Constructs a RtfImage for an Image.
| |
| Method Summary | |
|---|---|
| byte[] | getImage(Image image)
Extracts the image data from the Image. |
| void | setAlignment(int alignment)
Sets the alignment of this RtfImage. |
| void | setTopLevelElement(boolean topLevelElement)
Set whether this RtfImage should behave like a top level element
and enclose itself in a paragraph.
|
| byte[] | write()
Writes the RtfImage content
|
Parameters: doc The RtfDocument this RtfImage belongs to image The Image that this RtfImage wraps
Throws: DocumentException If an error occured accessing the image content
Parameters: image The Image for which to extract the content
Returns: The image data formated for the rtf document
Throws: DocumentException If an error occurs accessing the image content
Parameters: alignment The alignment to use.
Parameters: topLevelElement Whether to behave like a top level element.
Returns: the RtfImage content