? foo.diff Index: doc/fontconfig-devel.sgml =================================================================== RCS file: /local/src/CVS/fontconfig/doc/fontconfig-devel.sgml,v retrieving revision 1.7 diff -u -p -u -r1.7 fontconfig-devel.sgml --- doc/fontconfig-devel.sgml 23 Apr 2003 04:09:28 -0000 1.7 +++ doc/fontconfig-devel.sgml 5 Sep 2003 04:23:30 -0000 @@ -139,8 +139,8 @@ convenience for the applications renderi aspect FC_ASPECT Double Stretches glyphs horizontally before hinting pixelsize FC_PIXEL_SIZE Double Pixel size - spacing FC_SPACING Int Proportional, monospace or - charcell + spacing FC_SPACING Int Proportional, dual-width, + monospace or charcell foundry FC_FOUNDRY String Font foundry name antialias FC_ANTIALIAS Bool Whether glyphs can be antialiased Index: doc/fontconfig-user.sgml =================================================================== RCS file: /local/src/CVS/fontconfig/doc/fontconfig-user.sgml,v retrieving revision 1.7 diff -u -p -u -r1.7 fontconfig-user.sgml --- doc/fontconfig-user.sgml 22 Apr 2003 23:34:50 -0000 1.7 +++ doc/fontconfig-user.sgml 5 Sep 2003 04:23:31 -0000 @@ -98,7 +98,7 @@ convenience for the applications renderi size Double Point size aspect Double Stretches glyphs horizontally before hinting pixelsize Double Pixel size - spacing Int Proportional, monospace or charcell + spacing Int Proportional, dual-width, monospace or charcell foundry String Font foundry name antialias Bool Whether glyphs can be antialiased hinting Bool Whether the rasterizer should use hinting @@ -349,6 +349,7 @@ symbolic names for common font values: italic slant 100 oblique slant 110 proportional spacing 0 + dual spacing 90 mono spacing 100 charcell spacing 110 unknown rgba 0 Index: fontconfig/fontconfig.h =================================================================== RCS file: /local/src/CVS/fontconfig/fontconfig/fontconfig.h,v retrieving revision 1.46 diff -u -p -u -r1.46 fontconfig.h --- fontconfig/fontconfig.h 15 Aug 2003 19:45:20 -0000 1.46 +++ fontconfig/fontconfig.h 5 Sep 2003 04:23:31 -0000 @@ -128,6 +128,7 @@ typedef int FcBool; #define FC_WIDTH_ULTRAEXPANDED 200 #define FC_PROPORTIONAL 0 +#define FC_DUAL 90 #define FC_MONO 100 #define FC_CHARCELL 110 Index: src/fcfreetype.c =================================================================== RCS file: /local/src/CVS/fontconfig/src/fcfreetype.c,v retrieving revision 1.40 diff -u -p -u -r1.40 fcfreetype.c --- src/fcfreetype.c 26 Jun 2003 08:19:11 -0000 1.40 +++ src/fcfreetype.c 5 Sep 2003 04:23:32 -0000 @@ -1820,8 +1820,8 @@ FcFreeTypeCharSetAndSpacing (FT_Face fac int o; int i; FT_UInt glyph; - FT_Pos advance, all_advance = 0; - FcBool has_advance = FcFalse, fixed_advance = FcTrue; + FT_Pos advance, advance_one = 0, advance_two = 0; + FcBool has_advance = FcFalse, fixed_advance = FcTrue, dual_advance = FcFalse; fcs = FcCharSetCreate (); if (!fcs) @@ -1851,10 +1851,20 @@ FcFreeTypeCharSetAndSpacing (FT_Face fac if (!has_advance) { has_advance = FcTrue; - all_advance = advance; + advance_one = advance; } - else if (advance != all_advance) - fixed_advance = FcFalse; + else if (advance != advance_one) + { + if (fixed_advance) + { + dual_advance = FcTrue; + fixed_advance = FcFalse; + advance_two = advance; + } + else if (advance != advance_two) + dual_advance = FcFalse; + } + leaf = FcCharSetFindLeafCreate (fcs, ucs4); if (!leaf) goto bail1; @@ -1899,10 +1909,20 @@ FcFreeTypeCharSetAndSpacing (FT_Face fac if (!has_advance) { has_advance = FcTrue; - all_advance = advance; + advance_one = advance; } - else if (advance != all_advance) - fixed_advance = FcFalse; + else if (advance != advance_one) + { + if (fixed_advance) + { + dual_advance = FcTrue; + fixed_advance = FcFalse; + advance_two = advance; + } + else if (advance != advance_two) + dual_advance = FcFalse; + } + if (!leaf) { leaf = FcCharSetFindLeafCreate (fcs, ucs4); @@ -1956,10 +1976,19 @@ FcFreeTypeCharSetAndSpacing (FT_Face fac if (!has_advance) { has_advance = FcTrue; - all_advance = advance; + advance_one = advance; } - else if (advance != all_advance) - fixed_advance = FcFalse; + else if (advance != advance_one) + { + if (fixed_advance) + { + dual_advance = FcTrue; + fixed_advance = FcFalse; + advance_two = advance; + } + else if (advance != advance_two) + dual_advance = FcFalse; + } leaf = FcCharSetFindLeafCreate (fcs, ucs4); if (!leaf) goto bail1; @@ -1993,6 +2022,8 @@ FcFreeTypeCharSetAndSpacing (FT_Face fac #endif if (fixed_advance) *spacing = FC_MONO; + else if (dual_advance) + *spacing = FC_DUAL; else *spacing = FC_PROPORTIONAL; return fcs; Index: src/fcname.c =================================================================== RCS file: /local/src/CVS/fontconfig/src/fcname.c,v retrieving revision 1.19 diff -u -p -u -r1.19 fcname.c --- src/fcname.c 2 May 2003 01:11:09 -0000 1.19 +++ src/fcname.c 5 Sep 2003 04:23:32 -0000 @@ -167,6 +167,7 @@ static const FcConstant _FcBaseConstants { (FcChar8 *) "ultraexpanded", "width", FC_WIDTH_ULTRAEXPANDED }, { (FcChar8 *) "proportional", "spacing", FC_PROPORTIONAL, }, + { (FcChar8 *) "dual", "spacing", FC_DUAL, }, { (FcChar8 *) "mono", "spacing", FC_MONO, }, { (FcChar8 *) "charcell", "spacing", FC_CHARCELL, },