-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpreamble.tex
242 lines (197 loc) · 7.29 KB
/
preamble.tex
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
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
% ##################################################
% ENCODING
% ##################################################
\usepackage{cmap} % PDF character encoding
\usepackage[T1]{fontenc} % 8-bit font encoding
\usepackage[utf8]{inputenc} % UTF-8 input encoding
% OWN STUFF
\newcommand{\code}[1]{\texttt{#1}}
\usepackage{amsmath}
\usepackage{physics}
\usepackage{siunitx}[=v2]
\usepackage{subcaption}
\usepackage{nicefrac}
\usepackage[british]{babel}
\usepackage{floatrow}
\sisetup{
locale = DE,
separate-uncertainty
}
\DeclareSIUnit\eVperc{\eV\per\clight}
\DeclareSIUnit\clight{\text{\ensuremath{c}}}
\usepackage{todonotes}
\setuptodonotes{inline}
% ##################################################
% DOCUMENT VARIABLES
% ##################################################
% Personal data
\newcommand{\docAuthor}{Andrea Ernst}
\newcommand{\docMatriculationNumber}{588404}
% Document data
\newcommand{\docSupervisor}{Prof. Dr. Heiko Lacker}
\newcommand{\docCoSupervisor}{Prof. Dr. Cigdem Issever}
\newcommand{\docDeadline}{05.10.2021}
% ##################################################
% GENERAL
% ##################################################
\usepackage{scrhack} % better KOMA adaptions
\usepackage{xcolor} % color support
\usepackage{chngcntr} % for renumbering stuff
% ##################################################
% PDF SETTINGS
% ##################################################
\usepackage[
colorlinks=false,
linkcolor=black,
color=black,
filecolor=black,
urlcolor=black,
bookmarks=true,
bookmarksopen=true,
bookmarksopenlevel=3,
bookmarksnumbered,
plainpages=false,
pdfpagelabels=true,
hyperfootnotes,
pdfauthor={\docAuthor},
pdfcreator={\docAuthor}
]{hyperref}
% ##################################################
% FONTS AND SPACING
% ##################################################
\renewcommand{\familydefault}{\sfdefault} % default font
\usepackage[onehalfspacing]{setspace} % default 1.5 spacing
\raggedbottom % don't stretch spacing to fit page length
% font sizes and styles
\addtokomafont{chapter}{\sffamily\large\bfseries}
\addtokomafont{section}{\sffamily\normalsize\bfseries}
\addtokomafont{subsection}{\sffamily\normalsize\mdseries}
\addtokomafont{caption}{\sffamily\normalsize\mdseries}
% url font style
\usepackage{relsize}
\renewcommand*{\UrlFont}{\ttfamily\smaller\relax}
% ##################################################
% PAGE FORMATTING
% ##################################################
% Page layout
\usepackage[
% bindingoffset=1cm,
inner=3.5cm,
outer=3.5cm,
top=3cm,
bottom=2cm
]{geometry}
% Page header
\usepackage[
headsepline, % seperator line beneath page header on normal pages
plainheadsepline % seperator line beneath page header on pages like ToC
]{scrlayer-scrpage}
\clearpairofpagestyles % clear default settings
\addtokomafont{pagehead}{\normalfont} % use normal font for page header
\ohead*{\thepage} % page number
\ihead*{\leftmark} % chapter name
% ##################################################
% IMAGES AND FIGURES
% ##################################################
\usepackage{graphicx} % support for including images
\graphicspath{{pictures/}} % default path
% simple numbering without chapter
\renewcommand{\thefigure}{\arabic{figure}}
\counterwithout{figure}{chapter}
% ##################################################
% TABLES
% ##################################################
\usepackage{booktabs} % beautiful table style
\usepackage{multirow} % multi row and multi column table functionality
% simple numbering without chapter
\renewcommand{\thetable}{\arabic{table}}
\counterwithout{table}{chapter}
% ##################################################
% SOURCE CODE LISTINGS
% ##################################################
\usepackage{listings}
\usepackage{beramono} % use a typewriter font which supports bold characters
\renewcommand{\lstlistlistingname}{List of Code Listings} %
\renewcommand{\lstlistingname}{Code Listing}
\newcommand{\listoflolentryname}{\lstlistingname} % prefix for List of Code Listings
% define colors for source code highlighting
\definecolor{codegreen}{rgb}{0,0.6,0}
\definecolor{codegray}{rgb}{0.5,0.5,0.5}
\definecolor{codepurple}{rgb}{0.5,0,0.33}
\definecolor{codepurblue}{rgb}{0.16,0.0,1.0}
\definecolor{backcolour}{rgb}{0.95,0.95,0.92}
% set source code style
\lstdefinestyle{codestyle}{
backgroundcolor=\color{backcolour},
commentstyle=\color{codegreen},
keywordstyle=\bfseries\color{codepurple},
numberstyle=\tiny\color{codegray},
stringstyle=\color{codepurblue},
basicstyle=\scriptsize\ttfamily,
breakatwhitespace=false,
breaklines=true,
captionpos=b,
keepspaces=true,
numbers=left,
numbersep=5pt,
showspaces=false,
showstringspaces=false,
showtabs=false,
tabsize=2,
escapeinside={(*@}{@*)}
}
\lstset{style=codestyle, numberbychapter=false}
% ##################################################
% TABLE OF CONTENTS
% ##################################################
\KOMAoptions{toc=chapterentrydotfill} % dotted lines for chapters
%\addtokomafont{chapterentry}{\normalfont} % use normal font for chapter entries
% spacing
%\DeclareTOCStyleEntry[beforeskip=0cm]{chapter}{chapter}
%\DeclareTOCStyleEntry[beforeskip=0cm]{section}{section}
%\DeclareTOCStyleEntry[beforeskip=0cm]{default}{subsection}
%
%% colons after entry names
%\BeforeStartingTOC[lof]{\def\autodot{:}}
%\BeforeStartingTOC[lot]{\def\autodot{:}}
%\BeforeStartingTOC[lol]{\def\autodot{:}}
% ##################################################
% BIBLIOGRAPHY
% ##################################################
\usepackage{csquotes}
\usepackage[backend=biber,bibstyle=ieee, citestyle=numeric-comp]{biblatex}
\addbibresource{./BA.bib}
\addbibresource{SHIP-proposal.bib}
\addbibresource{ZINTH.bib}
\addbibresource{SPECTRAL-SEMICONDUCTOR.bib}
\setlength\bibitemsep{.5\baselineskip}
\setcounter{biburlnumpenalty}{9000} % break URLs on numbers
\setcounter{biburllcpenalty}{9000} % break URLs on lower case letters
\setcounter{biburlucpenalty}{9000} % break URLs on upper case letters
% ##################################################
% ABBREVIATIONS
% ##################################################
\usepackage[printonlyused]{acronym}
% ##################################################
% APPENDIX
% ##################################################
\usepackage[title,titletoc]{appendix}
% appendix chapter
\newcommand{\appendixchapter}[1]{
\cleardoublepage
\pagenumbering{arabic}
\renewcommand{\thepage}{\thechapter-\arabic{page}}
\chapter{#1}
}
% insert monthly report pdf as picture in order to keep page header
\newcommand{\monthlyreport}[2]{
\section{#1}
\centering
\includegraphics[trim=55 35 55 35,clip,width=1\textwidth]{#2}
\clearpage
}
% ##################################################
% MISC
% ##################################################
% better referencing of images, tables, etc.
\usepackage[nameinlink, noabbrev]{cleveref}