texlive[52500] Master/texmf-dist: svg (23oct19)
commits+karl at tug.org
commits+karl at tug.org
Wed Oct 23 23:39:18 CEST 2019
Revision: 52500
http://tug.org/svn/texlive?view=revision&revision=52500
Author: karl
Date: 2019-10-23 23:39:18 +0200 (Wed, 23 Oct 2019)
Log Message:
-----------
svg (23oct19)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/latex/svg/README.md
trunk/Master/texmf-dist/doc/latex/svg/svg.pdf
trunk/Master/texmf-dist/source/latex/svg/svg.dtx
trunk/Master/texmf-dist/tex/latex/svg/svg-extract.sty
trunk/Master/texmf-dist/tex/latex/svg/svg.sty
Modified: trunk/Master/texmf-dist/doc/latex/svg/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/svg/README.md 2019-10-23 21:38:48 UTC (rev 52499)
+++ trunk/Master/texmf-dist/doc/latex/svg/README.md 2019-10-23 21:39:18 UTC (rev 52500)
@@ -1,15 +1,15 @@
- svg and svg-extract -- Include and extract SVG pictures in LaTeX documents
+ svg and svg-extract – Handling SVG pictures in LaTeX documents
----------------------------------------------------------------------------
- Copyright (C) Philip Ilten <philten at cern.ch>, 2012-2016
+ Copyright (C) Philip Ilten <philten at cern.ch>, 2012-2016<br>
Copyright (C) Falk Hanisch <hanisch.latex at outlook.com>, 2017-
- svg 2019/10/10 v2.02c
+ svg 2019/10/22 v2.02d
----------------------------------------------------------------------------
- This material is subject to the LaTeX Project Public License version 1.3c
+ This material is subject to the LaTeX Project Public License version 1.3c
or later. See http://www.latex-project.org/lppl.txt for details.
----------------------------------------------------------------------------
@@ -18,34 +18,45 @@
Summary
-------
-The **svg** package is intended for the automated integration of SVG graphics
-into LaTeX documents. Therefor the capabilities provided by ***Inkscape***---or
-more precisely its command line tool---are used to export the text within a SVG
-graphic to a separate file, which is then rendered by LaTeX. For this purpose
-the two commands `\includesvg` and `\includeinkscape` are provided which are
-very similar to the `\includegraphics` command of the **graphicx** package.
+The **svg** package provides an user‑interface for automated integration
+of SVG graphics created with ***Inkscape*** into LaTeX documents.
+Therefor the capabilities provided by ***Inkscape***—and its command line
+tool—are used to export the text within a SVG graphic to a separate
+file, which is then rendered by LaTeX. The two commands `\includesvg` and
+`\includeinkscape` are provided as central user‑interface, which are very
+similar to the `\includegraphics` command of the **graphicx** package.
-In addition, the package **svg-extract** allows the extraction of these
-graphics into independent files in different graphic formats, exactly as
-it is rendered within the LaTeX document using either ***ImageMagick*** or
-***Ghostscript***
+In addition, the package **svg-extract** extends the user‑interface of
+package **svg** in order to support the extraction of these graphics into
+independent files in different graphic formats, exactly as they are rendered
+within the LaTeX document. For the creation of these graphics in the
+well‑known formats PDF, EPS and PS, LaTeX and possibly conversion
+tools shipped with the most LaTeX distributions are used. If the graphics are
+required in other file formats, either ***ImageMagick*** or ***Ghostscript***
+can be invoked.
Versions
--------
+**v2.02d** (2019/10/22)
++ fix bugs with current kernel (2019/10/01) regarding file name parsing, see
+ https://github.com/mrpiggi/svg/issues/16
++ use `\filemoddate` with XeLaTeX, see https://github.com/mrpiggi/svg/issues/12
+
**v2.02c** (2019/10/10)
+ fix bugs with current kernel (2019/10/01) regarding file name parsing
**v2.02b** (2018/11/12)
-+ fix bug for package **tikzscale** which changes `includgraphics` globally
++ fix bug for package **tikzscale** which changes the definition of
+ `\includegraphics`
**v2.02a** (2018/10/17)
+ fix bug for package **polyglossia** which fakes **babel** poorly
**v2.02** (2018/09/08)
-+ distortion of included and extracted graphics supported with options `distort`
- (or `keepaspectratio`) and `extractdistort` as well as rotation for
++ distortion of included and extracted graphics supported with options `distort`
+ (or `keepaspectratio`) and `extractdistort` as well as rotation for
extractions (`extractangle`)
+ fixed errors with active double qoutes from **babel** in path arguments
+ multiple dots within file names possible
@@ -72,8 +83,8 @@
+ **svg-extract**: enhanced support for ***ImageMagick***
+ **svg-extract**: support for ***Ghostscript*** added
+ package **subfig** not required anymore
-+ support of subfigures stopped due to the huge number of packages which deal
- with this topic and the large variety of implementing this functionality;
++ support of subfigures stopped due to the huge number of packages which deal
+ with this topic and the large variety of implementing this functionality;
naming exported graphics after their consecutive numbering can't be ensured
for all variants of subfigures, so it's neglected
Modified: trunk/Master/texmf-dist/doc/latex/svg/svg.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/source/latex/svg/svg.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/svg/svg.dtx 2019-10-23 21:38:48 UTC (rev 52499)
+++ trunk/Master/texmf-dist/source/latex/svg/svg.dtx 2019-10-23 21:39:18 UTC (rev 52500)
@@ -1,4 +1,4 @@
-% \CheckSum{3838}
+% \CheckSum{3884}
% \iffalse meta-comment
%
% svg and svg-extract -- Include and extract SVG pictures in LaTeX documents
@@ -111,11 +111,11 @@
\ifx\ProvidesFile\@undefined\def\ProvidesFile#1[#2]{}\fi
\ProvidesFile{svg.dtx}[%
%</driver>
-%<package&option>\NeedsTeXFormat{LaTeX2e}
+%<package&option>\NeedsTeXFormat{LaTeX2e}[2019-10-01]
%<package&option&base>\ProvidesPackage{svg}[%
%<package&option&extract>\ProvidesPackage{svg-extract}[%
%<*driver|package&option>
- 2019/10/10 v2.02c\space%
+ 2019/10/22 v2.02d\space%
%<package&option&base> (include SVG pictures)%
%<package&option&extract> (extract independent graphics from SVG pictures)%
]
@@ -260,6 +260,10 @@
% \changes{v2.02c}{2019/10/10}{%
% fix bugs with current kernel (2019/10/01) regarding file name parsing
% }^^A
+% \changes{v2.02d}{2019/10/22}{%
+% fix bugs with current kernel (2019/10/01) regarding file name parsing, see
+% \url{https://github.com/mrpiggi/svg/issues/16}
+% }^^A
% \ToDo{Workaround for missing \cs{transparent} (Lua\TeX lacks support)}[v2.03]
%
%
@@ -410,9 +414,7 @@
% graphic~file either does not exist or the file~modification date of the
% SVG~file is newer than that of the exported graphic~file. Thus the
% compilation time of the \LaTeX~document can be reduced to the necessary
-% minimum. Unfortunately a primitive like \cs{pdffilemoddate} is missing for
-% XeTeX, so with this engine, the behaviour will be the same as
-% \opt{inkscape}|=|\val{forced}.
+% minimum.
% \item[forced/force/overwrite]
% The \app{Inkscape}~export will definitely be done, any already existing
% exported file will overwritten regardlessly.
@@ -601,13 +603,8 @@
% PDF/EPS/PS/PNG~file (see~\opt{inkscapeformat}) and perhaps a correlating
% \LaTeX~file (see~\opt{inkscapelatex}). The export with \app{Inkscape} is only
% invoked, if the SVG~file is newer than the exported graphic~file or latter
-% doesn't exist at all.\footnote{\ignorespaces%
-% Due to the lack of XeTeX to compare file~modification dates, using this
-% \LaTeX~engine leads to \app{Inkscape}~exports with every run unless
-% \opt{inkscape}|=|\val{false} is used.%
-% }%
-% Once the export has been done, the graphic~file and maybe the \LaTeX~file are
-% included.
+% doesn't exist at all. Once the export has been done, the graphic~file and
+% maybe the \LaTeX~file are included.
%
% All previously described options can also be used as optional parameters to
% \cs{includesvg} and do have the same effect as described before. However, the
@@ -2283,6 +2280,10 @@
% \begin{macrocode}
\@svg at tempswafalse%
\expandafter\IfFileExists\expandafter{\svg at tempa}{%
+ \expandafter\svg at quotes@check\expandafter{\svg at tempa}%
+ \if at svg@quotes at found\else%
+ \svg at quotes@remove{\@filef at und}%
+ \fi%
\@svg at tempswatrue%
\edef\@filef at und{\expandafter\trim at spaces\expandafter{\@filef at und}}%
\svg at filename@parse[{#1}]{\@filef at und}%
@@ -2499,25 +2500,45 @@
% \end{macrocode}
% \end{macro}^^A \svg at file@missing
% \begin{macro}{\svg at iffilenewer}
+% \changes{v2.02d}{2019/10/22}{%
+% use \cs{filemoddate} with Xe\LaTeX, see
+% \url{https://github.com/mrpiggi/svg/issues/12}
+% }^^A
% The macro \cs{svg at iffilenewer} is used to decide, whether the export with
% \app{Inkscape} is necessary due to an updated SVG~file. This can only be
-% done, if \cs{pdf at filemoddate} is definied. Unfortunately this functionality
-% isn't provided by Xe\TeX.
+% done, if \cs{pdf at filemoddate} or \cs{filemoddate} is definied.
% \begin{macrocode}
+\newcommand*\svg at iffilenewer[2]{\@gobbletwo}
\ifx\pdf at filemoddate\@undefined
- \newcommand*\svg at iffilenewer[2]{\@gobbletwo}
+ \ifx\filemoddate\@undefined\else
+ \ifx\strcmp\@undefined\else
+ \renewcommand*\svg at iffilenewer[2]{%
+ \begingroup%
+ \edef\svg at tempa{\filemoddate{#1}}%
+ \edef\svg at tempb{\filemoddate{#2}}%
+ \ifnum\strcmp{\svg at tempa}{\svg at tempb}>\z@\relax%
+ \aftergroup\@firstoftwo%
+ \else%
+ \aftergroup\@secondoftwo%
+ \fi%
+ \endgroup%
+ }%
+ \fi
+ \fi
\else
- \newcommand*\svg at iffilenewer[2]{%
- \begingroup%
- \edef\svg at tempa{\pdf at filemoddate{#1}}%
- \edef\svg at tempb{\pdf at filemoddate{#2}}%
- \ifnum\pdf at strcmp{\svg at tempa}{\svg at tempb}>\z@\relax%
- \aftergroup\@firstoftwo%
- \else%
- \aftergroup\@secondoftwo%
- \fi%
- \endgroup%
- }
+ \ifx\pdf at strcmp\@undefined\else
+ \renewcommand*\svg at iffilenewer[2]{%
+ \begingroup%
+ \edef\svg at tempa{\pdf at filemoddate{#1}}%
+ \edef\svg at tempb{\pdf at filemoddate{#2}}%
+ \ifnum\pdf at strcmp{\svg at tempa}{\svg at tempb}>\z@\relax%
+ \aftergroup\@firstoftwo%
+ \else%
+ \aftergroup\@secondoftwo%
+ \fi%
+ \endgroup%
+ }%
+ \fi
\fi
% \end{macrocode}
% \end{macro}^^A \svg at iffilenewer
Modified: trunk/Master/texmf-dist/tex/latex/svg/svg-extract.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/svg/svg-extract.sty 2019-10-23 21:38:48 UTC (rev 52499)
+++ trunk/Master/texmf-dist/tex/latex/svg/svg-extract.sty 2019-10-23 21:39:18 UTC (rev 52500)
@@ -31,9 +31,9 @@
%% svg-example.svg, svg-preamble.tex and root.C (with derived file root.svg).
%%
%%
-\NeedsTeXFormat{LaTeX2e}
+\NeedsTeXFormat{LaTeX2e}[2019-10-01]
\ProvidesPackage{svg-extract}[%
- 2019/10/10 v2.02c\space%
+ 2019/10/22 v2.02d\space%
(extract independent graphics from SVG pictures)%
]
\RequirePackage{svg}[2017/03/27]
Modified: trunk/Master/texmf-dist/tex/latex/svg/svg.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/svg/svg.sty 2019-10-23 21:38:48 UTC (rev 52499)
+++ trunk/Master/texmf-dist/tex/latex/svg/svg.sty 2019-10-23 21:39:18 UTC (rev 52500)
@@ -31,9 +31,9 @@
%% svg-example.svg, svg-preamble.tex and root.C (with derived file root.svg).
%%
%%
-\NeedsTeXFormat{LaTeX2e}
+\NeedsTeXFormat{LaTeX2e}[2019-10-01]
\ProvidesPackage{svg}[%
- 2019/10/10 v2.02c\space%
+ 2019/10/22 v2.02d\space%
(include SVG pictures)%
]
\RequirePackage{scrbase}[2016/06/14]
@@ -611,6 +611,10 @@
\svg at set@input at path[{#3}]%
\@svg at tempswafalse%
\expandafter\IfFileExists\expandafter{\svg at tempa}{%
+ \expandafter\svg at quotes@check\expandafter{\svg at tempa}%
+ \if at svg@quotes at found\else%
+ \svg at quotes@remove{\@filef at und}%
+ \fi%
\@svg at tempswatrue%
\edef\@filef at und{\expandafter\trim at spaces\expandafter{\@filef at und}}%
\svg at filename@parse[{#1}]{\@filef at und}%
@@ -745,20 +749,37 @@
}{\svg at tempa}%
\endgroup%
}
+\newcommand*\svg at iffilenewer[2]{\@gobbletwo}
\ifx\pdf at filemoddate\@undefined
- \newcommand*\svg at iffilenewer[2]{\@gobbletwo}
+ \ifx\filemoddate\@undefined\else
+ \ifx\strcmp\@undefined\else
+ \renewcommand*\svg at iffilenewer[2]{%
+ \begingroup%
+ \edef\svg at tempa{\filemoddate{#1}}%
+ \edef\svg at tempb{\filemoddate{#2}}%
+ \ifnum\strcmp{\svg at tempa}{\svg at tempb}>\z@\relax%
+ \aftergroup\@firstoftwo%
+ \else%
+ \aftergroup\@secondoftwo%
+ \fi%
+ \endgroup%
+ }%
+ \fi
+ \fi
\else
- \newcommand*\svg at iffilenewer[2]{%
- \begingroup%
- \edef\svg at tempa{\pdf at filemoddate{#1}}%
- \edef\svg at tempb{\pdf at filemoddate{#2}}%
- \ifnum\pdf at strcmp{\svg at tempa}{\svg at tempb}>\z@\relax%
- \aftergroup\@firstoftwo%
- \else%
- \aftergroup\@secondoftwo%
- \fi%
- \endgroup%
- }
+ \ifx\pdf at strcmp\@undefined\else
+ \renewcommand*\svg at iffilenewer[2]{%
+ \begingroup%
+ \edef\svg at tempa{\pdf at filemoddate{#1}}%
+ \edef\svg at tempb{\pdf at filemoddate{#2}}%
+ \ifnum\pdf at strcmp{\svg at tempa}{\svg at tempb}>\z@\relax%
+ \aftergroup\@firstoftwo%
+ \else%
+ \aftergroup\@secondoftwo%
+ \fi%
+ \endgroup%
+ }%
+ \fi
\fi
\newcommand*\svg at local@param at set[1]{%
\svg at local@param at use%
More information about the tex-live-commits
mailing list