xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sushanth <sushanth....@gmail.com>
Subject Keeping fo:table-header and fo:table-body together within a page
Date Wed, 07 Jul 2010 09:31:12 GMT

First of all, I'm extremely sorry for the long text that follows this :)

I looked all around the internet for a solution to this problem and still
haven't found a straightforward solution. I am generating a PDF using FOP
0.95, where I have a bunch of pages, each of which can have multiple tables.
There are times I encounter this problem where the fo:table-header content
of one of the tables ends up as the last element on a page with no
table-body under it. The table-body starts on the next page, of course
preceded by table-header on the next page also which is fine, but is there
any way I can prevent a table-header from ending up as the last element on a
page if there is not enough space for the table-body to be displayed on the
same page?

The options I have tried so far include using
keep-together.within-page="always". This doesn't help because some tables
can even span multiple pages, in which case a page-break is not introduced.
I have read that FOP-Trunk provides integer support for keep-together, but I
wasn't able to build the FOP-Trunk jar. Is there any place where I can
directly download the latest FOP-Trunk jar?

The other option I have tried is brute-force, trying to keep count of the
number of rows printed on a page and introducing a manual page break, but
this is an ugly patch and I want to avoid using it and it will not work in
all scenarios.

Is there a simple solution to this problem using FOP 0.95? I'm sure somebody
would have anticipated this problem while developing FOP and must have some
solution in place for this :) Please let me know. I can't live with this
problem anymore.

-- 
View this message in context: http://old.nabble.com/Keeping-fo%3Atable-header-and-fo%3Atable-body-together-within-a-page-tp29094189p29094189.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Mime
View raw message