summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2016-12-19 12:47:46 +0000
committerRobin Watts <robin.watts@artifex.com>2016-12-19 12:56:52 +0000
commit26637fc54aa58360cfe3a0049f35ea32dc869309 (patch)
tree11182bbf08fa6636b4d93e6af4988c82910caa1a /source
parent15c15516c1949e8eb2081e324e610397fbcc1b2c (diff)
downloadmupdf-26637fc54aa58360cfe3a0049f35ea32dc869309.tar.xz
SVG output: Fix dropped group alpha.
Diffstat (limited to 'source')
-rw-r--r--source/fitz/svg-device.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/fitz/svg-device.c b/source/fitz/svg-device.c
index 16542a7a..571ced0e 100644
--- a/source/fitz/svg-device.c
+++ b/source/fitz/svg-device.c
@@ -989,7 +989,10 @@ svg_dev_begin_group(fz_context *ctx, fz_device *dev, const fz_rect *bbox, int is
fz_output *out = sdev->out;
/* SVG 1.1 doesn't support adequate blendmodes/knockout etc, so just ignore it for now */
- fz_printf(ctx, out, "<g>\n");
+ if (alpha == 1)
+ fz_printf(ctx, out, "<g>\n");
+ else
+ fz_printf(ctx, out, "<g opacity=\"%g\">\n", alpha);
}
static void