changeset 103041:3049105cf79e

(font_score): Check AVGWIDTH too.
author Kenichi Handa <handa@m17n.org>
date Tue, 21 Apr 2009 07:29:48 +0000
parents 10b0e119e49a
children 80bd3a8d586a
files src/font.c
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/font.c	Tue Apr 21 07:19:01 2009 +0000
+++ b/src/font.c	Tue Apr 21 07:29:48 2009 +0000
@@ -2270,6 +2270,9 @@
       if (! NILP (spec_prop[FONT_DPI_INDEX])
 	  && ! EQ (spec_prop[FONT_DPI_INDEX], AREF (entity, FONT_DPI_INDEX)))
 	diff |= 1;
+      if (! NILP (spec_prop[FONT_AVGWIDTH_INDEX])
+	  && ! EQ (spec_prop[FONT_AVGWIDTH_INDEX], AREF (entity, FONT_AVGWIDTH_INDEX)))
+	diff |= 1;
       score |= min (diff, 127) << sort_shift_bits[FONT_SIZE_INDEX];
     }