]> git.lyx.org Git - lyx.git/blob - src/tex2lyx/test/test-structure.tex
f698ca4d3347748d51561c60632ae61e97422254
[lyx.git] / src / tex2lyx / test / test-structure.tex
1 %% LyX trick_preamble_code_into_believing_that_this_was_created_by_lyx created this file.  For more info, see http://www.lyx.org/.
2 %% Do not edit unless you really know what you are doing.
3 \documentclass[legalpaper,french,german,english,dummyoption]{article}
4 \usepackage[latin9]{inputenc}
5 \usepackage{color}
6 \usepackage{rotfloat}
7 \usepackage{wrapfig}
8
9 \makeatletter
10
11 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
12 \pdfpageheight\paperheight
13 \pdfpagewidth\paperwidth
14
15 \providecommand{\LyX}{L\kern-.1667em\lower.25em\hbox{Y}\kern-.125emX\@}
16 \newcommand{\noun}[1]{\textsc{#1}}
17 %% Because html converters don't know tabularnewline
18 \providecommand{\tabularnewline}{\\}
19
20 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands.
21 \newenvironment{lyxlist}[1]
22 {\begin{list}{}
23 {\settowidth{\labelwidth}{#1}
24  \setlength{\leftmargin}{\labelwidth}
25  \addtolength{\leftmargin}{\labelsep}
26  \renewcommand{\makelabel}[1]{##1\hfil}}}
27 {\end{list}}
28
29 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
30 \newenvironment{foo}{==[}{]==}
31
32 \date{}
33
34 \@ifundefined{showcaptionsetup}{}{%
35  \PassOptionsToPackage{caption=false}{subfig}}
36 \usepackage{subfig}
37 \makeatother
38
39 \usepackage{babel}
40 \addto\extrasfrench{%
41    \providecommand{\og}{\leavevmode\flqq~}%
42    \providecommand{\fg}{\ifdim\lastskip>\z@\unskip\fi~\frqq}%
43 }
44
45 \begin{document}
46
47 \title{Title}
48
49 % this should be recognized as empty date:
50 \date{}
51
52 \maketitle
53 This document contains all sorts of layouts we are supposed to
54 support, along with weird nestings.
55
56 At time you will see that I use subsubsections in weird places. The
57 intent is just to make sure that I can include a macro-type layout
58 everyzhere it makes sense.
59
60 A normal paragraph
61 \begin{equation}
62 x = \sin y
63 \end{equation}
64 with maths inside it.
65
66 \begin{quote}
67 An environment...
68
69 ... with two paragraphs
70 \end{quote}
71
72 \begin{foo}
73 an unknown environment
74 \end{foo}
75
76
77 \section{A section}
78
79 \section[Hello!]{A section with optional argument}
80
81 \begin{quote}
82 An environment
83 \end{quote}
84
85 \section*{A starred section for floats}
86
87 \begin{figure}
88 \caption{ \emph{\noun{is}} a caption}
89 \end{figure}
90
91 \begin{figure}
92 \caption[s\noun{ho}rt]{this \emph{is} a caption}
93 \end{figure}
94
95 \begin{sidewaystable*}
96 \caption{rotated table, spanning all columns}
97
98 \centering{}%
99 \begin{tabular}{|c|c|}
100 \hline 
101 a  & b\tabularnewline
102 \hline 
103 \hline 
104 d  & c\tabularnewline
105 \hline 
106 \end{tabular}
107 \end{sidewaystable*}
108
109 \begin{wrapfigure}[4]{L}[2ex]{0.5\columnwidth}%
110 \begin{centering}
111 fdgsdfdh
112 \par\end{centering}
113
114 \caption{test1}
115 \end{wrapfigure}%
116 \LyX{} is a document preparation system. It excels at letting you
117 create complex technical and scientific articles with mathematics,
118 cross-references, bibliographies, indices, etc. It is very good at
119 documents of any length in which the usual processing abilities are
120 required: automatic sectioning and pagination, spell checking, and
121 so forth. It can also be used to write a letter to your mom, though
122 granted, there are probably simpler programs available for that. It
123 is definitely not the best tool for creating banners, flyers, or advertisements
124 (we'll explain why later), though with some effort all these can be
125 done, too.
126
127 \begin{wrapfigure}{o}{0.5\columnwidth}%
128 \begin{centering}
129 fdgs
130 \par\end{centering}
131
132 \caption{test2}
133 \end{wrapfigure}%
134 \LyX{} is a document preparation system. It excels at letting you
135 create complex technical and scientific articles with mathematics,
136 cross-references, bibliographies, indices, etc. It is very good at
137 documents of any length in which the usual processing abilities are
138 required: automatic sectioning and pagination, spell checking, and
139 so forth. It can also be used to write a letter to your mom, though
140 granted, there are probably simpler programs available for that. It
141 is definitely not the best tool for creating banners, flyers, or advertisements
142 (we'll explain why later), though with some effort all these can be
143 done, too.
144
145 \begin{wraptable}{i}[0.05\textwidth]{5ex}%
146 \caption{fdg}
147
148
149 \centering{}dfgd\end{wraptable}%
150 \LyX{} is a document preparation system. It excels at letting you
151 create complex technical and scientific articles with mathematics,
152 cross-references, bibliographies, indices, etc. It is very good at
153 documents of any length in which the usual processing abilities are
154 required: automatic sectioning and pagination, spell checking, and
155 so forth. It can also be used to write a letter to your mom, though
156 granted, there are probably simpler programs available for that. It
157 is definitely not the best tool for creating banners, flyers, or advertisements
158 (we'll explain why later), though with some effort all these can be
159 done, too.
160
161 \begin{table}
162 \caption{lkälöä}
163
164
165 \subfloat[ölkälö]{
166
167 klöä}
168
169 \end{table}
170
171
172 \begin{figure}
173 \subfloat[te\%st]{sub\textcolor{red}{fig}u\%re 1
174
175 }
176
177 \hfill{} \subfloat[]{subfigure 2ö
178
179 }
180
181 \subfloat{subfigure 3}
182
183 \caption{figure caption}
184
185
186 strange usage, but valid 
187 \end{figure}
188
189
190 \subsection{Some paragraph stuff}
191
192 A paragraph\footnote{hello} with a footnote and another
193 one\footnote{hello
194
195 there} with several paragraphs \vspace{1cm} aa
196
197 and another paragraph
198
199 \begin{center}
200 Some centered stuff
201 \end{center}
202
203 \begin{quotation}
204 An environment
205
206 \subsubsection*{with a command inside it}
207 \end{quotation}
208
209 \begin{quotation}
210 Another environment
211
212 \begin{quotation}
213 With another one inside it (with same layout)
214
215 [this one even has several paragraphs!]
216 \end{quotation}
217
218 \end{quotation}
219
220 We can also nest enumerations
221
222 \begin{enumerate}
223 \item Item1
224 \begin{enumerate}
225 \item Item1.a
226
227 \item Item1.b (there is  a paragraph break in front of this)
228 \begin{itemize}
229 \item Item1.b.*
230 \item Item1.b.*
231 \end{itemize}
232 \end{enumerate}
233 \item Item2
234 \end{enumerate}
235 \begin{enumerate}
236 \item Item1 (appears as Item3 with bug 5716)
237
238 Normal paragraph in Item1
239
240 \begin{enumerate}
241 \item Item1.a
242 \end{enumerate}
243 \end{enumerate}
244
245 Let's see what happens when normal paragraphs are inserted in lists:
246
247 \begin{itemize}
248 \item the first item
249
250 with some explanatory text under it
251
252 and a second paragraph for good measure
253
254 \subsubsection*{we can even have one as a subsubsection}
255
256 \item the second item
257
258 \item the third item
259
260 \subsubsection*{and a sssection heading inside it (why not?)}
261 \end{itemize}
262
263 What else? Well, we have descriptions:
264 \begin{description}
265 \item[ABC] first item
266 \item[BCD] second one
267 \end{description}
268 labelings:
269 \begin{lyxlist}{00.00.0000}
270 \item [label~1] first item
271 \item [label~2] second item
272 \end{lyxlist}
273 and bibliography:
274 \begin{thebibliography}{9}
275 \bibitem{FOO} Edward Bar. \emph{The Foo Book}. (1999)
276 \bibitem{FO2} Walter Müller \emph{The Müller Book}. (2004) 
277 \end{thebibliography}
278
279 \appendix
280
281 \section{This is the Appendix}
282
283 \noindent blabla bla bla
284
285 switch to german:\selectlanguage{german}
286 Hallo!
287 \foreignlanguage{french}{some \emph{french}}
288 back to english:\selectlanguage{newzealand}
289 and some nested \foreignlanguage{francais}{french \foreignlanguage{german}{nested
290 \emph{german}} french} english stuff.
291 Note that we both used \texttt{french} and the \texttt{francais} alias for the
292 french text, but for some reason this does not work with the
293 \texttt{newzealand} alias and \texttt{english} for english text.
294
295 \section{Another Appendix section}
296
297 blub
298
299 Test for missing \textbackslash end\_deeper (file format 278).
300 This must stay at the very end of the document!
301 \begin{itemize}
302 \item par1
303
304 par2
305 \begin{enumerate}
306 \item par1
307
308 par2
309 \end{enumerate}
310
311 \end{itemize}
312
313 \end{document}