[xep-support] Double Page Numbering Revisited

Ron Catterall ron at catterall.net
Thu Mar 30 15:31:07 PST 2006


I seem to remember that this problem was treated very recently on the 
docbook list - and a reasonable solution was found - 
docbook-apps at lists.oasis-open.org


>At 2006-03-30 13:05 -0600, Kevin Trainor wrote:
>>When I generate the slides for a course, I use <fo:page-number/> to 
>>number the slides consecutively.  Additonally, some of my slides 
>>make up a series that I would also like to label as [1 of 4], [2 of 
>>4], [3 of 4], etc.  So far, I have not figured out a good way to do 
>>this.  It seems to me that this would be a double page numbering 
>>scheme like the one that was discussed on this list about a month 
>>ago.
>
>Nope!  I don't see this as a double page numbering issue.
>
>>I recall that the best advice in that thread was to do post 
>>processing on the FO output file.
>
>Shouldn't have to.
>
>>Can anyone think of a way to do this with just a single pass of 
>>XSLT and XSL-FO?
>
>I'm assuming you are creating a page sequence for each <series> 
>element.  Put an empty block at the end of the flow for each series, 
>and use a unique value for each series to ensure no collisions 
>(perhaps use the generate-id() of the series element as the value).
>
>Then, in your static content use:
>
>  [<page-number/> of <page-number-citation ref-id="{generate-id(.)}"/>]
>
>You aren't "counting" the pages in the series, you are citing the 
>last page in the series.  So, if a series has 6 pages instead of 4, 
>you get "6" because you are citing the last page of the series.
>
>Note you will have to restart your page numbering with each 
>page-sequence, so use initial-page-number="1".
>
>Note also that if you do not want a blank page after a series that 
>has an odd number of pages, you will need 
>force-page-count="no-force" because the default of "auto" will imply 
>blank pages based on the page parity of the initial page number.
>
>I hope this helps.
>
>. . . . . . . . . . . . Ken
>
>
>--
>Registration open for XSLT/XSL-FO training: Wash.,DC 2006-06-12/16
>World-wide on-site corporate, govt. & user group XML/XSL training.
>G. Ken Holman                 mailto:gkholman at CraneSoftwrights.com
>Crane Softwrights Ltd.          http://www.CraneSoftwrights.com/f/
>Box 266, Kars, Ontario CANADA K0A-2E0    +1(613)489-0999 (F:-0995)
>Male Cancer Awareness Aug'05  http://www.CraneSoftwrights.com/f/bc
>Legal business disclaimers:  http://www.CraneSoftwrights.com/legal
>
>-------------------
>(*) To unsubscribe, send a message with words 'unsubscribe xep-support'
>in the body of the message to majordomo at renderx.com from the address
>you are subscribed from.
>(*) By using the Service, you expressly agree to these Terms of 
>Service http://www.renderx.com/terms-of-service.html


-- 
Ron Catterall, Phd, DSc				email: ron at catterall.net
Prolongacion de Hidalgo 140				http://catterall.net/
San Felipe del Agua					tel: +52 951 520 1821
Oaxaca      68020	Mexico				fax: +1 530 348 8309
-------------------
(*) To unsubscribe, send a message with words 'unsubscribe xep-support'
in the body of the message to majordomo at renderx.com from the address
you are subscribed from.
(*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/terms-of-service.html



More information about the Xep-support mailing list