minted-code-inclusion.tex 981 B

1234567891011121314151617181920212223
  1. \documentclass{beamer}
  2. \usepackage[utf8]{inputenc} % this is needed for german umlauts
  3. \usepackage[ngerman]{babel} % this is needed for german umlauts
  4. \usepackage[T1]{fontenc} % this is needed for correct output of umlauts in pdf
  5. \usepackage{minted} % needed for the inclusion of source code
  6. % from http://tex.stackexchange.com/questions/57151/how-do-i-prevent-conflicts-between-accsupp-and-hyperref
  7. \usepackage{accsupp}
  8. \newcommand\emptyaccsupp[1]{\BeginAccSupp{ActualText={}}#1\EndAccSupp{}}
  9. %default definition is: \def\theFancyVerbLine{\rmfamily\tiny\arabic{FancyVerbLine}}
  10. \let\theHFancyVerbLine\theFancyVerbLine% don't apply our patch to hyperref's version
  11. \def\theFancyVerbLine{\rmfamily\tiny\emptyaccsupp{\arabic{FancyVerbLine}}}
  12. \begin{document}
  13. \section{Section}
  14. \subsection{MySubSection}
  15. \begin{frame}{Blubtitle}
  16. \inputminted[linenos=true, numbersep=5pt, tabsize=4, fontsize=\small]{java}{IataCode.java}
  17. \end{frame}
  18. \end{document}