[goffice] Fix arc drawing.



commit 9dc5b9f21d988f89fc284c171af6d2ae0defd296
Author: Jean Brefort <jean brefort normalesup org>
Date:   Fri Mar 8 15:34:27 2013 +0100

    Fix arc drawing.

 ChangeLog                |    6 ++++++
 goffice/canvas/goc-arc.c |    1 -
 goffice/utils/go-emf.c   |    6 +++---
 3 files changed, 9 insertions(+), 4 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index ce39625..f08d75e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2013-03-08  Jean Brefort  <jean brefort normalesup org>
+
+       * goffice/canvas/goc-arc.c (goc_arc_draw): removed an extra cairo_save().
+       * goffice/utils/go-emf.c (go_emf_fillpath),
+       (go_emf_strokeandfillpath), (go_emf_polypolygon16): Fixed fill rule.
+
 2013-03-07  Morten Welinder  <terra gnome org>
 
        * goffice/canvas/goc-ellipse.c (goc_ellipse_distance): Avoid C++
diff --git a/goffice/canvas/goc-arc.c b/goffice/canvas/goc-arc.c
index 43deef3..bd1d5e8 100644
--- a/goffice/canvas/goc-arc.c
+++ b/goffice/canvas/goc-arc.c
@@ -391,7 +391,6 @@ goc_arc_draw (GocItem const *item, cairo_t *cr)
                cairo_stroke (cr);
        }
 
-       cairo_save(cr);
        if (goc_arc_prepare_draw (item, cr, 1)) {
                if (arc->type > 0)
                        go_styled_object_fill (GO_STYLED_OBJECT (item), cr, TRUE);
diff --git a/goffice/utils/go-emf.c b/goffice/utils/go-emf.c
index 1d90772..559ee81 100644
--- a/goffice/utils/go-emf.c
+++ b/goffice/utils/go-emf.c
@@ -3795,7 +3795,7 @@ go_emf_fillpath (GOEmfState *state)
                      "path", state->curDC->path,
                      "style", style,
                      "closed", state->curDC->closed_path,
-                     "fill-rule", !state->curDC->PolygonFillMode,
+                     "fill-rule", state->curDC->PolygonFillMode,
                      NULL);
        g_object_unref (style);
        go_path_free (state->curDC->path);
@@ -3813,7 +3813,7 @@ go_emf_strokeandfillpath (GOEmfState *state)
                      "path", state->curDC->path,
                      "style", state->curDC->style,
                      "closed", state->curDC->closed_path,
-                     "fill-rule", !state->curDC->PolygonFillMode,
+                     "fill-rule", state->curDC->PolygonFillMode,
                      NULL);
        go_path_free (state->curDC->path);
        state->curDC->path = NULL;
@@ -4311,7 +4311,7 @@ go_emf_polypolygon16 (GOEmfState *state)
        goc_item_new (state->curDC->group, GOC_TYPE_POLYGON,
                      "points", points,
                      "sizes", sizes,
-                     "fill-rule", !state->curDC->PolygonFillMode,
+                     "fill-rule", state->curDC->PolygonFillMode,
                      "style", state->curDC->style,
                      NULL);
        goc_int_array_unref (sizes);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]