]> git.lyx.org Git - lyx.git/blob - src/tex2lyx/test/test-refstyle-theorems.tex
test/test-refstyle-theorems.lyx.lyx: update reference according to yesterdays tex2lyx...
[lyx.git] / src / tex2lyx / test / test-refstyle-theorems.tex
1 %% Do not edit unless you really know what you are doing.
2 \documentclass[english]{book}
3 \usepackage[T1]{fontenc}
4 \usepackage[latin9]{inputenc}
5 \usepackage{refstyle}
6 \usepackage{float}
7 \usepackage{amsthm}
8
9 \makeatletter
10
11 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
12
13 \AtBeginDocument{\providecommand\partref[1]{\ref{part:#1}}}
14 \AtBeginDocument{\providecommand\chapref[1]{\ref{chap:#1}}}
15 \AtBeginDocument{\providecommand\secref[1]{\ref{sec:#1}}}
16 \AtBeginDocument{\providecommand\subsecref[1]{\ref{subsec:#1}}}
17 \AtBeginDocument{\providecommand\parref[1]{\ref{par:#1}}}
18 \AtBeginDocument{\providecommand\figref[1]{\ref{fig:#1}}}
19 \AtBeginDocument{\providecommand\tabref[1]{\ref{tab:#1}}}
20 \AtBeginDocument{\providecommand\algref[1]{\ref{alg:#1}}}
21 \AtBeginDocument{\providecommand\fnref[1]{\ref{fn:#1}}}
22 \AtBeginDocument{\providecommand\enuref[1]{\ref{enu:#1}}}
23 \AtBeginDocument{\providecommand\eqref[1]{\ref{eq:#1}}}
24 \AtBeginDocument{\providecommand\lemref[1]{\ref{lem:#1}}}
25 \AtBeginDocument{\providecommand\thmref[1]{\ref{thm:#1}}}
26 \AtBeginDocument{\providecommand\corref[1]{\ref{cor:#1}}}
27 \AtBeginDocument{\providecommand\propref[1]{\ref{prop:#1}}}
28 \floatstyle{ruled}
29 \newfloat{algorithm}{tbp}{loa}[chapter]
30 \providecommand{\algorithmname}{Algorithm}
31 \floatname{algorithm}{\protect\algorithmname}
32 \RS@ifundefined{subsecref}
33   {\newref{subsec}{name = \RSsectxt}}
34   {}
35 \RS@ifundefined{thmref}
36   {\def\RSthmtxt{theorem~}\newref{thm}{name = \RSthmtxt}}
37   {}
38 \RS@ifundefined{lemref}
39   {\def\RSlemtxt{lemma~}\newref{lem}{name = \RSlemtxt}}
40   {}
41
42
43 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands.
44 \theoremstyle{plain}
45 \newtheorem{thm}{\protect\theoremname}
46 \theoremstyle{plain}
47 \newtheorem{lem}[thm]{\protect\lemmaname}
48 \theoremstyle{plain}
49 \newtheorem{cor}[thm]{\protect\corollaryname}
50 \theoremstyle{plain}
51 \newtheorem{prop}[thm]{\protect\propositionname}
52 \theoremstyle{plain}
53 \newtheorem{conjecture}[thm]{\protect\conjecturename}
54 \theoremstyle{plain}
55 \newtheorem{fact}[thm]{\protect\factname}
56 \theoremstyle{definition}
57 \newtheorem{defn}[thm]{\protect\definitionname}
58 \theoremstyle{definition}
59 \newtheorem{example}[thm]{\protect\examplename}
60 \theoremstyle{definition}
61 \newtheorem{problem}[thm]{\protect\problemname}
62 \theoremstyle{definition}
63 \newtheorem{xca}[thm]{\protect\exercisename}
64 \theoremstyle{remark}
65 \newtheorem{rem}[thm]{\protect\remarkname}
66 \theoremstyle{remark}
67 \newtheorem{claim}[thm]{\protect\claimname}
68 \ifx\proof\undefined
69 \newenvironment{proof}[1][\protect\proofname]{\par
70 \normalfont\topsep6\p@\@plus6\p@\relax
71 \trivlist
72 \itemindent\parindent
73 \item[\hskip\labelsep\scshape #1]\ignorespaces
74 }{%
75 \endtrivlist\@endpefalse
76 }
77 \providecommand{\proofname}{Proof}
78 \fi
79
80 \makeatother
81
82 \usepackage{babel}
83 \providecommand{\claimname}{Claim}
84 \providecommand{\conjecturename}{Conjecture}
85 \providecommand{\corollaryname}{Corollary}
86 \providecommand{\definitionname}{Definition}
87 \providecommand{\examplename}{Example}
88 \providecommand{\exercisename}{Exercise}
89 \providecommand{\factname}{Fact}
90 \providecommand{\lemmaname}{Lemma}
91 \providecommand{\problemname}{Problem}
92 \providecommand{\propositionname}{Proposition}
93 \providecommand{\remarkname}{Remark}
94 \providecommand{\theoremname}{Theorem}
95
96 \begin{document}
97
98 \part{part\label{part:part}}
99
100 \partref{part}
101
102
103 \chapter{chapter\label{chap:chapter}}
104
105 \chapref{chapter}
106
107
108 \section{Section\label{sec:Section}}
109
110 \secref{Section}
111
112
113 \subsection{Subsection\label{subsec:subsection}}
114
115 Ref to \subsecref{subsection}.
116
117
118 \subsubsection{Subsubsection\label{subsec:Subsubsection}}
119
120 Ref to \subsecref{Subsubsection}.
121
122
123 \paragraph{paragraph\label{par:paragraph}}
124
125 \parref{paragraph}
126
127
128 \subparagraph{subparagraph\label{par:subparagraph}}
129
130 \parref{subparagraph}
131
132 \begin{figure}
133 \protect\caption{figure\label{fig:figure}}
134 \end{figure}
135
136
137 \figref{figure}
138
139 \begin{table}
140 \protect\caption{table\label{tab:table}}
141 \end{table}
142
143
144 \tabref{table}
145
146 \begin{algorithm}
147 \protect\caption{algorithm\label{alg:algorithm}}
148 \end{algorithm}
149
150
151 \algref{algorithm}
152
153 \footnote{foot\label{fn:foot}%
154 }
155
156 \fnref{foot}
157
158 \marginpar{margin\label{margin}}
159
160 \ref{margin}
161 \begin{enumerate}
162 \item item\label{enu:item}
163 \end{enumerate}
164 \enuref{item}
165
166 \begin{equation}
167 A=B\label{eq:A=00003DB}
168 \end{equation}
169
170
171 \eqref{A=00003DB}
172 \begin{lem}
173 lemma\label{lem:lemma}
174
175 \lemref{lemma}\end{lem}
176 \begin{thm}
177 theorem\label{thm:theorem}
178
179 \thmref{theorem}\end{thm}
180 \begin{cor}
181 corollary\label{cor:corollary}
182
183 \corref{corollary}\end{cor}
184 \begin{prop}
185 proposition\label{prop:proposition}
186
187 \propref{proposition}\end{prop}
188 \begin{conjecture}
189 conjecture\label{conjecture}
190
191 \ref{conjecture}\end{conjecture}
192 \begin{fact}
193 fact\label{fact}
194
195 \ref{fact}\end{fact}
196 \begin{defn}
197 definition\label{definition}
198
199 \ref{definition}\end{defn}
200 \begin{example}
201 example\label{example}
202
203 \ref{example}\end{example}
204 \begin{problem}
205 problem\label{problem}
206
207 \ref{problem}\end{problem}
208 \begin{xca}
209 exercise\label{exercise}
210
211 \ref{exercise}\end{xca}
212 \begin{rem}
213 remark\label{remark}
214
215 \ref{remark}\end{rem}
216 \begin{claim}
217 claim\label{claim}
218
219 \ref{claim}\end{claim}
220 \begin{proof}
221 proof\label{proof}
222
223 \ref{proof}\end{proof}
224
225 \end{document}