我在 Beamer 演示文稿中看到过一个漂亮的目录。有一些公式、图片、图表位于阴影背景的框架中。有想法怎么做吗?
答案1
您可以使用background
模板;背景是可以使用常用命令包含的图像;通过\includegraphics
在里面放置图像来控制不透明度;在 ToC 之后,再次重新定义模板以抑制图像:\node
TikZ
\documentclass{beamer}
\usetheme{Boadilla}
\usepackage{tikz}
\begin{document}
\setbeamertemplate{background}{%
\tikz\node[opacity=0.3] at (current page.center) {\includegraphics[height=\paperheight]{ctanlion}};}
\begin{frame}
\frametitle{Outline}
\tableofcontents
\end{frame}
\setbeamertemplate{background}{}
\section{Test Section One}
\begin{frame}
Contents of section one
\end{frame}
\section{Test Section Two}
\begin{frame}
Contents of section two
\end{frame}
\section{Test Section Three}
\begin{frame}
Contents of section three
\end{frame}
\end{document}
CTAN 狮子绘画由 Duane Bibby 绘制。
答案2
\documentclass{beamer}
\usepackage{filecontents}
\begin{filecontents*}{background.tex}
\documentclass[pstricks,border=0pt]{standalone}
\usepackage{pst-plot}
\begin{document}
\begin{pspicture}(-\psPi,-2)(\psPi,2)
\psplot[algebraic,plotpoints=1500]{-\psPi}{\psPi}{sin(15*x)*cos(13*x)+cos(5*x)}
\end{pspicture}
\end{document}
\end{filecontents*}
\usepackage{graphicx}
\AtBeginDocument
{
\immediate\write18{latex background}
\immediate\write18{dvips background}
\immediate\write18{ps2pdf background.ps}
}
\begin{document}
\bgroup
\usebackgroundtemplate{\includegraphics[width=\paperwidth]{background}}
\begin{frame}[t]{Table of Contents}
\tableofcontents
\end{frame}
\egroup
\section{Introduction}
\begin{frame}[t]{Who am I?}
I am a Garbage Collector.
\end{frame}
\section{At a glance}
\begin{frame}[t]{What is your hobby?}
Coding!
\end{frame}
\end{document}
编辑:用 编译代码pdflatex --shell-escape filename
。