问题
有没有办法暂时完全删除框架标题单身的指定帧的幻灯片? 完全删除,我的意思是标题的垂直空间也删除。
我尝试过的方法
我尝试使用该\begin{frame}{\only<...>{...}}
技术,但它保留了垂直间距。
原因
当我在具有覆盖规范的环境中深入时,其中一张幻灯片播放到一半时itemize
,我想显示一个大的全屏图形。在此全屏部分,我希望框架标题不存在(就像使用 指定一样\frame{}
)。全屏图像之后,我希望标题和其余项目重新出现。
除了从单张幻灯片中删除框架标题外,我可以实现所有这些。
平均能量损失
\documentclass{beamer}
\mode<presentation>
\setbeamercovered{transparent}
\begin{document}
\begin{frame}[t]{Frame number 1}
\begin{itemize}
\item This is frame number 1.
Compare the vertical placement of this itemize environment
to that on the next frame.
\end{itemize}
\end{frame}
\begin{frame}[t]{}
\begin{itemize}
\item This is frame number 2. Note that this second frame has no vertical space for the title.
\end{itemize}
\end{frame}
\begin{frame}[t]{\only<1,3>{Frame number 3}}
\begin{itemize}
\item <1-> I want the title showing on this slide, as it does.
\item <2-> I want the title completely gone here,
including the vertical space it occupies.
(In my actual presentation, there will be a full-screen
figure in this position,
and the itemize environment will disappear.
\item <3-> I want the title to come back
\end{itemize}
\end{frame}
\end{document}
答案1
嗯,我想我应该再试 10 分钟。
我通过在命令\frametitle
内包围命令解决了这个问题\only
。(在之前的尝试中,我反转了嵌套,但显然没有起作用。
实际操作如下:
\documentclass{beamer}
\mode<presentation>
\setbeamercovered{transparent}
\begin{document}
\begin{frame}[t]{Frame number 1}
\begin{itemize}
\item This is frame number 1.
Compare the vertical placement of this itemize environment
to that on the next frame.
\end{itemize}
\end{frame}
\begin{frame}[t]{}
\begin{itemize}
\item This is frame number 2. Note that this second frame has no vertical space for the title.
\end{itemize}
\end{frame}
\begin{frame}[t]{}
\only<1,3>{\frametitle{Frame number 3}}
\begin{itemize}
\item <1-> I want the title showing on this slide, as it does.
\item <2-> I want the title completely gone here,
including the vertical space it occupies.
(In my actual presentation, there will be a full-screen
figure in this position,
and the itemize environment will disappear.
\item <3-> I want the title to come back
\end{itemize}
\end{frame}
\end{document}
答案2
以下仅为第二张幻灯片插入全帧图像:
\only<2>{% On the second slide...
\AddToShipoutPictureFG*{% Add a picture to the ForeGround for this slide only
\AtPageCenter{% At the center of the page/slide
\makebox[0pt]{% Horizontally center image on slide
\raisebox{-.5\height}{% Vertically center image on slide
\includegraphics[height=\paperheight,width=\paperwidth]{example-image}%
}%
}%
}%
}%
}
您可以将其放置在frame
适用的代码的任何位置。
这是添加了上述代码的最小示例:
\documentclass{beamer}
\mode<presentation>
\setbeamercovered{transparent}
\usepackage{eso-pic}
\begin{document}
\begin{frame}[t]{Frame number 1}
\begin{itemize}
\item This is frame number 1.
Compare the vertical placement of this itemize environment
to that on the next frame.
\end{itemize}
\end{frame}
\begin{frame}[t]{}
\begin{itemize}
\item This is frame number 2. Note that this second frame has no vertical space for the title.
\end{itemize}
\end{frame}
\begin{frame}[t]{\only<1,3>{Frame number 3}}
\begin{itemize}
\item <1-> I want the title showing on this slide, as it does.
\item <2-> I want the title completely gone here,
including the vertical space it occupies.
(In my actual presentation, there will be a full-screen
figure in this position,
and the itemize environment will disappear.
\item <3-> I want the title to come back
\end{itemize}
\only<2>{% On the second slide...
\AddToShipoutPictureFG*{% Add a picture to the ForeGround for this slide only
\AtPageCenter{% At the center of the page/slide
\makebox[0pt]{% Horizontally center image on slide
\raisebox{-.5\height}{% Vertically center image on slide
\includegraphics[height=\paperheight,width=\paperwidth]{example-image}%
}%
}%
}%
}%
}
\end{frame}