summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/metapost/base/source/figs.mp
blob: e71bf2a9f7f79e8d4fa7168fddb78290f430c207 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
% $Id: figs.mp,v 1.2 2004/09/19 19:10:08 karl Exp $
% Examples for MetaPost doc, by John Hobby.  Public domain.

input boxes
beginfig(1);
pair shadowshift; shadowshift=(1,-1)*bp;

def drawshadowed(text t) =
  forsuffixes $=t:
    fill bpath$ shifted shadowshift;
    unfill bpath$;
    drawboxed($);
  endfor
enddef;

boxit.a(btex \s8A\s+2 \(lh a etex);
circleit.b(btex $e sup {i omega t}$ etex rotated 20);
b.w - a.e = (10,0)*bp;
drawshadowed(a,b);
draw a.e..b.w;

draw bbox currentpicture dashed evenly;
endfig;

end