diff options
author | David Turner <david@freetype.org> | 2007-07-01 09:51:15 +0000 |
---|---|---|
committer | David Turner <david@freetype.org> | 2007-07-01 09:51:15 +0000 |
commit | 481b25f00969549816b94e5d2d1f7d75d1cd930f (patch) | |
tree | a257c0672b2f6d57132864431132940033a5c0f0 /src/base/ftpatent.c | |
parent | 0ba89912928144811c0294ae5903658c0a33e387 (diff) |
* include/freetype/freetype.h, src/base/ftpatent.c: adding
FT_Face_SetUnpatentedHinting to dynamically change the setting
after a face is created.
Diffstat (limited to 'src/base/ftpatent.c')
-rw-r--r-- | src/base/ftpatent.c | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/src/base/ftpatent.c b/src/base/ftpatent.c index a2bda8fb..f598a3c4 100644 --- a/src/base/ftpatent.c +++ b/src/base/ftpatent.c @@ -246,7 +246,7 @@ { FT_Bool result = FALSE; - + if ( face && FT_IS_SFNT( face ) ) result = _tt_face_check_patents( face ); @@ -254,4 +254,25 @@ } + FT_EXPORT_DEF( FT_Bool ) + FT_Face_SetUnpatentedHinting( FT_Face face, + FT_Bool value ) + { + FT_Bool result = 0; + +#if defined(TT_CONFIG_OPTION_UNPATENTED_HINTING) && \ + !defined(TT_CONFIG_OPTION_BYTECODE_INTEPRETER) + if ( face && FT_IS_SFNT(face) ) + { + result = !face->internal->ignore_unpatented_hinter; + face->internal->ignore_unpatented_hinter = !value; + } +#else + FT_UNUSED(face); + FT_UNUSED(value); +#endif + + return result; + } + /* END */ |