Hi Jacques,
The way XSL-FO works with space-before is that if a block appears first on a page, the space-before property is normally ignored. That is to make the text start in the same place on each page. You can overcome this for a particular block by adding a space-before.conditionality="retain" property to title as well.

The generated text comes from the gentext files, and can be customized as described here:

http://www.sagehill.net/docbookxsl/CustomGentext.html#CustomGenText

Regarding smallcaps, is the font-variant property making it into the FO file? If so, then the stylesheet is working and you should look at the XEP setup again.

Bob Stayton
Sagehill Enterprises
DocBook Consulting
[EMAIL PROTECTED]


----- Original Message ----- From: "Jacques Foucry" <[EMAIL PROTECTED]>
To: "docbook " <[email protected]>
Sent: Monday, March 05, 2007 7:57 AM
Subject: [docbook-apps] Strange behaviour in my custom titlepage


Hello list,

As I read in the Bob's book, I took a part of fo/titlepage.templates.xml
to make my own titlepage.

I would like have the title in the center/middle of the page with the
edition number just below.

...
<!ENTITY middlepage  "1175mm"> <!-- middle of the page -->
]>
<t:templates xmlns:t="http://nwalsh.com/docbook/xsl/template/1.0";
   xmlns:param="http://nwalsh.com/docbook/xsl/template/1.0/param";
   xmlns:fo="http://www.w3.org/1999/XSL/Format";
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>

<t:titlepage t:element="book" t:wrapper="fo:block">
   <t:titlepage-content t:side="recto">
       <title
           t:named-template="division.title"
           param:node="ancestor-or-self::book[1]"
           text-align="center"
           font-size="&hsize5;"
           space-before="&middlepage;"
           font-weight="bold"
           font-family="{$title.fontset}"/>
       <subtitle
           text-align="center"
           font-size="&hsize4;"
           space-before="&hsize4space;"
           font-family="{$title.fontset}"/>
       <corpauthor font-size="&hsize3;"
           keep-with-next.within-column="always"
           space-before="2in"/>
       <authorgroup space-before="2in"/>
       <author font-size="&hsize3;"
           space-before="&hsize2space;"
           keep-with-next.within-column="always"/>
<!-- adding th edition number -->
       <edition space-before="1in"
           font-size="&hsize0;"
           font-family="{$title.fontset}"/>
   </t:titlepage-content>
...

I generated the xsl file with the command line
xsltproc -output mytitlepages.xsl template/titlepage.xsl mytitlepage.spec.xml

<xsl:template match="d:title" mode="book.titlepage.recto.auto.mode">
<fo:block xmlns:fo="http://www.w3.org/1999/XSL/Format";
xsl:use-attribute-sets="book.titlepage.recto.style" text-align="center"
font-size="24.8832pt" space-before="1175mm" font-weight="bold"
font-family="{$title.fontset}">
<xsl:call-template name="division.title">
<xsl:with-param name="node" select="ancestor-or-self::d:book[1]"/>
</xsl:call-template>
</fo:block>
</xsl:template>

The result seems to be ok but I can't have "a big space" before the book
title. A little bit like the space-before param is not used.

The edition number is correct but the word "Edition" in french as a
capital letter (seconde Édition) which is not correct. Where can I fix
this ?

Another question : is it possible to use a font-variant in this template ?
I tried to use small-caps which is defined in my xep.xml file (I use XEP)
but it doesn't seems to work.

Thanks in advance,

best regards,
Jacques
--
« Mac OS X Server à votre Service » en vente au Monde en Tique.
<http://www.lmet.fr/fiche.cgi?_ISBN=9782952726603>
Attention, il ne reste que 19 exemplaires.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to