summaryrefslogtreecommitdiff
path: root/test/device-offset.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2007-12-20 18:15:48 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2007-12-20 21:21:32 +0000
commit3bf06c336629d9a485fdb150058897e5a6a30b45 (patch)
tree979bd85b70707deb4e1b88ed8406571ba9a53b01 /test/device-offset.c
parent643834e7aa3e90678276453439017359ef942c9e (diff)
downloadcairo-3bf06c336629d9a485fdb150058897e5a6a30b45.tar.gz
[test/*] Create new surfaces using the group target.
cairo_get_target() returns the original surface passed to cairo_create(), and not the current destination as required when testing drawing to the same surface using multiple contexts. For completeness we also use the group target when creating similar surfaces within the tests (to check that similar surfaces of similar surfaces also work).
Diffstat (limited to 'test/device-offset.c')
-rw-r--r--test/device-offset.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/device-offset.c b/test/device-offset.c
index 5f0eb80f0..cee603f3c 100644
--- a/test/device-offset.c
+++ b/test/device-offset.c
@@ -59,7 +59,7 @@ draw (cairo_t *cr, int width, int height)
draw_square (cr);
/* Then, create an offset surface and repeat the drawing in red. */
- target = cairo_get_target (cr);
+ target = cairo_get_group_target (cr);
surface = cairo_surface_create_similar (target,
cairo_surface_get_content (target),
SIZE / 2, SIZE / 2);