[Tex/LaTex] Beamer Presentation: Show TOC at beginning of Unnumbered Subsection (Subsection*)

beamerlyxsectioningtable of contents

I am making slides for an upcoming presentation using the default beamer ornate template.
Part of the template lets me show the Table of Contents when transitioning into a new subsection (included below). This is perfect for my needs… almost!

\AtBeginSubsection[]{

  \frame<beamer>{ 

    \frametitle{Outline}   

    \tableofcontents[currentsection,currentsubsection] 

  }

}

Here's the problem: my TOC is fairly long, which means that not all of it fits on the outline slide. So, I removed singleton subsections; i.e. subsections that were the only subsections in that section.
This saved me some space in the "Outline" slide which lists the full TOC for the talk.

When I did this however, the sections that no longer had subsections didn't have a slide just before, showing which point in the outline I was talking about. In order to combat this, I added an unnumbered subsection in the required sections. I figured this would keep the entry out of the TOC in the outline, while highlighting the appropriate section in the TOC just before entering it. To my dismay, this was not the case.

Thus the question: how may I show the TOC at the beginning of an unnumbered subsection, or at the beginning of a section that doesn't have any subsections?

Technical specifications:

  • Mac OS X 10.7.5 (Lion)
  • LyX v2.0.5.1
  • MacTex v2.0 (build 150)

LaTeX Preamble:

\usetheme{Warsaw}
% or ...

\setbeamercovered{transparent}
% or whatever (possibly just delete it)

%slide numbering
\useoutertheme{infolines}
%\setbeamertemplate{footline}[frame number]

Best Answer

For the case of unnumbered subsections, you can use the optional argument of \AtBeginSubsection:

\documentclass{beamer}
\usetheme{Warsaw}
\setbeamercovered{transparent}
\useoutertheme{infolines}

\AtBeginSubsection[
  {\frame<beamer>{\frametitle{Outline}   
    \tableofcontents[currentsection,currentsubsection]}}%
]%
{
  \frame<beamer>{ 
    \frametitle{Outline}   
    \tableofcontents[currentsection,currentsubsection]}
}

\begin{document}

\section{Test Section}
\begin{frame}test\end{frame}
\subsection[]{Test Subsection}
\begin{frame}test frame of an unnumbered subsection\end{frame}

\end{document}