]> git.lyx.org Git - lyx.git/blob - src/tex2lyx/test/box-color-size-space-align.tex
Only the packages subscript and ulem if they are automatically loaded
[lyx.git] / src / tex2lyx / test / box-color-size-space-align.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[b4paper,twoside, twocolumn,12pt]{article}
4
5 \usepackage[T1]{fontenc}
6 \usepackage[latin9]{inputenc}
7
8 \usepackage{geometry}
9 \geometry{verbose,landscape,b4paper,tmargin=1cm,bmargin=2cm,lmargin=3cm,rmargin=4cm,headheight=6cm,headsep=5cm,footskip=7cm,columnsep=8cm}
10
11 \usepackage{amsmath}
12 \usepackage{color}
13 \definecolor{page_backgroundcolor}{rgb}{1, 0.3359375, 0}
14 \pagecolor{page_backgroundcolor}
15 \definecolor{document_fontcolor}{rgb}{0.66796875, 1, 0}
16 \color{document_fontcolor}
17 \definecolor{note_fontcolor}{rgb}{0, 0, 1}
18 \definecolor{shadecolor}{rgb}{1, 1, 0}
19 \usepackage{framed}
20 \usepackage{calc}
21 \usepackage{fancybox}
22 \PassOptionsToPackage{normalem}{ulem}
23 \usepackage{ulem}
24
25 \setlength{\parskip}{3mm}
26 \setlength{\parindent}{0sp}
27 \usepackage{setspace}
28 \setstretch{1.2}
29
30 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
31
32 %% The greyedout annotation environment
33 \newenvironment{lyxgreyedout}{\textcolor{note_fontcolor}\bgroup}{\egroup}
34
35 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
36
37 \setlength{\fboxsep}{3mm}
38
39 \definecolor{darkgreen}{cmyk}{0.5, 0, 1, 0.5}
40
41 \usepackage{ifpdf} % part of the hyperref bundle
42 \ifpdf % if pdflatex is used
43
44  % set fonts for nicer pdf view
45  \IfFileExists{lmodern.sty}{\usepackage{lmodern}}{}
46
47  % link all cross references and URLs in pdf output
48  \usepackage[colorlinks=true, bookmarks, bookmarksnumbered,
49   bookmarksopen, bookmarksopenlevel=2,
50   linkcolor=black, citecolor=black, urlcolor=blue, filecolor=blue,
51   pdfpagelayout=OneColumn, pdfnewwindow=true,
52   pdfstartview=XYZ, plainpages=false, pdfpagelabels,
53   pdfauthor={LyX Team}, pdftex,
54   pdftitle={tex2lyx testcase},pdfsubject={tex2lyx},
55   pdfkeywords={LyX, tex2lyx}]{hyperref}
56  
57 \else % if dvi or ps is produced
58
59  % link all cross references and URLs in dvi output
60  \usepackage[ps2pdf]{hyperref}
61
62 \fi % end if pdflatex is used
63
64
65 \begin{document}
66
67 \tableofcontents
68
69 \section{Boxes}
70
71 \subsection{Frameless Boxes}
72
73 blabla \mbox{mbox} blabla
74
75 blabla \makebox{makebox 1} blabla
76
77 blabla \makebox[3cm]{makebox 2} blabla
78
79 blabla \makebox[3cm][l]{makebox 3} blabla
80
81 \begin{figure}[ht]
82   \centering
83   \setlength{\unitlength}{.2in}
84
85 \begin{picture}(8,6)
86 \put(0,0){\makebox(0,0)[tr]{AAA}}
87 \put(8,0){\makebox(0,0){BBB}}
88 \put(1,0){\line(1,0){6}}   
89 \end{picture}
90
91 \end{figure}
92
93 \raisebox {8.5mm}{test}\raisebox {-6.5mm}{tset}
94
95 \subsection{Framed Boxes}
96
97 blabla \begin{framed}framed\end{framed} blabla
98
99 blabla \begin{framed}\begin{framed}nested framed\end{framed}\end{framed} blabla
100
101 blabla \fbox{fbox} blabla
102
103 blabla \framebox{framebox 1} blabla
104
105 blabla \framebox[3cm]{framebox 2} blabla
106
107 blabla \framebox[3cm][l]{framebox 3} blabla
108
109 Dies ist ein Beispieltext. %
110 \framebox{%
111 \begin{minipage}[c][1\totalheight][s]{0.2\columnwidth}%
112  \begin{center}
113   Der Boxinhalt
114  \par\end{center}
115
116  \begin{center}
117   ist über die
118  \par\end{center}
119
120  \begin{center}
121   Boxhöhe
122  \par\end{center}
123
124  \begin{center}
125   gleichmäßig verteilt.
126  \par\end{center}%
127 \end{minipage}}
128 Dies ist ein Beispieltext.
129
130 blabla \ovalbox{ovalbox} blabla
131
132 blabla \Ovalbox{Ovalbox} blabla
133
134 blabla \shadowbox{shadowbox} blabla
135
136 blabla \doublebox{doublebox} blabla
137
138 $\boxed{\int A=B}$
139
140 \subsection{LyX Boxes}
141
142 \begin{lyxgreyedout}
143 \textbf{Note:} Not all DVI-viewers are able to display rotations.
144 \end{lyxgreyedout}
145
146 \begin{shaded}%
147 Shaded background box\end{shaded}
148
149 \begin{minipage}[c]{1\columnwidth}%
150 \begin{shaded}%
151 Shaded background box, with inner minipage\end{shaded}%
152 \end{minipage}
153
154 \section{Colors}
155
156 \subsection{Predefined Colors}
157
158 test \textcolor{blue}{blue} test \textcolor{red}{red red red} test \textcolor{green}{bla}\textcolor{magenta}{blub}
159 test
160 \textcolor{green}{c}%
161 \textcolor{red}{o}%
162 \textcolor{blue}{l}%
163 \textcolor{green}{o}%
164 \textcolor{red}{r}
165
166 \subsection{Custom Colors}
167
168 test \textcolor{darkgreen}{dark green} test
169
170 \definecolor{violet}{rgb}{0.5, 0, 1}
171
172 test \textcolor{violet}{violet} test
173
174 \section{Font sizes}
175
176 \Huge Huge text
177
178 \huge huge text
179
180 \LARGE LARGE text
181
182 \Large Large text
183
184 \large large text
185
186 \normalsize normalsize text
187
188 \small small text
189
190 \footnotesize footnotesize text
191
192 \scriptsize scriptsize text
193
194 \tiny tiny text
195
196 \Huge Huge text \huge huge text \LARGE LARGE text \Large Large text
197 \large large text \normalsize normalsize text \small small text
198 \footnotesize footnotesize text \scriptsize scriptsize text \tiny tiny text
199
200 \normalsize Font size switches don't affect section headings!
201
202 \scriptsize bla blub
203
204 \section{Font size dummy 1}
205
206 bla blub
207
208 bla blub
209
210 \section*{Font size dummy 2}
211
212 bla blub
213 \normalsize
214
215
216 \section{Strikeout, underlined etc.}
217
218 Emphasized: \emph{test}
219
220 Underbar: \uline{test}
221
222 Double underbar: \uuline{test}
223
224 Wavy underbar: \uwave{test}
225
226 Strike out: \sout{test}
227
228 Crossed out: \xout{test}
229
230 Noun: \noun{test}
231
232 Underbar, emphasized, strikeout: \emph{\uline{\sout{test}}}
233
234
235 \section{Paragraph spacing}
236
237 bla
238
239 \begin{singlespace}
240 singlespace single singlespace single singlespace single singlespace single
241 singlespace single singlespace single singlespace single singlespace single
242 \end{singlespace}
243
244 \begin{onehalfspace}
245 onehalfspace 1 onehalfspace 1 onehalfspace 1 onehalfspace 1 onehalfspace 1
246 onehalfspace 1 onehalfspace 1 onehalfspace 1 onehalfspace 1 onehalfspace 1
247
248 onehalfspace 2 onehalfspace 2 onehalfspace 2 onehalfspace 2 onehalfspace 2
249 onehalfspace 2 onehalfspace 2 onehalfspace 2 onehalfspace 2 onehalfspace 2
250 \end{onehalfspace}
251
252 blub
253
254 \begin{onehalfspace}
255 onehalfspace single onehalfspace single onehalfspace single onehalfspace single
256 onehalfspace single onehalfspace single onehalfspace single onehalfspace single
257 \end{onehalfspace}
258
259 blablub
260
261 \begin{doublespace}
262 doublespace single doublespace single doublespace single doublespace single
263 doublespace single doublespace single doublespace single doublespace single
264 \end{doublespace}
265
266 \begin{spacing}{1.2}
267 1.2 spacing single 1.2 spacing single 1.2 spacing single 1.2 spacing single
268 1.2 spacing single 1.2 spacing single 1.2 spacing single 1.2 spacing single
269 \end{spacing}
270
271 \section{Paragraph alignment}
272
273 bla
274
275 \begin{center}
276 center single center single center single center single center single
277 center single center single center single center single center single
278 \end{center}
279
280 blabla
281
282 \begin{flushleft}
283 flushleft 1 flushleft 1 flushleft 1 flushleft 1 flushleft 1 flushleft 1
284 flushleft 1 flushleft 1 flushleft 1 flushleft 1 flushleft 1 flushleft 1
285
286 flushleft 2 flushleft 2 flushleft 2 flushleft 2 flushleft 2 flushleft 2
287 flushleft 2 flushleft 2 flushleft 2 flushleft 2 flushleft 2 flushleft 2
288 \end{flushleft}
289
290 blub
291
292 \begin{flushleft}
293 flushleft single flushleft single flushleft single flushleft single
294 flushleft single flushleft single flushleft single flushleft single
295 \end{flushleft}
296
297 blablub
298
299 \begin{flushright}
300 flushright single flushright single flushright single flushright single
301 flushright single flushright single flushright single flushright single
302 \end{flushright}
303
304 bla
305
306 \centering
307 centering single centering single centering single centering single
308 centering single centering single centering single centering single
309
310 blabla
311
312 \raggedright
313 raggedright 1 raggedright 1 raggedright 1 raggedright 1 raggedright 1
314 raggedright 1 raggedright 1 raggedright 1 raggedright 1 raggedright 1
315
316 raggedright 2 raggedright 2 raggedright 2 raggedright 2 raggedright 2
317 raggedright 2 raggedright 2 raggedright 2 raggedright 2 raggedright 2
318
319 \raggedleft
320 raggedleft 1 raggedleft 1 raggedleft 1 raggedleft 1 raggedleft 1
321 raggedleft 1 raggedleft 1 raggedleft 1 raggedleft 1 raggedleft 1
322
323 raggedleft 2 raggedleft 2 raggedleft 2 raggedleft 2 raggedleft 2
324 raggedleft 2 raggedleft 2 raggedleft 2 raggedleft 2 raggedleft 2
325
326 %set back to justified
327 \raggedright{}
328
329
330 \subsection{Horizontal spaces}
331
332 Lines can have an hfill \hfill in the middle.
333 Lines can have an hfill \hspace{\fill} in the middle.
334 Lines can have a protected hfill \hspace*{\fill} in the middle.
335 Lines can have a dotted fill \dotfill in the middle.
336 Lines can have a rule fill \hrulefill in the middle.
337 Lines can have a left arrow fill \leftarrowfill in the middle.
338 Lines can have a right arrow fill \rightarrowfill in the middle.
339 Lines can have a upbrace fill \upbracefill in the middle.
340 Lines can have a downbrace fill \downbracefill in the middle.
341 Lines can have space \hspace{2cm} in the middle.
342 Lines can have protected space \hspace*{2cm} in the middle.
343
344 We also handle defined spaces:
345
346 Interword\ a
347
348 Visible\textvisiblespace{}a
349
350 Thin\,a
351
352 Medium\:a
353
354 Thick\;a
355
356 NegThin\negthinspace{}a
357
358 NegMed\negmedspace{}a
359
360 NegThick\negthickspace{}a
361
362 enspace\enspace{}a
363
364 enskip\enskip{}a
365
366 quad\quad{}a
367
368 qquad\qquad{}a
369
370 \subsubsection*{now some math examples:}
371
372 $a\hfill b$
373
374 $a\hspace*{2cm}b$
375
376 $a\hspace{1cm}b$
377
378 $a\hspace*{\fill} b$
379
380 $a\enskip b$
381
382 $a\enspace b$
383
384
385 \subsection{Vertical spaces}
386
387 Lines can have a vfill \vfill in the middle.
388 Lines can have a vfill \vspace{\fill} in the middle.
389 Lines can have a protected vfill \vspace*{\fill} in the middle.
390 Lines can have vertical space \vspace{2cm} in the middle.
391 Lines can have protected vertical space \vspace*{2cm} in the middle.
392
393 We also handle skips:
394
395 bigskip 1:\bigskip
396
397 bigskip 2:\vspace{\bigskipamount}
398
399 medskip 1:\medskip
400
401 medskip 2:\vspace{\medskipamount}
402
403 smallskip 1:\smallskip
404
405 smallskip 2:\vspace{\smallskipamount}
406
407
408 \end{document}