You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by as...@apache.org on 2007/09/08 22:17:47 UTC
svn commit: r573901 [33/44] - in /cocoon/site: site/ site/2.0/
site/2.0/developing/ site/2.0/faq/ site/2.0/howto/chaperon/
site/2.0/installing/ site/2.0/plan/ site/2.0/snippet/ site/2.0/tutorial/
site/2.0/userdocs/ site/2.0/userdocs/actions/ site/2.0/u...
Modified: cocoon/site/site/2.0/userdocs/serializers/svg-serializer.html
URL: http://svn.apache.org/viewvc/cocoon/site/site/2.0/userdocs/serializers/svg-serializer.html?rev=573901&r1=573900&r2=573901&view=diff
==============================================================================
--- cocoon/site/site/2.0/userdocs/serializers/svg-serializer.html (original)
+++ cocoon/site/site/2.0/userdocs/serializers/svg-serializer.html Sat Sep 8 13:17:41 2007
@@ -1,480 +1,480 @@
-<html>
-<head>
-<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>The SVG Serializer</title>
-<STYLE type="text/css">
-a.menu {
- color: #FFFFFF;
- text-align:left;
- font-size:12px;
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-weight:plain;
- text-decoration:none;
- padding-left: 14px
-}
-
-A.menu:hover {
- color: #FFCC00
-}
-
-
-.menutitle {
- color: #000000;
- text-align:left;
- font-size:10px;
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-weight:bold;
- padding-left: 8px
-}
-.menuselected {
- color: #FFCC00;
- text-align:left;
- font-size:12px;
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-weight:bold;
- padding-left: 14px
-}
-</STYLE>
-</head>
-<body bgcolor="#ffffff" marginheight="4" marginwidth="4" leftmargin="4" topmargin="4" alink="#cc0000" vlink="#0086b2" link="#039acc" text="#000000">
-<table border="0" cellpadding="0" cellspacing="0" width="100%">
-<tr>
-<td align="left" valign="top" rowspan="3" height="60" width="135"><img border="0" vspace="0" hspace="0" src="images/logo.gif" height="60" width="135"></td><td background="images/line.gif" rowspan="1" colSpan="2" align="left" valign="top" height="0" width="100%"></td><td align="left" valign="top" rowspan="3" height="60" width="29"><img border="0" vspace="0" hspace="0" src="images/right.gif" height="60" width="29"></td>
-</tr>
-<tr>
-<td bgcolor="#0086b2" colspan="2" align="right" valign="top" height="35" width="100%"><font color="#ffffff" face="Verdana, Arial, Helvetica, sans-serif" size="5">The SVG Serializer</font></td>
-</tr>
-<tr>
-<td background="images/bottom.gif" colspan="2" width="100%" valign="top" height="20" bgcolor="#0086b2" align="right">
-<table width="288" cellspacing="0" cellpadding="0" border="0">
-<tr>
-<td align="left" valign="top" height="20" width="96"><a target="new" href="http://xml.apache.org/"><img border="0" vspace="0" hspace="0" name="xml" src="images/button-xml-lo.gif" height="20" width="96" alt="http://xml.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.apache.org/"><img border="0" vspace="0" hspace="0" name="asf" src="images/button-asf-lo.gif" height="20" width="96" alt="http://www.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.w3.org/"><img border="0" vspace="0" hspace="0" name="w3c" src="images/button-w3c-lo.gif" height="20" width="96" alt="http://www.w3.org/"></a></td>
-</tr>
-</table>
-</td>
-</tr>
-</table>
-<table width="100%" cellspacing="0" cellpadding="0" border="0">
-<tr width="100%">
-<td align="left" valign="top" width="120">
-<table width="120" cellspacing="0" cellpadding="0" border="0" bgcolor="#a0a0a0">
-<tr>
-<td valign="top" align="left"><img width="120" vspace="0" src="images/join.gif" hspace="0" height="14" border="0"><br>
-</td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../../index.html">Main</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../index.html">User Documentation</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Serializers</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="serializers.html">Overview</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Default</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="html-serializer.html">HTML Serializer</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Core</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xhtml-serializer.html">XHTML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xml-serializer.html">XML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="text-serializer.html">Text Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="wap-serializer.html">WAP/WML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><span class="menuselected">SVG Serializer</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgxml-serializer.html">SVG/XML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgjpeg-serializer.html">SVG/JPEG Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgpng-serializer.html">SVG/PNG Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgtiff-serializer.html">SVG/TIFF Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="vrml-serializer.html">VRML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="link-serializer.html">Link Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ziparchive-serializer.html">Zip archive Serializer</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Optional</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pdf-serializer.html">PDF Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ps-serializer.html">PS Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pcl-serializer.html">PCL Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xls-serializer.html">HSSF (XLS) Serializer</a></td>
-</tr>
-<tr>
-<td align="left" valign="top"><img width="120" vspace="0" src="images/close.gif" hspace="0" height="14" border="0"><br>
-</td>
-</tr>
-</table>
-</td><td>
-<table cellspacing="15" cellpadding="0" border="0">
-<tr>
-<td>
-
-
-
- <font face="verdana, helvetica, sans serif" size="+2" color="#0086b2">SVG Serializer</font>
-<hr style="color: #0086b2" size="1">
-
-<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Introduction</b></font>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- The SVG Serializer is an advanced serializer which accepts
- valid Scalable Vector Graphic documents (currently to the
- 2000-08-02 Candidate Recommendation specification) and
- renders it to an image which is served just like any other
- document in Cocoon.
- </font>
-</p>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- Why would you want to do this? Well, charts can be produced from the
- same data which generates tables, graphical images with text labels
- all following a standard theme can be generated or normal pages can be
- beautified.
- </font>
-</p>
-
-<p>
-<table border="0" cellpadding="0" cellspacing="3" width="100%">
-<tr>
-<td valign="top" width="28"><img alt="Note" border="0" hspace="0" vspace="0" height="29" width="28" src="images/note.gif"></td><td valign="top"><font color="black" face="verdana,helvetica,sanserif" size="-1"><i>
- For examples of this serializer, see the Cocoon welcome
- page in the distribution (<code><font face="courier, monospaced">[cocoon
- root]/welcome</font></code>).
- </i></font></td>
-</tr>
-</table>
-</p>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- So how does this serializer work?
- </font>
-</p>
-
-<blockquote>
-<ol>
-
-<li>
-<font face="verdana, helvetica, sans serif">Parse and validate SVG document</font>
-</li>
-
-<li>
-<font face="verdana, helvetica, sans serif">Call Batik's <code><font face="courier, monospaced">Transcoder</font></code> to encode this image as an image file, and return it to the user.</font>
-</li>
-
-</ol>
-</blockquote>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- The SVG xml document must have a root element <svg>, using xml namespace
- it is recommended to use the prefix <i>em</i>, and the namespace uri
- <i>http://www.w3.org/2000/svg</i>.
- </font>
-</p>
-
-
-
-<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Usage</b></font>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">The best way to explain how this serializer works is to show some examples.</font>
-</p>
-
-<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2">Basic Example</font>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">This is a basic example of the serializer.</font>
-</p>
-
-<div align="center">
-<table border="0" cellpadding="0" cellspacing="4">
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
-<pre>
-<map:serializers>
- <map:serializer>
- <map:serializer name="svg2jpeg" mime-type="image/jpeg"
- src="org.apache.cocoon.serialization.SVGSerializer">
- <parameter name="transcoder"
- value="org.apache.batik.transcoder.image.JPEGTranscoder"/>
- </map:serializer>
-<map:serializers>
-...
-<map:pipeline>
- <map:match pattern="sample.jpeg">
- <map:generate type="file" src="sample.svg"/>
- <map:serialize type="svg2jpeg"/>
- </map:match>
-</map:pipeline>
- </pre>
-</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-</table>
-</div>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- When the resource <code><font face="courier, monospaced">sample.jpeg</font></code> is requested, a SAX event
- stream is generated from the file <code><font face="courier, monospaced">sample.svg</font></code>, which is
- serialized using the <code><font face="courier, monospaced">svg2jpeg</font></code> serializer. This
- serializer is configured to use a specific transcoder. The MIME type
- is specified so that Cocoon can tell the client which type the
- document is. It can be seen that in general the use of this
- serializer is identical to that of the other serializers.
- </font>
-</p>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- The parameter <i>transcoder</i> selects explicitly a batik transcoder.
- You may want to rely on the default <i>mime-type</i> to
- transcoder association, omitting the transcoder parameter
- </font>
-</p>
-
-<table cellpadding="2" cellspacing="2" border="0" width="100%">
-<caption>
-<font face="verdana,helvetica,sanserif"></font>
-</caption>
-
-<tr>
-<td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>mime-type</b></font></td><td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>transcoder-class</b></font></td>
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/jpeg</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.JPEGTranscoder</font></td>
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/jpg</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.JPEGTranscoder</font></td>
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/png</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.PNGTranscoder</font></td>
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/tiff</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.TIFFTranscoder</font></td>
-</tr>
-
-</table>
-
-
-
-<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2">Advanced Example</font>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">This is a more advanced sample of using the SVG Serializer.</font>
-</p>
-
-<div align="center">
-<table border="0" cellpadding="0" cellspacing="4">
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
-<pre>
-<map:serializers>
- <map:serializer>
- <map:serializer name="svg2jpeg" mime-type="image/jpeg"
- src="org.apache.cocoon.serialization.SVGSerializer">
- <parameter name="transcoder"
- value="org.apache.batik.transcoder.image.JPEGTranscoder"/>
- <parameter name="background_color" type="color" value="#00FF00"/>
- </map:serializer>
-<map:serializers>
-...
-<map:pipeline>
- <map:match pattern="sample.jpeg">
- <map:generate type="file" src="sample.svg"/>
- <map:serialize type="svg2jpeg"/>
- </map:match>
-</map:pipeline>
- </pre>
-</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-</table>
-</div>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- In this example another parameter is given to the serializer,
- <code><font face="courier, monospaced">background_color</font></code>. This parameter is passed to the
- transcoder. The <code><font face="courier, monospaced">type</font></code> argument specifies the type of
- data to convert the <code><font face="courier, monospaced">value</font></code> to. In this example the
- string "#00FF00" is converted to a <code><font face="courier, monospaced">Color</font></code> object, which
- is passed to the transcoder as the background colour to
- use.
- </font>
-</p>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- For a list of the parameters available for each transcoder, refer to
- the Batik API docs.
- </font>
-</p>
-
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- The following table summarizes most useful general SVG ImageTranscoder parameters,
- all of these parameters are mapped to Batik's SVG ImageTranscoder hints.
- </font>
-</p>
-
-<table cellpadding="2" cellspacing="2" border="0" width="100%">
-<caption>
-<font face="verdana,helvetica,sanserif"></font>
-</caption>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">width</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">Specifies the width of the rasterized image explictly.
- If no height is specified the aspect ratio is kept.</font></td>
-
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">height</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">Specifies the width of the rasterized image explictly.
- If no width is specified the aspect ration is kept.</font></td>
-
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">background_color</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">color</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">
- 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.
- A color value of format <code><font face="courier, monospaced">RRGGBB</font></code>,
- or <code><font face="courier, monospaced">#RRGGBB</font></code> sets the background color of the rasterized image, by default
- the background color is white.</font></td>
-
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">language</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">string</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">to set the default language to use
- (may be used by a <switch> SVG element for example), by default language is
- set to <code><font face="courier, monospaced">en</font></code>.</font></td>
-
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">user_stylesheet_ur</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">string</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">to fix the URI of a user stylesheet</font></td>
-
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">pixel_to_mm</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">to specify the pixel to millimeter conversion factor, by default
- its value is <code><font face="courier, monospaced">0.264583</font></code> (96dpi).</font></td>
-
-</tr>
-
-</table>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- For this to work reliably with any transcoder, some magic must be
- done.
- </font>
-</p>
-
-<blockquote>
-<ol>
-
-<li>
-<font face="verdana, helvetica, sans serif">First, the parameter name is transformed to upper-case and then "KEY_" is
- prepended. This is to match the internal naming scheme of the hints
- in the Batik <code><font face="courier, monospaced">Transcoder</font></code> interfaces.
- </font>
-</li>
-
-<li>
-<font face="verdana, helvetica, sans serif">This name is then
- looked up via Reflection to ensure it is a valid parameter on the
- specified transcoder.
- </font>
-</li>
-
-<li>
-<font face="verdana, helvetica, sans serif">Then the value is converted to the type
- specified in the <code><font face="courier, monospaced">type</font></code> attribute (currently supported
- types are string, float, integer, boolean and color) and passed to
- the transcoder.
- </font>
-</li>
-
-</ol>
-</blockquote>
-
-
-
-
-
-</td>
-</tr>
-</table>
-</td>
-</tr>
-</table>
-<table width="100%" cellspacing="0" cellpadding="0" border="0">
-<tr>
-<td bgcolor="#0086b2"><img width="1" src="images/dot.gif" height="1"></td>
-</tr>
-<tr>
-<td align="center"><font size="-1" face="arial,helvetica,sanserif" color="#0086b2"><i>Copyright © 1999-2002 The Apache Software Foundation. All Rights Reserved.</i></font></td>
-</tr>
-</table>
-</body>
-</html>
+<html>
+<head>
+<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>The SVG Serializer</title>
+<STYLE type="text/css">
+a.menu {
+ color: #FFFFFF;
+ text-align:left;
+ font-size:12px;
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+ font-weight:plain;
+ text-decoration:none;
+ padding-left: 14px
+}
+
+A.menu:hover {
+ color: #FFCC00
+}
+
+
+.menutitle {
+ color: #000000;
+ text-align:left;
+ font-size:10px;
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+ font-weight:bold;
+ padding-left: 8px
+}
+.menuselected {
+ color: #FFCC00;
+ text-align:left;
+ font-size:12px;
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+ font-weight:bold;
+ padding-left: 14px
+}
+</STYLE>
+</head>
+<body bgcolor="#ffffff" marginheight="4" marginwidth="4" leftmargin="4" topmargin="4" alink="#cc0000" vlink="#0086b2" link="#039acc" text="#000000">
+<table border="0" cellpadding="0" cellspacing="0" width="100%">
+<tr>
+<td align="left" valign="top" rowspan="3" height="60" width="135"><img border="0" vspace="0" hspace="0" src="images/logo.gif" height="60" width="135"></td><td background="images/line.gif" rowspan="1" colSpan="2" align="left" valign="top" height="0" width="100%"></td><td align="left" valign="top" rowspan="3" height="60" width="29"><img border="0" vspace="0" hspace="0" src="images/right.gif" height="60" width="29"></td>
+</tr>
+<tr>
+<td bgcolor="#0086b2" colspan="2" align="right" valign="top" height="35" width="100%"><font color="#ffffff" face="Verdana, Arial, Helvetica, sans-serif" size="5">The SVG Serializer</font></td>
+</tr>
+<tr>
+<td background="images/bottom.gif" colspan="2" width="100%" valign="top" height="20" bgcolor="#0086b2" align="right">
+<table width="288" cellspacing="0" cellpadding="0" border="0">
+<tr>
+<td align="left" valign="top" height="20" width="96"><a target="new" href="http://xml.apache.org/"><img border="0" vspace="0" hspace="0" name="xml" src="images/button-xml-lo.gif" height="20" width="96" alt="http://xml.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.apache.org/"><img border="0" vspace="0" hspace="0" name="asf" src="images/button-asf-lo.gif" height="20" width="96" alt="http://www.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.w3.org/"><img border="0" vspace="0" hspace="0" name="w3c" src="images/button-w3c-lo.gif" height="20" width="96" alt="http://www.w3.org/"></a></td>
+</tr>
+</table>
+</td>
+</tr>
+</table>
+<table width="100%" cellspacing="0" cellpadding="0" border="0">
+<tr width="100%">
+<td align="left" valign="top" width="120">
+<table width="120" cellspacing="0" cellpadding="0" border="0" bgcolor="#a0a0a0">
+<tr>
+<td valign="top" align="left"><img width="120" vspace="0" src="images/join.gif" hspace="0" height="14" border="0"><br>
+</td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../../index.html">Main</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../index.html">User Documentation</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Serializers</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="serializers.html">Overview</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Default</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="html-serializer.html">HTML Serializer</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Core</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xhtml-serializer.html">XHTML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xml-serializer.html">XML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="text-serializer.html">Text Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="wap-serializer.html">WAP/WML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><span class="menuselected">SVG Serializer</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgxml-serializer.html">SVG/XML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgjpeg-serializer.html">SVG/JPEG Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgpng-serializer.html">SVG/PNG Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgtiff-serializer.html">SVG/TIFF Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="vrml-serializer.html">VRML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="link-serializer.html">Link Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ziparchive-serializer.html">Zip archive Serializer</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Optional</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pdf-serializer.html">PDF Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ps-serializer.html">PS Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pcl-serializer.html">PCL Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xls-serializer.html">HSSF (XLS) Serializer</a></td>
+</tr>
+<tr>
+<td align="left" valign="top"><img width="120" vspace="0" src="images/close.gif" hspace="0" height="14" border="0"><br>
+</td>
+</tr>
+</table>
+</td><td>
+<table cellspacing="15" cellpadding="0" border="0">
+<tr>
+<td>
+
+
+
+ <font face="verdana, helvetica, sans serif" size="+2" color="#0086b2">SVG Serializer</font>
+<hr style="color: #0086b2" size="1">
+
+<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Introduction</b></font>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ The SVG Serializer is an advanced serializer which accepts
+ valid Scalable Vector Graphic documents (currently to the
+ 2000-08-02 Candidate Recommendation specification) and
+ renders it to an image which is served just like any other
+ document in Cocoon.
+ </font>
+</p>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ Why would you want to do this? Well, charts can be produced from the
+ same data which generates tables, graphical images with text labels
+ all following a standard theme can be generated or normal pages can be
+ beautified.
+ </font>
+</p>
+
+<p>
+<table border="0" cellpadding="0" cellspacing="3" width="100%">
+<tr>
+<td valign="top" width="28"><img alt="Note" border="0" hspace="0" vspace="0" height="29" width="28" src="images/note.gif"></td><td valign="top"><font color="black" face="verdana,helvetica,sanserif" size="-1"><i>
+ For examples of this serializer, see the Cocoon welcome
+ page in the distribution (<code><font face="courier, monospaced">[cocoon
+ root]/welcome</font></code>).
+ </i></font></td>
+</tr>
+</table>
+</p>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ So how does this serializer work?
+ </font>
+</p>
+
+<blockquote>
+<ol>
+
+<li>
+<font face="verdana, helvetica, sans serif">Parse and validate SVG document</font>
+</li>
+
+<li>
+<font face="verdana, helvetica, sans serif">Call Batik's <code><font face="courier, monospaced">Transcoder</font></code> to encode this image as an image file, and return it to the user.</font>
+</li>
+
+</ol>
+</blockquote>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ The SVG xml document must have a root element <svg>, using xml namespace
+ it is recommended to use the prefix <i>em</i>, and the namespace uri
+ <i>http://www.w3.org/2000/svg</i>.
+ </font>
+</p>
+
+
+
+<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Usage</b></font>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">The best way to explain how this serializer works is to show some examples.</font>
+</p>
+
+<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2">Basic Example</font>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">This is a basic example of the serializer.</font>
+</p>
+
+<div align="center">
+<table border="0" cellpadding="0" cellspacing="4">
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
+<pre>
+<map:serializers>
+ <map:serializer>
+ <map:serializer name="svg2jpeg" mime-type="image/jpeg"
+ src="org.apache.cocoon.serialization.SVGSerializer">
+ <parameter name="transcoder"
+ value="org.apache.batik.transcoder.image.JPEGTranscoder"/>
+ </map:serializer>
+<map:serializers>
+...
+<map:pipeline>
+ <map:match pattern="sample.jpeg">
+ <map:generate type="file" src="sample.svg"/>
+ <map:serialize type="svg2jpeg"/>
+ </map:match>
+</map:pipeline>
+ </pre>
+</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+</table>
+</div>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ When the resource <code><font face="courier, monospaced">sample.jpeg</font></code> is requested, a SAX event
+ stream is generated from the file <code><font face="courier, monospaced">sample.svg</font></code>, which is
+ serialized using the <code><font face="courier, monospaced">svg2jpeg</font></code> serializer. This
+ serializer is configured to use a specific transcoder. The MIME type
+ is specified so that Cocoon can tell the client which type the
+ document is. It can be seen that in general the use of this
+ serializer is identical to that of the other serializers.
+ </font>
+</p>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ The parameter <i>transcoder</i> selects explicitly a batik transcoder.
+ You may want to rely on the default <i>mime-type</i> to
+ transcoder association, omitting the transcoder parameter
+ </font>
+</p>
+
+<table cellpadding="2" cellspacing="2" border="0" width="100%">
+<caption>
+<font face="verdana,helvetica,sanserif"></font>
+</caption>
+
+<tr>
+<td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>mime-type</b></font></td><td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>transcoder-class</b></font></td>
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/jpeg</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.JPEGTranscoder</font></td>
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/jpg</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.JPEGTranscoder</font></td>
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/png</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.PNGTranscoder</font></td>
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">image/tiff</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">org.apache.batik.transcoder.image.TIFFTranscoder</font></td>
+</tr>
+
+</table>
+
+
+
+<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2">Advanced Example</font>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">This is a more advanced sample of using the SVG Serializer.</font>
+</p>
+
+<div align="center">
+<table border="0" cellpadding="0" cellspacing="4">
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
+<pre>
+<map:serializers>
+ <map:serializer>
+ <map:serializer name="svg2jpeg" mime-type="image/jpeg"
+ src="org.apache.cocoon.serialization.SVGSerializer">
+ <parameter name="transcoder"
+ value="org.apache.batik.transcoder.image.JPEGTranscoder"/>
+ <parameter name="background_color" type="color" value="#00FF00"/>
+ </map:serializer>
+<map:serializers>
+...
+<map:pipeline>
+ <map:match pattern="sample.jpeg">
+ <map:generate type="file" src="sample.svg"/>
+ <map:serialize type="svg2jpeg"/>
+ </map:match>
+</map:pipeline>
+ </pre>
+</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+</table>
+</div>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ In this example another parameter is given to the serializer,
+ <code><font face="courier, monospaced">background_color</font></code>. This parameter is passed to the
+ transcoder. The <code><font face="courier, monospaced">type</font></code> argument specifies the type of
+ data to convert the <code><font face="courier, monospaced">value</font></code> to. In this example the
+ string "#00FF00" is converted to a <code><font face="courier, monospaced">Color</font></code> object, which
+ is passed to the transcoder as the background colour to
+ use.
+ </font>
+</p>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ For a list of the parameters available for each transcoder, refer to
+ the Batik API docs.
+ </font>
+</p>
+
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ The following table summarizes most useful general SVG ImageTranscoder parameters,
+ all of these parameters are mapped to Batik's SVG ImageTranscoder hints.
+ </font>
+</p>
+
+<table cellpadding="2" cellspacing="2" border="0" width="100%">
+<caption>
+<font face="verdana,helvetica,sanserif"></font>
+</caption>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">width</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">Specifies the width of the rasterized image explictly.
+ If no height is specified the aspect ratio is kept.</font></td>
+
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">height</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">Specifies the width of the rasterized image explictly.
+ If no width is specified the aspect ration is kept.</font></td>
+
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">background_color</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">color</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">
+ 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.
+ A color value of format <code><font face="courier, monospaced">RRGGBB</font></code>,
+ or <code><font face="courier, monospaced">#RRGGBB</font></code> sets the background color of the rasterized image, by default
+ the background color is white.</font></td>
+
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">language</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">string</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">to set the default language to use
+ (may be used by a <switch> SVG element for example), by default language is
+ set to <code><font face="courier, monospaced">en</font></code>.</font></td>
+
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">user_stylesheet_ur</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">string</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">to fix the URI of a user stylesheet</font></td>
+
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">pixel_to_mm</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">to specify the pixel to millimeter conversion factor, by default
+ its value is <code><font face="courier, monospaced">0.264583</font></code> (96dpi).</font></td>
+
+</tr>
+
+</table>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ For this to work reliably with any transcoder, some magic must be
+ done.
+ </font>
+</p>
+
+<blockquote>
+<ol>
+
+<li>
+<font face="verdana, helvetica, sans serif">First, the parameter name is transformed to upper-case and then "KEY_" is
+ prepended. This is to match the internal naming scheme of the hints
+ in the Batik <code><font face="courier, monospaced">Transcoder</font></code> interfaces.
+ </font>
+</li>
+
+<li>
+<font face="verdana, helvetica, sans serif">This name is then
+ looked up via Reflection to ensure it is a valid parameter on the
+ specified transcoder.
+ </font>
+</li>
+
+<li>
+<font face="verdana, helvetica, sans serif">Then the value is converted to the type
+ specified in the <code><font face="courier, monospaced">type</font></code> attribute (currently supported
+ types are string, float, integer, boolean and color) and passed to
+ the transcoder.
+ </font>
+</li>
+
+</ol>
+</blockquote>
+
+
+
+
+
+</td>
+</tr>
+</table>
+</td>
+</tr>
+</table>
+<table width="100%" cellspacing="0" cellpadding="0" border="0">
+<tr>
+<td bgcolor="#0086b2"><img width="1" src="images/dot.gif" height="1"></td>
+</tr>
+<tr>
+<td align="center"><font size="-1" face="arial,helvetica,sanserif" color="#0086b2"><i>Copyright © 1999-2002 The Apache Software Foundation. All Rights Reserved.</i></font></td>
+</tr>
+</table>
+</body>
+</html>
Modified: cocoon/site/site/2.0/userdocs/serializers/svgjpeg-serializer.html
URL: http://svn.apache.org/viewvc/cocoon/site/site/2.0/userdocs/serializers/svgjpeg-serializer.html?rev=573901&r1=573900&r2=573901&view=diff
==============================================================================
--- cocoon/site/site/2.0/userdocs/serializers/svgjpeg-serializer.html (original)
+++ cocoon/site/site/2.0/userdocs/serializers/svgjpeg-serializer.html Sat Sep 8 13:17:41 2007
@@ -1,332 +1,332 @@
-<html>
-<head>
-<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>SVG/JPEG Serializer</title>
-<STYLE type="text/css">
-a.menu {
- color: #FFFFFF;
- text-align:left;
- font-size:12px;
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-weight:plain;
- text-decoration:none;
- padding-left: 14px
-}
-
-A.menu:hover {
- color: #FFCC00
-}
-
-
-.menutitle {
- color: #000000;
- text-align:left;
- font-size:10px;
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-weight:bold;
- padding-left: 8px
-}
-.menuselected {
- color: #FFCC00;
- text-align:left;
- font-size:12px;
- font-family: Verdana, Arial, Helvetica, sans-serif;
- font-weight:bold;
- padding-left: 14px
-}
-</STYLE>
-</head>
-<body bgcolor="#ffffff" marginheight="4" marginwidth="4" leftmargin="4" topmargin="4" alink="#cc0000" vlink="#0086b2" link="#039acc" text="#000000">
-<table border="0" cellpadding="0" cellspacing="0" width="100%">
-<tr>
-<td align="left" valign="top" rowspan="3" height="60" width="135"><img border="0" vspace="0" hspace="0" src="images/logo.gif" height="60" width="135"></td><td background="images/line.gif" rowspan="1" colSpan="2" align="left" valign="top" height="0" width="100%"></td><td align="left" valign="top" rowspan="3" height="60" width="29"><img border="0" vspace="0" hspace="0" src="images/right.gif" height="60" width="29"></td>
-</tr>
-<tr>
-<td bgcolor="#0086b2" colspan="2" align="right" valign="top" height="35" width="100%"><font color="#ffffff" face="Verdana, Arial, Helvetica, sans-serif" size="5">SVG/JPEG Serializer</font></td>
-</tr>
-<tr>
-<td background="images/bottom.gif" colspan="2" width="100%" valign="top" height="20" bgcolor="#0086b2" align="right">
-<table width="288" cellspacing="0" cellpadding="0" border="0">
-<tr>
-<td align="left" valign="top" height="20" width="96"><a target="new" href="http://xml.apache.org/"><img border="0" vspace="0" hspace="0" name="xml" src="images/button-xml-lo.gif" height="20" width="96" alt="http://xml.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.apache.org/"><img border="0" vspace="0" hspace="0" name="asf" src="images/button-asf-lo.gif" height="20" width="96" alt="http://www.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.w3.org/"><img border="0" vspace="0" hspace="0" name="w3c" src="images/button-w3c-lo.gif" height="20" width="96" alt="http://www.w3.org/"></a></td>
-</tr>
-</table>
-</td>
-</tr>
-</table>
-<table width="100%" cellspacing="0" cellpadding="0" border="0">
-<tr width="100%">
-<td align="left" valign="top" width="120">
-<table width="120" cellspacing="0" cellpadding="0" border="0" bgcolor="#a0a0a0">
-<tr>
-<td valign="top" align="left"><img width="120" vspace="0" src="images/join.gif" hspace="0" height="14" border="0"><br>
-</td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../../index.html">Main</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../index.html">User Documentation</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Serializers</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="serializers.html">Overview</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Default</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="html-serializer.html">HTML Serializer</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Core</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xhtml-serializer.html">XHTML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xml-serializer.html">XML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="text-serializer.html">Text Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="wap-serializer.html">WAP/WML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svg-serializer.html">SVG Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgxml-serializer.html">SVG/XML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><span class="menuselected">SVG/JPEG Serializer</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgpng-serializer.html">SVG/PNG Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgtiff-serializer.html">SVG/TIFF Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="vrml-serializer.html">VRML Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="link-serializer.html">Link Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ziparchive-serializer.html">Zip archive Serializer</a></td>
-</tr>
-<tr>
-<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
-<span class="menutitle">Optional</span></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pdf-serializer.html">PDF Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ps-serializer.html">PS Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pcl-serializer.html">PCL Serializer</a></td>
-</tr>
-<tr>
-<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xls-serializer.html">HSSF (XLS) Serializer</a></td>
-</tr>
-<tr>
-<td align="left" valign="top"><img width="120" vspace="0" src="images/close.gif" hspace="0" height="14" border="0"><br>
-</td>
-</tr>
-</table>
-</td><td>
-<table cellspacing="15" cellpadding="0" border="0">
-<tr>
-<td>
-
-
- <font face="verdana, helvetica, sans serif" size="+2" color="#0086b2">SVG/JPEG Serializer</font>
-<hr style="color: #0086b2" size="1">
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- The SVG/JPEG serializes an xml svg document to a jpeg image.
- The serialization uses the Batik's JPEGTranscoder internally.
- </font>
-</p>
-
-<blockquote>
-<ul>
-
-<li>
-<font face="verdana, helvetica, sans serif">Name : svg2jpeg</font>
-</li>
-
-<li>
-<font face="verdana, helvetica, sans serif">Class: org.apache.cocoon.serialization.SVGSerializer</font>
-</li>
-
-<li>
-<font face="verdana, helvetica, sans serif">Cacheable: yes</font>
-</li>
-
-</ul>
-</blockquote>
-
-<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Sitemap Configuration</b></font>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- A minimal sitemap configuration snippet declaring the svg2jpeg serializer:
- </font>
-</p>
-
-<div align="center">
-<table border="0" cellpadding="0" cellspacing="4">
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
-<pre>
-<map:serializers..
- <map:serializer name="svg2jpeg"
- src="org.apache.cocoon.serialization.SVGSerializer"
- mime-type="image/jpeg"
- logger="sitemap.serializer.svg2jpeg"
- >
- </map:serializer>
-</pre>
-</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-</table>
-</div>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- A sitemap pipeline snippet using the svg2jpeg serializer:
- </font>
-</p>
-
-<div align="center">
-<table border="0" cellpadding="0" cellspacing="4">
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
-<pre>
-<map:match pattern="svg/*.jpg">
- <map:generate src="docs/samples/svg/{1}.svg"/>
- <map:serialize type="svg2jpeg"/>
-</map:match>
-</pre>
-</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-</table>
-</div>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- In the declaration section of the svg2jpeg a number of parameters can be specified.
- The following snippet set the background color explicitly:
- </font>
-</p>
-
-<div align="center">
-<table border="0" cellpadding="0" cellspacing="4">
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
-<pre>
-<map:serializers..
- <map:serializer name="svg2jpeg"
- src="org.apache.cocoon.serialization.SVGSerializer"
- mime-type="image/jpeg"
- logger="sitemap.serializer.svg2jpeg"
- >
- <parameter name="background_color" type="color" value="#ff00ff"/>
- </map:serializer>
-</pre>
-</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-<tr>
-<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
-</tr>
-</table>
-</div>
-
-
-<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>JPEGTranscoder Parameters</b></font>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- General ImageTranscoder parameters are described
- at the <a href="svg-serializer.html">SVG Serializer</a> user documentation.
- </font>
-</p>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- The following section presents JPEGTranscoder specific parameters configurable for the JPEGTranscoder.
- </font>
-</p>
-
-<table cellpadding="2" cellspacing="2" border="0" width="100%">
-<caption>
-<font face="verdana,helvetica,sanserif"></font>
-</caption>
-
-<tr>
-<td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>Parameter</b></font></td><td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>Type</b></font></td><td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>Comment</b></font></td>
-</tr>
-
-<tr>
-<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">quality</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">Specifies the JPEG quality as value between 0.0 and 1.0,
- 1.0 specifies highest quality. Usually a value of 0.9 is choosen.</font></td>
-
-</tr>
-
-</table>
-
-
-<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Further Reading</b></font>
-
-<p>
-<font color="black" face="verdana,helvetica,sanserif">
- Further details about JPEGTranscoder, ImageTranscoder is available
- at <a href="http://xml.apache.org/batik">Batik</a>.
- </font>
-</p>
-
-
-
-
-</td>
-</tr>
-</table>
-</td>
-</tr>
-</table>
-<table width="100%" cellspacing="0" cellpadding="0" border="0">
-<tr>
-<td bgcolor="#0086b2"><img width="1" src="images/dot.gif" height="1"></td>
-</tr>
-<tr>
-<td align="center"><font size="-1" face="arial,helvetica,sanserif" color="#0086b2"><i>Copyright © 1999-2002 The Apache Software Foundation. All Rights Reserved.</i></font></td>
-</tr>
-</table>
-</body>
-</html>
+<html>
+<head>
+<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>SVG/JPEG Serializer</title>
+<STYLE type="text/css">
+a.menu {
+ color: #FFFFFF;
+ text-align:left;
+ font-size:12px;
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+ font-weight:plain;
+ text-decoration:none;
+ padding-left: 14px
+}
+
+A.menu:hover {
+ color: #FFCC00
+}
+
+
+.menutitle {
+ color: #000000;
+ text-align:left;
+ font-size:10px;
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+ font-weight:bold;
+ padding-left: 8px
+}
+.menuselected {
+ color: #FFCC00;
+ text-align:left;
+ font-size:12px;
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+ font-weight:bold;
+ padding-left: 14px
+}
+</STYLE>
+</head>
+<body bgcolor="#ffffff" marginheight="4" marginwidth="4" leftmargin="4" topmargin="4" alink="#cc0000" vlink="#0086b2" link="#039acc" text="#000000">
+<table border="0" cellpadding="0" cellspacing="0" width="100%">
+<tr>
+<td align="left" valign="top" rowspan="3" height="60" width="135"><img border="0" vspace="0" hspace="0" src="images/logo.gif" height="60" width="135"></td><td background="images/line.gif" rowspan="1" colSpan="2" align="left" valign="top" height="0" width="100%"></td><td align="left" valign="top" rowspan="3" height="60" width="29"><img border="0" vspace="0" hspace="0" src="images/right.gif" height="60" width="29"></td>
+</tr>
+<tr>
+<td bgcolor="#0086b2" colspan="2" align="right" valign="top" height="35" width="100%"><font color="#ffffff" face="Verdana, Arial, Helvetica, sans-serif" size="5">SVG/JPEG Serializer</font></td>
+</tr>
+<tr>
+<td background="images/bottom.gif" colspan="2" width="100%" valign="top" height="20" bgcolor="#0086b2" align="right">
+<table width="288" cellspacing="0" cellpadding="0" border="0">
+<tr>
+<td align="left" valign="top" height="20" width="96"><a target="new" href="http://xml.apache.org/"><img border="0" vspace="0" hspace="0" name="xml" src="images/button-xml-lo.gif" height="20" width="96" alt="http://xml.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.apache.org/"><img border="0" vspace="0" hspace="0" name="asf" src="images/button-asf-lo.gif" height="20" width="96" alt="http://www.apache.org/"></a></td><td align="left" valign="top" height="20" width="96"><a target="new" href="http://www.w3.org/"><img border="0" vspace="0" hspace="0" name="w3c" src="images/button-w3c-lo.gif" height="20" width="96" alt="http://www.w3.org/"></a></td>
+</tr>
+</table>
+</td>
+</tr>
+</table>
+<table width="100%" cellspacing="0" cellpadding="0" border="0">
+<tr width="100%">
+<td align="left" valign="top" width="120">
+<table width="120" cellspacing="0" cellpadding="0" border="0" bgcolor="#a0a0a0">
+<tr>
+<td valign="top" align="left"><img width="120" vspace="0" src="images/join.gif" hspace="0" height="14" border="0"><br>
+</td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../../index.html">Main</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="../index.html">User Documentation</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Serializers</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="serializers.html">Overview</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Default</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="html-serializer.html">HTML Serializer</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Core</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xhtml-serializer.html">XHTML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xml-serializer.html">XML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="text-serializer.html">Text Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="wap-serializer.html">WAP/WML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svg-serializer.html">SVG Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgxml-serializer.html">SVG/XML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><span class="menuselected">SVG/JPEG Serializer</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgpng-serializer.html">SVG/PNG Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="svgtiff-serializer.html">SVG/TIFF Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="vrml-serializer.html">VRML Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="link-serializer.html">Link Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ziparchive-serializer.html">Zip archive Serializer</a></td>
+</tr>
+<tr>
+<td background="images/label-background_b.gif" bgcolor="#959595" valign="top"><img width="120" height="6" src="images/separator.gif"><br>
+<span class="menutitle">Optional</span></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pdf-serializer.html">PDF Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="ps-serializer.html">PS Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="pcl-serializer.html">PCL Serializer</a></td>
+</tr>
+<tr>
+<td valign="top" bgcolor="#959595" background="images/label-background_a.gif"><a class="menu" href="xls-serializer.html">HSSF (XLS) Serializer</a></td>
+</tr>
+<tr>
+<td align="left" valign="top"><img width="120" vspace="0" src="images/close.gif" hspace="0" height="14" border="0"><br>
+</td>
+</tr>
+</table>
+</td><td>
+<table cellspacing="15" cellpadding="0" border="0">
+<tr>
+<td>
+
+
+ <font face="verdana, helvetica, sans serif" size="+2" color="#0086b2">SVG/JPEG Serializer</font>
+<hr style="color: #0086b2" size="1">
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ The SVG/JPEG serializes an xml svg document to a jpeg image.
+ The serialization uses the Batik's JPEGTranscoder internally.
+ </font>
+</p>
+
+<blockquote>
+<ul>
+
+<li>
+<font face="verdana, helvetica, sans serif">Name : svg2jpeg</font>
+</li>
+
+<li>
+<font face="verdana, helvetica, sans serif">Class: org.apache.cocoon.serialization.SVGSerializer</font>
+</li>
+
+<li>
+<font face="verdana, helvetica, sans serif">Cacheable: yes</font>
+</li>
+
+</ul>
+</blockquote>
+
+<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Sitemap Configuration</b></font>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ A minimal sitemap configuration snippet declaring the svg2jpeg serializer:
+ </font>
+</p>
+
+<div align="center">
+<table border="0" cellpadding="0" cellspacing="4">
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
+<pre>
+<map:serializers..
+ <map:serializer name="svg2jpeg"
+ src="org.apache.cocoon.serialization.SVGSerializer"
+ mime-type="image/jpeg"
+ logger="sitemap.serializer.svg2jpeg"
+ >
+ </map:serializer>
+</pre>
+</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+</table>
+</div>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ A sitemap pipeline snippet using the svg2jpeg serializer:
+ </font>
+</p>
+
+<div align="center">
+<table border="0" cellpadding="0" cellspacing="4">
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
+<pre>
+<map:match pattern="svg/*.jpg">
+ <map:generate src="docs/samples/svg/{1}.svg"/>
+ <map:serialize type="svg2jpeg"/>
+</map:match>
+</pre>
+</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+</table>
+</div>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ In the declaration section of the svg2jpeg a number of parameters can be specified.
+ The following snippet set the background color explicitly:
+ </font>
+</p>
+
+<div align="center">
+<table border="0" cellpadding="0" cellspacing="4">
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td bgcolor="#ffffff">
+<pre>
+<map:serializers..
+ <map:serializer name="svg2jpeg"
+ src="org.apache.cocoon.serialization.SVGSerializer"
+ mime-type="image/jpeg"
+ logger="sitemap.serializer.svg2jpeg"
+ >
+ <parameter name="background_color" type="color" value="#ff00ff"/>
+ </map:serializer>
+</pre>
+</td><td width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+<tr>
+<td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td><td height="1" width="1" bgcolor="#0086b2"><img border="0" hspace="0" vspace="0" height="1" width="1" src="images/void.gif"></td>
+</tr>
+</table>
+</div>
+
+
+<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>JPEGTranscoder Parameters</b></font>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ General ImageTranscoder parameters are described
+ at the <a href="svg-serializer.html">SVG Serializer</a> user documentation.
+ </font>
+</p>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ The following section presents JPEGTranscoder specific parameters configurable for the JPEGTranscoder.
+ </font>
+</p>
+
+<table cellpadding="2" cellspacing="2" border="0" width="100%">
+<caption>
+<font face="verdana,helvetica,sanserif"></font>
+</caption>
+
+<tr>
+<td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>Parameter</b></font></td><td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>Type</b></font></td><td align="center" valign="center" rowspan="1" colspan="1" bgcolor="#039acc"><font face="verdana,helvetica,sanserif" size="-1" color="white"><b>Comment</b></font></td>
+</tr>
+
+<tr>
+<td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">quality</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">float</font></td><td align="left" valign="top" rowspan="1" colspan="1" bgcolor="#a0ddf0"><font face="verdana,helvetica,sanserif" size="-1" color="black">Specifies the JPEG quality as value between 0.0 and 1.0,
+ 1.0 specifies highest quality. Usually a value of 0.9 is choosen.</font></td>
+
+</tr>
+
+</table>
+
+
+<font face="verdana, helvetica, sans serif" size="+1" color="#0086b2"><b>Further Reading</b></font>
+
+<p>
+<font color="black" face="verdana,helvetica,sanserif">
+ Further details about JPEGTranscoder, ImageTranscoder is available
+ at <a href="http://xml.apache.org/batik">Batik</a>.
+ </font>
+</p>
+
+
+
+
+</td>
+</tr>
+</table>
+</td>
+</tr>
+</table>
+<table width="100%" cellspacing="0" cellpadding="0" border="0">
+<tr>
+<td bgcolor="#0086b2"><img width="1" src="images/dot.gif" height="1"></td>
+</tr>
+<tr>
+<td align="center"><font size="-1" face="arial,helvetica,sanserif" color="#0086b2"><i>Copyright © 1999-2002 The Apache Software Foundation. All Rights Reserved.</i></font></td>
+</tr>
+</table>
+</body>
+</html>