From 8d30cc5e32d4c098c1382594e0799de44a44f1bf Mon Sep 17 00:00:00 2001 From: Bryce Harrington Date: Tue, 12 Nov 2013 19:14:53 -0800 Subject: Inform tests of the canvas width and height This also fixes mis-matched surface sizes here and there. --- src/cairo-tests/roundrect.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/cairo-tests/roundrect.cpp') diff --git a/src/cairo-tests/roundrect.cpp b/src/cairo-tests/roundrect.cpp index 4c8c4b7..aff994c 100644 --- a/src/cairo-tests/roundrect.cpp +++ b/src/cairo-tests/roundrect.cpp @@ -37,8 +37,8 @@ ca_test_roundrect(caskbench_context_t *ctx) int i, w, x, y; for (i=0; isize; i++) { randomize_color (ctx->cr); - x = 10 + ((double)800*rand())/RAND_MAX; - y = 10 + ((double)300*rand())/RAND_MAX;; + x = 10 + ((double)ctx->canvas_width*rand())/RAND_MAX; + y = 10 + ((double)ctx->canvas_height*rand())/RAND_MAX;; w = ((double)ctx->size*rand())/RAND_MAX + 1; rounded_rectangle (ctx->cr, x, y, 100, 40, 4); -- cgit v1.3.1-4-g156e