diff options
author | Carl Worth <cworth@cworth.org> | 2005-04-26 12:38:06 +0000 |
---|---|---|
committer | Carl Worth <cworth@cworth.org> | 2005-04-26 12:38:06 +0000 |
commit | 1baa4d132903e21395dc66ca792164e2ef8885d2 (patch) | |
tree | 4b95e9a13ee0b7bcab4a9f22d919e493376d16eb /test/fill-and-stroke.c | |
parent | 618792c8c041ee2004acf1ff411e0adbe94a3e63 (diff) | |
download | cairo-1baa4d132903e21395dc66ca792164e2ef8885d2.tar.gz |
Originally: 2005-04-19 Carl Worth <cworth@cworth.org>
Add cairo_stroke_preserve, cairo_fill_preserve, and cairo_clip_preserve.
Rip the path out of cairo_gstate_t.
Add path to cairo_t.
Bring in most of the path code that used to live in cairo-gstate.c
Move arc generation code into its own file.
Accept path+ctm_inverse+tolerance instead of gstate. Absorb flattening and device space->user space conversion that used to be in _cairo_gstate_intepret_path.
Prefer cairo_fixed_t parameters over ciaro_point_t for cross-file interfaces.
Track changes in _cairo_path_fixed interfaces.
Port to use cairo_fill_preserve rather than cairo_save/cairo_restore which no longer work for saving the path.
Remove get and set of current point since it is no longer affected by cairo_save and cairo_restore. Add get and set testing for cairo_matrix_t.
Diffstat (limited to 'test/fill-and-stroke.c')
-rw-r--r-- | test/fill-and-stroke.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/test/fill-and-stroke.c b/test/fill-and-stroke.c index 5e0e49428..989317112 100644 --- a/test/fill-and-stroke.c +++ b/test/fill-and-stroke.c @@ -38,10 +38,8 @@ static cairo_test_status_t draw (cairo_t *cr, int width, int height) { cairo_rectangle (cr, PAD, PAD, SIZE, SIZE); - cairo_save (cr); cairo_set_source_rgb (cr, 0, 0, 1); - cairo_fill (cr); - cairo_restore (cr); + cairo_fill_preserve (cr); cairo_set_source_rgb (cr, 1, 0, 0); cairo_stroke (cr); @@ -51,9 +49,7 @@ draw (cairo_t *cr, int width, int height) PAD + SIZE / 2, PAD + SIZE / 2, SIZE / 2, 0, 2 * M_PI); - cairo_save (cr); - cairo_fill (cr); - cairo_restore (cr); + cairo_fill_preserve (cr); cairo_set_source_rgb (cr, 0, 0, 1); cairo_stroke (cr); |