From: Kenichi Handa Date: Wed, 14 Feb 2007 04:34:43 +0000 (+0000) Subject: (x_produce_glyphs): When a font is not found, make the X-Git-Tag: emacs-pretest-23.0.90~8295^2~598 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a2ac0bc74c776864cc005af8c414efb61fe5019c;p=emacs.git (x_produce_glyphs): When a font is not found, make the empty box occupy at least one column width. --- diff --git a/src/xdisp.c b/src/xdisp.c index 5a78dd48c10..cd4683a71b9 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -20853,9 +20853,15 @@ x_produce_glyphs (it) if (font_not_found_p || !pcm) { + int char_width = CHAR_WIDTH (it->char_to_display); + + if (char_width == 0) + /* This is a non spacing character. But, as we are + going to display an empty box, the box must occupy + at least one column. */ + char_width = 1; it->glyph_not_available_p = 1; - it->pixel_width = (FRAME_COLUMN_WIDTH (it->f) - * CHAR_WIDTH (it->char_to_display)); + it->pixel_width = FRAME_COLUMN_WIDTH (it->f) * char_width; it->phys_ascent = FONT_BASE (font) + boff; it->phys_descent = FONT_DESCENT (font) - boff; }