From a71d524ecad48837e0124a03124bc05f59a48be7 Mon Sep 17 00:00:00 2001 From: marha Date: Thu, 30 Apr 2015 23:24:30 +0200 Subject: fontconfig pixman libX11 mesa git update 30 Apr 2015 libX11 commit d3415d1f052530760b4617db45affcb984cfe35c pixman commit e0c0153d8e5d42c08c2b9bd2cf2123bff2c48d75 fontconfig commit 4a6f5efd5f6a468e1872d58e589bcf30ba88e2fd mesa commit 1ac7db07b363207e8ded9259f84bbcaa084b8667 --- fontconfig/conf.d/10-scale-bitmap-fonts.conf | 32 ++++++----- fontconfig/doc/fontconfig-user.sgml | 2 +- fontconfig/src/fcfreetype.c | 84 ++++------------------------ 3 files changed, 30 insertions(+), 88 deletions(-) (limited to 'fontconfig') diff --git a/fontconfig/conf.d/10-scale-bitmap-fonts.conf b/fontconfig/conf.d/10-scale-bitmap-fonts.conf index e3bcd46cd..b4e9cb4f2 100644 --- a/fontconfig/conf.d/10-scale-bitmap-fonts.conf +++ b/fontconfig/conf.d/10-scale-bitmap-fonts.conf @@ -2,8 +2,13 @@ + - + false @@ -13,10 +18,20 @@ + + + false + false + + true + @@ -30,20 +45,7 @@ - - - false - - - 64 - - - true - true @@ -55,7 +57,7 @@ If we *are* going to scale, go ahead and do it. --> - + false diff --git a/fontconfig/doc/fontconfig-user.sgml b/fontconfig/doc/fontconfig-user.sgml index 7b4ad7408..5803929f7 100644 --- a/fontconfig/doc/fontconfig-user.sgml +++ b/fontconfig/doc/fontconfig-user.sgml @@ -322,7 +322,7 @@ will be used to store the cache files. If it starts with '~', it refers to a directory in the users home directory. If 'prefix' is set to "xdg", the value in the XDG_CACHE_HOME environment variable will be added as the path prefix. please see XDG Base Directory Specification for more details. The default directory is ``$XDG_CACHE_HOME/fontconfig'' and it contains the cache files named ``<hash value>-<architecture>.cache-<version>'', -where <version> is the font configureation file +where <version> is the font configuration file version number (currently 5). <literal><include ignore_missing="no" prefix="default"></literal> diff --git a/fontconfig/src/fcfreetype.c b/fontconfig/src/fcfreetype.c index 50ff3489c..afbd9ac1e 100644 --- a/fontconfig/src/fcfreetype.c +++ b/fontconfig/src/fcfreetype.c @@ -978,76 +978,6 @@ FcNoticeFoundry(const FT_String *notice) return 0; } -static FcBool -FcVendorMatch(const FT_Char vendor[4], const FT_Char *vendor_string) -{ - /* vendor is not necessarily NUL-terminated. */ - int i, len; - - len = strlen((char *) vendor_string); - if (memcmp(vendor, vendor_string, len) != 0) - return FcFalse; - for (i = len; i < 4; i++) - if (vendor[i] != ' ' && vendor[i] != '\0') - return FcFalse; - return FcTrue; -} - -/* This table is partly taken from ttmkfdir by Joerg Pommnitz. */ - -/* It should not contain useless entries (such as UNKN) nor duplicate - entries for padding both with spaces and NULs. */ - -static const struct { - const FT_Char vendor[5]; - const FcChar8 foundry[13]; -} FcVendorFoundries[] = { - { "ADBE", "adobe"}, - { "AGFA", "agfa"}, - { "ALTS", "altsys"}, - { "APPL", "apple"}, - { "ARPH", "arphic"}, - { "ATEC", "alltype"}, - { "B&H", "b&h"}, - { "BITS", "bitstream"}, - { "CANO", "cannon"}, - { "CLM", "culmus"}, - { "DYNA", "dynalab"}, - { "EPSN", "epson"}, - { "FJ", "fujitsu"}, - { "IBM", "ibm"}, - { "ITC", "itc"}, - { "IMPR", "impress"}, - { "LARA", "larabiefonts"}, - { "LEAF", "interleaf"}, - { "LETR", "letraset"}, - { "LINO", "linotype"}, - { "MACR", "macromedia"}, - { "MONO", "monotype"}, - { "MS", "microsoft"}, - { "MT", "monotype"}, - { "NEC", "nec"}, - { "PARA", "paratype"}, - { "QMSI", "qms"}, - { "RICO", "ricoh"}, - { "URW", "urw"}, - { "Y&Y", "y&y"} -}; - -#define NUM_VENDOR_FOUNDRIES (int) (sizeof (FcVendorFoundries) / sizeof (FcVendorFoundries[0])) - -static const FcChar8 * -FcVendorFoundry(const FT_Char vendor[4]) -{ - int i; - - if (vendor) - for(i = 0; i < NUM_VENDOR_FOUNDRIES; i++) - if (FcVendorMatch (vendor, FcVendorFoundries[i].vendor)) - return FcVendorFoundries[i].foundry; - return 0; -} - typedef struct _FcStringConst { const FcChar8 *name; int value; @@ -1239,7 +1169,7 @@ FcFreeTypeQueryFace (const FT_Face face, #if 0 FcChar8 *family = 0; #endif - FcChar8 *complex_; + FcChar8 *complex_, *foundry_ = NULL; const FcChar8 *foundry = 0; int spacing; TT_OS2 *os2; @@ -1315,7 +1245,15 @@ FcFreeTypeQueryFace (const FT_Face face, */ if (os2 && os2->version >= 0x0001 && os2->version != 0xffff) - foundry = FcVendorFoundry(os2->achVendID); + { + if (os2->achVendID && os2->achVendID[0] != 0) + { + foundry_ = (FcChar8 *) malloc (sizeof (os2->achVendID) + 1); + memcpy ((void *)foundry_, os2->achVendID, sizeof (os2->achVendID)); + foundry_[sizeof (os2->achVendID)] = 0; + foundry = foundry_; + } + } if (FcDebug () & FC_DBG_SCANV) printf ("\n"); @@ -1946,6 +1884,8 @@ bail2: FcCharSetDestroy (cs); bail1: FcPatternDestroy (pat); + if (foundry_) + free (foundry_); bail0: return NULL; } -- cgit v1.2.3