← Prev in month ← Prev in thread
Next in thread → Next in month →

Re: [docbook-apps] toc where every chapter/section starts exactly at the same vertical position

From
Bob Stayton <>
Date
2006-06-29T19:26:08+00:00
ID
044901c69bb1$e0a934e0$6700a8c0@totoro
Thread
Re: [docbook-apps] toc where every chapter/section starts exactly at the same vertical position
Hi Stefan,
You could customize the template named 'toc.line' in fo/autotoc.xsl to use 
a fo:list-block with one list-item to format the two pieces.  Something 
like this:

<fo:list-block provisional-distance-between-starts="0.5in">
  <fo:list-item>
    <fo:list-item-label end-indent="label-end()">
      <fo:block>
        <xsl:copy-of select="$label"/>
      </fo:block>
    </fo:list-item-label>
    <fo:list-item-body start-indent="body-start()">
      <!-- the fo:block that formats the title with the leader and page 
reference -->
    </fo:list-item-body>
  </fo:list-item>
</fo:list-block>

It is the provisional-distance-between-starts that provides the consistent 
spacing, sort of like a two-column table.

Bob Stayton
Sagehill Enterprises
DocBook Consulting



----- Original Message ----- 
From: "Stefan Zander" <>
To: <>
Sent: Thursday, June 29, 2006 8:07 AM
Subject: [docbook-apps] toc where every chapter/section starts exactly at 
the same vertical position


> Hello everybody,
>
> sorry for the imprecise subject matter.
> Does anybody know how to generate a toc in a pdf-file with docbook 4.4, 
> which looks as follows:
>
> 1         Chapter 1
> 1.1      Chapter 1.1
> 1.2      Chapter 1.2
> 1.2.1   Chapter 1.2.1
> etc.
>
> What docbook does is something like this:
> 1 Chapter 1
> 1.1 Chapter 1.1
> 1.1.1 Chapter 1.1.1
> etc.
>
> Any ideas how to realize this?
> I am working with docbook 4.4, fop0.92beta, Java 1.5, docbook-xsl 1.70.1
>
> I tried to customize the autotox.xsl-stylesheet and use tables, but it 
> seems that this doesn't work.
>
> Thanks for any help.
>
> Stefan
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: 
> For additional commands, e-mail: 
>
>
>
← Prev in month ← Prev in thread
Next in thread → Next in month →