|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
org.apache.fop.svg.PDFTranscoder
This class enables to transcode an input to a pdf document.
Two transcoding hints (KEY_WIDTH and KEY_HEIGHT) can be used to respectively specify the image width and the image height. If only one of these keys is specified, the transcoder preserves the aspect ratio of the original image.
The KEY_BACKGROUND_COLOR defines the background color to use for opaque image formats, or the background color that may be used for image formats that support alpha channel.
The KEY_AOI represents the area of interest to paint in device space.
Three additional transcoding hints that act on the SVG processor can be specified:
KEY_LANGUAGE to set the default language to use (may be used by a <switch> SVG element for example), KEY_USER_STYLESHEET_URI to fix the URI of a user stylesheet, and KEY_PIXEL_UNIT_TO_MILLIMETER to specify the pixel to millimeter conversion factor.
Inner Class Summary | |
protected class |
PDFTranscoder.ImageTranscoderUserAgent
A user agent implementation for ImageTranscoder. |
Field Summary | |
static org.apache.batik.transcoder.TranscodingHints.Key |
KEY_STROKE_TEXT
|
protected org.apache.batik.bridge.UserAgent |
userAgent
The user agent dedicated to an ImageTranscoder. |
Constructor Summary | |
PDFTranscoder()
Constructs a new ImageTranscoder. |
Method Summary | |
protected org.apache.batik.dom.util.DocumentFactory |
createDocumentFactory(org.w3c.dom.DOMImplementation domImpl,
java.lang.String parserClassname)
Creates a DocumentFactory that is used to create an SVG DOM tree. |
protected void |
transcode(org.w3c.dom.Document document,
java.lang.String uri,
org.apache.batik.transcoder.TranscoderOutput output)
Transcodes the specified Document as an image in the specified output. |
Field Detail |
public static final org.apache.batik.transcoder.TranscodingHints.Key KEY_STROKE_TEXT
protected org.apache.batik.bridge.UserAgent userAgent
Constructor Detail |
public PDFTranscoder()
Method Detail |
protected void transcode(org.w3c.dom.Document document, java.lang.String uri, org.apache.batik.transcoder.TranscoderOutput output) throws org.apache.batik.transcoder.TranscoderException
document
- the document to transcodeuri
- the uri of the document or null if anyoutput
- the ouput where to transcodeTranscoderException
- if an error occured while transcodingprotected org.apache.batik.dom.util.DocumentFactory createDocumentFactory(org.w3c.dom.DOMImplementation domImpl, java.lang.String parserClassname)
domImpl
- the DOM Implementation (not used)parserClassname
- the XML parser classname
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |