2

i'm trying to export a TikZ picture to .eps using the following on Win7 (MikTeX), compiling with pdflatex:

\documentclass{article}
\usepackage{tikz}

\usetikzlibrary{external}
\tikzset{external/system call={pdflatex \tikzexternalcheckshellescape -halt-on-error 
-interaction=batchmode -jobname "\image" "\texsource" &&
pdftops -eps "\image".pdf}}
\tikzexternalize[shell escape=-enable-write18]

\begin{document}
\begin{tikzpicture}
\draw (0,0) circle (1cm);
\end{tikzpicture}
\end{document}}

For some reason, this does not yield any .eps file (the figure will only be exported as .pdf) - can somebody help me with this?

  • You can compile your code without that settings using latex and then convert the dvi to eps. – Sigur May 11 '13 at 16:21
  • Does it work manually? Here your example correctly calls pdftops -eps image.pdf. Do you get any error message? – Alexander May 11 '13 at 16:27
  • Welcome to TeX.SX! Usually, we don't put a greeting or a “thank you” in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Accepting and upvoting answers is the preferred way here to say “thank you” to users who helped you. – Peter Jansson May 11 '13 at 16:37
  • Note that TeX does not receive exit codes - if pdftops fails for some reason, it will assume that all is well and you do not get feedback. The external lib only checks if a "suitable" result file exists (I am unaware of options to receive the exit code, by the way) – Christian Feuersänger May 11 '13 at 18:24
  • 2
    For single diagrams you could also use the standalone class instead. – Martin Scharrer Jun 23 '13 at 12:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.