41761fdc |
1 | %%% -*-latex-*- |
2 | %%% |
3 | %%% Definitions for IPS course |
4 | |
76f457cb |
5 | \NeedsTeXFormat{LaTeX2e} |
6 | \ProvidesClass{ips}[2001/10/02] |
7 | |
8 | %%%----- Document class stuff ----------------------------------------------- |
9 | |
10 | \newif\ifipsslides \ipsslidesfalse |
11 | \newif\ifipsanswers \ipsanswerstrue |
12 | \InputIfFileExists{ips.cfg}\relax\relax |
13 | |
14 | \ifipsslides |
aa3dde65 |
15 | \PassOptionsToClass{a4, slidesonly}{mdwslides} |
76f457cb |
16 | \else |
aa3dde65 |
17 | \PassOptionsToClass{a4, article, twoside}{mdwslides} |
76f457cb |
18 | \fi |
aa3dde65 |
19 | \DeclareOption*{\PassOptionsToClass{\CurrentOption}{mdwslides}} |
76f457cb |
20 | \ProcessOptions |
aa3dde65 |
21 | \LoadClass{mdwslides} |
76f457cb |
22 | |
41761fdc |
23 | %%%----- Required packages -------------------------------------------------- |
24 | |
25 | \RequirePackage[palatino, helvetica, courier, maths=cmr]{mdwfonts} |
41761fdc |
26 | \RequirePackage[T1]{fontenc} |
27 | \RequirePackage{mdwtab, mathenv, crypto, mdwthm, mdwmath} |
28 | \RequirePackage[within=section]{exercise} |
29 | \RequirePackage{amssymb} |
30 | \RequirePackage{url} |
31 | |
32 | \ifx\pdfoutput\@@undefined |
76f457cb |
33 | \PassOptionsToPackage{dvips}{xy} |
41761fdc |
34 | \else |
41761fdc |
35 | \ifarticle |
36 | \pdfpagewidth\paperwidth |
37 | \pdfpageheight\paperheight |
38 | \else |
39 | \pdfpagewidth\paperheight |
40 | \pdfpageheight\paperwidth |
41 | \fi |
42 | \fi |
76f457cb |
43 | \RequirePackage[all]{xy} |
41761fdc |
44 | |
45 | %%%----- Miscellaneous settings --------------------------------------------- |
46 | |
47 | \errorcontextlines=999 |
48 | |
49 | %%%----- Style choices ------------------------------------------------------ |
50 | |
51 | \renewcommand{\qedsymbol}{$\square$} |
52 | \def\hex#1{\texttt{0x#1}} |
53 | \let\emptystring\lambda |
54 | \let\epsilon\varepsilon |
55 | \let\phi\varphi |
56 | \let\emptyset\varnothing |
57 | \bibliographystyle{mdwalpha} |
58 | \sloppy |
59 | |
60 | %%%----- Exercise typesetting ----------------------------------------------- |
61 | |
62 | \exctrcheck{section}{\answrite{\protect\subsection*{Section \thesection}}} |
63 | |
64 | %%%----- Diagram typesetting ------------------------------------------------ |
65 | |
66 | \turnradius={4pt} |
67 | |
68 | \def\ocat{ |
69 | \setbox\z@\hbox{$\scriptstyle\|$}% |
70 | \dimen8\ht\z@\advance\dimen8\dp\z@% |
71 | \mathbin{\xy *=<\dimen8>[o][F]{\box\z@} \endxy}% |
72 | } |
73 | |
41761fdc |
74 | %%%----- That's all, folks -------------------------------------------------- |
75 | |
76 | \endinput |