When creating a standalone document to convert it into a PNG file, I get an error if I include the SVG package.
MWE
%\documentclass{standalone}
\documentclass[convert={density=720,outext=.png}]{standalone}
\usepackage{svg}
\begin{document}
\includesvg{se}
\end{document}
Without the convert option it works perfectly. With the convert option I get the following error:
(/usr/local/texlive/2020/texmf-dist/tex/latex/svg/svg.sty
Package: svg 2020/05/07 v2.02f (include SVG pictures)
(/usr/local/texlive/2020/texmf-dist/tex/latex/koma-script/scrbase.sty
Package: scrbase 2020/04/19 v3.30 KOMA-Script package (KOMA-Script-independent basics and keyval usage)
! LaTeX Error: Missing \begin{document}.
See the LaTeX manual or LaTeX Companion for explanation.
Type H <return> for immediate help.
...
l.478 \FamilyProcessOptions{KOMA}
\relax
?
! Emergency stop.
I have tried to compile using both, pdftex and luatex, and get the same result.
Does anyone know what the reason for this error is, and how to solve it? Thanks for the help beforehand!
se.svg
?svg.sty
is loaded:Class standalone Warning: Conversion failed! Please ensure that shell escape (standalone) is enabled (e.g. use '-shell-escape').
svg
package, not the\includesvg{se}
. If I replace\includesvg{se}
bytest
in your MWE and compiles withpdflatex --shell-escape file.tex
I get the same errorscrbase.sty
in this context or what ever it issvg
is trying to do.\documentclass[convert]{standalone} \standaloneconfig{convert={density=720,outext=.png}}
could work.