[cairo] [PATCH 4/7] skia: Add section definitions and code docs for skia backend

Bryce W. Harrington b.harrington at samsung.com
Wed Feb 26 14:29:41 PST 2014


This fixes several distcheck errors regarding missing code docs.

Signed-off-by: Bryce Harrington <b.harrington at samsung.com>
---
 doc/public/cairo-sections.txt |    5 +++--
 src/cairo-skia-surface.cpp    |   21 +++++++++++++++++++++
 src/skia/cairo-skia-private.h |   19 +++++++++++++++++++
 3 files changed, 43 insertions(+), 2 deletions(-)

diff --git a/doc/public/cairo-sections.txt b/doc/public/cairo-sections.txt
index 3a78f36..4beaa0a 100644
--- a/doc/public/cairo-sections.txt
+++ b/doc/public/cairo-sections.txt
@@ -115,11 +115,12 @@ cairo_recording_surface_get_extents
 
 <SECTION>
 <FILE>cairo-skia</FILE>
-cairo_skia_context
 cairo_skia_context_t
-cairo_skia_surface
 cairo_skia_surface_t
 format_to_sk_config
+<SUBSECTION Private>
+cairo_skia_context
+cairo_skia_surface
 </SECTION>
 
 <SECTION>
diff --git a/src/cairo-skia-surface.cpp b/src/cairo-skia-surface.cpp
index bf6b14a..59b0c67 100644
--- a/src/cairo-skia-surface.cpp
+++ b/src/cairo-skia-surface.cpp
@@ -51,6 +51,27 @@
 #include <SkGradientShader.h>
 #include <SkDashPathEffect.h>
 
+/**
+ * SECTION:cairo-skia
+ * @Title: Skia Surfaces
+ * @Short_Description: Rendering to Skia surfaces
+ * @See_Also: #cairo_surface_t
+ *
+ * Originally written by Vladimir Vukicevic to investigate using Skia for
+ * Mozilla, it provides a nice integration with a rather interesting code
+ * base. By hooking Skia underneath Cairo it allows us to directly compare
+ * code paths... which is interesting.
+ **/
+
+/**
+ * CAIRO_HAS_SKIA_SURFACE:
+ *
+ * Defined if the Skia surface backend is available.
+ * This macro can be used to conditionally compile backend-specific code.
+ *
+ * Since: 1.12
+ **/
+
 #if (CAIRO_FIXED_BITS == 32) && (CAIRO_FIXED_FRAC_BITS == 16) && defined(SK_SCALAR_IS_FIXED)
 # define CAIRO_FIXED_TO_SK_SCALAR(x)  (x)
 #elif defined(SK_SCALAR_IS_FIXED)
diff --git a/src/skia/cairo-skia-private.h b/src/skia/cairo-skia-private.h
index cbd8c88..79aa2eb 100644
--- a/src/skia/cairo-skia-private.h
+++ b/src/skia/cairo-skia-private.h
@@ -44,7 +44,26 @@
 #include <SkPaint.h>
 #include <SkPath.h>
 
+/**
+ * cairo_skia_context_t:
+ *
+ * A #cairo_skia_context_t includes handles to Skia's canvas,
+ * paint, and path objects along with the Cairo source surfaces
+ * and matrix, and the original and target #cairo_skia_surface_t
+ * objects.
+ *
+ * Since: 1.12
+ **/
 typedef struct _cairo_skia_context cairo_skia_context_t;
+
+/**
+ * cairo_skia_surface_t:
+ *
+ * A #cairo_skia_surface_t is a container for the underlying
+ * #SkBitmap and the corresponding Cairo image surface.
+ *
+ * Since: 1.12
+ **/
 typedef struct _cairo_skia_surface cairo_skia_surface_t;
 
 struct _cairo_skia_context {
-- 
1.7.9.5


More information about the cairo mailing list