summaryrefslogtreecommitdiff
path: root/src/cairo-surface.c
diff options
context:
space:
mode:
authorCarl Worth <cworth@cworth.org>2006-04-14 17:29:19 -0700
committerCarl Worth <cworth@cworth.org>2006-04-14 17:29:19 -0700
commitdb111197ac436ace0c3aceb88a6d7c1abca03b02 (patch)
tree72d021f56abc073c0f7ddb87bff6ed944f5e8a8d /src/cairo-surface.c
parente890bfd2bf04a973ead9f5d53d06728165faa28d (diff)
Fix _cairo_surface_is_opaque to return FALSE not TRUE for non-image surfaces.
Diffstat (limited to 'src/cairo-surface.c')
-rw-r--r--src/cairo-surface.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/cairo-surface.c b/src/cairo-surface.c
index 5af49da5d..9a15db4f6 100644
--- a/src/cairo-surface.c
+++ b/src/cairo-surface.c
@@ -1710,6 +1710,14 @@ _format_is_opaque (cairo_format_t format)
return FALSE;
}
+/* XXX: This function is funny in a couple of ways. First it seems to
+ * be computing something like "not translucent" rather than "opaque"
+ * since it returns TRUE for an A1 image surface. Second, it just
+ * gives up on anything other than an image surface.
+ *
+ * I imagine something that might be more useful here (or in addition)
+ * would be cairo_surface_get_content.
+ */
cairo_bool_t
_cairo_surface_is_opaque (const cairo_surface_t *surface)
{
@@ -1719,5 +1727,5 @@ _cairo_surface_is_opaque (const cairo_surface_t *surface)
return _format_is_opaque (image_surface->format);
}
- return TRUE;
+ return FALSE;
}