1

I have an image, let's use this one from my thesis:

A .svg file made inside Inkscape with long latex equations.

that I include in my document using:

\begin{figure}
    \centering
    \includesvg[width=\textwidth]{zeeman}
    \caption{Caption}
    \label{fig:theory:zeeman}
\end{figure}

and it makes a nice image... except for the fact that clearly the width is calculated pre "compilation" and therefore is not correct:

A .svg rendered inside a PDF document, it does not span the width of the text..

I've looked at A link to the svg package documentation and on the tex exchange and all I can find are people who make neater images than me :D Is there a way I can ask latex to set the figure size post "compilation" or some other hack?

Thanks :)

0

1 Answer 1

0

I recommend svg2tikz, used as an plugin in Inkscape instead of \includesvg

There were some real problems with newer versions of Inkscape, but they were fixed last week so it works again.

The advantage is you get real tikz code, and can edit it as you see fit. The tikz code is not without some flaws. In particular, I've had to go in and rotate node labels manually -- but all those edits are straightforward if you're familiar with tikz. You don't get "how do I fix stuff that's not quite right" mysteries to solve.

Another advantage is not having to use ShellEscape.

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