gforge-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gforge-commits] gforge/docs/docbook/xsl article_pdf.xsl, NONE, 1.1 book


From: gsmet
Subject: [Gforge-commits] gforge/docs/docbook/xsl article_pdf.xsl, NONE, 1.1 book_pdf.xsl, NONE, 1.1 article_html.xsl, NONE, 1.1 article_html_chunk.xsl, NONE, 1.1 book_html_chunk.xsl, NONE, 1.1 book_html.xsl, NONE, 1.1
Date: Tue, 02 Mar 2004 10:58:42 -0600

Update of /cvsroot/gforge/gforge/docs/docbook/xsl
In directory db.perdue.net:/tmp/cvs-serv22607/docs/docbook/xsl

Added Files:
        article_pdf.xsl book_pdf.xsl article_html.xsl 
        article_html_chunk.xsl book_html_chunk.xsl book_html.xsl 
Log Message:
converted doc from Maven xdoc to XML Docbook

--- NEW FILE: article_pdf.xsl ---
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version="1.0">

        <xsl:import href="include/common_pdf.xsl" />
        <xsl:variable name="toc.section.depth">2</xsl:variable>
        <xsl:variable 
name="admon.graphics.path">../../xsl/db2latex/xsl/figures</xsl:variable>
        <xsl:variable 
name="latex.documentclass.article">a4paper,10pt,oneside</xsl:variable> 

        <xsl:template match="article">
                <xsl:call-template name="generate.latex.article.preamble"/>
                <xsl:text>&#10;\setcounter{tocdepth}{</xsl:text><xsl:value-of 
select="$toc.section.depth"/><xsl:text>}&#10;</xsl:text>
                
<xsl:text>&#10;\setcounter{secnumdepth}{</xsl:text><xsl:value-of 
select="$section.depth"/><xsl:text>}&#10;</xsl:text>
                <!-- Get and output article title -->
                <xsl:variable name="article.title">
                        <xsl:choose>
                                <xsl:when test="./title"> 
                                        <xsl:apply-templates select="./title"/>
                                </xsl:when>
                                <xsl:when test="./articleinfo/title">
                                        <xsl:apply-templates 
select="./articleinfo/title"/>
                                </xsl:when>
                                <xsl:otherwise>
                                        <xsl:apply-templates 
select="./artheader/title"/>
                                </xsl:otherwise>
                        </xsl:choose>
                </xsl:variable>
                <xsl:text>\title{</xsl:text>
                <xsl:value-of select="$latex.article.title.style"/>
                <xsl:text>{</xsl:text>
                <xsl:value-of select="$article.title"/>
                <xsl:text>}}&#10;</xsl:text>
                <!-- Display date information -->
                <xsl:variable name="article.date">
                        <xsl:apply-templates 
select="./artheader/date|./articleinfo/date"/>
                </xsl:variable>
                <xsl:if test="$article.date!=''">
                        <xsl:text>\date{</xsl:text>
                        <xsl:value-of select="$article.date"/>
                        <xsl:text>}&#10;</xsl:text>
                </xsl:if>
                <!-- Display author information -->
                <xsl:text>\author{</xsl:text>
                <xsl:choose>
                        <xsl:when test="articleinfo/authorgroup">
                                <xsl:apply-templates 
select="articleinfo/authorgroup"/>
                        </xsl:when>
                        <xsl:when test="artheader/authorgroup">
                                <xsl:apply-templates 
select="artheader/authorgroup"/>
                        </xsl:when>
                        <xsl:when test="articleinfo/author">
                                <xsl:for-each select="artheader">
                                        <xsl:call-template name="authorgroup"/>
                                </xsl:for-each>
                        </xsl:when>
                        <xsl:when test="artheader/author">
                                <xsl:for-each select="artheader">
                                        <xsl:call-template name="authorgroup"/>
                                </xsl:for-each>
                        </xsl:when>
                        <xsl:otherwise>
                                <xsl:call-template name="authorgroup"/>
                        </xsl:otherwise>
                </xsl:choose>
                <xsl:text>}&#10;</xsl:text>
                <!-- Display  begindocument command -->
                <xsl:call-template name="map.begin"/>
                <xsl:value-of select="$latex.maketitle"/>
                <xsl:apply-templates select="artheader|articleinfo" 
mode="standalone.article"/>
                <xsl:call-template name="toc"/>
                <xsl:call-template name="content-templates-rootid"/>
                <xsl:call-template name="map.end"/>
        </xsl:template> 

</xsl:stylesheet>

--- NEW FILE: book_pdf.xsl ---
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version="1.0">

        <xsl:import href="include/common_pdf.xsl" />
        <xsl:variable name="toc.section.depth">1</xsl:variable>
        <xsl:variable 
name="admon.graphics.path">../../xsl/db2latex/xsl/figures</xsl:variable>
        <xsl:variable 
name="latex.documentclass.book">a4paper,10pt,oneside</xsl:variable>

        <xsl:template match="book">
                <!-- book:1: generate.latex.book.preamble -->
                <xsl:call-template name="generate.latex.book.preamble"/>
                <!-- book:2: output title information     -->
                <xsl:text>\title{</xsl:text>
                        <xsl:apply-templates select="title|bookinfo/title"/>
                        <xsl:apply-templates 
select="subtitle|bookinfo/subtitle"/>
                <xsl:text>}&#10;</xsl:text>
                <!-- book:3: output author information     -->
                <xsl:text>\author{</xsl:text>
                <xsl:choose>
                        <xsl:when test="bookinfo/authorgroup">
                                <xsl:apply-templates 
select="bookinfo/authorgroup"/>
                        </xsl:when>
                        <xsl:otherwise>
                                <xsl:for-each select="bookinfo">
                                        <xsl:call-template name="authorgroup"/>
                                </xsl:for-each>
                        </xsl:otherwise>
                </xsl:choose>
                <xsl:text>}&#10;</xsl:text>
                <!-- book:4: dump any preamble after author  -->
                <xsl:value-of select="$latex.book.afterauthor"/>
                <!-- book:5: set some counters  -->
                <xsl:text>&#10;\setcounter{tocdepth}{</xsl:text><xsl:value-of 
select="$toc.section.depth"/><xsl:text>}&#10;</xsl:text>
                
<xsl:text>&#10;\setcounter{secnumdepth}{</xsl:text><xsl:value-of 
select="$section.depth"/><xsl:text>}&#10;</xsl:text>
                <!-- book:6: dump the begin document command  -->
                <xsl:value-of select="$latex.book.begindocument"/>
                <!-- book:7: include external Cover page if specified -->
                <xsl:if test="$latex.titlepage.file != ''">
                        
<xsl:text>&#10;\InputIfFileExists{</xsl:text><xsl:value-of 
select="$latex.titlepage.file"/>
                        <xsl:text>}{\typeout{WARNING: Using cover page 
</xsl:text>
                        <xsl:value-of select="$latex.titlepage.file"/>
                        <xsl:text>}}</xsl:text>
                </xsl:if>
                <!-- book:7b: maketitle and set up pagestyle -->
                <xsl:value-of select="$latex.maketitle"/>
                <!-- book:8: - APPLY TEMPLATES -->
                <xsl:apply-templates select="bookinfo"/>
                <xsl:call-template name="toc" />
                <xsl:call-template name="content-templates-rootid"/>
                <!-- book:9:  call map.end -->
                <xsl:call-template name="map.end"/>
        </xsl:template>

        <xsl:template match="book/article">
                <!-- Get and output article title -->
                <xsl:variable name="article.title">
                        <xsl:choose>
                                <xsl:when test="./title"> 
                                        <xsl:apply-templates select="./title"/>
                                </xsl:when>
                                <xsl:when test="./articleinfo/title">
                                        <xsl:apply-templates 
select="./articleinfo/title"/>
                                </xsl:when>
                                <xsl:otherwise>
                                        <xsl:apply-templates 
select="./artheader/title"/>
                                </xsl:otherwise>
                        </xsl:choose>
                </xsl:variable>
                <xsl:text>\chapter{</xsl:text><xsl:value-of 
select="$article.title"/><xsl:text>}&#10;</xsl:text>
                <!-- Display date information -->
                <xsl:variable name="article.date">
                        <xsl:apply-templates 
select="./artheader/date|./articleinfo/date"/>
                </xsl:variable>
                <xsl:if test="$article.date!=''">
                        <xsl:text>{</xsl:text>
                        <xsl:value-of select="$article.date"/>
                        <xsl:text>}\par&#10;</xsl:text>
                </xsl:if>
                <!-- Display author information -->
                <xsl:text>{</xsl:text>
                <xsl:value-of select="$latex.book.article.header.style"/>
                <xsl:text>{</xsl:text>
                <xsl:choose>
                        <xsl:when test="articleinfo/authorgroup">
                                <xsl:apply-templates 
select="articleinfo/authorgroup"/>
                        </xsl:when>
                        <xsl:when test="artheader/authorgroup">
                                <xsl:apply-templates 
select="artheader/authorgroup"/>
                        </xsl:when>
                        <xsl:when test="articleinfo/author">
                                <xsl:for-each select="artheader">
                                        <xsl:call-template name="authorgroup"/>
                                </xsl:for-each>
                        </xsl:when>
                        <xsl:when test="artheader/author">
                                <xsl:for-each select="artheader">
                                        <xsl:call-template name="authorgroup"/>
                                </xsl:for-each>
                        </xsl:when>
                        <xsl:otherwise>
                                <xsl:call-template name="authorgroup"/>
                        </xsl:otherwise>
                </xsl:choose>
                <xsl:text>}}\par&#10;</xsl:text>
                <xsl:apply-templates select="artheader|articleinfo" 
mode="article.within.book"/>
                <xsl:call-template name="content-templates"/>
        </xsl:template>

</xsl:stylesheet>

--- NEW FILE: article_html.xsl ---
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version='1.0'>

<xsl:import href="docbook/html/docbook.xsl" />

<xsl:param name="toc.section.depth">2</xsl:param>
<xsl:param name="autotoc.label.separator" select="'. '"/>
<xsl:param name="generate.index" select="1"/>
<xsl:param name="generate.toc">
article toc,figure
section toc,figure
</xsl:param>

<xsl:param name="section.autolabel" select="1"/>
<xsl:param name="generate.section.toc.level" select="1"/>

</xsl:stylesheet>

--- NEW FILE: article_html_chunk.xsl ---
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version='1.0'>

<xsl:import href="docbook/html/chunk.xsl" />
<xsl:param name="base.dir" />

<xsl:param name="toc.section.depth">2</xsl:param>
<xsl:param name="autotoc.label.separator" select="'. '"/>
<xsl:param name="generate.index" select="1"/>
<xsl:param name="generate.toc">
article toc,figure
section toc,figure
</xsl:param>

<xsl:param name="section.autolabel" select="1"/>

<xsl:param name="chunk.section.depth" select="2"/>
<xsl:param name="chunk.first.sections" select="1"/>

</xsl:stylesheet>

--- NEW FILE: book_html_chunk.xsl ---
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version='1.0'>

<xsl:import href="docbook/html/chunk.xsl" />

<!-- comes from xsltproc command line -->
<xsl:param name="base.dir" />

<xsl:param name="toc.section.depth">2</xsl:param>
<xsl:param name="autotoc.label.separator" select="'. '"/>
<xsl:param name="generate.index" select="1"/>
<xsl:param name="generate.toc">
book toc,figure
chapter toc,figure
article toc,figure
section toc,figure
</xsl:param>

<xsl:param name="section.autolabel" select="1"/>
<xsl:param name="generate.section.toc.level" select="2"/>

<xsl:param name="chunk.section.depth" select="1"/>

<xsl:param name="chunk.first.sections" select="1"/>

</xsl:stylesheet>

--- NEW FILE: book_html.xsl ---
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version='1.0'>

<xsl:import href="docbook/html/docbook.xsl" />

<xsl:param name="toc.section.depth">2</xsl:param>
<xsl:param name="autotoc.label.separator" select="'. '"/>
<xsl:param name="generate.index" select="1"/>
<xsl:param name="generate.toc">
book toc,figure
chapter toc,figure
article toc,figure
section toc,figure
</xsl:param>

<xsl:param name="section.autolabel" select="1"/>
<xsl:param name="generate.section.toc.level" select="2"/>

</xsl:stylesheet>





reply via email to

[Prev in Thread] Current Thread [Next in Thread]