1
0
Files
bachelor-thesis/main.tex
T

244 lines
6.0 KiB
TeX

% font size
\documentclass[12pt]{report}
% Margini (2.5cm su tutti i lati)
\usepackage[top=2.5cm, bottom=2.5cm, left=2.5cm, right=2.5cm, head=21.75pt, centering]{geometry}
% Interlinea
\linespread{1.5}
% Lingua e codifica
\usepackage[italian]{babel}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
% Stile ClassicThesis
\usepackage{newpxtext, newpxmath}
\usepackage{microtype}
\usepackage{parskip} % no indent
% Pagina e intestazioni
\usepackage{scrlayer-scrpage}
\ifoot[]{}
\cfoot[]{}
\ofoot[\pagemark]{\pagemark}
\pagestyle{scrplain}
% Colori generali
\usepackage{xcolor}
\definecolor{unimorered}{RGB}{237, 77, 45}
\definecolor{unimoregrey}{RGB}{84, 84, 84}
\definecolor{unimoreblack}{RGB}{0, 0, 0}
\definecolor{unimorewhite}{RGB}{255, 255, 255}
\definecolor{urlblue}{RGB}{0, 0, 238}
% Colori codice
\definecolor{lightgray}{rgb}{.9,.9,.9}
\definecolor{darkgray}{rgb}{.4,.4,.4}
\definecolor{purple}{rgb}{0.65, 0.12, 0.82}
\definecolor{green}{rgb}{0,0.6,0}
\definecolor{grey}{rgb}{0.5,0.5,0.5}
\definecolor{mauve}{rgb}{0.58,0,0.82}
\definecolor{backcolour}{rgb}{0.95,0.95,0.92}
\usepackage[hidelinks]{hyperref}
\hypersetup{
colorlinks=true,
linkcolor=unimoreblack,
filecolor=unimoreblack,
citecolor=unimoreblack,
urlcolor=urlblue,
}
% Immagini e tabelle
\usepackage{graphicx}
\usepackage{subcaption}
\usepackage{adjustbox}
\usepackage{booktabs}
\usepackage{makecell}
\usepackage{multirow}
\usepackage{float}
% Formattazione titoli
\usepackage{titlesec}
\titleformat{\chapter}[display]
{\normalfont\huge\bfseries\color{unimoreblack}}
{\chaptertitlename\ \thechapter}
{20pt}
{\Huge\color{unimoreblack}}
\titlespacing*{\chapter}{0pt}{-20pt}{40pt}
\titleformat{\section}
{\normalfont\Large\bfseries\color{unimoreblack}}
{\thesection}
{1em}
{}
\titlespacing*{\section}{0pt}{3.25ex plus 1ex minus .2ex}{1.5ex plus .2ex}
\titleformat{\subsection}
{\normalfont\large\bfseries\color{unimoreblack}}
{\thesubsection}
{1em}
{}
\titlespacing*{\subsection}{0pt}{3.25ex plus 1ex minus .2ex}{1.5ex plus .2ex}
% Citazioni e bibliografia
\usepackage{csquotes}
\usepackage[backend=biber, sorting=nty, defernumbers=true]{biblatex}
\appto{\bibsetup}{\raggedright}
\addbibresource{bibliography.bib}
% Codice e algoritmi
\usepackage{listings}
\usepackage{inconsolata}
\usepackage{algorithm}
\usepackage{algpseudocode}
\usepackage{xurl}
% Utility
\usepackage{verbatim}
\usepackage{filehook}
\usepackage{pifont}
\usepackage[bottom]{footmisc}
\usepackage{enumitem}
\usepackage{tikz}
\usetikzlibrary{calc}
% Stili per i linguaggi di programmazione
\lstdefinelanguage{MyPython}{
language=Python,
morekeywords={with, as},
keywordstyle=\bfseries\color{blue},
commentstyle=\color{green},
stringstyle=\color{mauve},
backgroundcolor=\color{backcolour},
basicstyle=\footnotesize\ttfamily,
showstringspaces=false,
numbers=left,
numberstyle=\footnotesize,
numbersep=9pt,
tabsize=2,
breaklines=true,
showtabs=false,
captionpos=t
}
\lstdefinelanguage{C}{
language=C,
morekeywords={with, as},
keywordstyle=\bfseries\color{blue},
commentstyle=\color{green},
stringstyle=\color{mauve},
backgroundcolor=\color{backcolour},
basicstyle=\footnotesize\ttfamily,
showstringspaces=false,
numbers=left,
numberstyle=\footnotesize,
numbersep=9pt,
tabsize=2,
breaklines=true,
showtabs=false,
captionpos=t
}
\lstdefinestyle{bash}{
basicstyle=\ttfamily\small,
rulesepcolor=\color{black},
language=bash,
breaklines=true,
backgroundcolor=\color{backcolour},
literate={"}{{\texttt{"}}}{1},
numbers=left,
numberstyle=\footnotesize,
numbersep=9pt,
columns=fixed,
keepspaces=true,
}
\lstdefinestyle{Prompt}{
breaklines=true,
basicstyle=\ttfamily,
}
\lstdefinestyle{Myyaml}{
basicstyle=\ttfamily\small,
breaklines=true,
numbers=left,
numberstyle=\footnotesize,
numbersep=9pt,
showstringspaces=false,
tabsize=2,
backgroundcolor=\color{backcolour},
columns=fixed,
keepspaces=true,
}
\usepackage{enumitem}
\begin{document}
\begin{titlepage}
% UniMore color accent line
{\color{unimorered}\rule{\textwidth}{2pt}}
\begin{center}
\includegraphics[width=8cm]{assets/images/unimore/Sigillo2015.png}
\vspace{1cm}
{\LARGE\color{unimoregrey}{ UNIVERSITÀ DEGLI STUDI DI MODENA \\E REGGIO EMILIA \\}}
{\large\color{unimoregrey}{ Dipartimento di Ingegneria "Enzo Ferrari" \\}}
{\large\color{unimoregrey}{ Corso di Laurea Triennale in Ingegneria del Veicolo (L-??) \\}}
\vspace{3cm}
{\Large\color{unimoreblack}{ \textbf{<Titolo dell'Elaborato>} }}\\
\vspace{3cm}
\end{center}
\begin{minipage}[t]{0.47\textwidth}
{\large\color{unimoregrey}{\bf Tutor:}\\}
{\large\color{unimoreblack}{Prof. <Nome Cognome>}}
\end{minipage}\hfill\begin{minipage}[t]{0.47\textwidth}\raggedleft
{\large\color{unimoregrey}{\bf Candidato:}\\}
{\large\color{unimoreblack}{<Nome Cognome>}\\}
{\large\color{unimoreblack}{Matricola <matricola>}}
\end{minipage}
\vfill
{\color{unimorered}\rule{\textwidth}{1pt}}
\hrulefill\\
\centering{\large\color{unimoregrey}{\bf ANNO ACCADEMICO 20XX/20XX }}
\end{titlepage}
\clearpage
\pagenumbering{roman}
\tableofcontents % Genera l'Indice
\renewcommand{\listfigurename}{Elenco delle Figure}
\listoffigures % Genera la Lista delle Figure
\renewcommand{\lstlistingname}{Codice}
\renewcommand{\lstlistlistingname}{Elenco dei Codici}
\lstlistoflistings % Genera la Lista dei Codici
\clearpage
\pagestyle{scrplain}
\pagenumbering{arabic}
% Aggiungi qui i capitoli
\input{chapters/01_introduction.tex}
%\input{chapters/02_second_chapter.tex}
%\input{chapters/03_third_chapter.tex}
\input{chapters/05_conclusions.tex}
\clearpage
\addcontentsline{toc}{chapter}{Riferimenti}
\printbibliography[heading=subbibliography, title=Bibliografia]
\nocite{*}
\end{document}