-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpreamble.tex
89 lines (88 loc) · 2.79 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
% turn off page header titles
\pagestyle{plain}
% change language to german
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
% better hyphenation
\usepackage[ngerman=ngerman-x-latest]{hyphsubst}
% turn off bibliography at the end of document
\let\pby\printbibliography
\renewcommand{\printbibliography}{}
% footnotes in tables
\usepackage{tablefootnote}
% promille symbol
\usepackage{textcomp}
% move all figures and tables to the end of the document
\usepackage[nomarkers,notables,nofiglist]{endfloat}
\AtBeginFigures{\setcounter{chapter}{0}}
\renewcommand{\figuresection}{Abbildungen}
% change name of list of figures to <empty>
\addto\captionsngerman{
\renewcommand{\listfigurename}{}
}
% fancy headers
\usepackage{fancyhdr}
\pagestyle{fancy}
% section header formatting
%raggedright prevents hyphenation in titles
\usepackage{titlesec}
\titleformat{\chapter}[display]
{\normalfont\huge\bfseries\raggedright}{\chaptertitlename\ \thechapter}{20pt}{\Huge}
\titlespacing*{\chapter}{0pt}{-25pt}{25pt}
\titleformat{\section}[display]{\normalfont\Large\bfseries\raggedright}{\thesection}{0pt}{}
\titleformat{\subsection}[display]{\normalfont\large\bfseries\raggedright}{\thesubsection}{0pt}{}
\titleformat{\subsubsection}[display]{\normalfont\normalsize\bfseries\raggedright}{\thesubsubsection}{0pt}{}
\titleformat{\paragraph}[runin]{\normalfont\normalsize\bfseries\raggedright}{}{0pt}{}
\titleformat{\subparagraph}[runin]{\normalfont\normalsize\bfseries\raggedright}{}{0pt}{}
% figure rotation
\usepackage{pdflscape}
\DeclareDelayedFloatFlavor{landscape}{figure}
% ignore fields in citations
\DeclareSourcemap{
\maps[datatype=bibtex]{
\map{
\step[fieldset=note,null]
\step[fieldset=isbn,null]
\step[fieldset=issn,null]
\step[fieldset=language,null]
\step[fieldset=month,null]
\step[fieldset=publisher,null]
\step[fieldset=pagetotal,null]
}
}
}
% better removal of orphaned and widowed lines
\usepackage[all]{nowidow}
% control footnote margin
\usepackage[hang]{footmisc}
\setlength\footnotemargin{13pt}
% this redefinition is only necessary for the end period
\makeatletter%
\long\def\@makefntext#1{%
\bgroup
\setbox\@tempboxa\hbox{%
\ifdim\footnotemargin>0pt
\hb@xt@\footnotemargin{\@makefnmark\hss}%
\else
\@makefnmark
\fi
}%
\leftmargin\wd\@tempboxa
\rightmargin\z@
\linewidth \columnwidth
\advance \linewidth -\leftmargin
\parshape \@ne \leftmargin \linewidth
\footnotesize
\@setpar{{\@@par}}%
\leavevmode
\llap{\box\@tempboxa}%
\parskip\hangfootparskip\relax
\parindent\hangfootparindent\relax
\footnotelayout#1%
% end every footnote with a period, if it not already has one
% french spacing has to be turned off for this solution to work
\ifnum\the\spacefactor<3000.\fi
\par\egroup
}
\makeatother