On 27.04.2006 12:08:59 Camilakill wrote: > > alright! So, in my case, it's not going to work because I need TureType > fonts! > I will come back to the "image approach"!!!
Except if you decide to implement TrueType font embedding for PostScript and send a patch. :-) > I've instaled the FOP 0.92beta now! > Is there any way I can render an image into a postscript file without having > to save it in a file first? Several. You can encode the bitmap image as a RFC 2397 data URL. FOP 0.92beta supports them natively. The other one is again the URIResolver. The best example of such a beast is our own FOURIResolver [1], or even simpler the ServletContextURIResolver [2]. It allows you to define your own special URIs. When your URIResolver encounters such a URI, it can return a StreamSource where you can set a ByteArrayInputStream which operates on the in-memory representation of the image you created earlier. The URIResolver can be set on the FopFactory using setURIResolver(). See also: http://xmlgraphics.apache.org/fop/0.92/embedding.html#fop-factory A more direct way, but probably a little more complicated and largely undocumented, yet, would we to use the org.apache.xmlgraphics.ps package in the xmlgraphics-commons.jar which provides tools for creating PostScript files (without XSL-FO). [1] http://svn.apache.org/viewcvs.cgi/xmlgraphics/fop/trunk/src/java/org/apache/fop/apps/FOURIResolver.java?view=markup [2] http://svn.apache.org/viewcvs.cgi/xmlgraphics/fop/trunk/src/java/org/apache/fop/servlet/ServletContextURIResolver.java?view=markup > As I have to create images dinamically, it would be a piece of work to store > it and identify unically the files etc. Jeremias Maerki --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
