diff options
author | Karl Berry <karl@freefriends.org> | 2006-12-26 23:19:21 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2006-12-26 23:19:21 +0000 |
commit | 5c2f658ac69482a0bac00f4b189ac870a0d621b9 (patch) | |
tree | 108610a32f8d5b881772d4bda4da03d4f28cc3ac /Master/texmf-dist/tex/generic | |
parent | e0a3cd18307ee9a22077133293f921e9b7689316 (diff) |
pstricks-add update
git-svn-id: svn://tug.org/texlive/trunk@2954 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic')
-rw-r--r-- | Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex | 54 |
1 files changed, 32 insertions, 22 deletions
diff --git a/Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex b/Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex index ebb26370977..be90c409c70 100644 --- a/Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex +++ b/Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex @@ -26,8 +26,8 @@ \ifx\MultidoLoaded\endinput\else \input multido \fi \ifx\PSTXKeyLoaded\endinput\else \input pst-xkey \fi % -\def\fileversion{2.81} -\def\filedate{2006/10/03} +\def\fileversion{2.82} +\def\filedate{2006/11/22} \message{`pstricks-add' v\fileversion, \filedate\space (dr,hv)} % \edef\PstAtCode{\the\catcode`\@} \catcode`\@=11\relax @@ -153,6 +153,13 @@ \endgroup% } % +\define@boolkey[psset]{pstricks-add}[Pst@]{angleCheck}[true]{} +\psset[pstricks-add]{angleCheck=true} +% +\def\pst@getangle#1#2{% + \ifPst@angleCheck\pst@@getangle{#1}\else\def\pst@angle{#1 }\fi% + \let#2\pst@angle} +% %--------------------------------------- small stuff ------------------------------- % transalpha needs a run through latex -> dvips -> ps2pdf14(!) % and view with Acrobat >= 5.0 @@ -548,7 +555,8 @@ \ifx\psk@arrowA\arrowType@H % do we have a Hook arrow at the beginning? \pst@number\pshooklength % yes \else - \psk@arrowsize\space CLW mul add dup \psk@arrowlength\space mul exch \psk@arrowinset mul neg add + \psk@arrowsize\space CLW mul add dup \psk@arrowlength\space mul + exch \psk@arrowinset mul neg add \fi /arrowlength exch def 4 copy % copy all four values for the arrow line @@ -566,11 +574,11 @@ \psk@ArrowInsidePos\space 1 gt { /Alpha y2 y1 sub x2 x1 sub Atan def /ArrowPos \psk@ArrowInsideOffset\space def - /Length x2 x1 sub y2 y1 sub Pyth def + /ALength x2 x1 sub y2 y1 sub Pyth def /dArrowPos \psk@ArrowInsidePos\space abs def { /ArrowPos ArrowPos dArrowPos add def - ArrowPos Length gt { exit } if + ArrowPos ALength gt { exit } if x1 Alpha cos ArrowPos mul add y1 Alpha sin ArrowPos mul add ArrowInside @@ -619,11 +627,11 @@ \psk@ArrowInsidePos\space 1 gt { /Alpha y12 y11 sub x12 x11 sub atan def /ArrowPos \psk@ArrowInsideOffset\space def - /Length x12 x11 sub y12 y11 sub Pyth def + /ALength x12 x11 sub y12 y11 sub Pyth def /dArrowPos \psk@ArrowInsidePos\space abs def { /ArrowPos ArrowPos dArrowPos add def - ArrowPos Length gt { exit } if + ArrowPos ALength gt { exit } if x11 Alpha cos ArrowPos mul add y11 Alpha sin ArrowPos mul add currentdict /ArrowInside known { ArrowInside } if @@ -744,11 +752,11 @@ \psk@ArrowInsidePos\space 1 gt { /Alpha y2 y1 sub x2 x1 sub atan def /ArrowPos \psk@ArrowInsideOffset\space def - /Length x2 x1 sub y2 y1 sub Pyth def + /ALength x2 x1 sub y2 y1 sub Pyth def /dArrowPos \psk@ArrowInsidePos\space abs def {% /ArrowPos ArrowPos dArrowPos add def - ArrowPos Length gt { exit } if + ArrowPos ALength gt { exit } if x1 Alpha cos ArrowPos mul add y1 Alpha sin ArrowPos mul add ArrowInside @@ -2649,7 +2657,8 @@ dup 4 -1 roll mul 2 index 2 add 1 roll } repeat pop pop } def - /divvect { ylength exch 1 index { dup 4 -1 roll exch div 2 index 2 add 1 roll } repeat pop pop } def + /divvect { ylength exch 1 index { dup 4 -1 roll exch div 2 + index 2 add 1 roll } repeat pop pop } def /k0 0 def /k1 0 def /k2 0 def /k3 0 def \ifPst@algebraic /F@pstplot (#4) tx@addDict begin AlgParser end cvx def \fi /Func { @@ -2659,7 +2668,8 @@ \ifPst@buildvector\else ylength array astore \fi \fi } def - \ifx\psk@method\@adams /F1 0 def /F2 0 def /F3 0 def /F4 0 def /F5 0 def /F6 0 def /INIT 1 def \fi + \ifx\psk@method\@adams /F1 0 def /F2 0 def /F3 0 def /F4 0 def + /F5 0 def /F6 0 def /INIT 1 def \fi \ifx\psk@method\@empty\else \ifx\psk@method\@varrkiv %% RUNGE-KUTTA method with var step algorithm /VarStep false def /VarStepRatio 1 def @@ -2699,7 +2709,8 @@ %{ \psk@varsteptol\space div .1 lt { /VarStep true def } if pop exit } if %pop /dx dx 4 div def exch /y exch def } loop { .001 div dup .1 lt - { dup 1e-6 lt { pop 3 } { log neg } ifelse /VarStepRatio exch def /VarStep true def } + { dup 1e-6 lt { pop 3 } { log neg } ifelse + /VarStepRatio exch def /VarStep true def } { pop } ifelse pop exit } if pop /dx dx 4 div def exch /y exch def } loop } def @@ -2759,15 +2770,15 @@ \ifx\psk@whichabs\@empty x \else y \psk@whichabs\space get \fi \else \psk@plotfuncx\space \fi \pst@number\psxunit mul y - \ifx\psk@method\@empty %% EULER method + \ifx\psk@method\@empty %% EULER method /y Func { dx mul } forall y aload pop addvect ylength array astore def \else% - \ifx\psk@method\@varrkiv %% RUNGE-KUTTA method + \ifx\psk@method\@varrkiv %% RUNGE-KUTTA method VARRK - \else\ifx\psk@method\@rkiv %% RUNGE-KUTTA method + \else\ifx\psk@method\@rkiv %% RUNGE-KUTTA method RK \else - /F1 F2 def /F2 F3 def /F3 F4 def /F4 %% ADAMS method + /F1 F2 def /F2 F3 def /F3 F4 def /F4 %% ADAMS method \ifcase\psk@adamsorder\or\or\or\or %% ORDRE 4 Func def @@ -2795,9 +2806,8 @@ \if@pst\psplot@ii\else\psplot@iii\fi \endgroup% \ignorespaces% -} -% -% +}% +%% \def\psGTriangle{\pst@object{psGTriangle}} \def\psGTriangle@i(#1)(#2)(#3)#4#5#6{{% \def\solid@star{}% @@ -2819,11 +2829,11 @@ [ \pst@colorB ] aload length 1 eq { dup dup } if 3 array astore [ \pst@colorA ] aload length 1 eq { dup dup } if 3 array astore tx@addDict begin GTriangle end % PS part - }% - \if@star\pspolygon(#1)(#2)(#3)\fi% draw borderline + } + \if@star\pspolygon(#1)(#2)(#3)\fi \def\pst@linetype{2}% \end@ClosedObj% -}} +}\ignorespaces} % \define@key[psset]{pstricks-add}{dicescale}{\def\psk@dicescale{#1}} \def\psdice{\pst@object{psdice}} |