Beamer를 사용하여 TOC의 하위 섹션 오버레이

Beamer를 사용하여 TOC의 하위 섹션 오버레이

프레젠테이션을 시작하면서 다음 사항을 보여드리고 싶습니다. 첫 번째 슬라이드에는 섹션만 포함된 목차를 표시하고 싶습니다. 즉, 하위 섹션은 보이지 않아야 하지만 거기에 있어야 합니다. 그런 다음 다음 슬라이드에서 하위 섹션을 연속적으로 혼합해야 합니다.

옵션을 사용하면 pausesubsections\tableofcontents번째 슬라이드에 첫 번째 섹션만 표시된다는 단점이 있습니다. 이 옵션을 사용하면 hidesubsections하위 섹션이 완전히 지워지므로 하위 섹션을 차례로 혼합할 수 없습니다.

enumerate와 를 itemize이용하여 가짜 목차를 설정해 보았는데 \pause'실제' 목차와 간격이 다릅니다. 아래에는 MWE가 제공되었습니다.

\documentclass{beamer}

\begin{document}

\begin{frame}{Outline}
    \tableofcontents[pausesubsections]
\end{frame}

\section{One}

\subsection{OneOne}
\begin{frame}
    There is nothing here.
\end{frame}

\subsection{OneTwo}
\begin{frame}
    There is nothing here.
\end{frame}


\section{Two}

\subsection{TwoOne}
\begin{frame}
    There is nothing here.
\end{frame}

\subsection{TwoTwo}
\begin{frame}
    There is nothing here.
\end{frame}

\end{document}

답변1

공간을 유지하면서 하위 섹션을 숨기려면 배경색으로 색상을 지정하면 쉽게 수행할 수 있습니다.

\documentclass{beamer}

\begin{document}

{
\setbeamercolor{subsection in toc}{fg=bg}
\begin{frame}{Outline}
    \tableofcontents
\end{frame}
}

\begin{frame}{Outline}
    \tableofcontents[pausesubsections]
\end{frame}

\section{One}

\subsection{OneOne}
\begin{frame}
    There is nothing here.
\end{frame}

\subsection{OneTwo}
\begin{frame}
    There is nothing here.
\end{frame}


\section{Two}

\subsection{TwoOne}
\begin{frame}
    There is nothing here.
\end{frame}

\subsection{TwoTwo}
\begin{frame}
    There is nothing here.
\end{frame}

\end{document}

답변2

어쩌면 이런 코드를 작성하고 싶을 수도 있습니다. 이는 비머 자체 명령과 함께 작동합니다.

첫 번째 슬라이드에는 섹션 제목만 포함된 개요가 표시됩니다. 섹션을 입력하면 하위 섹션의 제목이 삽입되고 강조 표시된 새로운 개요가 표시됩니다.

\documentclass{beamer}

\mode<presentation>{%
  %% At the begin of a section, insert a short outline
  \AtBeginSection[]{%
    \begin{frame}<beamer>%
      \frametitle{Outline}
      \tableofcontents[currentsection,subsectionstyle=show/shaded/hide]%
    \end{frame}%
  }%
  %% 
  %% Same for Subsections
  \AtBeginSubsection[]{%
    \begin{frame}<beamer>%
      \frametitle{Outline}
      \tableofcontents[currentsection,subsectionstyle=show/shaded/hide]%
    \end{frame}}%
}
\begin{document}


\begin{frame}{Outline}
    \tableofcontents[currentsection,sectionstyle=show,hideothersubsections]
\end{frame}

\section{One}

\subsection{OneOne}
\begin{frame}
    There is nothing here.
\end{frame}

\subsection{OneTwo}
\begin{frame}
    There is nothing here.
\end{frame}


\section{Two}

\subsection{TwoOne}
\begin{frame}
    There is nothing here.
\end{frame}

\subsection{TwoTwo}
\begin{frame}
    There is nothing here.
\end{frame}

\end{document}

관련 정보