summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/lapdf/drawing.tex
blob: 49ca0390718554a05524a45cbd82b16108259ccd (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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
\input preamble

% --------------------------------------------------------------------------
\begin{document}
\unitlength0.93cm

\begin{center}
{\Huge \bf{Drawing with \Lapdf}}
\bigskip

\begin{lapdf}(12,12)(-6,-6)
 \Setwidth(0.01)
 \Rect(-6,-6,12,12)
 \Line(-6,0)(+6,0) \Stroke
 \Line(0,-6)(0,+6) \Stroke
 \Dash(2)
 \Line(-6,-6)(+6,+6) \Stroke
 \Dash(0)
 \Gsave
  \Dash(1)
  \Moveto(-6,0)
  \Lineto(-2,6)
  \Lineto(2,-6)
  \Lineto(6,0) \Stroke
 \Grestore
 \Setwidth(0.02)
 \Red
 \Curve(64)(-6,0)(-2,6)(2,-6)(6,0) \Closepath \Gfill(0.9)
 \Cyan
 \Dash(2)
 \Rcurve(96)(-5,0,3)(0,8,1)(5,0,3) \Stroke
 \Rcurve(96)(-5,0,3)(0,8,-1)(5,0,3) \Stroke
 \Dash(0)
 \Green
 \Rcurve(96)(-5,0,1)(0,8,1)(5,0,1) \Stroke
 \Yellow
 \Rcurve(96)(-5,0,1)(0,8,3)(5,0,1) \Stroke
 \Rcurve(96)(-5,0,1)(0,8,0)(5,0,1) \Stroke
 \Magenta
 \Circle(64)(0,0,5) \Stroke
 \Setcol(0.3,0.3,0.3)
 \Curve(64)(-5,0)(0,-8)(5,0) \Stroke
\end{lapdf}
\bigskip

\begin{lapdf}(12,12)(-6,-6)
 \Setwidth(0.02)
 \Setjoin(1)
 \Red
 \Rotate(45)
 \Scale(1,0.8)
 \Circle(64)(0,0,1.86)
 \Circle(64)(0,0,4)
 \Circle(64)(0,0,6)
 \Fill(1,1,0)
 \Polygon(0,6)(3.527,-4.854)(-5.706,1.854)(5.706,1.854)(-3.527,-4.854)(0,6)
 \Fill(0,1,1)
\end{lapdf}
\end{center}
\end{document}