diff --git a/eisvogel.tex b/eisvogel.tex index 1986732..f252054 100644 --- a/eisvogel.tex +++ b/eisvogel.tex @@ -259,6 +259,11 @@ $if(listings)$ \usepackage{listings} \newcommand{\passthrough}[1]{#1} $endif$ +$if(listings-no-page-break)$ +\usepackage{etoolbox} +\BeforeBeginEnvironment{lstlisting}{\par\noindent\begin{minipage}{\linewidth}} +\AfterEndEnvironment{lstlisting}{\end{minipage}\par\addvspace{\topskip}} +$endif$ $if(lhs)$ \lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{} $endif$