Advertisement
Guest User

Untitled

a guest
May 11th, 2016
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Latex 5.04 KB | None | 0 0
  1. \documentclass[12pt]{report}
  2. \usepackage[T1]{fontenc}
  3. \usepackage{lmodern}
  4. \usepackage{fancyhdr}
  5. \usepackage{tikz}
  6. \usepackage{amssymb,amsmath}
  7. \usepackage{ifxetex,ifluatex}
  8. \usepackage{fixltx2e} % provides \textsubscript
  9. \usepackage{upquote} % we don't want curly quote
  10. \usepackage{longtable}
  11. \usepackage{titlesec}
  12. \usepackage{xhfill}
  13. \newcommand{\tightlist}{%
  14.   \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
  15.  
  16. % use microtype if available
  17. \IfFileExists{microtype.sty}{\usepackage{microtype}}{}
  18. \ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
  19.   \usepackage[utf8]{inputenc}
  20. $if(euro)$
  21.  \usepackage{eurosym}
  22. $endif$
  23. \else % if luatex or xelatex
  24.   \usepackage{fontspec}
  25.  \ifxetex
  26.    \usepackage{xltxtra,xunicode}
  27.  \fi
  28.  \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
  29.  \newcommand{\euro}{€}
  30. $if(mainfont)$
  31.    \setmainfont{$mainfont$}
  32. $endif$
  33. $if(sansfont)$
  34.    \setsansfont{$sansfont$}
  35. $endif$
  36. $if(monofont)$
  37.    \setmonofont{$monofont$}
  38. $endif$
  39. $if(mathfont)$
  40.    \setmathfont{$mathfont$}
  41. $endif$
  42. \fi
  43. $if(geometry)$
  44. \usepackage[$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
  45. $endif$
  46. $if(natbib)$
  47. \usepackage{natbib}
  48. \bibliographystyle{plainnat}
  49. $endif$
  50. $if(biblatex)$
  51. \usepackage{biblatex}
  52. $if(biblio-files)$
  53. \bibliography{$biblio-files$}
  54. $endif$
  55. $endif$
  56. $if(listings)$
  57. \usepackage{listings}
  58. $endif$
  59. $if(highlighting-macros)$
  60. $highlighting-macros$
  61. $endif$
  62. $if(verbatim-in-note)$
  63. \usepackage{fancyvrb}
  64. $endif$
  65. $if(fancy-enums)$
  66. % Redefine labelwidth for lists; otherwise, the enumerate package will cause
  67. % markers to extend beyond the left margin.
  68. \makeatletter\AtBeginDocument{%
  69.   \renewcommand{\@listi}
  70.    {\setlength{\labelwidth}{4em}}
  71. }\makeatother
  72. \usepackage{enumerate}
  73. $endif$
  74. $if(tables)$
  75. \usepackage{ctable}
  76. \usepackage{float} % provides the H option for float placement
  77. $endif$
  78. $if(graphics)$
  79. \usepackage{graphicx}
  80. % We will generate all images so they have a width \maxwidth. This means
  81. % that they will get their normal width if they fit onto the page, but
  82. % are scaled down if they would overflow the margins.
  83. \makeatletter
  84. \def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth
  85. \else\Gin@nat@width\fi}
  86. \makeatother
  87. \let\Oldincludegraphics\includegraphics
  88. \renewcommand{\includegraphics}[1]{\Oldincludegraphics[width=\maxwidth]{#1}}
  89. $endif$
  90. \ifxetex
  91.   \usepackage[setpagesize=false, % page size defined by xetex
  92.               unicode=false,     % unicode breaks when used with xetex
  93.               xetex]{hyperref}
  94. \else
  95.  \usepackage[unicode=true,breaklinks=true]{hyperref}
  96. \fi
  97. \hypersetup{breaklinks=true,
  98.            bookmarks=true,
  99.            pdfauthor={$author-meta$},
  100.            pdftitle={$title-meta$},
  101.            colorlinks=true,
  102.            urlcolor=$if(urlcolor)$$urlcolor$$else$blue$endif$,
  103.            linkcolor=$if(linkcolor)$$linkcolor$$else$magenta$endif$,
  104.            pdfborder={0 0 0}}
  105. $if(links-as-notes)$
  106. % Make links footnotes instead of hotlinks:
  107. \renewcommand{\href}[2]{#2\footnote{\url{#1}}}
  108. $endif$
  109. $if(strikeout)$
  110. \usepackage[normalem]{ulem}
  111. % avoid problems with \sout in headers with hyperref:
  112. \pdfstringdefDisableCommands{\renewcommand{\sout}{}}
  113. $endif$
  114. \setlength{\parindent}{0pt}
  115. \setlength{\parskip}{6pt plus 2pt minus 1pt}
  116. \setlength{\emergencystretch}{3em}  % prevent overfull lines
  117. $if(numbersections)$
  118. $else$
  119. \setcounter{secnumdepth}{0}
  120. $endif$
  121. $if(verbatim-in-note)$
  122. \VerbatimFootnotes % allows verbatim text in footnotes
  123. $endif$
  124. $if(lang)$
  125. \ifxetex
  126.   \usepackage{polyglossia}
  127.  \setmainlanguage{$mainlang$}
  128. \else
  129.  \usepackage[$lang$]{babel}
  130. \fi
  131. $endif$
  132. $for(header-includes)$
  133. $header-includes$
  134. $endfor$
  135.  
  136. \fancyfootoffset[L]{60px}
  137. \fancyfootoffset[R]{60px}
  138. \fancyheadoffset[L]{50px}
  139. \fancyheadoffset[R]{50px}
  140. \renewcommand{\footrulewidth}{0.4pt}
  141. \fancyfoot[L]{
  142.     \footnotesize{$title$}\\
  143.     \footnotesize{$author$}
  144. }
  145. \fancyfoot[R]{
  146.     \thepage
  147. }
  148. \fancyfoot[C]{ % empty right
  149. }
  150. \pagestyle{fancy}
  151.  
  152. \usepackage{setspace}
  153. \singlespacing
  154.  
  155. \definecolor{gray70}{gray}{0.30}
  156. \definecolor{gray50}{gray}{0.50}
  157.  
  158. \usepackage{sectsty}
  159. \allsectionsfont{\sffamily}
  160. \sectionfont{\LARGE\color{gray70}}
  161. \subsectionfont{\large\color{gray50}}
  162.  
  163. \usepackage[shortlabels]{enumitem}
  164. \setlist[itemize]{itemsep=.2em}
  165.  
  166. $if(title)$
  167. \title{$title$}
  168. $endif$
  169. \author{$for(author)$$author$$sep$ \and $endfor$}
  170. %\date{$date$}
  171. \date\today
  172.  
  173. \let\stdsection\section
  174. \renewcommand\section{\newpage\stdsection}
  175.  
  176. \begin{document}
  177. \sffamily % use sans-serif font
  178. $if(title)$
  179. \maketitle
  180. $endif$
  181.  
  182. %\pagebreak
  183.  
  184. $for(include-before)$
  185. $include-before$
  186.  
  187. $endfor$
  188. $if(toc)$
  189. {
  190. \hypersetup{linkcolor=black}
  191. \tableofcontents
  192. }
  193. $endif$
  194. $body$
  195.  
  196. $if(natbib)$
  197. $if(biblio-files)$
  198. $if(biblio-title)$
  199. $if(book-class)$
  200. \renewcommand\bibname{$biblio-title$}
  201. $else$
  202. \renewcommand\refname{$biblio-title$}
  203. $endif$
  204. $endif$
  205. \bibliography{$biblio-files$}
  206.  
  207. $endif$
  208. $endif$
  209. $if(biblatex)$
  210. \printbibliography$if(biblio-title)$[title=$biblio-title$]$endif$
  211.  
  212. $endif$
  213. $for(include-after)$
  214. $include-after$
  215.  
  216. $endfor$
  217. \end{document}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement