OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Re: [docbook-apps] Initial page numbering for book chapter?

Michèle Garoche wrote:
> Replying to myself, not sure though if there is not a better way to do 
> this.

I think maybe there is a slightly better (read: more general) way. I 
will leave it to the stylesheet authors to correct me if I am wrong :-)

I have experienced the exact same behavior, and found out that it 
happens when you have a preface in your book. If you don't have a 
preface, it works fine. The error is caused by what I think is a bug in 
the selection of first.book.content.

If you have a preface, then first.book.content will be a node set 
containing the preface. For the first chapter, this will invoke the 
default case of the <xsl:choose>, causing the first chapter to be 
numbered by the "auto-odd" rule and continue where the preface left off.

The comment describing first.book.content states that it should "Select 
the first content that the stylesheet places after the TOC". As I read 
the code, it really should "Select the first content that the stylesheet 

Thus, if you add "self::preface or" to the list of tests in the "not" 
part of the select attribute, everything works as expected, I believe.

To be concrete: Customize initial.page.number such that the definition 
of first.book.content looks like this (without the note, of course :-)):

<xsl:variable name="first.book.content"
                       not(self::title or
                           self::subtitle or
                           self::titleabbrev or
                           self::bookinfo or
                           self::info or
                           self::dedication or
                           self::toc or
                           self::preface or <-------- ADDED

I hope the above makes sense. If not, don't hesitate to let me know, and 
I will try to be clearer. English is not my native language :-D

Best regards,

	Rune Lausen

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]