aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Schweinsberg <[email protected]>2016-01-04 11:10:11 -0800
committerDavid Schweinsberg <[email protected]>2016-01-04 11:10:11 -0800
commitcb61bf69fd58c9f8280e0b5b7caf5c81546fd815 (patch)
treeb5326f2aa0ccb78817446dfada70d2542fd20905 /src
parent9585a56fd6e2791adef0ed371a2f4e1cae01e9a6 (diff)
Fixed a bug in vhcurveto/hvcurveto with the xf/yf values
Diffstat (limited to 'src')
-rw-r--r--src/net/java/dev/typecast/cff/T2Interpreter.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/net/java/dev/typecast/cff/T2Interpreter.java b/src/net/java/dev/typecast/cff/T2Interpreter.java
index ad2965f..b4fc704 100644
--- a/src/net/java/dev/typecast/cff/T2Interpreter.java
+++ b/src/net/java/dev/typecast/cff/T2Interpreter.java
@@ -289,7 +289,7 @@ public class T2Interpreter {
int xe = xd + dxe[i];
int ye = yd + dye[i];
int xf = xe + dxf[i];
- int yf = ye + dyf;
+ int yf = ye + (i == count - 1 ? dyf : 0);
curveTo(xa, ya, xb, yb, xc, yc);
curveTo(xd, yd, xe, ye, xf, yf);
}
@@ -343,7 +343,7 @@ public class T2Interpreter {
int yd = yc;
int xe = xd + dxe[i];
int ye = yd + dye[i];
- int xf = xe + dxf;
+ int xf = xe + (i == count - 1 ? dxf : 0);
int yf = ye + dyf[i];
curveTo(xa, ya, xb, yb, xc, yc);
curveTo(xd, yd, xe, ye, xf, yf);
@@ -473,7 +473,7 @@ public class T2Interpreter {
int yd = yc;
int xe = xd + dxe[i];
int ye = yd + dye[i];
- int xf = xe + dxf;
+ int xf = xe + (i == count - 1 ? dxf : 0);
int yf = ye + dyf[i];
curveTo(xa, ya, xb, yb, xc, yc);
curveTo(xd, yd, xe, ye, xf, yf);
@@ -529,7 +529,7 @@ public class T2Interpreter {
int xe = xd + dxe[i];
int ye = yd + dye[i];
int xf = xe + dxf[i];
- int yf = ye + dyf;
+ int yf = ye + (i == count - 1 ? dyf : 0);
curveTo(xa, ya, xb, yb, xc, yc);
curveTo(xd, yd, xe, ye, xf, yf);
}