Re: [docbook-apps] profile chunking

From
Jirka Kosek <>
Date
2005-08-14T19:00:09+00:00
ID
Thread
Re: [docbook-apps] profile chunking
Mauritz Jeanson wrote:

> To skip all sections that don't have an os attribute, create a profiling
> customization layer with an empty template:
> 
> <xsl:template match="section[not(@os)]">
> </xsl:template> 

This can break things like numbering and ToC. The better way is to strip 
section during profiling before document processing:

<xsl:template match="section[not(@os)]" mode="profile"/>

However I think that Sarah wrongly designed placing of profiling 
attributes. Request for stripping unmarked (without condition attribute) 
elements very often means that there is something wrong. Consider:

<section os="Linux">
<title>LILO</title>
...
</section>

I think that <title> with LILO should be processed when generating 
documentation for Linux. But what is the difference from

<section>
<title>Notepad</title>
...
</section>

This section probably shouldn't go to Linux documentation. But why 
section and title elements should be processed in a different way? Once 
you will start use different profiling logic for different elements you 
will end with messed up documents after some time.

					Jirka

-- 
------------------------------------------------------------------
   Jirka Kosek     e-mail:      http://www.kosek.cz
------------------------------------------------------------------
   Profesionální školení a poradenství v oblasti technologií XML.
      Podívejte se na náš nově spuštěný web http://DocBook.cz
        Podrobný přehled školení http://xmlguru.cz/skoleni/
------------------------------------------------------------------