Mercurial > docs > diploma
comparison thesis/thesis.sty @ 268:807660903834
cleanups and new codeinput command
author | meillo@marmaro.de |
---|---|
date | Thu, 15 Jan 2009 12:07:06 +0100 |
parents | aff94e950f39 |
children | 78987bc2c809 |
comparison
equal
deleted
inserted
replaced
267:8a6b6d941bbb | 268:807660903834 |
---|---|
1 \ProvidesPackage{thesis} | 1 \ProvidesPackage{thesis} |
2 | 2 |
3 \usepackage[utf8]{inputenc} | 3 \usepackage[utf8]{inputenc} |
4 \usepackage{graphicx} | |
5 \usepackage{url} | |
6 | 4 |
7 \usepackage{makeidx} | 5 \usepackage{graphicx} |
8 \makeindex | 6 \usepackage{url} |
7 \usepackage{relsize} % for \smaller, used in \NAME | |
8 \usepackage{verbatim} % for \verbatiminput, used in \code | |
9 %\usepackage{showidx} % for index-checking | |
9 | 10 |
10 \usepackage{multibib} | 11 \usepackage{makeidx} |
11 \newcites{web}{Websites} | 12 \makeindex |
12 | 13 |
13 \setlength{\parindent}{0em} | 14 \usepackage{multibib} |
14 \setlength{\parskip}{1.0ex plus 1.0ex minus 0.5ex} | 15 \newcites{web}{Websites} |
15 \setcounter{tocdepth}{2} | |
16 | 16 |
17 \pagestyle{headings} | 17 % font |
18 %\pagestyle{fancy} | 18 \usepackage[T1]{fontenc} |
19 %\lhead[\leftmark]{\thepage} | 19 \usepackage[sc,osf]{mathpazo} |
20 %\chead[]{} | 20 \linespread{1.05} % Palatino needs more leading (space between lines) |
21 %\rhead[\thepage]{\rightmark} | 21 %\linespread{2.05} % for proof-reading |
22 %\ifoot[\textsc{Markus Schnalke}]{\textsc{Markus Schnalke}} | |
23 %\cfoot[]{} | |
24 %\ofoot[\thepage]{\thepage} | |
25 | |
26 \usepackage{setspace} | |
27 \usepackage{relsize} | |
28 | |
29 % formating | |
30 \renewcommand{\path}[1]{\textit{#1}} | |
31 \newcommand{\name}[1]{\emph{#1}\index{#1}} | |
32 \newcommand{\NAME}[1]{{\smaller\textsc{#1}}\index{#1}} | |
33 \newcommand{\person}[1]{\textsc{#1}} | |
34 | |
35 % \newcommand{\source}[1]{\hspace{1em}\textit{\scriptsize(Quelle: #1)}} | |
36 \let\OLDcleardoublepage\cleardoublepage | |
37 \renewcommand{\cleardoublepage}{\thispagestyle{empty}\OLDcleardoublepage} | |
38 | |
39 % shortcuts | |
40 \newcommand{\masqmail}{\name{masqmail}} | |
41 \newcommand{\sendmail}{\name{sendmail}} | |
42 \newcommand{\qmail}{\name{qmail}} | |
43 \newcommand{\exim}{\name{exim}} | |
44 \newcommand{\postfix}{\name{postfix}} | |
45 \newcommand{\mta}{mail transfer agent} | |
46 \newcommand{\email}{email} | |
47 \newcommand{\debian}{\name{Debian}} | |
48 \newcommand{\linux}{\name{Linux}} | |
49 \newcommand{\gnulinux}{\NAME{GNU}/\name{Linux}} | |
50 \newcommand{\MTA}{\NAME{MTA}} | |
51 \newcommand{\RFC}{\NAME{RFC}} | |
52 \newcommand{\GNU}{\NAME{GNU}} | |
53 \newcommand{\unix}{\name{Unix}} | |
54 \newcommand{\freesw}{Free Software} | |
55 \newcommand{\gpl}{General Public License} | |
56 \newcommand{\GPL}{\NAME{GPL}} | |
57 \newcommand{\SMTP}{\NAME{SMTP}} | |
58 \newcommand{\TLS}{\NAME{TLS}} | |
59 \newcommand{\TODO}{\NAME{TODO}\,} | |
60 \newcommand{\RF}{\NAME{RF}\,} | |
61 \newcommand{\RG}{\NAME{RG}\,} | |
62 \newcommand{\RA}{\NAME{RA}\,} | |
63 \newcommand{\St}{\NAME{S}\,} | |
64 | |
65 \newcommand{\nth}{\textsuperscript{th}} | |
66 \newcommand{\st}{\textsuperscript{st}} | |
67 \newcommand{\nd}{\textsuperscript{nd}} | |
68 \newcommand{\rd}{\textsuperscript{rd}} | |
69 | |
70 | |
71 %%%% BEGIN DEBUG %%%% | |
72 %\usepackage{showidx} | |
73 %\doublespace | |
74 %%%% END DEBUG %%%% | |
75 | |
76 | |
77 % font | |
78 \usepackage[T1]{fontenc} | |
79 \usepackage[sc,osf]{mathpazo} | |
80 \linespread{1.05} % Palatino needs more leading (space between lines) | |
81 %\linespread{2.05} % for debugging | |
82 | 22 |
83 | 23 |
84 | 24 |
85 \usepackage{listings} | 25 % global formating |
86 \lstset{ | 26 \pagestyle{headings} |
87 basicstyle=\ttfamily\footnotesize, | 27 \setlength{\parindent}{0em} |
88 numberstyle=\tiny, | 28 \setlength{\parskip}{1.0ex plus 1.0ex minus 0.5ex} |
89 basewidth=0.45em, | 29 \setcounter{tocdepth}{2} |
90 numbers=left, | 30 \setlength{\labelsep}{1em} |
91 stepnumber=1, | 31 |
92 numbersep=2em, | 32 % formating macros |
93 showstringspaces=true, | 33 \renewcommand{\path}[1]{\textit{#1}} |
94 showtabs=true, | 34 \newcommand{\name}[1]{\emph{#1}\index{#1}} |
95 tab=\rightarrowfill, | 35 \newcommand{\NAME}[1]{{\smaller\textsc{#1}}\index{#1}} |
96 frame=lines, | 36 \newcommand{\person}[1]{\textsc{#1}} |
97 tabsize=4, | 37 |
98 captionpos=b, | 38 % shortcuts |
99 breaklines=false, | 39 \newcommand{\masqmail}{\name{masqmail}} |
100 breakatwhitespace=true | 40 \newcommand{\sendmail}{\name{sendmail}} |
101 } | 41 \newcommand{\qmail}{\name{qmail}} |
42 \newcommand{\exim}{\name{exim}} | |
43 \newcommand{\postfix}{\name{postfix}} | |
44 \newcommand{\mta}{mail transfer agent} | |
45 \newcommand{\email}{email} | |
46 \newcommand{\debian}{\name{Debian}} | |
47 \newcommand{\linux}{\name{Linux}} | |
48 \newcommand{\gnulinux}{\NAME{GNU}/\name{Linux}} | |
49 \newcommand{\MTA}{\NAME{MTA}} | |
50 \newcommand{\RFC}{\NAME{RFC}} | |
51 \newcommand{\GNU}{\NAME{GNU}} | |
52 \newcommand{\unix}{\name{Unix}} | |
53 \newcommand{\freesw}{Free Software} | |
54 \newcommand{\gpl}{General Public License} | |
55 \newcommand{\GPL}{\NAME{GPL}} | |
56 \newcommand{\SMTP}{\NAME{SMTP}} | |
57 \newcommand{\TLS}{\NAME{TLS}} | |
58 \newcommand{\TODO}{\NAME{TODO}\,} | |
59 \newcommand{\RF}{\NAME{RF}\,} | |
60 \newcommand{\RG}{\NAME{RG}\,} | |
61 \newcommand{\RA}{\NAME{RA}\,} | |
62 \newcommand{\St}{\NAME{S}\,} | |
63 | |
64 \newcommand{\nth}{\textsuperscript{th}} | |
65 \newcommand{\st}{\textsuperscript{st}} | |
66 \newcommand{\nd}{\textsuperscript{nd}} | |
67 \newcommand{\rd}{\textsuperscript{rd}} | |
102 | 68 |
103 | 69 |
104 \newenvironment{code}[2] { | |
105 \begin{center} | |
106 \lstset{label=#1,caption=#2} | |
107 \begin{list}{}{\setlength{\rightmargin}{2em}\setlength{\leftmargin}{2em}} | |
108 \item\ttfamily\footnotesize | |
109 }{ | |
110 \end{list} | |
111 \end{center} | |
112 } | |
113 | 70 |
71 \newcommand{\codeinput}[1]{ | |
72 \begin{quote} | |
73 \ttfamily\footnotesize | |
74 \verbatiminput{#1} | |
75 \end{quote} | |
76 } | |
114 | 77 |