# Customizing the sidebar in beamer

I'm working with the Marburg theme with beamer, and I would like to customize its Sidebar so that the title & author of the presentation does not show up, and I want the sections in the Sidebar to be numbered.

Desired output:

Example:

\documentclass{beamer}
\usetheme{Marburg}

\title{Some title}
\author{author}
\institute{my workplace}
\date{\today}

\AtBeginSection[]
{
\begin{frame}
\tableofcontents[currentsection,currentsubsection]
\end{frame}
}

\begin{document}

\begin{frame}
\titlepage
\end{frame}

\section[Outline]{}
\frame{\tableofcontents}

\section{Introdution}

\begin{frame}
\frametitle{Basics}
\begin{itemize}
\item A
\pause
\item B
\pause
\item C
\end{itemize}
\end{frame}

\subsection{More basics}

\begin{frame}
\frametitle{something goes here}
more stuff
\end{frame}

\section{My work}

\begin{frame}
my stuff...
\end{frame}

\end{document}


Thanks!

-
I found out that I can use \title[]{Some title} and \author[]{author} into tricking LaTex to think that the short title/author is the empty string as represented by []. Now what about the numbered sidebar items? –  david sedai Mar 6 '12 at 1:03

The following code contains the necessary redefinitions:

\documentclass{beamer}
\usetheme{Marburg}

\makeatletter
\setbeamertemplate{sidebar \beamer@sidebarside}
{
\beamer@tempdim=\beamer@sidebarwidth%
\vskip4em%
\vfill
\ifx\beamer@sidebarside\beamer@lefttext%
\else%
\usebeamercolor{normal text}%
\vskip2pt%
\fi%
}%

\ifx\beamer@sidebarside\beamer@lefttext%
\defbeamertemplate*{sidebar right}{sidebar theme}
{%
\vfill%
\vskip2pt}
\fi

\setbeamertemplate{section in sidebar}%{sidebar theme}
{%
\vbox{%
\vskip1ex%
}%
}
{%
\vbox{%
\vskip1ex%
}%
}
\makeatother

\title{Some title}
\author{author}
\institute{my workplace}
\date{\today}

\AtBeginSection[]
{
\begin{frame}
\tableofcontents[currentsection,currentsubsection]
\end{frame}
}

\begin{document}

\begin{frame}
\titlepage
\end{frame}

\section[Outline]{First Section}
\frame{\tableofcontents}

\section{Introduction}

\begin{frame}
\frametitle{Basics}
\begin{itemize}
\item A
\pause
\item B
\pause
\item C
\end{itemize}
\end{frame}

\subsection{More basics}

\begin{frame}
\frametitle{something goes here}
more stuff
\end{frame}

\section{My work}

\begin{frame}
my stuff...
\end{frame}

\end{document}


An image of the first slide:

-
Works like a charm. Thanks very much! –  david sedai Mar 6 '12 at 1:09
By the way, the code \usetheme[hideothersubsections]{Marburg} can also be used so that the sidebar shows subsections only for the section the slide is currently in. –  david sedai Mar 6 '12 at 2:40

To summarize:

(i) use \title[]{Some title} and \author[]{author} into tricking LaTeX to think that the short title/author is the empty string as represented by [].

(ii) use Gonzalo Medina's excellent solution to print out the numbered items.

-
My solution also takes care of the author/title issue: you can still use a non-empty optional argument and no information will be added to the sidebar. –  Gonzalo Medina Mar 6 '12 at 2:21
@Gonzalo Medina Absolutely. It's really a neat, all-in-one-place solution. I just want to point out that if someone else needs only to omit the author/title in the sidebar, there is a simple way using the blank brackets []. Thank you. –  david sedai Mar 6 '12 at 3:12