This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: [docbook-apps] One TOC and one glossary for multiple docbook XML files
- From: Bob Stayton <bobs at sco dot com>
- To: Yan Bilik <yan dot bilik at wanadoomaps dot com>
- Cc: docbook-apps at lists dot oasis-open dot org
- Date: Thu, 10 Apr 2003 22:26:32 -0700
- Subject: Re: [docbook-apps] One TOC and one glossary for multiple docbook XML files
- References: <7E4AD7E16817AC4FA31346785D04C372314AB3@atlanta.snv.fr>
On Thu, Apr 10, 2003 at 02:57:30PM +0200, Yan Bilik wrote:
> Hello,
>
> Here is my problem. We are several people, and each of us is writing his
> own docbook document(s). These files are quite short, and they can have
> cross-references to each other. We decided to use olinks in order to
> keep flexibility when publishing the corresponding HTML files. We also
> use profiling to be able to show or hide some texts to the reader,
> depending on the userlevel we set.
> That works fine.
>
> The bad point is about TOC and glossary. I wish I know if we can create
> *one* TOC and *one* glossary only, for all our XML files... The aim
> would be to have a unique TOC file with links to the XML files (or HTML
> ones when published), and a unique glossary file, pointed to by the XML
> files using the glossterms (same way: pointed to by HTML files when
> published).
>
> Any idea ?
Since you are using olinks, you could use the olink targets
database to create a master table of contents. One could
write an XSL stylesheet that generates a DocBook <toc>
with <tocentry> elements from the database, following the DocBook DTD
for <toc>.
Each <tocentry> could contain an olink to its element, *if*
every title you want in the master toc has an id attribute
on its element. Otherwise you won't be able to use olink
to point to it.
Then you could process the generated toc document with the
same olink database as a formatted collection of
cross references.
I'm not sure about the hierarchy and presentation.
Since the <toc> element is designed for a book, I think you
would probably need several of them for multiple books.
Fortunately, a <book> containing nothing but several
<toc> elements is a valid document.
Or perhaps you could arrange things into <tocpart>
elements within one toc. Depends on your collection.
I started writing a stylesheet that could do this.
I'll post something when it is further along.
--
Bob Stayton 400 Encinal Street
Publications Architect Santa Cruz, CA 95060
Technical Publications voice: (831) 427-7796
The SCO Group fax: (831) 429-1887
email: bobs at sco dot com
---------------------------------------------------------------------
To unsubscribe, e-mail: docbook-apps-unsubscribe at lists dot oasis-open dot org
For additional commands, e-mail: docbook-apps-help at lists dot oasis-open dot org