Bob Stayton wrote:
Oh, right, the page numbering starts
over because the context node is article when the page.sequence
template is called by name. Instead, that template can be called using
appy-templates in a mode:
(use d:index if you are using the
That sets the context node to be the
index element, so now the page-sequence is handled as an index, and the
page numbering does not restart.
I tried but I don't know how to distinguish between the first page of
the Index page and the first page of the document. What I would like is
to have header and footer on every pages except the first one (Page 1
of document). I saw in pagesetup.xsl that sequence can be odd, even,
first, blank but first applies to each page-sequence.
The headers and footers aren't
entirely empty. The page number appears in the footer, as you noted.
Also, the "Index" title will appear in the header starting on the
second page of the index page sequence. The default in DocBook is no
header on the first page of a page-sequence. If you want something
else, a bit of customizing of the header.content template will make it
do what you want.
Also, the title in the Index is centered on the first column. Is it
possible to adjust the title to the left without adjusting all other
Regarding a parameter for index
column count, that actually already exists as the column.count.index
But it only applies when an index
has its own page-sequence using the index page-master, not when an
index is handled inside the article's body page-sequence. I think what
you want is a parameter to set an article index in its own
page-sequence so the other parameter can apply.
Thanks. I should have think about it :-(
fo/component.xsl, that generally is not a good practice, as you found
when you updated. Rather, create a customization layer that imports
the stock DocBook stylesheet, and add any customized templates there to
override the stock templates. Then you don't lose your customizations
when you update. See:
Absolutely. Thanks again for a great support.
Hope this helps.
Original Message -----
Thursday, April 17, 2008 2:31 PM
Re: Re: [docbook-apps] Columns in index of article, with docbook-xsl-ns
I had the same problem as Rasmus and up to now I was using another
suggestion Bob gave me on November 1, 2006 (Subject: generating an
index with 2 columns) which also consisted of a modification of the
fo/component.xsl plus the setting of the column.count.body stylesheet
parameter to 2. This was doing the job but with some inconvenience:
Therefore, I was very interested with the new proposed solution. I
tried it and found the following problems:
- the header contained the title of the last section instead of
- more important, twice I updated the stylesheets and I forgot
to re-apply the modification to fo/component.xsl and I ended with a
complete document in 2 columns :-(
Whenever it is possible I use book but, for some of my documents,
switching to a book is not really a solution because they contain
several sections that cannot be organized into chapters and section is
not a child of book.
- The numbering of the Index pages restarts at 1 (shown also as
page 1 in the Table of Contents)
- The header and footer of the Index pages are empty
Ideally, it would be possible to use a parameter to specify the number
of columns in the Index pages.
Bob Stayton wrote:
<div class="moz-text-flowed" style="font-family:
Multiple columns are specified in the page-master, so your index
content must be removed from the main article page-sequence that uses
the "body" page-master and put into a new page-sequence using the
"index" page-master. You would have to customize the template with
match="article" from fo/component.xsl.
Near the end of the template, change:
----- Original Message ----- From: "Rasmus Kaj" <email@example.com>
Sent: Wednesday, April 16, 2008 10:53 AM
Subject: [docbook-apps] Columns in index of article, with
I'm trying, without success, to get a multi-column index in a DocBook
After a lot of searching I found that the index page-master isn't used
for an article. If I switch to a book it works, but then I get loads
extra page breaks and empty pages that I don't want (and what I write
feels more like an article than a book).
I do have the index on a page for itself. Can I specify a page-master
from my titlepages specification? Or can I specify a number of column
in some way that don't require the use of a page-master?
I'm using DocBook 5.0, docbook-xsl-ns-1.73.2, and fop 0.94.
Rasmus Kaj <firstname.lastname@example.org>
To unsubscribe, e-mail: email@example.com
For additional commands, e-mail: firstname.lastname@example.org