[Tex/LaTex] SVG from Inkscape to LaTeX ruins typesetting

convertinkscapesvg

I would like to use the .pdf_tex option for my SVG images exported from Inkscape because it's an amazing feature but it doesn't work as intended.

What I do:

  1. Export image from Inkscape

  2. Integrate into TeX by

    \begin{figure}
        \centering
        \def\svgwidth{\columnwidth}
        \input{N1N2N3.pdf_tex}
    \end{figure}
    
  3. Compile

Result:

In the PDF

enter image description here

My original SVG:

enter image description here

So thats not what I expected.
Can you help me to get it tidy and neat?

So I fixed it partly by using

\begin{center}
\resizebox{2in}{!}{\input{inkscapeout.pdf_tex}}
\end{center}

to scale text and image together but I still got a problem with the xlabel of the graph because the numbers are moved into the graph and also the legend is moved a little upward.

New result

enter image description here

I uploaded my original svg-file here

https://owncloud.tu-berlin.de/index.php/s/8pRPwotDkiS0C5K

Best Answer

Selecting a smaller font size should probably improve the result. Unfortunately the external link to the .svg file is death, so I can just guess a value

\begin{figure}
    \fontsize{6pt}{7pt}\selectfont
    \centering
    \def\svgwidth{\columnwidth}
    \input{N1N2N3.pdf_tex}
\end{figure}

Alternatively you could increase the font size in the original .svg (or whatever program you used to produce the graph).

Related Question