]> git.lyx.org Git - lyx.git/blob - lib/layouts/theorems-ams-chap-bytype.inc
DocBook: implement other letter classes (frletter, standard letter, KOMA-Script).
[lyx.git] / lib / layouts / theorems-ams-chap-bytype.inc
1 # Original Author : David L. Johnson <dlj0@lehigh.edu>
2 # Probably broken by Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
3 # modified and modularized by Emmanuel GUREGHIAN <gureghia@boston.bertin.fr>
4 # Tinkered with Sep. '07 by Paul Rubin <rubin@msu.edu>
5 # Modularized Jan 08 by Richard Heck <rgheck@comcast.net>
6 # Hacked June '09 by Paul Rubin <rubin@msu.edu> to use separate counters
7 # Chapter dependence added Oct '16 by Andrew Parsloe <aparsloe@clear.net.nz>
8
9 # The environments defined are :
10 # - Theorem
11 # - Corollary
12 # - Lemma
13 # - Proposition
14 # - Conjecture
15 # - Fact
16 # - Definition
17 # - Example
18 # - Problem
19 # - Exercise
20 # - Solution
21 # - Remark
22 # - Claim
23 # - Case (by inclusion)
24
25
26 # We need separate counters for each theorem-like style.
27 Format 85
28 Counter theorem
29         GuiName Theorem
30         Within         chapter
31 End
32 Counter corollary
33         GuiName Corollary
34         Within         chapter
35 End
36 Counter lemma
37         GuiName Lemma
38         Within         chapter
39 End
40 Counter proposition
41         GuiName Proposition
42         Within         chapter
43 End
44 Counter conjecture
45         GuiName Conjecture
46         Within         chapter
47 End
48 Counter fact
49         GuiName Fact
50         Within         chapter
51 End
52 Counter definition
53         GuiName Definition
54         Within         chapter
55 End
56 Counter example
57         GuiName Example
58         Within         chapter
59 End
60 Counter problem
61         GuiName Problem
62         Within         chapter
63 End
64 Counter exercise
65         GuiName Exercise
66         Within         chapter
67 End
68 Counter solution
69         GuiName Solution
70         Within         chapter
71 End
72 Counter remark
73         GuiName Remark
74         Within         chapter
75 End
76 Counter claim
77         GuiName Claim
78         Within         chapter
79 End
80
81 OutlinerName thm "Definitions & Theorems"
82
83 Style Theorem
84         Category              Reasoning
85         Margin                First_Dynamic
86         LatexType             Environment
87         LatexName             thm
88         NextNoIndent          1
89         ResetArgs             1
90         AddToToc              thm
91         IsTocCaption          1
92         Argument 1
93                 LabelString    "Additional Theorem Text"
94                 Tooltip        "Additional text appended to the theorem header"
95                 IsTocCaption      1
96         EndArgument
97         LabelSep              xx
98         ParIndent             MMM
99         ParSkip               0.4
100         ItemSep               0.2
101         TopSep                0.7
102         BottomSep             0.7
103         ParSep                0.3
104         Align                 Block
105         AlignPossible         Left
106         LabelType             Static
107         LabelCounter          theorem
108         LabelString           "Theorem \thetheorem."
109         Font
110           Shape               Italic
111           Size                Normal
112         EndFont
113         LabelFont
114           Shape               Up
115           Series              Bold
116         EndFont
117         Preamble
118                 \theoremstyle{plain}
119     \ifx\thechapter\undefined
120             \newtheorem{thm}{\protect\theoremname}
121           \else
122       \newtheorem{thm}{\protect\theoremname}[chapter]
123     \fi
124         EndPreamble
125         LangPreamble
126                 \providecommand{\theoremname}{_(Theorem)}
127         EndLangPreamble
128         BabelPreamble
129                 \addto\captions$$lang{\renewcommand{\theoremname}{_(Theorem)}}
130         EndBabelPreamble
131         Requires              amsthm
132         DocBookTag            para
133         DocBookAttr           role='theorem'
134 End
135
136
137 Style Corollary
138         CopyStyle             Theorem
139         LatexName             cor
140         LabelString           "Corollary \thecorollary."
141         Preamble
142           \theoremstyle{plain}
143     \ifx\thechapter\undefined
144             \newtheorem{cor}{\protect\corollaryname}
145           \else
146       \newtheorem{cor}{\protect\corollaryname}[chapter]
147     \fi
148         EndPreamble
149         LabelCounter          corollary
150         LangPreamble
151                 \providecommand{\corollaryname}{_(Corollary)}
152         EndLangPreamble
153         BabelPreamble
154                 \addto\captions$$lang{\renewcommand{\corollaryname}{_(Corollary)}}
155         EndBabelPreamble
156         DocBookTag            para
157         DocBookAttr           role='corollary'
158 End
159
160
161 Style Lemma
162         CopyStyle             Theorem
163         LatexName             lem
164         LabelString           "Lemma \thelemma."
165         Preamble
166           \theoremstyle{plain}
167     \ifx\thechapter\undefined
168       \newtheorem{lem}{\protect\lemmaname}
169     \else
170       \newtheorem{lem}{\protect\lemmaname}[chapter]
171     \fi
172         EndPreamble
173         LangPreamble
174           \providecommand{\lemmaname}{_(Lemma)}
175         EndLangPreamble
176         BabelPreamble
177           \addto\captions$$lang{\renewcommand{\lemmaname}{_(Lemma)}}
178         EndBabelPreamble
179         LabelCounter          lemma
180         DocBookTag            para
181         DocBookAttr           role='lemma'
182 End
183
184
185 Style Proposition
186         CopyStyle             Theorem
187         LatexName             prop
188         LabelString           "Proposition \theproposition."
189         Preamble
190           \theoremstyle{plain}
191     \ifx\thechapter\undefined
192       \newtheorem{prop}{\protect\propositionname}
193     \else
194       \newtheorem{prop}{\protect\propositionname}[chapter]
195     \fi
196         EndPreamble
197         LangPreamble
198           \providecommand{\propositionname}{_(Proposition)}
199         EndLangPreamble
200         BabelPreamble
201           \addto\captions$$lang{\renewcommand{\propositionname}{_(Proposition)}}
202         EndBabelPreamble
203         LabelCounter          proposition
204         DocBookTag            para
205         DocBookAttr           role='proposition'
206 End
207
208
209 Style Conjecture
210         CopyStyle             Theorem
211         LatexName             conjecture
212         LabelString           "Conjecture \theconjecture."
213         Preamble
214           \theoremstyle{plain}
215     \ifx\thechapter\undefined
216       \newtheorem{conjecture}{\protect\conjecturename}
217     \else
218       \newtheorem{conjecture}{\protect\conjecturename}[chapter]
219     \fi
220         EndPreamble
221         LangPreamble
222           \providecommand{\conjecturename}{_(Conjecture)}
223         EndLangPreamble
224         BabelPreamble
225           \addto\captions$$lang{\renewcommand{\conjecturename}{_(Conjecture)}}
226         EndBabelPreamble
227         LabelCounter          conjecture
228         DocBookTag            para
229         DocBookAttr           role='conjecture'
230 End
231
232
233 Style Fact
234         CopyStyle             Theorem
235         LatexName             fact
236         LabelString           "Fact \thefact."
237         Preamble
238           \theoremstyle{plain}
239     \ifx\thechapter\undefined
240       \newtheorem{fact}{\protect\factname}
241     \else
242       \newtheorem{fact}{\protect\factname}[chapter]
243     \fi
244         EndPreamble
245         LangPreamble
246           \providecommand{\factname}{_(Fact)}
247         EndLangPreamble
248         BabelPreamble
249           \addto\captions$$lang{\renewcommand{\factname}{_(Fact)}}
250         EndBabelPreamble
251         LabelCounter          fact
252         DocBookTag            para
253         DocBookAttr           role='fact'
254 End
255
256
257 Style Definition
258         CopyStyle             Theorem
259         LatexName             defn
260         LabelString           "Definition \thedefinition."
261         Font
262           Shape               Up
263         EndFont
264         LabelFont
265           Shape               Up
266           Series              Bold
267         EndFont
268         Preamble
269           \theoremstyle{definition}
270     \ifx\thechapter\undefined
271       \newtheorem{defn}{\protect\definitionname}
272     \else
273       \newtheorem{defn}{\protect\definitionname}[chapter]
274     \fi
275         EndPreamble
276         LangPreamble
277           \providecommand{\definitionname}{_(Definition)}
278         EndLangPreamble
279         BabelPreamble
280           \addto\captions$$lang{\renewcommand{\definitionname}{_(Definition)}}
281         EndBabelPreamble
282         LabelCounter          definition
283         DocBookTag            para
284         DocBookAttr           role='definition'
285 End
286
287
288 Style Example
289         CopyStyle             Definition
290         LatexName             example
291         LabelString           "Example \theexample."
292         Preamble
293           \theoremstyle{definition}
294     \ifx\thechapter\undefined
295       \newtheorem{example}{\protect\examplename}
296     \else
297       \newtheorem{example}{\protect\examplename}[chapter]
298     \fi
299         EndPreamble
300         Requires              amsthm
301         LangPreamble
302           \providecommand{\examplename}{_(Example)}
303         EndLangPreamble
304         BabelPreamble
305           \addto\captions$$lang{\renewcommand{\examplename}{_(Example)}}
306         EndBabelPreamble
307         LabelCounter          example
308         DocBookWrapperTag     informalexample
309         DocBookTag            para
310         DocBookAttr        ""
311 End
312
313
314 Style Problem
315         CopyStyle             Definition
316         LatexName             problem
317         LabelString           "Problem \theproblem."
318         Preamble
319           \theoremstyle{definition}
320     \ifx\thechapter\undefined
321       \newtheorem{problem}{\protect\problemname}
322     \else
323       \newtheorem{problem}{\protect\problemname}[chapter]
324     \fi
325         EndPreamble
326         Requires              amsthm
327         LangPreamble
328           \providecommand{\problemname}{_(Problem)}
329         EndLangPreamble
330         BabelPreamble
331           \addto\captions$$lang{\renewcommand{\problemname}{_(Problem)}}
332         EndBabelPreamble
333         LabelCounter          problem
334         DocBookTag            para
335         DocBookAttr           role='problem'
336 End
337
338
339 Style Exercise
340         CopyStyle             Definition
341         LatexName             xca
342         LabelString           "Exercise \theexercise."
343         Preamble
344           \theoremstyle{definition}
345     \ifx\thechapter\undefined
346       \newtheorem{xca}{\protect\exercisename}
347     \else
348       \newtheorem{xca}{\protect\exercisename}[chapter]
349     \fi
350         EndPreamble
351         Requires              amsthm
352         LangPreamble
353           \providecommand{\exercisename}{_(Exercise)}
354         EndLangPreamble
355         BabelPreamble
356           \addto\captions$$lang{\renewcommand{\exercisename}{_(Exercise)}}
357         EndBabelPreamble
358         LabelCounter          exercise
359         DocBookTag            para
360         DocBookAttr           role='exercise'
361 End
362
363
364 Style Solution
365         CopyStyle             Definition
366         LatexName             sol
367         LabelString           "Solution \thesolution."
368         Preamble
369           \theoremstyle{definition}
370     \ifx\thechapter\undefined
371       \newtheorem{sol}{\protect\solutionname}
372     \else
373       \newtheorem{sol}{\protect\solutionname}[chapter]
374     \fi
375         EndPreamble
376         Requires              amsthm
377         LangPreamble
378                 \providecommand{\solutionname}{_(Solution)}
379         EndLangPreamble
380         BabelPreamble
381                 \addto\captions$$lang{\renewcommand{\solutionname}{_(Solution)}}
382         EndBabelPreamble
383         LabelCounter          solution
384         DocBookTag            para
385         DocBookAttr           role='solution'
386 End
387
388
389 Style Remark
390         CopyStyle             Theorem
391         LatexName             rem
392         LabelString           "Remark \theremark."
393         Font
394           Shape               Up
395           Size                Normal
396         EndFont
397         LabelFont
398           Series              Medium
399           Shape               Italic
400         EndFont
401         Preamble
402           \theoremstyle{remark}
403     \ifx\thechapter\undefined
404       \newtheorem{rem}{\protect\remarkname}
405     \else
406       \newtheorem{rem}{\protect\remarkname}[chapter]
407     \fi
408         EndPreamble
409         LangPreamble
410           \providecommand{\remarkname}{_(Remark)}
411         EndLangPreamble
412         BabelPreamble
413           \addto\captions$$lang{\renewcommand{\remarkname}{_(Remark)}}
414         EndBabelPreamble
415         LabelCounter          remark
416         DocBookTag            note
417         DocBookItemTag        para
418 End
419
420
421 Style Claim
422         CopyStyle             Remark
423         LatexName             claim
424         LabelString           "Claim \theclaim."
425         Preamble
426           \theoremstyle{remark}
427     \ifx\thechapter\undefined
428       \newtheorem{claim}{\protect\claimname}
429     \else
430       \newtheorem{claim}{\protect\claimname}[chapter]
431     \fi
432         EndPreamble
433         Requires              amsthm
434         LangPreamble
435           \providecommand{\claimname}{_(Claim)}
436         EndLangPreamble
437         BabelPreamble
438           \addto\captions$$lang{\renewcommand{\claimname}{_(Claim)}}
439         EndBabelPreamble
440         LabelCounter          claim
441         DocBookTag            para
442         DocBookAttr           role='claim'
443         DocBookItemTag        ""
444 End
445
446
447 Input theorems-case.inc