Fix SVG error in importing transformed gradients with highlights.

This commit is contained in:
Jürg Lehni 2013-10-16 15:09:23 +02:00
parent 1decf451b4
commit f63cb40723

View file

@ -804,7 +804,8 @@ var Color = Base.extend(new function() {
var radius = destination.getDistance(origin),
highlight = components[3];
if (highlight) {
var vector = highlight.subtract(translation).subtract(origin);
highlight = highlight.subtract(translation);
var vector = highlight.subtract(origin);
if (vector.getLength() > radius)
highlight = origin.add(vector.normalize(radius - 0.1));
}