jlcode
jlcode copied to clipboard
interaction with beamer overlays
usually you can specify to show environments on certain beamer overlays with
\begin{env}<2->
\end{env}
for showing that only at the second overlay. However, this doesn't seem to work with jllisting.
Could you maybe create a MWE which I can run myself so that I can have a closer look ath this issue?
\documentclass{beamer}
\usepackage{jlcode}
\begin{document}
\begin{frame}[fragile]
\begin{jllisting}<1>
Hello
\end{jllisting}
\begin{jllisting}<2>
World
\end{jllisting}
% shows both
\end{frame}
\begin{frame}[fragile]
\onslide<2>{
\begin{jllisting}
Hello
\end{jllisting}
} % errors
\end{frame}
\end{document}
Thank you for the MWE.
I had a quick look at the problem and I figured out that this problem does not seem to be a problem of the jlcode package specifically, but rather a problem of the listings package in general. That's because testing the code
\documentclass{beamer}
\usepackage{listings}
\begin{document}
\begin{frame}[fragile]
\begin{lstlisting}<1>
Hello
\end{lstlisting}
\begin{lstlisting}<2>
World
\end{lstlisting}
% shows both
\end{frame}
\begin{frame}[fragile]
\onslide<2>{
\begin{lstlisting}
Hello
\end{lstlisting}
} % errors
\end{frame}
\end{document}
yields exactly the same problem. Hence I cannot really help you here I guess. ☹️