main.tex.php 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. \documentclass[paper=a4,fontsize=11pt,twoside,titlepage,parskip=half-,openright]{scrbook}
  2. \usepackage[paperwidth=15.5cm,
  3. paperheight=23.5cm,
  4. lmargin = 2.1cm,
  5. rmargin = 1.2cm,
  6. top = 2.2cm,
  7. headsep = 0.6cm,
  8. textheight = 19.3cm,
  9. footskip = 1.0cm]{geometry}
  10. \usepackage{tugraz_defaults}
  11. \usepackage{moresize}
  12. \usepackage{pdfpages}
  13. \usepackage{enumitem}
  14. \usepackage{mdframed}
  15. \usepackage[breakable, theorems, skins]{tcolorbox}
  16. \usepackage[backend=biber,
  17. url=true,
  18. style=numeric,
  19. giveninits=false,
  20. maxnames=32,
  21. minnames=32,
  22. maxcitenames=2,
  23. mincitenames=1,
  24. backref=true, %
  25. ]{biblatex}
  26. \addbibresource{main.bib}
  27. <?php
  28. foreach ($bibresources as $br => $bib)
  29. {
  30. echo '\addbibresource{'.$bib.'}
  31. ';
  32. }
  33. if (isset($options["--cv"]))
  34. echo '\addbibresource{cv.bib}
  35. ';
  36. ?>
  37. \DeclareFieldFormat*{title}{#1}
  38. \DeclareFieldFormat*{booktitle}{#1}
  39. \DeclareFieldFormat*{journaltitle}{#1}
  40. \newcommand{\itemcite}[1]{\begin{itemize}\item \fullcite{#1}\end{itemize}}
  41. \usepackage{graphicx}
  42. \usepackage[openbib,NoDate]{currvita}
  43. \preto\fullcite{\AtNextCite{\defcounter{maxnames}{99}}}
  44. \usepackage{scrhack}
  45. \usepackage{quotchap} %
  46. \DefineBibliographyStrings{english}{%
  47. backrefpage = {p.},%
  48. backrefpages = {pp.},%
  49. }
  50. \usepackage[titles]{tocloft}
  51. \renewcommand\cftchapaftersnum{.}
  52. \setlength{\cftchapnumwidth}{2em}
  53. \makeatletter
  54. \frenchspacing
  55. \widowpenalty=10000
  56. \clubpenalty=10000
  57. \setcounter{tocdepth}{1}
  58. \renewenvironment{table}
  59. {\setlength\abovecaptionskip{0\p@}%
  60. \setlength\belowcaptionskip{10\p@}%
  61. \@float{table}}
  62. {\end@float}
  63. \makeatother
  64. \makeatletter
  65. \def\cleardoublepage{\clearpage\if@twoside \ifodd\c@page\else
  66. \hbox{} \vspace*{\fill}
  67. \begin{center}
  68. \end{center}
  69. \vspace{\fill} \thispagestyle{empty}
  70. \newpage
  71. \if@twocolumn\hbox{}\newpage\fi\fi\fi}
  72. \makeatother
  73. \usepackage{titling}
  74. \usepackage[english]{babel}
  75. \addto{\captionsenglish}{\renewcommand*{\appendixname}{Appendix}}
  76. \renewcommand{\algorithmautorefname}{Algorithm}
  77. \renewcommand\itemautorefname{Step}
  78. \renewcommand\chapterautorefname{Chapter}
  79. \renewcommand\sectionautorefname{Section}
  80. \renewcommand\subsectionautorefname{Section}
  81. \renewcommand\subsubsectionautorefname{Section}
  82. \usepgfplotslibrary{dateplot}
  83. \usepgfplotslibrary{fillbetween}
  84. \hyphenation{}
  85. \usepackage{chngcntr}
  86. \addtokomafont{disposition}{\rmfamily}
  87. \usepackage{mypreamble}
  88. \begin{document}
  89. %\includepdf[pages=-]{front.pdf}
  90. \frontmatter
  91. %\counterwithin{lstlisting}{section}
  92. \counterwithin{listing}{section}
  93. \title{<?php echo $thesis_title ?>}
  94. \author{<?php echo $thesis_author ?>}
  95. \date{<?php echo $thesis_date ?>}
  96. %\pagenumbering{gobble}
  97. \newcommand{\tugsq}{\raisebox{0.5ex}{\tikzset{external/export next=false}\tikz{\fill (0,0) rectangle (0.5ex,0.5ex);}}}
  98. \sodef\so{}{0.45em}{1.4em}{0em}
  99. \begin{titlepage}%
  100. \pagestyle{empty}
  101. \tikzset{external/export next=false}
  102. \begin{tikzpicture}[remember picture,overlay]
  103. \node at (current page.south west){
  104. \tikzset{external/export next=false}
  105. \begin{tikzpicture}[remember picture, overlay]
  106. \fill[white] (0,0) rectangle (\paperwidth,\paperheight);
  107. \shade[shading=axis,bottom color=black!35,top color=white]
  108. (0,0) rectangle (\paperwidth,0.92\paperheight);
  109. \node[anchor=south west,inner sep=0pt] at (-2.8,1) {\includegraphics[width=152.5mm]{figures/background.png}};
  110. \end{tikzpicture}};
  111. \node at (current page.south east){
  112. \tikzset{external/export next=false}
  113. \begin{tikzpicture}[remember picture, overlay]
  114. \node[anchor=north east] at ($({\paperwidth-19cm},1)$) {
  115. \color{black}\fontsize{9}{9}\selectfont\so{\sffamily SCIENCE \tugsq{} PASSION \tugsq{} TECHNOLOGY}
  116. };
  117. \node [anchor=north east] at ($({\paperwidth-16cm},1.4)$) {\resizebox{1in}{!}{
  118. \includegraphics{figures/TU_Graz_Logo}
  119. }};
  120. \end{tikzpicture}};
  121. \node at (current page.east){
  122. \begin{tikzpicture}[remember picture, overlay]
  123. \node[anchor=east,xshift=-1.075cm,yshift=-3.6cm] (inst) {
  124. \color{black}\sffamily <?php echo $thesis_institute ?>
  125. };
  126. \node[below=of inst.east,anchor=east,yshift=0.4cm] {\sffamily Graz University of Technology};
  127. \end{tikzpicture}};
  128. \end{tikzpicture}
  129. \vspace{1cm}
  130. {\sffamily\large\noindent
  131. \theauthor}
  132. \vspace{0.15cm}
  133. \hrule
  134. \vspace{0.3cm}
  135. {\sffamily\huge\noindent \thetitle}
  136. \vspace{0.2cm}
  137. \hrule
  138. \vspace{2cm}
  139. {\sffamily\Large\noindent <?php echo $thesis_type ?>}\\[0.2cm]
  140. {\sffamily\noindent Assessors: <?php echo $thesis_assessors ?>}\\[0.2cm]
  141. {\sffamily\noindent <?php echo $thesis_date ?>}\\[0.2cm]
  142. \vspace{6cm}
  143. \end{titlepage}%
  144. %\pagenumbering{arabic}
  145. \cleardoublepage
  146. \addtocontents{toc}{\vspace*{\baselineskip}}
  147. \addtocontents{toc}{\vspace*{\baselineskip}}
  148. \tikzset{external/export next=true}
  149. \input{abstract}
  150. \cleardoublepage
  151. \tableofcontents
  152. \addcontentsline{toc}{chapter}{Contents}
  153. \cleardoublepage
  154. \mainmatter
  155. \addtocontents{toc}{\vspace*{\baselineskip}}
  156. \part[<?php echo $thesis_part1_title ?>]{<?php echo $thesis_part1_title ?>}
  157. \bgroup
  158. \begin{refsection}
  159. \input{intro}
  160. <?php echo $sloppy_begin; ?>
  161. \printbibliography[title={References}, heading=bibintoc]
  162. <?php echo $sloppy_end; ?>
  163. \end{refsection}
  164. \egroup
  165. \addtocontents{toc}{\vspace*{\baselineskip}}
  166. \cleardoublepage
  167. \part{Publications}
  168. \addtocontents{toc}{\protect\setcounter{tocdepth}{0}}
  169. \renewcommand*\thesection{\arabic{section}}
  170. \bgroup
  171. \begin{refsection}
  172. \chapter*{List of Publications}
  173. \label{sec:publicationlist}
  174. \addcontentsline{toc}{chapter}{List of Publications}
  175. During my thesis, I contributed to <?php echo $num_publications ?> publications in conference proceedings, <?php echo $num_publications_in_thesis ?> of which are included in this thesis as shown below.
  176. \newrefcontext[sorting=ydnt]
  177. \nocite{CV:*}
  178. <?php echo $sloppy_begin; ?>
  179. \printbibliography[title={Publications in this Thesis}, type=inproceedings, heading=subbibliography, keyword={mine}]
  180. \printbibliography[title={Other Contributions}, type=inproceedings, heading=subbibliography, keyword={mine_other}]
  181. <?php echo $sloppy_end; ?>
  182. \end{refsection}
  183. \egroup
  184. <?php
  185. foreach ($papers as $p => $f)
  186. {
  187. echo '
  188. \bgroup
  189. \begin{refsection}
  190. \input{'.$p.'/'.$f.'}
  191. \end{refsection}
  192. \egroup
  193. \newpage
  194. ';
  195. }
  196. ?>
  197. <?php
  198. if (isset($options['--cv']))
  199. {
  200. echo <<<'END'
  201. \cleardoublepage
  202. \appendix
  203. \part*{Appendix}
  204. \addcontentsline{toc}{part}{Appendix}
  205. \addtocontents{toc}{\protect\setcounter{tocdepth}{0}}
  206. \renewcommand*\thesection{\arabic{section}}
  207. \addtocontents{toc}{\vspace*{\baselineskip}}
  208. \chapter*{Curriculum Vitae}
  209. \bgroup
  210. \begin{refsection}
  211. \input{cv}
  212. \end{refsection}
  213. \egroup
  214. \cleardoublepage
  215. \chapter*{Academic Field ``Applied Computer Science''}
  216. \bgroup
  217. \begin{refsection}
  218. \input{academicfield}
  219. \end{refsection}
  220. \egroup
  221. \cleardoublepage
  222. END;
  223. }
  224. ?>
  225. <?php
  226. if (!isset($options['--no-statutory-declaration']))
  227. {
  228. echo <<<'END'
  229. \chapter*{Statutory Declaration}
  230. I declare that I have authored this thesis independently, that I have not used other than the declared sources / resources, and that I have explicitly marked all material which has been quoted either literally or by content from the used sources.
  231. END;
  232. }
  233. ?>
  234. \end{document}