[cairo] patches for cairo_arc and cairo_pattern_type_t documentation

Jonathan Watt jwatt at jwatt.org
Sat Sep 30 10:54:41 PDT 2006


I had some questions after reading the manual's description of cairo_arc which 
Carl kindly cleared up for me. I've attached a suggested patch for the cairo_arc 
documentation, and an additional patch for a typo in the description of 


-------------- next part --------------
diff --git a/src/cairo.c b/src/cairo.c
index cda9b0e..ad3eba8 100644
--- a/src/cairo.c
+++ b/src/cairo.c
@@ -1405,7 +1405,14 @@ slim_hidden_def (cairo_curve_to);
  * If there is a current point, an initial line segment will be added
  * to the path to connect the current point to the beginning of the
- * arc.
+ * arc. To prevent an initial line segment from being added to the path,
+ * preceed the call to cairo_arc with a call to cairo_new_sub_path to
+ * remove the current point. With no current point an initial move_to
+ * will be added to the path instead of the line_to.
+ *
+ * Calls to cairo_arc insert as many curve_to path segments as
+ * necessary to approximate the arc to the tolerance specified by
+ * cairo_set_tolerance.
  * Angles are measured in radians. An angle of 0.0 is in the direction
  * of the positive X axis (in user space). An angle of %M_PI/2.0 radians
-------------- next part --------------
diff --git a/src/cairo.h b/src/cairo.h
index 7a3b653..c3d4eb6 100644
--- a/src/cairo.h
+++ b/src/cairo.h
@@ -1493,7 +1493,7 @@ cairo_pattern_status (cairo_pattern_t *p
  * cairo_pattern_type_t
  * @CAIRO_PATTERN_TYPE_SOLID: The pattern is a solid (uniform)
  * color. It may be opaque or translucent.
- * @CAIRO_PATTERN_TYPE_SURFACE: The pattern is a based on a surface (an image).
+ * @CAIRO_PATTERN_TYPE_SURFACE: The pattern is based on a surface (an image).
  * @CAIRO_PATTERN_TYPE_LINEAR: The pattern is a linear gradient.
  * @CAIRO_PATTERN_TYPE_RADIAL: The pattern is a radial gradient.

More information about the cairo mailing list