1<?xml version='1.0'?>
2<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
3
4<!-- ************** HTML ************** -->
5<xsl:import href="http://www.boost.org/tools/boostbook/xsl/html.xsl"/>
6
7<!-- remove "Chapter 1" from first page -->
8<xsl:param name="chapter.autolabel" select="0"/>
9<!-- leave the html files in the directory ../html -->
10<xsl:param name="base.dir" select="'../html/'"/>
11
12<!-- ******* Table of Contents ******** -->
13<!-- How far down sections get TOC's -->
14<xsl:param name = "toc.section.depth" select="2" />
15
16<!-- Max depth in each TOC: -->
17<xsl:param name = "toc.max.depth" select="2" />
18
19<!-- How far down we go with TOC's -->
20<xsl:param name="generate.section.toc.level" select="2" />
21
22<!-- ************ Chunking ************ -->
23
24<!--
25BoostBook takes a section node id like safe_numeric.safe_cast
26and renders it as safe_numeric/safe_cast. Presumably they do this
27so they can make a huge "book" with all the libraries in subdirectories.
28But we want something different.  To my mind, this should have been
29done using the library "directory" attribute.  But of course that
30doesn't matter now.  We'll just re-hack the path to eliminate
31the "safe_numeric/" from the above example.
32-->
33
34<xsl:template match="*" mode="recursive-chunk-filename">
35    <xsl:variable name="their">
36        <xsl:apply-imports mode="recursive-chunk-filename" select="."/>
37    </xsl:variable>
38    <xsl:choose>
39    <xsl:when test="contains($their, '/')">
40        <xsl:value-of select="substring-after($their, '/')" />
41    </xsl:when>
42    <xsl:otherwise>
43        <xsl:value-of select="$their"/>
44    </xsl:otherwise>
45    </xsl:choose>
46</xsl:template>
47
48<!-- don't make first sections special - leave TOC in different file -->
49<xsl:param name="chunk.first.sections" select="3" />
50
51<!-- How far down we chunk nested sections -->
52<!--
53Note: each chunk have to start with  a section with an id
54Otherwise the chunk (i.e. file) will be lost.  There is no
55checking of this
56-->
57<xsl:param name="chunk.section.depth" select="2" />
58
59</xsl:stylesheet>
60