You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Jeremy Quinn <je...@media.demon.co.uk> on 2001/01/03 14:06:06 UTC

XSLFO questions

Dear All,

I started playing with XSL-FO in Cocoon 1 recently to transform XML to PDF.

I have some questions .... forgive me if some are off-topic ....

1. Memory problems
I get a lot of "out of memory" errors while rendering PDFs.
OK, so some of my XML files are quite large (up to 150K), but what is
particularly weird is that when I look at TomCat's console, during the
rendering process, often it looks like the formatting is repeated again and
again (often till all memory is used up, but not always). It is almost as
if the formatter is recursing into itself. You see the same page number
reports several times in *one* server hit.

At first it appeared that the repeated processing was caused when I had
syntactic errors in my XSLFO, but now it just seems to happen sporadically.

Any ideas anyone?

2. XSLFO -> other formats
Has anyone seen XSL StyleSheets or Formatters that output any other formats
from XSLFO apart from PDF? Like maybe HTML+CSS, SVG, Flash, etc.

3. Producing Bookmarks.
You know when you use Acrobat (plugin or App) to view PDFs, it is common
for files to have a list or hierarchy of "Bookmarks" typically shown in a
Frame on the left-hand side of the window.

Does anyone know if it is possible to generate a PDF using FOP (the XSLFO
to PDF Formatter) that has these Bookmarks available?


Thanks for any help

regards Jeremy
-- 
   ___________________________________________________________________

   Jeremy Quinn                                           Karma Divers
                                                       webSpace Design
                                            HyperMedia Research Centre

   <ma...@mac.com>     		 <http://www.media.demon.co.uk>
    <phone:+44.[0].20.7737.6831>        <pa...@sms.genie.co.uk>

Re: XSLFO questions

Posted by Jeremy Quinn <je...@media.demon.co.uk>.
At 11:48 -0800 03/01/01, Scott Jones wrote:
>Hi Jeremy,

Thanks for your reply, Scott.

>> I get a lot of "out of memory" errors while rendering PDFs.

>XML files are about twice as big as mine are, but I don't see anything like
>what you are talking about on my console -- which version of FOP are you
>using?  FOP 0.15 is supported by the latest CVS code for Cocoon 1.8.1-dev,
>so you might want to consider trying that (that is what I am using).

Yea, I realised late last night I had an old FOP installed v0.13 (!)
Version 0.15 is a lot better!
Now version 0.16 is out, it would be nice to work out what is stopping
Cocoon from compiling with it .... I think there nay have been some changes
in the API?

>> 2. XSLFO -> other formats
>> Has anyone seen XSL StyleSheets or Formatters that output any other
>formats
>> from XSLFO apart from PDF? Like maybe HTML+CSS, SVG, Flash, etc.
>
>There has been some discussion about creating RTF files on the
>fop-dev@xml.apache.org mailing list -- maybe you'd like to subscribe?

At this early stage I might find fop-users more useful ;)

>> 3. Producing Bookmarks.
>> You know when you use Acrobat (plugin or App) to view PDFs, it is common
>> for files to have a list or hierarchy of "Bookmarks" typically shown in a
>> Frame on the left-hand side of the window.
>>
>> Does anyone know if it is possible to generate a PDF using FOP (the XSLFO
>> to PDF Formatter) that has these Bookmarks available?
>
>This hasn't been implemented, although someone just brought it up a right
>before the holidays -- it's not part of the XSL FO spec, but would be very
>cool.  The conclusion that was reached on the list was to wait until FOP met
>the XSL FO spec before implementing extensions.  However, if you were
>motivated to work on it, then I'd bet that people would be ready to help!

It would be cool!
I can think of so many other additions :(
PDF Forms anyone ?


>Hope this helps.

Thanks

Jeremy
-- 
   ___________________________________________________________________

   Jeremy Quinn                                           Karma Divers
                                                       webSpace Design
                                            HyperMedia Research Centre

   <ma...@mac.com>     		 <http://www.media.demon.co.uk>
    <phone:+44.[0].20.7737.6831>        <pa...@sms.genie.co.uk>

Re: XSLFO questions

Posted by Scott Jones <sc...@on-sitemanager.com>.
Hi Jeremy,

> I get a lot of "out of memory" errors while rendering PDFs.
> OK, so some of my XML files are quite large (up to 150K), but what is
> particularly weird is that when I look at TomCat's console, during the
> rendering process, often it looks like the formatting is repeated again
and
> again (often till all memory is used up, but not always). It is almost as
> if the formatter is recursing into itself. You see the same page number
> reports several times in *one* server hit.
>
> At first it appeared that the repeated processing was caused when I had
> syntactic errors in my XSLFO, but now it just seems to happen
sporadically.

XML files are about twice as big as mine are, but I don't see anything like
what you are talking about on my console -- which version of FOP are you
using?  FOP 0.15 is supported by the latest CVS code for Cocoon 1.8.1-dev,
so you might want to consider trying that (that is what I am using).

Are you embedding images into your PDF files?  The image handling in earlier
versions of FOP is not that good, and will cause your PDF files to grow to
massive sizes.

> 2. XSLFO -> other formats
> Has anyone seen XSL StyleSheets or Formatters that output any other
formats
> from XSLFO apart from PDF? Like maybe HTML+CSS, SVG, Flash, etc.

There has been some discussion about creating RTF files on the
fop-dev@xml.apache.org mailing list -- maybe you'd like to subscribe?

> 3. Producing Bookmarks.
> You know when you use Acrobat (plugin or App) to view PDFs, it is common
> for files to have a list or hierarchy of "Bookmarks" typically shown in a
> Frame on the left-hand side of the window.
>
> Does anyone know if it is possible to generate a PDF using FOP (the XSLFO
> to PDF Formatter) that has these Bookmarks available?

This hasn't been implemented, although someone just brought it up a right
before the holidays -- it's not part of the XSL FO spec, but would be very
cool.  The conclusion that was reached on the list was to wait until FOP met
the XSL FO spec before implementing extensions.  However, if you were
motivated to work on it, then I'd bet that people would be ready to help!

Hope this helps.

-Scott