-
Notifications
You must be signed in to change notification settings - Fork 1
/
preamble.sty
90 lines (72 loc) · 3.37 KB
/
preamble.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
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
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{preamble}[Things which are needed for literally all tex files in this project]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Standard LaTeX settings
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% for pictures etc.
\RequirePackage{graphicx}
% provides \currfiledir used in graphicspath
\RequirePackage[abspath]{currfile}
% for spaces in commands
\RequirePackage{xspace}
% quoting and bibliography
\RequirePackage[backend=biber,style=alphabetic]{biblatex}
\RequirePackage{csquotes}
\emergencystretch=1em % avoid warnings overfull hbox in cite commands
% Multiple rows in tables
\usepackage{multirow}
% figures/subfigures
% hypcap=false disables non-useful warning "Warning: The option hypcap=true will be ignored for this"
\RequirePackage[hypcap=false]{caption}
\RequirePackage[subrefformat=parens]{subfig}
% todonodes: ability to add short annotations for things that still have to be done
\usepackage[colorinlistoftodos,prependcaption,textsize=tiny]{todonotes}
% our own stuff everything maya located maya.sty
\RequirePackage{maya} %
% disable non-useful warning: "PDF inclusion: multiple pdfs with page group included in a single page"
\pdfsuppresswarningpagegroup=1
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Headline and footer
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\RequirePackage{scrlayer-scrpage}
\pagestyle{scrheadings}
\clearpairofpagestyles
\automark[]{chapter}
\ohead[]{\rightmark}
\ofoot[\pagemark]{\pagemark}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Subfiles support
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\RequirePackage{subfiles}
% redefine subfile command to make sure 'maya/img' folder in all sub folders are found
\makeatletter
\let\org@subfile\subfile
\renewcommand*{\subfile}[1]{%
\filename@parse{#1}% LaTeX's file name parser
\expandafter
\graphicspath\expandafter{{maya/}\expandafter{\filename@area img/}}%
\org@subfile{#1}%
}
\makeatother
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% References
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\RequirePackage{hyperref} % creates links in table of contents
\RequirePackage[noabbrev]{cleveref}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Translation support
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% {<page in reference>}{<reference key>}{<original text>}{<translated text>}
\newcommand{\quotemytranslated}[4][]{%
\begin{quote}
#4
\footnote{My translation from (\cite[#1]{#2}): #3}
\end{quote}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Document related
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% note for drawings created by me
\newcommand{\authordrawings}{drawings by Sebastian Bauer}
% get document version
\input{document-version.tex}