If you don't know the sizes of the images at design time, you'd probably have to write an XSLT plug-in that would pre-load the image using the image loading framework from Apache XML Graphics Commons. This should be quite fast at runtime but possibly not so quick to implement.
On 03.12.2010 00:21:53 Lucian Opris wrote: > Thank you again for the answer. Considering I'll use fo:external-graphic, is > there easy way to determine page size in style? For large attachments (100 > pages) having many fo:page-sequence will not slow down the rendering > process? > Thanks, > > Lucian Opris > > -----Original Message----- > From: Jeremias Maerki [mailto:d...@jeremias-maerki.ch] > Sent: Thursday, December 02, 2010 2:07 AM > To: fop-users@xmlgraphics.apache.org > Subject: Re: Add-ons for Apache FOP > > fox:external-document doesn't allow any additional content besides the > full-page images. You'll have to determine the page sizes yourself and > use normal fo:page-sequence elements to set up the image for full-page > display. > > The PDF size increases that much because there is currently no easy way > to cache the already transferred PDF objects so they are not transferred > again for each page. I've experimented with that some time ago but had > to disable that feature because of massive problems. I may revisit this > at some point (no current plans). If you have to add larger PDFs to a > document I suggest you do that as a post-processing step using Apache > PDFBox. > > On 01.12.2010 21:45:05 Lucian Opris wrote: > > Also, I've noticed that without using fox:external-document the pdf size > is > > about 17K then using fox:external-document to call a 608K PDF I've got a > > resulting 2.104K PDF. Do you know what could cause such a dramatic file > > increase? > > > > Lucian Opris > > > > -----Original Message----- > > From: Lucian Opris [mailto:lucian.op...@bluematrix.com] > > Sent: Wednesday, December 01, 2010 3:12 PM > > To: fop-users@xmlgraphics.apache.org > > Subject: RE: Add-ons for Apache FOP > > > > Thank you Jeremias, > > I've added the <fox:external-document > > src="C:/FOP1/fop-1.0/attachments/my.pdf"/> to work in conjunction with new > > namespace > > xmlns:fox="http://xmlgraphics.apache.org/fop/extensions" and it worked > fine. > > Now the question is can we stamp header and footers on external pdf called > > with fox since fox:external-document is peer with fo:page-sequence? > > > > > > Lucian Opris > > > > -----Original Message----- > > From: Jeremias Maerki [mailto:d...@jeremias-maerki.ch] > > Sent: Wednesday, December 01, 2010 2:13 AM > > To: fop-users@xmlgraphics.apache.org > > Subject: Re: Add-ons for Apache FOP > > > > Hi Lucian > > > > On 30.11.2010 20:35:48 Lucian Opris wrote: > > > Hi Jeremias, > > > I'm using your FOP add-ons to call PDF attachments as images using > > > <fo:external-graphic src="my-doc.pdf#page=1"/>. > > > Is there a way to preserve pdf page size for landscape pages or should I > > use > > > <fox:external-document src="my-doc.pdf"/>? > > > > Support for landscape pages is available in the latest release (2.0.0) > > of the plug-in. > > > > > Are PDFs with mixed pagesizes work with <fox:external-document and have > > the > > > footer stamping start at the same point from left? > > > > Not sure what you mean by that. With fox:external-document the target > > page will have the exact size of the respective input page. This should > > work for each page independently. > > > > Jeremias Maerki > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org > For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org > For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org Jeremias Maerki --------------------------------------------------------------------- To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org