summaryrefslogtreecommitdiff
path: root/systems/doc/metapost/source-tutorial/fill.mp
blob: d4c52c4e9eb749877ebe3899870b43de1a48c46f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
if scantokens(mpversion) > 1.005:
  outputtemplate :=
else:
  filenametemplate
fi
"%j.mps";

beginfig(0);
	% Set unit size to 72bp = 1in
	u:=72;
	
	% Define path
	path p;
	p:=(0,0){right}..{dir 45}(3*u/4,u/4){dir 45}..{up}(u,u)--cycle;
	
	% Fill the path
	fill p withcolor red;

	% Draw the path
	draw p;
endfig;
end