This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [docbook-apps] force pagebreaks in a glossary


On Sat, 7 May 2005, Tom Peters wrote:

> Thanx for your explanation.  It remains problematic however.
> Setting "--stringparam  glossary.as.blocks 1", I first do a pre-processing
> with xsltproc and an xsl file to automatically add <indexterm> stanzas
> after each <glossterm>.  However, in the process the <?pagebreak?>s get
> removed from the output .xml, so they are no longer present to be
> processed in the next xsltproc that generates the .fo file.

O, hold on, apparently that depends on where I put the <?pagebreak?>.  I
do get an intermediate xml file now that still has them.  I can process
that with "--stringparam  glossary.as.blocks 1" which does appear to
obey pagebreaks.  As you wrote, that gives a different formatting as well.
I hope I don't sound too niggling when I prefer the original lay-out.  So
I'd like to make your alternative (with "--stringparam glossary.as.blocks
0") work.  However the code snippet in my xsl file is not understood by
xsltproc:

$ ./doitglos
compilation error: file printglos.xsl line 28 element choose
xsltParseStylesheetTop: unknown choose element

I've been experimenting with where to put it in the printglos.xsl file,
with varying results, but none proper.  I do not get the intended
<fo:list-item break-before="page"> stanzas in my output .fo file.


> This is my call:
>
> xsltproc -o Glos.tmp --stringparam glossary.as.blocks 0
> add-indexterms-glos.xsl Glos.xml
>
> This is the relevant piece of code (which you provided before and which
> I put at the end of the xsl file):
>
> <xsl:choose>
>   <xsl:when test="parent::glossary and $glossary.as.blocks = 0">
>       <fo:list-item break-before="page">
>             <fo:list-item-label><fo:block/></fo:list-item-label>
>             <fo:list-item-body><fo:block/></fo:list-item-body>
>       </fo:list-item>
>   </xsl:when>
>   <xsl:otherwise>
>     <fo:block break-before="page"/>
>   </xsl:otherwise>
> </xsl:choose>

--
#>!$!%(@^%#%*(&(#@#*$^@^$##*#@&(%)@**$!(&!^(#((#&%!)%*@)(&$($$%(@#)&*!^$)^@*^@)

	Tom Peters



---------------------------------------------------------------------
To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]