-
Notifications
You must be signed in to change notification settings - Fork 0
/
prog.sty
executable file
·41 lines (33 loc) · 1.25 KB
/
prog.sty
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
\def\listofprograms{\@restonecolfalse\if@twocolumn\@restonecoltrue\onecolumn
\fi\chapter*{List of programs\@mkboth
{List of programs}{List of programs}}\@starttoc{lop}\if@restonecol\twocolumn
\fi}
\let\l@program\l@figure
\newcounter{program}[chapter]
\def\theprogram{\thechapter.\@arabic\c@program}
\def\theHprogram{\theHchapter.\@arabic\c@program}
\def\fps@program{htb}
\def\ftype@program{1}
\def\ext@program{lop}
\def\fnum@program{Program \theprogram}
\@namedef{program*}{\@dblfloat{program}}
\@namedef{endprogram*}{\end@dblfloat}
\def\program{\@float{program}}
\let\endprogram\end@float
\def\listofexamples{\@restonecolfalse\if@twocolumn\@restonecoltrue\onecolumn
\fi\chapter*{List of examples\@mkboth
{List of examples}{List of examples}}\@starttoc{loe}\if@restonecol\twocolumn
\fi}
\let\l@example\l@figure
\newcounter{example}[chapter]
\def\theexample{\thechapter.\@arabic\c@example}
\def\theHexample{\theHchapter.\@arabic\c@example}
\def\fps@example{htb}
\def\ftype@example{1}
\def\ext@example{loe}
\def\fnum@example{Example \theexample}
\@namedef{example*}{\@dblfloat{example}}
\@namedef{endexample*}{\end@dblfloat}
\def\example{\@float{example}}
\let\endexample\end@float
\renewenvironment{boxed}{\begin{boxedminipage}{\textwidth}}{\end{boxedminipage}}