summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-12-19 22:11:59 +0000
committerKarl Berry <karl@freefriends.org>2019-12-19 22:11:59 +0000
commit8876a8021514f190d676e4e5261f1084a66754d3 (patch)
tree9a496107a312a1acbbdb06ea0e1657c285109729 /Master/texmf-dist/tex
parent693eacf895c01285e2992460bb489142ead8ae8a (diff)
pgf (19dec19)
git-svn-id: svn://tug.org/texlive/trunk@53187 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r--Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconstruct.code.tex6
-rw-r--r--Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.code.tex6
-rw-r--r--Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.code.tex2
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/datavisualization/tikzlibrarydatavisualization.code.tex4
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/graphs/tikzlibrarygraphs.standard.code.tex1
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzexternalshared.code.tex17
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarycalc.code.tex19
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryintersections.code.tex4
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryspy.code.tex14
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytopaths.code.tex2
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytrees.code.tex7
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryturtle.code.tex6
-rw-r--r--Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/tikz.code.tex127
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/circular/doc.lua15
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentAlign.lua31
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentDistance.lua12
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/doc.lua22
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/energybased/FMMMLayout.lua4
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/layered/SugiyamaLayout.lua4
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleEdgeDemo.lua5
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleHuffman.lua6
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlSprings.lua9
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlStart.lua26
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/ChildSpec.lua7
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/SpanningTreeComputation.lua9
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/doc.lua23
-rw-r--r--Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarybbox.code.tex94
-rw-r--r--Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryfpu.code.tex3
-rw-r--r--Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryintersections.code.tex9
-rw-r--r--Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarypatterns.meta.code.tex179
-rw-r--r--Master/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex2
-rw-r--r--Master/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex2
-rw-r--r--Master/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex66
-rw-r--r--Master/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex8
-rw-r--r--Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleparser.code.tex36
-rw-r--r--Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.code.tex5
-rw-r--r--Master/texmf-dist/tex/generic/pgf/pgf.revision.tex8
-rw-r--r--Master/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-dvipdfmx.def23
-rw-r--r--Master/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex20
-rw-r--r--Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex53
-rw-r--r--Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-context.def9
-rw-r--r--Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-plain.def9
-rw-r--r--Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.pdflinks.code.tex13
-rw-r--r--Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.prettyprinter.code.tex19
-rw-r--r--Master/texmf-dist/tex/latex/pgf/utilities/tikzexternal.sty12
45 files changed, 721 insertions, 237 deletions
diff --git a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconstruct.code.tex b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconstruct.code.tex
index c5b9ee1e99a..e7b8f98dd36 100644
--- a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconstruct.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconstruct.code.tex
@@ -130,9 +130,9 @@
\ifdim#1>\pgf@picmaxx\global\pgf@picmaxx#1\fi%
\ifdim#2<\pgf@picminy\global\pgf@picminy#2\fi%
\ifdim#2>\pgf@picmaxy\global\pgf@picmaxy#2\fi%
- \ifpgf@size@hooked%
- \let\pgf@size@hook@x#1\let\pgf@size@hook@y#2\pgf@path@size@hook%
- \fi%
+ \fi%
+ \ifpgf@size@hooked%
+ \let\pgf@size@hook@x#1\let\pgf@size@hook@y#2\pgf@path@size@hook%
\fi%
\ifdim#1<\pgf@pathminx\global\pgf@pathminx#1\fi%
\ifdim#1>\pgf@pathmaxx\global\pgf@pathmaxx#1\fi%
diff --git a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.code.tex b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.code.tex
index 028546dde89..15dfbbf1608 100644
--- a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.code.tex
@@ -851,11 +851,11 @@
\def\pgfpointxyz#1#2#3{%
\pgfmathparse{#1}%
- \global\let\pgftemp@x=\pgfmathresult%
+ \let\pgftemp@x=\pgfmathresult%
\pgfmathparse{#2}%
- \global\let\pgftemp@y=\pgfmathresult%
+ \let\pgftemp@y=\pgfmathresult%
\pgfmathparse{#3}%
- \global\let\pgftemp@z=\pgfmathresult%
+ \let\pgftemp@z=\pgfmathresult%
\global\pgf@x=\pgftemp@x\pgf@xx%
\global\advance\pgf@x by \pgftemp@y\pgf@yx%
\global\advance\pgf@x by \pgftemp@z\pgf@zx%
diff --git a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.code.tex b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.code.tex
index 3e292aa0383..27b9da97bbc 100644
--- a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.code.tex
@@ -456,14 +456,12 @@
\pgf@getpathsizes\pgf@interrupt@pathsizes%
\pgfsyssoftpath@getcurrentpath\pgf@interrupt@path%
\pgfsyssoftpath@setcurrentpath\pgfutil@empty%
- \edef\pgfscope@linewidth{\the\pgflinewidth}%
\let\pgf@interrupt@lastmoveto=\pgfsyssoftpath@lastmoveto%
\begingroup%
}
\def\endpgfinterruptpath
{%
\endgroup%
- \global\pgflinewidth=\pgfscope@linewidth%
\pgfsyssoftpath@setcurrentpath\pgf@interrupt@path%
\pgf@setpathsizes\pgf@interrupt@pathsizes%
\global\pgf@path@lastx\pgf@interrupt@savex%
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/datavisualization/tikzlibrarydatavisualization.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/datavisualization/tikzlibrarydatavisualization.code.tex
index 7f26cc00177..c56b29baae5 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/datavisualization/tikzlibrarydatavisualization.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/datavisualization/tikzlibrarydatavisualization.code.tex
@@ -887,9 +887,9 @@
\let\tikz@dv@at@list\pgfutil@empty%
\let\tikz@dv@style@at@list\pgfutil@empty%
\pgfkeysgetvalue{#2/scaling mapper}\tikz@lib@dv@mapper
- \expandafter\tikzdatavisualizationset\expandafter{\tikz@lib@dv@settings}%
\scope[/tikz/data visualization/.cd,every ticks/.try,every #1 ticks/.try,#3]%
% Setup options
+ \expandafter\tikzdatavisualizationset\expandafter{\tikz@lib@dv@settings}%
\pgfkeysgetvalue{/tikz/data visualization/common}\tikz@temp
\expandafter\tikzdatavisualizationset\expandafter{\tikz@temp}
\pgfkeysgetvalue{/tikz/data visualization/#1}\tikz@temp
@@ -1080,7 +1080,7 @@
\let\tikz@dv@style@at@list\pgfutil@empty
\pgfkeysgetvalue{#2/scaling mapper}\tikz@lib@dv@mapper
\let\tikz@lib@dv@ticks@default@at\pgfutil@empty%
- \scope[data visualization/grid layer,/tikz/data visualization/.cd,every grid,every #1 grid/.try,#3]
+ \scope[data visualization/grid layer,/tikz/data visualization/.cd,every #1 grid/.try,every grid,#3]
% Setup options
\pgfkeysgetvalue{#2/ticks at}\tikz@lib@dv@ticks@at%
\expandafter\tikzdatavisualizationset\expandafter{\tikz@lib@dv@settings}%
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/graphs/tikzlibrarygraphs.standard.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/graphs/tikzlibrarygraphs.standard.code.tex
index bfceb3769a5..c7f2daf7443 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/graphs/tikzlibrarygraphs.standard.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/graphs/tikzlibrarygraphs.standard.code.tex
@@ -10,6 +10,7 @@
\ProvidesFileRCS{tikzlibrarygraphs.standard.code.tex}
+\usetikzlibrary{graphs}%
%
% Basic graphs
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzexternalshared.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzexternalshared.code.tex
index 55b387f13c6..08fd794319b 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzexternalshared.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzexternalshared.code.tex
@@ -749,6 +749,13 @@
\fi
}
+% amsmath signals the first pass of aligned environments with measuring@true.
+% This is just \measuring@false in case \ifmeasuring@ is not defined
+\def\pgf@marshal{\let\ifmeasuring@\iffalse}
+\ifdefined\ifmeasuring@\else
+ \expandafter\pgf@marshal
+\fi
+
% Fills #1 with a filename for the current picture.
%
% The filename will be generated automatically by appending '-figure<number>' to the real jobname.
@@ -779,8 +786,10 @@
}{}%
\t@tikzexternal@tmpb=\expandafter{\tikzexternal@figurename}%
\xdef\pgf@tempa{\the\t@tikzexternal@tmpa\the\t@tikzexternal@tmpb\csname c@tikzext@no@\tikzexternal@figurename\endcsname}%
- % advance the counter for 'figure name':
- \tikzexternal@getnextfilename@advancecount
+ \ifmeasuring@\else
+ % advance the counter for 'figure name':
+ \tikzexternal@getnextfilename@advancecount
+ \fi
\fi
\else
\t@tikzexternal@tmpb=\expandafter{\tikzexternal@nextfile}%
@@ -798,7 +807,9 @@
\def\tikzexternal@getnextfilename@resetglobals{%
% Reset global flags:
- \global\let\tikzexternal@nextfile=\pgfutil@empty
+ \ifmeasuring@\else
+ \global\let\tikzexternal@nextfile=\pgfutil@empty
+ \fi
\global\tikzexternalexportnexttrue
}%
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarycalc.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarycalc.code.tex
index 594ccc6c49a..b6fc75aeef9 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarycalc.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarycalc.code.tex
@@ -39,10 +39,6 @@
\let\x=\tikz@cc@dox%
\let\y=\tikz@cc@doy%
\let\n=\tikz@cc@don%
- \let\rawx=\tikz@cc@dotempx%
- \let\rawy=\tikz@cc@dotempy%
- \let\rawz=\tikz@cc@dotempz%
- \let\coord=\tikz@cc@docoord%
\pgfutil@ifnextchar i{\tikz@cc@stop@let}{\tikz@cc@handle@line}%
}%
\def\tikz@cc@handle@line{%
@@ -74,17 +70,6 @@
\expandafter\edef\csname tikz@cc@p@\tikz@cc@coord@name\endcsname{\the\pgf@x,\the\pgf@y}%
\expandafter\edef\csname tikz@cc@x@\tikz@cc@coord@name\endcsname{\the\pgf@x}%
\expandafter\edef\csname tikz@cc@y@\tikz@cc@coord@name\endcsname{\the\pgf@y}%
- \pgfutil@letfirst\pgfutil@next{#1}%
- \ifx\pgfutil@next\pgfpointxyz
- \expandafter\edef\csname tikz@cc@tempx@\tikz@cc@coord@name\endcsname{\pgftemp@x}%
- \expandafter\edef\csname tikz@cc@tempy@\tikz@cc@coord@name\endcsname{\pgftemp@y}%
- \expandafter\edef\csname tikz@cc@tempz@\tikz@cc@coord@name\endcsname{\pgftemp@z}%
- \else
- \expandafter\edef\csname tikz@cc@tempx@\tikz@cc@coord@name\endcsname{}%
- \expandafter\edef\csname tikz@cc@tempy@\tikz@cc@coord@name\endcsname{}%
- \expandafter\edef\csname tikz@cc@tempz@\tikz@cc@coord@name\endcsname{}%
- \fi
- \expandafter\edef\csname tikz@cc@coord@\tikz@cc@coord@name\endcsname{\csname tikz@declared@coordinate\endcsname}%
\pgfutil@ifnextchar,{\tikz@cc@handle@nextline}{\tikz@cc@stop@let}%
}%
\def\tikz@cc@handle@nextline,{%
@@ -98,10 +83,6 @@
\def\tikz@cc@dox#1{\csname tikz@cc@x@#1\endcsname}%
\def\tikz@cc@doy#1{\csname tikz@cc@y@#1\endcsname}%
\def\tikz@cc@don#1{\csname tikz@cc@n@#1\endcsname}%
-\def\tikz@cc@dotempx#1{\csname tikz@cc@tempx@#1\endcsname}%
-\def\tikz@cc@dotempy#1{\csname tikz@cc@tempy@#1\endcsname}%
-\def\tikz@cc@dotempz#1{\csname tikz@cc@tempz@#1\endcsname}%
-\def\tikz@cc@docoord#1{\csname tikz@cc@coord@#1\endcsname}%
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryintersections.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryintersections.code.tex
index 5b0e83d5ee1..f7ff81b7e2a 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryintersections.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryintersections.code.tex
@@ -72,6 +72,10 @@
\let\tikz@intersect@total=\pgfutil@empty
\tikzset{
+ every scope/.append style={
+ execute at begin scope={\let\tikz@intersect@namedpaths@outside\tikz@intersect@namedpaths},
+ execute at end scope={\global\let\tikz@intersect@namedpaths\tikz@intersect@namedpaths@outside},
+ },
name intersections/.code={%
\tikzset{/tikz/intersection/.cd,
by=,
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryspy.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryspy.code.tex
index b23cf08caf2..c9ac86f17ee 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryspy.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryspy.code.tex
@@ -97,8 +97,20 @@
\pgftransformcm{\pgf@lib@svg@a}{\pgf@lib@svg@b}{\pgf@lib@svg@c}{\pgf@lib@svg@d}{\pgfpointorigin}%
}
}]{};
+ \expandafter\pgfutil@switch\expandafter{\tikz@anchor}{%
+ {north} {\def\tikz@spy@anchor{south}}%
+ {north east}{\def\tikz@spy@anchor{south west}}%
+ {east} {\def\tikz@spy@anchor{west}}%
+ {south east}{\def\tikz@spy@anchor{north west}}%
+ {south} {\def\tikz@spy@anchor{north}}%
+ {south west}{\def\tikz@spy@anchor{north east}}%
+ {west} {\def\tikz@spy@anchor{east}}%
+ {north west}{\def\tikz@spy@anchor{south east}}%
+ % default to center
+ {default} {\def\tikz@spy@anchor{center}}%
+ }
\node [alias=tikzspyinnode,inner sep=0pt,outer sep=0pt,at={#2},every spy in node/.try,
- path picture={\node[anchor=center,tikz@lib@reset@gs]{\nullfont%
+ path picture={\node[anchor=\tikz@spy@anchor,tikz@lib@reset@gs]{\nullfont%
\pgfpicture\relax\pgfsetbaseline{default}\pgfsettrimleft{default}\pgfsettrimright{default}%
\pgftransformreset%
\let\tikz@transform=\relax%
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytopaths.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytopaths.code.tex
index 2051fce8fd6..121a570f4b5 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytopaths.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytopaths.code.tex
@@ -163,7 +163,7 @@
\fi%
\tikz@to@start@compute%
\tikz@to@end@compute%
- \edef\tikz@computed@path{.. controls \tikz@computed@start and \tikz@computed@end .. (\tikz@toto)}
+ \edef\tikz@computed@path{.. controls \tikz@computed@start and \tikz@computed@end .. (\tikztotarget)}
}
\def\tikz@to@compute@distance{\tikz@scan@one@point\tikz@@to@compute@distance(\tikz@tofrom)}
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytrees.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytrees.code.tex
index 830435a029b..8ff54a03123 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytrees.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrarytrees.code.tex
@@ -59,7 +59,12 @@
% Circle grow
%
-\tikzset{grow cyclic/.style={growth function=\tikz@grow@circle}}%
+\tikzset{
+ grow cyclic/.style={
+ edge from parent/.append style={reset cm},
+ growth function=\tikz@grow@circle,
+ }
+}%
\tikzset{sibling angle/.initial=20}%
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryturtle.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryturtle.code.tex
index 009a309e311..76272f1a6cf 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryturtle.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibraryturtle.code.tex
@@ -28,7 +28,7 @@
% given, by turtle distance
\tikzset{
turtle/forward/.default=\pgfkeysvalueof{/tikz/turtle/distance},
- turtle/forward/.style={/tikz/insert path={to[/tikz/turtle/how]++(\tikz@lib@turtle@dir:#1)}}
+ turtle/forward/.style={/tikz/insert path={to[/tikz/turtle/how]++({\tikz@lib@turtle@dir}:{#1})}}
}%
@@ -46,7 +46,7 @@
\tikzset{
turtle/left/.default=90,
turtle/left/.code={%
- \pgfmathparse{#1+\tikz@lib@turtle@dir}%
+ \pgfmathparse{(#1)+(\tikz@lib@turtle@dir)}%
\ifdim\pgfmathresult pt>360pt\relax%
\pgfmathparse{\pgfmathresult-360}%
\fi%
@@ -60,7 +60,7 @@
turtle/right/.default=90,
turtle/right/.code={%
\pgfmathparse{#1}
- \pgfmathparse{\tikz@lib@turtle@dir-\pgfmathresult}%
+ \pgfmathparse{(\tikz@lib@turtle@dir)-\pgfmathresult}%
\ifdim\pgfmathresult pt<0pt\relax%
\pgfmathparse{\pgfmathresult+360}%
\fi%
diff --git a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/tikz.code.tex b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/tikz.code.tex
index 5f67167ad37..2d428f666f6 100644
--- a/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/tikz.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/frontendlayer/tikz/tikz.code.tex
@@ -283,7 +283,18 @@
% Radii and arc options
\tikzset{x radius/.initial=0pt}%
\tikzset{y radius/.initial=0pt}%
-\tikzset{radius/.style={/tikz/x radius=#1,/tikz/y radius=#1}}%
+\tikzset{%
+ radius/.code={%
+ \pgfmathparse{#1}%
+ \ifpgfmathunitsdeclared
+ \pgfkeyssetevalue{/tikz/x radius}{\pgfmathresult pt}%
+ \pgfkeyssetevalue{/tikz/y radius}{\pgfmathresult pt}%
+ \else
+ \pgfkeyssetevalue{/tikz/x radius}{\pgfmathresult}%
+ \pgfkeyssetevalue{/tikz/y radius}{\pgfmathresult}%
+ \fi
+ }%
+}%
\tikzset{start angle/.initial=}%
\tikzset{end angle/.initial=}%
\tikzset{delta angle/.initial=}%
@@ -696,9 +707,9 @@
\bgroup
[current point is local = true]
\pgfextra{\let\tikz@save@last@node=\tikzlastnode\tikz@node@is@a@labelfalse}%
- node [every pin,
- tikz@label@angle = #2,
+ node [tikz@label@angle = #2,
anchor=@auto,
+ every pin,
#1,
append after command = {%
(\tikz@save@last@node)
@@ -726,9 +737,9 @@
\bgroup
[current point is local = true]
\pgfextra{\let\tikz@save@last@node=\tikzlastnode\tikz@node@is@a@labelfalse}%
- node [every pin,
- tikz@label@angle = #2,
+ node [tikz@label@angle = #2,
anchor=@auto,
+ every pin,
#1,
append after command = {%
(\tikz@save@last@node)
@@ -857,9 +868,9 @@
\bgroup
[current point is local=true]
\pgfextra{\let\tikz@save@last@fig@name=\tikz@last@fig@name\tikz@node@is@a@labelfalse}
- node [every label,
- tikz@label@angle = #2,
+ node [tikz@label@angle = #2,
anchor=@auto,
+ every label,
#1,
tikz@label@post = \tikz@label@distance] {\iftikz@handle@active@nodes\expandafter\scantokens\else\expandafter\pgfutil@firstofone\fi{#3\noexpand}}
\pgfextra{\global\let\tikz@last@fig@name=\tikz@save@last@fig@name}
@@ -887,9 +898,9 @@
\bgroup
[current point is local=true]
\pgfextra{\let\tikz@save@last@fig@name=\tikz@last@fig@name\tikz@node@is@a@labelfalse}
- node [every label,
- tikz@label@angle = #2,
+ node [tikz@label@angle = #2,
anchor=@auto,
+ every label,
#1,
tikz@label@post = \tikz@label@distance] {\iftikz@handle@active@nodes\expandafter\scantokens\else\expandafter\pgfutil@firstofone\fi{#3\noexpand}}
\pgfextra{\global\let\tikz@last@fig@name=\tikz@save@last@fig@name}
@@ -1030,7 +1041,7 @@
\tikz@addtransform{%
\expandafter\tikz@extract@node@dist\tikz@node@distance and\pgf@stop%
\pgftransformshift{\pgfpointpolar{#2}{\tikz@extracted@node@distance}}}%
- \def\tikz@node@at{\pgfpointanchor{#1}{center}}}%
+ \def\tikz@node@at{\pgfpointanchor{\tikz@pp@name{#1}}{center}}}%
\def\tikz@extract@node@dist#1and#2\pgf@stop{%
\def\tikz@extracted@node@distance{#1}}%
@@ -1147,15 +1158,17 @@
\tikzset{badness warnings for centered text/.is if=tikz@warn@for@narrow@centered}%
\newif\iftikz@warn@for@narrow@centered
-\let\tikz@text@width=\pgfutil@empty
-\let\tikz@text@height=\pgfutil@empty
-\let\tikz@text@depth=\pgfutil@empty
-\let\tikz@textcolor=\pgfutil@empty
-\let\tikz@textfont=\pgfutil@empty
-\let\tikz@textopacity=\pgfutil@empty
-\let\tikz@node@textfont=\pgfutil@empty
-
-\def\tikz@text@action{\pgfutil@raggedright\rightskip0pt plus2em \spaceskip.3333em \xspaceskip.5em\relax}%
+\def\tikz@text@reset{%
+ \let\tikz@text@width=\pgfutil@empty
+ \let\tikz@text@height=\pgfutil@empty
+ \let\tikz@text@depth=\pgfutil@empty
+ \let\tikz@textcolor=\pgfutil@empty
+ \let\tikz@textfont=\pgfutil@empty
+ \let\tikz@textopacity=\pgfutil@empty
+ \let\tikz@node@textfont=\pgfutil@empty
+ \def\tikz@text@action{\pgfutil@raggedright\rightskip0pt plus2em \spaceskip.3333em \xspaceskip.5em\relax}%
+}
+\tikz@text@reset
% Alignment
@@ -2058,7 +2071,6 @@
% settings.
\def\tikz@command@path{%
- \global\let\tikz@intersect@namedpaths=\pgfutil@empty% clear intersections
\let\tikz@signal@path=\tikz@signal@path% for detection at begin of matrix cell
\pgfutil@ifnextchar[{\tikz@check@earg}%]
{\pgfutil@ifnextchar<{\tikz@doopt}{\tikz@@command@path}}}%
@@ -3615,7 +3627,7 @@
\tikzset{every circle/.try,#1}%
\pgftransformshift{\tikz@node@at}%
\tikz@transform%
- \tikz@do@circle{\pgfkeysvalueof{/tikz/x radius}}{\pgfkeysvalueof{/tikz/y radius}}
+ \tikz@do@ellipse{\pgfkeysvalueof{/tikz/x radius}}{\pgfkeysvalueof{/tikz/y radius}}
}%
\tikz@scan@next@command%
}%
@@ -3627,15 +3639,28 @@
\ifpgfutil@in@%
\tikz@@ellipseB(#1)%
\else%
- \tikz@do@circle{#1}{#1}%
+ \tikz@do@circle{#1}%
\fi%
}%
\tikz@scan@next@command%
}%
\def\tikz@@ellipseB(#1 and #2){%
- \tikz@do@circle{#1}{#2}
+ \tikz@do@ellipse{#1}{#2}%
}%
-\def\tikz@do@circle#1#2{
+\def\tikz@do@circle#1{%
+ \pgfmathparse{#1}%
+ \let\tikz@ellipse@x=\pgfmathresult
+ \ifpgfmathunitsdeclared
+ \pgfpathellipse{\pgfpointorigin}%
+ {\pgfqpoint{\tikz@ellipse@x pt}{0pt}}%
+ {\pgfpoint{0pt}{\tikz@ellipse@x pt}}%
+ \else
+ \pgfpathellipse{\pgfpointorigin}%
+ {\pgfpointxy{\tikz@ellipse@x}{0}}%
+ {\pgfpointxy{0}{\tikz@ellipse@x}}%
+ \fi
+}
+\def\tikz@do@ellipse#1#2{
\pgfmathparse{#1}%
\let\tikz@ellipse@x=\pgfmathresult%
\ifpgfmathunitsdeclared%
@@ -3801,9 +3826,11 @@
\tikz@scan@one@point\tikz@@coordinate@at@math(%
}%
\def\tikz@@coordinate@at@math#1{%
- \pgf@process{#1}%
- \edef\tikz@temp{(\the\pgf@x,\the\pgf@y)}%
- \expandafter\tikz@coordinate@caller\tikz@temp{}%
+ \pgfutil@ifundefined{tikz@scan@point@coordinate}%
+ {\pgf@process{#1}%
+ \edef\tikz@temp{(\the\pgf@x,\the\pgf@y)}%
+ \expandafter\tikz@coordinate@caller\tikz@temp{}}
+ {\expandafter\tikz@coordinate@caller\tikz@scan@point@coordinate{}}%
}%
@@ -3935,10 +3962,8 @@
\ifx\tikz@textcolor\pgfutil@empty%
\else%
\pgfutil@colorlet{.}{\tikz@textcolor}%
+ \pgfutil@color{\tikz@textcolor}%
\fi%
- % FIXME : this here is the proposed solution for <https://sourceforge.net/p/pgf/bugs/362/>
- % but it caused <https://sourceforge.net/p/pgf/bugs/503/>.
- % \pgfutil@color{.}%
\setbox\tikz@figbox=\box\pgfutil@voidb@x%
\setbox\tikz@figbox@bg=\box\pgfutil@voidb@x%
\tikz@uninstallcommands%
@@ -3950,6 +3975,8 @@
\ifnum\the\catcode`\:=\active\relax\expandafter\let\tikz@activecolon=\tikz@origcolon\fi%
\ifnum\the\catcode`\|=\active\relax\expandafter\let\tikz@activebar=\tikz@origbar\fi%
\aftergroup\tikz@fig@collectresetcolor%
+ \tikz@signal@halign@check%
+ \tikz@text@reset%
\tikz@halign@check%
\ignorespaces%
}%
@@ -4004,6 +4031,7 @@
\def\tikz@matrix@shift{\pgfpointorigin}%
\fi%
\let\tikz@transform=\relax%
+ \pgfmatrixbeforeassemblenode{\tikzset{every outer matrix/.try}}%
\pgfmatrix%
{\tikz@shape}%
{\tikz@m@anchor}%
@@ -4214,7 +4242,7 @@
\newif\iftikz@do@align
% Alignment handling
-\def\tikz@halign@check{%
+\def\tikz@signal@halign@check{%
\tikz@do@alignfalse
\ifx\tikz@text@width\pgfutil@empty%
\pgfkeysgetvalue{/tikz/node halign header}\tikz@align@header%
@@ -4223,6 +4251,8 @@
\tikz@do@aligntrue%
\fi%
\fi%
+}
+\def\tikz@halign@check{%
\iftikz@do@align%
% Bingo
\setbox\tikz@align@aligned@box=\box\pgfutil@voidb@x% void
@@ -4341,6 +4371,8 @@
\ifnum\the\catcode`\|=\active\relax\expandafter\let\tikz@activebar=\tikz@origbar\fi%
\tikz@atbegin@node%
\aftergroup\tikz@fig@collectresetcolor%
+ \tikz@signal@halign@check%
+ \tikz@text@reset%
\tikz@halign@check%
\ignorespaces%
}%
@@ -4379,9 +4411,17 @@
{\pgfutil@ifnextchar\bgroup{\tikz@nodes@main}%
{\tikzerror{Nodes must have a (possibly empty) label text}%
\tikz@fig@main{}}}}}}%}}%
-\def\tikz@nodes@at at#1){%
+
+% Look ahead whether the next character is a (. If that is the case, we scan
+% until ), otherwise we grab a single token and append.
+\def\tikz@nodes@at at{\pgfutil@ifnextchar({\tikz@nodes@at@}{\tikz@nodes@at@@}}%
+\def\tikz@nodes@at@#1){%
\expandafter\def\expandafter\tikz@nodes@collect\expandafter{\tikz@nodes@collect at#1)}%
\tikz@nodes@scan}%
+\def\tikz@nodes@at@@#1{%
+ \expandafter\def\expandafter\tikz@nodes@collect\expandafter{\tikz@nodes@collect at#1}%
+ \tikz@nodes@scan}%
+
\def\tikz@nodes@name#1){%
\expandafter\def\expandafter\tikz@nodes@collect\expandafter{\tikz@nodes@collect#1)}%
\tikz@nodes@scan}%
@@ -4786,7 +4826,7 @@
\let\tikz@picmode\tikz@mode%
\tikzset{name prefix ../.style/.expanded={/tikz/name prefix=\pgfkeysvalueof{/tikz/name prefix}}}%
\ifx\tikz@fig@name\pgfutil@empty\else%
- \tikzset{name prefix/.prefix/.expanded=\tikz@fig@name}%
+ \tikzset{name prefix/.expanded=\tikz@fig@name}%
\fi%
\pgfkeysvalueof{/tikz/pics/setup code}%
\pgfkeysgetvalue{/tikz/pics/code}{\tikz@pic@code}
@@ -5387,19 +5427,26 @@
\else%
\tikz@calc@anchor#2.center\tikz@stop% to be on the save side, in
% case iftikz@shapeborder is ignored...
- \expandafter\ifx\csname pgf@sh@ns@\tikz@pp@name{#2}\endcsname\tikz@coordinate@text%
- \else
- \tikz@shapebordertrue%
- \def\tikz@shapeborder@name{\tikz@pp@name{#2}}%
- \fi%
+ \ifcsname pgf@sh@ns@\tikz@pp@name{#2}\endcsname
+ \expandafter\ifx\csname pgf@sh@ns@\tikz@pp@name{#2}\endcsname\tikz@coordinate@text%
+ \else
+ \tikz@shapebordertrue%
+ \def\tikz@shapeborder@name{\tikz@pp@name{#2}}%
+ \fi%
+ \fi
\fi%
- \expandafter\let\expandafter\tikz@declared@coordinate\csname tikz@dcl@coord@\tikz@pp@name{#2}\endcsname
\edef\tikz@marshal{\noexpand#1{\noexpand\pgfqpoint{\the\pgf@x}{\the\pgf@y}}}%
\tikz@marshal%
}%
\def\tikz@calc@anchor#1.#2\tikz@stop{%
- \pgfpointanchor{\tikz@pp@name{#1}}{#2}%
+ % Check if a shape with name prefix exists, otherwise try the global name
+ % without prefix.
+ \ifcsname pgf@sh@ns@\tikz@pp@name{#1}\endcsname%
+ \pgfpointanchor{\tikz@pp@name{#1}}{#2}%
+ \else
+ \pgfpointanchor{#1}{#2}%
+ \fi
}%
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/circular/doc.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/circular/doc.lua
index 0bd9090a1c1..9198885965d 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/circular/doc.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/circular/doc.lua
@@ -14,7 +14,6 @@ local documentation = require 'pgf.gd.doc'.documentation
local summary = require 'pgf.gd.doc'.summary
local example = require 'pgf.gd.doc'.example
-
--------------------------------------------------------------------
key "simple necklace layout"
@@ -45,8 +44,10 @@ clockwise). The order of the nodes is the order in which they appear
in the graph, the edges are not taken into consideration, unless the
|componentwise| option is given.
%
-\begin{codeexample}[]
-\tikz[>=spaced stealth']
+\begin{codeexample}[
+ preamble={\usetikzlibrary{arrows.meta,graphs,graphdrawing}
+ \usegdlibrary{circular}}]
+\tikz[>={Stealth[round,sep]}]
\graph [simple necklace layout, grow'=down, node sep=1em,
nodes={draw,circle}, math nodes]
{
@@ -60,14 +61,16 @@ decomposed into connected components, which are then laid out
individually and packed using the usual component packing
mechanisms:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{circular}}]
\tikz \graph [simple necklace layout] {
a -- b -- c -- d -- a,
1 -- 2 -- 3 -- 1
};
\end{codeexample}
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{circular}}]
\tikz \graph [simple necklace layout, componentwise] {
a -- b -- c -- d -- a,
1 -- 2 -- 3 -- 1
@@ -78,7 +81,7 @@ The nodes are placed in such a way that
%
\begin{enumerate}
\item The (angular) distance between the centers of consecutive
- nodes is at least |node distance|,
+ nodes is at least |node distance|,
\item the distance between the borders of consecutive nodes is at
least |node sep|, and
\item the radius is at least |radius|.
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentAlign.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentAlign.lua
index 5e5b0635bf4..72a82be978a 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentAlign.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentAlign.lua
@@ -47,7 +47,6 @@ local declare = require "pgf.gd.interface.InterfaceToAlgorithms".declare
--
-- @end
-
---
declare {
@@ -86,7 +85,8 @@ declare {
the first node of the component encountered during specification
of the component.
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [binary tree layout, nodes={draw},
component align=first node]
{ a, b -- c, d -- e[second] -- f };
@@ -99,13 +99,15 @@ declare {
between the maximum and minimum value that the projected nodes
have on the shift line.
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [binary tree layout, nodes={draw},
component align=center]
{ a, b -- c, d -- e[second] -- f };
\end{codeexample}
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [binary tree layout, nodes={draw},
component direction=90,
component align=center]
@@ -119,13 +121,15 @@ declare {
through the center of the node whose center has the highest
projected value.
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [binary tree layout, nodes={draw},
component align=counterclockwise]
{ a, b -- c, d -- e[second] -- f };
\end{codeexample}
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [binary tree layout, nodes={draw},
component direction=90,
component align=counterclockwise]
@@ -138,13 +142,15 @@ declare {
Works like |counterclockwise|, only in the other direction:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [binary tree layout, nodes={draw},
component align=clockwise]
{ a, b -- c, d -- e[second] -- f };
\end{codeexample}
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [binary tree layout, nodes={draw},
component direction=90,
component align=clockwise]
@@ -160,7 +166,8 @@ declare {
packing, this means that the components are aligned so that the
bounding boxes of the components are aligned at the top.
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [tree layout, nodes={draw, align=center},
component sep=0pt,
component align=counterclockwise]
@@ -211,8 +218,8 @@ declare {
summary = [["
Like |components go right top aligned|, but with
- |component align| set to |counterclockwise| |bounding box|.
- This means that the components will be aligned with their bounding
+ |component align| set to |counterclockwise| |bounding box|.
+ This means that the components will be aligned with their bounding
boxed being top-aligned.
"]],
examples = [["
@@ -530,4 +537,4 @@ declare {
-return Components \ No newline at end of file
+return Components
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentDistance.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentDistance.lua
index 7ba4d000a7a..a2d04a178f5 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentDistance.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/ComponentDistance.lua
@@ -23,7 +23,6 @@ local declare = require "pgf.gd.interface.InterfaceToAlgorithms".declare
--
-- @end
-
---
declare {
@@ -42,7 +41,8 @@ declare {
are then shifted such that the padding (separating distance)
between the two boxes is the current value of |component sep|.
%
- \begin{codeexample}[]
+ \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [tree layout, nodes={draw}, component sep=0pt,
component packing=rectangular]
{ a -- long text, longer text -- b};
@@ -60,7 +60,8 @@ declare {
padding |component sep| can be used to avoid the nodes actually
touching each other.
%
- \begin{codeexample}[]
+ \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [tree layout, nodes={draw}, component sep=0pt,
level distance=1.5cm,
component packing=skyline]
@@ -89,7 +90,8 @@ declare {
which the line was moved. This means that the holes are ``filled
up by slanted roofs''.
%
- \begin{codeexample}[]
+ \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\begin{tikzpicture}
\graph [tree layout, nodes={draw}, component sep=0pt,
component packing=skyline]
@@ -103,4 +105,4 @@ declare {
}
-return Components \ No newline at end of file
+return Components
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/doc.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/doc.lua
index c7adfab830e..19bfd52fdf8 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/doc.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/control/doc.lua
@@ -31,7 +31,8 @@ Now, when you set this key for a single node of a graph,
then, by shifting the graph around, this ``wish'' can obviously
always be fulfill:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={ \usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{force}}]
\begin{tikzpicture}
\draw [help lines] (0,0) grid (3,2);
\graph [spring layout]
@@ -41,7 +42,8 @@ always be fulfill:
\end{tikzpicture}
\end{codeexample}
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={ \usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{force}}]
\begin{tikzpicture}
\draw [help lines] (0,0) grid (3,2);
\graph [spring layout]
@@ -61,7 +63,8 @@ by a graph drawing algorithm.) A nice side effect of this is that
you can use the |x| and |y| keys (see
Section~\ref{section-graphs-xy}) to specify desired positions:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={ \usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{force}}]
\begin{tikzpicture}
\draw [help lines] (0,0) grid (3,2);
\graph [spring layout]
@@ -71,7 +74,8 @@ Section~\ref{section-graphs-xy}) to specify desired positions:
\end{tikzpicture}
\end{codeexample}
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={ \usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{layered}}]
\begin{tikzpicture}
\draw [help lines] (0,0) grid (3,2);
\graph [layered layout]
@@ -94,6 +98,11 @@ sense that some nodes are ``nailed to the canvas'' while other
nodes can ``move freely''.
]]
+--[[
+% TODOsp: codeexamples: the following 3 examples need these libraries
+% \usetikzlibrary{graphs,graphdrawing}
+% \usegdlibrary{force}
+--]]
example
[[
\begin{tikzpicture}
@@ -158,6 +167,11 @@ Note how in the last example |c| is placed at |(1,1)| rather than
|b| as would happen by default.
]]
+--[[
+% TODOsp: codeexamples: the following 4 examples need these libraries
+% \usetikzlibrary{graphs,graphdrawing}
+% \usegdlibrary{layered}
+--]]
example
[[
\tikz \draw (0,0)
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/energybased/FMMMLayout.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/energybased/FMMMLayout.lua
index b7bab378191..fcd5b26fb00 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/energybased/FMMMLayout.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/energybased/FMMMLayout.lua
@@ -48,7 +48,7 @@ example
[[
\tikz [nodes={text height=.7em, text depth=.2em,
draw=black!20, thick, fill=white, font=\footnotesize},
- >=spaced stealth', rounded corners, semithick]
+ >={Stealth[round,sep]}, rounded corners, semithick]
\graph [FMMMLayout, node sep=1mm, variation=2] {
"5th Edition" -> { "6th Edition", "PWB 1.0" };
"6th Edition" -> { "LSX", "1 BSD", "Mini Unix", "Wollongong", "Interdata" };
@@ -126,4 +126,4 @@ example
-- Local Variables:
-- mode:latex
--- End: \ No newline at end of file
+-- End:
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/layered/SugiyamaLayout.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/layered/SugiyamaLayout.lua
index ab9d9ee77f7..ec75fa7e6e2 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/layered/SugiyamaLayout.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/doc/ogdf/layered/SugiyamaLayout.lua
@@ -50,7 +50,7 @@ example
[[
\tikz [nodes={text height=.7em, text depth=.2em,
draw=black!20, thick, fill=white, font=\footnotesize},
- >=spaced stealth', rounded corners, semithick]
+ >={Stealth[round,sep]}, rounded corners, semithick]
\graph [SugiyamaLayout, FastSimpleHierarchyLayout, grow=-80,
level distance=1.5cm, sibling distance=7mm] {
"5th Edition" -> { "6th Edition", "PWB 1.0" };
@@ -110,4 +110,4 @@ documentation [[
-- Local Variables:
-- mode:latex
--- End: \ No newline at end of file
+-- End:
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleEdgeDemo.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleEdgeDemo.lua
index c22c4decf22..3ff5f4ea230 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleEdgeDemo.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleEdgeDemo.lua
@@ -40,7 +40,8 @@ declare {
option is declared and how we use it to look up a vertex in the
graph by its name.
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={ \usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{examples}}]
\tikz [simple edge demo layout]
\graph [radius=2cm] {
a, b, c, d, e, f;
@@ -140,4 +141,4 @@ function SimpleEdgeDemo:run()
end
end
-return SimpleEdgeDemo \ No newline at end of file
+return SimpleEdgeDemo
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleHuffman.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleHuffman.lua
index f81abf11058..6aa9bffb724 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleHuffman.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/examples/SimpleHuffman.lua
@@ -51,7 +51,8 @@ declare {
HuffmanNode/.style={/tikz/.cd,circle,inner sep=0pt,outer sep=0pt,draw,minimum size=3pt}
}
-\begin{codeexample}[]
+\begin{codeexample}[preamble={ \usetikzlibrary{graphs,graphdrawing,quotes}
+ \usegdlibrary{examples}}]
\tikz \graph [simple Huffman layout,
level distance=7mm, sibling distance=8mm, grow'=up]
{
@@ -178,6 +179,7 @@ function SimpleHuffman:run()
%
Ok, we are mainly done now. Finish by computing vertical placements
and do formal cleanup.
+ %
\begin{codeexample}[code only, tikz syntax=false]
layered.arrange_layers_by_baselines(layers, self.adjusted_bb, self.ugraph)
end
@@ -282,4 +284,4 @@ function SimpleHuffman:run()
layered.arrange_layers_by_baselines(layer, self.adjusted_bb, self.ugraph)
end
-return SimpleHuffman \ No newline at end of file
+return SimpleHuffman
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlSprings.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlSprings.lua
index 45b9c9ef55e..71005d85274 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlSprings.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlSprings.lua
@@ -26,13 +26,15 @@ local declare = require("pgf.gd.interface.InterfaceToAlgorithms").declare
-- The following examples shows how a simple graph can be scaled by
-- changing the |node distance|:
-- %
--- \begin{codeexample}[]
+-- \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{force}}]
-- \tikz \graph [spring layout, node distance=7mm] { subgraph C_n[n=3] };
-- \tikz \graph [spring layout] { subgraph C_n[n=3] };
-- \tikz \graph [spring layout, node distance=15mm]{ subgraph C_n[n=3] };
-- \end{codeexample}
-- %
--- \begin{codeexample}[]
+-- \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{force}}]
-- \tikz \graph [spring electrical layout, node distance=0.7cm] { subgraph C_n[n=3] };
-- \tikz \graph [spring electrical layout] { subgraph C_n[n=3] };
-- \tikz \graph [spring electrical layout, node distance=1.5cm] { subgraph C_n[n=3] };
@@ -41,7 +43,6 @@ local declare = require("pgf.gd.interface.InterfaceToAlgorithms").declare
-- @end
-
---
declare {
@@ -56,5 +57,3 @@ declare {
the nodes they connect.
"]]
}
-
-
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlStart.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlStart.lua
index 269b81a3d7c..85a64b0a5a6 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlStart.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/force/ControlStart.lua
@@ -14,8 +14,6 @@
local declare = require("pgf.gd.interface.InterfaceToAlgorithms").declare
-
-
---
-- @section subsubsection {Start Configuration}
--
@@ -23,19 +21,21 @@ local declare = require("pgf.gd.interface.InterfaceToAlgorithms").declare
-- random distribution of the vertices. You can influence it by
-- changing the |random seed|:
-- %
---\begin{codeexample}[]
---\tikz \graph [random seed=10, spring layout] {
--- a -- {b, c, d} -- e -- f -- {g,h} -- {a,b,e};
---};
---\end{codeexample}
+-- \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{force}}]
+-- \tikz \graph [random seed=10, spring layout] {
+-- a -- {b, c, d} -- e -- f -- {g,h} -- {a,b,e};
+-- };
+-- \end{codeexample}
-- %
---\begin{codeexample}[]
---\tikz \graph [random seed=11, spring layout] {
--- a -- {b, c, d} -- e -- f -- {g,h} -- {a,b,e};
---};
---\end{codeexample}
+-- \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{force}}]
+-- \tikz \graph [random seed=11, spring layout] {
+-- a -- {b, c, d} -- e -- f -- {g,h} -- {a,b,e};
+-- };
+-- \end{codeexample}
--
-- Other methods, like a planar preembedding, are not implemented
-- currently.
--
--- @end \ No newline at end of file
+-- @end
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/ChildSpec.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/ChildSpec.lua
index 5af36428858..815f90d268e 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/ChildSpec.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/ChildSpec.lua
@@ -13,7 +13,6 @@
---
-- @section subsection {Specifying Missing Children}
---
-- \label{section-gd-missing-children}
--
-- In the present section we discuss keys for specifying missing children
@@ -38,7 +37,8 @@
-- \item When you use the |child| syntax, you can use the |missing| key
-- with the |child| command to indicate a missing child:
-- %
--- \begin{codeexample}[]
+-- \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{trees}}]
-- \tikz [binary tree layout, level distance=5mm]
-- \node {a}
-- child { node {b}
@@ -57,7 +57,8 @@
-- which really must be completely empty and may not even contain a
-- slash, to indicate a missing node:
-- %
--- \begin{codeexample}[]
+-- \begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{trees}}]
-- \tikz [binary tree layout, level distance=5mm]
-- \graph { a -> { b -> c -> d, e -> { , f -> { , g} } } };
-- \end{codeexample}
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/SpanningTreeComputation.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/SpanningTreeComputation.lua
index 8951ce0538c..dacf6348652 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/SpanningTreeComputation.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/SpanningTreeComputation.lua
@@ -35,14 +35,17 @@
-- Selects the (sub)algorithm that is to be used for computing spanning
-- trees whenever this is requested by a tree layout algorithm. The
-- default algorithm is |breadth first spanning tree|.
---
---\begin{codeexample}[]
+--%
+--\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{trees}}]
--\tikz \graph [tree layout, breadth first spanning tree]
--{
-- 1 -- {2,3,4,5} -- 6;
--};
--\end{codeexample}
---\begin{codeexample}[]
+--%
+--\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+-- \usegdlibrary{trees}}]
--\tikz \graph [tree layout, depth first spanning tree]
--{
-- 1 --[bend right] {2,3,4,5 [>bend left]} -- 6;
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/doc.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/doc.lua
index 169c7ff5e19..a44fd470317 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/doc.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/trees/doc.lua
@@ -83,7 +83,8 @@ When the subtrees of the children of a node are arranged, each
position with a missing child is treated as if a zero-width,
zero-height subtree were present at that positions:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz [tree layout, nodes={draw,circle}]
\node {r}
child { node {a}
@@ -95,7 +96,8 @@ zero-height subtree were present at that positions:
%
or in |graph| syntax:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [tree layout, nodes={draw,circle}]
{
r -> {
@@ -109,7 +111,8 @@ or in |graph| syntax:
%
More than one child can go missing:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [tree layout, nodes={draw,circle}, sibling sep=0pt]
{ r -> { a, , ,b -> {c,d}, ,e} };
\end{codeexample}
@@ -122,7 +125,8 @@ root node, they are usually \emph{not} considered as part of the
key ensures that |b|, |c|, |e|, and |f| all have a missing right
child):
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [tree layout, minimum number of children=2,
nodes={draw,circle}]
{ a -> { b -> c -> d, e -> f -> g } };
@@ -136,7 +140,8 @@ Br\"uggemann-Klein and Wood have proposed an extension of the
Reingold--Tilford method that is intended to better highlight the
overall structure of a tree. Consider the following two trees:
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz [baseline=(a.base), tree layout, minimum number of children=2,
sibling distance=5mm, level distance=5mm]
\graph [nodes={circle, inner sep=0pt, minimum size=2mm, fill, as=}]{
@@ -165,7 +170,8 @@ minimum distance is encountered on any level other than the first
level. Thus, in the first example there is no significant pair,
while in the second example |a| and |b| form such a pair.
%
-\begin{codeexample}[]
+\begin{codeexample}[preamble={\usetikzlibrary{graphs,graphdrawing}
+ \usegdlibrary{trees}}]
\tikz \graph [tree layout, minimum number of children=2,
level distance=5mm, nodes={circle,draw}]
{ / -> { a -> / -> /, b -> /[second] -> /[second] }};
@@ -287,6 +293,9 @@ example
};
]]
+--[[
+% TODOsp: codeexamples: the next example needs the library `arrows.meta`
+--]]
example
[[
\tikz \graph [binary tree layout] {
@@ -295,7 +304,7 @@ example
Tobin -> Plass -> { Lamport, Spivak }
}
};\qquad
-\tikz [>=spaced stealth']
+\tikz [>={Stealth[round,sep]}]
\graph [binary tree layout, grow'=right, level sep=1.5em,
nodes={right, fill=blue!50, text=white, chamfered rectangle},
edges={decorate,decoration={snake, post length=5pt}}]
diff --git a/Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarybbox.code.tex b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarybbox.code.tex
new file mode 100644
index 00000000000..38690faed14
--- /dev/null
+++ b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarybbox.code.tex
@@ -0,0 +1,94 @@
+% Copyright 2019 by an anonymous contributor
+%
+% This file may be distributed and/or modified
+%
+% 1. under the LaTeX Project Public License and/or
+% 2. under the GNU General Public License.
+%
+% See the file doc/generic/pgf/licenses/LICENSE for more details.
+
+\global\let\pgf@bbox@lt@curveto@normal\pgf@lt@curveto
+\global\let\pgf@bbox@nlt@curveto@normal\pgf@nlt@curveto
+
+\pgfqkeys{/pgf}{bezier bounding box/.is if=pgf@bbox@switch@}
+
+\def\pgf@bbox@switch@false{%
+ \let\pgf@lt@curveto \pgf@bbox@lt@curveto@normal
+ \let\pgf@nlt@curveto\pgf@bbox@nlt@curveto@normal
+}
+
+\def\pgf@bbox@switch@true{%
+ \let\pgf@lt@curveto \pgf@bbox@curveto
+ \let\pgf@nlt@curveto\pgf@bbox@curveto
+}
+
+\def\pgf@bbox@curveto#1#2#3#4#5#6{%
+ % extrema in x
+ \pgfmathsetmacro{\pgf@temp@b}{abs(\pgf@path@lastx-#5-3*#1+3*#3)}%
+ % ^^^ this is used for the denominator below, cannot become too small
+ \pgfmathsetmacro{\pgf@temp@c}{max(1+\pgf@path@lastx,max(#1,max(#3,#5)))}%
+ % ^^^ in order to avoid dimension too large errors from squaring lengths in pt
+ \pgfmathparse{((#1/\pgf@temp@c)*(#1/\pgf@temp@c)-1*((#1/\pgf@temp@c)*(#3/\pgf@temp@c))+(#3/\pgf@temp@c)*(#3/\pgf@temp@c)-1*((#1/\pgf@temp@c)*(#5/\pgf@temp@c))+(-(#3/\pgf@temp@c)+(#5/\pgf@temp@c))*(\pgf@path@lastx/\pgf@temp@c))}%
+ \pgfutil@tempdima=\pgfmathresult pt\relax%
+ % ^^^ discriminant
+ \ifdim\pgf@temp@b pt<0.01pt\relax%
+ % approximately linear
+ \pgfmathparse{abs(2*(#1)-2*(#3)+(#5))}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \ifdim\pgfutil@tempdimb<0.1pt\relax%
+ % if the denominator is very small, t is *likely* large but could be 0/0
+ \else
+ \pgfmathsetmacro{\pgf@temp@a}{(2*(#1)-3*(#3)+(#5))/(2*(#1)-2*(#3)+(#5))}%
+ \pgfmathparse{\pgf@path@lastx*pow(1-\pgf@temp@a,3)+3*#1*pow(1-\pgf@temp@a,2)*\pgf@temp@a+3*#3*(1-\pgf@temp@a)*\pgf@temp@a*\pgf@temp@a+#5*pow(\pgf@temp@a,3)}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \pgf@protocolsizes{\pgfutil@tempdimb}{#6}%
+ \fi%
+ \else
+ \ifdim\pgfutil@tempdima<0pt\relax% negative discriminant -> no turning point
+ \else
+ \pgfmathsetmacro{\pgf@temp@a}{min(1,max(0,(\pgf@path@lastx-2*#1+#3-\pgf@temp@c*sqrt(\pgfutil@tempdima))/(\pgf@path@lastx-#5-3*#1+3*#3)))}%
+ \pgfmathparse{\pgf@path@lastx*pow(1-\pgf@temp@a,3)+3*#1*pow(1-\pgf@temp@a,2)*\pgf@temp@a+3*#3*(1-\pgf@temp@a)*\pgf@temp@a*\pgf@temp@a+#5*pow(\pgf@temp@a,3)}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \pgf@protocolsizes{\pgfutil@tempdimb}{#6}%
+ \pgfmathsetmacro{\pgf@temp@a}{min(1,max(0,(\pgf@path@lastx-2*#1+#3+\pgf@temp@c*sqrt(\pgfutil@tempdima))/(\pgf@path@lastx-#5-3*#1+3*#3)))}%
+ \pgfmathparse{\pgf@path@lastx*pow(1-\pgf@temp@a,3)+3*#1*pow(1-\pgf@temp@a,2)*\pgf@temp@a+3*#3*(1-\pgf@temp@a)*\pgf@temp@a*\pgf@temp@a+#5*pow(\pgf@temp@a,3)}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \pgf@protocolsizes{\pgfutil@tempdimb}{#6}%
+ \fi%
+ \fi
+ %%%%%%%%%%%%%%%%%%%%%%%%%%%
+ % extrema in y (completely analogous to the above)
+ \pgfmathsetmacro{\pgf@temp@b}{abs(\pgf@path@lasty-#6-3*#2+3*#4)}%
+ \pgfmathsetmacro{\pgf@temp@c}{max(1+\pgf@path@lasty,max(#2,max(#4,#6)))}%
+ \pgfmathparse{((#2/\pgf@temp@c)*(#2/\pgf@temp@c)-1*((#2/\pgf@temp@c)*(#4/\pgf@temp@c))+(#4/\pgf@temp@c)*(#4/\pgf@temp@c)-1*((#2/\pgf@temp@c)*(#6/\pgf@temp@c))+(-(#4/\pgf@temp@c)+(#6/\pgf@temp@c))*(\pgf@path@lasty/\pgf@temp@c))}%
+ \pgfutil@tempdima=\pgfmathresult pt\relax%
+ % ^^^ discriminant
+ \ifdim\pgf@temp@b pt<0.01pt\relax%
+ % approximately linear
+ \pgfmathparse{abs(2*(#2)-2*(#4)+(#6))}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \ifdim\pgfutil@tempdimb<0.1pt\relax%
+ % if the denominator is very small, t is *likely* large but could be 0/0
+ \else
+ \pgfmathsetmacro{\pgf@temp@a}{(2*(#2)-3*(#4)+(#6))/(2*(#2)-2*(#4)+(#6))}%
+ \pgfmathparse{\pgf@path@lasty*pow(1-\pgf@temp@a,3)+3*#2*pow(1-\pgf@temp@a,2)*\pgf@temp@a+3*#4*(1-\pgf@temp@a)*\pgf@temp@a*\pgf@temp@a+#6*pow(\pgf@temp@a,3)}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \pgf@protocolsizes{#5}{\pgfutil@tempdimb}%
+ \fi%
+ \else
+ \ifdim\pgfutil@tempdima<0pt\relax% negative discriminant -> no turning point
+ \else
+ \pgfmathsetmacro{\pgf@temp@a}{min(1,max(0,(\pgf@path@lasty-2*#2+#4-\pgf@temp@c*sqrt(\pgfutil@tempdima))/(\pgf@path@lasty-#6-3*#2+3*#4)))}%
+ \pgfmathparse{\pgf@path@lasty*pow(1-\pgf@temp@a,3)+3*#2*pow(1-\pgf@temp@a,2)*\pgf@temp@a+3*#4*(1-\pgf@temp@a)*\pgf@temp@a*\pgf@temp@a+#6*pow(\pgf@temp@a,3)}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \pgf@protocolsizes{#5}{\pgfutil@tempdimb}%
+ \pgfmathsetmacro{\pgf@temp@a}{min(1,max(0,(\pgf@path@lasty-2*#2+#4+\pgf@temp@c*sqrt(\pgfutil@tempdima))/(\pgf@path@lasty-#6-3*#2+3*#4)))}%
+ \pgfmathparse{\pgf@path@lasty*pow(1-\pgf@temp@a,3)+3*#2*pow(1-\pgf@temp@a,2)*\pgf@temp@a+3*#4*(1-\pgf@temp@a)*\pgf@temp@a*\pgf@temp@a+#6*pow(\pgf@temp@a,3)}%
+ \pgfutil@tempdimb=\pgfmathresult pt\relax%
+ \pgf@protocolsizes{#5}{\pgfutil@tempdimb}%
+ \fi%
+ \fi
+ \pgf@protocolsizes{\pgf@path@lastx}{\pgf@path@lasty}%
+ \pgf@protocolsizes{#5}{#6}%
+ \pgfsyssoftpath@curveto{\the#1}{\the#2}{\the#3}{\the#4}{\the#5}{\the#6}%
+}
diff --git a/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryfpu.code.tex b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryfpu.code.tex
index cb20507fa04..270d9af8b5c 100644
--- a/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryfpu.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryfpu.code.tex
@@ -104,6 +104,9 @@
\let\pgfmathpostparse=\relax%
\pgfmath@catcodes%
\pgfmath@quickparsefalse%
+ \ifpgfmathfloatparseactive\else
+ \pgfmathfloat@parser@install
+ \fi
\pgfmathfloatparse@}%
% for pgf 2.00 :
diff --git a/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryintersections.code.tex b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryintersections.code.tex
index 6bed3e4721b..81b7d29c37d 100644
--- a/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryintersections.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibraryintersections.code.tex
@@ -361,23 +361,30 @@
\global\advance\pgf@intersect@solutions by1\relax%
\expandafter\global\expandafter\let\csname pgfpoint@g@intersect@solution@\the\pgf@intersect@solutions\endcsname=\pgf@intersect@solution@candidate
\ifpgf@intersect@sort%
+ % save coordinates of the intersection
+ \pgf@process{\pgf@intersect@solution@candidate}%
\pgf@xc=\pgf@x%
\pgf@yc=\pgf@y%
+ % determine length of path
\pgf@process{\pgfpointdiff{\pgfpoint@intersect@start@a}{\pgfpoint@intersect@end@a}}%
\edef\pgf@marshal{%
- \noexpand\pgfmathveclen@{\pgfmath@tonumber{\pgf@xa}}{\pgfmath@tonumber{\pgf@ya}}%
+ \noexpand\pgfmathveclen@{\pgfmath@tonumber{\pgf@x}}{\pgfmath@tonumber{\pgf@y}}%
}%
\pgf@marshal%
\let\pgf@intersect@length@a=\pgfmathresult%
+ % determine distance of intersection from start
\pgf@process{\pgfpointdiff{\pgfpoint@intersect@start@a}{\pgfqpoint{\pgf@xc}{\pgf@yc}}}%
\edef\pgf@marshal{%
\noexpand\pgfmathveclen@{\pgfmath@tonumber{\pgf@x}}{\pgfmath@tonumber{\pgf@y}}%
}%
\pgf@marshal%
+ % scale the distance to the path length (path time)
\pgfmathdivide@{\pgfmathresult}{\pgf@intersect@length@a}%
\pgf@x=\pgfmathresult pt\relax%
+ % advance by the path segment (see definition of \pgf@intersection@store@properties)
\advance\pgf@x by\pgf@intersect@time@offset pt\relax%
\edef\pgf@intersect@time@a{\pgfmath@tonumber{\pgf@x}}%
+ % save numbered
\expandafter\global\expandafter\let\csname pgf@g@intersect@solution@\the\pgf@intersect@solutions @time@a\endcsname=
\pgf@intersect@time@a
\else
diff --git a/Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarypatterns.meta.code.tex b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarypatterns.meta.code.tex
index 479992ad373..d04e75ab238 100644
--- a/Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarypatterns.meta.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/libraries/pgflibrarypatterns.meta.code.tex
@@ -85,7 +85,7 @@
\def\pgfdeclarepattern#1{%
\begingroup%
\nullfont%
- \def\pgf@pat@options{#1}%
+ \def\pgf@pat@options{,#1}%
\pgfkeys{/pgf/patterns/.cd,#1}%
\ifx\pgf@pat@name\pgfutil@empty
\pgferror{Declaring unnamed pattern}%
@@ -274,6 +274,183 @@
\pgfsys@setpatternuncolored{#4}{#1}{#2}{#3}%
}%
+% Predefined patterns
+
+\pgfdeclarepattern{
+ name=Lines,
+ parameters={
+ \pgfkeysvalueof{/pgf/pattern keys/distance},
+ \pgfkeysvalueof{/pgf/pattern keys/angle},
+ \pgfkeysvalueof{/pgf/pattern keys/xshift},
+ \pgfkeysvalueof{/pgf/pattern keys/yshift},
+ \pgfkeysvalueof{/pgf/pattern keys/line width},
+ },
+ bottom left={%
+ \pgfpoint
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ top right={%
+ \pgfpoint
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ tile size={%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}},
+ tile transformation={%
+ \pgftransformrotate{\pgfkeysvalueof{/pgf/pattern keys/angle}}%
+ \pgftransformshift{%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/xshift}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/yshift}}}},
+ defaults={
+ distance/.initial=3pt,
+ angle/.initial=0,
+ xshift/.initial=0pt,
+ yshift/.initial=0pt,
+ line width/.initial=\the\pgflinewidth,
+ },
+ code={%
+ \pgfsetlinewidth{\pgfkeysvalueof{/pgf/pattern keys/line width}}%
+ \pgfpathmoveto{\pgfpoint{-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}{0pt}}%
+ \pgfpathlineto{\pgfpoint{.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}{0pt}}%
+ \pgfusepath{stroke}%
+ },
+}
+
+\pgfdeclarepattern{
+ name=Hatch,
+ parameters={
+ \pgfkeysvalueof{/pgf/pattern keys/distance},
+ \pgfkeysvalueof{/pgf/pattern keys/angle},
+ \pgfkeysvalueof{/pgf/pattern keys/xshift},
+ \pgfkeysvalueof{/pgf/pattern keys/yshift},
+ \pgfkeysvalueof{/pgf/pattern keys/line width},
+ },
+ bottom left={%
+ \pgfpoint
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ top right={%
+ \pgfpoint
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ tile size={%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}},
+ tile transformation={%
+ \pgftransformrotate{\pgfkeysvalueof{/pgf/pattern keys/angle}}%
+ \pgftransformshift{%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/xshift}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/yshift}}}},
+ defaults={
+ distance/.initial=3pt,
+ angle/.initial=0,
+ xshift/.initial=0pt,
+ yshift/.initial=0pt,
+ line width/.initial=\the\pgflinewidth,
+ },
+ code={%
+ \pgfsetlinewidth{\pgfkeysvalueof{/pgf/pattern keys/line width}}%
+ \pgfpathmoveto{\pgfpoint{-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}{0pt}}%
+ \pgfpathlineto{\pgfpoint{.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}{0pt}}%
+ \pgfpathmoveto{\pgfpoint{0pt}{-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}}%
+ \pgfpathlineto{\pgfpoint{0pt}{.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}}%
+ \pgfusepath{stroke}%
+ },
+}
+
+\pgfdeclarepattern{
+ name=Dots,
+ parameters={
+ \pgfkeysvalueof{/pgf/pattern keys/distance},
+ \pgfkeysvalueof{/pgf/pattern keys/angle},
+ \pgfkeysvalueof{/pgf/pattern keys/xshift},
+ \pgfkeysvalueof{/pgf/pattern keys/yshift},
+ \pgfkeysvalueof{/pgf/pattern keys/radius},
+ },
+ bottom left={%
+ \pgfpoint
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ top right={%
+ \pgfpoint
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ tile size={%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}},
+ tile transformation={%
+ \pgftransformrotate{\pgfkeysvalueof{/pgf/pattern keys/angle}}%
+ \pgftransformshift{%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/xshift}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/yshift}}}},
+ defaults={
+ distance/.initial=3pt,
+ angle/.initial=0,
+ xshift/.initial=0pt,
+ yshift/.initial=0pt,
+ radius/.initial=.5pt,
+ },
+ code={%
+ \pgfpathcircle%
+ {\pgfpointorigin}%
+ {\pgfkeysvalueof{/pgf/pattern keys/radius}}
+ \pgfusepath{fill}%
+ },
+}
+
+\pgfdeclarepattern{
+ name=Stars,
+ parameters={
+ \pgfkeysvalueof{/pgf/pattern keys/distance},
+ \pgfkeysvalueof{/pgf/pattern keys/angle},
+ \pgfkeysvalueof{/pgf/pattern keys/xshift},
+ \pgfkeysvalueof{/pgf/pattern keys/yshift},
+ \pgfkeysvalueof{/pgf/pattern keys/radius},
+ \pgfkeysvalueof{/pgf/pattern keys/points},
+ },
+ bottom left={%
+ \pgfpoint
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {-.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ top right={%
+ \pgfpoint
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}%
+ {.5*(\pgfkeysvalueof{/pgf/pattern keys/distance})}},
+ tile size={%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/distance}}},
+ tile transformation={%
+ \pgftransformrotate{\pgfkeysvalueof{/pgf/pattern keys/angle}}%
+ \pgftransformshift{%
+ \pgfpoint
+ {\pgfkeysvalueof{/pgf/pattern keys/xshift}}%
+ {\pgfkeysvalueof{/pgf/pattern keys/yshift}}}},
+ defaults={
+ distance/.initial=3mm,
+ angle/.initial=0,
+ xshift/.initial=0pt,
+ yshift/.initial=0pt,
+ radius/.initial=1mm,
+ points/.initial=5,
+ },
+ code={%
+ \pgfmathsetmacro\a{180/(\pgfkeysvalueof{/pgf/pattern keys/points})}%
+ \pgfpathmoveto{\pgfpointpolar{90}{\pgfkeysvalueof{/pgf/pattern keys/radius}}}%
+ \foreach \i in {1,...,\pgfkeysvalueof{/pgf/pattern keys/points}}{%
+ \pgfpathlineto{\pgfpointpolar{90+2*\i*\a-\a}{.5*(\pgfkeysvalueof{/pgf/pattern keys/radius})}}%
+ \pgfpathlineto{\pgfpointpolar{90+2*\i*\a}{\pgfkeysvalueof{/pgf/pattern keys/radius}}}%
+ }%
+ \pgfpathclose%
+ \pgfusepath{fill}%
+ },
+}
%%% Local Variables:
%%% mode: latex
diff --git a/Master/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex b/Master/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex
index 2dbf154d8be..64dbe2b09a7 100644
--- a/Master/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex
@@ -434,7 +434,7 @@
\fi%
\fi%
\else%
- \ifdim\pgfmath@x>0.000244140625pt\relax% 2^-11
+ \ifdim\pgfmath@x>0.00048828125pt\relax% 2^-11
\ifdim\pgfmath@x>0.001953125pt\relax% 2^-9
\ifdim\pgfmath@x>0.00390625pt\relax% 2^-8
\multiply\pgfmath@x by128\relax%
diff --git a/Master/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex b/Master/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex
index c16d07005d8..e50dfd615e3 100644
--- a/Master/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex
@@ -238,7 +238,7 @@
\pgfmath@tokens@make{mathunit}{{mu}}
\pgfmath@tokens@make{numeric}{.0123456789}
\pgfmath@tokens@make{number}{0123456789}
-\pgfmath@tokens@make{functional}{_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNPQRSTUVWXYZ}
+\pgfmath@tokens@make{functional}{_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ}
\pgfmath@tokens@make{exponent}{eE}
\pgfmath@tokens@make{group}{{()}{[]}{\pgfmath@bgroup\pgfmath@egroup}}
\pgfmath@tokens@make{specials}{@)]\pgfmath@egroup}
diff --git a/Master/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex b/Master/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex
index d98ecb25d59..49313e88491 100644
--- a/Master/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex
@@ -13,6 +13,48 @@
\def\pgfmathincluded{}
+% Helper macros for \pgfmath@ifregister
+%
+\def\pgfmath@grabv#1#2#3#4#5#6#7\pgfmath@grabv{#2#3#4#5\ifx#6!!\fi}
+\def\pgfmath@ifskip@extract#1{\expandafter\pgfmath@grabv\meaning#1!!!!!!\pgfmath@grabv}
+\def\pgfmath@iftoks@extract#1{\expandafter\pgfmath@grabv\meaning#1!!!!!!\pgfmath@grabv}
+
+\def\pgfmath@grabvi#1#2#3#4#5#6#7#8\pgfmath@grabvi{#2#3#4#5#6\ifx#7!!\fi}
+\def\pgfmath@ifdimen@extract#1{\expandafter\pgfmath@grabvi\meaning#1!!!!!!\pgfmath@grabvi}
+\def\pgfmath@ifcount@extract#1{\expandafter\pgfmath@grabvi\meaning#1!!!!!!\pgfmath@grabvi}
+
+\def\pgfmath@grabvii#1#2#3#4#5#6#7#8#9\pgfmath@grabvii{#2#3#4#5#6#7\ifx#8!!\fi}
+\def\pgfmath@ifmuskip@extract#1{\expandafter\pgfmath@grabvii\meaning#1!!!!!!\pgfmath@grabvii}
+
+% \pgfmath@ifdimen@unguarded
+%
+% Check if #2 is a register of type #1.
+% Credits to Frank: https://tex.stackexchange.com/a/56905
+%
+% #1 register type (count, dimen, skip, muskip, toks)
+% #2 single token
+%
+\def\pgfmath@ifregister@unguarded#1#2{%
+ \expandafter\ifx\csname\csname pgfmath@if#1@extract\endcsname{#2}\expandafter\endcsname\csname #1\endcsname
+ \expandafter\pgfutil@firstoftwo
+ \else
+ \expandafter\pgfutil@secondoftwo
+ \fi}
+
+% \pgfmath@ifregister
+%
+% Checks if a token is a a certain type of register
+%
+% #1 register type (count, dimen, skip, muskip, toks)
+% #2 single token
+%
+\def\pgfmath@ifregister#1#2{%
+ \pgfutil@IfUndefined{pgfmath@if#1@extract}%
+ {\errmessage{Package PGF Math Error: Cannot test for #1 register}}%
+ {\pgfutil@IfUndefined{\csname pgfmath@if#1@extract\endcsname{#2}}%
+ {\pgfutil@secondoftwo}}%
+ {\pgfmath@ifregister@unguarded{#1}{#2}}}
+
% \pgfmath@ensureregister
%
% Ensure a control sequence exists as a TeX count/dimen register.
@@ -21,27 +63,9 @@
% #2 - a control sequence.
%
\def\pgfmath@ensureregister#1#2{%
- \begingroup%
- \setbox0=\hbox\bgroup\begingroup% In case #2 is a defined macro. Unlikely, but you never know...
- \afterassignment\pgfmath@@ensureregister%
- \noexpand#20.0pt\let\pgfmath@temp\relax\relax\pgfmath@#2#1\pgfmath@}
-
-\def\pgfmath@@ensureregister#1#2\pgfmath@#3#4#5\pgfmath@{%
- \endgroup\egroup%
- \endgroup%
- \ifx#4c%
- \ifx#1.% Already a count register.
- \else%
- \csname newcount\endcsname#3% This gets round \outer in plain TeX.
- \fi%
- \else%
- \ifx#4d%
- \ifx\let#1% Already a dimen register.
- \else%
- \csname newdimen\endcsname#3%
- \fi%
- \fi%
- \fi%
+ \pgfmath@ifregister{#1}{#2}%
+ {}%
+ {\csname new#1\endcsname#2}%
}
% Check registers exist. If not, create them.
diff --git a/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex b/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex
index 50c0e1e52f7..4f676aeea47 100644
--- a/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex
@@ -24,6 +24,9 @@
\let\pgf@matrix@cell=\pgfnodeparttextbox % alias
\let\pgf@matrix@box=\pgf@matrix@cell % alias
+\long\def\pgfmatrixbeforeassemblenode#1{%
+ \long\def\pgf@matrix@before@assemnble@node{#1}}
+\pgfmatrixbeforeassemblenode{}
% Sets the default row or column sep
%
@@ -211,6 +214,11 @@
\egroup\egroup%
\egroup%
%
+ % Inject custom tokens before assembling the node holding the matrix. Can
+ % be used to apply additional settings.
+ %
+ \pgf@matrix@before@assemnble@node
+ %
% If there are named nodes, we must adjust their coordinates.
%
\ifx\pgf@matrix@node@list\pgfutil@empty%
diff --git a/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleparser.code.tex b/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleparser.code.tex
index 3528771b1a8..3ac1aba9fce 100644
--- a/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleparser.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleparser.code.tex
@@ -410,7 +410,7 @@
\def\pgfparserlet@g
{%
\ifx\pgfparserlet@argb\pgfutil@sptoken
- % will also gobble the \pgfparserlet@c after \fi
+ % will also gobble the \pgfparserlet@h after \fi
\pgfparserlet@gobble@space\pgfparserlet@f
\fi
\pgfparserlet@h
@@ -496,24 +496,40 @@
{}
{\csname \pgfparser@current\space final action\endcsname}%
}
- {%
- \futurelet\pgfparsertoken\pgfparser@getnexttoken@a
- }%
+ {\futurelet\pgfparsertoken\pgfparser@getnexttoken@a}%
}
\pgfutil@protected\def\pgfparser@getnexttoken@a
{%
- \pgfparser@getnexttoken@iftokengobble\bgroup\bgroup
+ % check the problematic categories based on the meaning of the token
+ \edef\pgfparser@tokencategory{\pgfparser@extractmeaning\pgfparsertoken}%
+ \pgfparser@getnexttoken@ifcategory\pgfparser@category@i\bgroup
{%
- \pgfparser@getnexttoken@iftokengobble\egroup\egroup
+ \pgfparser@getnexttoken@ifcategory\pgfparser@category@ii\egroup
{%
- \pgfparser@getnexttoken@iftokengobble\pgfutil@sptoken{ }%
- {\pgfparser@getnexttoken@defchar}%
+ \pgfparser@getnexttoken@ifcategory\pgfparser@category@x{ }%
+ {%
+ \pgfparser@getnexttoken@ifcategory\pgfparser@category@vi{####}%
+ {\pgfparser@getnexttoken@defchar}%
+ }%
}%
}%
}
-\pgfutil@protected\def\pgfparser@getnexttoken@iftokengobble#1#2%
+\begingroup
+\def\pgfparser@extractmeaning#1%
{%
- \ifx\pgfparsertoken#1%
+ \endgroup
+ \def\pgfparser@extractmeaning##1%
+ {\expandafter\pgfparser@extractmeaning@\meaning##1#1#1\pgfparser@mark}%
+ \def\pgfparser@extractmeaning@##1#1##2#1##3\pgfparser@mark{##1#1##2}%
+ }
+\catcode`\ =12\pgfparser@extractmeaning{ } % ends the group
+\edef\pgfparser@category@i{\pgfparser@extractmeaning\bgroup}
+\edef\pgfparser@category@ii{\pgfparser@extractmeaning\egroup}
+\edef\pgfparser@category@vi{\pgfparser@extractmeaning#}
+\edef\pgfparser@category@x{\pgfparser@extractmeaning\pgfutil@sptoken}
+\pgfutil@protected\def\pgfparser@getnexttoken@ifcategory#1#2%
+ {%
+ \ifx\pgfparser@tokencategory#1%
\def\pgfparserletter{#2}%
\pgfparser@getnexttoken@gobble
\fi
diff --git a/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.code.tex b/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.code.tex
index 78edf01c626..166a5d56405 100644
--- a/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.code.tex
@@ -532,7 +532,7 @@
% Ok, check whether #1 is known!
\pgfutil@ifundefined{pgf@sh@ns@#1}
{\pgfutil@ifundefined{pgf@sh@ns@not yet positionedPGFINTERNAL#1}{%
- \pgferror{No shape named #1 is known}}{
+ \pgferror{No shape named `#1' is known}}{
% else, fail silently
}%
\pgfpointorigin}%
@@ -597,7 +597,7 @@
\def\pgfpointshapeborder#1#2{%
% Ok, check whether #1 is known!
\pgfutil@ifundefined{pgf@sh@ns@#1}
- {\pgferror{No shape named #1 is known}%
+ {\pgferror{No shape named `#1' is known}%
\pgfpointorigin}%
{%
\pgf@process{%
@@ -823,7 +823,6 @@
\anchor{north}{\centerpoint}%
\anchor{north west}{\centerpoint}%
\anchor{north east}{\centerpoint}%
- \anchor{center}{\centerpoint}%
\anchor{west}{\centerpoint}%
\anchor{east}{\centerpoint}%
\anchor{mid}{\centerpoint}%
diff --git a/Master/texmf-dist/tex/generic/pgf/pgf.revision.tex b/Master/texmf-dist/tex/generic/pgf/pgf.revision.tex
index 714fd17d5da..fd2ec0044b3 100644
--- a/Master/texmf-dist/tex/generic/pgf/pgf.revision.tex
+++ b/Master/texmf-dist/tex/generic/pgf/pgf.revision.tex
@@ -5,10 +5,10 @@
\catcode`\:=12
\catcode`\+=12
\catcode`\-=12
-\gdef\pgfrevision{3.1.4b}
-\gdef\pgfversion{3.1.4b}
-\gdef\pgfversiondatetime{2019-08-03 20:21:02 +1200}
-\gdef\pgfrevisiondatetime{2019-08-03 20:21:02 +1200}
+\gdef\pgfrevision{3.1.5}
+\gdef\pgfversion{3.1.5}
+\gdef\pgfversiondatetime{2019-12-19 19:56:10 +1300}
+\gdef\pgfrevisiondatetime{2019-12-19 19:56:10 +1300}
\gdef\pgf@glob@TMPa#1-#2-#3 #4\relax{#1/#2/#3}
\xdef\pgfversiondate{\expandafter\pgf@glob@TMPa\pgfversiondatetime\relax}
\xdef\pgfrevisiondate{\expandafter\pgf@glob@TMPa\pgfrevisiondatetime\relax}
diff --git a/Master/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-dvipdfmx.def b/Master/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-dvipdfmx.def
index 67b6cd87b3b..b2be0c9110b 100644
--- a/Master/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-dvipdfmx.def
+++ b/Master/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-dvipdfmx.def
@@ -307,21 +307,12 @@
% Image Mask came from pgfsys-pdftex.def
% generic/pgf/basiclayer/pgfcoreimage.code.tex must be modified!
\def\pgfsys@defineimage{% width, height, page number
- \ifx\includegraphics\undefined
- \ifx\pgf@imagewidth\pgfutil@empty\edef\pgf@imagewidth{1bp}\fi% width?
- \ifx\pgf@imageheight\pgfutil@empty\edef\pgf@imageheight{1bp}\fi% height?
- \ifx\pgf@imagepage\pgfutil@empty\else\edef\pgf@imagepage{ page \pgf@imagepage}\fi%
- \ifx\pgf@imageinterpolate\pgfutil@empty\else\edef\pgf@imageinterpolate{ /Interpolate\space\pgf@imageinterpolate}\fi%
- \ifx\pgf@imagemask\pgfutil@empty\else\xdef\pgf@imagemask{ /SMask @\pgf@imagemask}\fi%
- \edef\pgf@image{\noexpand\hbox to \pgf@imagewidth{\vbox to \pgf@imageheight{\vfil\special{pdf:image width \pgf@imagewidth\space height \pgf@imageheight\space\pgf@imagepage\space(\pgf@filename) <<\pgf@imageinterpolate\pgf@imagemask\space>>}}\hfil}}%
- \else
- \ifx\pgf@imagewidth\pgfutil@empty\else\edef\pgf@imagewidth{width=\pgf@imagewidth,}\fi%
- \ifx\pgf@imageheight\pgfutil@empty\else\edef\pgf@imageheight{height=\pgf@imageheight,}\fi%
- \ifx\pgf@imagepage\pgfutil@empty\else\edef\pgf@imagepage{page=\pgf@imagepage,}\fi%
- \ifx\pgf@imageinterpolate\pgfutil@empty\else\edef\pgf@imageinterpolate{interpolate=\pgf@imageinterpolate,}\fi%
- \ifx\pgf@imagemask\pgfutil@empty\else\xdef\pgf@imagemask{mask=\pgf@imagemask,}\fi%
- \edef\pgf@image{\noexpand\includegraphics[\pgf@imageheight\pgf@imagewidth\pgf@imagepage\pgf@imageinterpolate\pgf@imagemask]{\pgf@filename}}%
- \fi%
+ \ifx\pgf@imagewidth\pgfutil@empty\edef\pgf@imagewidth{1bp}\fi% width?
+ \ifx\pgf@imageheight\pgfutil@empty\edef\pgf@imageheight{1bp}\fi% height?
+ \ifx\pgf@imagepage\pgfutil@empty\else\edef\pgf@imagepage{ page \pgf@imagepage}\fi%
+ \ifx\pgf@imageinterpolate\pgfutil@empty\else\edef\pgf@imageinterpolate{ /Interpolate\space\pgf@imageinterpolate}\fi%
+ \ifx\pgf@imagemask\pgfutil@empty\else\xdef\pgf@imagemask{ /SMask @\pgf@imagemask}\fi%
+ \edef\pgf@image{\noexpand\hbox to \pgf@imagewidth{\vbox to \pgf@imageheight{\vfil\special{pdf:image width \pgf@imagewidth\space height \pgf@imageheight\space\pgf@imagepage\space(\pgf@filename) <<\pgf@imageinterpolate\pgf@imagemask\space>>}}\hfil}}%
}
\def\pgfsys@definemask#1{%
\ifx\pgf@maskmatte\pgfutil@empty%
@@ -377,7 +368,7 @@
% hook for xdvipdfmx:
\def\pgfsys@dvipdfmx@patternobj#1{%
- #1%
+ \pgfutil@insertatbegincurrentpagefrombox{#1}%
}%
% hook for xdvipdfmx:
diff --git a/Master/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex b/Master/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex
index 2f17652628a..73922a0f097 100644
--- a/Master/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex
@@ -74,9 +74,9 @@
}
\long\def\pgfkeyssetevalue#1#2{%
- \pgfkeys@temptoks={#2}%
- \pgfkeys@temptoks=\scantokens\expandafter{\expandafter{\the\pgfkeys@temptoks}}%
- \expandafter\edef\csname pgfk@#1\expandafter\endcsname\expandafter{\the\pgfkeys@temptoks}%
+ \edef\pgfkeys@temp##1##2##3##4##5##6##7##8##9{#2}%
+ \pgfkeys@temptoks=\expandafter{\pgfkeys@temp{##1}{##2}{##3}{##4}{##5}{##6}{##7}{##8}{##9}}%
+ \expandafter\edef\csname pgfk@#1\endcsname{\the\pgfkeys@temptoks}%
}
% Add text to a key at the end
@@ -401,11 +401,11 @@
% - path := '/my search path'
% - name := 'key/.code'
% - key = '/my search path/key/.code'
- \let\pgfkeys@temp=\pgfkeyscurrentkey
+ \let\pgfkeys@tempa=\pgfkeyscurrentkey
\let\pgfkeys@tempb=\pgfkeyscurrentname
\edef\pgfkeyscurrentkey{\pgfkeyscurrentpath}%
\pgfkeys@split@path%
- \let\pgfkeyscurrentkey=\pgfkeys@temp
+ \let\pgfkeyscurrentkey=\pgfkeys@tempa
\edef\pgfkeyscurrentname{\pgfkeyscurrentname/\pgfkeys@tempb}%
\pgfkeys@unknown
}%
@@ -958,6 +958,16 @@
\long\def\pgfkeys@exp@call#1{\pgfkeysalso{\pgfkeyscurrentpath={#1}}}
+\def\pgfkeys@mathparse{%
+ \ifcsname pgfmathparse\endcsname
+ \expandafter\pgfmathparse
+ \else
+ \pgfkeys@error{You have to load `pgfmath' to use \string\pgfmathparse}%
+ \expandafter\def\expandafter\pgfmathresult
+ \fi
+}
+\pgfkeys{/handlers/.evaluated/.code=\pgfkeys@mathparse{#1}\expandafter\pgfkeys@exp@call\expandafter{\pgfmathresult}}
+
% Try to set a key and do nothing if not define
\newif\ifpgfkeyssuccess
diff --git a/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex b/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex
index 6fbaf2687ba..b1c0546c17e 100644
--- a/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex
+++ b/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex
@@ -59,20 +59,16 @@
\fi}
% A variant of \pgfutil@ifundefined which will NOT let #1 to \relax it
-% is undefined. However, this macro is not expandable.
+% is undefined.
\def\pgfutil@IfUndefined#1{%
- \begingroup\expandafter\expandafter\expandafter\endgroup
- \expandafter\ifx\csname#1\endcsname\relax
- \expandafter\pgfutil@firstoftwo
- \else
+ \ifcsname#1\endcsname
\expandafter\pgfutil@secondoftwo
+ \else
+ \expandafter\pgfutil@firstoftwo
\fi
}
\long\def\pgfutil@firstofone#1{#1}
\long\def\pgfutil@firstoftwo#1#2{#1}
-\long\def\pgfutil@letfirst#1#2{\pgfutil@letfirst@#1#2\pgfutil@letfirst@end}
-\long\def\pgfutil@letfirst@#1#2#3\pgfutil@letfirst@end{\let#1=#2}
-\def\pgfutil@letfirst@end{}
\long\def\pgfutil@secondoftwo#1#2{#2}
\def\pgfutil@empty{}
\long\def\pgfutil@gobble@until@relax#1\relax{}
@@ -215,6 +211,45 @@
\let\pgfutil@repeat=\fi % this makes \loop...\if...\repeat skippable
+% \pgfutil@switch
+%
+% #1: string to switch on
+% #2: sequence of label-value pairs
+%
+% Example:
+%
+% \pgfutil@switch{foo}{%
+% {foo}{1}%
+% {bar}{2}%
+% {default}{X}%
+% }
+%
+% If a statement with the label `default' exists it will be executed
+% if no other label matches.
+
+\long\def\pgfutil@switch#1#2{%
+ \begingroup
+ \def\pgfutil@switch@selected{}%
+ \pgfutil@switch@collect@statements#2{}{}%
+ \ifcsname pgfutil@switch@choice@\detokenize{#1}\endcsname
+ \expandafter\let\expandafter\pgfutil@switch@selected\csname pgfutil@switch@choice@\detokenize{#1}\endcsname
+ \else
+ \ifdefined\pgfutil@switch@choice@default
+ \let\pgfutil@switch@selected\pgfutil@switch@choice@default
+ \fi
+ \fi
+ \expandafter\endgroup\pgfutil@switch@selected
+}
+
+\long\def\pgfutil@switch@collect@statements#1{%
+ \if\relax\detokenize{#1}\relax
+ \else
+ \afterassignment\pgfutil@switch@collect@statements
+ \expandafter\def\csname pgfutil@switch@choice@\detokenize{#1}\expandafter\endcsname
+ \fi
+}
+
+
% aux-read-hook
\let\pgfutil@aux@read@hook=\relax
@@ -709,7 +744,7 @@
\let\pgfmathresult=\pgfutil@empty
\else
% xb := rb / bb (the modified rb and modified bb!)
- \edef\pgf@marshal{
+ \edef\pgf@marshal{%
\noexpand\pgfmathfloatdivide@
{\csname r\Pb\endcsname}
{\csname m\Pb b\endcsname}%
diff --git a/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-context.def b/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-context.def
index bf7e43a298c..7d244efc5fa 100644
--- a/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-context.def
+++ b/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-context.def
@@ -167,11 +167,12 @@
\def\pgfutil@minipage[#1]#2{%
\hbox to#2\bgroup
\hsize=#2\relax
- \vbox\bgroup\leavevmode
+ \vbox\bgroup
+ \noindentation
}
\def\pgfutil@endminipage{%
- \egroup
+ \egroup
\egroup
}
@@ -225,7 +226,7 @@
\doifmodeelse {mkiv} {
- \def\pgfsysdriver{pgfsys-pdftex.def}
+ \def\pgfutil@guessdriver{\def\pgfsysdriver{pgfsys-luatex.def}}
\def\pgfutil@driver@if@in#1#2{%
\edef\pgf@marshal{\noexpand\pgfutil@in@{#1}{\preloadedspecials}}%
@@ -358,7 +359,7 @@
\appendtoks \the\pgfutil@everybye \to \everybye
-\long\def\AtBeginDocument#1{#1}%
+\long\def\AtBeginDocument#1{\appendtoks#1\to\everystarttext}%
% pgfcalendar uses translations
diff --git a/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-plain.def b/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-plain.def
index 090fcaeb5ae..95dacd18a46 100644
--- a/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-plain.def
+++ b/Master/texmf-dist/tex/generic/pgf/utilities/pgfutil-plain.def
@@ -26,6 +26,15 @@
\def\pgfutil@emu@rgb#1#2,#3,#4\@nil{\expandafter\def\csname\string\color@#1\endcsname{\xcolor@{}{}{rgb}{#2,#3,#4}}}
\def\pgfutil@emu@gray#1#2\@nil{\expandafter\def\csname\string\color@#1\endcsname{\xcolor@{}{}{rgb}{#2,#2,#2}}}
+\def\pgfutil@emu@RGB#1#2,#3,#4\@nil{%
+ \begingroup
+ \pgfmathdivide@{#2}{255}\let\pgfutil@emu@RGB@r\pgfmathresult
+ \pgfmathdivide@{#3}{255}\let\pgfutil@emu@RGB@g\pgfmathresult
+ \pgfmathdivide@{#4}{255}\let\pgfutil@emu@RGB@b\pgfmathresult
+ \edef\pgf@marshal{\def\expandafter\noexpand\csname\string\color@#1\endcsname{%
+ \noexpand\xcolor@{}{}{rgb}{\pgfutil@emu@RGB@r,\pgfutil@emu@RGB@g,\pgfutil@emu@RGB@b}}}%
+ \expandafter\endgroup\pgf@marshal
+}
\pgfutil@definecolor{white}{gray}{1}
\pgfutil@definecolor{black}{gray}{0}
diff --git a/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.pdflinks.code.tex b/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.pdflinks.code.tex
index a23b9ad6861..370c5ad071d 100644
--- a/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.pdflinks.code.tex
+++ b/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.pdflinks.code.tex
@@ -53,13 +53,6 @@
\newif\ifpgfmanualshowlabels
-% FIXME : \cleanedhypertarget/\cleanedhyperlink have been introduced
-% in http://pgf.cvs.sourceforge.net/viewvc/pgf/pgf/latex/pgf/doc/pgfmanual.pdflinks.code.tex?r1=1.15&r2=1.16
-% but they are not present on my (CFR) system... what problem did they
-% address/how can we satisfy this dependency?
-\pgfutil@IfUndefined{cleanedhypertarget}{\let\cleanedhypertarget=\hypertarget}{}
-\pgfutil@IfUndefined{cleanedhyperlink}{\let\cleanedhyperlink=\hyperlink}{}
-
\pgfkeys{%
/codeexample/prettyprint/cs arguments/pgfkeys/.initial=1,
/codeexample/prettyprint/cs/pgfkeys/.code 2 args={\pgfmanualpdfref{#1}{#1}\{\pgfmanualprettyprintpgfkeys{#2}\pgfmanualclosebrace},
@@ -238,9 +231,9 @@
\expandafter\gdef\csname pgfd@lbl@\pgfmanualpdflabel@@\endcsname{w}% 1. remember the label AND remember that we "w"rote it into the pdf.
\edef\pgfmanualpdflabel@@{\pgfkeysvalueof{/pdflinks/internal link prefix}.\pgfmanualpdflabel@@}%
\ifvmode%
- \expandafter\cleanedhypertarget\expandafter{\pgfmanualpdflabel@@}{#2}%
+ \expandafter\hypertarget\expandafter{\pgfmanualpdflabel@@}{#2}%
\else%
- {\setbox0=\hbox{\raise1em\hbox{\expandafter\cleanedhypertarget\expandafter{\pgfmanualpdflabel@@}{}}}\ht0=0pt\box0}#2%
+ {\setbox0=\hbox{\raise1em\hbox{\expandafter\hypertarget\expandafter{\pgfmanualpdflabel@@}{}}}\ht0=0pt\box0}#2%
\fi%
\else
#2%
@@ -287,7 +280,7 @@
}%
\def\pgfmanualpdfref@#1#2{%
\pgfkeysgetvalue{/pdflinks/internal link prefix}\pgfmanual@temp
- \expandafter\cleanedhyperlink\expandafter{\pgfmanual@temp.#1}{\pgfkeysvalueof{/pdflinks/render hyperlink/.@cmd}{#2}\pgfeov}%
+ \expandafter\hyperlink\expandafter{\pgfmanual@temp.#1}{\pgfkeysvalueof{/pdflinks/render hyperlink/.@cmd}{#2}\pgfeov}%
\ifpgfmanualshowlabels
\pgfkeysvalueof{/pdflinks/show labels code/.@cmd}{#1}\pgfeov
\fi
diff --git a/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.prettyprinter.code.tex b/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.prettyprinter.code.tex
index e8aa334224c..3a230cac233 100644
--- a/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.prettyprinter.code.tex
+++ b/Master/texmf-dist/tex/latex/pgf/doc/pgfmanual.prettyprinter.code.tex
@@ -720,7 +720,7 @@
% Collects tokens inside of a token list up to a single delimiting token, dealing with nested
% catcode-12-braces.
%
-% #1: is the end token, the delimiter. It won't be collected.
+% #1: list of tokens, each of which is marking the end. It won't be collected.
% #2: is code to invoke after
% \pgfmanualprettyprinterhandlecollectedargsVtwo has been invoked.
%
@@ -742,8 +742,9 @@
%
\def\pgfmanualprettyprintercollectupto#1#2{%
\pgfmanualprettyprinterarghasunmatchedbracesfalse
+ \def\pgfmanualprettyprinterterminator{}%
\begingroup
- \def\pgfmanual@loc@delimittoken{#1}%
+ \def\pgfmanual@loc@delimittokens{#1}%
\toksdef\t@afterpgfmanualprettyprinterhandlecollected=10
\t@afterpgfmanualprettyprinterhandlecollected={#2}%
%
@@ -758,6 +759,12 @@
\pgfmanual@pretty@collectupto@loop
}%
+% Stores the token that marks the end in the first argument of
+% \pgfmanualprettyprintercollectupto. For example if the token list was {,]}
+% and ] was encountered first, then \pgfmanualprettyprinterterminator will
+% be ].
+\def\pgfmanualprettyprinterterminator{}
+
% loops through all tokens, collecting the required number of
% arguments. This involves to track nested braces manually.
% #1 is a single token.
@@ -794,11 +801,13 @@
\advance\c@pgfmanual@pretty@openbracecount by-1
\t@pgfmanual@currentarg=\expandafter{\the\t@pgfmanual@currentarg#1}%
\else
- \ifx\pgfmanual@loc@TMPc\pgfmanual@loc@delimittoken
+ \expandafter\expandafter\expandafter\pgfutil@in@\expandafter\pgfmanual@loc@TMPc\expandafter{\pgfmanual@loc@delimittokens}%
+ \ifpgfutil@in@
\ifnum\c@pgfmanual@pretty@openbracecount=0
% do NOT include the delimit token.
\edef\pgfmanual@pretty@collectupto@loop@NEXT{%
\noexpand\endgroup
+ \noexpand\def\noexpand\pgfmanualprettyprinterterminator{\pgfmanual@loc@TMPc}%
\noexpand\pgfmanualprettyprinterhandlecollectedargsVtwo{\the\t@pgfmanual@currentarg}{1}%
\noexpand\pgfmanualprettyprintercollectupto@restore@callback
\the\t@afterpgfmanualprettyprinterhandlecollected
@@ -1053,7 +1062,7 @@
\if\pgfmanual@pretty@isconsumed0%
\def\pgfmanualprettyprinterhandlecollectedargsVtwo##1##2{\pgfmanual@pretty@pgfkeys@processvalue{##1}}% the braces will be handled separately.
\def\pgfmanual@pretty@pgfkeys@collectvalue@next{%
- \pgfmanualprettyprintercollectupto,{\afterpgfmanual@pretty@collectargs@finish@value}#1%
+ \pgfmanualprettyprintercollectupto{,]}{\afterpgfmanual@pretty@collectargs@finish@value}#1%
}%
\fi
\fi
@@ -1063,7 +1072,7 @@
\pgfutil@ifnextchar\pgfmanual@EOI{%
\pgfmanual@pretty@pgfkeys@loop
}{%
- \pgfmanual@pretty@pgfkeys@loop,% re-insert the gobbled comma here!
+ \expandafter\pgfmanual@pretty@pgfkeys@loop\pgfmanualprettyprinterterminator% re-insert the gobbled comma here!
}%
}%
diff --git a/Master/texmf-dist/tex/latex/pgf/utilities/tikzexternal.sty b/Master/texmf-dist/tex/latex/pgf/utilities/tikzexternal.sty
index 4f9d31572f6..75cb9aedb56 100644
--- a/Master/texmf-dist/tex/latex/pgf/utilities/tikzexternal.sty
+++ b/Master/texmf-dist/tex/latex/pgf/utilities/tikzexternal.sty
@@ -69,6 +69,10 @@
\def\tikz@opt@process#1#2{\tikzexternal@image}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\def\pgf@marshal{\let\ifmeasuring@\iffalse}
+\ifdefined\ifmeasuring@\else
+ \expandafter\pgf@marshal
+\fi
\def\tikzexternal@image{%
\leavevmode
\begingroup
@@ -80,14 +84,18 @@
\t@tikzexternal@tmpb=\expandafter{\tikzexternal@figurename}%
\count0=\csname c@tikzext@no@\tikzexternal@figurename\endcsname
\xdef\tikzexternal@curfilename{\the\t@tikzexternal@tmpa\the\t@tikzexternal@tmpb\the\count0 }%
- \advance\count0 by1\relax
+ \ifmeasuring@\else
+ \advance\count0 by1\relax
+ \fi
\expandafter\xdef\csname c@tikzext@no@\tikzexternal@figurename\endcsname{\the\count0 }%
\else
\t@tikzexternal@tmpb=\expandafter{\tikzexternal@nextfile}%
\xdef\tikzexternal@curfilename{\the\t@tikzexternal@tmpa\the\t@tikzexternal@tmpb}%
\fi
\endgroup
- \global\let\tikzexternal@nextfile=\empty
+ \ifmeasuring@\else
+ \global\let\tikzexternal@nextfile=\empty
+ \fi
\pgfincludeexternalgraphics\tikzexternal@curfilename
}%
\def\tikzset#1{}\def\pgfkeys#1{}\def\pgfqkeys#1#2{}