Compact lists in beamer

Compact lists in beamer

In my standard latex documents, I'm using enumitem to change my list output, in two ways:

  1. Make lists (on demand) more compact (noitemsep,topsep=0pt,parsep=0pt,partopsep=0pt)
  2. Change labeling of enumerate on the fly.

as via this answer. However, when doing that in my beamer-powered slides, I get an error along the lines of

tex capacity exceeded sorry grouping levels=255

It appears that enumitem is not compatible with beamer. What's a workaround to get these two features in beamer? Mock-up slide:

enter image description here

("a", "b", "c" are missing the dot, but I guess the point comes across).

Here's the doc that errs out:

% !TEX encoding = UTF-8 Unicode
% !TEX TS-program = pdflatexmk


\documentclass{beamer}





% add page numbers for malmoe
\newcommand*\oldmacro{}%
\let\oldmacro\insertshorttitle%
\renewcommand*\insertshorttitle{%
  \oldmacro\hfill%
  \insertframenumber\,/\,\inserttotalframenumber}


\usetheme{Malmoe}
\setbeamertemplate{headline}{}
\setbeamertemplate{footline}{}
\addtobeamertemplate{navigation symbols}{}{%
    \usebeamerfont{footline}%
    \usebeamercolor[fg]{footline}%
    \hspace{1em}%
    \insertframenumber/\inserttotalframenumber
}


\usepackage{enumitem}
\setlist[itemize]{noitemsep,topsep=0pt,parsep=0pt,partopsep=0pt}


\begin{document}





\begin{frame}{Foo}
Foo
\begin{enumerate}
\item Bar
\item Baz
\item Domingo
\end{enumerate}

Foo
\begin{enumerate}[a]
\item[a] Bar
\item[b] Baz
\item[c] Domingo
\end{enumerate}


and bar

\begin{itemize}
\item Bar
\item Baz
\item Domingo
\end{itemize}
\end{frame}


\end{document}

답변1

Answering

  1. Change labeling of enumerate on the fly.

To change the enumerate label on the fly there are several possibilities, for example:

\documentclass{beamer}

\begin{document}

\begin{frame}{Foo}
Foo
\begin{enumerate}
\item Bar
\item Baz
\item Domingo
\end{enumerate}

Foo
\begin{enumerate}[a.]
\item Bar
\item Baz
\item Domingo
\end{enumerate}

Foo
{
\setbeamertemplate{enumerate item}{\alph{enumi}.}
\begin{enumerate}
\item Bar
\item Baz
\item Domingo
\end{enumerate}
}

and bar

\begin{itemize}
\item Bar
\item Baz
\item Domingo
\end{itemize}
\end{frame}


\end{document}

enter image description here

관련 정보