[xsl] Cross-reference page number off by one

Subject: [xsl] Cross-reference page number off by one
From: "Craig Sampson" <Craig.Sampson@xxxxxxx>
Date: Tue, 21 Nov 2006 16:30:26 -0500

I am using fo:page-number-citation to supply the page number for cross
references within a single document. I am using Antenna House version 3.4 to
render the FO which I created with SAXON 6.5.3.

I have one instance where the target of the reference has been pushed off the
bottom of a page, when it was justified, resulting in it appearing at the top
of the following page. In this case the page number returned by
fo:page-number-citation is one less than the page number that the target
appears on. The actual link, in the PDF, does take you to the correct place
even though the page number in the reference is wrong.

Is there some trick that I am unaware of that corrects this problem, or have I
found a bug in the FO rendering engine?

Here's a snippet of the code that sets the id on the block:

		<fo:block id="{$targId}">

Here's a snippet of the code that references the id in order to obtain the
page number:

   		   <fo:basic-link internal-destination="{$myTargId}">
			 <xsl:value-of select="$linktxt"/><xsl:text> on page
</xsl:text><fo:page-number-citation ref-id="{$myTargId}"/>


Current Thread