File: theorem.html

package info (click to toggle)
texlive-lang 2018.20190227-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,175,732 kB
  • sloc: perl: 58,868; xml: 39,109; makefile: 4,050; sh: 4,033; python: 2,969; ansic: 2,846; ruby: 1,003; lisp: 714; awk: 636; java: 159; sed: 142; csh: 25; cpp: 12
file content (131 lines) | stat: -rw-r--r-- 4,566 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-2">
<title> Zastaw ciekawych makroinstrukcji </title>
<LINK REL="stylesheet" TYPE="text/css" HREF="mycss.css">
<meta http-equiv="Content-language" content="pl">
<meta name="Author" content="Wodzimierz Macewicz">
<meta name="Keywords" content="tex, latex, makroinstrukcje, pakiety makroinstrukcji, Wirtualna Akademia">
</head>
<body bgcolor=#a0f0a0>
<h2>theorem</h2>
Pakiet pozwala na definiowanie rodowisk sucych do opisu przykadw,
zada, definicji itp. podstawowym poleceniem jest:<br>
<code>\newteorem{<i>nazwa rodowiska</i>}{<i>tekst nagwka</i>}</code><br>
lub<br>
<code>\newteorem{<i>nazwa rodowiska drugiego</i>}%
	[<i>nazwa rodowiska</i>]{<i>tekst nagwka drugiego</i>}</code><br>
licznikiem kolejnych pozycji bdzie licznik okrelony przez
<i>nazwa rodowiska</i><br>
oraz<br>
<code>\newteorem{<i>nazwa rodowiska drugiego</i>}%
{<i>tekst nagwka drugiego</i>}[section]</code><br>
licznik zliczajcy kolejne uycie rodowiska jest zerowany przy zmianie
licznika <tt>section</tt> (<tt>chapter</tt>, <tt>subsection</tt> itp.), oraz
w skad numeru wchodzi licznik nadrzdny.

<p>
Dostpne s polecenia zmieniajce:
<ul>
<li>sposb numerowania kolejnych pozycji:<br>
<code>\theoremstyle{<i>style</i>}</code><br>
gdzie <i>style</i> moe przyjmowa nastpujce wartoci:
<dl>
<dt><tt>plain</tt>
<dd> emuluje oryginalny styl LaTeX'a
<dt><tt>break</tt>
<dd> tekst opisu pisany jest ,,od nowej linii''
<dt><tt>marginbreak</tt>
<dd> numer umieszczany jest na marginesie,
			tekst opisu pisany jest ,,od nowej linii''
<dt><tt>changebreak</tt>
<dd> numer umieszczany jest na pocztku nagwka,
			tekst opisu pisany jest ,,od nowej linii''
<dt><tt>change</tt>
<dd> numer umieszczany jest na pocztku nagwka,
<dt><tt>margin</tt>
<dd> numer umieszczany jest na marginesie,
</dl>
<li> font nagwka (wszystkie rodowiska musz mie ten sam font
nagwka (wana jest tylko pierwsza definicja!) <br>
<code>\theoremheaderfont{<i>font</i>}</code>
<li>font ktrym skadana jest tre rodowiska<br>
<code>\theorembodyfont{<i>font</i>}</code>
<li>odstp przed rodowiskiem<br>
<code>\theorempreskimamount</code>
<li>odstp po zamkniciu rodowiska<br>
<code>\theorempostskimamount</code>
</ul>

<p>
<b>Przykad</b><br>
Ponisze polecenia definiujce nowe rodowiska i ich cechy musz znale
si w preambule dokumentu (midzy poleceniem <code>\documentclass...</code>,
a <code>\begin{document}</code>).

<p>
Licznikiem rodowiska <i>Def</i> jest licznik rodowiska <i>The</i>,
a licznik rodowiska <i>Lem</i> jest zaleny od licznika rodowiska <i>The</i>.

<pre>
\theoremstyle{plain}               \newtheorem{Cor}{Corollary}

\theoremheaderfont{\normalfont\bfseries}
\theorembodyfont{\normalfont\slshape}

\theoremstyle{break}               \newtheorem{Exa}{Example}
\theoremstyle{changebreak}         \newtheorem{The}{Theorem}
\theoremstyle{marginbreak}         \newtheorem{Lem}{Lemma}[The]
\theoremstyle{change}              \newtheorem{Def}[The]{Definition}
\theoremstyle{margin}              \newtheorem{Rem}{Remark}
\theoremstyle{nonumber}            \newtheorem{uwaga}{Uwaga !}
\begin{Cor}
This is a sentence typeset in the theorem environment <i>Cor</i>.
\end{Cor}
\begin{Exa}
This is a sentence typeset in the theorem environment <i>Exa</i>.
\end{Exa}
\begin{The}
This is a sentence typeset in the theorem environment <i>The</i>.
\end{The}
\begin{Lem}
This is a sentence typeset in the theorem environment <i>Lem</i>.
\end{Lem}
\begin{Def}[extra text]
This is a sentence typeset in the theorem environment <i>Def</i>.
\end{Def}
\begin{Rem}
This is a sentence typeset in the theorem environment <i>Rem</i>.
\end{Rem}
\begin{uwaga}
This is a sentence typeset in the theorem environment <i>uwaga</i>.
\end{uwaga}
</pre>

<img src=theorem.gif>

<p>
Utworzenie nowego sposobu prezentacji rodowiska nie zostao rozwizane 
w sposb elegancki; wymaga dopisania nastpujcej
makroinstrukcji (przykad dla rodowiska <tt>uwaga</tt>), gdzie 
<i>nonumber</i> jest nazw nowego rodowiska
(uwaga na znak <tt>@</tt>)
<pre>
\gdef\th@nonumber{\normalfont\slshape
  \def\@begintheorem##1##2{\item[%
       \rlap{\vbox{\hbox{\hskip \labelsep\theorem@headerfont ##1}%
\vskip 1ex%
                   \hbox{\strut}}}]}%
\def\@opargbegintheorem##1##2##3{%
  \item[\rlap{\vbox{\hbox{\hskip \labelsep \theorem@headerfont
                     ##1\ ##2\ (##3)}%
                    \hbox{\strut}}}]}}
</pre>

<hr>
<em>Wodzimierz Macewicz</em>
<hr>
Ostatnie zmiany: 05.05.2014.

</body>
</html>