summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulesnakes.code.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/pgf/modules/pgfmodulesnakes.code.tex')
-rw-r--r--Master/texmf-dist/tex/generic/pgf/modules/pgfmodulesnakes.code.tex58
1 files changed, 29 insertions, 29 deletions
diff --git a/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulesnakes.code.tex b/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulesnakes.code.tex
index 9df6d309801..f87a884b417 100644
--- a/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulesnakes.code.tex
+++ b/Master/texmf-dist/tex/generic/pgf/modules/pgfmodulesnakes.code.tex
@@ -11,7 +11,7 @@
\pgfwarning{Snakes have been superseded by decorations. Use the module decorations instead of snakes}
-\usepgfmodule{decorations}%
+\usepgfmodule{decorations}
\endinput
@@ -58,7 +58,7 @@
\let\state=\pgf@snake@state
#3
\let\state=\pgf@orig@state%
-}%
+}
% Sets the additional transformation applied to every segment of a snake
@@ -69,8 +69,8 @@
%
% \pgfsetsnakesegmenttransformation{\pgftransformyshift{5pt}}
-\def\pgfsetsnakesegmenttransformation#1{\def\pgf@snakeadditionaltransform{#1}}%
-\pgfsetsnakesegmenttransformation{}%
+\def\pgfsetsnakesegmenttransformation#1{\def\pgf@snakeadditionaltransform{#1}}
+\pgfsetsnakesegmenttransformation{}
% Declares a new state
@@ -96,11 +96,11 @@
% \pgfpathlineto{\pgfpoint{10pt}{0pt}}
% }
-\def\pgf@snake@state#1{\pgfutil@ifnextchar[{\pgf@@snake@start#1}{\pgf@@snake@start#1[]}}%}%
+\def\pgf@snake@state#1{\pgfutil@ifnextchar[{\pgf@@snake@start#1}{\pgf@@snake@start#1[]}}%}
\def\pgf@@snake@start#1[#2]#3{%
\pgfutil@namedef{pgf@snake@@\pgf@snake@name @#1@options}{#2}%
\pgfutil@namedef{pgf@snake@@\pgf@snake@name @#1@code}{#3}%
-}%
+}
@@ -131,8 +131,8 @@
% MW: Calculate the angle of the snake.
%
\edef\pgf@marshal{%
- \noexpand\pgfmathanglebetweenpoints{\noexpand\pgfpointorigin}{%
- \noexpand\pgf@x\the\pgf@x\noexpand\pgf@y\the\pgf@y}%
+ \noexpand\pgfmathanglebetweenpoints{\noexpand\pgfpointorigin}{%
+ \noexpand\pgf@x\the\pgf@x\noexpand\pgf@y\the\pgf@y}%
}%
\pgf@marshal%
\let\pgfsnakeangle\pgfmathresult%
@@ -194,7 +194,7 @@
\fi%
}%
\endgroup%
-}%
+}
\def\pgf@snake@invoke#1#2{%
\pgfmathsetlength\pgf@xa{#2}%
@@ -204,7 +204,7 @@
}%
\advance\pgfsnakecompleteddistance by\pgf@xa%
\advance\pgfsnakeremainingdistance by-\pgf@xa%
-}%
+}
% Use a snake
%
@@ -212,13 +212,13 @@
% #2 = point to which the snake leads
%
% This operation mainly computes \pgfpathsnakealongvector for a vector
-% appropriately chosen. See \pgfpathsnakealongvector for details.
+% appropriately choosen. See \pgfpathsnakealongvector for details.
%
% Example:
%
% \pgfpathsnaketo{zig zag}{\pgfpoint{2cm}{3cm}}
-\def\pgfpathsnaketo#1#2{\pgfpathsnakesto{{#1}{\pgfsnakeremainingdistance}}{#2}}%
+\def\pgfpathsnaketo#1#2{\pgfpathsnakesto{{#1}{\pgfsnakeremainingdistance}}{#2}}
@@ -240,7 +240,7 @@
% translated by the width of the path element as specified in the
% width option of the path element. The dimensions
% \pgfsnakeremainingdistance and \pgfsnakecompleteddistance are
-% updated.
+% updated.
%
% The process ends when the state `final' is entered. The code of the
% final state is executed and the process stops.
@@ -251,7 +251,7 @@
\def\pgfpathsnakealongvector#1#2#3{%
\pgfutil@ifundefined{pgf@snake@@#1@initial}{\pgferror{Undefined snake ``#1''}}
- {
+ {
\begingroup% keep things local
\pgftransformreset%
\pgf@pt@x=\pgf@path@lastx% evil trickery to transform to the last point
@@ -267,8 +267,8 @@
{\pgfpointorigin}%
% Now, setup the automaton
\expandafter\let\expandafter\pgf@snake@current@state\expandafter=\csname pgf@snake@@#1@initial\endcsname%
- \def\pgf@snake@name{#1}%
- \pgfsnakecompleteddistance=0pt%
+ \def\pgf@snake@name{#1}%
+ \pgfsnakecompleteddistance=0pt%
\pgfmathsetlength\pgfsnakeremainingdistance{#2}%
\pgf@snake@run%
% Last step:
@@ -279,17 +279,17 @@
}%
\endgroup%
}%
-}%
+}
-\def\pgf@final@text{final}%
+\def\pgf@final@text{final}
\def\pgf@snake@run{%
\let\pgf@snake@next=\pgf@snake@do@state%
\ifx\pgf@snake@current@state\pgf@final@text%
\let\pgf@snake@next=\relax%
\fi%
- \pgf@snake@next%
-}%
+ \pgf@snake@next%
+}
\def\pgf@snake@do@state{%
\let\pgf@snake@next=\relax%
@@ -301,10 +301,10 @@
\let\pgf@snake@next=\pgf@snake@do@code%
\fi%
\pgf@snake@next%
-}%
+}
\def\pgf@snakes@setter{%
\pgfqkeys{/pgf/snakes}%
-}%
+}
\def\pgf@snake@do@code{%
% Ok, execute code:
@@ -320,13 +320,13 @@
% Next iteration:
\let\pgf@snake@current@state=\pgf@snake@next@state%
\pgf@snake@run%
-}%
+}
\pgfkeys{
/pgf/snakes/width/.code=\def\pgf@snake@width{#1}\pgf@snake@switch@if#1 to final\pgf@stop,%
/pgf/snakes/switch if less than/.code=\pgf@snake@switch@if#1\pgf@stop,%
/pgf/snakes/next state/.store in=\pgf@snake@next@state%
-}%
+}
\def\pgf@snake@switch@if#1to #2\pgf@stop{%
\ifx\pgf@snake@next\relax%
@@ -336,7 +336,7 @@
\let\pgf@snake@next=\pgf@snake@run%
\fi%
\fi%
-}%
+}
@@ -346,10 +346,10 @@
% in conjunction with other snakes.
\pgfdeclaresnake{lineto}{final}
-{%
+{
\state{final}
{ \pgfpathlineto{\pgfqpoint{\pgfsnakeremainingdistance}{0pt}} }
-}%
+}
@@ -359,10 +359,10 @@
% useful in conjunction with other snakes.
\pgfdeclaresnake{moveto}{final}
-{%
+{
\state{final}
{ \pgfpathmoveto{\pgfqpoint{\pgfsnakeremainingdistance}{0pt}} }
-}%
+}