Consider the following MWE.
\documentclass[handout]{beamer}
\newcounter{slidenumber}
\defbeamertemplate*{footline}{infolines theme frame plus slide}{
\setcounter{slidenumber}{\insertpagenumber}%
\addtocounter{slidenumber}{-\insertframestartpage}%
\addtocounter{slidenumber}{1}%
\leavevmode%
\hbox{%
\begin{beamercolorbox}[wd=\paperwidth,ht=2.25ex,dp=1ex,center]{date in head/foot}%
\insertframenumber(\alph{slidenumber}{})/ \inserttotalframenumber\hspace*{2ex}
\end{beamercolorbox}}%
\vskip0pt%
}
\setbeamertemplate{footline}[infolines theme frame plus slide]
\begin{document}
\begin{frame}
\only<handout:1>{Handout 1 of frame 1}
\only<handout:2>{Handout 2 of frame 1}
\end{frame}
\begin{frame}
Frame 2
\end{frame}
\end{document}
Frame 1 has two slides, I want to number them as 1(a)/2
, 1(b)/2
. Frame 2 has only one slide, and is currently numbered as 2(a)/2
. However, I want to number it as 2/2
.
In general, I want frames with multiple slides numbered as
<frame_num>(<slide_num_in_frame>)/<total_frame_num>
and frames with only one slide numbered as
<frame_num>/<total_frame_num>
How can I achieve this effect?