summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/pst-plot
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-02-24 00:16:51 +0000
committerKarl Berry <karl@freefriends.org>2012-02-24 00:16:51 +0000
commitbbda79f1b26d36a1eb6e35d06d722bae782908ef (patch)
treec2e05bb6da9602de3a7ad68bd58373d21bb09312 /Master/texmf-dist/tex/generic/pst-plot
parent6555c8caab96adf220665d0834350a10123d6240 (diff)
pst-plot 1.38 (23feb12)
git-svn-id: svn://tug.org/texlive/trunk@25485 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/pst-plot')
-rw-r--r--Master/texmf-dist/tex/generic/pst-plot/pst-plot.tex88
1 files changed, 47 insertions, 41 deletions
diff --git a/Master/texmf-dist/tex/generic/pst-plot/pst-plot.tex b/Master/texmf-dist/tex/generic/pst-plot/pst-plot.tex
index 12eaf98bae8..0a41943f9ef 100644
--- a/Master/texmf-dist/tex/generic/pst-plot/pst-plot.tex
+++ b/Master/texmf-dist/tex/generic/pst-plot/pst-plot.tex
@@ -1,4 +1,4 @@
-% $Id: pst-plot.tex 601 2011-11-07 10:26:05Z herbert $
+% $Id: pst-plot.tex 665 2012-02-23 07:26:33Z herbert $
%% BEGIN pst-plot.tex
%%
%% plotting functions and data with PSTricks.
@@ -20,8 +20,8 @@
\ifx\PSTFPloaded\endinput\else \input pst-fp.tex \fi
\ifx\MultidoLoaded\endinput\else \input multido.tex \fi
%
-\def\fileversion{1.34}
-\def\filedate{2011/11/07}
+\def\fileversion{1.38}
+\def\filedate{2012/02/23}
\message{ v\fileversion, \filedate\space (tvz,hv)}
%
\edef\TheAtCode{\the\catcode`\@}
@@ -157,14 +157,19 @@ D\space##1%
%
\def\beginplot@line{\begin@OpenObj}
\def\endplot@line{\psline@ii}
+%
\def\beginplot@polygon{\begin@ClosedObj}
\def\endplot@polygon{\pspolygon@ii}
+%
\def\beginplot@curve{\begin@OpenObj}
\def\endplot@curve{\pscurve@ii}
+%
\def\beginplot@ecurve{\begin@OpenObj}
\def\endplot@ecurve{\psecurve@ii}
+%
\def\beginplot@ccurve{\begin@ClosedObj}
\def\endplot@ccurve{\psccurve@ii}
+%
\def\beginplot@dots{\begin@SpecialObj}
\def\endplot@dots{\psdots@ii}
%
@@ -192,8 +197,10 @@ D\space##1%
%
\def\beginplot@bezier{\begin@OpenObj}
\def\endplot@bezier{\psbezier@ii}
+%
\def\beginplot@cbezier{\begin@ClosedObj}
\def\endplot@cbezier{\pscbezier@ii}
+
% added 2007-06-26 (hv)
\let\beginplot@LineToYAxis\beginplot@line % all from pst-plot
\def\endplot@LineToYAxis{\psLineToYAxis@ii}
@@ -265,7 +272,7 @@ D\space##1%
\Pst@Debug\space 0 gt { % print the equation
/Helvetica findfont 12 scalefont setfont
0 -50 moveto (y=) show % print y=
- v 20 string cvs show ( x+) show % m*x+
+ v \pst@number\psyunit \pst@number\psxunit div div 20 string cvs show ( x+) show % m*x+
u \pst@number\psyunit div 20 string cvs show } if
newpath
(\psk@xStart) length 0 gt % special start value?
@@ -331,11 +338,10 @@ D\space##1%
0 1 m 1 sub { % Index on stack
dup /Index ED
NArray exch get LowerQuartil sub abs IQL sub 0 gt {
- gsave
-% newpath
- 0 NArray Index get 2 0 360 arc gsave
- 1 0 0 setrgbcolor fill stroke
- grestore
+ \psk@dotsize
+ \@nameuse{psds@\psk@dotstyle}
+ 0 NArray Index get
+ Dot
NArray Index LowerQuartil UpperQuartil LowerQuartil sub \pst@IQLfactor\space mul sub
dup /MinVal ED put % replace with 1.5 IQL
% NArray Index 1 add get /MinVal ED
@@ -345,16 +351,12 @@ D\space##1%
dup /Index ED
NArray exch get UpperQuartil sub abs IQL sub 0 gt {
% newpath
- gsave
- 0 NArray Index get 2 0 360 arc gsave
- 1 0 0 setrgbcolor fill stroke
- grestore
+ \psk@dotsize
+ \@nameuse{psds@\psk@dotstyle}
+ 0 NArray Index get
+ Dot
NArray Index UpperQuartil LowerQuartil sub \pst@IQLfactor\space mul UpperQuartil add
dup /MaxVal ED put % replace with 1.5 IQL
-% closepath
-% NArray Index 1 sub get dup
-% IQL 1.5 mul UpperQuartil add gt { pop IQL 1.5 mul UpperQuartil add dup
-% NArray } if /MaxVal ED
}{ exit } ifelse
} for
%
@@ -448,17 +450,18 @@ D\space##1%
%
\def\beginqp@line{\pst@oplineto}
\def\doqp@line{
- dup
- \psk@yMaxValue \pst@number\psyunit mul gt
- { moveto }{
- dup
- \psk@yMinValue \pst@number\psyunit mul lt
- { moveto }{ L } ifelse
- } ifelse
+ dup
+ \psk@yMaxValue \pst@number\psyunit mul gt
+ { moveto }
+ { dup \psk@yMinValue \pst@number\psyunit mul lt
+ { moveto }
+ { L } ifelse
+ } ifelse
}
\def\endqp@line{%
\ifPst@variableLW \addto@pscode{ \pst@flattenpath }\fi%
\end@OpenObj}%
+
\def\testqp@line{%
\ifdim\pslinearc>\z@\else
\ifshowpoints\else
@@ -783,7 +786,7 @@ D\space##1%
\def\psplotinit#1{\xdef\psplot@init{#1 }}
\def\psplot@init{}
%
-\def\psplot{\pst@object{psplot}}
+\def\psplot{\def\pst@par{}\pst@object{psplot}}
\def\psplot@i#1#2{\@ifnextchar[{\psplot@x{#1}{#2}}{\psplot@x{#1}{#2}[]}}
\def\psplot@x#1#2[#3]#4{%
\pst@killglue%
@@ -854,15 +857,18 @@ D\space##1%
{ epsilon12 exch div 1 3 div exp /StillZero 0 def }
ifelse } bind def
\fi
- /xy {
- x \pst@number\psxunit mul F@pstplot \pst@number\psyunit mul
+ /xy { x \pst@number\psxunit mul F@pstplot \pst@number\psyunit mul
% \ifPst@algebraic F@pstplot \else #4 \fi \pst@number\psyunit mul
} def}%
\fi%
\gdef\psplot@init{}%
- \@pstfalse%
- \@nameuse{testqp@\psplotstyle}%
- \if@pst\psplot@ii\else\psplot@iii\fi%
+ \ifx\pslinestyle\psls@@symbol
+ \psplot@iii
+ \else
+ \@pstfalse%
+ \@nameuse{testqp@\psplotstyle}%
+ \if@pst\psplot@ii\else\psplot@iii\fi%
+ \fi%
\endgroup%
\ignorespaces}
%
@@ -876,7 +882,8 @@ D\space##1%
/x x 3 -1 roll add dup x1 gt {pop x1} if def
xy \@nameuse{doqp@\psplotstyle}
x x1 eq { exit } if} loop}%
- \else\pst@killglue%
+ \else
+ \pst@killglue%
\addto@pscode{
/ps@Exit false def
xy \@nameuse{beginqp@\psplotstyle}
@@ -1717,12 +1724,12 @@ D\space##1%
ArrowB
2 copy
/yEnd exch def /xEnd exch def
- \ifx\psk@axesstyle\pst@axes
- L % the line with arrows
- \@nameuse{psls@\pslinestyle} % linestyle for the axes
- stroke % draw the main line
- \else
+ \ifx\psk@axesstyle\@none
pop pop % axesstyle = none (only ticks) or frame (already drawn)
+ \else
+ L % the line with arrows
+ \@nameuse{psls@\pslinestyle} % linestyle for the axes
+ stroke % draw the main line
\fi
/yStart exch def
/xStart exch def
@@ -1908,11 +1915,10 @@ D\space##1%
}% end of \pscode
\end@SpecialObj%
% now draw the axes again with the correct linecolor
-% \ifis@yAxis%
+ \ifx\psk@axesstyle\@none\else
\ifPst@yAxis\psline[linecolor=\pslinecolor](0,#2)(0,#4)\fi%
-% \else%
\ifPst@xAxis\psline[linecolor=\pslinecolor](#1,0)(#3,0)\fi%
-% \fi%
+ \fi%
\ignorespaces%
}%
%
@@ -2014,7 +2020,7 @@ D\space##1%
\edef\pst@tempB{\pst@int{\pst@tempA}}
% \divide\pst@cnta\psk@dx\relax% % Number of ticks/labels
\multido{\nA=#3+1}{\pst@tempB}{\uput{\psxlabelsep}[-90]{\pst@xLabelsRot}(\nA,0)%\psxlabelsep)
- {\psPutXLabel{\nA}}}%
+ {\strut\psPutXLabel{\nA}}}%
\fi%
}
% Knows \pst@dimb and \pst@cnta
@@ -2059,7 +2065,7 @@ D\space##1%
\pstFPadd\pst@tempA{0.55}{\pst@tempA} % to prevent rounding errors
\edef\pst@tempB{\pst@int{\pst@tempA}}
% \divide\pst@cnta\psk@dy\relax% % Number of ticks/labels
- \multido{\nA=#3+1}{\pst@tempB}{\uput{\psylabelsep}[180]{\pst@yLabelsRot}(0,\nA){\psPutYLabel{\nA}}}%
+ \multido{\nA=#3+1}{\pst@tempB}{\uput{\psylabelsep}[180]{\pst@yLabelsRot}(0,\nA){\strut\psPutYLabel{\nA}}}%
\fi%
}
% \pst@dima: the width between two labels in pt