GNOME Bugzilla – Bug 355605
hexbox with 0000 in it
Last modified: 2006-09-12 17:27:23 UTC
The Hangul module produces hexboxes with all zeros in it in a couple of places: One: /* Find a base character to render the mark on */ int index = find_char (font, 0x25cc); /* DOTTED CIRCLE */ (pango_font_describe (font))); if (!index) index = find_char (font, 0x25cb); /* WHITE CIRCLE, in KSC-5601 */ if (!index) index = find_char (font, ' '); /* Space */ if (!index) /* Unknown glyph box with 0000 in it */ index = find_char (font, get_unknown_glyph (font, 0)); This doesn't look that bad. The other: index = (wc >= 0x3131) ? find_char (font, wc) : 0; pango_glyph_string_set_size (glyphs, *n_glyphs + 1); if (!index) set_glyph (font, glyphs, *n_glyphs, cluster_offset, get_unknown_glyph (font, index)); else set_glyph (font, glyphs, *n_glyphs, cluster_offset, index); The first set_glyph is definitely wrong. I'm changing it to: index = (wc >= 0x3131) ? find_char (font, wc) : 0; pango_glyph_string_set_size (glyphs, *n_glyphs + 1); if (!index) set_glyph (font, glyphs, *n_glyphs, cluster_offset, get_unknown_glyph (font, text[i])); else set_glyph (font, glyphs, *n_glyphs, cluster_offset, index);
Downstream bug: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=206044
Created attachment 72626 [details] [review] better fix fixed it the right way. 2006-09-12 Behdad Esfahbod <behdad@gnome.org> Bug 355605 – hexbox with 0000 in it * modules/hangul/hangul-fc.c (render_syllable): If decomposition fails, backup and add a single hexbox glyph for the original character.
Fixed in HEAD and pango-1-14