MOON
Server: Apache
System: Linux server30c.hostingraja.org 3.10.0-962.3.2.lve1.5.63.el7.x86_64 #1 SMP Fri Oct 8 12:03:35 UTC 2021 x86_64
User: jibhires (1887)
PHP: 8.1.30
Disabled: show_source, system, shell_exec, passthru, exec, popen, proc_open, allow_url_fopen, symlink, escapeshellcmd, pcntl_exec
Upload Files
File: //opt/alt/python27/share/doc/alt-python27-pycairo-1.8.6/examples/cairo_snippets/snippets/arc.py
xc = 0.5
yc = 0.5
radius = 0.4
angle1 = 45.0  * (M_PI/180.0)  #/* angles are specified */
angle2 = 180.0 * (M_PI/180.0)  #/* in radians           */

snippet_normalize (cr, width, height)

cr.arc (xc, yc, radius, angle1, angle2)
cr.stroke ()

#/* draw helping lines */
cr.set_source_rgba (1,0.2,0.2,0.6)
cr.arc (xc, yc, 0.05, 0, 2*M_PI)
cr.fill ()
cr.set_line_width (0.03)
cr.arc (xc, yc, radius, angle1, angle1)
cr.line_to (xc, yc)
cr.arc (xc, yc, radius, angle2, angle2)
cr.line_to (xc, yc)
cr.stroke ()