From 0d837b4a07681331648016cca7093402df68ca9f Mon Sep 17 00:00:00 2001 From: Robin Watts Date: Thu, 19 Dec 2013 20:14:23 +0000 Subject: Solve subpixel rendering problems with 270 degree rotations It seems that (int)-98.5 = 98, not -99. Use floorf instead. --- source/fitz/draw-device.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/fitz/draw-device.c') diff --git a/source/fitz/draw-device.c b/source/fitz/draw-device.c index 60735460..a92c88b5 100644 --- a/source/fitz/draw-device.c +++ b/source/fitz/draw-device.c @@ -554,8 +554,8 @@ fz_draw_fill_text(fz_device *devp, fz_text *text, const fz_matrix *ctm, if (glyph) { fz_pixmap *pixmap = glyph->pixmap; - int x = (int)trm.e; - int y = (int)trm.f; + int x = floorf(trm.e); + int y = floorf(trm.f); if (pixmap == NULL || pixmap->n == 1) { draw_glyph(colorbv, state->dest, glyph, x, y, &state->scissor); -- cgit v1.2.3