summaryrefslogtreecommitdiff
path: root/fitzdraw/pathstroke.c
diff options
context:
space:
mode:
authorTor Andersson <tor@ghostscript.com>2010-01-07 00:19:10 +0100
committerTor Andersson <tor@ghostscript.com>2010-01-07 00:19:10 +0100
commit662c6a3a0fe8bd09e90b877095f52a062eb92f22 (patch)
treef29952cb9cfc081cfbc34339ba581d13bcad5e2e /fitzdraw/pathstroke.c
parent12f3f31f0b28ee8854858e54962c9e5763a37d5e (diff)
downloadmupdf-662c6a3a0fe8bd09e90b877095f52a062eb92f22.tar.xz
Fix typos in stroking code and pass the device matrix to the interpreter. Now tigers.
Diffstat (limited to 'fitzdraw/pathstroke.c')
-rw-r--r--fitzdraw/pathstroke.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fitzdraw/pathstroke.c b/fitzdraw/pathstroke.c
index 0373931a..73d3bba3 100644
--- a/fitzdraw/pathstroke.c
+++ b/fitzdraw/pathstroke.c
@@ -241,6 +241,7 @@ linedot(struct sctx *s, fz_point a)
float ox = a.x - linewidth;
float oy = a.y;
int i;
+
for (i = 1; i < n; i++)
{
float theta = M_PI * 2 * i / n;
@@ -252,6 +253,7 @@ linedot(struct sctx *s, fz_point a)
ox = nx;
oy = ny;
}
+
line(s, ox, oy, a.x - linewidth, a.y);
}
@@ -288,7 +290,10 @@ strokelineto(struct sctx *s, fz_point cur)
float dy = cur.y - s->seg[s->sn-1].y;
if (dx * dx + dy * dy < FLT_EPSILON)
+ {
s->dot = 1;
+ return;
+ }
linestroke(s, s->seg[s->sn-1], cur);