summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/latex-make/figlatex.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-06-08 21:20:13 +0000
committerKarl Berry <karl@freefriends.org>2020-06-08 21:20:13 +0000
commitd25c2909171999d6094a1a8e5711cfe94502c943 (patch)
tree3b3252c497997a5a8ec3308962cd4832b804f849 /Master/texmf-dist/tex/latex/latex-make/figlatex.sty
parent323c05e60169fcb6fa9dc6a9d3db42de5c869f6c (diff)
latex-make (8jun20)
git-svn-id: svn://tug.org/texlive/trunk@55486 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/latex-make/figlatex.sty')
-rw-r--r--Master/texmf-dist/tex/latex/latex-make/figlatex.sty51
1 files changed, 20 insertions, 31 deletions
diff --git a/Master/texmf-dist/tex/latex/latex-make/figlatex.sty b/Master/texmf-dist/tex/latex/latex-make/figlatex.sty
index fb2326d8294..922be37af91 100644
--- a/Master/texmf-dist/tex/latex/latex-make/figlatex.sty
+++ b/Master/texmf-dist/tex/latex/latex-make/figlatex.sty
@@ -41,20 +41,12 @@
%%
\NeedsTeXFormat{LaTeX2e}%
\ProvidesPackage{figlatex}%
-[2018/10/17 v2.3.0 No changes in figlatex.dtx]
-\newif\ifFL@compatibility
-\DeclareOption{compatibility}{%
- %\PackageWarning{figlatex}{option compatibility}%
- \global\FL@compatibilitytrue%
-}
+[2020/06/01 v2.4.0 Fix support for new latex]
\newif\ifFL@debug
\DeclareOption{debug}{%
\global\FL@debugtrue%
}
{
- \def\compatibility{%
- \ExecuteOptions{compatibility}%
- }
\def\debug{%
\ExecuteOptions{debug}%
}
@@ -70,6 +62,7 @@
\RequirePackage{ifthen}
\RequirePackage{ifpdf}
\RequirePackage{graphicx}
+\RequirePackage{xstring}
\RequirePackage{color}
\RequirePackage{epstopdf}
\def\FL@dmessage#1{%
@@ -124,18 +117,9 @@
\def\FL@svgext{pdftex_t}%
\let\Gread@rawtex\Gread@pdf%
\DeclareGraphicsRule{.pdftex}{pdf}{*}{}%
- \ifFL@compatibility%
- \PackageWarningNoLine{figlatex}{Compatibility mode enabled
- for old LaTeX
- \MessageBreak Using .pdf extension for pdftex files}%
- \DeclareGraphicsRule{.pdftex_t}{rawtex}{.pdf}{}%
- \DeclareGraphicsRule{.fig}{figtex}{.pdf}{}%
- \DeclareGraphicsRule{.svg}{svgtex}{.pdf}{}%
- \else%
- \DeclareGraphicsRule{.pdftex_t}{rawtex}{.pdftex}{}%
- \DeclareGraphicsRule{.fig}{figtex}{.pdftex}{}%
- \DeclareGraphicsRule{.svg}{svgtex}{.pdftex}{}%
- \fi%
+ \DeclareGraphicsRule{.pdftex_t}{rawtex}{.pdftex}{}%
+ \DeclareGraphicsRule{.fig}{figtex}{.pdftex}{}%
+ \DeclareGraphicsRule{.svg}{svgtex}{.pdftex}{}%
\else
\def\FL@figext{pstex_t}%
\def\FL@svgext{pstex_t}%
@@ -151,22 +135,26 @@
\def\FL@exclamation{!}%
\let\FL@subfig@name\FL@exclamation%
\define@key{Gin}{subfig}{%
+ \typeout{using subfig #1}%
\def\FL@subfig@name{#1}%
}
\def\FL@sepdefault{_}%
\def\FL@subfig@check#1{%
}
\def\FL@Gin@getbase#1{%
+ \typeout{In getbase #1 with \FL@subfig@name / \FL@exclamation}%
\ifx\FL@subfig@name\FL@exclamation%
\else%
- \ifthenelse{\equal{#1}{.fig}}{%
+ \typeout{getbase lets go (\filename@area)(\filename@base)(#1)}%
+ \IfStrEq*{#1}{.fig}{%
% If we're including a subfig
\IfFileExists{\filename@area\filename@base#1}{%
% If the original .fig file exists, just change the name so that
- % it comprises the full path.
- \filename@parse{\@filef@und}%
- % Remove potential trailing spage at the end of the extension
- \def\filename@ext{fig}%
+ % it comprises the full path (file has been looked into
+ % texgraphics, etc.)
+ % Warning: the found filename is quoted :-(
+ \StrBetween[1,2]{\@filef@und}{"}{"}[\FL@filename@unquoted]
+ \filename@parse{\FL@filename@unquoted}%
% Check if the subfig file exists
\FL@subfig@check{\filename@area\filename@base.subfig}%
}{%
@@ -179,14 +167,15 @@
\edef\filename@base{\filename@base\FL@sepdefault\FL@subfig@name}%
}{%
}%
- \ifthenelse{\equal{#1}{.svg}}{%
+ \IfStrEq*{#1}{.svg}{%
% If we're including a subfig
\IfFileExists{\filename@area\filename@base#1}{%
% If the original .svg file exists, just change the name so that
- % it comprises the full path.
- \filename@parse{\@filef@und}%
- % Remove potential trailing spage at the end of the extension
- \def\filename@ext{svg}%
+ % it comprises the full path (file has been looked into
+ % texgraphics, etc.)
+ % Warning: the found filename is quoted :-(
+ \StrBetween[1,2]{\@filef@und}{"}{"}[\FL@filename@unquoted]
+ \filename@parse{\FL@filename@unquoted}%
% Check if the subfig file exists
\FL@subfig@check{\filename@area\filename@base.subfig}%
}{%