[Sie-announce] SIEコード [1126] 1, clipの単位を除去

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2009年 4月 24日 (金) 22:21:42 JST


Revision: 1126
          http://svn.sourceforge.jp/view?root=sie&view=rev&rev=1126
Author:   dhrname
Date:     2009-04-24 22:21:42 +0900 (Fri, 24 Apr 2009)

Log Message:
-----------
1, clipの単位を除去
2, fill,stroke要素の属性を設定するようにした

Modified Paths:
--------------
    branches/04x/046/sie.js

Modified: branches/04x/046/sie.js
===================================================================
--- branches/04x/046/sie.js	2009-04-18 14:45:52 UTC (rev 1125)
+++ branches/04x/046/sie.js	2009-04-24 13:21:42 UTC (rev 1126)
@@ -203,7 +203,7 @@
   }
   var backright = bl + viewWidth + 1;
   var backdown = bt + viewHeight + 1;
-  trstyle.clip = "rect(" +bt+ " " +backright+ "px " +backdown+ "px " +bl+ ")";
+  trstyle.clip = "rect(" +bt+ " " +backright+ " " +backdown+ " " +bl+ ")";
   //以下、テキストの位置を修正
   var text = this.rootElement.getElementsByTagName("div");
   for (var i=0,textli=text.length;i<textli;++i) {
@@ -349,7 +349,6 @@
 }
 STGroupElement.prototype.set = function (sw,sh) {
   try{
-  var ele = this.tar;
   stvsetob(this.children,sw,sh);
   delete (this.children);
   } catch(e){stlog.addd(e,3145)}
@@ -1012,10 +1011,10 @@
       this.w = w; this.h = h; //radialGradientで必要
       isRadial = this.gradient(fillElement, RegExp.$1, matrix);
     } else {
-      el.fillcolor = this.color(this.fill);
+      fillElement.setAttribute("color", this.color(this.fill));
       var fillOpacity = this.fillopacity * this.opacity; //opacityを掛け合わせる
       if (fillOpacity < 1) {
-        fillElement.opacity = fillOpacity;
+        fillElement.setAttribute("opacity", fillOpacity);
       }
     }
     } catch(e) {stlog.add(e,682); fillElement.on = "true";
@@ -1032,11 +1031,11 @@
     try {
     var sw = new STLength(this.strokewidth, Math.sqrt((w*w + h*h) / 2));
     var swx = sw.value * Math.sqrt(Math.abs(matrix.determinant()));
-    el.strokeweight = swx + "px";
+    strokeElement.setAttribute("weight", swx + "px");
     if (this.stroke.match(/url\(#([^)]+)/)) {
       this.gradient(strokeElement, RegExp.$1);
     } else {
-      el.strokecolor = this.color(this.stroke);
+      strokeElement.setAttribute("color", this.color(this.stroke));
       var strokeOpacity = this.strokeopacity * this.opacity; //opacityを掛け合わせる
       if (swx < 1) {
         strokeOpacity *= swx; //太さが1px未満なら色を薄くする
@@ -1919,12 +1918,12 @@
   obst.width = regwv+ "px";
   obst.height = reghv+ "px";
   ob.coordsize = regwv  +" "+  reghv;
-  var dn = new Date();
+  var dnj = new Date();
   STdocument[dn] = new SVGtoVML(obc,obwidth,obheight,regw,regh);
   obj.parentNode.insertBefore(ob,obj);
   STdocument[dn].read(ob);
   STdocument[dn].set(ob);
-  alert((new Date()).getTime() - dn.getTime());
+  alert((new Date()).getTime() - dnj.getTime());
   data = dc = null;
   if (NAIBU.STObject !== void 0) {NAIBU.STObject.next();}
 }




Sie-announce メーリングリストの案内
Back to archive index