--- SvgExporterPG-orig.js 2011-09-15 23:11:40.000000000 +0200 +++ SvgExporterPG.js 2011-09-26 14:37:10.099224303 +0200 @@ -385,19 +385,18 @@ } if (!continuous) { //p.scale(this.getPatternFactor()); - p.scale(1/this.scale); + //p.scale(1/this.scale); var num = p.getNumDashes(); - var str = ""; + var str = []; for ( var i = 0; i < num; ++i) { var len = Math.abs(p.getDashLengthAt(i)); + // double gaps to account for round linecap + if (p.getDashLengthAt(i) < 0) { len += this.weight / 2; } // see FS#192: //len = this.convert(len); - str += "" + len; - if (i < num - 1) { - str += ","; - } + str.push(len); } - additionalStyles += "stroke-dasharray:" + str; + additionalStyles += "stroke-dasharray:" + str.join(","); // does more harm than good // if (isShape(this.shape)) { @@ -428,9 +427,9 @@ // dimension entity: export text: this.writeEntityComment(entity); this.text = entity.getTextData(); -// var angle = this.text.getAngle(); -// var offset = RVector.createPolar(this.text.getHeight()/2, angle + Math.PI/2); -// this.text.move(offset); + var angle = this.text.getAngle(); + var offset = RVector.createPolar(this.text.getHeight()/2, angle + Math.PI/2); + this.text.move(offset); this.textColor = entity.getColor(); this.exportText(); this.text = undefined;