[Tex/LaTex] Beamer – How to add sub-frame numbers

beamerpage-numbering

I have the following code which works for counting pages:

\setbeamertemplate{navigation symbols}{
    \usebeamercolor[fg]{title}
    \hspace{1em}
    \large\insertframenumber/\inserttotalframenumber
}

added to the preamble.

I was wondering if I could add something so that when I cycle through a single frame it counts that too for example I would like the following to show:

1a/1 , 1b/1 , 1c/1 instead of 1/1 for all frames.

\documentclass[demo]{beamer}

\setbeamertemplate{navigation symbols}{
    \usebeamercolor[fg]{title}
    \hspace{1em}
    \large\insertframenumber/\inserttotalframenumber
}

\begin{document}

    \begin{frame}{Title}
        \begin{itemize}
            \item<1-> stuff
            \item<2-> stuff
            \item<3-> stuff
        \end{itemize}
    \end{frame}

\end{document}

Best Answer

Here's one possibility:

\documentclass[demo]{beamer}
\usepackage{tikz}

\makeatletter
\def\c@slideinframe{\beamer@slideinframe}
\def\beamerslideinframe{\beamer@slideinframe}
\makeatother

\addtobeamertemplate{frametitle}{}{%
\begin{tikzpicture}[remember picture,overlay]
  \node[inner sep=0pt,font=\large,anchor=south east] 
    at ([xshift=-0.5em]current page.south east)       
    {\insertframenumber-(\alph{slideinframe})/\inserttotalframenumber};%
\end{tikzpicture}
}
\setbeamertemplate{navigation symbols}{}

\begin{document}

    \begin{frame}{Title}
    \frametitle{Slide \arabic{slideinframe}}
        \begin{itemize}
            \item<1-> stuff
            \item<2-> stuff
            \item<3-> stuff
        \end{itemize}
    \end{frame}

\end{document}

The result:

enter image description here

The template in which to add the information about the slide number has to be carefully chosen; in some "late" templates (such as navigation symbols, footline) the value for the slide number gets affected by the overlays specification, so I had to use an "early" template such as frametitle and used TikZ to place the numbers in the desired location.

The code needs two or three runs to stabilize.