29.11.2012 Views

MetaFun - Pragma ADE

MetaFun - Pragma ADE

MetaFun - Pragma ADE

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

path p ; p := (0,0) -- (2cm,3cm) ;<br />

drawpath p ; drawpoints p ;<br />

p := p shortened 1cm ;<br />

drawpath p ; drawpoints p ;<br />

p := p shortened -1cm ;<br />

drawpath p ; drawpoints p ;<br />

Here are a few more drawing helpers. Even if you don't need them you might at some point take<br />

a look at their definitions to see what happens there. First we give a square round corners with<br />

roundedsquare:<br />

path p ; p := roundedsquare(2cm,4cm,.25cm) ;<br />

drawpath p ; drawpoints p ;<br />

Next we draw a square-like circle (or circle-like square) using tensecircle:<br />

path p ; p := tensecircle(2cm,4cm,.25cm) ;<br />

drawpath p ; drawpoints p ;<br />

Some extensions Welcome to MetaPost<br />

55

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!