You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by JOSE L MARTINEZ-AVIAL <jl...@gmail.com> on 2012/02/13 05:49:43 UTC
Special footer on the last-but-one page of the document, regardless
of page-sequence
Hi,
I'm using FOP 1.0 to create a document. The document is variable; there
is a list of sections which may or may not be present on the document,
depending on the document. In order to do that I'm using a page-sequence
for each section, and the XSLT transformation takes care of adding or not
the section. All the sections use the same master-reference, except the
last one (which is always present). So at the end I got the following
<fo:root>
<!-- Definiton of layouts -->
<fo:page-sequence master-reference="Letter">
...
</fo:page-sequence>
<fo:page-sequence master-reference="Letter">
...
</fo:page-sequence>
<fo:page-sequence master-reference="Letter">
...
</fo:page-sequence>
<fo:page-sequence master-reference="Letter">
...
</fo:page-sequence>
<fo:page-sequence master-reference="Letter-two-colummns">
...
</fo:page-sequence>
</fo:root>
I also need that structure because each section has a different footer(
They are all the same, the only difference is a text saying the name of the
section). It works fine. The issue I have is that I need to add a barcode
on the footer of the last-but-one odd page of the document.And that page
could be on the last sequence, or in the previous one, there is no way to
tell, since it depends where the last page-sequence starts, and how long it
is.
I've tried defining a page-sequence-master with
conditional-page-master-reference, but the conditions apply to each
sequence, not to the whole document, so I got the barcode at the end of
each section, which does not work for me. Is there anyway to do this?
Thanks.
Jose
Re: Special footer on the last-but-one page of the document, regardless
of page-sequence
Posted by Pascal Sancho <pa...@takoma.fr>.
Hi Jose,
Whate about something like that:
<fo:page-sequence-master master-name="mySeqMaster">
<fo:repeatable-page-master-alternatives>
<fo:conditional-page-master-reference
master-reference="lastMaster" page-position="last"/>
<fo:conditional-page-master-reference
master-reference="oddMaster" odd-or-even="odd"/>
<fo:conditional-page-master-reference
master-reference="otherMaster"/>
</fo:repeatable-page-master-alternatives>
</fo:page-sequence-master>
Each simple-page-master having a different static content.
Note: the order of fo:conditional-page-master-reference gives respective
priorities.
Le 13/02/2012 05:49, JOSE L MARTINEZ-AVIAL a écrit :
> Hi,
> I'm using FOP 1.0 to create a document. The document is variable;
> there is a list of sections which may or may not be present on the
> document, depending on the document. In order to do that I'm using a
> page-sequence for each section, and the XSLT transformation takes care
> of adding or not the section. All the sections use the same
> master-reference, except the last one (which is always present). So at
> the end I got the following
>
> <fo:root>
> <!-- Definiton of layouts -->
> <fo:page-sequence master-reference="Letter">
> ...
> </fo:page-sequence>
> <fo:page-sequence master-reference="Letter">
> ...
> </fo:page-sequence>
> <fo:page-sequence master-reference="Letter">
> ...
> </fo:page-sequence>
> <fo:page-sequence master-reference="Letter">
> ...
> </fo:page-sequence>
> <fo:page-sequence master-reference="Letter-two-colummns">
> ...
> </fo:page-sequence>
> </fo:root>
>
> I also need that structure because each section has a different footer(
> They are all the same, the only difference is a text saying the name of
> the section). It works fine. The issue I have is that I need to add a
> barcode on the footer of the last-but-one odd page of the document.And
> that page could be on the last sequence, or in the previous one, there
> is no way to tell, since it depends where the last page-sequence starts,
> and how long it is.
>
> I've tried defining a page-sequence-master with
> conditional-page-master-reference, but the conditions apply to each
> sequence, not to the whole document, so I got the barcode at the end of
> each section, which does not work for me. Is there anyway to do this?
>
> Thanks.
>
> Jose
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org