W3C home > Mailing lists > Public > www-xsl-fo@w3.org > August 2003

Re: Markers

From: G. Ken Holman <gkholman@CraneSoftwrights.com>
Date: Sat, 23 Aug 2003 18:20:09 -0300
Message-Id: <>
To: <www-xsl-fo@w3.org>

At 2003-08-20 16:09 -0400, Cindy Hunt wrote:
>I am creating a running head and want it to display "Chapter ##" and the 
>text of the chapter title along with the page number. The page number is 
>working fine but the chapter number and title text are not pulling in. I 
>am using a marker for these

And your example looks just fine to me.

><xsl:template match="chapter">
><xsl:number count="chapter" level="any" from="body"/>

You don't describe your document model, but I'm guessing your chapter 
elements are siblings.  I suggest you replace the above with:


because level="any" will be *much* slower and should only be used for 
things like book-wide figures that are scattered throughout a 
document.  The default attributes will count like-named siblings, so you 
don't need to add any explicit attributes in your situation (if my 
assumption is correct).

>Anyone have ideas on what would keep this from working correctly? I am 
>using the FOP engine via XMLSpy if that helps.

I'm guessing an implementation problem, I can't see any reason why it 
wouldn't work.

I hope this helps.

............ Ken

Instructor-led on-site corporate, government & user group training
for XSLT and XSL-FO world-wide; please contact us for the details;
Next public European delivery:  3-day XSLT/2-day XSL-FO 2003-09-22

G. Ken Holman                 mailto:gkholman@CraneSoftwrights.com
Crane Softwrights Ltd.          http://www.CraneSoftwrights.com/f/
Box 266, Kars, Ontario CANADA K0A-2E0    +1(613)489-0999 (F:-0995)
ISBN 0-13-065196-6                       Definitive XSLT and XPath
ISBN 0-13-140374-5                               Definitive XSL-FO
ISBN 1-894049-08-X   Practical Transformation Using XSLT and XPath
ISBN 1-894049-11-X               Practical Formatting Using XSL-FO
Member of the XML Guild of Practitioners:     http://XMLGuild.info
Male Breast Cancer Awareness  http://www.CraneSoftwrights.com/f/bc
Received on Saturday, 23 August 2003 17:20:15 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:58:28 UTC