[cairo] patch for checking overlapping of "space" glyphs
Henry (Yu) Song - SISA
hsong at sisa.samsung.com
Tue Mar 13 08:55:10 PDT 2012
If a glyph is a space, box.p1.x and box.p2.x == 0 or box.p1.y and box.p2.y == 0
Date: Mon Mar 12 13:28:32 2012 -0700
check for space situation
diff --git a/src/cairo-scaled-font.c b/src/cairo-scaled-font.c
index e32e975..eda1da4 100644
--- a/src/cairo-scaled-font.c
+++ b/src/cairo-scaled-font.c
@@ -2215,8 +2215,9 @@ _cairo_scaled_font_glyph_device_extents (cairo_scaled_font_t *scaled_font,
y = _cairo_fixed_from_double (glyphs[i].y);
y1 = y + scaled_glyph->bbox.p1.y;
y2 = y + scaled_glyph->bbox.p2.y;
+
- if (overlap == FALSE)
+ if (overlap == FALSE && ((y1 != y2) || (x1 != x2)))
overlap = _range_contains_glyph (&box, x1, y1, x2, y2);
if (x1 < box.p1.x) box.p1.x = x1;
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cairographics.org/archives/cairo/attachments/20120313/8de81c62/attachment.htm>
More information about the cairo
mailing list