[cairo-commit] cairo/src cairo-win32-font.c,1.39.2.2,1.39.2.3

Tim Rowley commit at pdx.freedesktop.org
Wed Sep 28 10:27:41 PDT 2005


Committed by: tor

Update of /cvs/cairo/cairo/src
In directory gabe:/tmp/cvs-serv19979/src

Modified Files:
      Tag: BRANCH_1_0
	cairo-win32-font.c 
Log Message:
	Bug #4612, reviewed by cworth.
	
	* src/cairo-win32-font.c (_cairo_win32_scaled_font_glyph_bbox):
	Add cast so that sign conversion doesn't alter comparison.


Index: cairo-win32-font.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo-win32-font.c,v
retrieving revision 1.39.2.2
retrieving revision 1.39.2.3
diff -u -d -r1.39.2.2 -r1.39.2.3
--- cairo-win32-font.c	26 Sep 2005 16:09:38 -0000	1.39.2.2
+++ cairo-win32-font.c	28 Sep 2005 17:27:39 -0000	1.39.2.3
@@ -812,10 +812,10 @@
 		x1 = x + metrics.gmptGlyphOrigin.x;
 	    if (i == 0 || y1 > y - metrics.gmptGlyphOrigin.y)
 		y1 = y - metrics.gmptGlyphOrigin.y;
-	    if (i == 0 || x2 < x + metrics.gmptGlyphOrigin.x + metrics.gmBlackBoxX)
-		x2 = x + metrics.gmptGlyphOrigin.x + metrics.gmBlackBoxX;
-	    if (i == 0 || y2 < y - metrics.gmptGlyphOrigin.y + metrics.gmBlackBoxY)
-		y2 = y - metrics.gmptGlyphOrigin.y + metrics.gmBlackBoxY;
+	    if (i == 0 || x2 < x + metrics.gmptGlyphOrigin.x + (int)metrics.gmBlackBoxX)
+		x2 = x + metrics.gmptGlyphOrigin.x + (int)metrics.gmBlackBoxX;
+	    if (i == 0 || y2 < y - metrics.gmptGlyphOrigin.y + (int)metrics.gmBlackBoxY)
+		y2 = y - metrics.gmptGlyphOrigin.y + (int)metrics.gmBlackBoxY;
 	}
 
 	cairo_win32_scaled_font_done_font (&scaled_font->base);



More information about the cairo-commit mailing list