changeset 109386:1cbe0a6dbbc2

Do not record a font-entity in the property of font-object.
author Kenichi Handa <handa@etlken>
date Wed, 14 Jul 2010 12:40:47 +0900
parents ac2791665c24
children 2bc66123f2c6
files src/ChangeLog src/font.c
diffstat 2 files changed, 10 insertions(+), 14 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Tue Jul 13 15:18:51 2010 +0900
+++ b/src/ChangeLog	Wed Jul 14 12:40:47 2010 +0900
@@ -1,3 +1,8 @@
+2010-07-14  Kenichi Handa  <handa@m17n.org>
+
+	* font.c (font_open_entity): Cancel previous change.
+	(Ffont_get): Don't check FONT_ENTITY_INDEX of a font-object.
+
 2010-07-13  Dan Nicolaescu  <dann@ics.uci.edu>
 
 	Remove subprocesses #ifdefs from term.c.
--- a/src/font.c	Tue Jul 13 15:18:51 2010 +0900
+++ b/src/font.c	Wed Jul 14 12:40:47 2010 +0900
@@ -3005,7 +3005,6 @@
     return Qnil;
   ASET (entity, FONT_OBJLIST_INDEX,
 	Fcons (font_object, AREF (entity, FONT_OBJLIST_INDEX)));
-  ASET (font_object, FONT_ENTITY_INDEX, entity);
   num_fonts++;
 
   font = XFONT_OBJECT (font_object);
@@ -4131,20 +4130,12 @@
   if (NILP (val) && EQ (key, QCotf) && FONT_OBJECT_P (font))
     {
       struct font *fontp = XFONT_OBJECT (font);
-      Lisp_Object entity = AREF (font, FONT_ENTITY_INDEX);
-
-      val = Fassq (key, AREF (entity, FONT_EXTRA_INDEX));
-      if (NILP (val))
-	{
-	  if (fontp->driver->otf_capability)
-	    val = fontp->driver->otf_capability (fontp);
-	  else
-	    val = Fcons (Qnil, Qnil);
-	  font_put_extra (font, QCotf, val);
-	  font_put_extra (entity, QCotf, val);
-	}
+
+      if (fontp->driver->otf_capability)
+	val = fontp->driver->otf_capability (fontp);
       else
-	val = Fcdr (val);
+	val = Fcons (Qnil, Qnil);
+      font_put_extra (font, QCotf, val);
     }
   else
     val = Fcdr (val);