Closed RaphaelWimmer closed 4 years ago
\def\SVG@cmd@inkscape{inkscape -z -C}%
is nowhere in the code since release v2.00 so you are probably using a very old version of package svg.sty
.
Oh, sorry - I just found this line in the current svg.dtx. Why is it there?
Edit: oh:
% \section{Old Implementation}
Sorry for wasting your time. I was using an old version of the package and misunderstood the code because I just Ctrl-F-ed '-z'). I'll upgrade svg.sty. Thank you for your work!
In my local 2.02b svg.sty, "-z" is here (and this version is causing problems with Inkscape 1.0):
\ProvidesPackage{svg}[%
2018/11/12 v2.02b\space%
(include SVG pictures)
[...]
\newcommand*\svg@ink@cmd[2]{%
\svg@ink@exe\space-z\space\svg@ink@area\space%
(Debian package texlive-latex-extra, version: 2018.20190227-2)
Oh, sorry - I just found this line in the current svg.dtx. Why is it there?
When I took over the maintenance of the package, users with compatibility problems should be able to work around them and build the old version v1.0
locally with svg.dtx. Since the new user interface has been official for more than 3 years now, I will remove this part with the next main release v2.03
.
In my local 2.02b svg.sty, "-z" is here (and this version is causing problems with Inkscape 1.0):
\newcommand*\svg@ink@cmd[2]{% \svg@ink@exe\space-z\space\svg@ink@area\space%
That's the cause of the problem and was resolved with v2.02f
. See https://github.com/mrpiggi/svg/blob/1014d8c67955ecfb5cd9a7acaf1f07567ccb6024/source/svg.dtx#L2309-L2320
This is a continuation of Issue #20 regarding support for Inkscape 1.0.
Maybe I am missing something but it seems the code still uses the
-z
flag for all Inkscape versions:\def\SVG@cmd@inkscape{inkscape -z -C}%
However,
-z
is just an alias for--without-gui
(see e.g. Issue #8 ) so it probably should be removed from the above definition. The package already sets the--without-gui
flag for Inkscape 0.x so there is no need to set it via-z
. Calling Inkscape 1.0 with-z
will cause it to fail with error messageUnknown option -z
.(Inkscape 1.0 dropped the
--without-gui
flag completely man page and automatically runs export commands without GUI unless specified with--with-gui
.)Solution would probably be to just change this line to:
\def\SVG@cmd@inkscape{inkscape -C}%
or even better (because more verbose):
\def\SVG@cmd@inkscape{inkscape --export-area-page}%