remove none-existing reference
[PyX.git] / manual / radii2.py
blob157de1a1482b02afd68da77e2206249e4bf60cf3
1 from pyx import *
2 c = canvas.canvas()
4 circle = path.circle(0, 0, 2)
5 line = path.line(-3, 1, 3, 2)
7 isects_circle, isects_line = circle.intersect(line)
9 arc1, arc2 = circle.split(isects_circle)
11 arc = arc1.arclen()<arc2.arclen() and arc1 or arc2
13 isects_line.sort()
14 line1, line2, line3 = line.split(isects_line)
16 segment = line2 << arc
18 c.fill(segment, [color.grey(0.5)])
20 c.stroke(circle, [style.linewidth.Thick])
21 c.stroke(line, [style.linewidth.Thick])
23 for isect in isects_circle:
24 c.stroke(path.line(0, 0, *circle.at(isect)))
26 c.writePDFfile()