Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Maybe a bug in beamer, works OK while using the minimal document class.

Again, following the example over there, and also after playing with Circling/framing and referring to a bunch of nodes, the following doesn't work as expected:

\documentclass[ignorenonframetext,xcolor={table,svgnames}]{beamer}
%\documentclass{minimal}

\usepackage{tikz}
\usetikzlibrary{shapes,backgrounds,fit,positioning}

\begin{document}

\tikzstyle{every picture}+=[remember picture]


\begin{frame}

  \tikzstyle{na} = [baseline=-.5ex]

  \begin{tabular}{ll}
    Blah & $=$ Again blah 
    \tikz[na] \node[coordinate] (blah) {};\\ 
    Foo & $+$ Bar \\
    Buggy & $=$
    \tikz[baseline]{
      \node[rounded corners,fill=red!15,anchor=base] (bug)
      {Bug};
    }
  \end{tabular}

  \bigskip

 This is also buggy, booh \tikz[na] \node[coordinate] (booh) {};

  \begin{tikzpicture}[overlay]
    \path[very thick,->] (blah) edge [bend right] (bug);
    \path[very thick,->] (booh) edge [bend left] (bug);
  \end{tikzpicture}  

\end{frame}

\end{document}

I just found the culprit, it is the ignorenonframetext option!! But why is it so?

share|improve this question
    
I just found the culprit, it is the ignorenonframetext option!! But why is it so? –  green diod Dec 3 '12 at 1:34
2  
It's beaceuse \tikzstyle{every picture}+=[remember picture] is outside the frame and inside the body of the document, so ignorenonframetext just ignores the remember picture` part. –  Gonzalo Medina Dec 3 '12 at 1:48

1 Answer 1

up vote 6 down vote accepted

The problem is that \tikzstyle{every picture}+=[remember picture] is outside the frame and inside the body of the document, so ignorenonframetext just ignores the remember picture part. You can send this to the preamble (to make it global) or inside the frame environment (notice that I used \tikzset instead of the obsolete \tikzstyle):

\documentclass[ignorenonframetext,xcolor={table,svgnames}]{beamer}
\usepackage{tikz}
\usetikzlibrary{shapes,backgrounds,fit,positioning}

\tikzset{every picture/.style={remember picture}}

\begin{document}

\begin{frame}
  \tikzset{na/.style={baseline=-.5ex}}

  \begin{tabular}{ll}
    Blah & $=$ Again blah 
    \tikz[na] \node[coordinate] (blah) {};\\ 
    Foo & $+$ Bar \\
    Buggy & $=$
    \tikz[baseline]{
      \node[rounded corners,fill=red!15,anchor=base] (bug)
      {Bug};
    }
  \end{tabular}

  \bigskip

 This is also buggy, booh \tikz[na] \node[coordinate] (booh) {};

  \begin{tikzpicture}[overlay]
    \path[very thick,->] (blah) edge [bend right] (bug);
    \path[very thick,->] (booh) edge [bend left] (bug);
  \end{tikzpicture}  

\end{frame}

\end{document}

enter image description here

share|improve this answer
    
Good!! Thanks for the explanation of the interaction of the ignorenonframetext option and the 'tikzset' location. I didn't know tikzstyle was obsolete. Point taken. –  green diod Dec 3 '12 at 2:05

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.