2 <!DOCTYPE xsl:stylesheet SYSTEM "xsl.dtd">
3 <xsl:stylesheet version="1.0"
4 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 xmlns="http://www.w3.org/TR/xhtml1/strict">
7 <xsl:strip-space elements="doc chapter section"/>
8 <xsl:output method="text" indent="yes" encoding="iso-8859-1"/>
10 <xsl:template match="article">
11 \documentclass[a4paper]{article}
16 <xsl:apply-templates/>
20 <xsl:template match="book">
21 \documentclass[a4paper]{book}
26 <xsl:apply-templates/>
30 <xsl:template match="report">
31 \documentclass[a4paper]{report}
36 <xsl:apply-templates/>
40 <xsl:template match="titlepage">
42 <xsl:apply-templates/>
46 <xsl:template match="title">
48 \sffamily\bfseries\LARGE{<xsl:apply-templates/>}
52 <xsl:template match="subtitle">
54 \sffamily\bfseries\Large{<xsl:apply-templates/>}
58 <xsl:template match="author">
60 \sffamily{<xsl:apply-templates/>}
64 <xsl:template match="date">
66 \sffamily{<xsl:apply-templates/>}
70 <xsl:template match="docinfo">
71 \begin{tabular}{|l|l|}
73 \multicolumn{2}{|c|}{\textbf{Document Information}} \\
75 <xsl:apply-templates/>
79 <xsl:template match="infoitem">
80 <xsl:value-of select="@label"/> &
81 <xsl:apply-templates/> \\
85 <xsl:template match="abstract">
88 \begin{bfseries}Abstract:\end{bfseries}
91 <xsl:apply-templates/>
95 <xsl:template match="toc">
100 <xsl:template match="chapter/heading">
101 \chapter{<xsl:apply-templates/>}
104 <xsl:template match="section/heading">
105 \section{<xsl:apply-templates/>}
108 <xsl:template match="subsection/heading">
109 \subsection{<xsl:apply-templates/>}
112 <xsl:template match="subsubsection/heading">
113 \subsubsection{<xsl:apply-templates/>}
116 <xsl:template match="paragraph/heading">
117 \paragraph{<xsl:apply-templates/>}
120 <xsl:template match="subparagraph/heading">
121 \subparagraph{<xsl:apply-templates/>}
124 <xsl:template match="para">
126 <xsl:apply-templates/>
129 <xsl:template match="quote">
131 <xsl:apply-templates/>
135 <xsl:template match="verbatim">
137 <xsl:apply-templates/>
141 <xsl:template match="itemize">
143 <xsl:apply-templates/>
147 <xsl:template match="enumerate">
149 <xsl:apply-templates/>
153 <xsl:template match="item">
154 \item <xsl:apply-templates/>
157 <xsl:template match="footnote">\footnote{<xsl:apply-templates/>}</xsl:template>
159 <xsl:template match="emph">\begin{itshape}<xsl:apply-templates/>\end{itshape}</xsl:template>
161 <xsl:template match="strong">\begin{bfseries}<xsl:apply-templates/>\end{bfseries}</xsl:template>
163 <xsl:template match="code">\begin{ttfamily}<xsl:apply-templates/>\end{ttfamily}</xsl:template>
165 <xsl:template match="remark">\begin{slshape}<xsl:apply-templates/>\end{slshape}</xsl:template>
167 <xsl:template match="sub">$_{<xsl:apply-templates/>}$</xsl:template>
168 <xsl:template match="sup">$^{<xsl:apply-templates/>}$</xsl:template>
170 <xsl:template match="table">
171 \begin{tabular}{<xsl:value-of select="@cpos"/>c}
172 <xsl:apply-templates/>
176 <xsl:template match="thead">
177 <xsl:apply-templates/>\\
180 <xsl:template match="thead/col">
181 \begin{bfseries}<xsl:apply-templates/>\end{bfseries}&
184 <xsl:template match="row">
185 <xsl:apply-templates/>\\
188 <xsl:template match="row/col">
189 <xsl:apply-templates/>&
192 <xsl:template match="picture">
193 \scalebox{<xsl:value-of select="@scale"/>}{\includegraphics{<xsl:value-of select="@eps"/>}}
196 <xsl:template match="label">\label{<xsl:value-of select="@name"/>}</xsl:template>
198 <xsl:template match="ref"><xsl:apply-templates/>\ref{<xsl:value-of select="@to"/>}</xsl:template>
199 <xsl:template match="page"><xsl:apply-templates/>\pageref{<xsl:value-of select="@to"/>}</xsl:template>
200 <xsl:template match="reference">
201 <xsl:apply-templates/>[<xsl:value-of select="@href"/>]
204 <xsl:template match="include">
205 <xsl:apply-templates select="document(@href)"/>
208 <xsl:template match="LaTeX">
209 <xsl:value-of select="@command"/>