Templates

UCY MME Diploma Thesis

Preview

UCY MME Diploma Thesis

LaTeX thesis template for undergraduate students of the Department of Mechanical and Manufacturing Engineering at the University of Cyprus, for MME 405 and MME 406.

Category

university

License

Free to use (MIT)

File

thesis.tex

thesis.texRead-only preview
% ======================================================================
%   University of Cyprus – Thesis Template
%   Greek main language
%   Compile with XeLaTeX
% ======================================================================

\documentclass[12pt,a4paper]{report}

% ------------------ Language & fonts ------------------
\usepackage{fontspec}
\usepackage[main=greek,english]{babel}

% Main thesis font
% Uses Times New Roman if available; otherwise falls back to TeX Gyre Termes.
\IfFontExistsTF{Times New Roman}
  {\setmainfont{Times New Roman}}
  {\setmainfont{TeX Gyre Termes}}

% ------------------ Packages ------------------
\usepackage{graphicx}
\usepackage{geometry}
\usepackage{setspace}
\usepackage[explicit]{titlesec}
\usepackage{caption}
\usepackage{xcolor}
\usepackage{fancyhdr}
\usepackage[normalem]{ulem}
\usepackage{microtype}
\usepackage[hidelinks]{hyperref}
\usepackage{float}
\usepackage{cite}
\usepackage{amsmath}
\usepackage{tikz}
\usetikzlibrary{calc}
\usepackage{comment}
\usepackage{pgffor}

% ------------------ Student / Thesis Information ------------------
\input{student_info}

% ------------------ Colors ------------------
\definecolor{footergray}{gray}{0.5}

% ------------------ Page setup ------------------
\geometry{
  left=3cm,
  right=2.5cm,
  top=2.5cm,
  bottom=2.5cm
}

\onehalfspacing
\setlength{\parindent}{1.25cm}
\setlength{\headheight}{14pt}

% ======================================================================
% HEADER & FOOTER — MAIN MATTER
% ======================================================================

\pagestyle{fancy}
\fancyhf{}

\fancyhead[R]{\fontsize{10}{12}\selectfont\color{footergray}\thepage}

\fancyfoot[L]{\fontsize{10}{12}\selectfont\color{footergray}\StudentName}
\fancyfoot[R]{\fontsize{10}{12}\selectfont\color{footergray}\ThesisType}

\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0.4pt}
\renewcommand{\footrule}{%
  {\color{gray!50}\hrule width\headwidth height\footrulewidth}
}

\fancypagestyle{plain}{
  \fancyhf{}
  \fancyhead[R]{\fontsize{10}{12}\selectfont\color{footergray}\thepage}
  \fancyfoot[L]{\fontsize{10}{12}\selectfont\color{footergray}\StudentName}
  \fancyfoot[R]{\fontsize{10}{12}\selectfont\color{footergray}\ThesisType}
  \renewcommand{\headrulewidth}{0pt}
  \renewcommand{\footrulewidth}{0.4pt}
}

% ======================================================================
% FRONT MATTER PAGINATION — ROMAN, FOOTER ONLY
% ======================================================================

\fancypagestyle{romanstyle}{
  \fancyhf{}
  \fancyfoot[C]{\thepage}
  \renewcommand{\headrulewidth}{0pt}
  \renewcommand{\footrulewidth}{0pt}
}

% ======================================================================
% CHAPTER FORMAT — NUMBERED CHAPTERS
% ======================================================================

\titleformat{\chapter}[display]
  {\bfseries\itshape\centering}
  {%
    \vspace*{0.8cm}
    \hrule height 0.8pt
    \vspace{0.5pt}
    \hrule height 0.8pt
    \vspace{0.5em}
    \Large \ChapterWord\ \thechapter
    \vspace{0.5em}
    \hrule height 0.8pt
    \vspace{0.5pt}
    \hrule height 0.8pt
  }
  {0em}
  {\raggedleft\bfseries\large #1}

\titlespacing*{\chapter}{0pt}{0pt}{2.2em}

% ======================================================================
% CHAPTER FORMAT — UNNUMBERED CHAPTERS
% ======================================================================

\titleformat{name=\chapter,numberless}[display]
  {\bfseries\itshape\centering}
  {%
    \vspace*{0cm}
    \hrule height 0.8pt
    \vspace{0.5pt}
    \hrule height 0.8pt
  }
  {-1em}
  {%
    \bfseries\Large #1
    \vspace{0.5em}
    \hrule height 0.8pt
    \vspace{0.5pt}
    \hrule height 0.8pt
    \vspace*{-1cm}
  }

% ======================================================================
% SECTION FORMAT
% ======================================================================

\titleformat{\section}[hang]
  {\Huge\bfseries}
  {\thesection}
  {0.8em}
  {\parbox[t]{0.85\textwidth}{\raggedright\uline{#1}}}

\titlespacing*{\section}{0pt}{1.2em}{0.6em}

% ======================================================================
% CAPTIONS
% ======================================================================

\captionsetup{
  font=small,
  labelfont=bf,
  labelsep=colon,
  justification=centering
}

% ======================================================================
% DOCUMENT
% ======================================================================

\begin{document}

% =========================
% TITLE PAGE
% =========================

\begin{titlepage}
\thispagestyle{empty}

% ---- Full-page frame ----
\begin{tikzpicture}[remember picture,overlay]
  \draw[line width=0.8pt]
    ($(current page.north west)+(2cm,-2cm)$)
    rectangle
    ($(current page.south east)+(-2cm,2cm)$);
\end{tikzpicture}

\begin{center}
    \textbf{\LARGE \UniversityName}\\[1cm]

    \IfFileExists{\LogoPath}
    {
      \includegraphics[width=0.2\textwidth]{\LogoPath}\\[1cm]
    }
    {
      \vspace{2cm}
    }

    {\Large \ThesisType}\\[2cm]

    {\LARGE \textbf{\ThesisTitle}}\\[6cm]

    \large \StudentName\\[0.5cm]

    \textbf{\large \DepartmentName}\\[2cm]

    \ThesisDate
\end{center}

\end{titlepage}

% =========================
% DECLARATION
% =========================

\clearpage
\thispagestyle{empty}
\vspace*{0cm}

\begin{center}
    \textbf{\Large \UniversityName}\\
    \textbf{\Large \DepartmentName}\\[3cm]

    {\large \ThesisTitle}\\[3cm]

    \StudentName\\[2cm]

    \underline{\SupervisorLabel}\\
    \SupervisorName\\[6cm]

    \DeclarationText\\[2cm]

    \ThesisDate
\end{center}

% =========================
% FRONT MATTER
% =========================

\clearpage
\pagenumbering{roman}
\pagestyle{romanstyle}

% Make chapter-start pages in front matter use roman style
\fancypagestyle{plain}{
  \fancyhf{}
  \fancyfoot[C]{\thepage}
  \renewcommand{\headrulewidth}{0pt}
  \renewcommand{\footrulewidth}{0pt}
}

\chapter*{\AcknowledgementsTitle}
\phantomsection
\addcontentsline{toc}{chapter}{\AcknowledgementsTitle}
\IfFileExists{text/acknowledgements.tex}
  {\input{text/acknowledgements}}
  {Πρόσθεσε εδώ τις ευχαριστίες.}

\thispagestyle{romanstyle}

\chapter*{\AbstractTitle}
\phantomsection
\addcontentsline{toc}{chapter}{\AbstractTitle}
\IfFileExists{text/abstract.tex}
  {\input{text/abstract}}
  {Πρόσθεσε εδώ την περίληψη.}

\thispagestyle{romanstyle}

\tableofcontents
\thispagestyle{romanstyle}

\listoffigures
\thispagestyle{romanstyle}
\phantomsection
\addcontentsline{toc}{chapter}{\listfigurename}

% Uncomment if you need a list of tables
% \listoftables
% \thispagestyle{romanstyle}
% \phantomsection
% \addcontentsline{toc}{chapter}{\listtablename}

% Restore normal plain style for main chapters
\fancypagestyle{plain}{
  \fancyhf{}
  \fancyhead[R]{\fontsize{10}{12}\selectfont\color{footergray}\thepage}
  \fancyfoot[L]{\fontsize{10}{12}\selectfont\color{footergray}\StudentName}
  \fancyfoot[R]{\fontsize{10}{12}\selectfont\color{footergray}\ThesisType}
  \renewcommand{\headrulewidth}{0pt}
  \renewcommand{\footrulewidth}{0.4pt}
}

% =========================
% MAIN BODY
% =========================

\titleformat{\section}[hang]
  {\large\bfseries}
  {\thesection}
  {0.8em}
  {\uline{#1}}

\titlespacing*{\section}{0pt}{1.2em}{0.6em}

\clearpage
\pagenumbering{arabic}
\setcounter{page}{1}
\pagestyle{plain}

% =========================
% CHAPTERS
% =========================

\foreach \n in {1,...,\NumberOfChapters}{
    \chapter{\ChapterTitle{\n}}

    \edef\ChapterFile{text/chapter\n.tex}
    \IfFileExists{\ChapterFile}
      {\input{\ChapterFile}}
      {Πρόσθεσε εδώ το περιεχόμενο του κεφαλαίου \n.}
}

% =========================
% REFERENCES
% =========================
\clearpage
\phantomsection
\addcontentsline{toc}{chapter}{\BibliographyTitle}
\renewcommand{\bibname}{\BibliographyTitle}

\nocite{*}

\bibliographystyle{\BibliographyStyle}
\bibliography{\ReferencesFile}

% =========================
% APPENDICES
% =========================

\clearpage
\input{text/appendix}

\end{document}
Preview
UCY MME Diploma Thesis preview
UCY MME Diploma Thesis LaTeX Template | Bibby | Bibby AI