Sync get-path-extents test with the one on 1.10.

The problem fixed by e9bb70d2de
had already been fixed on master by always computing exact extents:
89e1261dd0
This commit is contained in:
Jeff Muizelaar 2010-11-10 14:21:58 -05:00
parent 3afd7cd031
commit 7237eb62be

View file

@ -187,7 +187,7 @@ draw (cairo_t *cr, int width, int height)
cairo_restore (cr2);
/* http://bugs.freedesktop.org/show_bug.cgi?id=7965 */
phase = "A vertical, open path";
phase = "A horizontal, open path";
cairo_save (cr2);
cairo_set_line_cap (cr2, CAIRO_LINE_CAP_ROUND);
cairo_set_line_join (cr2, CAIRO_LINE_JOIN_ROUND);
@ -199,6 +199,32 @@ draw (cairo_t *cr, int width, int height)
cairo_new_path (cr2);
cairo_restore (cr2);
phase = "A vertical, open path";
cairo_save (cr2);
cairo_set_line_cap (cr2, CAIRO_LINE_CAP_ROUND);
cairo_set_line_join (cr2, CAIRO_LINE_JOIN_ROUND);
cairo_new_path (cr2);
cairo_move_to (cr2, 180, 0);
cairo_line_to (cr2, 180, 750);
errors += !check_extents (ctx, phase, cr2, FILL, EQUALS, 0, 0, 0, 0);
errors += !check_extents (ctx, phase, cr2, STROKE, EQUALS, 175, -5, 10, 760);
errors += !check_extents (ctx, phase, cr2, PATH, EQUALS, 180, 0, 0, 750);
cairo_new_path (cr2);
cairo_restore (cr2);
phase = "A degenerate open path";
cairo_save (cr2);
cairo_set_line_cap (cr2, CAIRO_LINE_CAP_ROUND);
cairo_set_line_join (cr2, CAIRO_LINE_JOIN_ROUND);
cairo_new_path (cr2);
cairo_move_to (cr2, 180, 0);
cairo_line_to (cr2, 180, 0);
errors += !check_extents (ctx, phase, cr2, FILL, EQUALS, 0, 0, 0, 0);
errors += !check_extents (ctx, phase, cr2, STROKE, EQUALS, 175, -5, 10, 10);
errors += !check_extents (ctx, phase, cr2, PATH, EQUALS, 180, 0, 0, 0);
cairo_new_path (cr2);
cairo_restore (cr2);
phase = "Simple rect";
cairo_save (cr2);
cairo_rectangle (cr2, 10, 10, 80, 80);