6 p
= path
.path(path
.arc(0,0, R
, 0,270)) + path
.line(0,-R
, R
,-R
)
7 label
= (r
"\PyX{} is fun. " * 4)[:-1] # chop off last space
9 c
.draw(p
, [deco
.stroked([color
.rgb
.blue
]), deco
.curvedtext(label
)])
10 c
.draw(p
, [trafo
.translate(2.5*R
,0), deco
.stroked([color
.rgb
.blue
]), deco
.curvedtext(label
,textattrs
=[text
.halign
.right
],relarclenpos
=1)])
11 c
.draw(p
.reversed(), [trafo
.translate(0, -2.5*R
), deco
.stroked([color
.rgb
.blue
]), deco
.curvedtext(label
,textattrs
=[text
.halign
.right
],relarclenpos
=1)])
12 c
.draw(p
.reversed(), [trafo
.translate(2.5*R
, -2.5*R
), deco
.stroked([color
.rgb
.blue
]), deco
.curvedtext(label
)])
14 c
.writeEPSfile("textalongpath")
15 c
.writePDFfile("textalongpath")