diff options
author | Karl Berry <karl@freefriends.org> | 2009-05-16 00:19:13 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-05-16 00:19:13 +0000 |
commit | bab45528d65eaafe68a705dbb2a57075c7b7cbd8 (patch) | |
tree | 10b4ae2b5195c8dede153ab89359ec00f55f325f /Build/source/utils/asymptote/doc/flowchartdemo.asy | |
parent | 8643d90372e9c31e0f461c15c596b60a545bd7d3 (diff) |
asymptote 1.72 sources (not integrated into build yet)
git-svn-id: svn://tug.org/texlive/trunk@13110 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/utils/asymptote/doc/flowchartdemo.asy')
-rw-r--r-- | Build/source/utils/asymptote/doc/flowchartdemo.asy | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/Build/source/utils/asymptote/doc/flowchartdemo.asy b/Build/source/utils/asymptote/doc/flowchartdemo.asy new file mode 100644 index 00000000000..74940d92f34 --- /dev/null +++ b/Build/source/utils/asymptote/doc/flowchartdemo.asy @@ -0,0 +1,30 @@ +size(0,300); + +import flowchart; + +block block1=rectangle(Label("Example",magenta), + pack(Label("Start:",heavygreen),"",Label("$A:=0$",blue), + "$B:=1$"),(-0.5,3),palegreen,paleblue,red); +block block2=diamond(Label("Choice?",blue),(0,2),palegreen,red); +block block3=roundrectangle("Do something",(-1,1)); +block block4=bevel("Don't do something",(1,1)); +block block5=circle("End",(0,0)); + +draw(block1); +draw(block2); +draw(block3); +draw(block4); +draw(block5); + +add(new void(picture pic, transform t) { + draw(pic,path(new pair[]{block1.right(t),block2.top(t)},Horizontal), + Arrow,PenMargin); + draw(pic,Label("Yes",0.5),path(new pair[]{block2.left(t),block3.top(t)}, + Horizontal),Arrow,PenMargin); + draw(pic,Label("No",0.5,N),path(new pair[]{block2.right(t),block4.top(t)}, + Horizontal),Arrow,PenMargin); + draw(pic,path(new pair[]{block3.bottom(t),block5.left(t)},Vertical), + Arrow,PenMargin); + draw(pic,path(new pair[]{block4.bottom(t),block5.right(t)},Vertical), + Arrow,PenMargin); + }); |