[cairo] [PATCH] Compilation fixes: Add prototype for cairo_surface_get_device_offset.

Carl Worth cworth at cworth.org
Tue Feb 28 15:38:32 PST 2006


Also track rename of values for cairo_pattern_type_t.

---

 Vladimir,

 Your device-offset-rework branch wasn't compiling for me without this.

 You should be able to just pipe this message to git-am and have the
 right thing happen.

 -Carl

 src/cairo-surface.c |    4 ++--
 src/cairo.h         |    5 +++++
 2 files changed, 7 insertions(+), 2 deletions(-)

ee23d4d824664046223705c0bc54790a2171a63d
diff --git a/src/cairo-surface.c b/src/cairo-surface.c
index 9b1a2ad..1c148ec 100644
--- a/src/cairo-surface.c
+++ b/src/cairo-surface.c
@@ -912,13 +912,13 @@ _cairo_surface_composite (cairo_operator
         int backend_mask_x = mask_x;
         int backend_mask_y = mask_y;
 
-        if (src->type == CAIRO_PATTERN_SURFACE) {
+        if (src->type == CAIRO_PATTERN_TYPE_SURFACE) {
             cairo_surface_t *src_surface = ((cairo_surface_pattern_t*)src)->surface;
             backend_src_x = BACKEND_X(src_surface, src_x);
             backend_src_y = BACKEND_Y(src_surface, src_y);
         }
 
-        if (mask && mask->type == CAIRO_PATTERN_SURFACE) {
+        if (mask && mask->type == CAIRO_PATTERN_TYPE_SURFACE) {
             cairo_surface_t *mask_surface = ((cairo_surface_pattern_t*)mask)->surface;
             backend_mask_x = BACKEND_X(mask_surface, mask_x);
             backend_mask_y = BACKEND_Y(mask_surface, mask_y);
diff --git a/src/cairo.h b/src/cairo.h
index 5b38d18..e32be61 100644
--- a/src/cairo.h
+++ b/src/cairo.h
@@ -1295,6 +1295,11 @@ cairo_surface_set_device_offset (cairo_s
 				 double           x_offset,
 				 double           y_offset);
 
+cairo_public void
+cairo_surface_get_device_offset (cairo_surface_t *surface,
+				 double          *x_offset,
+				 double          *y_offset);
+
 /* Image-surface functions */
 
 /**
-- 
1.2.3.g2656-dirty

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/cairo/attachments/20060228/0b3ebcd6/attachment.pgp


More information about the cairo mailing list