From: oetiker Date: Fri, 16 Dec 2011 20:19:49 +0000 (+0000) Subject: fix horyzontal alignement of lines and aread X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=e760d0f0b6f7ff2e68ef8f95a7c045cf1ea03ca9;p=rrdtool-all.git fix horyzontal alignement of lines and aread git-svn-id: svn://svn.oetiker.ch/rrdtool/branches/1.4@2245 a5681a0c-68f1-0310-ab6d-d61299d08faa --- diff --git a/program/src/rrd_gfx.c b/program/src/rrd_gfx.c index 30bf7912..f7844326 100644 --- a/program/src/rrd_gfx.c +++ b/program/src/rrd_gfx.c @@ -295,7 +295,7 @@ void gfx_line_fit( cairo_user_to_device_distance(cr, &line_width, &line_height); line_width = line_width / 2.0 - ceil(line_width / 2.0); line_height = line_height / 2.0 - ceil(line_height / 2.0); - *x = ceil(*x - 0.5) - line_width; + *x = floor(*x - 0.5) - line_width; *y = ceil(*y + 0.5) + line_height; cairo_device_to_user(cr, x, y); }