]> git.pld-linux.org Git - packages/fontconfig.git/commitdiff
- speed up cache generation (from FC)
authorKarol Krenski <charles@pld-linux.org>
Tue, 30 May 2006 15:56:48 +0000 (15:56 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    fontconfig-cmap-parsing.patch -> 1.1

fontconfig-cmap-parsing.patch [new file with mode: 0644]

diff --git a/fontconfig-cmap-parsing.patch b/fontconfig-cmap-parsing.patch
new file mode 100644 (file)
index 0000000..60db365
--- /dev/null
@@ -0,0 +1,63 @@
+--- fontconfig-2.3.95/src/fcfreetype.c.cmap-parsing    2006-04-25 11:31:41.000000000 -0400
++++ fontconfig-2.3.95/src/fcfreetype.c 2006-05-18 08:14:09.000000000 -0400
+@@ -2511,31 +2511,12 @@
+       }
+       else
+       {
+-          FT_UInt gindex;
+-        
+-          /*
+-           * Find the first encoded character in the font
+-           */
+-          if (FT_Get_Char_Index (face, 0))
++            page = ~0;
++            leaf = NULL;
++            ucs4 = FT_Get_First_Char (face, &glyph);
++            while (glyph != 0)
+           {
+-              ucs4 = 0;
+-              gindex = 1;
+-          }
+-          else
+-          {
+-              ucs4 = FT_Get_Next_Char (face, 0, &gindex);
+-              if (!ucs4)
+-                  gindex = 0;
+-          }
+-
+-          while (gindex)
+-          {
+-              page = ucs4 >> 8;
+-              leaf = 0;
+-              while ((ucs4 >> 8) == page)
+-              {
+-                  glyph = FT_Get_Char_Index (face, ucs4);
+-                  if (glyph && FcFreeTypeCheckGlyph (face, ucs4, 
++                if (FcFreeTypeCheckGlyph (face, ucs4,
+                                                      glyph, blanks, &advance))
+                   {
+                       if (advance)
+@@ -2558,8 +2539,9 @@
+                           }
+                       }
+-                      if (!leaf)
++                    if ((ucs4 >> 8) != page)
+                       {
++                        page = (ucs4 >> 8);
+                           leaf = FcCharSetFindLeafCreate (fcs, ucs4);
+                           if (!leaf)
+                               goto bail1;
+@@ -2571,11 +2553,7 @@
+                           font_max = ucs4;
+ #endif
+                   }
+-                  ucs4++;
+-              }
+-              ucs4 = FT_Get_Next_Char (face, ucs4 - 1, &gindex);
+-              if (!ucs4)
+-                  gindex = 0;
++                ucs4 = FT_Get_Next_Char (face, ucs4, &glyph);
+           }
+ #ifdef CHECK
+           for (ucs4 = 0; ucs4 < 0x10000; ucs4++)
This page took 0.150319 seconds and 4 git commands to generate.