After fumbling with the different versions of \mode
, I managed to get it to work.
I do not really understand why I have to use one version at some place and the other at another place, and I am open to explanations, better ways of doing it or even automating it (ie. defining a shorter macro to do that).
\documentclass{beamer}
\makeatletter
\@ifclassloaded{beamer}{\usecolortheme{orchid}}{\usepackage{beamerarticle}}
\makeatother
\NewDocumentEnvironment{preuve}{O{Preuve}}{\begin{block}{#1}}{\end{block}}
\begin{document}
\begin{frame}
\begin{alertblock}{Berge, 1957}
Un couplage $C$ est de cardinal maximal si et seulement s'il n'admet pas de chemin augmentant.
\end{alertblock}
\pause
\begin{preuve}[Preuve du sens non couvert par le lemme]
some already long text
\mode
<presentation>
% article mode does not see this
\hfill …/…
\end{preuve}
\end{frame}
\begin{frame}
\begin{block}{}
\mode
<all>
Soit $p$ un chemin maximal dans $K$ : \uncover<2->{sa première et sa dernière arêtes sont dans $C_2$.}
\mode
<presentation>
\end{block}\pause[3]\vfill
\mode
<all>
\mode<article>{\end{preuve}}
Remarque : ce lemme et ce théorème n'utilisent pas le fait que le graphe est biparti.\\
Cette propriété va cependant permettre de faciliter la recherche d'un chemin augmentant.
\end{frame}
\end{document}