Commit a00dea21 authored by Caleb Michael Moore's avatar Caleb Michael Moore

cairo clip path stuff

parent 4289af24
......@@ -71,6 +71,11 @@ rsvg_cairo_clip_render_path (RsvgDrawingCtx *ctx, const RsvgBpathDef *bpath_def)
_set_rsvg_affine (cr, state->affine);
if (rsvg_state_current(ctx)->clip_rule == FILL_RULE_EVENODD)
cairo_set_fill_rule (((RsvgCairoRender *)ctx->render)->cr, CAIRO_FILL_RULE_EVEN_ODD);
else /* state->fill_rule == FILL_RULE_NONZERO */
cairo_set_fill_rule (((RsvgCairoRender *)ctx->render)->cr, CAIRO_FILL_RULE_WINDING);
for (i=0; i < bpath_def->n_bpath; i++) {
bpath = &bpath_def->bpath[i];
......@@ -176,11 +181,7 @@ rsvg_cairo_clip (RsvgDrawingCtx *ctx, RsvgClipPath *clip, RsvgCairoBbox *bbox)
for (i = 0; i < 6; i++)
clip->super.state->affine[i] = affinesave[i];
if (rsvg_state_current (ctx)->fill_rule == FILL_RULE_EVENODD)
cairo_set_fill_rule (save->cr, CAIRO_FILL_RULE_EVEN_ODD);
else /* state->fill_rule == FILL_RULE_NONZERO */
cairo_set_fill_rule (save->cr, CAIRO_FILL_RULE_WINDING);
g_free(ctx->render);
cairo_clip(save->cr);
ctx->render = &save->super;
}
......@@ -2,9 +2,8 @@
rsvg-cairo.c: Command line utility for exercising rsvg with cairo.
Copyright (C) 2000 Eazel, Inc.
Copyright (C) 2002 Dom Lachowicz
Copyright (C) 2005 Carl Worth.
Copyright (C) 2005 Caleb Moore
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public License as
......@@ -21,8 +20,7 @@
Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA.
Authors: Raph Levien <raph@artofcode.com>
Carl Worth <cworth@cworth.org>
Authors: Caleb Moore <c.moore@student.unsw.edu.au>
*/
#include "config.h"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment