
이 비머 문서의 마지막 섹션에서는 다음을 수행합니다.
"다음 섹션"을 클릭하면 이것이 마지막 섹션이므로 여기서 멈추는 것이 바람직합니다. 그러나 "다음 섹션"을 클릭하면 이 마지막 섹션 내의 마지막 프레임으로 이동합니다.
원하는 결과를 얻을 수 있는 방법이 있습니까(즉, 마지막 섹션에 있을 때 "다음 섹션"을 클릭하면 점프하지 마세요).
암호:
\documentclass{beamer}
\AtBeginSection[]{\label{sec:\thesection}}
\newcounter{prevsec}
\title{Some Title}
\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{footline}{%
\setcounter{prevsec}{\thesection}
\ifnum\theprevsec>1
\addtocounter{prevsec}{-1}
\fi
\quad\hyperlinkpresentationstart{\beamerreturnbutton{Back to start}}%
\quad\hyperlinksectionstart{\beamerreturnbutton{Back to section start}}%
\quad\hyperlink{Detailed_Analysis}{\beamergotobutton{Detailed Analysis}}%
\quad\hyperlinksectionstartnext{\beamerskipbutton{Next section}}%
\quad\hyperlink{sec:\theprevsec}{\beamerskipbutton{previous section}}%
\vspace*{0.2cm}%
}
\begin{document}
\section{sec1}
\begin{frame}%{ss}
1st section/ page 1 out of 1
\end{frame}
\begin{frame}
1st section/ page 2 out of 2
\end{frame}
\begin{frame}[label=Detailed_Analysis]
Detailed Analysis
\end{frame}
\section{sec2}
\begin{frame}
2nd section
\end{frame}
\section{sec3}
\begin{frame}
3rd section
\end{frame}
\begin{frame}
More content on the 3rd section
\end{frame}
\begin{frame}
Even More content on the 3rd section
\end{frame}
\end{document}
답변1
다음 코드는 마지막 섹션의 하이퍼링크를 비활성화합니다. 최소한 2개의 컴파일이 필요합니다.
\documentclass{beamer}
\AtBeginSection[]{\label{sec:\thesection}}
\newcounter{prevsec}
\usepackage{totcount}
\regtotcounter{section}
\title{Some Title}
\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{footline}{%
\setcounter{prevsec}{\thesection}
\ifnum\value{prevsec}>1
\addtocounter{prevsec}{-1}
\fi
\quad\hyperlinkpresentationstart{\beamerreturnbutton{Back to start}}%
\quad\hyperlinksectionstart{\beamerreturnbutton{Back to section start}}%
\quad\hyperlink{Detailed_Analysis}{\beamergotobutton{Detailed Analysis}}%
\ifnum\value{section}<\totvalue{section}%
\quad\hyperlinksectionstartnext{\beamerskipbutton{Next section}}%
\else%
\quad \beamerskipbutton{Next section}%
\fi%
\quad\hyperlink{sec:\theprevsec}{\beamerskipbutton{previous section}}%
\vspace*{0.2cm}%
}
\begin{document}
\section{sec1}
\begin{frame}%{ss}
1st section/ page 1 out of 1
\end{frame}
\begin{frame}
1st section/ page 2 out of 2
\end{frame}
\begin{frame}[label=Detailed_Analysis]
Detailed Analysis
\end{frame}
\section{sec2}
\begin{frame}
2nd section
\end{frame}
\section{sec3}
\begin{frame}
3rd section
\end{frame}
\begin{frame}
More content on the 3rd section
\end{frame}
\begin{frame}
Even More content on the 3rd section
\end{frame}
\end{document}