Created Debian package
[xmldoc.git] / latex.xsl
index 3f171d4..0d884a0 100644 (file)
--- a/latex.xsl
+++ b/latex.xsl
@@ -1,5 +1,4 @@
 <?xml version="1.0"?>
-<!DOCTYPE xsl:stylesheet SYSTEM "xsl.dtd">
 <xsl:stylesheet version="1.0"
                 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                 xmlns="http://www.w3.org/TR/xhtml1/strict">
@@ -9,6 +8,7 @@
 
 <xsl:template match="article">
 \documentclass[a4paper]{article}
+\usepackage{xcolor}
 \usepackage{graphics}
 \usepackage{latexsym}
 \usepackage{marvosym}
@@ -19,6 +19,7 @@
 
 <xsl:template match="book">
 \documentclass[a4paper]{book}
+\usepackage{xcolor}
 \usepackage{graphics}
 \usepackage{latexsym}
 \usepackage{marvosym}
@@ -29,6 +30,7 @@
 
 <xsl:template match="report">
 \documentclass[a4paper]{report}
+\usepackage{xcolor}
 \usepackage{graphics}
 \usepackage{latexsym}
 \usepackage{marvosym}
 \end{verbatim}
 </xsl:template>
 
+<xsl:template match="example">
+\begin{verbatim} 
+ <xsl:apply-templates/>
+\end{verbatim}
+</xsl:template>
+
 <xsl:template match="itemize">
 \begin{itemize}
    <xsl:apply-templates/>
 \end{enumerate}
 </xsl:template>
 
-<xsl:template match="item">
+<xsl:template match="description">
+\begin{description}
+   <xsl:apply-templates/>
+\end{description}
+</xsl:template>
+
+<xsl:template match="itemize/item">
 \item <xsl:apply-templates/>
 </xsl:template>
 
+<xsl:template match="enumerate/item">
+\item <xsl:apply-templates/>
+</xsl:template>
+
+<xsl:template match="description/item">
+\item[<xsl:value-of select='@tag'/>] <xsl:apply-templates/>
+</xsl:template>
+
 <xsl:template match="footnote">\footnote{<xsl:apply-templates/>}</xsl:template>
 
 <xsl:template match="emph">\begin{itshape}<xsl:apply-templates/>\end{itshape}</xsl:template>
 <xsl:template match="sub">$_{<xsl:apply-templates/>}$</xsl:template>
 <xsl:template match="sup">$^{<xsl:apply-templates/>}$</xsl:template>
 
+<xsl:template match="color">\textcolor{<xsl:value-of select="@colorname"/>}{<xsl:apply-templates/>}</xsl:template>
+
+<xsl:template match="big">\large{<xsl:apply-templates/>}</xsl:template>
+<xsl:template match="small">\small{<xsl:apply-templates/>}</xsl:template>
+
+<xsl:template match="newline">\\</xsl:template>
+<xsl:template match="newpage">\newpage</xsl:template>
+
 <xsl:template match="table">
 \begin{tabular}{<xsl:value-of select="@cpos"/>c}
 <xsl:apply-templates/>
 
 <xsl:template match="label">\label{<xsl:value-of select="@name"/>}</xsl:template>
 
+<xsl:template match="index"></xsl:template>
 <xsl:template match="ref"><xsl:apply-templates/>\ref{<xsl:value-of select="@to"/>}</xsl:template>
 <xsl:template match="page"><xsl:apply-templates/>\pageref{<xsl:value-of select="@to"/>}</xsl:template>
 <xsl:template match="reference">