preamble.sty 7.15 KB
Newer Older
Alija Sabic's avatar
Alija Sabic committed
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
\NeedsTeXFormat{LaTeX2e}[1994/06/01]
\ProvidesPackage{preamble}[2018/12/08 Document Preamble]

% multi screen mode
\RequirePackage{pgfpages}
% Enable two-screen mode only for notes
\@ifclasswith{beamer}{notes}{\setbeameroption{show notes on second screen=right}}{}

% ----------------------------------------------------------------------------------------------------------------------------
% Theme
% ----------------------------------------------------------------------------------------------------------------------------
\usetheme[%
    % hideothersubsections,%
    toclevel=4,%
    stoclevel=3,%
    style=noir,%
    framewidth=3,%
    right,%
    sidebarwidth=0.23\paperwidth,%
    sidebarnavsep=0.4cm,%
    showframes,%
    noframes,%
    sidebarnavsep=1em,%
    % alert=ttw-violett,%
]{fhtw}%
% \usetheme[style=fhtw-random,sidebarwidth=0.25\paperwidth,,framewidth=3,frameamount=42]{fhtw}
% \usetheme[style=noir,showframes]{fhtw}
% \usetheme[style=noir-bridge]{fhtw}
% \usetheme[style=noir-bridge-color]{fhtw}
% \usetheme[style=bridge]{fhtw}
% \usetheme[style=simple,sidebarwidth=0.2\paperwidth]{fhtw}
% \usetheme[style=complex,gridsize=15,sidebarwidth=0.2\paperwidth]{fhtw}

% ----------------------------------------------------------------------------------------------------------------------------
% Hooks
% ----------------------------------------------------------------------------------------------------------------------------
% \AtEndDocument{\bibliolist{}}
\AtBeginSection[]{%
    \begin{frame}[plain]%
        \frametitle{Section}
        \tableofcontents[sections=\value{section},sectionstyle=show,subsectionstyle=show,subsubsectionstyle=show]%
        \addtocounter{framenumber}{-1}
    \end{frame}%
}

% ----------------------------------------------------------------------------------------------------------------------------
% Bibliography/References
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage[square,numbers,sort]{natbib}
% TODO: provide examples
\RequirePackage{usebib}
\bibinput{references}

\setlength{\bibsep}{1em}
\bibliographystyle{IEEEtranN}
\interfootnotelinepenalty=10000

% ----------------------------------------------------------------------------------------------------------------------------
% Styles & Packages
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage{fhtw}
\RequirePackage{custom}
% \RequirePackage{lipsum}
\RequirePackage{adjustbox}
\RequirePackage{appendixnumberbeamer}

% ----------------------------------------------------------------------------------------------------------------------------
% Paragraph Spacing
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage{parskip}
\setlength{\parskip}{0.5em}

% ----------------------------------------------------------------------------------------------------------------------------
% Captions
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage[skip=0.5em]{caption}
\setlength{\belowcaptionskip}{-1em}

% ----------------------------------------------------------------------------------------------------------------------------
% Floats
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage{newfloat}
\RequirePackage{float}
\SetupFloatingEnvironment{listing}{placement=H}
% \usepackage[compatibility=false]{caption}
% \DeclareFloatingEnvironment[fileext=src,placement={H},name=Listing]{source}
% \captionsetup[source]{type=listing}
% \newenvironment{source}{\captionsetup{format=plain,type=listing}}{}

% ----------------------------------------------------------------------------------------------------------------------------
% Units
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage[binary-units]{siunitx}
\RequirePackage{xfrac}
\sisetup{quotient-mode=fraction,fraction-function=\sfrac,product-units=single,exponent-product=\times}

% ----------------------------------------------------------------------------------------------------------------------------
% Tables
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage{booktabs,tabu}
\RequirePackage{multirow}
\RequirePackage{multicol}

% ----------------------------------------------------------------------------------------------------------------------------
% Hyperlinks
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage{bookmark}
\RequirePackage{hyperref}
\hypersetup{
    % bookmarksopen=true,%
    % bookmarksopenlevel=\beamer@fhtw@toclevel,%
    % colorlinks = false, linkbordercolor = {white}, linkbordercolor = tw-green!50, linkbordercolor = white,
    % anchorcolor= tw-green, anchorcolor= white!0, citebordercolor = tw-gray!50, urlbordercolor = tw-blue!50,
    colorlinks = true,
    anchorcolor = black,
    linkcolor = \primarycolor,
    citecolor = \primarycolor,
    urlcolor = \primarycolor,
}
\setcounter{tocdepth}{\beamer@fhtw@toclevel}

% ----------------------------------------------------------------------------------------------------------------------------
% Acronyms
% ----------------------------------------------------------------------------------------------------------------------------
% \RequirePackage[hyperref=true]{acro}
\RequirePackage[hyperref=true]{custom/acro}
\acsetup{first-long-format=\itshape,extra-style=comma,hyperref=true}
\input{acronyms}

% \RequirePackage{hyperref}
% \hypersetup{
%     % colorlinks = false, linkbordercolor = {white}, linkbordercolor = tw-green!50, linkbordercolor = white,
%     % anchorcolor= tw-green, anchorcolor= white!0, citebordercolor = tw-gray!50, urlbordercolor = tw-blue!50,
%     colorlinks = true,
%     anchorcolor = black,
%     linkcolor = \primarycolor,
%     citecolor = \primarycolor,
%     urlcolor = \primarycolor,
% }


% ----------------------------------------------------------------------------------------------------------------------------
% Languagues
% ----------------------------------------------------------------------------------------------------------------------------
% \RequirePackage[french,german,english]{babel}
\RequirePackage[ngerman,english]{babel}

% ----------------------------------------------------------------------------------------------------------------------------
% Figure
% ----------------------------------------------------------------------------------------------------------------------------
% \RequirePackage{adjustbox}
\setlength{\fboxsep}{0pt}
\setlength{\fboxrule}{0.15mm}

% ----------------------------------------------------------------------------------------------------------------------------
% TikZ
% ----------------------------------------------------------------------------------------------------------------------------
\RequirePackage{tikz}