[Pkg-javascript-commits] [pdf.js] 136/207: Fixes SVG transforms on restore

David Prévot taffit at moszumanska.debian.org
Mon Jul 28 15:36:40 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository pdf.js.

commit 834f466c05b835c44a5fc2d3db33161040586539
Author: Yury Delendik <ydelendik at mozilla.com>
Date:   Thu Jun 19 23:18:04 2014 -0500

    Fixes SVG transforms on restore
---
 src/display/svg.js | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/display/svg.js b/src/display/svg.js
index cf82dff..225bd11 100644
--- a/src/display/svg.js
+++ b/src/display/svg.js
@@ -132,6 +132,12 @@ var SVGGraphics = (function SVGGraphicsClosure(ctx) {
     restore: function SVGGraphics_restore() {
       this.transformMatrix = this.transformStack.pop();
       this.current = this.extraStack.pop();
+
+      this.tgrp = document.createElementNS(NS, 'svg:g');
+      this.tgrp.setAttributeNS(null, 'id', 'transform');
+      this.tgrp.setAttributeNS(null, 'transform',
+          'matrix(' + this.transformMatrix + ')');
+      this.pgrp.appendChild(this.tgrp);
     },
 
     group: function SVGGraphics_group(items) {
@@ -669,7 +675,6 @@ var SVGGraphics = (function SVGGraphicsClosure(ctx) {
     },
 
     rectangle: function SVGGraphics_rectangle(x, y, width, height) {
-      this.save();
       var current = this.current;
       if (width < 0) {
         x = x + width;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git



More information about the Pkg-javascript-commits mailing list