View Issue Details

IDProjectCategoryView StatusLast Update
0000516luatexluatex bugpublic2012-04-09 05:07
ReporterphiAssigned ToTaco 
PrioritynormalSeveritytweakReproducibilityhave not tried
Status closedResolutionfixed 
Product Version 
Target VersionFixed in Version0.65.0 
Summary0000516: FontForge bug makes Cambria Math accents look bad
DescriptionA small bug in FontForge may lead to displacements when reading the AccentTop table, which makes accents in Cambria Math look wrong. Patch is attached.
Tagsmath

Activities

phi

2010-11-17 23:01

reporter  

fontforge-bug.patch (1,142 bytes)
Index: source/texk/web2c/luatexdir/luafontloader/fontforge/fontforge/parsettfatt.c
===================================================================
--- source/texk/web2c/luatexdir/luafontloader/fontforge/fontforge/parsettfatt.c	(revision 3963)
+++ source/texk/web2c/luatexdir/luafontloader/fontforge/fontforge/parsettfatt.c	(working copy)
@@ -4954,13 +4954,14 @@
     if ( glyphs==NULL )
 return;
     fseek(ttf,start+4,SEEK_SET);
-    for ( i=0; i<cnt; ++i ) if ( glyphs[i]<info->glyph_cnt && info->chars[ glyphs[i]]!=NULL ) {
-	val = (int16) getushort(ttf);
+    for ( i=0; i<cnt; ++i ) {
+      val = (int16) getushort(ttf);
+      offset = getushort(ttf);
+      if ( glyphs[i]<info->glyph_cnt && info->chars[ glyphs[i]]!=NULL ) {
 	if ( is_ic )
 	    info->chars[ glyphs[i] ]->italic_correction = val;
 	else
 	    info->chars[ glyphs[i] ]->top_accent_horiz = val;
-	offset = getushort(ttf);
 #ifdef FONTFORGE_CONFIG_DEVICETABLES
 	if ( offset!=0 ) {
 	    DeviceTable *dv = chunkalloc(sizeof(DeviceTable));
@@ -4971,6 +4972,7 @@
 		info->chars[ glyphs[i] ]->top_accent_adjusts = dv;
 	}
 #endif
+      }
     }
     free(glyphs);
 }
fontforge-bug.patch (1,142 bytes)

Taco

2010-11-24 14:51

administrator   ~0000660

patch applied in revision 3968.

Issue History

Date Modified Username Field Change
2010-11-17 23:01 phi New Issue
2010-11-17 23:01 phi File Added: fontforge-bug.patch
2010-11-24 14:48 Taco Status new => assigned
2010-11-24 14:48 Taco Assigned To => Taco
2010-11-24 14:51 Taco Note Added: 0000660
2010-11-24 14:51 Taco Status assigned => resolved
2010-11-24 14:51 Taco Resolution open => fixed
2010-12-13 14:43 Taco Fixed in Version => 0.65.0
2010-12-13 14:43 Taco Status resolved => closed
2012-04-09 05:07 Khaled Hosny Tag Attached: math