6

I'm using Vaucanson-G to render automata (I also use TikZ, but here, I want Vaucanson-G). Because it uses PStricks although I want to compile with pdflatex, I have put all my automata in separated files, which I dvilatex|dvipdf|pdfcrop before \includegraphics. It works well, but I thought this was a typical example of use of standalone (standalone 2012/09/15 v1.1b).

However, the bounding-box is dead wrong.

On the following input:

\documentclass{standalone}
\usepackage{vaucanson-g}

\begin{document}
\VCDraw{%
  \begin{VCPicture}[-0.9]{(-1.4,-1.4cm)(5.4,1.4cm)}
    \State{(0,0)}{A}
    \State{(4,0)}{C}
    \Initial{A}\Final{C}
    \EdgeL{A}{C}{b}
    \LoopN[.5]{A}{a + b}
    \LoopN[.5]{C}{2a + 2b}
  \end{VCPicture}
}
\end{document}

it produces (missing labels on top, too much space below, overall it seems that the BBox is shifted downward)

Vaucanson-G and standalone

whereas pdfcrop produces the expected result:

Vaucanson-G and pdfcrop

Is there something I can do to get the expected result? Thanks!

1 Answer 1

3

standalone uses the coordinates of the pspicture environment for the clipping. Your y coordinate is too small. Use:

\begin{VCPicture}[-0.9]{(-1.4,-1.4cm)(5.4,2.8cm)}
2
  • Ah! Ok, thanks a lot! I wonder why the problem of the coordinates never shows when the Vaucanson-G picture is inline in a regular article (with text around it etc.). Also, is there a means to have a tool report the proper coordinates?
    – akim
    Sep 23, 2013 at 11:37
  • no, there is no tool on TeX level. You can use auto-pst-pdf instead of standalone
    – user2478
    Sep 23, 2013 at 11:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .