2 <xsl:stylesheet version="1.0"
3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
4 xmlns="http://www.w3.org/TR/xhtml1/strict">
6 <xsl:strip-space elements="doc chapter section"/>
7 <xsl:output method="text" indent="yes" encoding="iso-8859-1"/>
9 <xsl:template match="article">
10 \documentclass[a4paper]{article}
15 <xsl:apply-templates/>
19 <xsl:template match="book">
20 \documentclass[a4paper]{book}
25 <xsl:apply-templates/>
29 <xsl:template match="report">
30 \documentclass[a4paper]{report}
35 <xsl:apply-templates/>
39 <xsl:template match="titlepage">
41 <xsl:apply-templates/>
45 <xsl:template match="title">
47 \sffamily\bfseries\LARGE{<xsl:apply-templates/>}
51 <xsl:template match="subtitle">
53 \sffamily\bfseries\Large{<xsl:apply-templates/>}
57 <xsl:template match="author">
59 \sffamily{<xsl:apply-templates/>}
63 <xsl:template match="date">
65 \sffamily{<xsl:apply-templates/>}
69 <xsl:template match="docinfo">
70 \begin{tabular}{|l|l|}
72 \multicolumn{2}{|c|}{\textbf{Document Information}} \\
74 <xsl:apply-templates/>
78 <xsl:template match="infoitem">
79 <xsl:value-of select="@label"/> &
80 <xsl:apply-templates/> \\
84 <xsl:template match="abstract">
87 \begin{bfseries}Abstract:\end{bfseries}
90 <xsl:apply-templates/>
94 <xsl:template match="toc">
99 <xsl:template match="chapter/heading">
100 \chapter{<xsl:apply-templates/>}
103 <xsl:template match="section/heading">
104 \section{<xsl:apply-templates/>}
107 <xsl:template match="subsection/heading">
108 \subsection{<xsl:apply-templates/>}
111 <xsl:template match="subsubsection/heading">
112 \subsubsection{<xsl:apply-templates/>}
115 <xsl:template match="paragraph/heading">
116 \paragraph{<xsl:apply-templates/>}
119 <xsl:template match="subparagraph/heading">
120 \subparagraph{<xsl:apply-templates/>}
123 <xsl:template match="para">
125 <xsl:apply-templates/>
128 <xsl:template match="quote">
130 <xsl:apply-templates/>
134 <xsl:template match="verbatim">
136 <xsl:apply-templates/>
140 <xsl:template match="itemize">
142 <xsl:apply-templates/>
146 <xsl:template match="enumerate">
148 <xsl:apply-templates/>
152 <xsl:template match="item">
153 \item <xsl:apply-templates/>
156 <xsl:template match="footnote">\footnote{<xsl:apply-templates/>}</xsl:template>
158 <xsl:template match="emph">\begin{itshape}<xsl:apply-templates/>\end{itshape}</xsl:template>
160 <xsl:template match="strong">\begin{bfseries}<xsl:apply-templates/>\end{bfseries}</xsl:template>
162 <xsl:template match="code">\begin{ttfamily}<xsl:apply-templates/>\end{ttfamily}</xsl:template>
164 <xsl:template match="remark">\begin{slshape}<xsl:apply-templates/>\end{slshape}</xsl:template>
166 <xsl:template match="sub">$_{<xsl:apply-templates/>}$</xsl:template>
167 <xsl:template match="sup">$^{<xsl:apply-templates/>}$</xsl:template>
169 <xsl:template match="newline">\\</xsl:template>
170 <xsl:template match="newpage">\newpage</xsl:template>
172 <xsl:template match="table">
173 \begin{tabular}{<xsl:value-of select="@cpos"/>c}
174 <xsl:apply-templates/>
178 <xsl:template match="thead">
179 <xsl:apply-templates/>\\
182 <xsl:template match="thead/col">
183 \begin{bfseries}<xsl:apply-templates/>\end{bfseries}&
186 <xsl:template match="row">
187 <xsl:apply-templates/>\\
190 <xsl:template match="row/col">
191 <xsl:apply-templates/>&
194 <xsl:template match="picture">
195 \scalebox{<xsl:value-of select="@scale"/>}{\includegraphics{<xsl:value-of select="@eps"/>}}
198 <xsl:template match="label">\label{<xsl:value-of select="@name"/>}</xsl:template>
200 <xsl:template match="ref"><xsl:apply-templates/>\ref{<xsl:value-of select="@to"/>}</xsl:template>
201 <xsl:template match="page"><xsl:apply-templates/>\pageref{<xsl:value-of select="@to"/>}</xsl:template>
202 <xsl:template match="reference">
203 <xsl:apply-templates/>[<xsl:value-of select="@href"/>]
206 <xsl:template match="include">
207 <xsl:apply-templates select="document(@href)"/>
210 <xsl:template match="LaTeX">
211 <xsl:value-of select="@command"/>