答案1
比默有自己的机制来创建TOC。
基本上,每次你打电话\tableofcontents[options]
,比默包含同一个.toc
文件一次。唯一的区别是,使用不同options
的比默将改变其将样式应用于文件内容的方式.toc
。
毕竟,比默为您提供了一些投影仪模板,例如subsection in toc
,subsection in toc shaded
以便您可以决定正常/阴影[[sub]sub]部分的最终外观。
让我给你举个例子。这是正常的目录的样子
\documentclass{beamer}
\usepackage{multicol,tikz}
\usetikzlibrary{shapes.symbols}
\begin{document}
\section{PGF}
\subsection{Arrow Keys}
\subsubsection{Length}
\subsubsection{Width}
\subsection{Decoration}
\subsubsection{Amplitude}
\subsubsection{Radius}
\subsection{Text}
\subsubsection{Left}
\subsubsection{Right}
\section{TikZ}
\subsection{CS}
\subsubsection{Node}
\subsubsection{Solution}
\subsection{External}
\subsubsection{Optimize}
\subsubsection{Prefix}
\subsection{Graphs}
\subsubsection{Quick}
\subsubsection{Simple}
\section{PGFPLOTS}
\subsection{Table}
\subsubsection{Col sep}
\subsubsection{Row sep}
\subsection{Group}
\subsubsection{Group name}
\subsubsection{Group size}
\subsection{Mesh}
\subsubsection{Check}
\subsubsection{Odering}
\frame{{Normal TOC}
\begin{multicols}2\tableofcontents\end{multicols}
}
\frame{{Normal TOC}
\begin{multicols}2\tableofcontents[currentsection]\end{multicols}
}
\frame{{Normal TOC}
\begin{multicols}2\tableofcontents[hideothersubsections]\end{multicols}
}
如果你通过以下方式构建这些模板,那么 TOC 看起来就是这样的\tikz[remember picture,overlay]
\tikzset{
every picture/.style={remember picture,overlay,scale=.3}
}
\defbeamertemplate*{section in toc}{tikz}{
\tikz\path(temp node)+(0,-1)node(temp node){}+(0,0)node[right]{\inserttocsection};
}
\defbeamertemplate*{section in toc shaded}{tikz}[1][.2]{
\tikz\path(temp node)+(0,-1)node(temp node){}+(0,0)node[right,opacity=#1]{\inserttocsection};
}
\defbeamertemplate*{subsection in toc}{tikz}{
\tikz\path(temp node)+(0,-1)node(temp node){}+(6,0)node[right]{\inserttocsubsection};
}
\defbeamertemplate*{subsection in toc shaded}{tikz}[1][.2]{
\tikz\path(temp node)+(0,-1)node(temp node){}+(6,0)node[right,opacity=#1]{\inserttocsubsection};
}
\defbeamertemplate*{subsubsection in toc}{tikz}{
\tikz\path(temp node)+(0,-1)node(temp node){}+(12,0)node[right]{\inserttocsubsubsection};
}
\defbeamertemplate*{subsubsection in toc shaded}{tikz}[1][.2]{
\tikz\path(temp node)+(0,-1)node(temp node){}+(12,0)node[right,opacity=#1]{\inserttocsubsubsection};
}
\frame{{Ti\emph kZ TOC}
\tikz\path(current page.north west)+(12,-1)node(temp node){};\tableofcontents
}
\frame{{Ti\emph kZ TOC}
\tikz\path(current page.north west)+(12,-1)node(temp node){};\tableofcontents[currentsection]
}
\frame{{Ti\emph kZ TOC}
\tikz\path(current page.north west)+(12,-1)node(temp node){};\tableofcontents[hideothersubsections]
}
通过更多的工作,你可以实现
\tikzset{
every picture/.style={remember picture,overlay,scale=1},
Signal/.style={fill,signal,signal from=west,minimum width=3cm,minimum height=1cm},
Secnal/.style={shift={(0,-.5)},right,rotate=-70,opacity=#1},
Subsecnal/.style={below right,rotate=-60,opacity=#1},
Subsubsecnal/.style={below right,rotate=-50,opacity=#1},
}
\defbeamertemplate*{section in toc}{fabulous}{
\tikz\path(temp section)+(3,0)node[Signal,blue](temp section){}node[Secnal= 1](true section){\inserttocsection}(true section.north east)node(temp subsection){};
}
\defbeamertemplate*{section in toc shaded}{fabulous}[1][.5]{
\tikz\path(temp section)+(3,0)node[Signal,gray](temp section){}node[Secnal=#1](true section){\inserttocsection}(true section.north east)node(temp subsection){};
}
\defbeamertemplate*{subsection in toc}{fabulous}{
\tikz\path(temp subsection)node[Subsecnal= 1](true subsection){$>$\inserttocsubsection}(true subsection.south west)node(temp subsection){}(true subsection.north east)node(temp subsubsection){};
}
\defbeamertemplate*{subsection in toc shaded}{fabulous}[1][.2]{
\tikz\path(temp subsection)node[Subsecnal=#1](true subsection){$>$\inserttocsubsection}(true subsection.south west)node(temp subsection){}(true subsection.north east)node(temp subsubsection){};
}
\defbeamertemplate*{subsubsection in toc}{fabulous}{
\tikz\path(temp subsubsection)node[Subsubsecnal= 1](true subsubsection){$-$\inserttocsubsubsection}(true subsubsection.north east)node(temp subsubsection){};
}
\defbeamertemplate*{subsubsection in toc shaded}{fabulous}[1][.2]{
\tikz\path(temp subsubsection)node[Subsubsecnal=#1](true subsubsection){$-$\inserttocsubsubsection}(true subsubsection.north east)node(temp subsubsection){};
}
\frame{{Fabulous TOC}
\tikz\path(current page.north west)+(0,-2)node(temp section){};\tableofcontents
}
\frame{{Fabulous TOC}
\tikz\path(current page.north west)+(0,-2)node(temp section){};\tableofcontents[currentsection]
}
\frame{{Fabulous TOC}
\tikz\path(current page.north west)+(0,-2)node(temp section){};\tableofcontents[hideothersubsections]
}
\end{document}