AddArcToPath -- add elliptical arc to path (V5.0)
AddArcToPath(id, xc, yc, ra, rb, start, end[, clockwise])
This function adds an elliptical arc to the path specified in the first argument. You have to provide the center point of the arc in the xc and yc arguments. The arc's radii have to be passed in ra and rb, and the start and end angles have to be specified in the start and end arguments respectively. All angles must be specified in degrees. If you want to have a closed ellipse, the start argument needs to be 0 and the end argument needs to be 360. Using the AddEllipseToPath() command is of course easier in this case. The optional argument clockwise can be used to specify whether or not the elliptical arc shall be drawn in clockwise direction. This tag defaults to True which means clockwise drawing. If you set it to False, AddArcToPath() will connect the angles in anti- clockwise direction.

Note that AddArcToPath() doesn't add a center point vertex. If you want the start and end angles of the arc to be connected with the center point, you need to do this manually by calling MoveTo() before AddArcToPath() and LineTo() afterwards.

Also note that AddArcToPath() only starts a new subpath in case there is no active subpath. Otherwise it will simply connect its vertices to the currently active subpath. If you don't want this, you'll have to manually open a new subpath before calling AddArcToPath(). Furthermore, AddArcToPath() also won't close the active subpath when it is finished.

identifier of path to which the elliptical arc should be added
x center point of arc
y center point of arc
arc radius on the x axis
arc radius on the y axis
start angle in degrees (must be positive)
end angle in degrees (must be positive)
optional: whether or not the angles should be connected in clockwise direction (defaults to True which means clockwise)

Show TOC