JP-Ellis / tikz-feynman

Feynman Diagrams with TikZ
http://www.jpellis.me/projects/tikz-feynman
Other
148 stars 20 forks source link

Reuse diagram #68

Open Turgon-Aran-Gondolin opened 4 years ago

Turgon-Aran-Gondolin commented 4 years ago

In feynmf, there's a command called \fmfreuse, it enables us to reuse the diagram created earlier with a key. As pointed out in Assign a name to a TikZ picture for reusing it, they can use \tikzset to do the job, but that's too inconvenient. The method in my mind would be like what the op stated:

\begin{tikzpicture}[rname=mypic]
%...
\end{tikzpicture}

And it seems the 2nd answer did just that, but I'm not sure if his method breaks thing. Do you have any solution in mind?