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 "Readman, Devon" <De...@moh.gov.on.ca> on 2004/02/10 17:05:14 UTC

Determine Pagebreaks?

Is there anyway in fop 0.20.5 to determine when a page break has occured?
For example, I need to be able to redisplay a document section heading (e.g.
'Section 2 Continued...') when the section is spread over multiple pages.
Thanks.

Devon

Devon Readman
Programmer Analyst
Business Solutions Division
Human Services I&IT Cluster
(613) 548-6318

"I trade it all for a little more." C. Montgomery Burns


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


RE: Determine Pagebreaks?

Posted by George Yi <gy...@srds.com>.
Use break-fore or break-after attr in your block.

George

-----Original Message-----
From: Readman, Devon [mailto:Devon.Readman@moh.gov.on.ca] 
Sent: Tuesday, February 10, 2004 10:05 AM
To: fop-user@xml.apache.org
Subject: Determine Pagebreaks?

Is there anyway in fop 0.20.5 to determine when a page break has
occured?
For example, I need to be able to redisplay a document section heading
(e.g.
'Section 2 Continued...') when the section is spread over multiple
pages.
Thanks.

Devon

Devon Readman
Programmer Analyst
Business Solutions Division
Human Services I&IT Cluster
(613) 548-6318

"I trade it all for a little more." C. Montgomery Burns


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




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


Re: Determine Pagebreaks?

Posted by Chris Pratt <ch...@planetpratt.com>.
Doh!  You know that one has gotten me about three times since I started
using this.
  (*Chris*)

----- Original Message ----- 
From: "J.Pietschmann" <j3...@yahoo.de>
To: <fo...@xml.apache.org>
Sent: Tuesday, February 10, 2004 11:56 am
Subject: Re: Determine Pagebreaks?


> Chris Pratt wrote:
> > I'm not sure that this will work (I'm making it up as I go) but couldn't
you
> > use the grouping trick with the page number to test when the page number
> > changes between elements?
>
> Transformation and FO layout are two different processing stages. There
> is no way (well, no standardized way) feed back information from the
> layout to the XSL transformation. This means, whatever you do in the
> transformation, you wont get page numbers. A <fo:page-number/> or
> <fo:page-number-reference/> will *not* evaluate to a page number during
> the transformation.
>
> J.Pietschmann
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
> For additional commands, e-mail: fop-user-help@xml.apache.org
>
>



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


Re: Determine Pagebreaks?

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Chris Pratt wrote:
> I'm not sure that this will work (I'm making it up as I go) but couldn't you
> use the grouping trick with the page number to test when the page number
> changes between elements?

Transformation and FO layout are two different processing stages. There
is no way (well, no standardized way) feed back information from the
layout to the XSL transformation. This means, whatever you do in the
transformation, you wont get page numbers. A <fo:page-number/> or
<fo:page-number-reference/> will *not* evaluate to a page number during
the transformation.

J.Pietschmann


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


Re: Determine Pagebreaks?

Posted by Chris Pratt <ch...@planetpratt.com>.
I'm not sure that this will work (I'm making it up as I go) but couldn't you
use the grouping trick with the page number to test when the page number
changes between elements?
  (*Chris*)

----- Original Message ----- 
From: "Andreas L. Delmelle" <a_...@pandora.be>
To: <fo...@xml.apache.org>
Sent: Tuesday, February 10, 2004 9:32 am
Subject: RE: Determine Pagebreaks?


> > -----Original Message-----
> > From: Readman, Devon [mailto:Devon.Readman@moh.gov.on.ca]
> >
> > Is there anyway in fop 0.20.5 to determine when a page break has
occured?
>
> Nope. (Well, not through XSL-FO anyway; you would need to directly talk to
> the AreaTree to achieve that...)
>
> > For example, I need to be able to redisplay a document section
> > heading (e.g.
> > 'Section 2 Continued...') when the section is spread over multiple
pages.
>
> You may want to take a closer look at fo:marker/fo:retrieve-marker to
> achieve a similar effect.
> ( see the sample files in FOP_HOME/examples/fo/markers to get the idea )
> If you it's no problem to alter the XML/XSL in such a way to add markers
to
> every section, it should be a piece of cake :)
>
> Hope this helps!
>
> Cheers,
>
> Andreas
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
> For additional commands, e-mail: fop-user-help@xml.apache.org
>
>



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


RE: Determine Pagebreaks?

Posted by "Andreas L. Delmelle" <a_...@pandora.be>.
> -----Original Message-----
> From: Readman, Devon [mailto:Devon.Readman@moh.gov.on.ca]
>
> Is there anyway in fop 0.20.5 to determine when a page break has occured?

Nope. (Well, not through XSL-FO anyway; you would need to directly talk to
the AreaTree to achieve that...)

> For example, I need to be able to redisplay a document section
> heading (e.g.
> 'Section 2 Continued...') when the section is spread over multiple pages.

You may want to take a closer look at fo:marker/fo:retrieve-marker to
achieve a similar effect.
( see the sample files in FOP_HOME/examples/fo/markers to get the idea )
If you it's no problem to alter the XML/XSL in such a way to add markers to
every section, it should be a piece of cake :)

Hope this helps!

Cheers,

Andreas


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