Commit 8e3759aa by Dmitry Baranovskiy

Fixed path parsing. Ok, lets release it. ;)

parent e85b406e
...@@ -310,7 +310,7 @@ window.Raphael = (function () { ...@@ -310,7 +310,7 @@ window.Raphael = (function () {
r[7] = +(pa[7] - y).toFixed(3); r[7] = +(pa[7] - y).toFixed(3);
break; break;
case "v": case "v":
r[1] = +(pa[1] - y).toFixed(3); r[1] = (pa[1] - y).toFixed(3);
break; break;
default: default:
for (var j = 1, jj = pa.length; j < jj; j++) { for (var j = 1, jj = pa.length; j < jj; j++) {
...@@ -369,13 +369,19 @@ window.Raphael = (function () { ...@@ -369,13 +369,19 @@ window.Raphael = (function () {
case "V": case "V":
r[1] = +pa[1] + y; r[1] = +pa[1] + y;
break; break;
case "H":
r[1] = +pa[1] + x;
break;
default: default:
for (var j = 1, jj = pa.length; j < jj; j++) { for (var j = 1, jj = pa.length; j < jj; j++) {
r[j] = +pa[j] + ((j % 2) ? x : y); r[j] = +pa[j] + ((j % 2) ? x : y);
} }
} }
} else { } else {
res[i] = pa; r = res[i] = [];
for (var k = 0, kk = pa.length; k < kk; k++) {
res[i][k] = pa[k];
}
} }
switch (r[0]) { switch (r[0]) {
case "Z": case "Z":
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment