summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/pgfplots/pgfplots.paths.code.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/pgfplots/pgfplots.paths.code.tex')
-rw-r--r--Master/texmf-dist/tex/generic/pgfplots/pgfplots.paths.code.tex71
1 files changed, 71 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/generic/pgfplots/pgfplots.paths.code.tex b/Master/texmf-dist/tex/generic/pgfplots/pgfplots.paths.code.tex
new file mode 100644
index 00000000000..077a3a2b95d
--- /dev/null
+++ b/Master/texmf-dist/tex/generic/pgfplots/pgfplots.paths.code.tex
@@ -0,0 +1,71 @@
+%--------------------------------------------
+%
+% Package pgfplots
+%
+% Provides a user-friendly interface to create function plots (normal
+% plots, semi-logplots and double-logplots).
+%
+% It is based on Till Tantau's PGF package.
+%
+% Copyright 2007-2012 by Christian Feuersänger.
+%
+% This program is free software: you can redistribute it and/or modify
+% it under the terms of the GNU General Public License as published by
+% the Free Software Foundation, either version 3 of the License, or
+% (at your option) any later version.
+%
+% This program is distributed in the hope that it will be useful,
+% but WITHOUT ANY WARRANTY; without even the implied warranty of
+% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+% GNU General Public License for more details.
+%
+% You should have received a copy of the GNU General Public License
+% along with this program. If not, see <http://www.gnu.org/licenses/>.
+%
+%--------------------------------------------
+%
+
+\newif\ifpgfplots@path@replace@ellipse
+
+\def\pgfplots@install@path@replacements{%
+ \ifpgfplots@path@replace@ellipse
+ \let\tikz@do@circle=\pgfplots@path@@tikz@do@circle
+ \expandafter\def\expandafter\pgfinterruptpicture\expandafter{\pgfinterruptpicture
+ \let\tikz@do@circle=\pgfplots@path@@tikz@do@circle@orig
+ }%
+ \fi
+}%
+
+\let\pgfplots@path@@tikz@do@circle@orig=\tikz@do@circle
+
+% This is a replacement for \tikz@do@circle which replaces the "xy"
+% coordinate system by one which is compatible with pgfplots.
+\def\pgfplots@path@@tikz@do@circle#1#2{%
+ \begingroup
+ \ifpgfplots@usefpu
+ \pgfkeys{/pgf/fpu,/pgf/fpu/output format=fixed}%
+ \fi
+ \pgfmathparse{#1}%
+ \let\tikz@ellipse@x=\pgfmathresult%
+ \ifpgfmathunitsdeclared%
+ \pgfmathparse{#2}%
+ \let\tikz@ellipse@y=\pgfmathresult%
+ \ifpgfmathunitsdeclared%
+ \pgfpathellipse{\pgfpointorigin}{%
+ \pgfqpoint{\tikz@ellipse@x pt}{0pt}}{\pgfpoint{0pt}{\tikz@ellipse@y pt}}%
+ \else%
+ \PackageError{tikz}{You cannot mix dimensions and dimensionless values in an ellipse}{}%
+ \fi%
+ \else%
+ \pgfmathparse{#2}%
+ \let\tikz@ellipse@y=\pgfmathresult%
+ \ifpgfmathunitsdeclared%
+ \PackageError{tikz}{You cannot mix dimensions and dimensionless values in an ellipse}{}%
+ \else%
+ \pgfpathellipse{\pgfpointorigin}
+ {\pgfplotspointaxisdirectionxy{\tikz@ellipse@x}{0}}
+ {\pgfplotspointaxisdirectionxy{0}{\tikz@ellipse@y}}%
+ \fi%
+ \fi%
+ \endgroup
+}