[poppler] poppler/CairoOutputDev.cc

Carlos Garcia Campos carlosgc at kemper.freedesktop.org
Wed Nov 18 01:58:18 PST 2009


 poppler/CairoOutputDev.cc |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 037979a01a6fcafc61360e758dbc4a5eb056825e
Author: Carlos Garcia Campos <carlosgc at gnome.org>
Date:   Tue Nov 17 19:12:30 2009 +0100

    [cairo] If there's a soft mask available when filling, apply the mask instead of filling
    
    Fixes bug #8474.

diff --git a/poppler/CairoOutputDev.cc b/poppler/CairoOutputDev.cc
index 5f283c3..04457e4 100644
--- a/poppler/CairoOutputDev.cc
+++ b/poppler/CairoOutputDev.cc
@@ -668,7 +668,12 @@ void CairoOutputDev::fill(GfxState *state) {
   cairo_set_source (cairo, fill_pattern);
   LOG(printf ("fill\n"));
   //XXX: how do we get the path
-  cairo_fill (cairo);
+  if (mask) {
+    cairo_clip (cairo);
+    cairo_mask (cairo, mask);
+  } else {
+    cairo_fill (cairo);
+  }
   if (cairo_shape) {
     cairo_set_fill_rule (cairo_shape, CAIRO_FILL_RULE_WINDING);
     doPath (cairo_shape, state, state->getPath());


More information about the poppler mailing list