com.lowagie.text

Class ImgWMF

Implemented Interfaces:
Element, MarkupAttributes

public class ImgWMF
extends Image
implements Element

An ImgWMF is the representation of a windows metafile that has to be inserted into the document
See Also:
Element, Image

Field Summary

Fields inherited from class com.lowagie.text.Image

AX, AY, BX, BY, CX, CY, DEFAULT, DX, DY, LEFT, MIDDLE, ORIGINAL_BMP, ORIGINAL_GIF, ORIGINAL_JPEG, ORIGINAL_NONE, ORIGINAL_PNG, ORIGINAL_PS, ORIGINAL_TIFF, ORIGINAL_WMF, RIGHT, TEXTWRAP, UNDERLYING, XYRatio, absoluteX, absoluteY, additional, alignment, alt, annotation, bpc, colorspace, deflated, dpiX, dpiY, imageMask, indentationLeft, indentationRight, interpolation, invert, layer, markupAttributes, mask, mySerialId, originalData, originalType, plainHeight, plainWidth, profile, rawData, rotation, scaledHeight, scaledWidth, serialId, smask, spacingAfter, spacingBefore, template, transparency, type, url, widthPercentage

Fields inherited from class com.lowagie.text.Rectangle

BOTTOM, BOX, LEFT, NO_BORDER, RIGHT, TOP, UNDEFINED, background, border, borderColorBottom, borderColorLeft, borderColorRight, borderColorTop, borderWidth, borderWidthBottom, borderWidthLeft, borderWidthRight, borderWidthTop, color, grayFill, llx, lly, markupAttributes, rotation, urx, ury, useVariableBorders

Fields inherited from interface com.lowagie.text.Element

ALIGN_BASELINE, ALIGN_BOTTOM, ALIGN_CENTER, ALIGN_JUSTIFIED, ALIGN_JUSTIFIED_ALL, ALIGN_LEFT, ALIGN_MIDDLE, ALIGN_RIGHT, ALIGN_TOP, ALIGN_UNDEFINED, ANCHOR, ANNOTATION, AUTHOR, CCITTG3_1D, CCITTG3_2D, CCITTG4, CCITT_BLACKIS1, CCITT_ENCODEDBYTEALIGN, CCITT_ENDOFBLOCK, CCITT_ENDOFLINE, CELL, CHAPTER, CHUNK, CREATIONDATE, CREATOR, GRAPHIC, HEADER, IMGRAW, IMGTEMPLATE, JPEG, KEYWORDS, LIST, LISTITEM, MULTI_COLUMN_TEXT, PARAGRAPH, PHRASE, PRODUCER, PTABLE, RECTANGLE, ROW, SECTION, SUBJECT, TABLE, TITLE

Constructor Summary

ImgWMF(String filename)
Constructs an ImgWMF-object, using a filename.
ImgWMF(URL url)
Constructs an ImgWMF-object, using an url.
ImgWMF(byte[] img)
Constructs an ImgWMF-object from memory.
ImgWMF(Image image)
Constructs an Image -object, using an url .

Method Summary

private void
processParameters()
This method checks if the image is a valid WMF and processes some parameters.
void
readWMF(PdfTemplate template)
Reads the WMF into a template.

Methods inherited from class com.lowagie.text.Image

absoluteX, absoluteY, alignment, alt, annotation, bpc, colorspace, getAdditional, getDpiX, getDpiY, getICCProfile, getImageMask, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getLayer, getMarkupAttribute, getMarkupAttributeNames, getMarkupAttributes, getMySerialId, getOriginalData, getOriginalType, getSerialId, getTransparency, getWidthPercentage, getXYRatio, hasAbsolutePosition, hasAbsoluteX, hasICCProfile, indentationLeft, indentationRight, isDeflated, isImgRaw, isImgTemplate, isInterpolation, isInvertMask, isInverted, isJpeg, isMask, isMaskCandidate, isSmask, isTag, makeMask, matrix, plainHeight, plainWidth, rawData, scaleAbsolute, scaleAbsoluteHeight, scaleAbsoluteWidth, scalePercent, scalePercent, scaleToFit, scaledHeight, scaledWidth, setAbsolutePosition, setAdditional, setAlignment, setAlt, setAnnotation, setDeflated, setDpi, setImageMask, setIndentationLeft, setIndentationRight, setInterpolation, setInvertMask, setInverted, setLayer, setMarkupAttribute, setMarkupAttributes, setOriginalData, setOriginalType, setRotation, setRotationDegrees, setSmask, setSpacingAfter, setSpacingBefore, setTemplateData, setTransparency, setUrl, setWidthPercentage, setXYRatio, skip, spacingAfter, spacingBefore, tagICC, templateData, toURL, type, url

Methods inherited from class com.lowagie.text.Rectangle

backgroundColor, border, borderColor, borderWidth, bottom, bottom, cloneNonPositionParameters, disableBorderSide, enableBorderSide, getBorderColorBottom, getBorderColorLeft, getBorderColorRight, getBorderColorTop, getBorderWidthBottom, getBorderWidthLeft, getBorderWidthRight, getBorderWidthTop, getChunks, getMarkupAttribute, getMarkupAttributeNames, getMarkupAttributes, getRotation, getVariableBorderWidth, grayFill, hasBorder, hasBorders, height, isUseVariableBorders, left, left, normalize, process, rectangle, right, right, rotate, setBackgroundColor, setBorder, setBorderColor, setBorderColorBottom, setBorderColorLeft, setBorderColorRight, setBorderColorTop, setBorderWidth, setBorderWidthBottom, setBorderWidthLeft, setBorderWidthRight, setBorderWidthTop, setBottom, setGrayFill, setLeft, setMarkupAttribute, setMarkupAttributes, setRight, setTop, setUseVariableBorders, top, top, type, updateBorderBasedOnWidth, width

Constructor Details

ImgWMF

public ImgWMF(String filename)
            throws BadElementException,
                   MalformedURLException,
                   IOException
Constructs an ImgWMF-object, using a filename.
Parameters:
filename - a String-representation of the file that contains the image.

ImgWMF

public ImgWMF(URL url)
            throws BadElementException,
                   IOException
Constructs an ImgWMF-object, using an url.
Parameters:
url - the URL where the image can be found
Throws:
BadElementException - on error

ImgWMF

public ImgWMF(byte[] img)
            throws BadElementException,
                   IOException
Constructs an ImgWMF-object from memory.
Parameters:
img - the memory image
Throws:
BadElementException - on error

ImgWMF

(package private)  ImgWMF(Image image)
Constructs an Image -object, using an url .
Parameters:
image - another Image object.

Method Details

processParameters

private void processParameters()
            throws BadElementException,
                   IOException
This method checks if the image is a valid WMF and processes some parameters.

readWMF

public void readWMF(PdfTemplate template)
            throws IOException,
                   DocumentException
Reads the WMF into a template.
Parameters:
template - the template to read to
Throws:
DocumentException - on error