Roo/svg/Canvas.js
authorAlan Knowles <alan@roojs.com>
Fri, 25 Jun 2021 07:34:41 +0000 (15:34 +0800)
committerAlan Knowles <alan@roojs.com>
Fri, 25 Jun 2021 07:34:41 +0000 (15:34 +0800)
Roo/svg/Canvas.js

index c9700de..efa7724 100644 (file)
@@ -91,7 +91,10 @@ Roo.extend(Roo.svg.Canvas, Roo.bootstrap.Component,  {
                 width : x,
                 height : x * ratio //p.getComputedHeight() - p.getFrameWidth('tb')
             });
-            this.updateViewBox();
+            if (gs.height) {
+                this.el.attr("viewBox", box.x + " " + box.y + " " + box.width + " " + box.height);
+            }
+            
         }).defer(300, this);
         
     },