对 TikZ 图片使用“外部”选择

对 TikZ 图片使用“外部”选择

对于以下示例:

\documentclass{beamer}

\usepackage[utf8]{inputenc}
\usepackage{tikz}
\usetikzlibrary{calc,external}
\usepackage{pgfplots}
\tikzexternalize

\begin{document}
\tikzstyle{every picture}+=[remember picture]
% following doesn't work
% \tikzset{every baseline/.append code={external/export=false}}
% \tikzstyle{every baseline}+=[external/export=false]
% \tikzstyle{every overlay}+=[external/export=false]

\begin{frame}
  \frametitle{Frame Title}
  \begin{itemize}
  \item first item with longer sentences 
      and a \tikz[baseline]{\node[inner xsep=0pt,
      anchor=base, fill=red!60](n1){node};}
  \item second item with pgf plot: \\
    \begin{tikzpicture}
      \begin{axis}[width=7cm,height=5cm]
        \addplot[color=blue]{sin(deg(x))};
      \end{axis}
    \end{tikzpicture}
  \item third item with \tikz[baseline]{\node[inner xsep=0pt,
      anchor=base, fill=red!60](n2){node};}
  \end{itemize}

  \begin{tikzpicture}[overlay,>=latex, shorten >= 3pt, shorten <=3pt]
    \draw[-,red!60,ultra thick](n1.east) -- ($(n1.east) + (.5,0)$)
    |- (n2.east);
  \end{tikzpicture}

\end{frame}
\end{document}

%%% Local Variables: 
%%% mode: latex
%%% LaTeX-command: "latex -shell-escape"
%%% TeX-PDF-mode: t
%%% TeX-master: t
%%% End: 

是否存在一种聪明/懒惰的方法(=一些全局设置)来不外部化所有tikz 图片 overlaybaseline

编辑:
现在使用external/named only=true然后明确命名 pgfplots\tikzsetnextfilename{filename}

相关内容