我已经声明了一系列\hyperlinksection
:
\documentclass{beamer}
\usepackage[]{hyperref}
\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{footline}{%
\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\hyperlinksectionendprev{\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}
\end{document}
超链接“返回开始”、“返回章节开始”、“详细分析”、“下一节”起作用,但“上一节”超链接不会跳转到上一节,而是跳转到“详细分析”部分,即:
在第 2 部分时:
如果我点击“上一节”,它会转到“详细分析”部分而不是“第一节”:
有没有什么办法可以让Previous section
超链接发挥作用?
更新:使用@samcarter 答案,存在这个问题:当在最后一节时:
如果你点击“下一节”,理想的结果是停在这里,因为这是最后一节。但是,如果你点击“下一节”,你将转到最后一节中的最后一帧:
有没有办法实现理想的结果(即当我们在最后一节时,如果我们点击“下一节”,就不要跳转)。
代码:
\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
我猜问题是\hyperlinksectionendprev
跳转到上一节的最后一帧,而你似乎想转到上一节的第一帧。
\documentclass{beamer}
\AtBeginSection[]{\label{sec:\thesection}}
\newcounter{prevsec}
\title{Some Title}
\setbeamertemplate{footline}{%
\setcounter{prevsec}{\value{section}}
\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}}%
\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}
\end{document}