[Sie-announce] SIEコード [1578]

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2010年 1月 15日 (金) 21:19:47 JST


Revision: 1578
          http://sourceforge.jp/projects/sie/svn/view?view=rev&revision=1578
Author:   dhrname
Date:     2010-01-15 21:19:47 +0900 (Fri, 15 Jan 2010)

Log Message:
-----------


Modified Paths:
--------------
    branches/05x/058/sie.js

Modified: branches/05x/058/sie.js
===================================================================
--- branches/05x/058/sie.js	2010-01-15 12:06:12 UTC (rev 1577)
+++ branches/05x/058/sie.js	2010-01-15 12:19:47 UTC (rev 1578)
@@ -466,34 +466,32 @@
 }
 STText.prototype.set = function textset( /*float*/ w, /*float*/ h) {
   try {
-  var ttm = this.transformable;
-  var fontSize = fontset(this.paint["font-size"], w, h, ttm);
-  if (this.x._emToUnits(fontSize)) {
-    this.y._emToUnits(fontSize);
-  }
-  var p = new Point(this.x.value,this.y.value);
-  var ptm = p.matrixTransform(ttm);
-  this.tar.w = w;
-  this.tar.h = h;
-  var tts = this.tar.style;
-  tts.position = "absolute";
-  var ttp = this.tar.parentNode;
-  if (ttp.lastChild.nodeName !== "rect") {
-    var backr = document.createElement("v:rect");
-    var backrs = backr.style; //ずれを修正するためのもの
-    backrs.width = "1px";
-    backrs.height = "1px";
-    backrs.left = "0px";
-    backrs.top = "0px";
-    backr.stroked = "false";
-    backr.filled = "false";
-    ttp.appendChild(backr);
-  }
-  tts.width = "0px";
-  tts.height = "0px";
-  this.paint.fset(w,h,ttm);
-  } catch(e) {stlog.add(e,236);}
-  try {
+    var ttm = this.transformable;
+    var fontSize = fontset(this.paint["font-size"], w, h, ttm);
+    if (this.x._emToUnits(fontSize)) {
+      this.y._emToUnits(fontSize);
+    }
+    var p = new Point(this.x.value,this.y.value);
+    var ptm = p.matrixTransform(ttm);
+    this.tar.w = w;
+    this.tar.h = h;
+    var tts = this.tar.style;
+    tts.position = "absolute";
+    var ttp = this.tar.parentNode;
+    if (ttp.lastChild.nodeName !== "rect") {
+      var backr = document.createElement("v:rect");
+      var backrs = backr.style; //ずれを修正するためのもの
+      backrs.width = "1px";
+      backrs.height = "1px";
+      backrs.left = "0px";
+      backrs.top = "0px";
+      backr.stroked = "false";
+      backr.filled = "false";
+      ttp.appendChild(backr);
+    }
+    tts.width = "0px";
+    tts.height = "0px";
+    this.paint.fset(w,h,ttm);
     //以下は、テキストの幅であるtextLengthを算出する
     var arr = this.tspan, textLength = 0, fontSize = this.paint.fontSize, atfontSize = 0, fij = /[fijlt.,:;1]/g; //fontSizeは親要素の文字サイズ。atfontSizeは各span要素のサイズ。
     for (var i=0,s={dx:0,dy:0},arri=arr.length;i<arri;++i) {
@@ -1569,7 +1567,6 @@
   listR = /\([^\)]+\)/g,
   degR = /[\-\d\.e]+/g;
 NAIBU.transformToCTM = function( /*element*/ ele, /*Matrix*/ matrix) {
-  try {
   var tft = ele.getAttribute("transform");
   if (tft) {
     var _parseFloat = parseFloat;
@@ -1648,7 +1645,6 @@
     }
     list = coma = mat = matri = null;
   }
-  }  catch(e) {stlog.add(e,816);}
   return matrix;
 };
 })();




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