connect different tikz pictures on the same page


/ Published in: LaTeX
Save to your folder(s)

[overlay] tells Tikz not to compute a bounding box for the picture. Otherwise the bounding box will include all referenced nodes


Copy this code and paste it in your HTML
  1. \usetikzlibrary{shapes}
  2. \tikzstyle{every picture}+=[remember picture]
  3.  
  4. \begin{tikzpicture}
  5. \node (a) at (0,0) [rectangle, draw] {};
  6. \end{tikzpicture}
  7. abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc abc
  8. \begin{tikzpicture}
  9. \node (b) at (0,0) [circle, draw] {};
  10. \end{tikzpicture}
  11.  
  12. \begin{tikzpicture}[overlay]
  13. \draw (a) -- (b);
  14. \end{tikzpicture}

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.