Commit 3d8416fc authored by Naohiro Aota's avatar Naohiro Aota Committed by Chong Yidong
Browse files

Check FC_DUAL too. For such fonts, check width one by one (Bug#4129).

* xftfont.c (xftfont_open): Check font width one by one also when
spacing is dual.

* ftfont.c (ftfont_open): Ditto.
parent 8bf1c786
2010-06-30 Naohiro Aota <naota@elisp.net> (tiny change)
* xftfont.c (xftfont_open): Check font width one by one also when
spacing is dual.
* ftfont.c (ftfont_open): Ditto.
2010-06-26 Andreas Schwab <schwab@linux-m68k.org>
* alloc.c (Fmake_byte_code): Don't access undefined argument
......
......@@ -1262,7 +1262,7 @@ ftfont_open (f, entity, pixel_size)
spacing = XINT (AREF (entity, FONT_SPACING_INDEX));
else
spacing = FC_PROPORTIONAL;
if (spacing != FC_PROPORTIONAL)
if (spacing != FC_PROPORTIONAL && spacing != FC_DUAL)
font->min_width = font->average_width = font->space_width
= (scalable ? ft_face->max_advance_width * size / upEM
: ft_face->size->metrics.max_advance >> 6);
......
......@@ -429,7 +429,7 @@ xftfont_open (f, entity, pixel_size)
ascii_printable[i] = ' ' + i;
}
BLOCK_INPUT;
if (spacing != FC_PROPORTIONAL)
if (spacing != FC_PROPORTIONAL && spacing != FC_DUAL)
{
font->min_width = font->average_width = font->space_width
= xftfont->max_advance_width;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment