studarbeit.sty 4.64 KB
Newer Older
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
1 2
\usepackage{lmodern}

Andreas Zwinkau's avatar
Andreas Zwinkau committed
3 4
\usepackage{microtype}

Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
5
\usepackage[german]{babel}
6
%\usepackage[german,english]{babel}     % use this if your thesis is in English -- last option specifies the default language
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
7 8 9

\usepackage{tikz}
\usetikzlibrary{positioning,calc,arrows}
Andreas Zwinkau's avatar
Andreas Zwinkau committed
10
\usetikzlibrary{firm}
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
11 12 13 14 15 16 17 18

\usepackage{listings}

\newcommand{\thesistype}[1]{\newcommand{\thethesistype}{#1}}
\newcommand{\zweitgutachter}[1]{\newcommand{\thezweitgutachter}{#1}}
\newcommand{\betreuer}[1]{\newcommand{\thebetreuer}{#1}}
\newcommand{\coverimage}[1]{\newcommand{\thecoverimage}{#1}}

Andreas Zwinkau's avatar
Andreas Zwinkau committed
19 20 21 22
\makeatletter
\newcommand{\myBCOR}{\the\ta@bcor}
\makeatother

Andreas Zwinkau's avatar
moar  
Andreas Zwinkau committed
23
\usepackage{csquotes} % provides \enquote{} macro for "quotes"
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
24 25 26 27 28

\usepackage{amsmath}
\usepackage[labelformat=simple]{subfig}
\usepackage[font={sf},margin=10pt,labelfont=bf]{caption}
\usepackage{booktabs}
Andreas Zwinkau's avatar
moar  
Andreas Zwinkau committed
29 30 31 32 33
\usepackage{hyperref}
\hypersetup{
  pdftitle={TODO},
  pdfdisplaydoctitle=true,
  bookmarks=true,
Andreas Zwinkau's avatar
Andreas Zwinkau committed
34
  %colorlinks=true, % use this if the boxes around links bother you ;)
Andreas Zwinkau's avatar
moar  
Andreas Zwinkau committed
35 36
  pdfstartpage=3,
}
Andreas Zwinkau's avatar
Andreas Zwinkau committed
37
\usepackage{hypcap} % hyperref fix
Andreas Zwinkau's avatar
Andreas Zwinkau committed
38 39
\usepackage[nameinlink,noabbrev]{cleveref} % better references
\crefname{figure}{Abbildung}{Abbildungen}
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
40

Andreas Zwinkau's avatar
Andreas Zwinkau committed
41
% TODO fancyhdr should not be necessary with KOMA script
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
42 43 44 45 46 47 48 49 50 51 52
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhead{} % clear all header fields
\fancyhead[LE,RO]{\slshape \rightmark}
\fancyfoot{} % clear all footer fields
\fancyfoot[LE,RO]{\thepage}

\definecolor{todo}{rgb}{0.8,0,0}
\newcommand\tod[1]{\texttt{\textcolor{todo}{#1}}}
\newcommand\todo[1]{\par\texttt{\textcolor{todo}{#1}}\par}

Andreas Zwinkau's avatar
Andreas Zwinkau committed
53 54
%%% Title Page %%%

Andreas Zwinkau's avatar
Andreas Zwinkau committed
55
\usepackage{titling} % for \thetitle command
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
56 57 58 59 60
\newcommand{\mytitlepage}{
  \begin{titlepage}
    \begin{tikzpicture}[remember picture,overlay]
      % Seitenrahmen zeichnen.
      \draw[semithick,rounded corners=0.5cm]
Andreas Zwinkau's avatar
Andreas Zwinkau committed
61
        ($(current page.north west) + ( 1cm,-1cm) + (\myBCOR,0)$) --
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
62 63 64 65 66
        ($(current page.north east) + (-1cm,-1cm)$) --
        ($(current page.south east) + (-1cm, 1.5cm)$);

      \draw[semithick,rounded corners=0.5cm]
        ($(current page.south east) + (-1cm, 1.5cm)$) --
Andreas Zwinkau's avatar
Andreas Zwinkau committed
67 68
        ($(current page.south west) + ( 1cm, 1.5cm) + (\myBCOR,0)$) --
        ($(current page.north west) + ( 1cm,-1cm) + (\myBCOR,0)$);
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
69 70

      % Logo einbinden.
Andreas Zwinkau's avatar
Andreas Zwinkau committed
71 72
      \node[anchor=north west] (logo) at
        ($(current page.north west) + (1.75cm,-1.5cm) + (\myBCOR,0)$)
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
73 74 75 76 77 78 79 80 81 82 83
      {
        \includegraphics[width=4cm]{KITLogo}
      };

      % Institut / Lehrstuhl.
      \node[anchor=east] at ($(current page.east |- logo.east) + (-1.75cm,0cm)$)
      {
        \begin{minipage}{5.2cm}
          \begin{flushleft}
            \footnotesize{}Institut für Programmstrukturen und Datenorganisation (IPD) \\
            \vspace{6pt}
sebastian.buchwald1's avatar
sebastian.buchwald1 committed
84
            Lehrstuhl Prof.~Dr.-Ing.~Snelting
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
85 86 87 88
          \end{flushleft}
        \end{minipage}
      };

Andreas Zwinkau's avatar
Andreas Zwinkau committed
89
      \node (title) at ($(current page.center |- logo.south) + (\myBCOR/2, -4cm)$)
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108
      {
        % Korrekter Zeilenabstand etc. durch Minipage.
        \begin{minipage}{12cm}
          \begin{center}
            \huge\textbf{\thetitle}
          \end{center}
        \end{minipage}
      };

      \node[below=1.05cm of title.south]   (prename)  { \thethesistype\ von };
      \node[below=0.75cm of prename.south] (name)     { \Large{}\textbf{\theauthor} };
      \node[below=0.8cm  of name.south]    (postname) { an der Fakultät für Informatik };

      \node[below=0.5cm  of postname.south] (bildchen) { \includegraphics[width=0.8\textwidth]{\thecoverimage}
                                                      };

      \node[below=0.4cm of bildchen.south] (table)
      {
        \begin{tabular}{ll}
sebastian.buchwald1's avatar
sebastian.buchwald1 committed
109
          \textbf{Erstgutachter:}           & Prof.~Dr.-Ing.~Gregor~Snelting \\[5pt]
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
110 111 112 113 114 115 116 117
          \textbf{Zweitgutachter:}          & \thezweitgutachter\\[5pt]
          \textbf{Betreuende Mitarbeiter:} & \thebetreuer \\
        \end{tabular}
      };

      \node[below=1.3cm of table.south] (time)
      {
        \begin{tabular}{ll}
sebastian.buchwald1's avatar
sebastian.buchwald1 committed
118
        \textbf{Bearbeitungszeit:} & {\year=1990 \month=1 \day=1 \today} -- {\year=2000 \month=12 \day=31 \today}
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
119 120 121 122 123 124
        \end{tabular}
      };

      % Fußzeile, unten zentriert.
      \node[anchor=south] (footnote) at ($(current page.center |- current page.south) + (0cm, 0.65cm)$)
      {
sebastian.buchwald1's avatar
sebastian.buchwald1 committed
125
        \tiny{}KIT -- Die Forschungsuniversität in der Helmholtz-Gemeinschaft
Andreas Zwinkau's avatar
initial  
Andreas Zwinkau committed
126 127 128 129 130 131
        \hspace{0.5cm}
        \Large{}\textbf{www.kit.edu}
      };
    \end{tikzpicture}
  \end{titlepage}
}
Andreas Zwinkau's avatar
Andreas Zwinkau committed
132 133 134 135 136 137 138 139 140 141 142

%%% TikZ helper %%%

\usetikzlibrary{patterns}
\pgfdeclarelayer{background}
\pgfdeclarelayer{foreground}
\pgfsetlayers{background,main,foreground}

\newcommand{\tikzselect}[3][black!20]{{
  \fill[color=#1] plot[smooth cycle, tension=#2] coordinates{#3} -- cycle;
}}
Andreas Zwinkau's avatar
Andreas Zwinkau committed
143 144

\recalctypearea % necessary if e.g. somebody changes fonts