Permalink
Browse files

Consider stroke opacity

  • Loading branch information...
1 parent 48107a7 commit b21baeeee699b1c3934addf38645515ee6df93b9 Tobias Schneider committed Jun 12, 2010
Showing with 5 additions and 3 deletions.
  1. +5 −3 src/renderer/svg.js
View
@@ -330,12 +330,14 @@
}else{
attrs.fill = color2string(fill);
var alpha = fill.alpha;
- attrs.opacity = alpha == undefined ? 1 : alpha;
+ if(undefined != alpha){ attrs.fill_opacity = alpha; }
}
}else{ attrs.fill = "none"; }
if(line){
- attrs.stroke = color2string(line.color);
- attrs.stroke_width = Math.max(line.width, 1);
+ var color = line.color,
+ alpha = color.alpha;
+ attrs.stroke = color2string(color);
+ if(undefined != alpha){ attrs.stroke_opacity = alpha; }
}
t._setAttributes(node, attrs);
}

0 comments on commit b21baee

Please sign in to comment.