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] A big mystery


Hi Jacques,
I didn't understand this part of your mail:

> My titlepage.xsl content that :

>         <fo:table border-width="0.1pt" border-style="solid">
>         <fo:table-body>
>        ...

That isn't a complete template, and it isn't clear how titlepage.xsl is
used.
In which context is this table being created?

I tried putting your table in a template named 'book.titlepage.recto', and
the table rendered with XEP with all elements centered within the table.
The table did not reach the full width of the page, though, because by
default
XEP uses table-layout="auto", so the table width was only as wide as your
widest text.  Adding width="100%" to the fo:table centered everything nicely
on the page.


Bob Stayton
Sagehill Enterprises
DocBook Consulting
bobs@sagehill.net


----- Original Message ----- 
From: "Jacques Foucry" <jacques@foucry.net>
To: "docbook-apps" <docbook-apps@lists.oasis-open.org>
Sent: Saturday, October 15, 2005 4:15 AM
Subject: [docbook-apps] A big mystery


Hello list,

I trying to have a custom titlepage.

My xml file content that :

<bookinfo>
         <title>My Book title</title>
         <subtitle>My Book subtitle</subtitle>
         <author>
             <firstname>Jacques</firstname>
             <surname>Foucry</surname>
         </author>
         <revhistory>
             <revision>
                 <revnumber>1.2.0 French</revnumber>
                 <date><?dbtimestamp format="Y-m-d H:M:S"?></date>
             </revision>
         </revhistory>
</bookinfo>

My titlepage.xsl content that :

         <fo:table border-width="0.1pt" border-style="solid">
         <fo:table-body>
           <fo:table-row>
             <fo:table-cell>
               <fo:block text-align="center">
                 <fo:external-graphic src="url('images/Couv/
MyLogo.jpg')" width="9.38cm" height="5.5cm"/>
                 </fo:block>
                 </fo:table-cell>
                 </fo:table-row>
                 <fo:table-row>
                   <fo:table-cell>
                     <fo:block text-align="center">
                 <xsl:apply-templates select="bookinfo/title"/>
                 <xsl:apply-templates select="bookinfo/subtitle"/>
                 <xsl:apply-templates select="bookinfo/revhistory/
revision/revnumber"/>
                     </fo:block>
             </fo:table-cell>
           </fo:table-row>
         </fo:table-body>
       </fo:table>

And my custom.xsl content that :

<xsl:template match="bookinfo/title">
     <fo:block xmlns:fo="http://www.w3.org/1999/XSL/Format";
     xsl:use-attribute-sets="book.titlepage.recto.style"
     text-align="center" space-before="15.552pt"
     font-family="{$title.fontset}" font-weight="bold" font-size="64pt"
     color="#999999">
     <xsl:apply-templates select="." mode="book.titlepage.recto.mode"/>
     </fo:block>
</xsl:template>
<xsl:template match="bookinfo/subtitle">
     <fo:block xmlns:fo="http://www.w3.org/1999/XSL/Format";
       xsl:use-attribute-sets="book.titlepage.recto.style"
       text-align="center" space-before="15.552pt"
       font-family="{$title.fontset}" font-weight="bold" font-
size="24pt"
       color="#000000">
       <xsl:apply-templates select="."
mode="book.titlepage.recto.mode"/>
     </fo:block>
   </xsl:template>
   <xsl:template match="bookinfo/revhistory/revision/revnumber">
       <fo:block xmlns:fo="http://www.w3.org/1999/XSL/Format";
           xsl:use-attribute-sets="book.titlepage.recto.style"
           text-align="center" space-before="15.552pt"
           font-family="{$title.fontset}" font-weight="bold" font-
size="14pt"
           color="#000000">
           <xsl:apply-templates select="."
mode="book.titlepage.recto.mode"/>
       </fo:block>
   </xsl:template>

And the result is strange.

The picture (myLogo) is centered ;
the title (My Book title) is left align ;
the subtitle (My Book subtitle) is centered ;
the revision number is centered.

And I can explain why, with the same code in custom.xsl the title is
not centered.

This part of code use to work. I think the change was using docbook-
xsl 1.69.1 instead of docbook-xsl 1.68.1.

I use XEP to make the transformation.

May I've looked to much to this part to see the mistake. If one of
you can see it, It will be great.

Thanks in advance,
Jacques
-- 
BOY SCOUT : un enfant habillé comme un couillon, commandé par un
couillon habillé comme un enfant.
                P. Desproges




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






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