[Tex/LaTex] Beamer navigation bars to show only \subsubsections and \subsubsubsections

beamernavigation

I need to customize my navigation bars in the following manner:

  1. Subsubsection title shows up in navigation bars where section title are usually placed
  2. A new command \subsubsubsection is defined
  3. Title of the \subsubsubsection shows up where where subsection titles are usually placed.

This presentation would not use \section and \subsection. In effect I need to map two commands to take their place. The reason why I need this is that I am utilizing same slides via \input{} for two different scenarios. In one presentation I don't wish them to show up in navigation bars as they are a minor part of a huge presentation, but in the other they would be the only content and sectioning should be visible in navigation bars. Here is my minimal (non) working example. I usually use Warsaw theme, but hopefully the solution would be theme agnostic.

\documentclass[compress]{beamer}
\usetheme{Warsaw}

\begin{document}

\subsubsection{Section} %This should show up in navigation bar in a place where the section title is usually placed

\begin{frame}{Sample Slide I}
 Content 
\end{frame}

\subsubsubsection{Subsection} %This should show up in navigation bar in a place where the subsection title is usually placed

\begin{frame}{Sample Slide I}   
Content 
\end{frame}
\end{document}

Best Answer

The design of beamer discourages \subsubsection use and is built around a formal structure of \section/\subsection/(\subsubsection) (i.e. subsections have to be part of sections). Indeed, support for \subsubsections is partial at best. There is no support for \subsubsubsection (not a standard LaTeX command anyway: \paragraph is the name for this concept in the base classes but this is quite deliberately not defined in beamer).

Where the source has to use \subsubsection and \subsubsubsection, I'd therefore go with redirecting these to \section and \subsection, respectively:

\documentclass[compress]{beamer}
\let\subsubsection\section
\let\subsubsubsection\subsection
\usetheme{Warsaw}

\begin{document}

\subsubsection{A}

\begin{frame}{Sample Slide I}
 Content 
\end{frame}

\subsubsubsection{AA}

\begin{frame}{Sample Slide I}   
Content 
\end{frame}
\end{document}

The \let block could be set up conditionally if required, of of course you could give them custom names (\mysection or similar).