summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/dvips/pstricks
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-08-14 23:23:35 +0000
committerKarl Berry <karl@freefriends.org>2012-08-14 23:23:35 +0000
commitc2aec9146006572a51a8d425ee7e702cd35f3e03 (patch)
treed9632cec255b8e1f0c0a64f55574303917e8b8b3 /Master/texmf-dist/dvips/pstricks
parent9ef4d43a194168faca909a9261e94c3ba72e85af (diff)
pstricks (14aug12)
git-svn-id: svn://tug.org/texlive/trunk@27404 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/dvips/pstricks')
-rw-r--r--Master/texmf-dist/dvips/pstricks/pstricks.pro76
1 files changed, 59 insertions, 17 deletions
diff --git a/Master/texmf-dist/dvips/pstricks/pstricks.pro b/Master/texmf-dist/dvips/pstricks/pstricks.pro
index 77519c55514..c00d0413c19 100644
--- a/Master/texmf-dist/dvips/pstricks/pstricks.pro
+++ b/Master/texmf-dist/dvips/pstricks/pstricks.pro
@@ -1,7 +1,7 @@
-% $Id: pstricks.pro 647 2012-02-12 15:03:40Z herbert $
+% $Id: pstricks.pro 700 2012-08-13 21:04:25Z herbert $
%
%% PostScript prologue for pstricks.tex.
-%% Version 1.12, 2012/02/12
+%% Version 1.14, 2012/08/13
%%
%% This program can be redistributed and/or modified under the terms
%% of the LaTeX Project Public License Distributed from CTAN archives
@@ -189,7 +189,7 @@ tx@Dict begin
/y2 ED
a Div ceiling cvi /x2 ED /y1 ED
a Div cvi /x1 ED /y2 y2 y1 sub def
- clip
+ clipType % must be defined in pstricks.tex: clip -- eoclip
newpath
2 setlinecap
systemdict
@@ -219,7 +219,7 @@ tx@Dict begin
/y2 ED /x2 ED /y1 ED /x1 ED
y2 y1 sub a div 2 add cvi /Ny ED
x2 x1 sub a div 2 add cvi /Nx ED
- clip
+ clipType % must be defined in pstricks.tex: clip -- eoclip
newpath
/yA y1 dotRadius add CLW add def
/xA0 x1 dotRadius add CLW add def
@@ -238,29 +238,71 @@ tx@Dict begin
} def
%
/PenroseFill {% on stack: scaling factor
- dup dup scale
- 1 exch div round /penroseFactor ED
- a 0 dtransform round exch round exch
- 2 copy idtransform
- exch Atan rotate
- idtransform pop /a ED
- .25 .25 itransform pathbbox
- /y2 ED
- a Div ceiling cvi /x2 ED /y1 ED
- a Div cvi /x1 ED /y2 y2 y1 sub def
+ /Scale ED
+% 1 exch div round /penroseFactor ED
+% a 0 dtransform round exch round exch
+% 2 copy idtransform
+% exch Atan rotate
+% idtransform pop /a ED
+% .25 .25 itransform pathbbox
+% /y2 ED
+% a Div ceiling cvi /x2 ED /y1 ED
+% a Div cvi /x1 ED /y2 y2 y1 sub def
clip
newpath
- systemdict
- /setstrokeadjust known { true setstrokeadjust } if
+gsave
+ 220 150 translate
+ Scale dup scale
+ systemdict /setstrokeadjust known { true setstrokeadjust } if
/I/S/L/W/G/+/Z/F/E/D[/def/exch/for{E D}/add{s E get mul}
{ Z -36.2001 1 33 }{25 E S rlineto}{/q Z dup q G E q 1 + G}{Z 2 2}]{cvx def}forall
[0 72 1008 {dup sin E cos }F ]1 setlinejoin/s W{/a W{/b I 10{/i I 4{/m I moveto
i m +/j I 10{/l Z b m l + G a l G sub s m get div .2 + floor .3 + 25
mul j l + S rmoveto}F i L j L stroke }F}F}F}F
grestore
- pop pop
+% pop pop
} def
%
+/PenroseFillA {% on stack: scaling factor, border color, kite color, dart color
+ /Scale ED
+ Scale dup scale
+ /border_colour ED
+ /kite_colour ED
+ /dart_colour ED
+ clip
+
+ newpath
+ gsave
+ 100 100 translate
+ 6
+ Scale 1 lt { 1 Scale dup add div mul cvi } if %%%% Number of iterations
+ 10 %%%% Long side length in millimeters
+ /border_width { L 0.06 mul }def %%%% Choose the scalefactor for the borders
+ /L exch 25.4 div 72 mul def %%%% Conversion: mm -> inches -> points
+ /f{-1 5 sqrt add 2 div}bind def %%%% The reciprocal of the golden ratio
+ /l{L f mul}bind def %%%% Short side length l = L*f
+ /Ll{L l add}bind def %%%% Ll = L + l
+ /c{36 cos L mul}bind def %%%% c = L*cos(36)
+ /s{36 sin L mul}bind def %%%% s = L*sin(36)
+ /draw_tile { 0 0 moveto c s lineto 0 lineto gsave closepath gsave fill grestore
+ 0 setlinewidth stroke grestore border_colour stroke } bind def
+ /half_kite { dup dup 0 gt{ 1 sub gsave f f neg scale -36 rotate half_dart
+ Ll 0 translate 144 rotate kite grestore }
+ { kite_colour L draw_tile }ifelse
+ pop } bind def
+ /half_dart { dup dup 0 gt{ 1 sub gsave f f scale half_kite
+ -144 rotate Ll neg 0 translate half_dart grestore }
+ { dart_colour l draw_tile }ifelse
+ pop } bind def
+ /kite{ gsave half_kite 1 -1 scale half_kite grestore }bind def
+ border_width setlinewidth 1 setlinejoin 1 setlinecap
+% 450 0 translate
+ dup f exch neg exp dup scale
+ 5 {kite 72 rotate } repeat stroke
+ grestore
+} def
+%
+%
/TruchetFill { % on stack: scaling factor
10 dict begin
dup dup scale