diff options
author | marha <marha@users.sourceforge.net> | 2011-11-18 15:38:32 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2011-11-18 15:38:32 +0100 |
commit | ac36cb2c0db123b18d83f59d011d83b299edea63 (patch) | |
tree | c513e767ebfb36c8439b87eec7853198cc0387af /freetype/src/base | |
parent | 7a750103eafc49dd7ee461b6f5efb41a93174056 (diff) | |
parent | 1037d56ca89d503cfd62830a90e934a2806ad804 (diff) | |
download | vcxsrv-ac36cb2c0db123b18d83f59d011d83b299edea63.tar.gz vcxsrv-ac36cb2c0db123b18d83f59d011d83b299edea63.tar.bz2 vcxsrv-ac36cb2c0db123b18d83f59d011d83b299edea63.zip |
Merge remote-tracking branch 'origin/released'
Diffstat (limited to 'freetype/src/base')
-rw-r--r-- | freetype/src/base/ftbase.h | 5 | ||||
-rw-r--r-- | freetype/src/base/ftbitmap.c | 4 | ||||
-rw-r--r-- | freetype/src/base/ftrfork.c | 2 | ||||
-rw-r--r-- | freetype/src/base/fttype1.c | 28 |
4 files changed, 34 insertions, 5 deletions
diff --git a/freetype/src/base/ftbase.h b/freetype/src/base/ftbase.h index 5ab258764..a13fe595b 100644 --- a/freetype/src/base/ftbase.h +++ b/freetype/src/base/ftbase.h @@ -49,7 +49,8 @@ FT_BEGIN_HEADER FT_Face *aface ); -#ifdef FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK +#if defined( FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK ) && \ + ( !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON ) ) /* Mac OS X/Darwin kernel often changes recommended method to access */ /* the resource fork and older methods makes the kernel issue the */ /* warning of deprecated method. To calm it down, the methods based */ @@ -57,7 +58,7 @@ FT_BEGIN_HEADER /* the case the resource is opened but found to lack a font in it. */ FT_LOCAL( FT_Bool ) raccess_rule_by_darwin_vfs( FT_UInt rule_index ); -#endif /* FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK */ +#endif FT_END_HEADER diff --git a/freetype/src/base/ftbitmap.c b/freetype/src/base/ftbitmap.c index 5e1ab1a97..1f2ada0e4 100644 --- a/freetype/src/base/ftbitmap.c +++ b/freetype/src/base/ftbitmap.c @@ -417,8 +417,8 @@ target->pitch = source->width + pad; - if ( target->pitch > 0 && - target->rows > FT_ULONG_MAX / target->pitch ) + if ( target->pitch > 0 && + (FT_ULong)target->rows > FT_ULONG_MAX / target->pitch ) return FT_Err_Invalid_Argument; if ( target->rows * target->pitch > old_size && diff --git a/freetype/src/base/ftrfork.c b/freetype/src/base/ftrfork.c index c94cdd86d..fbbb3c8e6 100644 --- a/freetype/src/base/ftrfork.c +++ b/freetype/src/base/ftrfork.c @@ -417,6 +417,7 @@ } +#if !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON ) static FT_RFork_Rule raccess_get_rule_type_from_rule_index( FT_UInt rule_index ) { @@ -440,6 +441,7 @@ return FALSE; } } +#endif static FT_Error diff --git a/freetype/src/base/fttype1.c b/freetype/src/base/fttype1.c index d271c0af6..733c6936f 100644 --- a/freetype/src/base/fttype1.c +++ b/freetype/src/base/fttype1.c @@ -4,7 +4,7 @@ /* */ /* FreeType utility file for PS names support (body). */ /* */ -/* Copyright 2002, 2003, 2004 by */ +/* Copyright 2002-2004, 2011 by */ /* David Turner, Robert Wilhelm, and Werner Lemberg. */ /* */ /* This file is part of the FreeType project, and may only be used, */ @@ -91,4 +91,30 @@ } + /* documentation is in t1tables.h */ + + FT_EXPORT_DEF( FT_Long ) + FT_Get_PS_Font_Value( FT_Face face, + PS_Dict_Keys key, + FT_UInt idx, + void *value, + FT_Long value_len ) + { + FT_Int result = 0; + FT_Service_PsInfo service = NULL; + + + if ( face ) + { + FT_FACE_FIND_SERVICE( face, service, POSTSCRIPT_INFO ); + + if ( service && service->ps_get_font_value ) + result = service->ps_get_font_value( face, key, idx, + value, value_len ); + } + + return result; + } + + /* END */ |