Thanks David,

I'm reluctant to go the XSLT route because our team REALLY values being 
able to see the xincluded information resolved in our authoring 
environment.
Thanks,
Kate
..........................................................................................................................................................................................................................
 



Kate Wringe | Tech Writer 2| Sybase
445 Wes Graham Way, Waterloo, ON, N2L 6R2 Canada | Tel: (519) 883-6838 | 
[email protected] | www.sybase.com 

 



"Cramer, David W (David)" <[email protected]> 
07/26/2010 04:06 PM

To
"'[email protected]'" <[email protected]>, "'DocBook Technical 
Committee'" <[email protected]>, 
"'[email protected]'" <[email protected]>
cc

Subject
RE: [docbook] Sections and topics






Hi Kate,
As an addition to the fine suggestions that have been provided, this comes 
to my mind:
 
You could keep doing what you're doing with the dummy wrapper sections but 
have an intermediary xslt step that promote the sections.  You would do 
this after resolving the xincludes but before passing the document to the 
DocBook xsls. 
 
The xslt would change this: 
 
<chapter role="dummy">
<title/>
<section id="someid"><title>Real title</title><!-- content --></section>
</chapter>
 
To:
 
<chapter id="someid"><title>Real title</title><!-- content --></chapter>
 
Since the chapter and section content models are so similar, you shouldn't 
have a problem and the result will be a normal looking toc in your output.
 
Something of a hack I guess, but it should work.
 
David
 

From: [email protected] [mailto:[email protected]] 
Sent: Monday, July 26, 2010 2:26 PM
To: DocBook Technical Committee; [email protected]
Subject: [docbook] Sections and topics


Hello, 

Here's the problem that I am increasingly running into: We have a 
<section> in one book that we want to reuse as a <chapter> in another book 
and vice versa. 

For example, in book A, there is section about using a tool with product A 
and in book B, we need to include the same information, but it must exist 
at the chapter level. 
Currently, in order to solve this problem, in Book A we create a <section> 
that contains the information and we xinclude this <section> into an 
essentially empty <chapter> element in Book B. As a result, our TOC 
becomes bloated and we end up with these funny chapter pages (in HTML 
Help) that only contain vague sentences followed by links to sections. 

It would be easier for us if the book structure allowed the <section> 
element to exist at the same level as the <chapter> element. 
So that, for example, the following would be valid: 
<book><title>titletext</title> 
        <section>text.... 
        </section> 
</book> 

I understand that the section element is supposed to contain information 
that is a section of something else and so the committee has been 
reluctant to see the <section> as a direct element of the <book> element. 
I had hoped that the <topic> element in modular DocBook would offer a 
better alternative. Unfortunately, from what I understand, you 
cannot have a topic embedded within a topic. So, even if we switched to 
using topics, we'd have the same problem as described above. 

Apologies if I am bringing up a subject that has already been addressed. 
Any suggestions as to how to solve this problem would be greatly 
appreciated. 

Thank you, 
Kate 


..........................................................................................................................................................................................................................
 



Kate Wringe | Tech Writer 2| Sybase
445 Wes Graham Way, Waterloo, ON, N2L 6R2 Canada | Tel: (519) 883-6838 | 
[email protected] | www.sybase.com 

 

Reply via email to