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] v5. info element


Hi Bob.


Bob Stayton wrote:
> Hi Dave,
> Since you mention ns stripping, I presume you are processing a DB5 
> document with the non-namespaced stylesheets.  If so, then I can tell 
> you that in the stripping process the d:book/d:info element is 
> transformed into an info element, at least in the 1.74.0 stylesheets 
> (see common/stripns.xsl).  The stylesheets do handle info, even though 
> it is not a DB4 element, simply as a convenience in this manner:
> 
>  <xsl:choose>
>    <xsl:when test="bookinfo/title">
>      <xsl:apply-templates mode="book.titlepage.recto.auto.mode" 
> select="bookinfo/title"/>
>    </xsl:when>
>    <xsl:when test="info/title">
>      <xsl:apply-templates mode="book.titlepage.recto.auto.mode" 
> select="info/title"/>
>    </xsl:when>
>    <xsl:when test="title">
>      <xsl:apply-templates mode="book.titlepage.recto.auto.mode" 
> select="title"/>
>    </xsl:when>
>  </xsl:choose>
> 
> This construction enables the base stylesheets to be easily transformed 
> into the namespaced stylesheets by a mechanical process.

OK. That leaves me asking 'when' it happens?
I.e. should my customization be using d:info or just info as the match
element.


> 
> I think what you are seeing is that the template that matches on book 
> does not do a general apply-templates on the info element. 

Drat! You guessed! I had to match on book with high priority to get that :-)


  Instead, the
> titlepage.templates.xsl stylesheet module selectively applies templates 
> to some of the children of info, based on the specs in the 
> titlepage.templates.xml spec file. 

Which is the route I resorted to eventually!
(Except I don't like the revhistory presentation in pdf?
I wanted border='thin black solid' to make it look like a table with
the various component parts - but that is nit picking)


  So a template with
> match="/book/info" would never be reached, unless you customized the 
> match="book" template to apply it.  If the titlepage spec file includes 
> revhistory for book, then match="/book/info/revhistory" will be 
> applied.   By default, revhistory is not specified for book in the 
> titlepage spec file.


That's what I was missing, hence my customization efforts!

Not mentioned at
http://www.sagehill.net/docbookxsl/HTMLTitlePage.html#TitlePageElems ?


OK. Thanks Bob. I'll 'go figure'
I've never tried customizing titlepage.xsl!



regards

-- 
Dave Pawson
XSLT XSL-FO FAQ.
http://www.dpawson.co.uk


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