%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Documentclass %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[paper=a4, fontsize=12pt, listof=totoc, twoside, titlepage, openright]{scrbook}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Packages %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage[english]{babel} %ngerman
\usepackage[backend=biber, style=alphabetic, isbn=false, url=true]{biblatex}
\usepackage[babel, german=guillemets]{csquotes}
\usepackage{geometry}
\usepackage[acronym, toc, nomain, nopostdot, nonumberlist, style=super]{glossaries}
\usepackage{graphicx}
\usepackage[colorlinks=true, linkcolor=blue, urlcolor=blue, citecolor=blue, anchorcolor=blue]{hyperref} % NOTE: DIGITAL version
% \usepackage[hidelinks, unicode]{hyperref} % for the printed version % NOTE: PRINTED version
\usepackage[automark, headsepline]{scrlayer-scrpage}%,footsepline,markcase=upper
\usepackage{setspace}
\usepackage{siunitx}
\usepackage{tikz}
%%% Debug %%%
\usepackage{blindtext}
% \usepackage{showframe}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Package Setups %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% biblatex %%%
\addbibresource{bibliography/books.bib}
\addbibresource{bibliography/online.bib}
\addbibresource{bibliography/papers.bib}
\addbibresource{bibliography/thesis.bib}
\addbibresource{bibliography/AgentSoftwareFramework.bib}
%%% glossaries %%%
\loadglsentries{others/acronyms.tex}
\loadglsentries{others/symbols.tex}
\makeglossaries
%%% geometry %%%
% \geometry{a4paper,top=35mm,bottom=35mm,left=30mm,right=30mm} % NOTE: DIGITAL version
\geometry{a4paper,top=35mm,bottom=35mm,left=25mm,right=25mm} % NOTE: PRINTED version
\geometry{bindingoffset=1cm}  % NOTE: PRINTED version
%%%% graphicx %%%
\graphicspath{{graphics/}}
%%% scrlayer-scrpage %%%
\ihead{\headmark}
\ohead{\pagemark}
\ofoot{}
%%% siunitx %%%
\sisetup{detect-all=true}
%\sisetup{locale = DE}
%%% tikz %%%
\usetikzlibrary{arrows.meta}
\usetikzlibrary{automata} % FSM
\usetikzlibrary{backgrounds}
\usetikzlibrary{calc}
\usetikzlibrary{chains}
\usetikzlibrary{intersections}
% \usetikzlibrary{mindmap}
\usetikzlibrary{positioning}
\usetikzlibrary{shadows}
\usetikzlibrary{shapes,
  shapes.arrows,
  shapes.gates.logic.US,
  shapes.gates.logic.IEC,
  shapes.geometric,
  shapes.symbols,
  shapes.multipart,
  shapes.misc}%

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}

  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Preamble %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  \include{others/titlepage}
  \frontmatter
  \include{others/acknowledgments}
  \tableofcontents
  \cleardoublepage
  \printglossaries
  \cleardoublepage
  \listoftables
  \cleardoublepage
  \listoffigures
  \cleardoublepage

  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Content %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  \mainmatter
  \onehalfspacing
  % \includeonly{chapters/chapter1}
  \include{chapters/introduction}
  \blindtext[25]

  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Bibliography %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  \printbibliography[heading=bibintoc]

  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Appendix %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  % \appendix
  % \include{others/appendix}

  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Postamble %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  % \backmatter
  % \printglossaries
  % \cleardoublepage
  % \listoftables
  % \cleardoublepage
  % \listoffigures

\end{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
