summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/pstricks-add
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-01-06 23:51:31 +0000
committerKarl Berry <karl@freefriends.org>2013-01-06 23:51:31 +0000
commit96da899a02bb24f0c9fb437f4933cccae75f357b (patch)
treeaa65702f2c099dee05fc358161ab59f3ff6e5afb /Master/texmf-dist/tex/generic/pstricks-add
parenta9ec77a042693fd60429f18a8c4a095105f624e6 (diff)
pstricks-add (6jan13)
git-svn-id: svn://tug.org/texlive/trunk@28750 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/pstricks-add')
-rw-r--r--Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex62
1 files changed, 51 insertions, 11 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 977a11dbfa3..71449f6e718 100644
--- a/Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex
+++ b/Master/texmf-dist/tex/generic/pstricks-add/pstricks-add.tex
@@ -1,4 +1,4 @@
-%% $Id: pstricks-add.tex 710 2012-09-28 07:27:01Z herbert $
+%% $Id: pstricks-add.tex 741 2013-01-01 16:08:58Z herbert $
%%
%%
%% This is file `pstricks-add.tex',
@@ -31,8 +31,8 @@
\ifx\PSTXKeyLoaded\endinput\else \input pst-xkey \fi
\ifx\PSTmathLoaded\endinput\else \input pst-math \fi
%
-\def\fileversion{3.59}
-\def\filedate{2012/09/28}
+\def\fileversion{3.60}
+\def\filedate{2013/01/01}
\message{`pstricks-add' v\fileversion, \filedate\space (dr,hv)}
%
\edef\PstAtCode{\the\catcode`\@} \catcode`\@=11\relax
@@ -218,6 +218,45 @@
exch \tx@UserCoor ){#3}
\end@SpecialObj}
%
+\def\psBrace{\def\pst@par{}\pst@object{psBrace}}
+\def\psBrace@i(#1)(#2){%
+ \begin@ClosedObj
+ \if@star\def\pst@tempC{true }\else\def\pst@tempC{false }\fi
+% \ifx\psk@rot\empty\def\psk@@rot{0}\else\let\psk@@rot\psk@rot\fi
+% \def\psk@rot{Alpha \psk@@rot\space add 90 sub}%
+ \pst@getcoor{#1}\pst@tempA
+ \pst@getcoor{#2}\pst@tempB
+ \addto@pscode{
+ /ifStar \pst@tempC def
+ /radius1 \psk@braceWidthOuter def
+ /radius2 \psk@braceWidthInner def
+ /Alpha \pst@tempA \pst@tempB 3 -1 roll sub 3 1 roll exch sub atan def
+% gsave STV CP T /ps@rot \psk@rot\space def grestore
+ /Length \pst@tempA \pst@tempB Pyth2 def
+ /Left { Length \psk@bracePos\space mul } bind def
+ /Right { Length Left sub } bind def
+ /Width \psk@braceWidth def
+ /pop4 { pop pop pop pop } def
+ [ Alpha cos Alpha sin Alpha sin neg Alpha cos \pst@tempA ] concat
+ 0 0 moveto
+ 0 radius2 neg radius2 radius2 neg radius2 arcto pop4
+ Left radius2 sub radius1 sub 0 rlineto
+ Left radius2 neg Left radius2 radius1 add neg radius1 arcto pop4
+ currentpoint /y@Label ED /x@Label ED
+ Left radius2 neg Left radius1 add radius2 neg radius1 arcto pop4
+ Right radius2 sub radius1 sub 0 rlineto
+ Length radius2 neg Length 0 radius2 arcto pop4
+% 0 Width neg rlineto
+ Length radius2 Width add neg Length radius2 sub radius2 Width add neg radius2 arcto pop4
+ Right radius2 sub radius1 sub neg 0 rlineto
+ Left radius1 add Width radius1 add radius2 add neg radius1 90 180 arc
+ Left radius1 sub Width radius1 add radius2 add neg radius1 0 90 arc
+ Left radius2 sub radius1 sub neg 0 rlineto
+ radius2 Width neg radius2 270 180 arcn
+ 0 0 lineto }
+ \end@ClosedObj
+ \ignorespaces}
+%
\newdimen\psparallelogramsep
\define@key[psset]{pstricks-add}{parallelogramsep}[3mm]{\pssetlength\psparallelogramsep{#1}}
\psset[pstricks-add]{parallelogramsep=3mm}
@@ -1405,12 +1444,12 @@ a add
\def\psplotTangent@i*{\@ifnextchar[{\psplotTangent@ii}{\psplotTangent@ii[]}}
\def\psplotTangent@ii[#1]#2#3#4{%
\pst@killglue%
- \expandafter\psplotTangent@x#3,,\@nil\relax
+ \expandafter\psplotTangent@x#3,,\@nil\relax%
\begingroup%
- \ifx\relax#1\relax\else\psset{linestyle=solid,#1}\fi
+ \ifx\relax#1\relax\else\psset{linestyle=solid,#1}\fi%
\ifx\psk@Derive\@empty\ifPst@algebraic\def\psk@Derive{NOT@EMPTY}\fi\fi%%dr 0606 hv 1003
- \pst@addarrowdef
- \addto@pscode{
+ \pst@addarrowdef%
+ \addto@pscode{%
/F@pstplot \ifPst@algebraic (#4) tx@addDict begin AlgParser end cvx \else { #4 } \fi def % define function
\ifx\psk@Derive\@empty\else
\ifx\psk@Derive\@NOTEMPTY\else%%dr 0606
@@ -1425,11 +1464,11 @@ a add
{ /y ED /x ED /@parametric true def } % if yes, then we have 2 values%%dr 0606
{ \ifPst@polarplot x \ifPst@algebraic RadtoDeg \fi PtoC /y ED /x ED \else /y ED \fi } ifelse
cleartomark
- \ifx\psk@Derive\@NOTEMPTY%%begin dr 0606
+ \ifx\psk@Derive\@NOTEMPTY %%begin dr 0606
%% algebraic we can use the derivative machine
/FDer@pstplot (#4) @parametric { (t) } { (x) } ifelse
tx@Derive begin Derive end tx@addDict begin AlgParser end cvx def
- \fi%%end dr 0606
+ \fi %%end dr 0606
x \pst@number\psxunit mul y \pst@number\psyunit mul
translate % define the temporary origin
% now we calculate the slope of the tangent
@@ -1472,7 +1511,8 @@ a add
y \pst@number\psyunit mul x \pst@number\psxunit mul Atan \ifPST@Tnormal 90 add \fi
% y ATAN1 % we have the slope angle of the tangent. ATAN is defined int the pstricks.pro, patch 6
\fi
- cvi 180 mod dup 90 gt { 180 sub } if % -90 <= angle <= 90
+ dup % to prevent rounding errors use original value
+ cvi 180 mod 90 gt { 180 sub } if % -90 <= angle <= 90
rotate % rotate, depending to the origin
/Lineto /lineto load def % the pro file needs /Lineto
\pst@cp % kill the currentpoint, if any
@@ -1505,7 +1545,7 @@ a add
grestore
\fi
}%
- \use@pscode
+ \use@pscode%
\endgroup%
\@starfalse%
\ignorespaces}