Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/3party
diff options
context:
space:
mode:
authorDarafei Praliaskouski <komzpa@gmail.com>2013-02-22 15:59:45 +0400
committerAlex Zolotarev <alex@maps.me>2015-09-23 01:51:25 +0300
commita57574eadb89117ec348c905c5a78a55ea197107 (patch)
tree9226cf9292225bdc2baabff01c312cca77ac05be /3party
parente18fe9f4cc6531cee399377b044862128f9db174 (diff)
[freetype] Updated to 2.4.11
StrokedImageCache ported to 2.4.11. Disabled winfonts, type1 and type42 due to conflicts on qt/linux. Production build footprint shrinked by ~1mb.
Diffstat (limited to '3party')
-rw-r--r--3party/freetype/ChangeLog2228
-rw-r--r--3party/freetype/Jamfile2
-rw-r--r--3party/freetype/README12
-rwxr-xr-x[-rw-r--r--]3party/freetype/autogen.sh0
-rw-r--r--3party/freetype/builds/exports.mk2
-rw-r--r--3party/freetype/builds/mac/FreeType.m68k_cfm.make.txt1
-rw-r--r--3party/freetype/builds/mac/FreeType.m68k_far.make.txt1
-rw-r--r--3party/freetype/builds/mac/FreeType.ppc_carbon.make.txt1
-rw-r--r--3party/freetype/builds/mac/FreeType.ppc_classic.make.txt1
-rw-r--r--3party/freetype/builds/mac/ftmac.c3
-rw-r--r--3party/freetype/builds/toplevel.mk4
-rw-r--r--3party/freetype/builds/unix/aclocal.m4294
-rwxr-xr-x3party/freetype/builds/unix/config.guess53
-rwxr-xr-x3party/freetype/builds/unix/config.sub66
-rwxr-xr-x3party/freetype/builds/unix/configure663
-rw-r--r--3party/freetype/builds/unix/configure.ac117
-rw-r--r--3party/freetype/builds/unix/configure.raw115
-rw-r--r--3party/freetype/builds/unix/detect.mk1
-rw-r--r--3party/freetype/builds/unix/ftconfig.in7
-rwxr-xr-x3party/freetype/builds/unix/install-sh23
-rw-r--r--[-rwxr-xr-x]3party/freetype/builds/unix/ltmain.sh95
-rw-r--r--3party/freetype/builds/unix/unix-def.in2
-rw-r--r--3party/freetype/builds/vms/ftconfig.h7
-rw-r--r--3party/freetype/builds/win32/vc2005/index.html10
-rw-r--r--3party/freetype/builds/win32/vc2008/index.html10
-rw-r--r--3party/freetype/builds/win32/vc2010/index.html10
-rw-r--r--3party/freetype/builds/win32/visualc/freetype.dsp20
-rw-r--r--3party/freetype/builds/win32/visualc/index.html10
-rw-r--r--3party/freetype/builds/win32/visualce/freetype.dsp20
-rw-r--r--3party/freetype/builds/win32/visualce/index.html10
-rw-r--r--3party/freetype/builds/wince/vc2005-ce/index.html10
-rw-r--r--3party/freetype/builds/wince/vc2008-ce/index.html10
-rwxr-xr-x3party/freetype/configure26
-rw-r--r--3party/freetype/devel/ftoption.h26
-rw-r--r--3party/freetype/docs/CHANGES117
-rw-r--r--3party/freetype/docs/CUSTOMIZE17
-rw-r--r--3party/freetype/docs/INSTALL.CROSS6
-rw-r--r--3party/freetype/docs/VERSION.DLL58
-rw-r--r--3party/freetype/docs/reference/ft2-auto_hinter.html313
-rw-r--r--3party/freetype/docs/reference/ft2-base_interface.html77
-rw-r--r--3party/freetype/docs/reference/ft2-basic_types.html6
-rw-r--r--3party/freetype/docs/reference/ft2-bdf_fonts.html4
-rw-r--r--3party/freetype/docs/reference/ft2-bitmap_handling.html4
-rw-r--r--3party/freetype/docs/reference/ft2-bzip2.html4
-rw-r--r--3party/freetype/docs/reference/ft2-cache_subsystem.html4
-rw-r--r--3party/freetype/docs/reference/ft2-cid_fonts.html4
-rw-r--r--3party/freetype/docs/reference/ft2-computations.html10
-rw-r--r--3party/freetype/docs/reference/ft2-font_formats.html4
-rw-r--r--3party/freetype/docs/reference/ft2-gasp_table.html4
-rw-r--r--3party/freetype/docs/reference/ft2-glyph_management.html4
-rw-r--r--3party/freetype/docs/reference/ft2-glyph_stroker.html6
-rw-r--r--3party/freetype/docs/reference/ft2-glyph_variants.html8
-rw-r--r--3party/freetype/docs/reference/ft2-gx_validation.html4
-rw-r--r--3party/freetype/docs/reference/ft2-gzip.html4
-rw-r--r--3party/freetype/docs/reference/ft2-header_file_macros.html52
-rw-r--r--3party/freetype/docs/reference/ft2-incremental.html4
-rw-r--r--3party/freetype/docs/reference/ft2-index.html506
-rw-r--r--3party/freetype/docs/reference/ft2-lcd_filtering.html4
-rw-r--r--3party/freetype/docs/reference/ft2-list_processing.html4
-rw-r--r--3party/freetype/docs/reference/ft2-lzw.html4
-rw-r--r--3party/freetype/docs/reference/ft2-mac_specific.html4
-rw-r--r--3party/freetype/docs/reference/ft2-module_management.html169
-rw-r--r--3party/freetype/docs/reference/ft2-multiple_masters.html4
-rw-r--r--3party/freetype/docs/reference/ft2-ot_validation.html4
-rw-r--r--3party/freetype/docs/reference/ft2-outline_processing.html48
-rw-r--r--3party/freetype/docs/reference/ft2-pfr_fonts.html4
-rw-r--r--3party/freetype/docs/reference/ft2-quick_advance.html4
-rw-r--r--3party/freetype/docs/reference/ft2-raster.html4
-rw-r--r--3party/freetype/docs/reference/ft2-sfnt_names.html4
-rw-r--r--3party/freetype/docs/reference/ft2-sizes_management.html4
-rw-r--r--3party/freetype/docs/reference/ft2-system_interface.html4
-rw-r--r--3party/freetype/docs/reference/ft2-toc.html24
-rw-r--r--3party/freetype/docs/reference/ft2-truetype_engine.html4
-rw-r--r--3party/freetype/docs/reference/ft2-truetype_tables.html15
-rw-r--r--3party/freetype/docs/reference/ft2-type1_tables.html6
-rw-r--r--3party/freetype/docs/reference/ft2-user_allocation.html4
-rw-r--r--3party/freetype/docs/reference/ft2-version.html6
-rw-r--r--3party/freetype/docs/reference/ft2-winfnt_fonts.html4
-rw-r--r--3party/freetype/docs/release31
-rw-r--r--3party/freetype/freetype.pro22
-rw-r--r--3party/freetype/include/freetype/config/ftconfig.h10
-rw-r--r--3party/freetype/include/freetype/config/ftheader.h15
-rw-r--r--3party/freetype/include/freetype/config/ftmodule.h6
-rw-r--r--3party/freetype/include/freetype/config/ftstdlib.h4
-rw-r--r--3party/freetype/include/freetype/freetype.h167
-rw-r--r--3party/freetype/include/freetype/ftautoh.h349
-rw-r--r--3party/freetype/include/freetype/ftchapters.h14
-rw-r--r--3party/freetype/include/freetype/fterrdef.h6
-rw-r--r--3party/freetype/include/freetype/fterrors.h3
-rw-r--r--3party/freetype/include/freetype/ftgasp.h4
-rw-r--r--3party/freetype/include/freetype/ftmodapi.h161
-rw-r--r--3party/freetype/include/freetype/ftoutln.h24
-rw-r--r--3party/freetype/include/freetype/ftstroke.h40
-rw-r--r--3party/freetype/include/freetype/ftsynth.h7
-rw-r--r--3party/freetype/include/freetype/fttypes.h4
-rw-r--r--3party/freetype/include/freetype/internal/autohint.h81
-rw-r--r--3party/freetype/include/freetype/internal/ftcalc.h8
-rw-r--r--3party/freetype/include/freetype/internal/ftdriver.h383
-rw-r--r--3party/freetype/include/freetype/internal/ftobjs.h855
-rw-r--r--3party/freetype/include/freetype/internal/ftpic.h34
-rw-r--r--3party/freetype/include/freetype/internal/ftrfork.h64
-rw-r--r--3party/freetype/include/freetype/internal/ftserv.h625
-rw-r--r--3party/freetype/include/freetype/internal/fttrace.h5
-rw-r--r--3party/freetype/include/freetype/internal/psaux.h6
-rw-r--r--3party/freetype/include/freetype/internal/pshints.h52
-rw-r--r--3party/freetype/include/freetype/internal/services/svbdf.h23
-rw-r--r--3party/freetype/include/freetype/internal/services/svcid.h48
-rw-r--r--3party/freetype/include/freetype/internal/services/svgldict.h28
-rw-r--r--3party/freetype/include/freetype/internal/services/svmm.h51
-rw-r--r--3party/freetype/include/freetype/internal/services/svpostnm.h32
-rw-r--r--3party/freetype/include/freetype/internal/services/svprop.h81
-rw-r--r--3party/freetype/include/freetype/internal/services/svpscmap.h73
-rw-r--r--3party/freetype/include/freetype/internal/services/svpsinfo.h46
-rw-r--r--3party/freetype/include/freetype/internal/services/svsfnt.h31
-rw-r--r--3party/freetype/include/freetype/internal/services/svttcmap.h37
-rw-r--r--3party/freetype/include/freetype/internal/services/svttglyf.h19
-rw-r--r--3party/freetype/include/freetype/internal/sfnt.h327
-rw-r--r--3party/freetype/include/freetype/internal/tttypes.h6
-rw-r--r--3party/freetype/include/freetype/t1tables.h2
-rw-r--r--3party/freetype/include/freetype/ttnameid.h20
-rw-r--r--3party/freetype/include/freetype/tttables.h18
-rw-r--r--3party/freetype/modules.cfg4
-rw-r--r--3party/freetype/src/autofit/afangles.c65
-rw-r--r--3party/freetype/src/autofit/afcjk.c28
-rw-r--r--3party/freetype/src/autofit/afcjk.h11
-rw-r--r--3party/freetype/src/autofit/afdummy.c5
-rw-r--r--3party/freetype/src/autofit/aferrors.h3
-rw-r--r--3party/freetype/src/autofit/afglobal.c89
-rw-r--r--3party/freetype/src/autofit/afglobal.h46
-rw-r--r--3party/freetype/src/autofit/afhints.c200
-rw-r--r--3party/freetype/src/autofit/afhints.h20
-rw-r--r--3party/freetype/src/autofit/afindic.c14
-rw-r--r--3party/freetype/src/autofit/afindic.h4
-rw-r--r--3party/freetype/src/autofit/aflatin.c361
-rw-r--r--3party/freetype/src/autofit/aflatin.h19
-rw-r--r--3party/freetype/src/autofit/aflatin2.c95
-rw-r--r--3party/freetype/src/autofit/aflatin2.h4
-rw-r--r--3party/freetype/src/autofit/afloader.c64
-rw-r--r--3party/freetype/src/autofit/afloader.h34
-rw-r--r--3party/freetype/src/autofit/afmodule.c213
-rw-r--r--3party/freetype/src/autofit/afmodule.h21
-rw-r--r--3party/freetype/src/autofit/afpic.c53
-rw-r--r--3party/freetype/src/autofit/afpic.h59
-rw-r--r--3party/freetype/src/autofit/aftypes.h40
-rw-r--r--3party/freetype/src/autofit/afwarp.c2
-rw-r--r--3party/freetype/src/base/basepic.c66
-rw-r--r--3party/freetype/src/base/basepic.h21
-rw-r--r--3party/freetype/src/base/ftadvanc.c15
-rw-r--r--3party/freetype/src/base/ftbase.c2
-rw-r--r--3party/freetype/src/base/ftbase.h6
-rw-r--r--3party/freetype/src/base/ftbitmap.c2
-rw-r--r--3party/freetype/src/base/ftcalc.c19
-rw-r--r--3party/freetype/src/base/ftgloadr.c2
-rw-r--r--3party/freetype/src/base/ftglyph.c32
-rw-r--r--3party/freetype/src/base/ftinit.c103
-rw-r--r--3party/freetype/src/base/ftmac.c6
-rw-r--r--3party/freetype/src/base/ftobjs.c197
-rw-r--r--3party/freetype/src/base/ftoutln.c245
-rw-r--r--3party/freetype/src/base/ftpic.c12
-rw-r--r--3party/freetype/src/base/ftrfork.c84
-rw-r--r--3party/freetype/src/base/ftstroke.c11
-rw-r--r--3party/freetype/src/base/ftsynth.c25
-rw-r--r--3party/freetype/src/base/fttrigon.c97
-rw-r--r--3party/freetype/src/bdf/bdf.h8
-rw-r--r--3party/freetype/src/bdf/bdfdrivr.c39
-rw-r--r--3party/freetype/src/bdf/bdfdrivr.h2
-rw-r--r--3party/freetype/src/bdf/bdferror.h3
-rw-r--r--3party/freetype/src/bdf/bdflib.c239
-rw-r--r--3party/freetype/src/bzip2/ftbzip2.c3
-rw-r--r--3party/freetype/src/cache/ftcbasic.c4
-rw-r--r--3party/freetype/src/cache/ftccmap.c7
-rw-r--r--3party/freetype/src/cache/ftcerror.h3
-rw-r--r--3party/freetype/src/cache/ftcmanag.c2
-rw-r--r--3party/freetype/src/cache/ftstrokedcache.c2
-rw-r--r--3party/freetype/src/cff/cffdrivr.c83
-rw-r--r--3party/freetype/src/cff/cfferrs.h3
-rw-r--r--3party/freetype/src/cff/cffgload.c25
-rw-r--r--3party/freetype/src/cff/cffload.c45
-rw-r--r--3party/freetype/src/cff/cffload.h2
-rw-r--r--3party/freetype/src/cff/cffobjs.c63
-rw-r--r--3party/freetype/src/cff/cffparse.c115
-rw-r--r--3party/freetype/src/cff/cffpic.c117
-rw-r--r--3party/freetype/src/cff/cffpic.h85
-rw-r--r--3party/freetype/src/cff/cfftypes.h2
-rw-r--r--3party/freetype/src/cid/ciderrs.h3
-rw-r--r--3party/freetype/src/cid/cidgload.c2
-rw-r--r--3party/freetype/src/cid/cidload.c30
-rw-r--r--3party/freetype/src/cid/cidobjs.c11
-rw-r--r--3party/freetype/src/cid/cidparse.c4
-rw-r--r--3party/freetype/src/cid/cidriver.c12
-rw-r--r--3party/freetype/src/cid/cidriver.h2
-rw-r--r--3party/freetype/src/gxvalid/gxvcommn.c8
-rw-r--r--3party/freetype/src/gxvalid/gxvcommn.h5
-rw-r--r--3party/freetype/src/gxvalid/gxverror.h4
-rw-r--r--3party/freetype/src/gxvalid/gxvfeat.c4
-rw-r--r--3party/freetype/src/gxvalid/gxvmod.c2
-rw-r--r--3party/freetype/src/gxvalid/gxvmod.h2
-rw-r--r--3party/freetype/src/gxvalid/gxvprop.c2
-rw-r--r--3party/freetype/src/gzip/ftgzip.c5
-rw-r--r--3party/freetype/src/lzw/ftlzw.c5
-rw-r--r--3party/freetype/src/otvalid/otverror.h3
-rw-r--r--3party/freetype/src/otvalid/otvmod.c2
-rw-r--r--3party/freetype/src/otvalid/otvmod.h2
-rw-r--r--3party/freetype/src/pcf/pcfdrivr.c15
-rw-r--r--3party/freetype/src/pcf/pcfdrivr.h2
-rw-r--r--3party/freetype/src/pcf/pcferror.h3
-rw-r--r--3party/freetype/src/pcf/pcfread.c6
-rw-r--r--3party/freetype/src/pfr/pfrdrivr.c20
-rw-r--r--3party/freetype/src/pfr/pfrdrivr.h2
-rw-r--r--3party/freetype/src/pfr/pfrerror.h3
-rw-r--r--3party/freetype/src/pfr/pfrobjs.c8
-rw-r--r--3party/freetype/src/psaux/afmparse.c7
-rw-r--r--3party/freetype/src/psaux/psauxerr.h3
-rw-r--r--3party/freetype/src/psaux/psauxmod.c2
-rw-r--r--3party/freetype/src/psaux/psauxmod.h2
-rw-r--r--3party/freetype/src/psaux/psconv.c220
-rw-r--r--3party/freetype/src/psaux/psconv.h10
-rw-r--r--3party/freetype/src/psaux/psobjs.c4
-rw-r--r--3party/freetype/src/psaux/t1cmap.c8
-rw-r--r--3party/freetype/src/psaux/t1decode.c16
-rw-r--r--3party/freetype/src/pshinter/pshalgo.c5
-rw-r--r--3party/freetype/src/pshinter/pshglob.c51
-rw-r--r--3party/freetype/src/pshinter/pshmod.c17
-rw-r--r--3party/freetype/src/pshinter/pshnterr.h3
-rw-r--r--3party/freetype/src/pshinter/pshpic.c30
-rw-r--r--3party/freetype/src/pshinter/pshpic.h24
-rw-r--r--3party/freetype/src/psnames/psmodule.c65
-rw-r--r--3party/freetype/src/psnames/psnamerr.h3
-rw-r--r--3party/freetype/src/psnames/pspic.c58
-rw-r--r--3party/freetype/src/psnames/pspic.h32
-rw-r--r--3party/freetype/src/raster/ftmisc.h21
-rw-r--r--3party/freetype/src/raster/ftraster.c88
-rw-r--r--3party/freetype/src/raster/ftrend1.c13
-rw-r--r--3party/freetype/src/raster/rasterrs.h3
-rw-r--r--3party/freetype/src/raster/rastpic.c43
-rw-r--r--3party/freetype/src/raster/rastpic.h15
-rw-r--r--3party/freetype/src/sfnt/sfdriver.c182
-rw-r--r--3party/freetype/src/sfnt/sferrors.h3
-rw-r--r--3party/freetype/src/sfnt/sfntpic.c126
-rw-r--r--3party/freetype/src/sfnt/sfntpic.h90
-rw-r--r--3party/freetype/src/sfnt/sfobjs.c45
-rw-r--r--3party/freetype/src/sfnt/ttcmap.c333
-rw-r--r--3party/freetype/src/sfnt/ttcmap.h109
-rw-r--r--3party/freetype/src/sfnt/ttcmapc.h19
-rw-r--r--3party/freetype/src/sfnt/ttload.c36
-rw-r--r--3party/freetype/src/sfnt/ttmtx.c4
-rw-r--r--3party/freetype/src/smooth/ftgrays.c131
-rw-r--r--3party/freetype/src/smooth/ftsmerrs.h3
-rw-r--r--3party/freetype/src/smooth/ftsmooth.c81
-rw-r--r--3party/freetype/src/smooth/ftspic.c53
-rw-r--r--3party/freetype/src/smooth/ftspic.h21
-rw-r--r--3party/freetype/src/tools/apinames.c17
-rw-r--r--3party/freetype/src/tools/docmaker/content.py4
-rw-r--r--3party/freetype/src/tools/docmaker/sources.py8
-rw-r--r--3party/freetype/src/truetype/rules.mk5
-rw-r--r--3party/freetype/src/truetype/truetype.c3
-rw-r--r--3party/freetype/src/truetype/ttdriver.c86
-rw-r--r--3party/freetype/src/truetype/tterrors.h3
-rw-r--r--3party/freetype/src/truetype/ttgload.c193
-rw-r--r--3party/freetype/src/truetype/ttgxvar.c59
-rw-r--r--3party/freetype/src/truetype/ttinterp.c1023
-rw-r--r--3party/freetype/src/truetype/ttinterp.h80
-rw-r--r--3party/freetype/src/truetype/ttobjs.c47
-rw-r--r--3party/freetype/src/truetype/ttobjs.h19
-rw-r--r--3party/freetype/src/truetype/ttpic.c62
-rw-r--r--3party/freetype/src/truetype/ttpic.h40
-rw-r--r--3party/freetype/src/truetype/ttpload.c18
-rw-r--r--3party/freetype/src/truetype/ttsubpix.c265
-rw-r--r--3party/freetype/src/truetype/ttsubpix.h908
-rw-r--r--3party/freetype/src/type1/t1afm.c5
-rw-r--r--3party/freetype/src/type1/t1driver.c57
-rw-r--r--3party/freetype/src/type1/t1driver.h2
-rw-r--r--3party/freetype/src/type1/t1errors.h3
-rw-r--r--3party/freetype/src/type1/t1gload.c74
-rw-r--r--3party/freetype/src/type1/t1gload.h10
-rw-r--r--3party/freetype/src/type1/t1load.c112
-rw-r--r--3party/freetype/src/type1/t1objs.c52
-rw-r--r--3party/freetype/src/type1/t1objs.h31
-rw-r--r--3party/freetype/src/type1/t1parse.c31
-rw-r--r--3party/freetype/src/type1/t1tokens.h2
-rw-r--r--3party/freetype/src/type42/t42drivr.c36
-rw-r--r--3party/freetype/src/type42/t42drivr.h2
-rw-r--r--3party/freetype/src/type42/t42error.h3
-rw-r--r--3party/freetype/src/type42/t42objs.c81
-rw-r--r--3party/freetype/src/type42/t42objs.h22
-rw-r--r--3party/freetype/src/type42/t42parse.c12
-rw-r--r--3party/freetype/src/winfonts/fnterrs.h3
-rw-r--r--3party/freetype/src/winfonts/winfnt.c80
-rw-r--r--3party/freetype/src/winfonts/winfnt.h2
289 files changed, 13001 insertions, 5086 deletions
diff --git a/3party/freetype/ChangeLog b/3party/freetype/ChangeLog
index 2aae63dfd0..b5c7d13aa2 100644
--- a/3party/freetype/ChangeLog
+++ b/3party/freetype/ChangeLog
@@ -1,3 +1,2139 @@
+2012-12-20 Werner Lemberg <wl@gnu.org>
+
+ * Version 2.4.11 released.
+ ==========================
+
+
+ Tag sources with `VER-2-4-11'.
+
+ * docs/CHANGES, docs/release: Updated.
+
+ * docs/VERSION.DLL: Update documentation and bump version number to
+ 2.4.11.
+
+ * README, Jamfile (RefDoc),
+ builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
+ builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
+ builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
+ builds/win32/visualc/freetype.dsp,
+ builds/win32/visualc/freetype.vcproj,
+ builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
+ builds/win32/visualce/freetype.vcproj,
+ builds/win32/visualce/index.html,
+ builds/wince/vc2005-ce/freetype.vcproj,
+ builds/wince/vc2005-ce/index.html,
+ builds/wince/vc2008-ce/freetype.vcproj,
+ builds/wince/vc2008-ce/index.html: s/2.4.10/2.4.11/, s/2410/2411/.
+
+ * include/freetype/freetype.h (FREETYPE_PATCH): Set to 10.
+
+ * builds/unix/configure.raw (version_info): Set to 16:0:10.
+
+ * builds/toplevel.mk (dist): Don't include `.mailmap'.
+
+2012-12-20 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [base] Improve trigonometric core.
+
+ FreeType used to rely on a 24-step iteration CORDIC algorithm to
+ calculate trigonometric functions and rotate vectors. It turns out
+ that once the vector is in the right half-plane, the initial rotation
+ by 63 degrees is not necessary. The algorithm is perfectly capable
+ to converge to any angle starting from the second 45 degree rotation.
+ This patch removes the first rotation and makes it a 23-step CORDIC
+ algorithm.
+
+ * src/base/fttrigon.c (FT_TRIG_SCALE, FT_TRIG_COSCALE): Update macro
+ values.
+ (ft_trig_pseudo_rotate, ft_trig_pseudo_polarize): Remove initial
+ rotation.
+
+2012-12-19 Werner Lemberg <wl@gnu.org>
+
+ * src/base/ftobjs.c (ft_property_do): Fix compiler warning.
+
+2012-12-19 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ * src/base/ftrfork.c (FT_Raccess_Guess): Switch to FT_Int counters.
+
+2012-12-19 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [base] Clean up trigonometric core.
+
+ * src/base/fttrrigon.c (ft_trig_pseudo_polarize): Align algorithm
+ with `ft_trig_pseudo_rotate'.
+
+2012-12-18 Infinality <infinality@infinality.net>
+
+ [truetype] Minor performance enhancement.
+
+ * src/truetype/ttgload.c: (TT_Process_Simple_Glyph): Use FT_MulFix
+ instead of FT_MulDiv.
+
+2012-12-17 Infinality <infinality@infinality.net>
+
+ [truetype] Remove unusued code and variables.
+
+ * src/truetype/ttinterp.c: Updated.
+ (Ins_FDEF): Remove opcode patterns that are not being used.
+
+2012-12-16 Werner Lemberg <wl@gnu.org>
+
+ Various compiler warning fixes.
+
+ * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Use
+ `logical not' operator instead of negation. The idea is that `~'
+ returns exactly the data type enforced by the cast to a pointer (be
+ it 32bit or 64bit or whatever), while a negative integer has not
+ this flexibility.
+ * src/cache/ftccmap.c (FTC_CMAP_UNKNOWN): Ditto.
+ * src/truetype/ttgxvar.c (ALL_POINTS, TT_Get_MM_Var): Ditto.
+ * src/type/t1load.c (T1_Get_MM_Var): Ditto.
+ (parse_blend_axis_types): Use cast.
+ * src/bdf/bdflib.c (_bdf_readstream): Use cast.
+
+2012-12-16 Infinality <infinality@infinality.net>
+
+ [truetype] Remove unusued code and variables. Add minor fixes.
+
+ * src/truetype/ttsubpix.h: Updated.
+ (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Trebuchet MS.
+ (ALLOW_X_DMOVEX_Rules): Remove Arial characters.
+ (ALLOW_X_DMOVE_Rules): Remove Arial characters.
+ (RASTERIZER_35_Rules): Verdana no longer needs to be here.
+ (SKIP_IUP_Rules): Formatting fix.
+ (DELTAP_SKIP_EXAGGERATED_VALUES_Rules): Remove Segoe UI.
+ (COMPATIBLE_WIDTHS_Rules): Add Monaco and Trebuchet MS.
+ (X_SCALING_Rules): Add misc. corrective fixes.
+
+ * src/truetype/ttgload.c: (TT_Process_Simple_Glyph): Adjust correction
+ factor for emboldening during scaling.
+
+ * src/truetype/ttinterp.h: Updated.
+ (TT_ExecContextRec): Remove unused variables.
+
+ * src/truetype/ttobjs.h: Updated.
+ (TT_SizeRec): Add ttfautohinted variable.
+
+ * src/truetype/ttinterp.c: Updated.
+ (Ins_FDEF): Rework code to fix bugs and add more detection.
+ (Ins_CALL): Remove unused code.
+ (Ins_LOOPCALL): Remove unused code.
+ (TT_RunIns): Remove unusued code.
+ (Ins_SHPIX): Add logic to handle ttfautohinted fonts.
+ (Ins_MIRP): Don't round x in cut-in calculation. Add logic to handle
+ ttfautohinted fonts.
+
+2012-12-16 Werner Lemberg <wl@gnu.org>
+
+ [sfnt] Fix Savannah bug #37936.
+
+ * src/sfnt/ttload.c (tt_face_load_gasp): Avoid memory leak.
+
+2012-12-15 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [base] Fix 11-year old bug.
+
+ Since the initial commit (ebe85f59) the value of FT_TRIG_SCALE has
+ always been slightly less than the correct value, which has been
+ given in the comment as a hexadecimal. As a result, vector lengths
+ were underestimated and rotated vectors were shortened.
+
+ * src/base/fttrigon.c (FT_TRIG_SCALE): Fix macro value.
+
+2012-12-15 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #37907.
+
+ * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Normalize
+ negative second parameter of `ENCODING' field also.
+
+2012-12-15 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #37906.
+
+ * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Use correct array
+ size for checking `glyph_enc'.
+
+2012-12-15 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #37905.
+
+ * src/bdf/bdflib.c (_bdf_parse_start) <STARTPROPERTIES>: Reset
+ `props_size' to zero in case of allocation error; this value gets
+ used in a loop in `bdf_free_font'.
+
+2012-12-10 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [truetype] Scale F_dot_P down.
+
+ The dot product between freeVector and projVector or cosine of
+ the angle between these FT_F2Dot14 unit vectors used to be scaled up
+ by 4 and routinely occupied 32 bits in an FT_Long field F_dot_P.
+ This patch scales the value down by 2^14 instead, which simplifies
+ its use throughout the bytecode interpreter.
+
+ This does not lead to the loss of precision because the lower bits
+ are unreliable anyway. Consider two unit vectors (1,0) and (.6,.8)
+ for which the true value of F_dot_P is .6 * 0x40000000 = 0x26666666.
+ These vectors are stored as (0x4000,0) and (0x2666,0x3333) after
+ rounding and F_dot_P is assigned 0x26660000. The lower bits were
+ already lost while rounding the unit vector components.
+
+ Besides code simplification, this change can lead to better
+ performance when FT_MulDiv with the scaled-down F_dot_P is less
+ likely to use the costly 64-bit path. We are not changing the type
+ of F_dot_P to FT_F2Dot14 at this point.
+
+ * src/truetype/ttinterp.c (Compute_Funcs): Scale F_dot_P down by 14
+ bits and modify its use accordingly.
+ (Direct_Move, Direct_Move_Orig, Compute_Point_Displacement): Modify
+ the use of F_dot_P field.
+ * src/truetype/ttobjs.c (tt_size_run_fpgm): Change arbitrary
+ assignment of F_dot_P to its theoretical maximum in case we decide
+ to scale back its type later.
+
+2012-12-09 Johnson Y. Yan <yinsen_yan@foxitsoftware.com>
+
+ [type1] Another fix for 2012-09-17 commit.
+
+ * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Correctly set
+ `limit' value.
+
+2012-12-06 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [truetype] Tweak the previous commit.
+
+ * src/truetype/ttinterp.c (Current_Ratio): Put unit vector
+ components as the second TT_MulFix14 arguments. This is required
+ on 16-bit systems.
+
+2012-12-06 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [truetype] Microoptimizations in bytecode interpreter.
+
+ * src/truetype/ttinterp.c (TT_DivFix14): New macro.
+ (Normalize): Use it here.
+ (Current_Ratio): Use TT_MulFix14 instead of FT_MulDiv.
+ (Ins_SHPIX): Cancel out two TT_MulFix14 calls.
+
+2012-12-05 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [truetype] Cosmetic improvement in bytecode interpreter.
+
+ * src/truetype/ttinterp.c: Use explicit calls to FT_MulDiv,
+ FT_MulFix, and FT_DivFix instead of macros.
+
+2012-12-03 John Tytgat <John.Tytgat@esko.com>
+
+ [pshinter] Clamp BlueScale value.
+
+ This is Savannah bug #37856.
+
+ * src/pshinter/pshglob.c (psh_calc_max_height): New function.
+ (psh_globals_new): Use it to limit BlueScale value to
+ `1 / max_of_blue_zone_heights'.
+
+2012-12-01 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [truetype, type1] Revise the use of FT_MulDiv.
+
+ * src/truetype/ttgxvar.c: Updated.
+ * src/truetype/ttobjs.c: Updated.
+ * src/type1/t1load.c: Updated.
+
+2012-11-30 Werner Lemberg <wl@gnu.org>
+
+ [configure] Preserve customized `ftoption.h'.
+
+ Problem reported by Del Merritt <del@alum.mit.edu>.
+
+ * builds/unix/configure.raw <cpp computation of bit length>: Don't
+ remove existing FreeType configuration files.
+
+2012-11-29 John Tytgat <John.Tytgat@esko.com>
+
+ [type1] Fix Savannah bug #37831.
+
+ The bug report also contains a patch.
+
+ * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Really fix
+ change from 2012-09-17.
+
+2012-11-28 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [truetype] Fix formatting and typo.
+
+2012-11-27 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [cid, type1, type42] Clean up units_per_EM calculations.
+
+ * src/cid/cidload.c (cid_parse_font_matrix): Updated.
+ * src/type1/t1load.c (t1_parse_font_matrix): Updated.
+ * src/type42/t42parse.c (t42_parse_font_matrix): Updated.
+
+2012-11-27 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [ftstroke] Minor improvement.
+
+ * src/base/ftstroke.c: Replace nested FT_DivFix and FT_MulFix with
+ FT_MulDiv.
+
+2012-11-17 Werner Lemberg <wl@gnu.org>
+
+ * src/base/fttrigon.c (ft_trig_downscale): Make 64bit version work.
+
+2012-11-15 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [base] Fix integer overflows in dd5718c7d67a.
+
+ * src/base/ftoutln.c (FT_Outline_EmboldenXY): Use FT_MulDiv.
+
+2012-11-15 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Trace stem widths.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_widths): Add some
+ FT_TRACE calls.
+
+2012-11-13 Werner Lemberg <wl@gnu.org>
+
+ [cff] Add support for OpenType Collections (OTC).
+
+ * src/cff/cffload.c (cff_font_load): Separate subfont and face
+ index handling to load both pure CFFs with multiple subfonts and
+ OTCs (with multiple faces where each face holds exactly one
+ subfont).
+ * src/cff/cffobjs.c (cff_face_init): Updated.
+
+2012-11-12 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Minor improvement.
+
+ * src/autofit/aflatin.c (af_latin_hints_compute_blue_edges): Fix
+ loop.
+
+2012-11-10 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Improve tracing.
+
+ * src/autofit/aflatin.c (af_latin_hint_edges)
+ [FT_DEBUG_LEVEL_TRACE]: Count number of actions and emit something
+ if there weren't any.
+
+2012-11-04 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [base] Fortify emboldening code against egregious distortions.
+
+ * src/base/ftoutln.c (FT_Outline_EmboldenXY): Threshold emboldening
+ strength when it leads to segment collapse.
+
+2012-11-03 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [base] Clean up emboldening code and improve comments there.
+
+ * src/base/ftoutln.c (FT_Outline_EmboldenXY): Replace sequential
+ calls to FT_MulFix and FT_DivFix with FT_MulDiv.
+ Mention that bisectors are used to figure out the shift direction.
+
+2012-10-24 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Add standard character to `AF_ScriptClassRec' structure.
+
+ * src/autofit/aftypes.h (AF_ScriptClassRec): Add `standard_char'
+ member.
+ (AF_DEFINE_SCRIPT_CLASS): Updated.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_widths): Use it.
+ (af_latin_metrics_init, af_latin_script_class): Updated.
+
+ * src/autofit/aflatin.c (af_latin2_metrics_init_widths): Use it.
+ (af_latin2_metrics_init, af_latin2_script_class): Updated.
+
+ * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Use it.
+ (af_cjk_metrics_init, af_cjk_script_class): Updated.
+
+ * src/autofit/afindic.c (af_indic_metrics_init,
+ af_indic_script_class): Updated.
+
+ * src/autofit/afcjk.h, src/autofit/aflatin.h: Updated.
+
+ * src/autofit/afdummy.c: Updated.
+
+2012-10-24 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Only use Unicode CMap.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init): Implement it, to be
+ in sync with `af_face_globals_compute_script_coverage'.
+
+2012-10-21 Werner Lemberg <wl@gnu.org>
+
+ [psaux] Improve parsing of invalid numbers.
+
+ * src/psaux/psconv.c (PS_Conv_Strtol): Always parse complete number,
+ even in case of overflow.
+ (PS_Conv_ToInt): Only increase cursor if parsing was successful.
+ (PS_Conv_ToFixed): Ditto.
+ Trace underflow and data error.
+
+2012-10-21 Werner Lemberg <wl@gnu.org>
+
+ [smooth] Improve tracing.
+
+ * src/smooth/ftgrays.c (gray_sweep): Trace last sweep line of
+ current band also.
+
+2012-10-20 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [truetype] Cheaper way to threshold angles between vectors.
+
+ * src/truetype/ttinterp.c (Ins_ISECT): Thresholding tangent is a lot
+ cheaper than thresholding sine.
+
+2012-10-20 Werner Lemberg <wl@gnu.org>
+
+ [cff] Improve parsing of invalid real numbers.
+
+ * src/cff/cffparse.c (cff_parse_real): Always parse complete number,
+ even in case of overflow or underflow.
+ Also trace one more underflow.
+
+2012-10-20 Andreas Pehnack <andreas.pehnack@me.com>
+
+ [sfnt] Load pure CFF fonts wrapped in SFNT container.
+
+ Such fonts only have a `cmap' and a `CFF' table.
+
+ * src/sfnt/ttload.c (tt_face_load_font_dir): Don't call
+ `check_table_dir' if font signature is `OTTO'.
+
+2012-10-20 Werner Lemberg <wl@gnu.org>
+
+ [psaux] Fix some value overflows and improve tracing.
+
+ * src/psaux/psconv.c: Include FT_INTERNAL_DEBUG_H.
+ (FT_COMPONENT): Define.
+ (PS_Conv_Strtol): Return FT_Long.
+ Handle bad data and overflow.
+ Emit some tracing messages in case of error.
+ (PS_Conv_ToInt): Return FT_Long.
+ (PS_Conv_ToFixed): Updated.
+ * src/psaux/psconv.h: Updated.
+
+ * include/freetype/internal/fttrace.h: Add `psconv'.
+
+2012-10-20 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Fix `make multi CC=c++'.
+
+ * src/autofit/aflatin.c, src/autofit/aflatin2.c: Include
+ `afglobal.h'.
+ * src/autofit/afloader.c: Fix order of header files.
+ * src/autofit/afmodule.c: Include `afglobal.h' and `aferrors.h'.
+
+2012-10-19 Werner Lemberg <wl@gnu.org>
+
+ [cff] Fix more value errors and improve tracing.
+
+ * src/cff/cffparse.c (cff_parse_integer): Emit tracing message in
+ case of error.
+ (cff_parse_real): Handle and trace overflow, underflow, and bad data
+ consistently.
+ (do_fixed): New helper function, handling and tracing overflow.
+ (cff_parse_fixed, cff_parse_fixed_scaled): Use `do_fixed'.
+
+2012-10-17 Werner Lemberg <wl@gnu.org>
+
+ [psaux] Fix some value overflows.
+
+ * src/psaux/psconv.c (PS_Conv_ToFixed): Implement it.
+
+2012-10-17 Bram Tassyns <BramT@enfocus.com>
+
+ [cff] Fix value overflow.
+
+ * src/cff/cffparse.c (cff_parse_fixed_scaled): Implement it.
+
+2012-10-17 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix Savannah bug #37572.
+
+ * src/truetype/ttinterp.c (Ins_ISECT): Use angle between vectors to
+ avoid grazing intersections. The previous threshold was too coarse,
+ incorrectly rejecting short but valid vectors.
+
+2012-09-30 Gilles Espinasse <g.esp@free.fr>
+
+ Remove useless `rm' detection.
+
+ `rm -f' is directly used in the `configure' script created by
+ autoconf, thus no availability test is necessary.
+
+ * builds/unix/configure.raw (RMF): Remove test.
+ * builds/unix/unix-def.in (DELETE): Updated.
+
+2012-09-29 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Minor optimization.
+
+ * src/autofit/afglobals.c (af_face_globals_compute_script_coverage):
+ Add loop condition.
+
+2012-09-29 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Fix thinko.
+
+ * src/autofit/aftypes.h (AF_SCRIPT):
+ s/AF_SCRIPT_NONE/AF_SCRIPT_DUMMY/. We already use `AF_SCRIPT_NONE'
+ as a bit mask.
+
+ * src/autofit/afdummy.c: Updated.
+
+2012-09-18 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Implement `increase-x-height' property.
+
+ * include/freetype/ftautoh.h (FT_Prop_IncreaseXHeight): New
+ structure.
+
+ * include/autofit/afmodule.c (af_property_get_face_globals): New
+ function, re-using code from `af_property_get'.
+ (af_property_set, af_property_get): Handle `increase-x-height'.
+ Updated.
+
+2012-09-18 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Implement Infinality's `increase glyph heights'.
+
+ This is an improved version of a similar fix contained in the
+ so-called `Infinality patch', taken from
+
+ http://www.infinality.net/fedora/linux/zips/freetype-infinality-2.4.10-20120616_01-x86_64.tar.bz2
+
+ which addresses various enhancements of the auto-hinter. Without
+ properties to control a module's metadata it wasn't possible to
+ adapt the patches because everything was originally controlled by
+ environment variables which I consider not suitable in general.
+
+ A patch to control `increase_x_height' follows.
+
+ * src/autofit/afglobal.h (AF_PROP_INCREASE_X_HEIGHT_MIN,
+ AF_PROP_INCREASE_X_HEIGHT_MAX): New macros.
+ (AF_FaceGlobalsRec): Add `increase_x_height' member.
+ * src/autofit/afglobal.c (af_face_globals_new): Initialize it.
+
+ * src/autofit/aflatin.c (af_latin_metrics_scale_dim),
+ * src/autofit/aflatin2.c (af_latin2_metrics_scale_dim): Implement
+ handling of `increase_x_height'.
+
+2012-09-18 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Add hierarchical property access to some structures.
+
+ * src/autofit/afglobal.h: Include `afmodule.h'.
+ (AF_FaceGlobalsRec): Add `module' member.
+ (AF_FaceGlobals): Typedef moved to...
+ * src/autofit/aftypes.h: Here.
+ (AF_ScriptMetricsRec): Add `globals' member.
+
+ * src/autofit/afglobal.c (af_face_globals_new,
+ af_face_globals_compute_script_coverage,
+ af_face_globals_get_metrics): Updated.
+
+ * src/autofit/afloader.c (af_loader_reset), src/autofit/afmodule.c
+ (af_property_get): Updated.
+
+2012-09-17 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #37350.
+
+ * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Check for ASCII
+ storage only if we actually have at least four bytes.
+
+2012-09-15 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Implement `fallback-script' property.
+
+ * src/autofit/afglobal.c: s/default_script/fallback_script/.
+ * src/autofit/afglobal.h: s/AF_SCRIPT_DEFAULT/AF_SCRIPT_FALLBACK/.
+
+ * src/autofit/afmodule.c: s/default_script/fallback_script/.
+ (af_property_set, af_property_get): Implement `fallback-script'.
+ * src/autofit/afmodule.h: s/default_script/fallback_script/.
+
+ * include/freetype/ftautoh.h: Document it.
+
+2012-09-15 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Correct previous Unicode 6.1.0 change.
+
+ The auto-hinter's latin module only handles latin ligatures in the
+ `Alphabetical Presentation Forms' block.
+
+ * src/autofit/aflatin.c (af_latin_uniranges): Fix it.
+
+2012-09-15 Werner Lemberg <wl@gnu.org>
+
+ * src/autofit/afmodule.c: s/FT_Err_/AF_Err_/.
+
+2012-09-15 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Make default script a global property.
+
+ * src/autofit/afmodule.h (AF_ModuleRec): Add `default_script' field.
+
+ * src/autofit/afglobal.c (af_face_globals_compute_script_coverage,
+ af_face_globals_new), src/autofit/afloader.c (af_loader_reset),
+ src/autofit/afmodule.c (af_property_get) <glyph-to-script-map>,
+ af_autofitter_init:
+ Handle default script.
+
+ * src/autofit/afglobal.h: Updated.
+
+2012-09-15 Werner Lemberg <wl@gnu.org>
+
+ Use `FT_Module' instead of `FT_Library' argument in property funcs.
+
+ This internal change simplifies access to global module data.
+
+ * include/freetype/internal/services/svprop.h
+ (FT_Properties_SetFunc, FT_Properties_GetFunc): Change accordingly.
+
+ * src/base/ftobjs.c (ft_property_do), src/autofit/afmodule.c
+ (af_property_set, af_property_get): Updated.
+
+2012-09-14 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Update to Unicode 6.1.0.
+
+ * src/autofit/afcjk.c (af_cjk_uniranges), src/autofit/aflatin.c
+ (af_latin_uniranges): Add and fix ranges.
+
+2012-09-14 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Pass `AF_Module' instead of `AF_Loader'.
+
+ We want to access the (not yet existing) module's global data later
+ on.
+
+ * src/autofit/afloader.c: Include `afmodule.h'.
+ (af_loader_init, af_loader_reset, af_loader_done,
+ af_loader_load_glyph): Change accordingly.
+ * src/autofit/afmodule.c (AF_ModuleRec): Move to `afmodule.h'.
+ Updated.
+
+ * src/autofit/afmodule.h: Include `afloader.h'.
+ (AF_ModuleRec): Define here.
+ * src/autofit/afloader.h (AF_Module): Define here.
+ Updated.
+
+2012-09-14 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Fix `make multi'.
+
+ * include/freetype/internal/fttrace.h: Add `afmodule'.
+ * src/autofit/afmodule.c: Include FT_INTERNAL_DEBUG_H.
+ (FT_COMPONENT): Define.
+
+2012-09-14 Werner Lemberg <wl@gnu.org>
+
+ * src/autofit/afmodule.c: s/FT_Autofitter/AF_Module/.
+
+2012-09-12 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Minor reorganization.
+
+ * src/autofit/afglobal.c (AF_SCRIPT_LIST_DEFAULT,
+ AF_SCRIPT_LIST_NONE, AF_DIGIT): Move to...
+ * src/autofit/afglobal.h (AF_SCRIPT_DEFAULT, AF_SCRIPT_LIST_NONE,
+ AF_DIGIT): This and update code.
+
+2012-09-01 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Implement `glyph-to-script-map' property.
+
+ * include/freetype/ftautoh.h: New public header file.
+ * include/freetype/config/ftheader.h (FT_AUTOHINTER_H): New macro.
+
+ * src/autofit/afglobal.c (AF_FaceGlobalsRec): Move structure to...
+ * src/autofit/afglobal.h: This header file.
+ * src/autofit/afmodule.c: Include FT_AUTOHINTER_H.
+ (af_property_get): Handle `glyph-to-script-map'.
+
+2012-08-31 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Implement properties service framework.
+
+ No properties are added yet.
+
+ * src/autofit/afmodule.c: Include FT_SERVICE_PROPERTIES_H.
+ (af_property_set, af_property_get): New dummy functions.
+ (af_service_properties, af_services, af_get_interface): Provide
+ service setup.
+ (autofit_moduleclass): Add service interface.
+
+ * src/autofit/afpic.c: Add necessary forward declarations.
+ (autofit_module_class_pic_init): Add code for service addition.
+ (autofit_module_pic_free): Add code for service removal.
+ * src/autofit/afpic.h (AF_SERVICES_GET, AF_SERVICE_PROPERTIES_GET):
+ New macros which provide necessary syntactical sugar for PIC
+ support.
+
+2012-08-30 Werner Lemberg <wl@gnu.org>
+
+ Implement properties to control FreeType modules.
+
+ * include/freetype/fterrdef.h (FT_Err_Missing_Property): New error
+ code.
+ * include/freetype/ftmodapi.h (FT_Property_Set, FT_Property_Get):
+ New API.
+
+ * include/freetype/internal/services/svprop.h: New file.
+ * include/freetype/internal/ftserv.h (FT_SERVICE_PROPERTIES_H): New
+ macro.
+
+ * src/base/ftobjs.c: Include FT_SERVICE_PROPERTIES_H.
+ (ft_property_do, FT_Property_Set, FT_Property_Get): New functions.
+
+2012-08-29 Werner Lemberg <wl@gnu.org>
+
+ [docmaker] Allow `-' in tags and identifiers.
+
+ * src/tools/docmaker/content.py (re_identifier),
+ src/tools/docmaker/sources.py (re_markup_tag1, re_markup_tag2,
+ re_crossref): Add `-' in patterns.
+
+2012-08-27 Werner Lemberg <wl@gnu.org>
+
+ [FT_CONFIG_OPTION_PIC] Fix g++ 4.6.2 compiler warnings.
+
+ * include/freetype/internal/ftdriver.h (FT_DEFINE_DRIVER),
+ include/freetype/internal/ftobjs.h (FT_DEFINE_RENDERER,
+ FT_DEFINE_MODULE), include/freetype/internal/ftserv.h
+ (FT_DEFINE_SERVICEDESCREC1, FT_DEFINE_SERVICEDESCREC2,
+ FT_DEFINE_SERVICEDESCREC3, FT_DEFINE_SERVICEDESCREC4,
+ FT_DEFINE_SERVICEDESCREC5, FT_DEFINE_SERVICEDESCREC6),
+ src/autofit/afpic.c (autofit_module_class_pic_init),
+ src/base/basepic.c (ft_base_pic_init), src/base/ftinit.c
+ (ft_create_default_module_classes), src/cff/cffparse.c
+ (FT_Create_Class_cff_field_handlers), src/cff/cffpic.c
+ (cff_driver_class_pic_init), src/pshinter/pshpic.c
+ (pshinter_module_class_pic_init), src/psnames/pspic.c
+ (psnames_module_class_pic_init), src/raster/rastpic.c
+ (ft_raster1_renderer_class_pic_init), src/sfnt/sfntpic.c
+ (sfnt_module_class_pic_init), src/sfnt/ttcmap.c
+ (FT_Create_Class_tt_cmap_classes), src/smooth/ftspic.c
+ (ft_smooth_renderer_class_pic_init), src/truetype/ttpic.c
+ (tt_driver_class_pic_init): Initialize allocation variable.
+
+2012-08-27 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix compilation warning.
+
+ * src/truetype/ttgload.c (IS_HINTED): Move macro to...
+ * src/truetype/ttobjs.h: This header file.
+
+2012-08-27 Werner Lemberg <wl@gnu.org>
+
+ [autofit, cff, pshinter, psnames] More renamings for orthogonality.
+
+ * src/autofit/afmodule.c, src/autofit/afpic.h:
+ s/AF_AUTOFITTER_/AF_/.
+
+ * src/cff/cffdrivr.c, src/cff/cffobjs.c, src/cff/cffparse.c,
+ src/cff/cffpic.h: s/FT_CFF_/CFF_/.
+
+ * src/pshinter/pshmod.c, src/pshinter/pshpic.h:
+ s/FT_PSHINTER_/PSHINTER_/.
+
+ * src/psnames/psmodule.c, src/psnames/pspic.h:
+ s/FT_PSCMAPS/PSCMAPS_/.
+
+2012-08-27 Werner Lemberg <wl@gnu.org>
+
+ [sfnt, truetype] More renamings for orthogonality.
+
+ * src/sfnt/sfdriver.c, src/sfnt/sfntpic.h, src/sfnt/ttcmap.c,
+ src/truetype/ttdriver.c, src/truetype/ttpic.h: s/FT_SFNT_/SFNT_/,
+ s/FT_TT_/TT_/, s/GET_CMAP_INFO_GET/CMAP_INFO_GET/.
+
+2012-08-27 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Some macro and variable renamings for orthogonality.
+
+ * include/freetype/internal/autohint.h, src/base/ftobjs.c,
+ src/autofit/afmodule.c, src/autofit/afpic.c, src/autofit/afpic.h:
+ s/SERVICE/INTERFACE/, s/service/interface/, s/Service/Interface/.
+
+2012-08-26 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #37178.
+
+ * src/base/ftobjs.c (FT_Open_Face): Initialize `error' with
+ `FT_Err_Missing_Module' before loop to indicate `no valid drivers'.
+
+2012-08-17 Werner Lemberg <wl@gnu.org>
+
+ * src/base/ftsynth.c (FT_GlyphSlot_Oblique): Fix shear angle.
+
+ The old value was far too large (more than 20°). The new one
+ corresponds to 12°, quite common in typography.
+
+2012-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [smooth] Fix Savannah bug #37017.
+
+ * src/smooth/ftgrays.c (gray_render_cubic): Use a different set of
+ checks when detecting super curvy splines to be split.
+
+2012-08-05 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Improve recognition of flat segments.
+
+ Problem reported by Brad Dunzer <BDunzer@extensis.com>.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_blues): We have
+ a flat segment if the horizontal distance of best on-points is
+ larger than a given threshold.
+
+2012-08-05 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Variable renamings.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_blues): Replace
+ `glyph' with `outline'.
+ s/best_first/best_contour_first/.
+ s/best_last/best_contour_last/.
+
+2012-07-31 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #37000.
+
+ * src/type1/t1load.c (parse_encoding): Fix order of checks.
+
+2012-07-17 Werner Lemberg <wl@gnu.org>
+
+ [psaux] Fix Savannah bug #36833.
+
+ * src/psaux/t1decode.c (t1operator_seac): `seac' is not a valid
+ operator if we want metrics only.
+
+2012-07-16 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #36832.
+
+ * src/type1/t1load.c (parse_charstrings): Reject negative number of
+ glyphs.
+
+2012-07-13 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #36829.
+
+ * src/type1/t1load.c (parse_encoding): Check cursor position after
+ call to T1_Skip_PS_Token.
+
+2012-07-12 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ Revert the last commit 45337b07.
+
+ * src/base/ftstroke.c (FT_Stroker_New): Revert the previous change.
+
+2012-07-11 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [ftstroke] Fix uninitialized return value.
+
+ * src/base/ftstroke.c (FT_Stroker_New): Return FT_Err_Ok instead.
+
+2012-07-11 Werner Lemberg <wl@gnu.org>
+
+ [smooth] Avoid memory leak in case of failure.
+
+ * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use flags to
+ indicate what to clean up after finishing the function, with and
+ without errors.
+
+2012-07-09 Werner Lemberg <wl@gnu.org>
+
+ Fix compilation with MSVC 5.0.
+
+ Problem reported by Peter Breitenlohner and Akira Kakuto.
+
+ * include/freetype/config/ftstdlib.h (ft_setjmp): Updated.
+ * src/sfnt/ttcmap.c (tt_face_build_cmaps): Remove cast.
+
+2012-07-09 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Improve debugging messages; do some code cleanup.
+
+ * src/autofit/aflatin.c (af_latin_align_linked_edge,
+ af_latin_hint_edges): Synchronize with formatting used in the
+ ttfautohint project.
+
+2012-07-07 Gilles Espinasse <g.esp@free.fr>
+
+ Fix strict-aliasing warning.
+
+ * src/base/ftglyph.c (FT_Glyph_To_Bitmap): Avoid double cast.
+
+2012-07-07 Dave Thomas <dave.thomas@metaforic.com>
+
+ [ARM] Fix FT_MulFix_arm.
+
+ * include/freetype/config/ftconfig.h (FT_MulFix_arm) [__arm__]:
+ Avoid ADDS instruction to clobber condition codes.
+
+2012-07-06 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Do some code cleanup.
+
+ * src/autofit/afglobal.c (af_face_globals_new): Simplify.
+
+ * src/autofit/afhints.c: Use `FT_TRACE7' instead of `printf'
+ everywhere.
+ (FT_COMPONENT): New macro.
+ (af_glyph_hints_done): Simplify.
+
+ * include/freetype/internal/fttrace.h: Updated.
+
+2012-07-05 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Improve output of debugging information.
+
+ * src/autofit/afhints.c (af_glyph_hints_dump_segments): Print more
+ data; report no data.
+ (af_glyph_hints_dump_edges): Report no data.
+
+2012-07-04 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Fix Savannah bug #36091.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_blues),
+ src/autofit/aflatin2.c (af_latin2_metrics_init_blues): Change the
+ constraint for testing round vs. flat segment: Accept either a
+ small distance or a small angle.
+
+2012-07-04 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Beautify blue zone tracing.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_blues),
+ src/autofit/aflatin2.c (af_latin2_metrics_init_blues): Implement it.
+
+2012-07-03 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Quantize stem widths.
+
+ * src/autofit/afangles.c (af_sort_widths): Rename to...
+ (af_sort_and_quantize_widths): This.
+ Add code to avoid stem widths which are almost identical.
+ * src/autofit/aftypes.h, src/autofit/aflatin.c, src/autofit/afcjk.c:
+ Updated.
+
+2012-07-03 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Minor speed-up.
+
+ * src/autofit/afangles (af_sort_pos, af_sort_widths): Don't swap
+ elements if they are equal.
+
+2012-06-30 Gilles Espinasse <g.esp@free.fr>
+
+ Fix `checking if gcc static flag -static works' test.
+
+ On my linux build tree, I receive yes answer in in every package I
+ build except freetype for this test checking if gcc static flag
+ `-static' works
+
+ On freetype, no is received, unless bzip2 and zlib are disabled using
+
+ ./configure --without-bzip2 --without-zlib
+
+ The reason is that bzip2 and zlib tests add `-lz' and `-lbz2' to
+ LDFLAGS and this broke static flag test.
+
+ * builds/unix/configure.raw: Update CFLAGS and LDFLAGS only after
+ LT_INIT has run.
+
+2012-06-28 Infinality <infinality@infinality.net>
+
+ [truetype] Fix various artifacts.
+
+ Verdana was broken in the original Infinality commit. Also
+ includes other minor fixes.
+
+ * src/truetype/ttsubpix.h: Updated. Removed unused macros.
+ (RASTERIZER_35_Rules): Add Verdana.
+ (SKIP_NONPIXEL_Y_MOVES_Rules): Add Tahoma `s'.
+ (MIRP_CVT_ZERO_Rules): Remove Verdana.
+ (ALWAYS_SKIP_DELTAP_Rules): Add Russian char 0x438.
+ (COMPATIBLE_WIDTHS_Rules): Rearrange some rules.
+ (X_SCALING_Rules): Adjust Verdana `a' at 12 and 13 ppem.
+
+ * src/truetype/ttsubpix.c: Updated.
+ (sph_set_tweaks): Re-execute fpgm always.
+
+2012-06-28 Gilles Espinasse <g.esp@free.fr>
+
+ Fix CFLAGS and LDFLAGS share configure test.
+
+ * builds/unix/configure.raw: Fix typo.
+
+2012-06-28 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Set the `subpixel_positioned' flag unconditionally.
+
+ This is how the code currently behaves.
+
+ * src/truetype/ttgload.c (tt_loader_init): Do it.
+
+2012-06-27 Werner Lemberg <wl@gnu.org>
+
+ Fix conditional compilation.
+
+ * src/base/basepic.c: Use FT_CONFIG_OPTION_MAC_FONTS.
+
+2012-06-27 Werner Lemberg <wl@gnu.org>
+
+ Fix conditional compilation.
+
+ * include/freetype/internal/ftcalc.h (FT_MulDiv_No_Round): Don't
+ enclose with `TT_USE_BYTECODE_INTERPRETER'; we now need the function
+ elsewhere also.
+
+ * src/autofit/afcjk.h: Use AF_CONFIG_OPTION_CJK.
+
+ * src/truetype/ttgload.c (tt_loader_init): Fix compiler warning.
+
+ * src/truetype/ttinterp.c (Ins_MSIRP): Fix compiler warning.
+
+ * src/truetype/ttinterp.h: Use
+ TT_CONFIG_OPTION_BYTECODE_INTERPRETER.
+
+2012-06-26 Infinality <infinality@infinality.net>
+
+ [truetype] Remove unused rounding functionality.
+
+ The subpixel hinting patch contained the concept of an adjustable
+ number of gridlines per pixel. This is no longer used due to x
+ being completely ignored instead. This will return some of the
+ code to its existing state prior to the original Infinality
+ commit.
+
+ * include/freetype/internal/ftobjs.h (FT_PIX_FLOOR_GRID,
+ FT_PIX_ROUND_GRID, FT_PIX_CEIL_GRID): Removed.
+
+ * src/truetype/ttinterp.c: Updated.
+ (Round_None, Round_To_Grid, Round_To_Half_Grid, Round_Down_To_Grid,
+ Round_Up_To_Grid, Round_To_Double_Grid, Round_Super, Round_Super_45,
+ SetSuperRound): Remove parameter to handle the number of grid lines per
+ pixel.
+ (SET_SuperRound, ROUND_None, CUR_Func_round): Updated.
+ (DO_SROUND, DOS45ROUND, DO_ODD, DO_EVEN): Updated.
+ (DO_ROUND, DO_NROUND): Updated.
+ (Move_Zp2_Point, Ins_SHPIX, Ins_MSIRP, Ins_MDAP, Ins_MIAP,
+ Ins_MDRP, Ins_MIRP): Perform Round_None instead of calling a modified
+ rounding function. Remove gridlines_per_pixel. Create a local
+ variable to store control value cutin. Simplify the conditional for
+ ignore_x_mode. Adjust rounding calls to pass only two values.
+
+2012-06-25 Werner Lemberg <wl@gnu.org>
+
+ [cff] Fix Savannah bug #36705.
+
+ Handle numbers like 2.001 correctly.
+
+ * src/cff/cffparse.c (cff_parse_real): Avoid negative values for
+ `shift'.
+
+2012-06-18 Infinality <infinality@infinality.net>
+
+ [truetype] Support subpixel hinting.
+
+ This is the large, famous `Infinality' patch to support ClearType
+ bytecode which has been available from
+ http://www.infinality.net/blog/ for some time, and which has been
+ refined over the last years. While still experimental, it is now
+ mature enough to be included directly into FreeType.
+
+ Most of the code is based on the ClearType whitepaper written by
+ Greg Hitchcock
+
+ http://www.microsoft.com/typography/cleartype/truetypecleartype.aspx
+
+ which gives a detailed overview of the necessary changes to the
+ Microsoft rasterizer so that older fonts are supported. However, a
+ lot of details are still missing, and this patches provides a
+ framework to easily handle rendering issues down to the glyph level
+ of certain fonts.
+
+ Note that ClearType support is not completely implemented! In
+ particular, full support for the options `compatible_widths',
+ `symmetrical_smoothing, and `bgr' (via the GETINFO bytecode
+ instruction) is missing.
+
+ * src/truetype/ttsubpix.c: New file, providing code to handle
+ `tweaks', this is, rules for certain glyphs in certain fonts
+ (including wildcards) which need a special treatment.
+
+ * src/truetype/ttsubpix.h: New file, holding the tweaking rules.
+
+ * include/freetype/config/ftoption.h, src/devel/ftoption.h
+ (TT_CONFIG_OPTION_SUBPIXEL_HINTING): New macro.
+
+ * include/freetype/internal/ftobjs.h (FT_PIX_FLOOR_GRID,
+ FT_PIX_ROUND_GRID, FT_PIX_CEIL_GRID): New macros.
+
+ * src/truetype/truetype.c [TT_USE_BYTECODE_INTERPRETER]: Include
+ `ttsubpix.c'.
+
+ * src/truetype/ttgload.c: Include `ttsubpix.h'.
+ [All changes below are guarded by TT_CONFIG_OPTION_SUBPIXEL_HINTING.]
+
+ (tt_get_metrics): Set tweak flags.
+ (TT_Hint_Glyph): Call `FT_Outline_EmboldenXY' if necessary.
+ (TT_Process_Simple_Glyph): Compensate emboldening if necessary.
+ (compute_glyph_metrics): Handle `compatible widths' option.
+ (tt_loader_init): Handle ClearType GETINFO information bits.
+
+ * src/truetype/rules.mk (TT_DRC_SRC): Updated.
+
+ * src/truetype/ttinterp.c: Include `ttsubpix.h'.
+ [Where necessary, changes below are guarded by
+ TT_CONFIG_OPTION_SUBPIXEL_HINTING.]
+
+ (Direct_Move, Direct_Move_X): Extended.
+ (Round_None, Round_To_Grid, Round_To_Half_Grid, Round_Down_To_Grid,
+ Round_Up_To_Grid, Round_To_Double_Grid, Round_Super, Round_Super_45,
+ SetSuperRound): Add parameter to handle the number of grid lines per
+ pixel.
+ (SET_SuperRound, ROUND_None, CUR_Func_round): Updated.
+ (DO_SROUND, DOS45ROUND, DO_ODD, DO_EVEN): Updated.
+ (DO_ROUND, DO_NROUND): Updated.
+ (DO_RS): Take care of `Typeman' bytecode patterns.
+ (Ins_FDEF): Add some debugging code. Commented out.
+ (Ins_ENDF): Restore state.
+ (Ins_CALL, Ins_LOOPCALL): Handle inline delta functions.
+ (Ins_MD): Handle `Vacuform' rounds.
+ (Move_Zp2_Point, Ins_SHPIX, Ins_MSIRP, Ins_MDAP, Ins_MIAP,
+ Ins_MDRP, Ins_MIRP): Handle tweaks.
+ (Ins_ALIGNRP): Add tweak guard.
+ (Ins_IUP, Ins_DELTAP): Handle tweaks.
+ (Ins_GETINFO): Handle new ClearType bits.
+ (TT_RunIns): Handle tweaks.
+
+ * src/truetype/ttinterp.h: Updated.
+ (SPH_TweakRule, SPH_ScaleRule): New structures for tweaks.
+ (TT_ExecContextRec): Add members for subpixel hinting support.
+
+ * src/truetype/ttobjs.h (TT_DefRecord): Add `inline_delta' member.
+
+2012-06-15 Werner Lemberg <wl@gnu.org>
+
+ * Version 2.4.10 released.
+ =========================
+
+
+ Tag sources with `VER-2-4-10'.
+
+ * docs/VERSION.DLL: Update documentation and bump version number to
+ 2.4.10.
+
+ * README, Jamfile (RefDoc),
+ builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
+ builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
+ builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
+ builds/win32/visualc/freetype.dsp,
+ builds/win32/visualc/freetype.vcproj,
+ builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
+ builds/win32/visualce/freetype.vcproj,
+ builds/win32/visualce/index.html,
+ builds/wince/vc2005-ce/freetype.vcproj,
+ builds/wince/vc2005-ce/index.html,
+ builds/wince/vc2008-ce/freetype.vcproj,
+ builds/wince/vc2008-ce/index.html: s/2.4.9/2.4.10/, s/249/2410/.
+
+ * include/freetype/freetype.h (FREETYPE_PATCH): Set to 10.
+
+ * builds/unix/configure.raw (version_info): Set to 15:0:9.
+
+2012-06-15 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Improve spacing.
+
+ * docs/CHANGES: Updated.
+
+2012-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ * builds/exports.mk: Add CCexe_CFLAGS and CCexe_LDFLAGS.
+
+ to pass special compiler/linker flags under cross development.
+ Suggested by Savannah bug #36367.
+
+ ChangeLog on 2010-07-15 saying as they were removed was wrong
+ for the official trunk of FreeType2. This commit is the first
+ introduction of them.
+
+2012-06-14 Werner Lemberg <wl@gnu.org>
+
+ * docs/CHANGES: Updated.
+
+2012-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [truetype] Add new versions of NEC FA family to tricky font list.
+
+ NEC FA family dated in 1996 have different checksum.
+ Reported by Johnson Y. Yan <yinsen_yan@foxitsoftware.com>; see
+
+ http://lists.gnu.org/archive/html/freetype-devel/2012-06/msg00023.html
+
+ * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids): 4 sets
+ of fpgm & prep table checksums for FA-Gothic, FA-Minchou,
+ FA-RoundedGothicM, FA-RoundedGothicB are added. The family
+ names in sample PDF are truncated, thus the list of the
+ family names in tt_check_trickyness_family() is not updated yet.
+
+2012-06-06 Werner Lemberg <wl@gnu.org>
+
+ [ftraster] Fix rounding issue causing visual artifacts.
+
+ Problem reported by jola <hans-jochen.lau@lhsystems.com>; see
+
+ http://lists.gnu.org/archive/html/freetype-devel/2012-05/msg00036.html
+
+ * src/raster/ftraster.c (SMulDiv_No_Round): New macro.
+ (Line_Up): Use it.
+ * src/raster/ftmisc.h (FT_MulDiv_No_Round): Copied from `ftcalc.c'.
+
+2012-05-28 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ * src/base/ftoutln.c (FT_Outline_Get_Orientation): Simplify.
+
+ We now use the cross product of the direction vectors to compute the
+ outline's orientation.
+
+2012-05-28 Werner Lemberg <wl@gnu.org>
+
+ * docs/CHANGES: Updated.
+
+2012-05-28 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ New function FT_Outline_EmboldenXY.
+
+ * include/freetype/ftoutln.h (FT_Outline_EmboldenXY): Define it.
+
+ * src/base/ftoutln.c (FT_Outline_EmboldenXY): Implement it, using a
+ simplified embolding algorithm.
+ (FT_Outline_Embolden): Make it a special case of
+ `FT_Outline_EmboldenXY'
+
+2012-05-07 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #36386.
+
+ * src/type1/t1load.c (t1_load_keyword): Ignore keyword if context is
+ not valid.
+
+2012-04-07 Werner Lemberg <wl@gnu.org>
+
+ Remove compiler warning.
+
+ * src/truetype/ttgload.c (TT_Load_Glyph)
+ [!TT_CONFIG_OPTION_EMBEDDED_BITMAPS]: Access `glyph->face' directly.
+
+2012-03-28 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Properly copy scaler flags to script metrics object.
+
+ Without this patch, only the dummy and cjk autohinter modules get
+ them (since they copy the whole scaler object).
+
+ * src/autofit/aflatin.c (af_latin_metrics_scale),
+ src/autofit/aflatin2.c (af_latin2_metrics_scale): Implement it.
+
+2012-03-22 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [bdflib] Remove redundant macro.
+
+ * src/bdf/bdflib.c (isdigok): Remove and replace with sbitset, which
+ is exactly the same.
+
+2012-03-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [configure] Fix Savannah bug #35644.
+
+ * builds/unix/configure.raw: Check `-ansi' flag works even if gcc
+ is used. Bionic libc headers for Android lose the consistency
+ when they are parsed with __STDC_VERSION__ older than 199901L or
+ __STRICT_ANSI__.
+
+2012-03-20 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Improvement to Savannah bug #35656.
+
+ * src/bdf/bdflib.c (isdigok): Add cast, as suggested in report.
+
+2012-03-17 Chris Liddell <chris.liddell@artifex.com>
+
+ [type1] Fix Savannah bug #35847.
+
+ * src/type1/t1load.c (parse_subrs): Fix the loop exit condition;
+ we want to exit when we have run out of data.
+
+2012-03-16 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Really fix Savannah bug #35658.
+
+ * src/bdf/bdflib.c (_bdf_list_split): Add one more `field' initializer.
+
+2012-03-14 Yann Droneaud <yann@droneaud.fr>
+
+ [sfnt] Make arrays static like all others.
+
+ * src/sfnt/ttload.c (tt_face_load_maxp, tt_face_load_os2),
+ src/sfnt/ttmtx.c (tt_face_load_hhea): Add `static' keyword to frame
+ fields.
+
+2012-03-14 Huw Davies <huw@codeweavers.com>
+
+ [sfnt] A refinement of the previous commit.
+
+ * src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16,
+ tt_name_entry_ascii_from_other): Stop at null byte.
+
+2012-03-14 Huw Davies <huw@codeweavers.com>
+
+ [sfnt] Add `name' table compatibility to MS Windows.
+
+ * src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16,
+ tt_name_entry_ascii_from_other): Don't replace `\0' with question
+ marks when converting strings.
+
+2012-03-14 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #35833.
+
+ Based on the patch given in the bug report.
+
+ * src/type1/t1load.c (IS_INCREMENTAL): New macro.
+ (read_binary_data): Add parameter `incremental'.
+ Update all callers using `IS_INCREMENTAL'.
+
+2012-03-11 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Return correct linear advance width values.
+
+ This was quite a subtle bug which accidentally showed up with glyph
+ `afii10023' of arial.ttf (version 2.76). This glyph is a composite;
+ the first component, `E', has an advance width of 1366 font units,
+ while the advance width of the composite itself (which looks like
+ uppercase `E' with dieresis) is 1367 font units. I think this is
+ actually a bug in the font itself, because there is no reason that
+ this glyph has not the same width as uppercase `E' without the
+ dieresis. Anyway, it helped identify this problem.
+
+ Using the TrueType hinter, the correct value (1367) of `afii10023'
+ was returned, but the autohinter mysteriously returned 1366.
+
+ Digging in the code showed that the autohinter recursively calls
+ FT_Load_Glyph to load the glyph, adding the FT_LOAD_NO_SCALE load
+ flag. However, the `linearHoriAdvance' field is still returned as a
+ scaled value. To avoid scaling twice, the old code in autofit reset
+ `linearHoriAdvance', using the `horiAdvance' field. This seemed to
+ work since FT_LOAD_NO_SCALE was in use, but it failed actually,
+ because `horiAdvance' is defined as the distance of the first
+ subglyph's phantom points, which in turn are initialized using the
+ advance width of the first subglyph. And as the given example
+ shows, these widths can differ.
+
+ * src/autofit/afloader.c (af_loader_load_g): Temporarily set
+ FT_LOAD_LINEAR_DESIGN while calling FT_Load_Glyph to get unscaled
+ values for the linear advance widths.
+
+2012-03-10 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix SSW instruction.
+
+ * src/truetype/ttinterp.c (DO_SSW): SSW *does* use font units. For
+ verification, it took some time to find a font which actually uses
+ this instruction.
+
+2012-03-09 Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation.
+
+ * include/freetype/freetype.h: Swap order of preprocessor blocks.
+
+2012-03-08 Werner Lemberg <wl@gnu.org>
+
+ * Version 2.4.9 released.
+ =========================
+
+
+ Tag sources with `VER-2-4-9'.
+
+ * docs/CHANGES: Updated.
+
+ * docs/VERSION.DLL: Update documentation and bump version number to
+ 2.4.9.
+
+ * README, Jamfile (RefDoc),
+ builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
+ builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
+ builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
+ builds/win32/visualc/freetype.dsp,
+ builds/win32/visualc/freetype.vcproj,
+ builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
+ builds/win32/visualce/freetype.vcproj,
+ builds/win32/visualce/index.html,
+ builds/wince/vc2005-ce/freetype.vcproj,
+ builds/wince/vc2005-ce/index.html,
+ builds/wince/vc2008-ce/freetype.vcproj,
+ builds/wince/vc2008-ce/index.html: s/2.4.8/2.4.9/, s/248/249/.
+
+ * include/freetype/freetype.h (FREETYPE_PATCH): Set to 9.
+
+ * builds/unix/configure.raw (version_info): Set to 14:1:8.
+
+2012-03-08 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Add missing overflow check.
+
+ * src/bdf/bdflib.c (_bdf_parse_glyphs) <BITMAP>: Add threshold for
+ `glyph->bpr'.
+
+2012-03-07 Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation.
+
+ * src/autofit/aferrors.h, src/bdf/bdferror.h, src/bzip2/ftbzip2.c,
+ src/cache/ftcerror.h, src/cff/cfferrs.h, src/cid/ciderrs.h,
+ src/gxvalid/gxverror.h, src/gzip/ftgzip.c, src/lzw/ftlzw.c,
+ src/otvalid/otverror.h, src/pcf/pcferror.h, src/pfr/pfrerror.h,
+ src/psaux/psauxerr.h, src/pshinter/pshnterr.h,
+ src/psnames/psnamerr.h, src/raster/rasterrs.h, src/sfnt/sferrors.h,
+ src/smooth/ftsmerrs.h, src/truetype/tterrors.h,
+ src/type1/t1errors.h, src/type42/t42error.h, src/winfonts/fnterrs.h:
+ Add #undef FT_ERR_PREFIX before #define FT_ERR_PREFIX.
+
+2012-03-03 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #35660.
+
+ For some divisions, we use casts to 32bit entities. Always guard
+ against division by zero with these casts also.
+
+ * src/base/ftcalc.c (ft_div64by32): Remove redundant cast.
+ (FT_MulDiv, FT_MulDiv_No_Round): Add 32bit cast.
+ (FT_DivFix): Add 32bit cast (this omission triggered the bug).
+
+2012-03-03 Werner Lemberg <wl@gnu.org>
+
+ [psaux] Fix handling of track kerning.
+
+ * src/psaux/afmparse.c (afm_parse_track_kern): Don't inverse sign
+ for `min_kern'. It is indeed quite common that track kerning
+ *increases* spacing for very small sizes.
+
+2012-03-02 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix Savannah bug #35689.
+
+ * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Check first outline
+ point.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #35656.
+
+ * src/bdf/bdflib.c (_bdf_parse_glyphs) <_BDF_BITMAP>: Check validity
+ of nibble characters instead of accessing `a2i' array.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [winfonts] Fix Savannah bug #35659.
+
+ * src/winfonts/winfnt.c (FNT_Face_Init): Check number of glyphs.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #35658.
+
+ * src/bdf/bdflib.c (_bdf_list_split): Initialize `field' elements
+ properly.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [psaux] Fix Savannah bug #35657.
+
+ If in function `skip_spaces' the routine `skip_comment' comes to the
+ end of buffer, `cur' is still increased by one, so we need to check
+ for `p >= limit' and not `p == limit'.
+
+ * src/psaux/psconv.c (PS_Conv_Strtol, PS_Conv_ToFixed,
+ PS_Conv_ASCIIHexDecode, PS_Conv_EexecDecode): Fix boundary checking.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix Savannah bug #35646.
+
+ * src/truetype/ttinterp.c (Ins_MIRP): Typo, present since ages. The
+ code is now in sync with the other operators (e.g. MSIRP) which
+ modify twilight points.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #35643.
+
+ * src/bdf/bdflib.c (_bdf_list_ensure): Bring code in sync with
+ comment before `_bdf_list_split', this is, really allocate at least
+ five `field' elements.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #35641.
+
+ * src/bdf/bdflib.c (_bdf_parse_glyphs) <DWIDTH, BBX>: Abort if
+ _BDF_ENCODING isn't set. We need this because access to the `glyph'
+ variable might be undefined otherwise.
+
+2012-03-01 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix Savannah bug #35640.
+
+ * src/truetype/ttinterp.c (SkipCode, TT_RunIns): Fix boundary check
+ for NPUSHB and NPUSHW instructions.
+
+2012-02-29 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix Savannah bug #35601.
+
+ * src/truetype/ttinterp.c (Ins_SHZ): Use number of points instead of
+ last point for loop.
+ Also remove redundant boundary check.
+
+2012-02-29 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Remove redundant check.
+
+ * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Remove redundant
+ second check for ordered contour start points.
+
+2012-02-29 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Make SHC instruction behave similar to MS rasterizer.
+
+ * src/truetype/ttinterp.c (Ins_SHC): Handle virtual contour in
+ twilight zone.
+
+2012-02-29 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ Avoid modulo operators against a power-of-two denominator.
+
+ * src/afcjk.c (af_hint_normal_stem), src/base/ftoutln.c
+ (ft_contour_has), src/cff/cffgload.c (cff_decoder_parse_charstrings)
+ <cff_op_vvcurveto, cff_op_hhcurveto, cff_op_hvcurveto>,
+ src/gxvalid/gxvcommn.c (GXV_32BIT_ALIGNMENT_VALIDATE),
+ src/gxvalid/gxvfeat.c (gxv_feat_setting_validate): Replace `%' with
+ `&' operator.
+
+2012-02-29 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Don't synchronize digit widths for light rendering mode.
+
+ We don't hint horizontally in this mode.
+
+ * src/autofit/afloader.c (af_loader_load_g) <Hint_Metrics>:
+ Implement it.
+
+2012-02-26 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [type42] Minor code optimization (again).
+
+ * src/type42/t42parse.c (t42_parse_sfnts): Simplify previous change.
+
+2012-02-26 Mateusz Jurczyk <mjurczyk@google.com>
+ Werner Lemberg <wl@gnu.org>
+
+ [smooth] Fix Savannah bug #35604.
+
+ * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use `FT_Pos'
+ instead of `FT_UInt' for some variables and update comparisons
+ accordingly. A detailed analysis can be found in the bug report.
+
+2012-02-26 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [type42] Minor code optimization.
+
+ * src/type42/t42parse.c (t42_parse_sfnts): Use bitmask instead of
+ modulo operator.
+
+2012-02-26 Werner Lemberg <wl@gnu.org>
+
+ * docs/CHANGES: Updated.
+
+2012-02-26 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #35608.
+
+ * src/type1/t1parse.c (T1_Get_Private_Dict): Reject too short
+ dictionaries.
+
+2012-02-26 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Support `ENCODING -1 <n>' format.
+
+ * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Implement it.
+
+2012-02-26 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #35607.
+
+ * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Normalize
+ negative encoding values.
+
+2012-02-26 Werner Lemberg <wl@gnu.org>
+
+ [type1] Fix Savannah bug #35606.
+
+ * src/type1/t1load.c (parse_subrs): Add proper guards for `strncmp'.
+
+ * src/psaux/psobjs.c (ps_parser_skip_PS_token): Emit error message
+ only if cur < limit.
+
+2012-02-25 Werner Lemberg <wl@gnu.org>
+
+ [pcf] Fix Savannah bug #35603.
+
+ * src/pcf/pcfread.c (pcf_get_properties): Assure final zero byte in
+ `strings' array.
+
+2012-02-25 Werner Lemberg <wl@gnu.org>
+
+ [type42] Fix Savannah bug #35602.
+
+ * src/type42/t42parse.c (t42_parse_sfnts): Check `string_size' more
+ thoroughly.
+
+2012-02-25 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bugs #35599 and #35600.
+
+ * src/bdf/bdflib.c (ACMSG16): New warning message.
+ (_bdf_parse_glyphs) <_BDF_BITMAP>: Check line length.
+
+2012-02-24 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bugs #35597 and #35598.
+
+ * src/bdf/bdflib.c (_bdf_is_atom): Fix handling of property value.
+
+2012-02-24  Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation (6/6).
+
+ * src/cff/cffdrivr.c: s/Load_Glyph/cff_glyph_load/.
+
+ * src/cid/cidload.c: s/parse_font_matrix/cid_parse_font_matrix/.
+ s/t1_init_loader/cid_init_loader/.
+ s/t1_done_loader/cid_done_loader/.
+
+ * src/pxaux/t1cmap.c: s/t1_get_glyph_name/psaux_get_glyph_name/.
+
+ * src/truetype/ttdriver.c: s/Load_Glyph/tt_glyph_load/.
+
+ * src/type1/t1load.c: s/parse_font_matrix/t1_parse_font_matrix/.
+
+2012-02-24  Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation (5/6).
+
+ * include/freetype/fterrors.h: Undefine FT_KEEP_ERR_PREFIX after
+ using it.
+
+2012-02-22  Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation (4/6).
+
+ * src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine RAS_ARG,
+ RAS_ARGS, RAS_VAR, and RAS_VARS before defining it.
+
+ * src/smooth/ftgrays.c: s/TRaster/black_TRaster/,
+ s/PRaster/black_PRaster/.
+ * src/raster/ftraster.c: s/TRaster/gray_TRaster/,
+ s/PRaster/gray_PRaster/.
+
+2012-02-20  Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation (3/6).
+
+ * src/smooth/ftgrays.c: s/TWorker/black_TWorker/,
+ s/PWorker/black_PWorker/.
+ * src/raster/ftraster.c: s/TWorker/gray_TWorker/,
+ s/PWorker/gray_PWorker/.
+
+2012-02-20  Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation (2/6).
+
+ * src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine FLOOR,
+ CEILING, TRUNC, and SCALED before defining it.
+
+2012-02-20  Vinnie Falco <vinnie.falco@gmail.com>
+
+ Prepare source code for amalgamation (1/6).
+
+ See discussion starting at
+
+ http://lists.gnu.org/archive/html/freetype-devel/2012-01/msg00037.html
+
+ * src/smooth/ftgrays.c: s/TBand/gray_TBand/.
+ * src/raster/ftraster.c: s/TBand/black_TBand/.
+
+2012-02-17 Alexei Podtelezhnikov <apodtele@gmail.com>
+
+ [autofit] Fix outline flags.
+
+ * src/autofit/afloader.c (af_loader_load_g): Don't reassign
+ `outline.flags' so that this information is preserved. See
+ discussion starting at
+
+ http://lists.gnu.org/archive/html/freetype-devel/2012-02/msg00046.html
+
+2012-02-11 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Fix Savannah bug #35466.
+
+ Jump instructions are now bound to the current function. The MS
+ Windows rasterizer behaves the same, as confirmed by Greg Hitchcock.
+
+ * src/truetype/ttinterp.h (TT_CallRec): Add `Cur_End' element.
+ * src/truetype/ttobjs.h (TT_DefRecord): Add `end' element.
+
+ * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF): Check upper
+ bound of jump address.
+ (Ins_FDEF, Ins_CALL, Ins_LOOPCALL, Ins_UNKNOWN, TT_RunIns): Updated.
+
+2012-02-11 Werner Lemberg <wl@gnu.org>
+
+ We don't use `extensions'.
+
+ * include/freetype/internal/ftobjs.h (FT_DriverRec): Remove
+ `extensions' field.
+
+2012-02-11 Werner Lemberg <wl@gnu.org>
+
+ Clean up `generic' fields.
+
+ * include/freetype/internal/ftobjs.h (FT_ModuleRec, FT_LibraryRec):
+ Remove `generic' field since users can't access it.
+
+ * src/base/ftobjs.c (FT_Done_GlyphSlot): Call `generic.finalizer' as
+ advertised in the documentation of FT_Generic.
+ (Destroy_Module, FT_Done_Library): Updated to changes in `ftobjs.h'.
+
+2012-02-07 Werner Lemberg <wl@gnu.org>
+
+ [autofit] Harmonize function arguments.
+
+ * src/autofit/afloader.c, src/autofit/afloader.h: Use `FT_Int32' for
+ `load_flags'.
+
+2012-02-07 Werner Lemberg <wl@gnu.org>
+
+ * src/cff/cffobjs.c (cff_face_init): Remove unnecessary casts.
+
+2012-01-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [gxvalid] Fix Savannah bug #35286.
+
+ Patch submitted by anonymous reporter.
+
+ * src/gxvalid/gxvcommn.c (gxv_XStateTable_subtable_setup):
+ gxv_set_length_by_ulong_offset() must be called with 3, not 4,
+ the number of the subtables in the state tables; classTable,
+ stateArray, entryTable.
+
+2012-01-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [raccess] Modify for PIC build.
+
+ Based on the patch provided by Erik Dahlstrom <ed@opera.com>,
+ http://lists.gnu.org/archive/html/freetype-devel/2012-01/msg00010.html
+
+ Also `raccess_guess_table[]' and `raccess_rule_by_darwin_vfs()'
+ are renamed with `ft_' suffixes.
+
+ * src/base/ftbase.h: `raccess_rule_by_darwin_vfs()' is renamed
+ to `ft_raccess_rule_by_darwin_vfs()'.
+ * src/base/ftobjs.c: Ditto.
+
+ * src/base/ftrfork.c: Declarations of FT_RFork_Rule,
+ raccess_guess_rec, are moved to...
+ * include/freetype/internal/ftrfork.h: Here.
+
+ * include/freetype/internal/ftrfork.h:
+ FT_RFORK_RULE_ARRAY_{BEGIN,ENTRY,END} macros are defined
+ to replace raccess_guess_table[] in both of PIC and non-PIC
+ modes.
+ * src/base/ftrfork.c: raccess_guess_table[] array is rewritten
+ by FT_RFORK_RULE_ARRAY_{BEGIN,ENTRY,END}.
+
+ * src/base/basepic.h (BasePIC): Add `ft_raccess_guess_table'
+ storage. (FT_RACCESS_GUESS_TABLE_GET): New macro to retrieve
+ the function pointer from `ft_raccess_guess_table' storage in
+ `BasePIC' structure.
+ * src/base/ftrfork.c (FT_Raccess_Guess): Rewritten with
+ FT_RACCESS_GUESS_TABLE_GET.
+ (raccess_get_rule_type_from_rule_index): Add `library' as the
+ first argument to the function, to retrieve the storage of
+ `ft_raccess_guess_table' from it. Also `raccess_guess_table'
+ is replaced by FT_RACCESS_GUESS_TABLE_GET.
+ (ft_raccess_rule_by_darwin_vfs): Ditto.
+
+2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Remove trailing spaces.
+
+2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Formatting PIC related sources.
+
+ * src/autofit/afpic.c: Harmonize to FT2 coding conventions.
+ * src/base/basepic.c: Ditto.
+ * src/base/ftpic.c: Ditto.
+ * src/cff/cffpic.c: Ditto.
+ * src/pshinter/pshpic.c: Ditto.
+ * src/psnames/pspic.c: Ditto.
+ * src/raster/rastpic.c: Ditto.
+ * src/sfnt/sfntpic.c: Ditto.
+ * src/smooth/ftspic.c: Ditto.
+ * src/truetype/ttpic.c: Ditto.
+
+2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [autofit] Fix the inclusion of `aflatin2.h' in PIC file.
+
+ * src/autofit/afpic.c: Include `aflatin2.h' when
+ FT_OPTION_AUTOFIT2 is defined, as afglobal.c does so.
+ Unconditionally inclusion causes declared but unimplemented
+ warning by GCC 4.6.
+
+2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [cff] Remove redundant declarations of cff_cmap_XXX_class_rec.
+
+ * src/cff/cffpic.c: The declarations of
+ FT_Init_Class_cff_cmap_encoding_class_rec() and
+ FT_Init_Class_cff_cmap_unicode_class_rec() are removed.
+ They can be obtained by the inclusion of cffcmap.h.
+ cffcmap.h invokes FT_DECLARE_CMAP_CLASS() and it declares
+ FT_Init_Class_cff_cmap_encoding_class_rec() etc in PIC mode.
+
+2012-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Fix redundant declaration warning in PIC mode.
+
+ Originally FT_DEFINE_{DRIVER,MODULE,RENDERER}() macros were
+ designed to declare xxx_pic_{free,init} by themselves.
+ Because these macros are used at the end of the module
+ interface (e.g. ttdriver.c) and the wrapper source to build
+ a module as a single object (e.g. truetype.c) includes
+ the PIC file (e.g. ttpic.c) before the module interface,
+ these macros are expanded AFTER xxx_pic_{free,init} body
+ when the modules are built as single object.
+ The declaration after the implementation causes the redundant
+ declaration warnings, so the declarations are moved to module
+ PIC headers (e.g. ttpic.h). Separating to other header files
+ are needed for multi build.
+
+ * include/freetype/internal/ftdriver.h (FT_DEFINE_DRIVER):
+ Remove class_##_pic_free and class_##_pic_init declarations.
+ * include/freetype/internal/ftobjs.h (FT_DEFINE_RENDERER,
+ FT_DEFINE_MODULE): Ditto.
+
+ * src/base/basepic.h: Insert a comment and fix coding style.
+ * src/autofit/afpic.h: Declare autofit_module_class_pic_{free,
+ init}.
+ * src/cff/cffpic.h: Declare cff_driver_class_pic_{free,init}.
+ * src/pshinter/pshpic.h: Declare pshinter_module_class_pic_{free,
+ init}.
+ * src/psnames/pspic.h: Declare psnames_module_class_pic_{free,
+ init}.
+ * src/raster/rastpic.h: Declare
+ ft_raster{1,5}_renderer_class_pic_{free,init}
+ * src/sfnt/sfntpic.h: Declare sfnt_module_class_pic_{free,init}.
+ * src/smooth/ftspic.h: Declare
+ ft_smooth_{,lcd_,lcdv_}renderer_class_pic_{free,init}.
+ * src/truetype/ttpic.h: Declare tt_driver_class_pic_{free,init}.
+
+2012-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Make pspic.c to include module error header to fix multi build.
+
+ * src/psnames/pspic.c: Include `psnamerr.h'.
+
+2012-01-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [base] Fix a dereference of uninitialized variable in PIC mode.
+
+ * src/base/ftglyph.c (FT_Glyph_To_Bitmap): `glyph' must be
+ set before derefering to obtain `library'. The initialization
+ of `clazz', `glyph', `library' and NULL pointer check are
+ reordered to minimize PIC conditonals.
+
+2012-01-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [base] Insert explicit cast for GCC 4.6 in PIC mode.
+
+ * src/base/ftinit.c (FT_Add_Default_Modules): Under PIC
+ configuration, FT_DEFAULT_MODULES_GET returns
+ FT_Module_Class** pointer, GCC 4.6 warns that
+ const FT_Module_Class* const* variable is warned as
+ inappropriate to store it. To calm it, explicit cast is
+ inserted. Also `library' is checked to prevent the NULL
+ pointer dereference in FT_DEFAULT_MODULES_GET.
+
+2012-01-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Fix PIC build broken by d9145241fe378104ba4c12a42534549faacc92e6.
+
+ Under PIC configuration, FT_{CFF,PSCMAPS,SFNT,TT}_SERVICES_GET
+ take no arguments but derefer the variable named `library'
+ internally.
+
+ * src/cff/cffdrivr.c (cff_get_interface): Declare `library' and
+ set it if non-NULL driver is passed.
+ * src/truetype/ttdriver.c (tt_get_interface): Ditto.
+
+ * src/sfnt/sfdriver.c (sfnt_get_interface): Declare `library'
+ under PIC configuration, and set it if non-NULL module is given.
+ * src/psnames/psmodule.c (psnames_get_interface): Ditto.
+
+2012-01-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Make PIC files include module error headers, to use the error codes
+ with per-module prefix.
+
+ * src/autofit/afpic.c: Include `aferrors.h'.
+ * src/cff/cffpic.c: Include `cfferrs.h'.
+ * src/pshinter/pshpic.c: Include `pshnterr.h'.
+ * src/raster/rastpic.c: Include `rasterrs.h'.
+ * src/sfnt/sfntpic.c: Include `sferrors.h'.
+ * src/smooth/ftspic.c: Include `ftsmerrs.h'.
+ * src/truetype/ttpic.c: Include `tterrors.h'.
+
+2012-01-04 Tobias Ringström <tobias@ringis.se>
+
+ [truetype] Fix IP instruction if x_ppem != y_ppem.
+
+ * src/truetype/ttinterp.c (Ins_IP): Scale `orus' coordinates
+ properly.
+
+2012-01-02 Werner Lemberg <wl@gnu.org>
+
+ Fix tracing message for `loca' table.
+
+ * src/truetype/ttpload.c (tt_face_get_location): Don't emit a
+ warning message if the last `loca' entry references an empty glyph.
+
+2011-12-10 Werner Lemberg <wl@gnu.org>
+
+ Add some variable initializations.
+ Reported by Richard COOK <rscook@unicode.org>.
+
+ * src/type1/t1driver.c (t1_ps_get_font_value): Initialize `val'.
+ * src/smooth/ftgrays.c (gray_render_conic): Initialize `levels'
+ earlier.
+
+2011-12-08 Werner Lemberg <wl@gnu.org>
+
+ Fix serious scaling bug in `FT_Get_Advances'.
+
+ * src/base/ftadvanc.c (FT_Get_Advances): Advance values returned by
+ `FT_Load_Glyph' must be simply multiplied by 1024.
+
+2011-12-08 Werner Lemberg <wl@gnu.org>
+
+ * src/bdf/bdflib.c (_bdf_parse_start): Drop redundant error tracing.
+
+2011-12-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [mac] Unify DARWIN_NO_CARBON with FT_MACINTOSH.
+
+ Originally FT_MACINTOSH was a pure auto macro and DARWIN_NO_CARBON
+ was a configurable macro to disable Carbon-dependent code. Because
+ now configure script sets DARWIN_NO_CARBON by default and disables
+ Darwin & Carbon-dependent codes, these macros can be unified.
+ FT_MACINTOSH (undefined by default) is kept and DARWIN_NO_CARBON
+ (defined by default) is removed, because DARWIN_NO_CARBON violates
+ FT_XXX naming convention of public macros, and a macro configured by
+ default is not portable for the building without configure (e.g.
+ make devel).
+
+ * builds/unix/configure.raw: Define FT_MACINTOSH if Carbon-based
+ old Mac font support is requested and Carbon is available.
+ * builds/unix/ftconfig.in: Undefine FT_MACINTOSH when the support
+ for Mac OS X without Carbon (e.g. Mac OS X 10.4 for ppc64) is
+ requested.
+ * include/freetype/config/ftconfig.in: Ditto.
+ * builds/vms/ftconfig.h: Ditto.
+
+ * src/base/ftbase.h: Remove DARWIN_NO_CARBON.
+ * src/base/ftbase.c: Ditto.
+ * src/base/ftobjs.c: Ditto.
+ * src/base/ftrfork.c: Ditto.
+
+ * src/base/ftmac.c: Compile the body if FT_MACINTOSH is defined
+ (same with TT_USE_BYTECODE_INTERPRETER in ttinterp.c).
+ * builds/mac/ftmac.c: Ditto.
+
+ * builds/mac/FreeType.m68k_cfm.make.txt: Define FT_MACINTOSH.
+ * builds/mac/FreeType.m68k_far.make.txt: Ditto.
+ * builds/mac/FreeType.ppc_classic.make.txt: Ditto.
+ * builds/mac/FreeType.ppc_carbon.make.txt: Ditto.
+
+2011-11-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Fix Savannah bug #34728 (`make devel' on Mac OS X).
+
+ * builds/toplevel.mk: Check `/dev/null' to identify the Unix-
+ like systems without `init' nor `hurd' (e.g. Mac OS X >= 10.4).
+ * builds/unix/detect.mk: Ditto.
+
+2011-11-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [apinames] Fix the overflow of signed integer hash.
+
+ * src/tools/apinames.c (names_add): Change the type of `h' from
+ int to unsigned int, to prevent undefined behaviour in the
+ overflow of signed integers (overflow of unsigned int is defined
+ to be wrap around). Found by clang test suggested by Sean
+ McBride.
+
+2011-11-30 Werner Lemberg <wl@gnu.org>
+
+ [winfonts] Remove casts.
+
+ * src/winfonts/winfnt.c (winfnt_driver_class): Remove all casts and
+ update affected functions.
+ (FNT_Size_Select): Fix number of arguments.
+
+2011-11-30 Werner Lemberg <wl@gnu.org>
+
+ [type42] Remove casts.
+
+ * src/type42/t42driver.c (t42_driver_class): Remove all casts and
+ update affected functions.
+
+ * src/type42/t42objs.c, src/type42/t42objs.h: Updated for t42driver
+ changes.
+
+2011-11-30 Werner Lemberg <wl@gnu.org>
+
+ [type1] Remove casts.
+
+ * src/type1/t1driver.c (t1_driver_class): Remove all casts and
+ update affected functions.
+
+ * src/type1/t1gload.c, src/type1/t1gload.h, src/type1/t1objs.c:
+ Updated for t1driver changes.
+ src/type1/t1objs.h (T1_Driver): Remove unused typedef.
+ Updated for t1driver changes.
+
+2011-11-27 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Fix Savannah bug #34896.
+
+ ENCODING now covers the whole Unicode range.
+
+ Note, however, that this change is quite expensive since it
+ increases the size of three arrays by almost 400kByte in total. The
+ right fix is to replace the logic with something smarter.
+ Additionally, there exist very old BDFs for three-byte CCCII
+ encoding which exceeds the range of Unicode (another reason to have
+ a smarter logic).
+
+ * src/bdf/bdf.h (bdf_font_t): Increase size of `nmod' and `umod'
+ arrays.
+ * src/bdf/bdflib.c (bdf_parse_t): Increase size of `have' array.
+
+2011-11-27 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Improve tracing.
+
+ * src/bdf/bdflib.c (DBGMSG1, DBGMSG2): New macros.
+ (_bdf_parse_glyphs): Use them.
+
+2011-11-26 Werner Lemberg <wl@gnu.org>
+
+ Improve tracing.
+
+ * src/bdf/bdfdrivr.c (BDF_Face_Done), src/pcf/pcfdrivr.c
+ (PCF_Face_Done): Remove tracing message.
+
+ * src/bdf/bdfdrivr.c (BDF_Face_Init), src/cff/cffobjs.c
+ (cff_face_init), src/cid/cidobjs.c (cid_face_init),
+ src/pfr/pfrobjs.c (pfr_face_init), src/sfnt/sfobjs.c
+ (sfnt_init_face), src/truetype/ttobjs.c (tt_face_init),
+ src/type1/t1objs.c (T1_Face_Init), src/type42/t42objs.c
+ (T42_Face_Init), src/winfonts/winfnt.c (FNT_Face_Init): Add
+ `greeting' message.
+
+ * src/sfnt/sfobjs.c (sfnt_open_font), src/type42/t42objs.c
+ (T42_Open_Face): Improve tracing.
+
+2011-11-26 Werner Lemberg <wl@gnu.org>
+
+ [cid] Fix error code.
+
+ * src/cid/cidparse.c (cid_parser_new): Do it.
+
+2011-11-26 Werner Lemberg <wl@gnu.org>
+
+ [cff] Fix error code.
+
+ * src/cff/cffload.c (cff_font_load): Do it.
+
+2011-11-26 Werner Lemberg <wl@gnu.org>
+
+ Add new error code FT_Err_Missing_Module.
+
+ Previously, FreeType misleadingly returned
+ FT_Err_Unknown_File_Format if a module was missing (or a test was
+ missing completely).
+
+ * include/freetype/fterrdef.h (FT_Err_Missing_Module): Define.
+
+ * src/cff/cffobjs.c (cff_face_init), src/cff/cffdrivr.c
+ (cff_get_glyph_name), src/cid/cidobjs.c (cid_face_init),
+ src/sfnt/sfobjs.c (sfnt_init_face), src/truetype/ttobjs.c
+ (tt_face_init), src/type1/t1objs.c (T1_Face_Init),
+ src/type42/t42objs.c (T42_Face_Init, T42_Driver_Init): Updated.
+
+ * src/type1/t1afm.c (T1_Read_Metrics), src/type/t1objs.c
+ (T1_Face_Init), src/type42/t42objs.c (T42_Face_Init): Remove now
+ redundant test for `psaux'.
+
+2011-11-25 Werner Lemberg <wl@gnu.org>
+
+ [bdf] Add more error messages.
+
+ * src/bdf/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
+ Add line number argument.
+ Update all callers.
+ (ERRMSG5, ERRMSG6, ERRMSG7, ERRMSG8, ERRMSG9): New macros.
+ (_bdf_readstream, _bdf_set_default_spacing, _bdf_add_property,
+ _bdf_parse_glyphs, _bdf_parse_start): Add error messages.
+
+2011-11-24 Werner Lemberg <wl@gnu.org>
+
+ * include/freetype/fterrors.h: Remove dead code.
+
+2011-11-15 Werner Lemberg <wl@gnu.org>
+
+ * docs/releases: Updated.
+
2011-11-15 Werner Lemberg <wl@gnu.org>
* Version 2.4.8 released.
@@ -184,7 +2320,7 @@
2011-09-27 Simon Bünzli <zeniko@gmail.com>
- Fix Savannah bug #34189.
+ [type1] Fix Savannah bug #34189.
* src/type1/t1load.c (T1_Open_Face): Initialize
`face->len_buildchar'.
@@ -227,7 +2363,7 @@
Add explicit LZW decompression stack size limit.
Stack larger than 1<<LZW_MAX_BITS is never needed if prefix table is
- constructed correctly. It's even less than that, see e.g.
+ constructed correctly. It's even less than that, see e.g.
libarchive code comment for a better size upper bound:
http://code.google.com/p/libarchive/source/browse/trunk/libarchive/archive_read_support_filter_compress.c?r=3635#121
@@ -265,7 +2401,7 @@
2011-09-07 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #33816.
+ [cff] Fix Savannah bug #33816.
* src/cff/cfftypes.h (CFF_FontRecDictRec): New member
`has_font_matrix'.
@@ -327,7 +2463,7 @@
2011-08-09 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #33975.
+ [cff] Fix Savannah bug #33975.
* src/cff/cffparse.c (cff_parse_font_matrix): Fix typo.
@@ -459,7 +2595,7 @@
2011-07-02 Just Fill Bugs <mozbugbox@yahoo.com.au>
- Fix Savannah bug #33246.
+ [truetype] Fix Savannah bug #33246.
* src/truetype/ttobjs.c (tt_check_single_notdef): New function.
(tt_face_init): Use it to test FT_FACE_FLAG_SCALABLE.
@@ -573,7 +2709,7 @@
2011-06-29 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #33663.
+ [bdf] Fix Savannah bug #33663.
* src/bdf/bdflib.c (_bdf_parse_glyphs): Handle negative values for
ENCODING correctly.
@@ -1127,7 +3263,7 @@
2011-04-13 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #33047.
+ [psaux] Fix Savannah bug #33047.
Patch submitted by anonymous reporter.
@@ -1220,7 +3356,7 @@
2011-03-07 Bram Tassyns <bramt@enfocus.be>
- Fix Savannah bug #27988.
+ [cff] Fix Savannah bug #27988.
* src/cff/cffobjs.c (remove_style): New function.
(cff_face_init): Use it to strip off the style part of the family
@@ -2052,14 +4188,14 @@
2010-10-12 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #31310.
+ [truetype] Fix Savannah bug #31310.
* src/truetype/ttgxvar.c (ft_var_readpackedpoints): Protect against
invalid `runcnt' values.
2010-10-08 Chris Liddell <chris.liddell@artifex.com>
- Fix Savannah bug #31275.
+ [sfnt] Fix Savannah bug #31275.
* src/sfnt/ttpost.c: Include FT_INTERNAL_DEBUG_H.
@@ -2118,7 +4254,7 @@
2010-10-02 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #31088 (sort of).
+ [sfnt] Fix Savannah bug #31088 (sort of).
* src/sfnt/ttload.c (tt_face_load_maxp): Always allocate at least 64
function entries.
@@ -2134,7 +4270,7 @@
2010-10-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
- Fix Savannah bug #31040.
+ [truetype] Fix Savannah bug #31040.
* src/truetype/ttinterp.c (free_buffer_in_size): Remove.
(TT_RunIns): Updated.
@@ -2368,7 +4504,7 @@
2010-08-17 Teijo Kinnunen <Teijo.Kinnunen@nuance.com>
- Fix Savannah bug #30788.
+ [cache] Fix Savannah bug #30788.
* src/cache/ftccache.c (FTC_Cache_Clear): Check `cache->buckets' for
NULL too.
@@ -2445,7 +4581,7 @@
2010-08-05 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30657.
+ [truetype] Fix Savannah bug #30657.
* src/truetype/ttinterp.c (BOUNDSL): New macro.
Change `BOUNDS' to `BOUNDSL' where appropriate.
@@ -2455,7 +4591,7 @@
2010-08-05 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30656.
+ [type42] Fix Savannah bug #30656.
* src/type42/t42parse.c (t42_parse_sfnts): Protect against negative
string_size.
@@ -2654,7 +4790,7 @@
2010-07-08 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30361.
+ [truetype] Fix Savannah bug #30361.
* src/truetype/ttinterp.c (Ins_IUP): Fix bounds check.
@@ -2775,7 +4911,7 @@
2010-06-30 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30263.
+ [smooth] Fix Savannah bug #30263.
* src/smooth/ftgrays.c (gray_render_span): Use cast to `unsigned
int' to avoid integer overflow.
@@ -2866,7 +5002,7 @@
2010-06-26 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30262.
+ [sfnt] Fix Savannah bug #30262.
* src/sfnt/ttload.c (tt_face_load_maxp): Limit `maxComponentDepth'
arbitrarily to 100 to avoid stack exhaustion.
@@ -2883,14 +5019,14 @@
2010-06-25 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30261.
+ [pfr] Fix Savannah bug #30261.
* src/pfr/pfrobjs.c (pfr_face_init): Reject fonts which contain
neither outline nor bitmap glyphs.
2010-06-25 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30254.
+ [cff] Fix Savannah bug #30254.
* src/cff/cffload.c (cff_index_get_pointers): Do sanity check for
first offset also.
@@ -2905,7 +5041,7 @@
2010-06-24 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30247.
+ [pcf] Fix Savannah bug #30247.
* src/pcf/pcfread.c (pcf_get_metrics): Disallow (invalid) fonts with
zero metrics.
@@ -2922,14 +5058,14 @@
2010-06-24 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30236.
+ [sfnt] Fix Savannah bug #30236.
* src/sfnt/ttcmap.c (tt_face_build_cmaps): Improve check for pointer
to `cmap_table'.
2010-06-24 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30235.
+ [pfr] Fix Savannah bug #30235.
* src/pfr/pfrgload.c (pfr_glyph_load_simple): Protect against
invalid indices if there aren't any coordinates for indexing.
@@ -2945,7 +5081,7 @@
2010-06-23 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30220.
+ [bdf] Fix Savannah bug #30220.
* include/freetype/fterrdef.h
(BDF_Err_Missing_Fontboundingbox_Field): New error code.
@@ -2957,21 +5093,21 @@
2010-06-21 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30168.
+ [pfr] Fix Savannah bug #30168.
* src/pfr/pfrgload.c (pfr_glyph_load_compound): Limit the number of
subglyphs to avoid endless recursion.
2010-06-20 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30145.
+ [psaux] Fix Savannah bug #30145.
* src/psaux/psobjs.c (t1_builder_add_contour): Protect against
`outline == NULL' which might happen in invalid fonts.
2010-06-19 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30135.
+ [bdf] Fix Savannah bug #30135.
* src/bdf/bdflib.c (_bdf_list_join): Don't modify value in static
string `empty'.
@@ -2979,14 +5115,14 @@
2010-06-15 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30108.
+ [autofit] Fix Savannah bug #30108.
* src/autofit/afglobal.c (af_face_globals_compute_script_coverage):
Properly mask AF_DIGIT bit in comparison.
2010-06-11 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30106.
+ [pshinter] Fix Savannah bug #30106.
Point numbers for FreeType's implementation of hinting masks are
collected before the final number of points of a glyph has been
@@ -3015,14 +5151,14 @@
2010-06-09 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30082.
+ [cff] Fix Savannah bug #30082.
* src/cff/cffgload.c (cff_decoder_parse_charstrings)
<cff_op_callothersubr>: Protect against stack underflow.
2010-06-08 Werner Lemberg <wl@gnu.org>
- Fix Savannah bug #30053.
+ [cff] Fix Savannah bug #30053.
* src/cff/cffparse.c (cff_parse_real): Handle border case where
`fraction_length' has value 10.
@@ -3068,7 +5204,7 @@
2010-05-21 Bram Tassyns <bramt@enfocus.be>
- Fix Savannah bug #27987.
+ [cff] Fix Savannah bug #27987.
* src/cff/cffobjs.c (remove_subset_prefix): New function.
(cff_face_init): Use it to adjust `cffface->family_name'.
@@ -3104,7 +5240,7 @@
2010-05-10 Ken Sharp <ken.sharp@artifex.com>
- Fix Savannah bug #29846.
+ [psaux] Fix Savannah bug #29846.
Previously we discovered fonts which used `setcurrentpoint' to set
the initial point of a contour to 0,0. This caused FreeType to
@@ -3123,9 +5259,9 @@
and real proper usage of the operator to work the same way as Adobe
interpreters apparently do.
- (t1_decoder_parse_charstrings): Make `setcurrentpoint' use the top
- two elements of the stack to establish unconditionally the current x
- and y coordinates.
+ * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Make
+ `setcurrentpoint' use the top two elements of the stack to establish
+ unconditionally the current x and y coordinates.
Make the `flex' subroutine handling (OtherSubr 0) put the current
x,y coordinates onto the stack, instead of two dummy uninitialised
@@ -3133,7 +5269,7 @@
2010-04-14 Ken Sharp <ken.sharp@artifex.com>
- Fix Savannah bug #29444.
+ [psaux] Fix Savannah bug #29444.
* src/psaux/psobjs.c (t1_builder_start_point): Accept (invalid)
`lineto' immediately after `hsbw', in accordance with Acrobat, GS,
@@ -3141,21 +5277,21 @@
2010-04-14 Michał Cichoń <thedmd@artifexmundi.com>
- Fix Savannah bug #27999.
+ [psaux] Fix Savannah bug #27999.
* src/cache/ftcmanag.c (FTC_Manager_RemoveFaceID): Only remove
selected entry, not all.
2010-04-06 Jonathan Kew <jfkthame@gmail.com>
- Add overflow check to `fvar' table.
+ [truetype] Add overflow check to `fvar' table.
* src/truetype/ttgxvar.c (TT_Get_MM_Var): Check axis and instance
count.
2010-04-05 Ken Sharp <ken.sharp@artifex.com>
- Fix Savannah bug #29335.
+ [raster] Fix Savannah bug #29335.
* src/raster/ftraster.c (Line_Up): Use slow multiplication to
prevent overflow. This shouldn't have any serious impact on speed,
@@ -3178,7 +5314,7 @@
2010-04-01 John Tytgat <John.Tytgat@esko.com>
- Fix Savannah bug #29404.
+ [truetype] Fix Savannah bug #29404.
* src/truetype/ttgload.c: Revert change 2752bd1a (check on bit 1
of `head' table of TrueType fonts).
@@ -3197,20 +5333,20 @@
2010-03-11 Chris Liddell <chris.liddell@artifex.com>
- Fix Savannah bug #27442.
+ [raster] Fix Savannah bug #27442.
* src/raster/ftraster.c (ft_black_reset): Fix `buffer_size'.
2010-03-09 Werner Lemberg <wl@gnu.org>
- Remove unused variable.
+ [cff] Remove unused variable.
Reported by Graham.
* src/cff/cffparse.c (cff_parse_real): Remove `rest'.
2010-03-02 John Tytgat <John.Tytgat@esko.com>
- Improve CFF string (especially glyphname) lookup performance.
+ [cff] Improve CFF string (especially glyphname) lookup performance.
We do this by avoiding memory allocation and file I/O. This is
Savannah patch #7104.
@@ -3277,7 +5413,7 @@
2010-02-18 Chris Liddell <chris.liddell@artifex.com>
- Fix Savannah bug #28905.
+ [truetype] Fix Savannah bug #28905.
Initialize phantom points before calling the incremental interface
to update glyph metrics.
@@ -3290,7 +5426,7 @@
----------------------------------------------------------------------------
-Copyright 2010-2011 by
+Copyright 2010-2012 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used, modified,
diff --git a/3party/freetype/Jamfile b/3party/freetype/Jamfile
index eb000d6593..b3d48279bd 100644
--- a/3party/freetype/Jamfile
+++ b/3party/freetype/Jamfile
@@ -195,7 +195,7 @@ rule RefDoc
actions RefDoc
{
- python $(FT2_SRC)/tools/docmaker/docmaker.py --prefix=ft2 --title=FreeType-2.4.8 --output=$(DOC_DIR) $(FT2_INCLUDE)/freetype/*.h $(FT2_INCLUDE)/freetype/config/*.h
+ python $(FT2_SRC)/tools/docmaker/docmaker.py --prefix=ft2 --title=FreeType-2.4.11 --output=$(DOC_DIR) $(FT2_INCLUDE)/freetype/*.h $(FT2_INCLUDE)/freetype/config/*.h
}
RefDoc refdoc ;
diff --git a/3party/freetype/README b/3party/freetype/README
index fdc5e902d3..068e623a10 100644
--- a/3party/freetype/README
+++ b/3party/freetype/README
@@ -1,5 +1,5 @@
- FreeType 2.4.8
- ==============
+ FreeType 2.4.11
+ ===============
Please read the docs/CHANGES file, it contains IMPORTANT
INFORMATION.
@@ -19,9 +19,9 @@
and download one of the following files.
- freetype-doc-2.4.8.tar.bz2
- freetype-doc-2.4.8.tar.gz
- ftdoc248.zip
+ freetype-doc-2.4.11.tar.bz2
+ freetype-doc-2.4.11.tar.gz
+ ftdoc2411.zip
Bugs
@@ -44,7 +44,7 @@
----------------------------------------------------------------------
-Copyright 2006-2011 by
+Copyright 2006-2012 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/3party/freetype/autogen.sh b/3party/freetype/autogen.sh
index 9f2fb6a3e8..9f2fb6a3e8 100644..100755
--- a/3party/freetype/autogen.sh
+++ b/3party/freetype/autogen.sh
diff --git a/3party/freetype/builds/exports.mk b/3party/freetype/builds/exports.mk
index 52f2912d39..96b10db874 100644
--- a/3party/freetype/builds/exports.mk
+++ b/3party/freetype/builds/exports.mk
@@ -51,7 +51,7 @@ ifneq ($(EXPORTS_LIST),)
APINAMES_EXE := $(subst /,$(SEP),$(OBJ_DIR)/apinames$(E_BUILD))
$(APINAMES_EXE): $(APINAMES_SRC)
- $(CCexe) $(TE)$@ $<
+ $(CCexe) $(CCexe_CFLAGS) $(TE)$@ $< $(CCexe_LDFLAGS)
.PHONY: symbols_list
diff --git a/3party/freetype/builds/mac/FreeType.m68k_cfm.make.txt b/3party/freetype/builds/mac/FreeType.m68k_cfm.make.txt
index 0bd145257a..425f9f9ce2 100644
--- a/3party/freetype/builds/mac/FreeType.m68k_cfm.make.txt
+++ b/3party/freetype/builds/mac/FreeType.m68k_cfm.make.txt
@@ -17,6 +17,7 @@ Includes = \xB6
Sym-68K = -sym off
COptions = \xB6
+ -d FT_MACINTOSH=1 \xB6
-d HAVE_FSSPEC=1 \xB6
-d HAVE_FSREF=0 \xB6
-d HAVE_QUICKDRAW_TOOLBOX=1 \xB6
diff --git a/3party/freetype/builds/mac/FreeType.m68k_far.make.txt b/3party/freetype/builds/mac/FreeType.m68k_far.make.txt
index e8e2f6eb19..ebf5a1b56a 100644
--- a/3party/freetype/builds/mac/FreeType.m68k_far.make.txt
+++ b/3party/freetype/builds/mac/FreeType.m68k_far.make.txt
@@ -16,6 +16,7 @@ Includes = \xB6
Sym-68K = -sym off
COptions = \xB6
+ -d FT_MACINTOSH=1 \xB6
-d HAVE_FSSPEC=1 \xB6
-d HAVE_FSREF=0 \xB6
-d HAVE_QUICKDRAW_TOOLBOX=1 \xB6
diff --git a/3party/freetype/builds/mac/FreeType.ppc_carbon.make.txt b/3party/freetype/builds/mac/FreeType.ppc_carbon.make.txt
index c37e0f36f9..2926413f39 100644
--- a/3party/freetype/builds/mac/FreeType.ppc_carbon.make.txt
+++ b/3party/freetype/builds/mac/FreeType.ppc_carbon.make.txt
@@ -17,6 +17,7 @@ Includes = \xB6
Sym-PPC = -sym off
PPCCOptions = \xB6
+ -d FT_MACINTOSH=1 \xB6
-d HAVE_FSSPEC=1 \xB6
-d HAVE_FSREF=1 \xB6
-d HAVE_QUICKDRAW_TOOLBOX=1 \xB6
diff --git a/3party/freetype/builds/mac/FreeType.ppc_classic.make.txt b/3party/freetype/builds/mac/FreeType.ppc_classic.make.txt
index 0c0991eb07..377de9ab98 100644
--- a/3party/freetype/builds/mac/FreeType.ppc_classic.make.txt
+++ b/3party/freetype/builds/mac/FreeType.ppc_classic.make.txt
@@ -17,6 +17,7 @@ Includes = \xB6
Sym-PPC = -sym off
PPCCOptions = \xB6
+ -d FT_MACINTOSH=1 \xB6
-d HAVE_FSSPEC=1 \xB6
-d HAVE_FSREF=0 \xB6
-d HAVE_QUICKDRAW_TOOLBOX=1 \xB6
diff --git a/3party/freetype/builds/mac/ftmac.c b/3party/freetype/builds/mac/ftmac.c
index c974f670f2..719dd0ce97 100644
--- a/3party/freetype/builds/mac/ftmac.c
+++ b/3party/freetype/builds/mac/ftmac.c
@@ -171,6 +171,7 @@ typedef short ResourceIndex;
#define PREFER_LWFN 1
#endif
+#ifdef FT_MACINTOSH
#if !HAVE_QUICKDRAW_CARBON /* QuickDraw is deprecated since Mac OS X 10.4 */
@@ -1527,5 +1528,7 @@ typedef short ResourceIndex;
}
+#endif /* FT_MACINTOSH */
+
/* END */
diff --git a/3party/freetype/builds/toplevel.mk b/3party/freetype/builds/toplevel.mk
index d552a4a179..03b6e28d5f 100644
--- a/3party/freetype/builds/toplevel.mk
+++ b/3party/freetype/builds/toplevel.mk
@@ -3,7 +3,7 @@
#
-# Copyright 1996-2000, 2001, 2003, 2006, 2008, 2009, 2010 by
+# Copyright 1996-2001, 2003, 2006, 2008-2010, 2012 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -122,6 +122,7 @@ ifdef check_platform
#
is_unix := $(strip $(wildcard /sbin/init) \
$(wildcard /usr/sbin/init) \
+ $(wildcard /dev/null) \
$(wildcard /hurd/auth))
ifneq ($(is_unix),)
@@ -200,6 +201,7 @@ dist:
currdir=`pwd` ; \
for f in `find . -wholename '*/.git' -prune \
-o -name .gitignore \
+ -o -name .mailmap \
-o -type d \
-o -print` ; do \
ln -s $$currdir/$$f tmp/$$f ; \
diff --git a/3party/freetype/builds/unix/aclocal.m4 b/3party/freetype/builds/unix/aclocal.m4
index b1ed6c7845..0940200fdb 100644
--- a/3party/freetype/builds/unix/aclocal.m4
+++ b/3party/freetype/builds/unix/aclocal.m4
@@ -1,7 +1,7 @@
-# generated automatically by aclocal 1.11.1 -*- Autoconf -*-
+# generated automatically by aclocal 1.12.5 -*- Autoconf -*-
+
+# Copyright (C) 1996-2012 Free Software Foundation, Inc.
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -14,8 +14,8 @@
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
#
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
-# Inc.
+# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is free software; the Free Software Foundation gives
@@ -24,8 +24,8 @@
m4_define([_LT_COPYING], [dnl
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
-# Inc.
+# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is part of GNU Libtool.
@@ -159,6 +159,8 @@ AC_REQUIRE([AC_CANONICAL_BUILD])dnl
AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
+_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
+dnl
_LT_DECL([], [host_alias], [0], [The host system])dnl
_LT_DECL([], [host], [0])dnl
_LT_DECL([], [host_os], [0])dnl
@@ -644,7 +646,7 @@ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
configured by $[0], generated by m4_PACKAGE_STRING.
-Copyright (C) 2010 Free Software Foundation, Inc.
+Copyright (C) 2011 Free Software Foundation, Inc.
This config.lt script is free software; the Free Software Foundation
gives unlimited permision to copy, distribute and modify it."
@@ -808,6 +810,7 @@ AC_DEFUN([LT_LANG],
m4_case([$1],
[C], [_LT_LANG(C)],
[C++], [_LT_LANG(CXX)],
+ [Go], [_LT_LANG(GO)],
[Java], [_LT_LANG(GCJ)],
[Fortran 77], [_LT_LANG(F77)],
[Fortran], [_LT_LANG(FC)],
@@ -829,6 +832,29 @@ m4_defun([_LT_LANG],
])# _LT_LANG
+m4_ifndef([AC_PROG_GO], [
+# NOTE: This macro has been submitted for inclusion into #
+# GNU Autoconf as AC_PROG_GO. When it is available in #
+# a released version of Autoconf we should remove this #
+# macro and use it instead. #
+m4_defun([AC_PROG_GO],
+[AC_LANG_PUSH(Go)dnl
+AC_ARG_VAR([GOC], [Go compiler command])dnl
+AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
+_AC_ARG_VAR_LDFLAGS()dnl
+AC_CHECK_TOOL(GOC, gccgo)
+if test -z "$GOC"; then
+ if test -n "$ac_tool_prefix"; then
+ AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
+ fi
+fi
+if test -z "$GOC"; then
+ AC_CHECK_PROG(GOC, gccgo, gccgo, false)
+fi
+])#m4_defun
+])#m4_ifndef
+
+
# _LT_LANG_DEFAULT_CONFIG
# -----------------------
m4_defun([_LT_LANG_DEFAULT_CONFIG],
@@ -859,6 +885,10 @@ AC_PROVIDE_IFELSE([AC_PROG_GCJ],
m4_ifdef([LT_PROG_GCJ],
[m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
+AC_PROVIDE_IFELSE([AC_PROG_GO],
+ [LT_LANG(GO)],
+ [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
+
AC_PROVIDE_IFELSE([LT_PROG_RC],
[LT_LANG(RC)],
[m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
@@ -961,7 +991,13 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
-dynamiclib -Wl,-single_module conftest.c 2>conftest.err
_lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
+ # If there is a non-empty error log, and "single_module"
+ # appears in it, assume the flag caused a linker warning
+ if test -s conftest.err && $GREP single_module conftest.err; then
+ cat conftest.err >&AS_MESSAGE_LOG_FD
+ # Otherwise, if the output was created with a 0 exit code from
+ # the compiler, it worked.
+ elif test -f libconftest.dylib && test $_lt_result -eq 0; then
lt_cv_apple_cc_single_mod=yes
else
cat conftest.err >&AS_MESSAGE_LOG_FD
@@ -969,6 +1005,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
rm -rf libconftest.dylib*
rm -f conftest.*
fi])
+
AC_CACHE_CHECK([for -exported_symbols_list linker flag],
[lt_cv_ld_exported_symbols_list],
[lt_cv_ld_exported_symbols_list=no
@@ -980,6 +1017,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
[lt_cv_ld_exported_symbols_list=no])
LDFLAGS="$save_LDFLAGS"
])
+
AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
[lt_cv_ld_force_load=no
cat > conftest.c << _LT_EOF
@@ -997,7 +1035,9 @@ _LT_EOF
echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
_lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
+ if test -s conftest.err && $GREP force_load conftest.err; then
+ cat conftest.err >&AS_MESSAGE_LOG_FD
+ elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
lt_cv_ld_force_load=yes
else
cat conftest.err >&AS_MESSAGE_LOG_FD
@@ -1042,8 +1082,8 @@ _LT_EOF
])
-# _LT_DARWIN_LINKER_FEATURES
-# --------------------------
+# _LT_DARWIN_LINKER_FEATURES([TAG])
+# ---------------------------------
# Checks for linker and compiler features on darwin
m4_defun([_LT_DARWIN_LINKER_FEATURES],
[
@@ -1054,6 +1094,8 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
if test "$lt_cv_ld_force_load" = "yes"; then
_LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+ m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
+ [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
else
_LT_TAGVAR(whole_archive_flag_spec, $1)=''
fi
@@ -1337,14 +1379,27 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
CFLAGS="$SAVE_CFLAGS"
fi
;;
-sparc*-*solaris*)
+*-*solaris*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.o` in
*64-bit*)
case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
+ yes*)
+ case $host in
+ i?86-*-solaris*)
+ LD="${LD-ld} -m elf_x86_64"
+ ;;
+ sparc*-*-solaris*)
+ LD="${LD-ld} -m elf64_sparc"
+ ;;
+ esac
+ # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
+ if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
+ LD="${LD-ld}_sol2"
+ fi
+ ;;
*)
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
LD="${LD-ld} -64"
@@ -1421,13 +1476,13 @@ old_postuninstall_cmds=
if test -n "$RANLIB"; then
case $host_os in
openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
+ old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
;;
*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
+ old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
;;
esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
+ old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
fi
case $host_os in
@@ -1607,6 +1662,11 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
lt_cv_sys_max_cmd_len=196608
;;
+ os2*)
+ # The test takes a long time on OS/2.
+ lt_cv_sys_max_cmd_len=8192
+ ;;
+
osf*)
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
@@ -1646,7 +1706,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
# If test is not a shell built-in, we'll probably end up computing a
# maximum length that is only half of the actual maximum length, but
# we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
+ while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
= "X$teststring$teststring"; } >/dev/null 2>&1 &&
test $i != 17 # 1/2 MB should be enough
do
@@ -2192,7 +2252,7 @@ need_version=unknown
case $host_os in
aix3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
shlibpath_var=LIBPATH
@@ -2201,7 +2261,7 @@ aix3*)
;;
aix[[4-9]]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
hardcode_into_libs=yes
@@ -2266,7 +2326,7 @@ beos*)
;;
bsdi[[45]]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
@@ -2405,7 +2465,7 @@ m4_if([$1], [],[
;;
dgux*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
@@ -2413,10 +2473,6 @@ dgux*)
shlibpath_var=LD_LIBRARY_PATH
;;
-freebsd1*)
- dynamic_linker=no
- ;;
-
freebsd* | dragonfly*)
# DragonFly does not have aout. When/if they implement a new
# versioning mechanism, adjust this.
@@ -2424,7 +2480,7 @@ freebsd* | dragonfly*)
objformat=`/usr/bin/objformat`
else
case $host_os in
- freebsd[[123]]*) objformat=aout ;;
+ freebsd[[23]].*) objformat=aout ;;
*) objformat=elf ;;
esac
fi
@@ -2442,7 +2498,7 @@ freebsd* | dragonfly*)
esac
shlibpath_var=LD_LIBRARY_PATH
case $host_os in
- freebsd2*)
+ freebsd2.*)
shlibpath_overrides_runpath=yes
;;
freebsd3.[[01]]* | freebsdelf3.[[01]]*)
@@ -2462,17 +2518,18 @@ freebsd* | dragonfly*)
;;
gnu*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
+ shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
haiku*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
dynamic_linker="$host_os runtime_loader"
@@ -2533,7 +2590,7 @@ hpux9* | hpux10* | hpux11*)
;;
interix[[3-9]]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
@@ -2549,7 +2606,7 @@ irix5* | irix6* | nonstopux*)
nonstopux*) version_type=nonstopux ;;
*)
if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
else
version_type=irix
fi ;;
@@ -2586,9 +2643,9 @@ linux*oldld* | linux*aout* | linux*coff*)
dynamic_linker=no
;;
-# This must be Linux ELF.
+# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -2651,7 +2708,7 @@ netbsd*)
;;
newsos6)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
@@ -2720,7 +2777,7 @@ rdos*)
;;
solaris*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -2745,7 +2802,7 @@ sunos4*)
;;
sysv4 | sysv4.3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
@@ -2769,7 +2826,7 @@ sysv4 | sysv4.3*)
sysv4*MP*)
if test -d /usr/nec ;then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
soname_spec='$libname${shared_ext}.$major'
shlibpath_var=LD_LIBRARY_PATH
@@ -2800,7 +2857,7 @@ sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
tpf*)
# TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -2810,7 +2867,7 @@ tpf*)
;;
uts4*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
@@ -3232,7 +3289,7 @@ irix5* | irix6* | nonstopux*)
lt_cv_deplibs_check_method=pass_all
;;
-# This must be Linux ELF.
+# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
lt_cv_deplibs_check_method=pass_all
;;
@@ -3652,6 +3709,7 @@ for ac_symprfx in "" "_"; do
# which start with @ or ?.
lt_cv_sys_global_symbol_pipe="$AWK ['"\
" {last_section=section; section=\$ 3};"\
+" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
" \$ 0!~/External *\|/{next};"\
" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
@@ -4236,7 +4294,9 @@ m4_if([$1], [CXX], [
case $cc_basename in
nvcc*) # Cuda Compiler Driver 2.2
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
- _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC'
+ if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
+ _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
+ fi
;;
esac
else
@@ -4328,18 +4388,33 @@ m4_if([$1], [CXX], [
;;
*)
case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
+ *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
# Sun Fortran 8.3 passes all unrecognized flags to the linker
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
_LT_TAGVAR(lt_prog_compiler_wl, $1)=''
;;
+ *Sun\ F* | *Sun*Fortran*)
+ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+ _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
+ ;;
*Sun\ C*)
# Sun C 5.9
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
;;
+ *Intel*\ [[CF]]*Compiler*)
+ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
+ _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
+ ;;
+ *Portland\ Group*)
+ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
+ _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+ ;;
esac
;;
esac
@@ -4499,7 +4574,9 @@ m4_if([$1], [CXX], [
;;
cygwin* | mingw* | cegcc*)
case $cc_basename in
- cl*) ;;
+ cl*)
+ _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
+ ;;
*)
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
_LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
@@ -4524,7 +4601,6 @@ m4_if([$1], [CXX], [
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
- _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
@@ -4775,8 +4851,7 @@ _LT_EOF
xlf* | bgf* | bgxlf* | mpixlf*)
# IBM XL Fortran 10.1 on PPC cannot create shared libs itself
_LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
- _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
- _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
+ _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
if test "x$supports_anon_versioning" = xyes; then
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
@@ -5071,6 +5146,7 @@ _LT_EOF
# The linker will not automatically build a static lib if we build a DLL.
# _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
+ _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
# Don't use ranlib
_LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
@@ -5117,10 +5193,6 @@ _LT_EOF
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
- freebsd1*)
- _LT_TAGVAR(ld_shlibs, $1)=no
- ;;
-
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
# support. Future versions do this automatically, but an explicit c++rt0.o
# does not break anything, and helps significantly (at the cost of a little
@@ -5133,7 +5205,7 @@ _LT_EOF
;;
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2*)
+ freebsd2.*)
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_minus_L, $1)=yes
@@ -5172,7 +5244,6 @@ _LT_EOF
fi
if test "$with_gnu_ld" = no; then
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
- _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
@@ -5614,9 +5685,6 @@ _LT_TAGDECL([], [no_undefined_flag], [1],
_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
[Flag to hardcode $libdir into a binary during linking.
This must work even if $libdir does not exist])
-_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1],
- [[If ld is used when linking, flag to hardcode $libdir into a binary
- during linking. This must work even if $libdir does not exist]])
_LT_TAGDECL([], [hardcode_libdir_separator], [1],
[Whether we need a single "-rpath" flag with a separated argument])
_LT_TAGDECL([], [hardcode_direct], [0],
@@ -5770,7 +5838,6 @@ _LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
@@ -6140,7 +6207,7 @@ if test "$_lt_caught_CXX_error" != yes; then
esac
;;
- freebsd[[12]]*)
+ freebsd2.*)
# C++ shared libraries reported to be fairly broken before
# switch to ELF
_LT_TAGVAR(ld_shlibs, $1)=no
@@ -6901,12 +6968,18 @@ public class foo {
}
};
_LT_EOF
+], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
+package foo
+func foo() {
+}
+_LT_EOF
])
_lt_libdeps_save_CFLAGS=$CFLAGS
case "$CC $CFLAGS " in #(
*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
+*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
esac
dnl Parse the compiler output and extract the necessary
@@ -7103,7 +7176,6 @@ _LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_automatic, $1)=no
@@ -7236,7 +7308,6 @@ _LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_automatic, $1)=no
@@ -7419,6 +7490,73 @@ CFLAGS=$lt_save_CFLAGS
])# _LT_LANG_GCJ_CONFIG
+# _LT_LANG_GO_CONFIG([TAG])
+# --------------------------
+# Ensure that the configuration variables for the GNU Go compiler
+# are suitably defined. These variables are subsequently used by _LT_CONFIG
+# to write the compiler configuration to `libtool'.
+m4_defun([_LT_LANG_GO_CONFIG],
+[AC_REQUIRE([LT_PROG_GO])dnl
+AC_LANG_SAVE
+
+# Source file extension for Go test sources.
+ac_ext=go
+
+# Object file extension for compiled Go test sources.
+objext=o
+_LT_TAGVAR(objext, $1)=$objext
+
+# Code to be used in simple compile tests
+lt_simple_compile_test_code="package main; func main() { }"
+
+# Code to be used in simple link tests
+lt_simple_link_test_code='package main; func main() { }'
+
+# ltmain only uses $CC for tagged configurations so make sure $CC is set.
+_LT_TAG_COMPILER
+
+# save warnings/boilerplate of simple test code
+_LT_COMPILER_BOILERPLATE
+_LT_LINKER_BOILERPLATE
+
+# Allow CC to be a program name with arguments.
+lt_save_CC=$CC
+lt_save_CFLAGS=$CFLAGS
+lt_save_GCC=$GCC
+GCC=yes
+CC=${GOC-"gccgo"}
+CFLAGS=$GOFLAGS
+compiler=$CC
+_LT_TAGVAR(compiler, $1)=$CC
+_LT_TAGVAR(LD, $1)="$LD"
+_LT_CC_BASENAME([$compiler])
+
+# Go did not exist at the time GCC didn't implicitly link libc in.
+_LT_TAGVAR(archive_cmds_need_lc, $1)=no
+
+_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
+_LT_TAGVAR(reload_flag, $1)=$reload_flag
+_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
+
+if test -n "$compiler"; then
+ _LT_COMPILER_NO_RTTI($1)
+ _LT_COMPILER_PIC($1)
+ _LT_COMPILER_C_O($1)
+ _LT_COMPILER_FILE_LOCKS($1)
+ _LT_LINKER_SHLIBS($1)
+ _LT_LINKER_HARDCODE_LIBPATH($1)
+
+ _LT_CONFIG($1)
+fi
+
+AC_LANG_RESTORE
+
+GCC=$lt_save_GCC
+CC=$lt_save_CC
+CFLAGS=$lt_save_CFLAGS
+])# _LT_LANG_GO_CONFIG
+
+
# _LT_LANG_RC_CONFIG([TAG])
# -------------------------
# Ensure that the configuration variables for the Windows resource compiler
@@ -7488,6 +7626,13 @@ dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
+# LT_PROG_GO
+# ----------
+AC_DEFUN([LT_PROG_GO],
+[AC_CHECK_TOOL(GOC, gccgo,)
+])
+
+
# LT_PROG_RC
# ----------
AC_DEFUN([LT_PROG_RC],
@@ -8152,9 +8297,24 @@ dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
m4_define([_LT_WITH_PIC],
[AC_ARG_WITH([pic],
- [AS_HELP_STRING([--with-pic],
+ [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
- [pic_mode="$withval"],
+ [lt_p=${PACKAGE-default}
+ case $withval in
+ yes|no) pic_mode=$withval ;;
+ *)
+ pic_mode=default
+ # Look at the argument we got. We use all the common list separators.
+ lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
+ for lt_pkg in $withval; do
+ IFS="$lt_save_ifs"
+ if test "X$lt_pkg" = "X$lt_p"; then
+ pic_mode=yes
+ fi
+ done
+ IFS="$lt_save_ifs"
+ ;;
+ esac],
[pic_mode=default])
test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
@@ -8326,15 +8486,15 @@ m4_define([lt_dict_filter],
# @configure_input@
-# serial 3293 ltversion.m4
+# serial 3337 ltversion.m4
# This file is part of GNU Libtool
-m4_define([LT_PACKAGE_VERSION], [2.4])
-m4_define([LT_PACKAGE_REVISION], [1.3293])
+m4_define([LT_PACKAGE_VERSION], [2.4.2])
+m4_define([LT_PACKAGE_REVISION], [1.3337])
AC_DEFUN([LTVERSION_VERSION],
-[macro_version='2.4'
-macro_revision='1.3293'
+[macro_version='2.4.2'
+macro_revision='1.3337'
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
_LT_DECL(, macro_revision, 0)
])
diff --git a/3party/freetype/builds/unix/config.guess b/3party/freetype/builds/unix/config.guess
index 8152efd675..872b96a161 100755
--- a/3party/freetype/builds/unix/config.guess
+++ b/3party/freetype/builds/unix/config.guess
@@ -2,9 +2,9 @@
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
-# 2011 Free Software Foundation, Inc.
+# 2011, 2012 Free Software Foundation, Inc.
-timestamp='2011-11-11'
+timestamp='2012-09-25'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -17,9 +17,7 @@ timestamp='2011-11-11'
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
-# 02110-1301, USA.
+# along with this program; if not, see <http://www.gnu.org/licenses/>.
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@@ -57,8 +55,8 @@ GNU config.guess ($timestamp)
Originally written by Per Bothner.
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free
-Software Foundation, Inc.
+2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
+Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -145,7 +143,7 @@ UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
*:NetBSD:*:*)
# NetBSD (nbsd) targets should (where applicable) match one or
- # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*,
+ # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
# *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
# switched to ELF, *-*-netbsd* would select the old
# object file format. This provides both forward
@@ -202,6 +200,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
echo "${machine}-${os}${release}"
exit ;;
+ *:Bitrig:*:*)
+ UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
+ echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE}
+ exit ;;
*:OpenBSD:*:*)
UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
@@ -304,7 +306,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
echo arm-acorn-riscix${UNAME_RELEASE}
exit ;;
- arm:riscos:*:*|arm:RISCOS:*:*)
+ arm*:riscos:*:*|arm*:RISCOS:*:*)
echo arm-unknown-riscos
exit ;;
SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
@@ -803,6 +805,9 @@ EOF
i*:CYGWIN*:*)
echo ${UNAME_MACHINE}-pc-cygwin
exit ;;
+ *:MINGW64*:*)
+ echo ${UNAME_MACHINE}-pc-mingw64
+ exit ;;
*:MINGW*:*)
echo ${UNAME_MACHINE}-pc-mingw32
exit ;;
@@ -863,6 +868,13 @@ EOF
i*86:Minix:*:*)
echo ${UNAME_MACHINE}-pc-minix
exit ;;
+ aarch64:Linux:*:*)
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
+ exit ;;
+ aarch64_be:Linux:*:*)
+ UNAME_MACHINE=aarch64_be
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
+ exit ;;
alpha:Linux:*:*)
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
EV5) UNAME_MACHINE=alphaev5 ;;
@@ -897,16 +909,16 @@ EOF
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
cris:Linux:*:*)
- echo cris-axis-linux-gnu
+ echo ${UNAME_MACHINE}-axis-linux-gnu
exit ;;
crisv32:Linux:*:*)
- echo crisv32-axis-linux-gnu
+ echo ${UNAME_MACHINE}-axis-linux-gnu
exit ;;
frv:Linux:*:*)
- echo frv-unknown-linux-gnu
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
hexagon:Linux:*:*)
- echo hexagon-unknown-linux-gnu
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
i*86:Linux:*:*)
LIBC=gnu
@@ -948,7 +960,7 @@ EOF
test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
;;
or32:Linux:*:*)
- echo or32-unknown-linux-gnu
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
padre:Linux:*:*)
echo sparc-unknown-linux-gnu
@@ -989,7 +1001,7 @@ EOF
echo ${UNAME_MACHINE}-dec-linux-gnu
exit ;;
x86_64:Linux:*:*)
- echo x86_64-unknown-linux-gnu
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
xtensa*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
@@ -1196,6 +1208,9 @@ EOF
BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
echo i586-pc-haiku
exit ;;
+ x86_64:Haiku:*:*)
+ echo x86_64-unknown-haiku
+ exit ;;
SX-4:SUPER-UX:*:*)
echo sx4-nec-superux${UNAME_RELEASE}
exit ;;
@@ -1251,7 +1266,7 @@ EOF
NEO-?:NONSTOP_KERNEL:*:*)
echo neo-tandem-nsk${UNAME_RELEASE}
exit ;;
- NSE-?:NONSTOP_KERNEL:*:*)
+ NSE-*:NONSTOP_KERNEL:*:*)
echo nse-tandem-nsk${UNAME_RELEASE}
exit ;;
NSR-?:NONSTOP_KERNEL:*:*)
@@ -1320,11 +1335,11 @@ EOF
i*86:AROS:*:*)
echo ${UNAME_MACHINE}-pc-aros
exit ;;
+ x86_64:VMkernel:*:*)
+ echo ${UNAME_MACHINE}-unknown-esx
+ exit ;;
esac
-#echo '(No uname command or uname output not recognized.)' 1>&2
-#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
-
eval $set_cc_for_build
cat >$dummy.c <<EOF
#ifdef _SEQUENT_
diff --git a/3party/freetype/builds/unix/config.sub b/3party/freetype/builds/unix/config.sub
index e76eaf472a..89b1286300 100755
--- a/3party/freetype/builds/unix/config.sub
+++ b/3party/freetype/builds/unix/config.sub
@@ -2,9 +2,9 @@
# Configuration validation subroutine script.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
-# 2011 Free Software Foundation, Inc.
+# 2011, 2012 Free Software Foundation, Inc.
-timestamp='2011-11-11'
+timestamp='2012-10-10'
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
@@ -21,9 +21,7 @@ timestamp='2011-11-11'
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
-# 02110-1301, USA.
+# along with this program; if not, see <http://www.gnu.org/licenses/>.
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@@ -76,8 +74,8 @@ version="\
GNU config.sub ($timestamp)
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free
-Software Foundation, Inc.
+2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
+Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -125,13 +123,17 @@ esac
maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
case $maybe_os in
nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
- linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
+ linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
knetbsd*-gnu* | netbsd*-gnu* | \
kopensolaris*-gnu* | \
storm-chaos* | os2-emx* | rtmk-nova*)
os=-$maybe_os
basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
;;
+ android-linux)
+ os=-linux-android
+ basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown
+ ;;
*)
basic_machine=`echo $1 | sed 's/-[^-]*$//'`
if [ $basic_machine != $1 ]
@@ -154,7 +156,7 @@ case $os in
-convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
-c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
-harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
- -apple | -axis | -knuth | -cray | -microblaze)
+ -apple | -axis | -knuth | -cray | -microblaze*)
os=
basic_machine=$1
;;
@@ -223,6 +225,12 @@ case $os in
-isc*)
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
;;
+ -lynx*178)
+ os=-lynxos178
+ ;;
+ -lynx*5)
+ os=-lynxos5
+ ;;
-lynx*)
os=-lynxos
;;
@@ -247,11 +255,14 @@ case $basic_machine in
# Some are omitted here because they have special meanings below.
1750a | 580 \
| a29k \
+ | aarch64 | aarch64_be \
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
| am33_2.0 \
- | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \
- | be32 | be64 \
+ | arc \
+ | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \
+ | avr | avr32 \
+ | be32 | be64 \
| bfin \
| c4x | clipper \
| d10v | d30v | dlx | dsp16xx \
@@ -264,7 +275,7 @@ case $basic_machine in
| le32 | le64 \
| lm32 \
| m32c | m32r | m32rle | m68000 | m68k | m88k \
- | maxq | mb | microblaze | mcore | mep | metag \
+ | maxq | mb | microblaze | microblazeel | mcore | mep | metag \
| mips | mipsbe | mipseb | mipsel | mipsle \
| mips16 \
| mips64 | mips64el \
@@ -319,8 +330,7 @@ case $basic_machine in
c6x)
basic_machine=tic6x-unknown
;;
- m6811 | m68hc11 | m6812 | m68hc12 | picochip)
- # Motorola 68HC11/12.
+ m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip)
basic_machine=$basic_machine-unknown
os=-none
;;
@@ -333,7 +343,10 @@ case $basic_machine in
strongarm | thumb | xscale)
basic_machine=arm-unknown
;;
-
+ xgate)
+ basic_machine=$basic_machine-unknown
+ os=-none
+ ;;
xscaleeb)
basic_machine=armeb-unknown
;;
@@ -356,6 +369,7 @@ case $basic_machine in
# Recognize the basic CPU types with company name.
580-* \
| a29k-* \
+ | aarch64-* | aarch64_be-* \
| alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
| alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
@@ -377,7 +391,8 @@ case $basic_machine in
| lm32-* \
| m32c-* | m32r-* | m32rle-* \
| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
- | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \
+ | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \
+ | microblaze-* | microblazeel-* \
| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
| mips16-* \
| mips64-* | mips64el-* \
@@ -719,7 +734,6 @@ case $basic_machine in
i370-ibm* | ibm*)
basic_machine=i370-ibm
;;
-# I'm not sure what "Sysv32" means. Should this be sysv3.2?
i*86v32)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv32
@@ -777,9 +791,13 @@ case $basic_machine in
basic_machine=ns32k-utek
os=-sysv
;;
- microblaze)
+ microblaze*)
basic_machine=microblaze-xilinx
;;
+ mingw64)
+ basic_machine=x86_64-pc
+ os=-mingw64
+ ;;
mingw32)
basic_machine=i386-pc
os=-mingw32
@@ -1341,15 +1359,15 @@ case $os in
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
| -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
| -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
- | -openbsd* | -solidbsd* \
+ | -bitrig* | -openbsd* | -solidbsd* \
| -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
| -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
| -chorusos* | -chorusrdb* | -cegcc* \
| -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
- | -mingw32* | -linux-gnu* | -linux-android* \
- | -linux-newlib* | -linux-uclibc* \
+ | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
+ | -linux-newlib* | -linux-musl* | -linux-uclibc* \
| -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
@@ -1532,6 +1550,9 @@ case $basic_machine in
c4x-* | tic4x-*)
os=-coff
;;
+ hexagon-*)
+ os=-elf
+ ;;
tic54x-*)
os=-coff
;;
@@ -1559,9 +1580,6 @@ case $basic_machine in
;;
m68000-sun)
os=-sunos3
- # This also exists in the configure program, but was not the
- # default.
- # os=-sunos4
;;
m68*-cisco)
os=-aout
diff --git a/3party/freetype/builds/unix/configure b/3party/freetype/builds/unix/configure
index 0e2a7bcf88..ba987277d1 100755
--- a/3party/freetype/builds/unix/configure
+++ b/3party/freetype/builds/unix/configure
@@ -1,13 +1,11 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.68 for FreeType 2.4.8.
+# Generated by GNU Autoconf 2.69 for FreeType 2.4.11.
#
# Report bugs to <freetype@nongnu.org>.
#
#
-# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
-# Foundation, Inc.
+# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
#
#
# This configure script is free software; the Free Software Foundation
@@ -136,6 +134,31 @@ export LANGUAGE
# CDPATH.
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
+# Use a proper internal environment variable to ensure we don't fall
+ # into an infinite loop, continuously re-executing ourselves.
+ if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
+ _as_can_reexec=no; export _as_can_reexec;
+ # We cannot yet assume a decent shell, so we have to provide a
+# neutralization value for shells without unset; and this also
+# works around shells that cannot unset nonexistent variables.
+# Preserve -v and -x to the replacement shell.
+BASH_ENV=/dev/null
+ENV=/dev/null
+(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
+case $- in # ((((
+ *v*x* | *x*v* ) as_opts=-vx ;;
+ *v* ) as_opts=-v ;;
+ *x* ) as_opts=-x ;;
+ * ) as_opts= ;;
+esac
+exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
+# Admittedly, this is quite paranoid, since all the known shells bail
+# out after a failed `exec'.
+$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
+as_fn_exit 255
+ fi
+ # We don't want this to propagate to other subprocesses.
+ { _as_can_reexec=; unset _as_can_reexec;}
if test "x$CONFIG_SHELL" = x; then
as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
emulate sh
@@ -169,7 +192,8 @@ if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
else
exitcode=1; echo positional parameters were not saved.
fi
-test x\$exitcode = x0 || exit 1"
+test x\$exitcode = x0 || exit 1
+test -x / || exit 1"
as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
@@ -222,21 +246,25 @@ IFS=$as_save_IFS
if test "x$CONFIG_SHELL" != x; then :
- # We cannot yet assume a decent shell, so we have to provide a
- # neutralization value for shells without unset; and this also
- # works around shells that cannot unset nonexistent variables.
- # Preserve -v and -x to the replacement shell.
- BASH_ENV=/dev/null
- ENV=/dev/null
- (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
- export CONFIG_SHELL
- case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
- esac
- exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
+ export CONFIG_SHELL
+ # We cannot yet assume a decent shell, so we have to provide a
+# neutralization value for shells without unset; and this also
+# works around shells that cannot unset nonexistent variables.
+# Preserve -v and -x to the replacement shell.
+BASH_ENV=/dev/null
+ENV=/dev/null
+(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
+case $- in # ((((
+ *v*x* | *x*v* ) as_opts=-vx ;;
+ *v* ) as_opts=-v ;;
+ *x* ) as_opts=-x ;;
+ * ) as_opts= ;;
+esac
+exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
+# Admittedly, this is quite paranoid, since all the known shells bail
+# out after a failed `exec'.
+$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
+exit 255
fi
if test x$as_have_required = xno; then :
@@ -339,6 +367,14 @@ $as_echo X"$as_dir" |
} # as_fn_mkdir_p
+
+# as_fn_executable_p FILE
+# -----------------------
+# Test if FILE is an executable regular file.
+as_fn_executable_p ()
+{
+ test -f "$1" && test -x "$1"
+} # as_fn_executable_p
# as_fn_append VAR VALUE
# ----------------------
# Append the text in VALUE to the end of the definition contained in VAR. Take
@@ -460,6 +496,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits
chmod +x "$as_me.lineno" ||
{ $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
+ # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
+ # already done that, so ensure we don't try to do so again and fall
+ # in an infinite loop. This has already happened in practice.
+ _as_can_reexec=no; export _as_can_reexec
# Don't try to exec as it changes $[0], causing all sort of problems
# (the dirname of $[0] is not the place where we might find the
# original and so on. Autoconf is especially sensitive to this).
@@ -494,16 +534,16 @@ if (echo >conf$$.file) 2>/dev/null; then
# ... but there are two gotchas:
# 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
# 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -p'.
+ # In both cases, we have to default to `cp -pR'.
ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -p'
+ as_ln_s='cp -pR'
elif ln conf$$.file conf$$ 2>/dev/null; then
as_ln_s=ln
else
- as_ln_s='cp -p'
+ as_ln_s='cp -pR'
fi
else
- as_ln_s='cp -p'
+ as_ln_s='cp -pR'
fi
rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
rmdir conf$$.dir 2>/dev/null
@@ -515,28 +555,8 @@ else
as_mkdir_p=false
fi
-if test -x / >/dev/null 2>&1; then
- as_test_x='test -x'
-else
- if ls -dL / >/dev/null 2>&1; then
- as_ls_L_option=L
- else
- as_ls_L_option=
- fi
- as_test_x='
- eval sh -c '\''
- if test -d "$1"; then
- test -d "$1/.";
- else
- case $1 in #(
- -*)set "./$1";;
- esac;
- case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
- ???[sx]*):;;*)false;;esac;fi
- '\'' sh
- '
-fi
-as_executable_p=$as_test_x
+as_test_x='test -x'
+as_executable_p=as_fn_executable_p
# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
@@ -570,8 +590,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='FreeType'
PACKAGE_TARNAME='freetype'
-PACKAGE_VERSION='2.4.8'
-PACKAGE_STRING='FreeType 2.4.8'
+PACKAGE_VERSION='2.4.11'
+PACKAGE_STRING='FreeType 2.4.11'
PACKAGE_BUGREPORT='freetype@nongnu.org'
PACKAGE_URL=''
@@ -645,6 +665,8 @@ FT2_EXTRA_LIBS
LIBBZ2
LIBZ
ftmac_c
+XX_ANSIFLAGS
+XX_CFLAGS
FTSYS_SRC
EGREP
GREP
@@ -652,9 +674,6 @@ INSTALL_DATA
INSTALL_SCRIPT
INSTALL_PROGRAM
RMDIR
-RMF
-XX_ANSIFLAGS
-XX_CFLAGS
EXEEXT_BUILD
CC_BUILD
CPP
@@ -1198,8 +1217,6 @@ target=$target_alias
if test "x$host_alias" != x; then
if test "x$build_alias" = x; then
cross_compiling=maybe
- $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
- If a cross compiler is detected then cross compile mode will be used" >&2
elif test "x$build_alias" != "x$host_alias"; then
cross_compiling=yes
fi
@@ -1285,7 +1302,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures FreeType 2.4.8 to adapt to many kinds of systems.
+\`configure' configures FreeType 2.4.11 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1350,7 +1367,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of FreeType 2.4.8:";;
+ short | recursive ) echo "Configuration of FreeType 2.4.11:";;
esac
cat <<\_ACEOF
@@ -1383,7 +1400,7 @@ Optional Packages:
--with-quickdraw-carbon use MacOS QuickDraw in Carbon, if available
(default=yes)
--with-ats use AppleTypeService, if available (default=yes)
- --with-pic try to use only PIC/non-PIC objects [default=use
+ --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
both]
--with-gnu-ld assume the C compiler uses GNU ld [default=no]
--with-sysroot=DIR Search for dependent libraries within DIR
@@ -1465,10 +1482,10 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-FreeType configure 2.4.8
-generated by GNU Autoconf 2.68
+FreeType configure 2.4.11
+generated by GNU Autoconf 2.69
-Copyright (C) 2010 Free Software Foundation, Inc.
+Copyright (C) 2012 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
@@ -1735,7 +1752,8 @@ int
main ()
{
static int test_array [1 - 2 * !(($2) >= 0)];
-test_array [0] = 0
+test_array [0] = 0;
+return test_array [0];
;
return 0;
@@ -1751,7 +1769,8 @@ int
main ()
{
static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0
+test_array [0] = 0;
+return test_array [0];
;
return 0;
@@ -1777,7 +1796,8 @@ int
main ()
{
static int test_array [1 - 2 * !(($2) < 0)];
-test_array [0] = 0
+test_array [0] = 0;
+return test_array [0];
;
return 0;
@@ -1793,7 +1813,8 @@ int
main ()
{
static int test_array [1 - 2 * !(($2) >= $ac_mid)];
-test_array [0] = 0
+test_array [0] = 0;
+return test_array [0];
;
return 0;
@@ -1827,7 +1848,8 @@ int
main ()
{
static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0
+test_array [0] = 0;
+return test_array [0];
;
return 0;
@@ -1923,7 +1945,7 @@ $as_echo "$ac_try_echo"; } >&5
test ! -s conftest.err
} && test -s conftest$ac_exeext && {
test "$cross_compiling" = yes ||
- $as_test_x conftest$ac_exeext
+ test -x conftest$ac_exeext
}; then :
ac_retval=0
else
@@ -2058,8 +2080,8 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by FreeType $as_me 2.4.8, which was
-generated by GNU Autoconf 2.68. Invocation command line was
+It was created by FreeType $as_me 2.4.11, which was
+generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@@ -2414,7 +2436,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
# Don't forget to update docs/VERSION.DLL!
-version_info='14:0:8'
+version_info='16:0:10'
ft_version=`echo $version_info | tr : .`
@@ -2548,7 +2570,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}gcc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -2588,7 +2610,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_CC="gcc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -2641,7 +2663,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}cc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -2682,7 +2704,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
ac_prog_rejected=yes
continue
@@ -2740,7 +2762,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -2784,7 +2806,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_CC="$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -3230,8 +3252,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <stdarg.h>
#include <stdio.h>
-#include <sys/types.h>
-#include <sys/stat.h>
+struct stat;
/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
struct buf { int x; };
FILE * (*rcsopen) (struct buf *, struct stat *, int);
@@ -3475,7 +3496,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC_BUILD="${build}-gcc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -3512,7 +3533,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC_BUILD="gcc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -3550,7 +3571,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
ac_prog_rejected=yes
continue
@@ -3614,68 +3635,8 @@ fi
-
-# get compiler flags right
-
-if test "x$GCC" = xyes; then
- XX_CFLAGS="-Wall"
- XX_ANSIFLAGS="-pedantic -ansi"
-else
- case "$host" in
- *-dec-osf*)
- CFLAGS=
- XX_CFLAGS="-std1 -g3"
- XX_ANSIFLAGS=
- ;;
- *)
- XX_CFLAGS=
- XX_ANSIFLAGS=
- ;;
- esac
-fi
-
-
-
-
# auxiliary programs
-# Extract the first word of "rm", so it can be a program name with args.
-set dummy rm; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RMF+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RMF"; then
- ac_cv_prog_RMF="$RMF" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_RMF="rm -f"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RMF=$ac_cv_prog_RMF
-if test -n "$RMF"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMF" >&5
-$as_echo "$RMF" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
# Extract the first word of "rmdir", so it can be a program name with args.
set dummy rmdir; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
@@ -3692,7 +3653,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_RMDIR="rmdir"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -3756,7 +3717,7 @@ case $as_dir/ in #((
# by default.
for ac_prog in ginstall scoinst install; do
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
if test $ac_prog = install &&
grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
# AIX install. It has an incompatible calling convention.
@@ -3841,7 +3802,7 @@ do
for ac_prog in grep ggrep; do
for ac_exec_ext in '' $ac_executable_extensions; do
ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
+ as_fn_executable_p "$ac_path_GREP" || continue
# Check for GNU ac_path_GREP and select it if it is found.
# Check for GNU $ac_path_GREP
case `"$ac_path_GREP" --version 2>&1` in
@@ -3907,7 +3868,7 @@ do
for ac_prog in egrep; do
for ac_exec_ext in '' $ac_executable_extensions; do
ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
+ as_fn_executable_p "$ac_path_EGREP" || continue
# Check for GNU ac_path_EGREP and select it if it is found.
# Check for GNU $ac_path_EGREP
case `"$ac_path_EGREP" --version 2>&1` in
@@ -4112,11 +4073,11 @@ else
int
main ()
{
-/* FIXME: Include the comments suggested by Paul. */
+
#ifndef __cplusplus
- /* Ultrix mips cc rejects this. */
+ /* Ultrix mips cc rejects this sort of thing. */
typedef int charset[2];
- const charset cs;
+ const charset cs = { 0, 0 };
/* SunOS 4.1.1 cc rejects this. */
char const *const *pcpcc;
char **ppc;
@@ -4133,8 +4094,9 @@ main ()
++pcpcc;
ppc = (char**) pcpcc;
pcpcc = (char const *const *) ppc;
- { /* SCO 3.2v4 cc rejects this. */
- char *t;
+ { /* SCO 3.2v4 cc rejects this sort of thing. */
+ char tx;
+ char *t = &tx;
char const *s = 0 ? (char *) 0 : (char const *) 0;
*t++ = 0;
@@ -4150,10 +4112,10 @@ main ()
iptr p = 0;
++p;
}
- { /* AIX XL C 1.02.0.0 rejects this saying
+ { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
"k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
- struct s { int j; const int *ap[3]; };
- struct s *b; b->j = 5;
+ struct s { int j; const int *ap[3]; } bx;
+ struct s *b = &bx; b->j = 5;
}
{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
const int foo = 10;
@@ -4251,12 +4213,18 @@ _ACEOF
# check whether cpp computation of size of int and long in ftconfig.in works
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking cpp computation of bit length in ftconfig.in works" >&5
-$as_echo_n "checking cpp computation of bit length in ftconfig.in works... " >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cpp computation of bit length in ftconfig.in works" >&5
+$as_echo_n "checking whether cpp computation of bit length in ftconfig.in works... " >&6; }
orig_CPPFLAGS="${CPPFLAGS}"
CPPFLAGS="-I${srcdir} -I. ${CPPFLAGS}"
-ac_clean_files="ft2build.h ftoption.h ftstdlib.h"
-touch ft2build.h ftoption.h ftstdlib.h
+
+ac_clean_files=
+for f in ft2build.h ftoption.h ftstdlib.h; do
+ if test ! -f $f; then
+ ac_clean_files="$ac_clean_files $f"
+ touch $f
+ fi
+done
cat > conftest.c <<\_ACEOF
#include <limits.h>
@@ -4275,7 +4243,7 @@ echo >> conftest.c "#endif"
${CPP} ${CPPFLAGS} conftest.c | ${GREP} ac_cpp_ft > conftest.sh
eval `cat conftest.sh`
-${RMF} conftest.c conftest.sh confft2build.h ftoption.h ftstdlib.h
+rm -f conftest.* $ac_clean_files
if test x != "x${ac_cpp_ft_sizeof_int}" \
-a x != x"${ac_cpp_ft_sizeof_long}"; then
@@ -4314,7 +4282,8 @@ $as_echo "no" >&6; }
esac
if test x"${ft_use_autoconf_sizeof_types}" = xyes; then
- $as_echo "#define FT_USE_AUTOCONF_SIZEOF_TYPES 1" >>confdefs.h
+
+$as_echo "#define FT_USE_AUTOCONF_SIZEOF_TYPES /**/" >>confdefs.h
fi
@@ -4604,6 +4573,67 @@ done
+# get compiler flags right
+# we try to make the compiler work for C89-strict source.
+# even if C compiler is GCC and C89 flags are available,
+# some system headers (e.g. Android Bionic libc) is broken
+# in C89 mode. we have to check the compilation finishes
+# successfully.
+#
+if test "x$GCC" = xyes; then
+ XX_CFLAGS="-Wall"
+ XX_ANSIFLAGS=""
+ for a in -pedantic -ansi
+ do
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking gcc compiler flag ${a} to assure ANSI C works correctly" >&5
+$as_echo_n "checking gcc compiler flag ${a} to assure ANSI C works correctly... " >&6; }
+ orig_CFLAGS="${CFLAGS}"
+ CFLAGS="${CFLAGS} ${XX_ANSIFLAGS} ${a}"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+ #include <stdio.h>
+int
+main ()
+{
+{puts("");return 0;}
+ ;
+ return 0;
+}
+
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok, add it to XX_ANSIFLAGS" >&5
+$as_echo "ok, add it to XX_ANSIFLAGS" >&6; }
+ XX_ANSIFLAGS="${XX_ANSIFLAGS} ${a}"
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ CFLAGS="${orig_CFLAGS}"
+ done
+else
+ case "$host" in
+ *-dec-osf*)
+ CFLAGS=
+ XX_CFLAGS="-std1 -g3"
+ XX_ANSIFLAGS=
+ ;;
+ *)
+ XX_CFLAGS=
+ XX_ANSIFLAGS=
+ ;;
+ esac
+fi
+
+
+
+
# check for system zlib
# don't quote AS_HELP_STRING!
@@ -4661,8 +4691,6 @@ fi
fi
if test x$with_zlib != xno && test -n "$LIBZ"; then
- CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_SYSTEM_ZLIB"
- LDFLAGS="$LDFLAGS $LIBZ"
SYSTEM_ZLIB=yes
fi
@@ -4723,8 +4751,7 @@ fi
fi
if test x$with_bzip2 != xno && test -n "$LIBBZ2"; then
- CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_USE_BZIP2"
- LDFLAGS="$LDFLAGS $LIBBZ2"
+ SYSTEM_LIBBZ2=yes
fi
# Some options handling SDKs/archs in CFLAGS should be copied
@@ -4755,8 +4782,8 @@ $as_echo "no, copy to LDFLAGS" >&6; }
shift 1
;;
-m32|-m64|-march=*|-mcpu=*) # options taking no argument
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: whether CFLAGS and LDFLAGS share ${c}" >&5
-$as_echo "whether CFLAGS and LDFLAGS share ${c}" >&6; }
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether CFLAGS and LDFLAGS share ${c}" >&5
+$as_echo_n "checking whether CFLAGS and LDFLAGS share ${c}... " >&6; }
if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
@@ -4827,9 +4854,9 @@ if ac_fn_c_try_link "$LINENO"; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
$as_echo "ok" >&6; }
ftmac_c='ftmac.c'
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking OS_INLINE macro is ANSI compatible" >&5
-$as_echo_n "checking OS_INLINE macro is ANSI compatible... " >&6; }
- orig_CFLAGS="$CFLAGS"
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether OS_INLINE macro is ANSI compatible" >&5
+$as_echo_n "checking whether OS_INLINE macro is ANSI compatible... " >&6; }
+ orig_CFLAGS="$CFLAGS -DFT_MACINTOSH"
CFLAGS="$CFLAGS $XX_CFLAGS $XX_ANSIFLAGS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -5313,9 +5340,6 @@ esac
-
-
-
case `pwd` in
*\ * | *\ *)
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
@@ -5324,8 +5348,8 @@ esac
-macro_version='2.4'
-macro_revision='1.3293'
+macro_version='2.4.2'
+macro_revision='1.3337'
@@ -5432,7 +5456,7 @@ do
for ac_prog in sed gsed; do
for ac_exec_ext in '' $ac_executable_extensions; do
ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue
+ as_fn_executable_p "$ac_path_SED" || continue
# Check for GNU ac_path_SED and select it if it is found.
# Check for GNU $ac_path_SED
case `"$ac_path_SED" --version 2>&1` in
@@ -5511,7 +5535,7 @@ do
for ac_prog in fgrep; do
for ac_exec_ext in '' $ac_executable_extensions; do
ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
- { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue
+ as_fn_executable_p "$ac_path_FGREP" || continue
# Check for GNU ac_path_FGREP and select it if it is found.
# Check for GNU $ac_path_FGREP
case `"$ac_path_FGREP" --version 2>&1` in
@@ -5767,7 +5791,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -5811,7 +5835,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -5969,6 +5993,11 @@ else
lt_cv_sys_max_cmd_len=196608
;;
+ os2*)
+ # The test takes a long time on OS/2.
+ lt_cv_sys_max_cmd_len=8192
+ ;;
+
osf*)
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
@@ -6008,7 +6037,7 @@ else
# If test is not a shell built-in, we'll probably end up computing a
# maximum length that is only half of the actual maximum length, but
# we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
+ while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
= "X$teststring$teststring"; } >/dev/null 2>&1 &&
test $i != 17 # 1/2 MB should be enough
do
@@ -6230,7 +6259,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6270,7 +6299,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OBJDUMP="objdump"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6434,7 +6463,7 @@ irix5* | irix6* | nonstopux*)
lt_cv_deplibs_check_method=pass_all
;;
-# This must be Linux ELF.
+# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
lt_cv_deplibs_check_method=pass_all
;;
@@ -6573,7 +6602,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6613,7 +6642,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_DLLTOOL="dlltool"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6713,7 +6742,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6757,7 +6786,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_AR="$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6882,7 +6911,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_STRIP="${ac_tool_prefix}strip"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6922,7 +6951,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_STRIP="strip"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -6981,7 +7010,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7021,7 +7050,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_RANLIB="ranlib"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7071,13 +7100,13 @@ old_postuninstall_cmds=
if test -n "$RANLIB"; then
case $host_os in
openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
+ old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
;;
*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
+ old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
;;
esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
+ old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
fi
case $host_os in
@@ -7125,7 +7154,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_AWK="$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7266,6 +7295,7 @@ for ac_symprfx in "" "_"; do
# which start with @ or ?.
lt_cv_sys_global_symbol_pipe="$AWK '"\
" {last_section=section; section=\$ 3};"\
+" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
" \$ 0!~/External *\|/{next};"\
" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
@@ -7654,7 +7684,7 @@ $as_echo "$lt_cv_cc_needs_belf" >&6; }
CFLAGS="$SAVE_CFLAGS"
fi
;;
-sparc*-*solaris*)
+*-*solaris*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
@@ -7665,7 +7695,20 @@ sparc*-*solaris*)
case `/usr/bin/file conftest.o` in
*64-bit*)
case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
+ yes*)
+ case $host in
+ i?86-*-solaris*)
+ LD="${LD-ld} -m elf_x86_64"
+ ;;
+ sparc*-*-solaris*)
+ LD="${LD-ld} -m elf64_sparc"
+ ;;
+ esac
+ # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
+ if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
+ LD="${LD-ld}_sol2"
+ fi
+ ;;
*)
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
LD="${LD-ld} -64"
@@ -7698,7 +7741,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7738,7 +7781,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7818,7 +7861,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7858,7 +7901,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7910,7 +7953,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -7950,7 +7993,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_NMEDIT="nmedit"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8002,7 +8045,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8042,7 +8085,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_LIPO="lipo"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8094,7 +8137,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8134,7 +8177,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OTOOL="otool"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8186,7 +8229,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8226,7 +8269,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OTOOL64="otool64"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8305,7 +8348,13 @@ else
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
-dynamiclib -Wl,-single_module conftest.c 2>conftest.err
_lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
+ # If there is a non-empty error log, and "single_module"
+ # appears in it, assume the flag caused a linker warning
+ if test -s conftest.err && $GREP single_module conftest.err; then
+ cat conftest.err >&5
+ # Otherwise, if the output was created with a 0 exit code from
+ # the compiler, it worked.
+ elif test -f libconftest.dylib && test $_lt_result -eq 0; then
lt_cv_apple_cc_single_mod=yes
else
cat conftest.err >&5
@@ -8316,6 +8365,7 @@ else
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
if ${lt_cv_ld_exported_symbols_list+:} false; then :
@@ -8348,6 +8398,7 @@ rm -f core conftest.err conftest.$ac_objext \
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
$as_echo_n "checking for -force_load linker flag... " >&6; }
if ${lt_cv_ld_force_load+:} false; then :
@@ -8369,7 +8420,9 @@ _LT_EOF
echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
_lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
+ if test -s conftest.err && $GREP force_load conftest.err; then
+ cat conftest.err >&5
+ elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
lt_cv_ld_force_load=yes
else
cat conftest.err >&5
@@ -8454,7 +8507,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_AS="${ac_tool_prefix}as"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8494,7 +8547,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_AS="as"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8546,7 +8599,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8586,7 +8639,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_DLLTOOL="dlltool"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8638,7 +8691,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8678,7 +8731,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OBJDUMP="objdump"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
@@ -8805,7 +8858,22 @@ fi
# Check whether --with-pic was given.
if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
+ withval=$with_pic; lt_p=${PACKAGE-default}
+ case $withval in
+ yes|no) pic_mode=$withval ;;
+ *)
+ pic_mode=default
+ # Look at the argument we got. We use all the common list separators.
+ lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
+ for lt_pkg in $withval; do
+ IFS="$lt_save_ifs"
+ if test "X$lt_pkg" = "X$lt_p"; then
+ pic_mode=yes
+ fi
+ done
+ IFS="$lt_save_ifs"
+ ;;
+ esac
else
pic_mode=default
fi
@@ -8883,6 +8951,10 @@ LIBTOOL='$(SHELL) $(top_builddir)/libtool'
+
+
+
+
test -z "$LN_S" && LN_S="ln -s"
@@ -9338,7 +9410,9 @@ lt_prog_compiler_static=
case $cc_basename in
nvcc*) # Cuda Compiler Driver 2.2
lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
+ if test -n "$lt_prog_compiler_pic"; then
+ lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
+ fi
;;
esac
else
@@ -9429,18 +9503,33 @@ lt_prog_compiler_static=
;;
*)
case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
+ *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
# Sun Fortran 8.3 passes all unrecognized flags to the linker
lt_prog_compiler_pic='-KPIC'
lt_prog_compiler_static='-Bstatic'
lt_prog_compiler_wl=''
;;
+ *Sun\ F* | *Sun*Fortran*)
+ lt_prog_compiler_pic='-KPIC'
+ lt_prog_compiler_static='-Bstatic'
+ lt_prog_compiler_wl='-Qoption ld '
+ ;;
*Sun\ C*)
# Sun C 5.9
lt_prog_compiler_pic='-KPIC'
lt_prog_compiler_static='-Bstatic'
lt_prog_compiler_wl='-Wl,'
;;
+ *Intel*\ [CF]*Compiler*)
+ lt_prog_compiler_wl='-Wl,'
+ lt_prog_compiler_pic='-fPIC'
+ lt_prog_compiler_static='-static'
+ ;;
+ *Portland\ Group*)
+ lt_prog_compiler_wl='-Wl,'
+ lt_prog_compiler_pic='-fpic'
+ lt_prog_compiler_static='-Bstatic'
+ ;;
esac
;;
esac
@@ -9802,7 +9891,6 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
hardcode_direct=no
hardcode_direct_absolute=no
hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
hardcode_libdir_separator=
hardcode_minus_L=no
hardcode_shlibpath_var=unsupported
@@ -10052,8 +10140,7 @@ _LT_EOF
xlf* | bgf* | bgxlf* | mpixlf*)
# IBM XL Fortran 10.1 on PPC cannot create shared libs itself
whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
+ hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
if test "x$supports_anon_versioning" = xyes; then
archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
@@ -10432,6 +10519,7 @@ fi
# The linker will not automatically build a static lib if we build a DLL.
# _LT_TAGVAR(old_archive_from_new_cmds, )='true'
enable_shared_with_static_runtimes=yes
+ exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
# Don't use ranlib
old_postinstall_cmds='chmod 644 $oldlib'
@@ -10477,6 +10565,7 @@ fi
hardcode_shlibpath_var=unsupported
if test "$lt_cv_ld_force_load" = "yes"; then
whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+
else
whole_archive_flag_spec=''
fi
@@ -10505,10 +10594,6 @@ fi
hardcode_shlibpath_var=no
;;
- freebsd1*)
- ld_shlibs=no
- ;;
-
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
# support. Future versions do this automatically, but an explicit c++rt0.o
# does not break anything, and helps significantly (at the cost of a little
@@ -10521,7 +10606,7 @@ fi
;;
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2*)
+ freebsd2.*)
archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
hardcode_direct=yes
hardcode_minus_L=yes
@@ -10560,7 +10645,6 @@ fi
fi
if test "$with_gnu_ld" = no; then
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
hardcode_libdir_separator=:
hardcode_direct=yes
hardcode_direct_absolute=yes
@@ -11184,11 +11268,6 @@ esac
-
-
-
-
-
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
$as_echo_n "checking dynamic linker characteristics... " >&6; }
@@ -11278,7 +11357,7 @@ need_version=unknown
case $host_os in
aix3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
shlibpath_var=LIBPATH
@@ -11287,7 +11366,7 @@ aix3*)
;;
aix[4-9]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
hardcode_into_libs=yes
@@ -11352,7 +11431,7 @@ beos*)
;;
bsdi[45]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
@@ -11491,7 +11570,7 @@ darwin* | rhapsody*)
;;
dgux*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
@@ -11499,10 +11578,6 @@ dgux*)
shlibpath_var=LD_LIBRARY_PATH
;;
-freebsd1*)
- dynamic_linker=no
- ;;
-
freebsd* | dragonfly*)
# DragonFly does not have aout. When/if they implement a new
# versioning mechanism, adjust this.
@@ -11510,7 +11585,7 @@ freebsd* | dragonfly*)
objformat=`/usr/bin/objformat`
else
case $host_os in
- freebsd[123]*) objformat=aout ;;
+ freebsd[23].*) objformat=aout ;;
*) objformat=elf ;;
esac
fi
@@ -11528,7 +11603,7 @@ freebsd* | dragonfly*)
esac
shlibpath_var=LD_LIBRARY_PATH
case $host_os in
- freebsd2*)
+ freebsd2.*)
shlibpath_overrides_runpath=yes
;;
freebsd3.[01]* | freebsdelf3.[01]*)
@@ -11548,17 +11623,18 @@ freebsd* | dragonfly*)
;;
gnu*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
+ shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
haiku*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
dynamic_linker="$host_os runtime_loader"
@@ -11619,7 +11695,7 @@ hpux9* | hpux10* | hpux11*)
;;
interix[3-9]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
@@ -11635,7 +11711,7 @@ irix5* | irix6* | nonstopux*)
nonstopux*) version_type=nonstopux ;;
*)
if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
else
version_type=irix
fi ;;
@@ -11672,9 +11748,9 @@ linux*oldld* | linux*aout* | linux*coff*)
dynamic_linker=no
;;
-# This must be Linux ELF.
+# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -11756,7 +11832,7 @@ netbsd*)
;;
newsos6)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
@@ -11825,7 +11901,7 @@ rdos*)
;;
solaris*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -11850,7 +11926,7 @@ sunos4*)
;;
sysv4 | sysv4.3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
@@ -11874,7 +11950,7 @@ sysv4 | sysv4.3*)
sysv4*MP*)
if test -d /usr/nec ;then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
soname_spec='$libname${shared_ext}.$major'
shlibpath_var=LD_LIBRARY_PATH
@@ -11905,7 +11981,7 @@ sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
tpf*)
# TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -11915,7 +11991,7 @@ tpf*)
;;
uts4*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
@@ -12697,6 +12773,8 @@ CC="$lt_save_CC"
+
+
ac_config_commands="$ac_config_commands libtool"
@@ -12710,6 +12788,20 @@ CC="$lt_save_CC"
+# changing LDFLAGS value should only be done after
+# lt_cv_prog_compiler_static_works test
+if test x$SYSTEM_ZLIB = xyes; then
+ CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_SYSTEM_ZLIB"
+ LDFLAGS="$LDFLAGS $LIBZ"
+fi
+
+if test x$SYSTEM_LIBBZ2 = xyes; then
+ CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_USE_BZIP2"
+ LDFLAGS="$LDFLAGS $LIBBZ2"
+fi
+
+
+
# configuration file -- stay in 8.3 limit
#
@@ -13136,16 +13228,16 @@ if (echo >conf$$.file) 2>/dev/null; then
# ... but there are two gotchas:
# 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
# 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -p'.
+ # In both cases, we have to default to `cp -pR'.
ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -p'
+ as_ln_s='cp -pR'
elif ln conf$$.file conf$$ 2>/dev/null; then
as_ln_s=ln
else
- as_ln_s='cp -p'
+ as_ln_s='cp -pR'
fi
else
- as_ln_s='cp -p'
+ as_ln_s='cp -pR'
fi
rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
rmdir conf$$.dir 2>/dev/null
@@ -13205,28 +13297,16 @@ else
as_mkdir_p=false
fi
-if test -x / >/dev/null 2>&1; then
- as_test_x='test -x'
-else
- if ls -dL / >/dev/null 2>&1; then
- as_ls_L_option=L
- else
- as_ls_L_option=
- fi
- as_test_x='
- eval sh -c '\''
- if test -d "$1"; then
- test -d "$1/.";
- else
- case $1 in #(
- -*)set "./$1";;
- esac;
- case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
- ???[sx]*):;;*)false;;esac;fi
- '\'' sh
- '
-fi
-as_executable_p=$as_test_x
+
+# as_fn_executable_p FILE
+# -----------------------
+# Test if FILE is an executable regular file.
+as_fn_executable_p ()
+{
+ test -f "$1" && test -x "$1"
+} # as_fn_executable_p
+as_test_x='test -x'
+as_executable_p=as_fn_executable_p
# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
@@ -13247,8 +13327,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by FreeType $as_me 2.4.8, which was
-generated by GNU Autoconf 2.68. Invocation command line was
+This file was extended by FreeType $as_me 2.4.11, which was
+generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -13313,11 +13393,11 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-FreeType config.status 2.4.8
-configured by $0, generated by GNU Autoconf 2.68,
+FreeType config.status 2.4.11
+configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
-Copyright (C) 2010 Free Software Foundation, Inc.
+Copyright (C) 2012 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
@@ -13407,7 +13487,7 @@ fi
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
if \$ac_cs_recheck; then
- set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+ set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
shift
\$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
CONFIG_SHELL='$SHELL'
@@ -13451,6 +13531,7 @@ pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
+PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
@@ -13531,7 +13612,6 @@ with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
@@ -13590,6 +13670,7 @@ DLLTOOL \
OBJDUMP \
SHELL \
ECHO \
+PATH_SEPARATOR \
SED \
GREP \
EGREP \
@@ -13638,7 +13719,6 @@ with_gnu_ld \
allow_undefined_flag \
no_undefined_flag \
hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
hardcode_libdir_separator \
exclude_expsyms \
include_expsyms \
@@ -14301,8 +14381,8 @@ $as_echo "$as_me: executing $ac_file commands" >&6;}
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
#
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
-# Inc.
+# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is part of GNU Libtool.
@@ -14365,6 +14445,9 @@ SHELL=$lt_SHELL
# An echo program that protects backslashes.
ECHO=$lt_ECHO
+# The PATH separator for the build system.
+PATH_SEPARATOR=$lt_PATH_SEPARATOR
+
# The host system.
host_alias=$host_alias
host=$host
@@ -14660,10 +14743,6 @@ no_undefined_flag=$lt_no_undefined_flag
# This must work even if \$libdir does not exist
hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
# Whether we need a single "-rpath" flag with a separated argument.
hardcode_libdir_separator=$lt_hardcode_libdir_separator
diff --git a/3party/freetype/builds/unix/configure.ac b/3party/freetype/builds/unix/configure.ac
index e6cdb8e438..7189d4e812 100644
--- a/3party/freetype/builds/unix/configure.ac
+++ b/3party/freetype/builds/unix/configure.ac
@@ -2,7 +2,7 @@
#
# Process this file with autoconf to produce a configure script.
#
-# Copyright 2001-2011 by
+# Copyright 2001-2012 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -11,13 +11,13 @@
# indicate that you have read the license and understand and accept it
# fully.
-AC_INIT([FreeType], [2.4.8], [freetype@nongnu.org], [freetype])
+AC_INIT([FreeType], [2.4.11], [freetype@nongnu.org], [freetype])
AC_CONFIG_SRCDIR([ftconfig.in])
# Don't forget to update docs/VERSION.DLL!
-version_info='14:0:8'
+version_info='16:0:10'
AC_SUBST([version_info])
ft_version=`echo $version_info | tr : .`
AC_SUBST([ft_version])
@@ -66,32 +66,8 @@ AC_SUBST(CC_BUILD)
AC_SUBST(EXEEXT_BUILD)
-
-# get compiler flags right
-
-if test "x$GCC" = xyes; then
- XX_CFLAGS="-Wall"
- XX_ANSIFLAGS="-pedantic -ansi"
-else
- case "$host" in
- *-dec-osf*)
- CFLAGS=
- XX_CFLAGS="-std1 -g3"
- XX_ANSIFLAGS=
- ;;
- *)
- XX_CFLAGS=
- XX_ANSIFLAGS=
- ;;
- esac
-fi
-AC_SUBST([XX_CFLAGS])
-AC_SUBST([XX_ANSIFLAGS])
-
-
# auxiliary programs
-AC_CHECK_PROG([RMF], [rm], [rm -f])
AC_CHECK_PROG([RMDIR], [rmdir], [rmdir])
@@ -124,11 +100,17 @@ AC_CHECK_SIZEOF([long])
# check whether cpp computation of size of int and long in ftconfig.in works
-AC_MSG_CHECKING([cpp computation of bit length in ftconfig.in works])
+AC_MSG_CHECKING([whether cpp computation of bit length in ftconfig.in works])
orig_CPPFLAGS="${CPPFLAGS}"
CPPFLAGS="-I${srcdir} -I. ${CPPFLAGS}"
-ac_clean_files="ft2build.h ftoption.h ftstdlib.h"
-touch ft2build.h ftoption.h ftstdlib.h
+
+ac_clean_files=
+for f in ft2build.h ftoption.h ftstdlib.h; do
+ if test ! -f $f; then
+ ac_clean_files="$ac_clean_files $f"
+ touch $f
+ fi
+done
cat > conftest.c <<\_ACEOF
#include <limits.h>
@@ -147,7 +129,7 @@ echo >> conftest.c "#endif"
${CPP} ${CPPFLAGS} conftest.c | ${GREP} ac_cpp_ft > conftest.sh
eval `cat conftest.sh`
-${RMF} conftest.c conftest.sh confft2build.h ftoption.h ftstdlib.h
+rm -f conftest.* $ac_clean_files
if test x != "x${ac_cpp_ft_sizeof_int}" \
-a x != x"${ac_cpp_ft_sizeof_long}"; then
@@ -180,7 +162,8 @@ case :${ft_use_autoconf_sizeof_types}:${enable_biarch_config}: in
esac
if test x"${ft_use_autoconf_sizeof_types}" = xyes; then
- AC_DEFINE([FT_USE_AUTOCONF_SIZEOF_TYPES])
+ AC_DEFINE([FT_USE_AUTOCONF_SIZEOF_TYPES], [],
+ [Define if autoconf sizeof types should be used.])
fi
CPPFLAGS="${orig_CPPFLAGS}"
@@ -222,6 +205,48 @@ AC_SUBST([FTSYS_SRC])
AC_CHECK_FUNCS([memcpy memmove])
+# get compiler flags right
+# we try to make the compiler work for C89-strict source.
+# even if C compiler is GCC and C89 flags are available,
+# some system headers (e.g. Android Bionic libc) is broken
+# in C89 mode. we have to check the compilation finishes
+# successfully.
+#
+if test "x$GCC" = xyes; then
+ XX_CFLAGS="-Wall"
+ XX_ANSIFLAGS=""
+ for a in -pedantic -ansi
+ do
+ AC_MSG_CHECKING([gcc compiler flag ${a} to assure ANSI C works correctly])
+ orig_CFLAGS="${CFLAGS}"
+ CFLAGS="${CFLAGS} ${XX_ANSIFLAGS} ${a}"
+ AC_COMPILE_IFELSE([
+ AC_LANG_PROGRAM([#include <stdio.h>],[{puts("");return 0;}])
+ ],[
+ AC_MSG_RESULT([ok, add it to XX_ANSIFLAGS])
+ XX_ANSIFLAGS="${XX_ANSIFLAGS} ${a}"
+ ],[
+ AC_MSG_RESULT([no])
+ ])
+ CFLAGS="${orig_CFLAGS}"
+ done
+else
+ case "$host" in
+ *-dec-osf*)
+ CFLAGS=
+ XX_CFLAGS="-std1 -g3"
+ XX_ANSIFLAGS=
+ ;;
+ *)
+ XX_CFLAGS=
+ XX_ANSIFLAGS=
+ ;;
+ esac
+fi
+AC_SUBST([XX_CFLAGS])
+AC_SUBST([XX_ANSIFLAGS])
+
+
# check for system zlib
# don't quote AS_HELP_STRING!
@@ -232,8 +257,6 @@ if test x$with_zlib != xno && test -z "$LIBZ"; then
AC_CHECK_LIB([z], [gzsetparams], [AC_CHECK_HEADER([zlib.h], [LIBZ='-lz'])])
fi
if test x$with_zlib != xno && test -n "$LIBZ"; then
- CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_SYSTEM_ZLIB"
- LDFLAGS="$LDFLAGS $LIBZ"
SYSTEM_ZLIB=yes
fi
@@ -247,8 +270,7 @@ if test x$with_bzip2 != xno && test -z "$LIBBZ2"; then
AC_CHECK_LIB([bz2], [BZ2_bzDecompress], [AC_CHECK_HEADER([bzlib.h], [LIBBZ2='-lbz2'])])
fi
if test x$with_bzip2 != xno && test -n "$LIBBZ2"; then
- CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_USE_BZIP2"
- LDFLAGS="$LDFLAGS $LIBBZ2"
+ SYSTEM_LIBBZ2=yes
fi
# Some options handling SDKs/archs in CFLAGS should be copied
@@ -276,7 +298,7 @@ do
shift 1
;;
-m32|-m64|-march=*|-mcpu=*) # options taking no argument
- AC_MSG_RESULT([whether CFLAGS and LDFLAGS share ${c}])
+ AC_MSG_CHECKING([whether CFLAGS and LDFLAGS share ${c}])
if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
then
AC_MSG_RESULT([yes])
@@ -330,8 +352,8 @@ if test x$with_old_mac_fonts = xyes; then
])],
[AC_MSG_RESULT([ok])
ftmac_c='ftmac.c'
- AC_MSG_CHECKING([OS_INLINE macro is ANSI compatible])
- orig_CFLAGS="$CFLAGS"
+ AC_MSG_CHECKING([whether OS_INLINE macro is ANSI compatible])
+ orig_CFLAGS="$CFLAGS -DFT_MACINTOSH"
CFLAGS="$CFLAGS $XX_CFLAGS $XX_ANSIFLAGS"
AC_COMPILE_IFELSE([
AC_LANG_PROGRAM([
@@ -667,18 +689,29 @@ esac
AC_SUBST([ftmac_c])
AC_SUBST([LIBZ])
AC_SUBST([LIBBZ2])
-AC_SUBST([CFLAGS])
-AC_SUBST([LDFLAGS])
AC_SUBST([FT2_EXTRA_LIBS])
AC_SUBST([SYSTEM_ZLIB])
-
LT_INIT(win32-dll)
AC_SUBST([hardcode_libdir_flag_spec])
AC_SUBST([wl])
AC_SUBST([build_libtool_libs])
+# changing LDFLAGS value should only be done after
+# lt_cv_prog_compiler_static_works test
+if test x$SYSTEM_ZLIB = xyes; then
+ CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_SYSTEM_ZLIB"
+ LDFLAGS="$LDFLAGS $LIBZ"
+fi
+
+if test x$SYSTEM_LIBBZ2 = xyes; then
+ CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_USE_BZIP2"
+ LDFLAGS="$LDFLAGS $LIBBZ2"
+fi
+
+AC_SUBST([CFLAGS])
+AC_SUBST([LDFLAGS])
# configuration file -- stay in 8.3 limit
#
diff --git a/3party/freetype/builds/unix/configure.raw b/3party/freetype/builds/unix/configure.raw
index c557480955..bf26061f02 100644
--- a/3party/freetype/builds/unix/configure.raw
+++ b/3party/freetype/builds/unix/configure.raw
@@ -2,7 +2,7 @@
#
# Process this file with autoconf to produce a configure script.
#
-# Copyright 2001-2011 by
+# Copyright 2001-2012 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -17,7 +17,7 @@ AC_CONFIG_SRCDIR([ftconfig.in])
# Don't forget to update docs/VERSION.DLL!
-version_info='14:0:8'
+version_info='16:0:10'
AC_SUBST([version_info])
ft_version=`echo $version_info | tr : .`
AC_SUBST([ft_version])
@@ -66,32 +66,8 @@ AC_SUBST(CC_BUILD)
AC_SUBST(EXEEXT_BUILD)
-
-# get compiler flags right
-
-if test "x$GCC" = xyes; then
- XX_CFLAGS="-Wall"
- XX_ANSIFLAGS="-pedantic -ansi"
-else
- case "$host" in
- *-dec-osf*)
- CFLAGS=
- XX_CFLAGS="-std1 -g3"
- XX_ANSIFLAGS=
- ;;
- *)
- XX_CFLAGS=
- XX_ANSIFLAGS=
- ;;
- esac
-fi
-AC_SUBST([XX_CFLAGS])
-AC_SUBST([XX_ANSIFLAGS])
-
-
# auxiliary programs
-AC_CHECK_PROG([RMF], [rm], [rm -f])
AC_CHECK_PROG([RMDIR], [rmdir], [rmdir])
@@ -124,11 +100,17 @@ AC_CHECK_SIZEOF([long])
# check whether cpp computation of size of int and long in ftconfig.in works
-AC_MSG_CHECKING([cpp computation of bit length in ftconfig.in works])
+AC_MSG_CHECKING([whether cpp computation of bit length in ftconfig.in works])
orig_CPPFLAGS="${CPPFLAGS}"
CPPFLAGS="-I${srcdir} -I. ${CPPFLAGS}"
-ac_clean_files="ft2build.h ftoption.h ftstdlib.h"
-touch ft2build.h ftoption.h ftstdlib.h
+
+ac_clean_files=
+for f in ft2build.h ftoption.h ftstdlib.h; do
+ if test ! -f $f; then
+ ac_clean_files="$ac_clean_files $f"
+ touch $f
+ fi
+done
cat > conftest.c <<\_ACEOF
#include <limits.h>
@@ -147,7 +129,7 @@ echo >> conftest.c "#endif"
${CPP} ${CPPFLAGS} conftest.c | ${GREP} ac_cpp_ft > conftest.sh
eval `cat conftest.sh`
-${RMF} conftest.c conftest.sh confft2build.h ftoption.h ftstdlib.h
+rm -f conftest.* $ac_clean_files
if test x != "x${ac_cpp_ft_sizeof_int}" \
-a x != x"${ac_cpp_ft_sizeof_long}"; then
@@ -180,7 +162,8 @@ case :${ft_use_autoconf_sizeof_types}:${enable_biarch_config}: in
esac
if test x"${ft_use_autoconf_sizeof_types}" = xyes; then
- AC_DEFINE([FT_USE_AUTOCONF_SIZEOF_TYPES])
+ AC_DEFINE([FT_USE_AUTOCONF_SIZEOF_TYPES], [],
+ [Define if autoconf sizeof types should be used.])
fi
CPPFLAGS="${orig_CPPFLAGS}"
@@ -222,6 +205,48 @@ AC_SUBST([FTSYS_SRC])
AC_CHECK_FUNCS([memcpy memmove])
+# get compiler flags right
+# we try to make the compiler work for C89-strict source.
+# even if C compiler is GCC and C89 flags are available,
+# some system headers (e.g. Android Bionic libc) is broken
+# in C89 mode. we have to check the compilation finishes
+# successfully.
+#
+if test "x$GCC" = xyes; then
+ XX_CFLAGS="-Wall"
+ XX_ANSIFLAGS=""
+ for a in -pedantic -ansi
+ do
+ AC_MSG_CHECKING([gcc compiler flag ${a} to assure ANSI C works correctly])
+ orig_CFLAGS="${CFLAGS}"
+ CFLAGS="${CFLAGS} ${XX_ANSIFLAGS} ${a}"
+ AC_COMPILE_IFELSE([
+ AC_LANG_PROGRAM([#include <stdio.h>],[{puts("");return 0;}])
+ ],[
+ AC_MSG_RESULT([ok, add it to XX_ANSIFLAGS])
+ XX_ANSIFLAGS="${XX_ANSIFLAGS} ${a}"
+ ],[
+ AC_MSG_RESULT([no])
+ ])
+ CFLAGS="${orig_CFLAGS}"
+ done
+else
+ case "$host" in
+ *-dec-osf*)
+ CFLAGS=
+ XX_CFLAGS="-std1 -g3"
+ XX_ANSIFLAGS=
+ ;;
+ *)
+ XX_CFLAGS=
+ XX_ANSIFLAGS=
+ ;;
+ esac
+fi
+AC_SUBST([XX_CFLAGS])
+AC_SUBST([XX_ANSIFLAGS])
+
+
# check for system zlib
# don't quote AS_HELP_STRING!
@@ -232,8 +257,6 @@ if test x$with_zlib != xno && test -z "$LIBZ"; then
AC_CHECK_LIB([z], [gzsetparams], [AC_CHECK_HEADER([zlib.h], [LIBZ='-lz'])])
fi
if test x$with_zlib != xno && test -n "$LIBZ"; then
- CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_SYSTEM_ZLIB"
- LDFLAGS="$LDFLAGS $LIBZ"
SYSTEM_ZLIB=yes
fi
@@ -247,8 +270,7 @@ if test x$with_bzip2 != xno && test -z "$LIBBZ2"; then
AC_CHECK_LIB([bz2], [BZ2_bzDecompress], [AC_CHECK_HEADER([bzlib.h], [LIBBZ2='-lbz2'])])
fi
if test x$with_bzip2 != xno && test -n "$LIBBZ2"; then
- CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_USE_BZIP2"
- LDFLAGS="$LDFLAGS $LIBBZ2"
+ SYSTEM_LIBBZ2=yes
fi
# Some options handling SDKs/archs in CFLAGS should be copied
@@ -276,7 +298,7 @@ do
shift 1
;;
-m32|-m64|-march=*|-mcpu=*) # options taking no argument
- AC_MSG_RESULT([whether CFLAGS and LDFLAGS share ${c}])
+ AC_MSG_CHECKING([whether CFLAGS and LDFLAGS share ${c}])
if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
then
AC_MSG_RESULT([yes])
@@ -330,8 +352,8 @@ if test x$with_old_mac_fonts = xyes; then
])],
[AC_MSG_RESULT([ok])
ftmac_c='ftmac.c'
- AC_MSG_CHECKING([OS_INLINE macro is ANSI compatible])
- orig_CFLAGS="$CFLAGS"
+ AC_MSG_CHECKING([whether OS_INLINE macro is ANSI compatible])
+ orig_CFLAGS="$CFLAGS -DFT_MACINTOSH"
CFLAGS="$CFLAGS $XX_CFLAGS $XX_ANSIFLAGS"
AC_COMPILE_IFELSE([
AC_LANG_PROGRAM([
@@ -667,18 +689,29 @@ esac
AC_SUBST([ftmac_c])
AC_SUBST([LIBZ])
AC_SUBST([LIBBZ2])
-AC_SUBST([CFLAGS])
-AC_SUBST([LDFLAGS])
AC_SUBST([FT2_EXTRA_LIBS])
AC_SUBST([SYSTEM_ZLIB])
-
LT_INIT(win32-dll)
AC_SUBST([hardcode_libdir_flag_spec])
AC_SUBST([wl])
AC_SUBST([build_libtool_libs])
+# changing LDFLAGS value should only be done after
+# lt_cv_prog_compiler_static_works test
+if test x$SYSTEM_ZLIB = xyes; then
+ CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_SYSTEM_ZLIB"
+ LDFLAGS="$LDFLAGS $LIBZ"
+fi
+
+if test x$SYSTEM_LIBBZ2 = xyes; then
+ CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_USE_BZIP2"
+ LDFLAGS="$LDFLAGS $LIBBZ2"
+fi
+
+AC_SUBST([CFLAGS])
+AC_SUBST([LDFLAGS])
# configuration file -- stay in 8.3 limit
#
diff --git a/3party/freetype/builds/unix/detect.mk b/3party/freetype/builds/unix/detect.mk
index e74af57308..b2ae4f42bc 100644
--- a/3party/freetype/builds/unix/detect.mk
+++ b/3party/freetype/builds/unix/detect.mk
@@ -20,6 +20,7 @@ ifeq ($(PLATFORM),ansi)
#
is_unix := $(strip $(wildcard /sbin/init) \
$(wildcard /usr/sbin/init) \
+ $(wildcard /dev/null) \
$(wildcard /hurd/auth))
ifneq ($(is_unix),)
diff --git a/3party/freetype/builds/unix/ftconfig.in b/3party/freetype/builds/unix/ftconfig.in
index fd4a5cd4fa..9531afda18 100644
--- a/3party/freetype/builds/unix/ftconfig.in
+++ b/3party/freetype/builds/unix/ftconfig.in
@@ -142,8 +142,7 @@ FT_BEGIN_HEADER
/* This is the only necessary change, so it is defined here instead */
/* providing a new configuration file. */
/* */
-#if ( defined( __APPLE__ ) && !defined( DARWIN_NO_CARBON ) ) || \
- ( defined( __MWERKS__ ) && defined( macintosh ) )
+#if defined( __APPLE__ ) || ( defined( __MWERKS__ ) && defined( macintosh ) )
/* no Carbon frameworks for 64bit 10.4.x */
/* AvailabilityMacros.h is available since Mac OS X 10.2, */
/* so guess the system version by maximum errno before inclusion */
@@ -153,9 +152,7 @@ FT_BEGIN_HEADER
#endif
#if defined( __LP64__ ) && \
( MAC_OS_X_VERSION_MIN_REQUIRED <= MAC_OS_X_VERSION_10_4 )
-#define DARWIN_NO_CARBON 1
-#else
-#define FT_MACINTOSH 1
+/undef FT_MACINTOSH
#endif
#elif defined( __SC__ ) || defined( __MRC__ )
diff --git a/3party/freetype/builds/unix/install-sh b/3party/freetype/builds/unix/install-sh
index 3f83ce9b55..a9244eb078 100755
--- a/3party/freetype/builds/unix/install-sh
+++ b/3party/freetype/builds/unix/install-sh
@@ -1,7 +1,7 @@
#!/bin/sh
# install - install a program, script, or datafile
-scriptversion=2010-02-06.18; # UTC
+scriptversion=2011-01-19.21; # UTC
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
@@ -156,6 +156,10 @@ while test $# -ne 0; do
-s) stripcmd=$stripprog;;
-t) dst_arg=$2
+ # Protect names problematic for `test' and other utilities.
+ case $dst_arg in
+ -* | [=\(\)!]) dst_arg=./$dst_arg;;
+ esac
shift;;
-T) no_target_directory=true;;
@@ -186,6 +190,10 @@ if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then
fi
shift # arg
dst_arg=$arg
+ # Protect names problematic for `test' and other utilities.
+ case $dst_arg in
+ -* | [=\(\)!]) dst_arg=./$dst_arg;;
+ esac
done
fi
@@ -232,9 +240,9 @@ fi
for src
do
- # Protect names starting with `-'.
+ # Protect names problematic for `test' and other utilities.
case $src in
- -*) src=./$src;;
+ -* | [=\(\)!]) src=./$src;;
esac
if test -n "$dir_arg"; then
@@ -256,12 +264,7 @@ do
echo "$0: no destination specified." >&2
exit 1
fi
-
dst=$dst_arg
- # Protect names starting with `-'.
- case $dst in
- -*) dst=./$dst;;
- esac
# If destination is a directory, append the input filename; won't work
# if double slashes aren't ignored.
@@ -389,7 +392,7 @@ do
case $dstdir in
/*) prefix='/';;
- -*) prefix='./';;
+ [-=\(\)!]*) prefix='./';;
*) prefix='';;
esac
@@ -407,7 +410,7 @@ do
for d
do
- test -z "$d" && continue
+ test X"$d" = X && continue
prefix=$prefix$d
if test -d "$prefix"; then
diff --git a/3party/freetype/builds/unix/ltmain.sh b/3party/freetype/builds/unix/ltmain.sh
index 3061e3c5a2..63ae69dc6f 100755..100644
--- a/3party/freetype/builds/unix/ltmain.sh
+++ b/3party/freetype/builds/unix/ltmain.sh
@@ -1,9 +1,9 @@
-# libtool (GNU libtool) 2.4
+# libtool (GNU libtool) 2.4.2
# Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
-# 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
+# 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
# This is free software; see the source for copying conditions. There is NO
# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
@@ -41,6 +41,7 @@
# --quiet, --silent don't print informational messages
# --no-quiet, --no-silent
# print informational messages (default)
+# --no-warn don't display warning messages
# --tag=TAG use configuration variables from tag TAG
# -v, --verbose print more informational messages than default
# --no-verbose don't print the extra informational messages
@@ -69,7 +70,7 @@
# compiler: $LTCC
# compiler flags: $LTCFLAGS
# linker: $LD (gnu? $with_gnu_ld)
-# $progname: (GNU libtool) 2.4
+# $progname: (GNU libtool) 2.4.2
# automake: $automake_version
# autoconf: $autoconf_version
#
@@ -79,9 +80,9 @@
PROGRAM=libtool
PACKAGE=libtool
-VERSION=2.4
+VERSION=2.4.2
TIMESTAMP=""
-package_revision=1.3293
+package_revision=1.3337
# Be Bourne compatible
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
@@ -136,15 +137,10 @@ progpath="$0"
: ${CP="cp -f"}
test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'}
-: ${EGREP="grep -E"}
-: ${FGREP="grep -F"}
-: ${GREP="grep"}
-: ${LN_S="ln -s"}
: ${MAKE="make"}
: ${MKDIR="mkdir"}
: ${MV="mv -f"}
: ${RM="rm -f"}
-: ${SED="sed"}
: ${SHELL="${CONFIG_SHELL-/bin/sh}"}
: ${Xsed="$SED -e 1s/^X//"}
@@ -387,7 +383,7 @@ case $progpath in
;;
*)
save_IFS="$IFS"
- IFS=:
+ IFS=${PATH_SEPARATOR-:}
for progdir in $PATH; do
IFS="$save_IFS"
test -x "$progdir/$progname" && break
@@ -771,8 +767,8 @@ func_help ()
s*\$LTCFLAGS*'"$LTCFLAGS"'*
s*\$LD*'"$LD"'*
s/\$with_gnu_ld/'"$with_gnu_ld"'/
- s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/
- s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/
+ s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/
+ s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/
p
d
}
@@ -1052,6 +1048,7 @@ opt_finish=false
opt_help=false
opt_help_all=false
opt_silent=:
+opt_warning=:
opt_verbose=:
opt_silent=false
opt_verbose=false
@@ -1120,6 +1117,10 @@ esac
opt_silent=false
func_append preserve_args " $opt"
;;
+ --no-warning|--no-warn)
+ opt_warning=false
+func_append preserve_args " $opt"
+ ;;
--no-verbose)
opt_verbose=false
func_append preserve_args " $opt"
@@ -2059,7 +2060,7 @@ func_mode_compile ()
*.[cCFSifmso] | \
*.ada | *.adb | *.ads | *.asm | \
*.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \
- *.[fF][09]? | *.for | *.java | *.obj | *.sx | *.cu | *.cup)
+ *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup)
func_xform "$libobj"
libobj=$func_xform_result
;;
@@ -3201,11 +3202,13 @@ func_mode_install ()
# Set up the ranlib parameters.
oldlib="$destdir/$name"
+ func_to_tool_file "$oldlib" func_convert_file_msys_to_w32
+ tool_oldlib=$func_to_tool_file_result
func_show_eval "$install_prog \$file \$oldlib" 'exit $?'
if test -n "$stripme" && test -n "$old_striplib"; then
- func_show_eval "$old_striplib $oldlib" 'exit $?'
+ func_show_eval "$old_striplib $tool_oldlib" 'exit $?'
fi
# Do each command in the postinstall commands.
@@ -3470,7 +3473,7 @@ static const void *lt_preloaded_setup() {
# linked before any other PIC object. But we must not use
# pic_flag when linking with -static. The problem exists in
# FreeBSD 2.2.6 and is fixed in FreeBSD 3.1.
- *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*)
+ *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*)
pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;;
*-*-hpux*)
pic_flag_for_symtable=" $pic_flag" ;;
@@ -3982,14 +3985,17 @@ func_exec_program_core ()
# launches target application with the remaining arguments.
func_exec_program ()
{
- for lt_wr_arg
- do
- case \$lt_wr_arg in
- --lt-*) ;;
- *) set x \"\$@\" \"\$lt_wr_arg\"; shift;;
- esac
- shift
- done
+ case \" \$* \" in
+ *\\ --lt-*)
+ for lt_wr_arg
+ do
+ case \$lt_wr_arg in
+ --lt-*) ;;
+ *) set x \"\$@\" \"\$lt_wr_arg\"; shift;;
+ esac
+ shift
+ done ;;
+ esac
func_exec_program_core \${1+\"\$@\"}
}
@@ -5057,9 +5063,15 @@ void lt_dump_script (FILE* f)
{
EOF
func_emit_wrapper yes |
- $SED -e 's/\([\\"]\)/\\\1/g' \
- -e 's/^/ fputs ("/' -e 's/$/\\n", f);/'
-
+ $SED -n -e '
+s/^\(.\{79\}\)\(..*\)/\1\
+\2/
+h
+s/\([\\"]\)/\\\1/g
+s/$/\\n/
+s/\([^\n]*\).*/ fputs ("\1", f);/p
+g
+D'
cat <<"EOF"
}
EOF
@@ -5643,7 +5655,8 @@ func_mode_link ()
continue
;;
- -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
+ -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
+ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
func_append compiler_flags " $arg"
func_append compile_command " $arg"
func_append finalize_command " $arg"
@@ -6147,7 +6160,8 @@ func_mode_link ()
lib=
found=no
case $deplib in
- -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
+ -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
+ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
if test "$linkmode,$pass" = "prog,link"; then
compile_deplibs="$deplib $compile_deplibs"
finalize_deplibs="$deplib $finalize_deplibs"
@@ -6831,7 +6845,7 @@ func_mode_link ()
test "$hardcode_direct_absolute" = no; then
add="$dir/$linklib"
elif test "$hardcode_minus_L" = yes; then
- add_dir="-L$dir"
+ add_dir="-L$absdir"
# Try looking first in the location we're being installed to.
if test -n "$inst_prefix_dir"; then
case $libdir in
@@ -7316,6 +7330,7 @@ func_mode_link ()
# which has an extra 1 added just for fun
#
case $version_type in
+ # correct linux to gnu/linux during the next big refactor
darwin|linux|osf|windows|none)
func_arith $number_major + $number_minor
current=$func_arith_result
@@ -7432,7 +7447,7 @@ func_mode_link ()
versuffix="$major.$revision"
;;
- linux)
+ linux) # correct to gnu/linux during the next big refactor
func_arith $current - $age
major=.$func_arith_result
versuffix="$major.$age.$revision"
@@ -8020,6 +8035,11 @@ EOF
# Test again, we may have decided not to build it any more
if test "$build_libtool_libs" = yes; then
+ # Remove ${wl} instances when linking with ld.
+ # FIXME: should test the right _cmds variable.
+ case $archive_cmds in
+ *\$LD\ *) wl= ;;
+ esac
if test "$hardcode_into_libs" = yes; then
# Hardcode the library paths
hardcode_libdirs=
@@ -8050,7 +8070,7 @@ EOF
elif test -n "$runpath_var"; then
case "$perm_rpath " in
*" $libdir "*) ;;
- *) func_apped perm_rpath " $libdir" ;;
+ *) func_append perm_rpath " $libdir" ;;
esac
fi
done
@@ -8058,11 +8078,7 @@ EOF
if test -n "$hardcode_libdir_separator" &&
test -n "$hardcode_libdirs"; then
libdir="$hardcode_libdirs"
- if test -n "$hardcode_libdir_flag_spec_ld"; then
- eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\"
- else
- eval dep_rpath=\"$hardcode_libdir_flag_spec\"
- fi
+ eval "dep_rpath=\"$hardcode_libdir_flag_spec\""
fi
if test -n "$runpath_var" && test -n "$perm_rpath"; then
# We should set the runpath_var.
@@ -9152,6 +9168,8 @@ EOF
esac
done
fi
+ func_to_tool_file "$oldlib" func_convert_file_msys_to_w32
+ tool_oldlib=$func_to_tool_file_result
eval cmds=\"$old_archive_cmds\"
func_len " $cmds"
@@ -9261,7 +9279,8 @@ EOF
*.la)
func_basename "$deplib"
name="$func_basename_result"
- eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
+ func_resolve_sysroot "$deplib"
+ eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
test -z "$libdir" && \
func_fatal_error "\`$deplib' is not a valid libtool archive"
func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name"
diff --git a/3party/freetype/builds/unix/unix-def.in b/3party/freetype/builds/unix/unix-def.in
index e0a7a3a61f..d3ebc8b265 100644
--- a/3party/freetype/builds/unix/unix-def.in
+++ b/3party/freetype/builds/unix/unix-def.in
@@ -15,7 +15,7 @@
TOP_DIR := $(shell cd $(TOP_DIR); pwd)
-DELETE := @RMF@
+DELETE := rm -f
DELDIR := @RMDIR@
CAT := cat
SEP := /
diff --git a/3party/freetype/builds/vms/ftconfig.h b/3party/freetype/builds/vms/ftconfig.h
index 99c37db391..62fadac0fa 100644
--- a/3party/freetype/builds/vms/ftconfig.h
+++ b/3party/freetype/builds/vms/ftconfig.h
@@ -95,8 +95,7 @@ FT_BEGIN_HEADER
/* This is the only necessary change, so it is defined here instead */
/* providing a new configuration file. */
/* */
-#if ( defined( __APPLE__ ) && !defined( DARWIN_NO_CARBON ) ) || \
- ( defined( __MWERKS__ ) && defined( macintosh ) )
+#if defined( __APPLE__ ) || ( defined( __MWERKS__ ) && defined( macintosh ) )
/* no Carbon frameworks for 64bit 10.4.x */
/* AvailabilityMacros.h is available since Mac OS X 10.2, */
/* so guess the system version by maximum errno before inclusion */
@@ -106,9 +105,7 @@ FT_BEGIN_HEADER
#endif
#if defined( __LP64__ ) && \
( MAC_OS_X_VERSION_MIN_REQUIRED <= MAC_OS_X_VERSION_10_4 )
-#define DARWIN_NO_CARBON 1
-#else
-#define FT_MACINTOSH 1
+#undef FT_MACINTOSH
#endif
#elif defined( __SC__ ) || defined( __MRC__ )
diff --git a/3party/freetype/builds/win32/vc2005/index.html b/3party/freetype/builds/win32/vc2005/index.html
index d21bebd7bb..a380079d9f 100644
--- a/3party/freetype/builds/win32/vc2005/index.html
+++ b/3party/freetype/builds/win32/vc2005/index.html
@@ -11,14 +11,14 @@
<p>This directory contains project files for Visual C++, named
<tt>freetype.vcproj</tt>, and Visual Studio, called <tt>freetype.sln</tt>. It
-compiles the following libraries from the FreeType 2.4.8 sources:</p>
+compiles the following libraries from the FreeType 2.4.11 sources:</p>
<ul>
<pre>
- freetype248.lib - release build; single threaded
- freetype248_D.lib - debug build; single threaded
- freetype248MT.lib - release build; multi-threaded
- freetype248MT_D.lib - debug build; multi-threaded</pre>
+ freetype2411.lib - release build; single threaded
+ freetype2411_D.lib - debug build; single threaded
+ freetype2411MT.lib - release build; multi-threaded
+ freetype2411MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/3party/freetype/builds/win32/vc2008/index.html b/3party/freetype/builds/win32/vc2008/index.html
index b7032bf5a8..f064b228e4 100644
--- a/3party/freetype/builds/win32/vc2008/index.html
+++ b/3party/freetype/builds/win32/vc2008/index.html
@@ -11,14 +11,14 @@
<p>This directory contains project files for Visual C++, named
<tt>freetype.vcproj</tt>, and Visual Studio, called <tt>freetype.sln</tt>. It
-compiles the following libraries from the FreeType 2.4.8 sources:</p>
+compiles the following libraries from the FreeType 2.4.11 sources:</p>
<ul>
<pre>
- freetype248.lib - release build; single threaded
- freetype248_D.lib - debug build; single threaded
- freetype248MT.lib - release build; multi-threaded
- freetype248MT_D.lib - debug build; multi-threaded</pre>
+ freetype2411.lib - release build; single threaded
+ freetype2411_D.lib - debug build; single threaded
+ freetype2411MT.lib - release build; multi-threaded
+ freetype2411MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/3party/freetype/builds/win32/vc2010/index.html b/3party/freetype/builds/win32/vc2010/index.html
index b8e332116a..9c4dd0bbc8 100644
--- a/3party/freetype/builds/win32/vc2010/index.html
+++ b/3party/freetype/builds/win32/vc2010/index.html
@@ -11,14 +11,14 @@
<p>This directory contains a project file for Visual C++, named
<tt>freetype.vcxproj</tt>, and Visual Studio, called <tt>freetype.sln</tt>. It
-compiles the following libraries from the FreeType 2.4.8 sources:</p>
+compiles the following libraries from the FreeType 2.4.11 sources:</p>
<ul>
<pre>
- freetype248.lib - release build; single threaded
- freetype248_D.lib - debug build; single threaded
- freetype248MT.lib - release build; multi-threaded
- freetype248MT_D.lib - debug build; multi-threaded</pre>
+ freetype2411.lib - release build; single threaded
+ freetype2411_D.lib - debug build; single threaded
+ freetype2411MT.lib - release build; multi-threaded
+ freetype2411MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/3party/freetype/builds/win32/visualc/freetype.dsp b/3party/freetype/builds/win32/visualc/freetype.dsp
index aae60ef5d5..b8e05ae09a 100644
--- a/3party/freetype/builds/win32/visualc/freetype.dsp
+++ b/3party/freetype/builds/win32/visualc/freetype.dsp
@@ -54,7 +54,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Debug"
@@ -78,7 +78,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411_D.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Debug Multithreaded"
@@ -102,8 +102,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"lib\freetype248_D.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248MT_D.lib"
+# ADD BASE LIB32 /nologo /out:"lib\freetype2411_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411MT_D.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Release Multithreaded"
@@ -126,8 +126,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"lib\freetype248.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248MT.lib"
+# ADD BASE LIB32 /nologo /out:"lib\freetype2411.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411MT.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Release Singlethreaded"
@@ -151,8 +151,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype248.lib"
-# ADD LIB32 /out:"..\..\..\objs\freetype248ST.lib"
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2411.lib"
+# ADD LIB32 /out:"..\..\..\objs\freetype2411ST.lib"
# SUBTRACT LIB32 /nologo
!ELSEIF "$(CFG)" == "freetype - Win32 Debug Singlethreaded"
@@ -177,8 +177,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype248_D.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248ST_D.lib"
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2411_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411ST_D.lib"
!ENDIF
diff --git a/3party/freetype/builds/win32/visualc/index.html b/3party/freetype/builds/win32/visualc/index.html
index 677155d763..684dbfd695 100644
--- a/3party/freetype/builds/win32/visualc/index.html
+++ b/3party/freetype/builds/win32/visualc/index.html
@@ -11,14 +11,14 @@
<p>This directory contains project files for Visual C++, named
<tt>freetype.dsp</tt>, and Visual Studio, called <tt>freetype.sln</tt>. It
-compiles the following libraries from the FreeType 2.4.8 sources:</p>
+compiles the following libraries from the FreeType 2.4.11 sources:</p>
<ul>
<pre>
- freetype248.lib - release build; single threaded
- freetype248_D.lib - debug build; single threaded
- freetype248MT.lib - release build; multi-threaded
- freetype248MT_D.lib - debug build; multi-threaded</pre>
+ freetype2411.lib - release build; single threaded
+ freetype2411_D.lib - debug build; single threaded
+ freetype2411MT.lib - release build; multi-threaded
+ freetype2411MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/3party/freetype/builds/win32/visualce/freetype.dsp b/3party/freetype/builds/win32/visualce/freetype.dsp
index aae60ef5d5..b8e05ae09a 100644
--- a/3party/freetype/builds/win32/visualce/freetype.dsp
+++ b/3party/freetype/builds/win32/visualce/freetype.dsp
@@ -54,7 +54,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Debug"
@@ -78,7 +78,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411_D.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Debug Multithreaded"
@@ -102,8 +102,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"lib\freetype248_D.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248MT_D.lib"
+# ADD BASE LIB32 /nologo /out:"lib\freetype2411_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411MT_D.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Release Multithreaded"
@@ -126,8 +126,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"lib\freetype248.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248MT.lib"
+# ADD BASE LIB32 /nologo /out:"lib\freetype2411.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411MT.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Release Singlethreaded"
@@ -151,8 +151,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype248.lib"
-# ADD LIB32 /out:"..\..\..\objs\freetype248ST.lib"
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2411.lib"
+# ADD LIB32 /out:"..\..\..\objs\freetype2411ST.lib"
# SUBTRACT LIB32 /nologo
!ELSEIF "$(CFG)" == "freetype - Win32 Debug Singlethreaded"
@@ -177,8 +177,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype248_D.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype248ST_D.lib"
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2411_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2411ST_D.lib"
!ENDIF
diff --git a/3party/freetype/builds/win32/visualce/index.html b/3party/freetype/builds/win32/visualce/index.html
index 6a2fcf9479..e41c3cba54 100644
--- a/3party/freetype/builds/win32/visualce/index.html
+++ b/3party/freetype/builds/win32/visualce/index.html
@@ -21,14 +21,14 @@ the following targets:
<li>PPC/SP WM6 (Windows Mobile 6)</li>
</ul>
-It compiles the following libraries from the FreeType 2.4.8 sources:</p>
+It compiles the following libraries from the FreeType 2.4.11 sources:</p>
<ul>
<pre>
- freetype248.lib - release build; single threaded
- freetype248_D.lib - debug build; single threaded
- freetype248MT.lib - release build; multi-threaded
- freetype248MT_D.lib - debug build; multi-threaded</pre>
+ freetype2411.lib - release build; single threaded
+ freetype2411_D.lib - debug build; single threaded
+ freetype2411MT.lib - release build; multi-threaded
+ freetype2411MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/3party/freetype/builds/wince/vc2005-ce/index.html b/3party/freetype/builds/wince/vc2005-ce/index.html
index 2731c1c99e..ff1e345f8e 100644
--- a/3party/freetype/builds/wince/vc2005-ce/index.html
+++ b/3party/freetype/builds/wince/vc2005-ce/index.html
@@ -21,14 +21,14 @@ the following targets:
<li>PPC/SP WM6 (Windows Mobile 6)</li>
</ul>
-It compiles the following libraries from the FreeType 2.4.8 sources:</p>
+It compiles the following libraries from the FreeType 2.4.11 sources:</p>
<ul>
<pre>
- freetype248.lib - release build; single threaded
- freetype248_D.lib - debug build; single threaded
- freetype248MT.lib - release build; multi-threaded
- freetype248MT_D.lib - debug build; multi-threaded</pre>
+ freetype2411.lib - release build; single threaded
+ freetype2411_D.lib - debug build; single threaded
+ freetype2411MT.lib - release build; multi-threaded
+ freetype2411MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/3party/freetype/builds/wince/vc2008-ce/index.html b/3party/freetype/builds/wince/vc2008-ce/index.html
index 5c21035ee6..97cca35fe9 100644
--- a/3party/freetype/builds/wince/vc2008-ce/index.html
+++ b/3party/freetype/builds/wince/vc2008-ce/index.html
@@ -21,14 +21,14 @@ the following targets:
<li>PPC/SP WM6 (Windows Mobile 6)</li>
</ul>
-It compiles the following libraries from the FreeType 2.4.8 sources:</p>
+It compiles the following libraries from the FreeType 2.4.11 sources:</p>
<ul>
<pre>
- freetype248.lib - release build; single threaded
- freetype248_D.lib - debug build; single threaded
- freetype248MT.lib - release build; multi-threaded
- freetype248MT_D.lib - debug build; multi-threaded</pre>
+ freetype2411.lib - release build; single threaded
+ freetype2411_D.lib - debug build; single threaded
+ freetype2411MT.lib - release build; multi-threaded
+ freetype2411MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/3party/freetype/configure b/3party/freetype/configure
index b397556241..55a24fdc59 100755
--- a/3party/freetype/configure
+++ b/3party/freetype/configure
@@ -92,19 +92,19 @@ if test $inode_src -ne $inode_dst; then
cp $abs_ft2_dir/modules.cfg $abs_curr_dir
fi
echo "Generating \`Makefile'"
- echo "TOP_DIR := $abs_ft2_dir" > Makefile
- echo "OBJ_DIR := $abs_curr_dir" >> Makefile
- echo "OBJ_BUILD := \$(OBJ_DIR)" >> Makefile
- echo "DOC_DIR := \$(OBJ_DIR)/reference" >> Makefile
- echo "FT_LIBTOOL_DIR := \$(OBJ_DIR)" >> Makefile
- echo "ifndef FT2DEMOS" >> Makefile
- echo " include \$(TOP_DIR)/Makefile" >> Makefile
- echo "else" >> Makefile
- echo " TOP_DIR_2 := \$(TOP_DIR)/../ft2demos" >> Makefile
- echo " PROJECT := freetype" >> Makefile
- echo " CONFIG_MK := \$(OBJ_DIR)/config.mk" >> Makefile
- echo " include \$(TOP_DIR_2)/Makefile" >> Makefile
- echo "endif" >> Makefile
+ echo "TOP_DIR := $abs_ft2_dir" > Makefile
+ echo "OBJ_DIR := $abs_curr_dir" >> Makefile
+ echo "OBJ_BUILD := \$(OBJ_DIR)" >> Makefile
+ echo "DOC_DIR := \$(OBJ_DIR)/reference" >> Makefile
+ echo "FT_LIBTOOL_DIR := \$(OBJ_DIR)" >> Makefile
+ echo "ifndef FT2DEMOS" >> Makefile
+ echo " include \$(TOP_DIR)/Makefile" >> Makefile
+ echo "else" >> Makefile
+ echo " TOP_DIR_2 := \$(TOP_DIR)/../ft2demos" >> Makefile
+ echo " PROJECT := freetype" >> Makefile
+ echo " CONFIG_MK := \$(OBJ_DIR)/config.mk" >> Makefile
+ echo " include \$(TOP_DIR_2)/Makefile" >> Makefile
+ echo "endif" >> Makefile
fi
# call make
diff --git a/3party/freetype/devel/ftoption.h b/3party/freetype/devel/ftoption.h
index 4da0221db3..6b2a40f839 100644
--- a/3party/freetype/devel/ftoption.h
+++ b/3party/freetype/devel/ftoption.h
@@ -4,7 +4,7 @@
/* */
/* User-selectable configuration macros (specification only). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -560,6 +560,28 @@ FT_BEGIN_HEADER
/*************************************************************************/
/* */
+ /* Define TT_CONFIG_OPTION_SUBPIXEL_HINTING if you want to compile */
+ /* EXPERIMENTAL subpixel hinting support into the TrueType driver. This */
+ /* replaces the native TrueType hinting mechanism when anything but */
+ /* FT_RENDER_MODE_MONO is requested. */
+ /* */
+ /* Enabling this causes the TrueType driver to ignore instructions under */
+ /* certain conditions. This is done in accordance with the guide here, */
+ /* with some minor differences: */
+ /* */
+ /* http://www.microsoft.com/typography/cleartype/truetypecleartype.aspx */
+ /* */
+ /* By undefining this, you only compile the code necessary to hint */
+ /* TrueType glyphs with native TT hinting. */
+ /* */
+ /* This option requires TT_CONFIG_OPTION_BYTECODE_INTERPRETER to be */
+ /* defined. */
+ /* */
+#define TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+
+ /*************************************************************************/
+ /* */
/* If you define TT_CONFIG_OPTION_UNPATENTED_HINTING, a special version */
/* of the TrueType bytecode interpreter is used that doesn't implement */
/* any of the patented opcodes and algorithms. The patents related to */
@@ -669,7 +691,7 @@ FT_BEGIN_HEADER
/*************************************************************************/
/* */
- /* T1_MAX_DICT_DEPTH is the maximal depth of nest dictionaries and */
+ /* T1_MAX_DICT_DEPTH is the maximum depth of nest dictionaries and */
/* arrays in the Type 1 stream (see t1load.c). A minimum of 4 is */
/* required. */
/* */
diff --git a/3party/freetype/docs/CHANGES b/3party/freetype/docs/CHANGES
index a63061e112..18ec1945ad 100644
--- a/3party/freetype/docs/CHANGES
+++ b/3party/freetype/docs/CHANGES
@@ -1,4 +1,117 @@
+CHANGES BETWEEN 2.4.10 and 2.4.11
+
+ I. IMPORTANT BUG FIXES
+
+ - Some vulnerabilities in the BDF implementation have been fixed.
+ Users of this font format should upgrade.
+
+
+ II. IMPORTANT CHANGES
+
+ - Subpixel hinting support has been contributed by Infinality,
+ based on Greg Hitchcock's whitepaper at
+
+ http://www.microsoft.com/typography/cleartype/truetypecleartype.aspx
+
+ Originally, it was a separate patch available from
+
+ http://www.infinality.net/blog/
+
+ and which has been integrated.
+
+ Note that ClearType support is not completely implemented! In
+ particular, full support for the options `compatible_widths',
+ `symmetrical_smoothing, and `bgr' (via the GETINFO bytecode
+ instruction) is missing.
+
+ Activation of subpixel hinting support can be controlled with
+ the `TT_CONFIG_OPTION_SUBPIXEL_HINTING' configuration option; it
+ is switched off by default. This feature is still experimental;
+ we welcome test reports!
+
+ - Support for OpenType collections (OTC) has been added.
+
+ - Pure CFF fonts within an SFNT wrapper are now supported.
+
+
+ III. MISCELLANEOUS
+
+ - Minor rendering improvements to the auto-hinter.
+
+ - `FT_GlyphSlot_Oblique' now uses a shear angle of 12°.
+
+ - Experimental support to handle `property modules', for example
+ to control the behaviour of the auto-hinter. The API consists
+ of two new functions, `FT_Property_Set' and `FT_Property_Get'.
+
+ The code is still subject to change and should not be used for
+ production.
+
+ - The `ftdiff' demo program now supports UTF-8 encoded input files
+ for option `-f'.
+
+ - Using keys `r' and `R', you can now adjust the stroker radius in
+ the `ftview' demo program.
+
+ - Other, minor fixes and improvements.
+
+
+======================================================================
+
+CHANGES BETWEEN 2.4.9 and 2.4.10
+
+ I. IMPORTANT BUG FIXES
+
+ - Incremental glyph loading as needed by ghostscript was broken.
+
+
+ II. MISCELLANEOUS
+
+ - A new function `FT_Outline_EmboldenXY', contributed by Alexei
+ Podtelezhnikov.
+
+ - In the `ftview' demo program, key `e' has been replaced with `x'
+ and `y' to embolden in the horizontal and vertical direction,
+ respectively.
+
+ - The glyph spacing computation in `FT_GlyphSlot_Embolden' (and
+ similar code in `ftview') has been improved.
+
+ - Minor improvements to the TrueType bytecode interpreter and
+ glyph loader, the auto-hinter, and the B/W rasterizer.
+
+
+======================================================================
+
+CHANGES BETWEEN 2.4.8 and 2.4.9
+
+ I. IMPORTANT BUG FIXES
+
+ - Another round of fixes to better handle invalid fonts. Many of
+ them are vulnerabilities (see CVE-2012-1126 up to CVE-2012-1144
+ and SA48320) so all users should upgrade.
+
+
+ II. MISCELLANEOUS
+
+ - The `ENCODING -1 <n>' format of BDF fonts is now supported.
+
+ - For BDF fonts, support for the whole Unicode encoding range has
+ been added.
+
+ - Better TTF support for x_ppem != y_ppem.
+
+ - `FT_Get_Advances' sometimes returned bogus values.
+
+ - The demo programs no longer recognize and handle default
+ suffixes; you now have to always specify the complete font name.
+
+ - Better rendering and LCD mode cycling added to `ftview'.
+
+
+======================================================================
+
CHANGES BETWEEN 2.4.7 and 2.4.8
I. IMPORTANT BUG FIXES
@@ -181,7 +294,7 @@ CHANGES BETWEEN 2.4.1 and 2.4.2
The two new functions increment the respective counter.
`FT_Done_Library' and `FT_Done_Face' then only destroy a library
or face if the counter is 1, otherwise they simply decrement the
- counter.
+ counter.
======================================================================
@@ -3601,7 +3714,7 @@ Extensions support:
------------------------------------------------------------------------
-Copyright 2000-2011 by
+Copyright 2000-2012 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/3party/freetype/docs/CUSTOMIZE b/3party/freetype/docs/CUSTOMIZE
index 7d7d474ec0..396eda38ea 100644
--- a/3party/freetype/docs/CUSTOMIZE
+++ b/3party/freetype/docs/CUSTOMIZE
@@ -31,6 +31,10 @@ II. Modules list
make uses `modules.cfg' to generate `ftmodule.h' (in the object
directory).
+ If you build FreeType in a directory separate from the source files,
+ put your customized `modules.cfg' in that directory; that way you
+ can keep the source files `clean'.
+
If you don't use GNU make you have to manually edit the file
`include/freetype/config/ftmodule.h' (which is *not* used with if
compiled with GNU make) to add or remove the drivers and components
@@ -77,11 +81,12 @@ IV. Overriding default configuration and module headers
[This is actually a combination of method 2 and 3.]
- Just put your custom `ftoption.h' file into the objects directory
- (normally `<topdir>/objs'), which GNU make prefers over the
- standard location. No action is needed for `ftmodule.h' because
- it is generated automatically in the objects directory.
-
+ Just put your custom `ftoption.h' file into the objects directory
+ (normally `<topdir>/objs' if you build in the source tree, or the
+ directory where you invoke configure if you build in a separate
+ directory), which GNU make prefers over the standard location. No
+ action is needed for `ftmodule.h' because it is generated
+ automatically in the objects directory.
2. Using the C include path
@@ -137,7 +142,7 @@ IV. Overriding default configuration and module headers
----------------------------------------------------------------------
-Copyright 2003, 2005, 2006 by
+Copyright 2003, 2005, 2006, 2012 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/3party/freetype/docs/INSTALL.CROSS b/3party/freetype/docs/INSTALL.CROSS
index 3def12c8c5..005d44293e 100644
--- a/3party/freetype/docs/INSTALL.CROSS
+++ b/3party/freetype/docs/INSTALL.CROSS
@@ -44,11 +44,11 @@ INSTALL.UNIX for required tools and the basic self-building procedure.
the option pair `--host=' and `--target='. This is broken and
doesn't work. Similarly, an explicit CC specification like
- env CC=mips-ip22-linux-gcc ./configure
+ env CC=mips-ip22-linux-gcc ./configure # BAD
or
- env CC=/usr/local/mips-ip22-linux/bin/gcc ./configure
+ env CC=/usr/local/mips-ip22-linux/bin/gcc ./configure # BAD
doesn't work either; such a configuration confuses the
`configure' script while trying to find the cross and native C
@@ -121,7 +121,7 @@ INSTALL.UNIX for required tools and the basic self-building procedure.
----------------------------------------------------------------------
-Copyright 2006, 2008 by suzuki toshiya
+Copyright 2006, 2008, 2012 by suzuki toshiya
David Turner, Robert Wilhelm, and Werner Lemberg.
diff --git a/3party/freetype/docs/VERSION.DLL b/3party/freetype/docs/VERSION.DLL
index 044f6b87dc..cf8c353252 100644
--- a/3party/freetype/docs/VERSION.DLL
+++ b/3party/freetype/docs/VERSION.DLL
@@ -1,5 +1,5 @@
Due to our use of `libtool' to generate and install the FreeType 2
-libraries on Unix systems, as well as other historical events, it is
+libraries on Unix systems, as well as other historical events, it is
generally very difficult to know precisely which release of the font
engine is installed on a given system.
@@ -10,16 +10,16 @@ FreeType on Unix.
1. Version and Release numbers
------------------------------
-For each new public release of FreeType 2, there are generally *three*
+For each new public release of FreeType 2, there are generally *three*
distinct `version' numbers to consider:
- * The official FreeType 2 release number, like 2.0.9 or 2.1.3.
+ * The official FreeType 2 release number, like 2.3.1 or 2.4.10.
- * The libtool (and Unix) specific version number, like 9.2.3. This is
- what `freetype-config --version' returns.
+ * The libtool (and Unix) specific version number, like 13.0.7. This
+ is what `freetype-config --version' returns.
* The platform-specific shared object number, used for example when
- the library is installed as `/usr/lib/libfreetype.so.6.3.2'.
+ the library is installed as `/usr/lib/libfreetype.so.6.7.1'.
The platform-specific number is, unsurprisingly, platform-specific and
varies with the operating system you are using (several variants of
@@ -38,21 +38,23 @@ macros defined in FT_FREETYPE_H:
See below for a small autoconf fragment.
-The release number is also available at *runtime* through the
-`FT_Library_Version' API. Unfortunately, this one wasn't available or
-working correctly before the 2.1.3 official release.
+The release number is also available at *runtime* through the
+`FT_Library_Version' API.
2. History
----------
-The following table gives, for each official release, the corresponding
-libtool number, as well as the shared object number found on _most_
-systems, but not all of them:
+The following table gives, for all releases since 2.3.0, the
+corresponding libtool number, as well as the shared object number found
+on _most_ systems, but not all of them:
- release libtool so
+ release libtool so
-------------------------------
+ 2.4.11 16.0.10 6.10.0
+ 2.4.10 15.0.9 6.9.0
+ 2.4.9 14.1.8 6.8.1
2.4.8 14.0.8 6.8.0
2.4.7 13.2.7 6.7.2
2.4.6 13.1.7 6.7.1
@@ -75,34 +77,6 @@ systems, but not all of them:
2.3.2 9.13.3 6.3.13
2.3.1 9.12.3 6.3.12
2.3.0 9.11.3 6.3.11
- 2.2.1 9.10.3 6.3.10
- 2.2.0 9.9.3 6.3.9
- 2.1.10 9.8.3 6.3.8
- 2.1.9 9.7.3 6.3.7
- 2.1.8 9.6.3 6.3.6
- 2.1.7 9.5.3 6.3.5
- 2.1.6 9.5.3 6.3.5
- 2.1.5 9.4.3 6.3.4
- 2.1.4 9.3.3 6.3.3
- 2.1.3 9.2.3 6.3.2
- 2.1.2 9.1.3 6.3.1
- 2.1.1 9.0.3 ?
- 2.1.0 8.0.2 ?
- 2.0.9 9.0.3 ?
- 2.0.8 8.0.2 ?
- 2.0.4 7.0.1 ?
- 2.0.1 6.1.0 ?
-
-The libtool numbers are a bit inconsistent due to the library's history:
-
- - 2.1.0 was created as a development branch from 2.0.8 (hence the same
- libtool numbers).
-
- - 2.0.9 was a bug-fix release of the `stable' branch, and we
- incorrectly increased its libtool number.
-
- - 2.1.4 was a development version, however it was stable enough to be
- the basis of the 2.2.0 release.
3. Autoconf Code Fragment
@@ -134,7 +108,7 @@ other release numbers.
------------------------------------------------------------------------
-Copyright 2002-2011 by
+Copyright 2002-2012 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/3party/freetype/docs/reference/ft2-auto_hinter.html b/3party/freetype/docs/reference/ft2-auto_hinter.html
new file mode 100644
index 0000000000..68a87d4ba9
--- /dev/null
+++ b/3party/freetype/docs/reference/ft2-auto_hinter.html
@@ -0,0 +1,313 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+"http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+<title>FreeType-2.4.11 API Reference</title>
+<style type="text/css">
+ body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
+ color: #000000;
+ background: #FFFFFF; }
+
+ p { text-align: justify; }
+ h1 { text-align: center; }
+ li { text-align: justify; }
+ td { padding: 0 0.5em 0 0.5em; }
+ td.left { padding: 0 0.5em 0 0.5em;
+ text-align: left; }
+
+ a:link { color: #0000EF; }
+ a:visited { color: #51188E; }
+ a:hover { color: #FF0000; }
+
+ span.keyword { font-family: monospace;
+ text-align: left;
+ white-space: pre;
+ color: darkblue; }
+
+ pre.colored { color: blue; }
+
+ ul.empty { list-style-type: none; }
+</style>
+</head>
+<body>
+
+<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
+
+<center><h1>
+The auto-hinter
+</h1></center>
+<h2>Synopsis</h2>
+<table align=center cellspacing=5 cellpadding=0 border=0>
+<tr><td></td><td><a href="#glyph-to-script-map">glyph-to-script-map</a></td><td></td><td><a href="#fallback-script">fallback-script</a></td></tr>
+<tr><td></td><td><a href="#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_XXX</a></td><td></td><td><a href="#increase-x-height">increase-x-height</a></td></tr>
+<tr><td></td><td><a href="#FT_Prop_GlyphToScriptMap">FT_Prop_GlyphToScriptMap</a></td><td></td><td><a href="#FT_Prop_IncreaseXHeight">FT_Prop_IncreaseXHeight</a></td></tr>
+</table><br><br>
+
+<table align=center width="87%"><tr><td>
+<p>While FreeType's auto-hinter doesn't expose API functions by itself, it is possible to control its behaviour with <a href="ft2-module_management.html#FT_Property_Set">FT_Property_Set</a> and <a href="ft2-module_management.html#FT_Property_Get">FT_Property_Get</a>. The following lists the available properties together with the necessary macros and structures.</p>
+<p>Note that the auto-hinter's module name is &lsquo;autofitter&rsquo; for historical reasons.</p>
+</td></tr></table><br>
+<table align=center width="75%"><tr><td>
+<h4><a name="glyph-to-script-map">glyph-to-script-map</a></h4>
+<table align=center width="87%"><tr><td>
+<p>The auto-hinter provides various script modules to hint glyphs. Examples of supported scripts are Latin or CJK. Before a glyph is auto-hinted, the Unicode character map of the font gets examined, and the script is then determined based on Unicode character ranges, see below.</p>
+<p>OpenType fonts, however, often provide much more glyphs than character codes (small caps, superscripts, ligatures, swashes, etc.), to be controlled by so-called &lsquo;features&rsquo;. Handling OpenType features can be quite complicated and thus needs a separate library on top of FreeType.</p>
+<p>The mapping between glyph indices and scripts (in the auto-hinter sense, see the <a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_XXX</a> values) is stored as an array with &lsquo;num_glyphs&rsquo; elements, as found in the font's <a href="ft2-base_interface.html#FT_Face">FT_Face</a> structure. The &lsquo;glyph-to-script-map&rsquo; property returns a pointer to this array which can be modified as needed. Note that the modification should happen before the first glyph gets processed by the auto-hinter so that the global analysis of the font shapes actually uses the modified mapping.</p>
+<p>The following example code demonstrates how to access it (omitting the error handling).</p>
+<pre class="colored">
+ FT_Library library;
+ FT_Face face;
+ FT_Prop_GlyphToScriptMap prop;
+
+
+ FT_Init_FreeType( &amp;library );
+ FT_New_Face( library, "foo.ttf", 0, &amp;face );
+
+ prop.face = face;
+
+ FT_Property_Get( library, "autofitter",
+ "glyph-to-script-map", &amp;prop );
+
+ // adjust `prop.map' as needed right here
+
+ FT_Load_Glyph( face, ..., FT_LOAD_FORCE_AUTOHINT );
+</pre>
+</td></tr></table><br>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
+<h4><a name="FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_XXX</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_AUTOHINTER_H (freetype/ftautoh.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_NONE</a> 0
+#define <a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_LATIN</a> 1
+#define <a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_CJK</a> 2
+#define <a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_INDIC</a> 3
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>A list of constants used for the <a href="ft2-auto_hinter.html#glyph-to-script-map">glyph-to-script-map</a> property to specify the script submodule the auto-hinter should use for hinting a particular glyph.</p>
+</td></tr></table><br>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>values</b></em></td></tr><tr><td>
+<p></p>
+<table cellpadding=3 border=0>
+<tr valign=top><td colspan=0><b>FT_AUTOHINTER_SCRIPT_NONE</b></td></tr>
+<tr valign=top><td></td><td>
+<p>Don't auto-hint this glyph.</p>
+</td></tr>
+<tr valign=top><td colspan=0><b>FT_AUTOHINTER_SCRIPT_LATIN</b></td></tr>
+<tr valign=top><td></td><td>
+<p>Apply the latin auto-hinter. For the auto-hinter, &lsquo;latin&rsquo; is a very broad term, including Cyrillic and Greek also since characters from those scripts share the same design constraints.</p>
+<p>By default, characters from the following Unicode ranges are assigned to this submodule.</p>
+<pre class="colored">
+ U+0020 - U+007F // Basic Latin (no control characters)
+ U+00A0 - U+00FF // Latin-1 Supplement (no control characters)
+ U+0100 - U+017F // Latin Extended-A
+ U+0180 - U+024F // Latin Extended-B
+ U+0250 - U+02AF // IPA Extensions
+ U+02B0 - U+02FF // Spacing Modifier Letters
+ U+0300 - U+036F // Combining Diacritical Marks
+ U+0370 - U+03FF // Greek and Coptic
+ U+0400 - U+04FF // Cyrillic
+ U+0500 - U+052F // Cyrillic Supplement
+ U+1D00 - U+1D7F // Phonetic Extensions
+ U+1D80 - U+1DBF // Phonetic Extensions Supplement
+ U+1DC0 - U+1DFF // Combining Diacritical Marks Supplement
+ U+1E00 - U+1EFF // Latin Extended Additional
+ U+1F00 - U+1FFF // Greek Extended
+ U+2000 - U+206F // General Punctuation
+ U+2070 - U+209F // Superscripts and Subscripts
+ U+20A0 - U+20CF // Currency Symbols
+ U+2150 - U+218F // Number Forms
+ U+2460 - U+24FF // Enclosed Alphanumerics
+ U+2C60 - U+2C7F // Latin Extended-C
+ U+2DE0 - U+2DFF // Cyrillic Extended-A
+ U+2E00 - U+2E7F // Supplemental Punctuation
+ U+A640 - U+A69F // Cyrillic Extended-B
+ U+A720 - U+A7FF // Latin Extended-D
+ U+FB00 - U+FB06 // Alphab. Present. Forms (Latin Ligatures)
+ U+1D400 - U+1D7FF // Mathematical Alphanumeric Symbols
+ U+1F100 - U+1F1FF // Enclosed Alphanumeric Supplement
+</pre>
+<p></p>
+</td></tr>
+<tr valign=top><td colspan=0><b>FT_AUTOHINTER_SCRIPT_CJK</b></td></tr>
+<tr valign=top><td></td><td>
+<p>Apply the CJK auto-hinter, covering Chinese, Japanese, Korean, old Vietnamese, and some other scripts.</p>
+<p>By default, characters from the following Unicode ranges are assigned to this submodule.</p>
+<pre class="colored">
+ U+1100 - U+11FF // Hangul Jamo
+ U+2E80 - U+2EFF // CJK Radicals Supplement
+ U+2F00 - U+2FDF // Kangxi Radicals
+ U+2FF0 - U+2FFF // Ideographic Description Characters
+ U+3000 - U+303F // CJK Symbols and Punctuation
+ U+3040 - U+309F // Hiragana
+ U+30A0 - U+30FF // Katakana
+ U+3100 - U+312F // Bopomofo
+ U+3130 - U+318F // Hangul Compatibility Jamo
+ U+3190 - U+319F // Kanbun
+ U+31A0 - U+31BF // Bopomofo Extended
+ U+31C0 - U+31EF // CJK Strokes
+ U+31F0 - U+31FF // Katakana Phonetic Extensions
+ U+3200 - U+32FF // Enclosed CJK Letters and Months
+ U+3300 - U+33FF // CJK Compatibility
+ U+3400 - U+4DBF // CJK Unified Ideographs Extension A
+ U+4DC0 - U+4DFF // Yijing Hexagram Symbols
+ U+4E00 - U+9FFF // CJK Unified Ideographs
+ U+A960 - U+A97F // Hangul Jamo Extended-A
+ U+AC00 - U+D7AF // Hangul Syllables
+ U+D7B0 - U+D7FF // Hangul Jamo Extended-B
+ U+F900 - U+FAFF // CJK Compatibility Ideographs
+ U+FE10 - U+FE1F // Vertical forms
+ U+FE30 - U+FE4F // CJK Compatibility Forms
+ U+FF00 - U+FFEF // Halfwidth and Fullwidth Forms
+ U+1B000 - U+1B0FF // Kana Supplement
+ U+1D300 - U+1D35F // Tai Xuan Hing Symbols
+ U+1F200 - U+1F2FF // Enclosed Ideographic Supplement
+ U+20000 - U+2A6DF // CJK Unified Ideographs Extension B
+ U+2A700 - U+2B73F // CJK Unified Ideographs Extension C
+ U+2B740 - U+2B81F // CJK Unified Ideographs Extension D
+ U+2F800 - U+2FA1F // CJK Compatibility Ideographs Supplement
+</pre>
+<p></p>
+</td></tr>
+<tr valign=top><td colspan=0><b>FT_AUTOHINTER_SCRIPT_INDIC</b></td></tr>
+<tr valign=top><td></td><td>
+<p>Apply the indic auto-hinter, covering all major scripts from the Indian sub-continent and some other related scripts like Thai, Lao, or Tibetan.</p>
+<p>By default, characters from the following Unicode ranges are assigned to this submodule.</p>
+<pre class="colored">
+ U+0900 - U+0DFF // Indic Range
+ U+0F00 - U+0FFF // Tibetan
+ U+1900 - U+194F // Limbu
+ U+1B80 - U+1BBF // Sundanese
+ U+1C80 - U+1CDF // Meetei Mayak
+ U+A800 - U+A82F // Syloti Nagri
+ U+11800 - U+118DF // Sharada
+</pre>
+<p>Note that currently Indic support is rudimentary only, missing blue zone support.</p>
+</td></tr>
+</table>
+</td></tr></table>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
+<h4><a name="FT_Prop_GlyphToScriptMap">FT_Prop_GlyphToScriptMap</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_AUTOHINTER_H (freetype/ftautoh.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_Prop_GlyphToScriptMap_
+ {
+ <a href="ft2-base_interface.html#FT_Face">FT_Face</a> face;
+ <a href="ft2-basic_types.html#FT_Byte">FT_Byte</a>* map;
+
+ } <b>FT_Prop_GlyphToScriptMap</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>The data exchange structure for the <a href="ft2-auto_hinter.html#glyph-to-script-map">glyph-to-script-map</a> property.</p>
+</td></tr></table><br>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
+<h4><a name="fallback-script">fallback-script</a></h4>
+<table align=center width="87%"><tr><td>
+<p>If no auto-hinter script module can be assigned to a glyph, a fallback script gets assigned to it (see also the <a href="ft2-auto_hinter.html#glyph-to-script-map">glyph-to-script-map</a> property). By default, this is <a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_CJK</a>. Using the &lsquo;fallback-script&rsquo; property, this fallback value can be changed.</p>
+<pre class="colored">
+ FT_Library library;
+ FT_UInt fallback_script = FT_AUTOHINTER_SCRIPT_NONE;
+
+
+ FT_Init_FreeType( &amp;library );
+
+ FT_Property_Set( library, "autofitter",
+ "fallback-script", &amp;fallback_script );
+</pre>
+</td></tr></table><br>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>This property can be used with <a href="ft2-module_management.html#FT_Property_Get">FT_Property_Get</a> also.</p>
+<p>It's important to use the right timing for changing this value: The creation of the glyph-to-script map which eventually uses the fallback script value gets triggered either by setting or reading a face-specific property like <a href="ft2-auto_hinter.html#glyph-to-script-map">glyph-to-script-map</a>, or by auto-hinting any glyph from that face. In particular, if you have already created an <a href="ft2-base_interface.html#FT_Face">FT_Face</a> structure but not loaded any glyph (using the auto-hinter), a change of the fallback glyph will affect this face.</p>
+</td></tr></table>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
+<h4><a name="increase-x-height">increase-x-height</a></h4>
+<table align=center width="87%"><tr><td>
+<p>For ppem values in the range 6&nbsp;&lt;= ppem &lt;= &lsquo;increase-x-height&rsquo;, round up the font's x&nbsp;height much more often than normally. If the value is set to&nbsp;0, which is the default, this feature is switched off. Use this property to improve the legibility of small font sizes if necessary.</p>
+<pre class="colored">
+ FT_Library library;
+ FT_Face face;
+ FT_Prop_IncreaseXHeight prop;
+
+
+ FT_Init_FreeType( &amp;library );
+ FT_New_Face( library, "foo.ttf", 0, &amp;face );
+ FT_Set_Char_Size( face, 10 * 64, 0, 72, 0 );
+
+ prop.face = face;
+ prop.limit = 14;
+
+ FT_Property_Set( library, "autofitter",
+ "increase-x-height", &amp;prop );
+</pre>
+</td></tr></table><br>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>This property can be used with <a href="ft2-module_management.html#FT_Property_Get">FT_Property_Get</a> also.</p>
+<p>Set this value right after calling <a href="ft2-base_interface.html#FT_Set_Char_Size">FT_Set_Char_Size</a>, but before loading any glyph (using the auto-hinter).</p>
+</td></tr></table>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
+<h4><a name="FT_Prop_IncreaseXHeight">FT_Prop_IncreaseXHeight</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_AUTOHINTER_H (freetype/ftautoh.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_Prop_IncreaseXHeight_
+ {
+ <a href="ft2-base_interface.html#FT_Face">FT_Face</a> face;
+ <a href="ft2-basic_types.html#FT_UInt">FT_UInt</a> limit;
+
+ } <b>FT_Prop_IncreaseXHeight</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>The data exchange structure for the <a href="ft2-auto_hinter.html#increase-x-height">increase-x-height</a> property.</p>
+</td></tr></table><br>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+</body>
+</html>
diff --git a/3party/freetype/docs/reference/ft2-base_interface.html b/3party/freetype/docs/reference/ft2-base_interface.html
index ab5540c9d6..8ed2f11b3d 100644
--- a/3party/freetype/docs/reference/ft2-base_interface.html
+++ b/3party/freetype/docs/reference/ft2-base_interface.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Base Interface
@@ -391,6 +391,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
<p>If not disabled with <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a>, the values represent dimensions of the hinted glyph (in case hinting is applicable).</p>
+<p>Stroking a glyph with an outside border does not increase &lsquo;horiAdvance&rsquo; or &lsquo;vertAdvance&rsquo;; you have to manually adjust these values to account for the added width and height.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -693,8 +694,8 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<a href="ft2-list_processing.html#FT_ListRec">FT_ListRec</a> sizes_list;
- <a href="ft2-basic_types.html#FT_Generic">FT_Generic</a> autohint;
- <span class="keyword">void</span>* extensions;
+ <a href="ft2-basic_types.html#FT_Generic">FT_Generic</a> autohint; /* face-specific auto-hinter data */
+ <span class="keyword">void</span>* extensions; /* unused */
<a href="ft2-base_interface.html#FT_Face_Internal">FT_Face_Internal</a> internal;
@@ -747,7 +748,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>A field reserved for client uses. See the <a href="ft2-basic_types.html#FT_Generic">FT_Generic</a> type description.</p>
</td></tr>
<tr valign=top><td><b>bbox</b></td><td>
-<p>The font bounding box. Coordinates are expressed in font units (see &lsquo;units_per_EM&rsquo;). The box is large enough to contain any glyph from the font. Thus, &lsquo;bbox.yMax&rsquo; can be seen as the &lsquo;maximal ascender&rsquo;, and &lsquo;bbox.yMin&rsquo; as the &lsquo;minimal descender&rsquo;. Only relevant for scalable formats.</p>
+<p>The font bounding box. Coordinates are expressed in font units (see &lsquo;units_per_EM&rsquo;). The box is large enough to contain any glyph from the font. Thus, &lsquo;bbox.yMax&rsquo; can be seen as the &lsquo;maximum ascender&rsquo;, and &lsquo;bbox.yMin&rsquo; as the &lsquo;minimum descender&rsquo;. Only relevant for scalable formats.</p>
<p>Note that the bounding box might be off by (at least) one pixel for hinted fonts. See <a href="ft2-base_interface.html#FT_Size_Metrics">FT_Size_Metrics</a> for further discussion.</p>
</td></tr>
<tr valign=top><td><b>units_per_EM</b></td><td>
@@ -763,10 +764,10 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>The height is the vertical distance between two consecutive baselines, expressed in font units. It is always positive. Only relevant for scalable formats.</p>
</td></tr>
<tr valign=top><td><b>max_advance_width</b></td><td>
-<p>The maximal advance width, in font units, for all glyphs in this face. This can be used to make word wrapping computations faster. Only relevant for scalable formats.</p>
+<p>The maximum advance width, in font units, for all glyphs in this face. This can be used to make word wrapping computations faster. Only relevant for scalable formats.</p>
</td></tr>
<tr valign=top><td><b>max_advance_height</b></td><td>
-<p>The maximal advance height, in font units, for all glyphs in this face. This is only relevant for vertical layouts, and is set to &lsquo;height&rsquo; for fonts that do not provide vertical metrics. Only relevant for scalable formats.</p>
+<p>The maximum advance height, in font units, for all glyphs in this face. This is only relevant for vertical layouts, and is set to &lsquo;height&rsquo; for fonts that do not provide vertical metrics. Only relevant for scalable formats.</p>
</td></tr>
<tr valign=top><td><b>underline_position</b></td><td>
<p>The position, in font units, of the underline line for this face. It is the center of the underlining stem. Only relevant for scalable formats.</p>
@@ -918,7 +919,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>A macro that returns true whenever a face object contains vertical metrics.</p>
+<p>A macro that returns true whenever a face object contains real vertical metrics (and not only synthesized ones).</p>
</td></tr></table><br>
</td></tr></table>
<hr width="75%">
@@ -1231,7 +1232,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>The height in 26.6 fractional pixels. See <a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a> for the details.</p>
</td></tr>
<tr valign=top><td><b>max_advance</b></td><td>
-<p>The maximal advance width in 26.6 fractional pixels. See <a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a> for the details.</p>
+<p>The maximum advance width in 26.6 fractional pixels. See <a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a> for the details.</p>
</td></tr>
</table>
</td></tr></table>
@@ -1507,6 +1508,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
<p>In case you want to provide your own memory allocating routines, use <a href="ft2-module_management.html#FT_New_Library">FT_New_Library</a> instead, followed by a call to <a href="ft2-module_management.html#FT_Add_Default_Modules">FT_Add_Default_Modules</a> (or a series of calls to <a href="ft2-module_management.html#FT_Add_Module">FT_Add_Module</a>).</p>
+<p>For multi-threading applications each thread should have its own FT_Library object.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -1882,6 +1884,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>Unlike FreeType 1.x, this function automatically creates a glyph slot for the face object which can be accessed directly through &lsquo;face-&gt;glyph&rsquo;.</p>
<p>FT_Open_Face can be used to quickly check whether the font format of a given font resource is supported by FreeType. If the &lsquo;face_index&rsquo; field is negative, the function's return value is&nbsp;0 if the font format is recognized, or non-zero otherwise; the function returns a more or less empty face handle in &lsquo;*aface&rsquo; (if &lsquo;aface&rsquo; isn't NULL). The only useful field in this special case is &lsquo;face-&gt;num_faces&rsquo; which gives the number of faces within the font file. After examination, the returned <a href="ft2-base_interface.html#FT_Face">FT_Face</a> structure should be deallocated with a call to <a href="ft2-base_interface.html#FT_Done_Face">FT_Done_Face</a>.</p>
<p>Each new face object created with this function also owns a default <a href="ft2-base_interface.html#FT_Size">FT_Size</a> object, accessible as &lsquo;face-&gt;size&rsquo;.</p>
+<p>One <a href="ft2-base_interface.html#FT_Library">FT_Library</a> instance can have multiple face objects, this is, <a href="ft2-base_interface.html#FT_Open_Face">FT_Open_Face</a> and its siblings can be called multiple times using the same &lsquo;library&rsquo; argument.</p>
<p>See the discussion of reference counters in the description of <a href="ft2-base_interface.html#FT_Reference_Face">FT_Reference_Face</a>.</p>
</td></tr></table>
</td></tr></table>
@@ -2246,6 +2249,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
<p>Although drivers may select the bitmap strike matching the request, you should not rely on this if you intend to select a particular bitmap strike. Use <a href="ft2-base_interface.html#FT_Select_Size">FT_Select_Size</a> instead in that case.</p>
+<p>The relation between the requested size and the resulting glyph size is dependent entirely on how the size is defined in the source face. The font designer chooses the final size of each glyph relative to this size. For more information refer to &lsquo;http://www.freetype.org/freetype2/docs/glyphs/glyphs-2.html&rsquo;</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -2349,6 +2353,9 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>return</b></em></td></tr><tr><td>
<p>FreeType error code. 0&nbsp;means success.</p>
</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>You should not rely on the resulting glyphs matching, or being constrained, to this pixel size. Refer to <a href="ft2-base_interface.html#FT_Request_Size">FT_Request_Size</a> to understand how requested sizes relate to actual sizes.</p>
+</td></tr></table>
</td></tr></table>
<hr width="75%">
<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
@@ -2458,20 +2465,20 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_DEFAULT</a> 0x0
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_SCALE</a> 0x1
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a> 0x2
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a> 0x4
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_BITMAP</a> 0x8
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_VERTICAL_LAYOUT</a> 0x10
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_FORCE_AUTOHINT</a> 0x20
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_CROP_BITMAP</a> 0x40
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_PEDANTIC</a> 0x80
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH</a> 0x200
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_RECURSE</a> 0x400
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_TRANSFORM</a> 0x800
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a> 0x1000
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_LINEAR_DESIGN</a> 0x2000
-#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_AUTOHINT</a> 0x8000U
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_SCALE</a> ( 1L &lt;&lt; 0 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a> ( 1L &lt;&lt; 1 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a> ( 1L &lt;&lt; 2 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_BITMAP</a> ( 1L &lt;&lt; 3 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_VERTICAL_LAYOUT</a> ( 1L &lt;&lt; 4 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_FORCE_AUTOHINT</a> ( 1L &lt;&lt; 5 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_CROP_BITMAP</a> ( 1L &lt;&lt; 6 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_PEDANTIC</a> ( 1L &lt;&lt; 7 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH</a> ( 1L &lt;&lt; 9 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_RECURSE</a> ( 1L &lt;&lt; 10 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_TRANSFORM</a> ( 1L &lt;&lt; 11 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a> ( 1L &lt;&lt; 12 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_LINEAR_DESIGN</a> ( 1L &lt;&lt; 13 )
+#define <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_AUTOHINT</a> ( 1L &lt;&lt; 15 )
</pre></table><br>
<table align=center width="87%"><tr><td>
@@ -2487,11 +2494,12 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>Note that by default, the glyph loader doesn't render outlines into bitmaps. The following flags are used to modify this default behaviour to more specific and useful cases.</p>
</td></tr>
<tr valign=top><td><b>FT_LOAD_NO_SCALE</b></td><td>
-<p>Don't scale the outline glyph loaded, but keep it in font units.</p>
+<p>Don't scale the loaded outline glyph but keep it in font units.</p>
<p>This flag implies <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a> and <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_BITMAP</a>, and unsets <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a>.</p>
+<p>If the font is &lsquo;tricky&rsquo; (see <a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_TRICKY</a> for more), using FT_LOAD_NO_SCALE usually yields meaningless outlines because the subglyphs must be scaled and positioned with hinting instructions. This can be solved by loading the font without FT_LOAD_NO_SCALE and setting the character size to &lsquo;font-&gt;units_per_EM&rsquo;.</p>
</td></tr>
<tr valign=top><td><b>FT_LOAD_NO_HINTING</b></td><td>
-<p>Disable hinting. This generally generates &lsquo;blurrier&rsquo; bitmap glyph when the glyph is rendered in any of the anti-aliased modes. See also the note below.</p>
+<p>Disable hinting. This generally generates &lsquo;blurrier&rsquo; bitmap glyphs when the glyph are rendered in any of the anti-aliased modes. See also the note below.</p>
<p>This flag is implied by <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_SCALE</a>.</p>
</td></tr>
<tr valign=top><td><b>FT_LOAD_RENDER</b></td><td>
@@ -2504,7 +2512,8 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr>
<tr valign=top><td colspan=0><b>FT_LOAD_VERTICAL_LAYOUT</b></td></tr>
<tr valign=top><td></td><td>
-<p>Load the glyph for vertical text layout. <i>Don't</i> use it as it is problematic currently.</p>
+<p>Load the glyph for vertical text layout. In particular, the &lsquo;advance&rsquo; value in the <a href="ft2-base_interface.html#FT_GlyphSlotRec">FT_GlyphSlotRec</a> structure is set to the &lsquo;vertAdvance&rsquo; value of the &lsquo;metrics&rsquo; field.</p>
+<p>In case <a href="ft2-base_interface.html#FT_HAS_VERTICAL">FT_HAS_VERTICAL</a> doesn't return true, you shouldn't use this flag currently. Reason is that in this case vertical metrics get synthesized, and those values are not always consistent across various font formats.</p>
</td></tr>
<tr valign=top><td><b>FT_LOAD_FORCE_AUTOHINT</b></td><td>
<p>Indicates that the auto-hinter is preferred over the font's native hinter. See also the note below.</p>
@@ -2514,6 +2523,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr>
<tr valign=top><td><b>FT_LOAD_PEDANTIC</b></td><td>
<p>Indicates that the font driver should perform pedantic verifications during glyph loading. This is mostly used to detect broken glyphs in fonts. By default, FreeType tries to handle broken fonts also.</p>
+<p>In particular, errors from the TrueType bytecode engine are not passed to the application if this flag is not set; this might result in partially hinted or distorted glyphs in case a glyph's bytecode is buggy.</p>
</td></tr>
<tr valign=top><td colspan=0><b>FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH</b></td></tr>
<tr valign=top><td></td><td>
@@ -2544,6 +2554,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>By default, hinting is enabled and the font's native hinter (see <a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HINTER</a>) is preferred over the auto-hinter. You can disable hinting by setting <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a> or change the precedence by setting <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_FORCE_AUTOHINT</a>. You can also set <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_AUTOHINT</a> in case you don't want the auto-hinter to be used at all.</p>
<p>See the description of <a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_TRICKY</a> for a special exception (affecting only a handful of Asian fonts).</p>
<p>Besides deciding which hinter to use, you can also decide which hinting algorithm to use. See <a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_XXX</a> for details.</p>
+<p>Note that the auto-hinter needs a valid Unicode cmap (either a native one or synthesized by FreeType) for producing correct results. If a font provides an incorrect mapping (for example, assigning the character code U+005A, LATIN CAPITAL LETTER Z, to a glyph depicting a mathematical integral sign), the auto-hinter might produce useless results.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -2595,7 +2606,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
<p>You should use only <i>one</i> of the FT_LOAD_TARGET_XXX values in your &lsquo;load_flags&rsquo;. They can't be ORed.</p>
-<p>If <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a> is also set, the glyph is rendered in the corresponding mode (i.e., the mode which matches the used algorithm best) unless <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a> is set.</p>
+<p>If <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a> is also set, the glyph is rendered in the corresponding mode (i.e., the mode which matches the used algorithm best). An exeption is FT_LOAD_TARGET_MONO since it implies <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a>.</p>
<p>You can use a hinting algorithm that doesn't correspond to the same rendering mode. As an example, it is possible to use the &lsquo;light&rsquo; hinting algorithm and have the results rendered in horizontal LCD pixel mode, with code like</p>
<pre class="colored">
FT_Load_Glyph( face, glyph_index,
@@ -2978,7 +2989,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>The point size in 16.16 fractional points.</p>
</td></tr>
<tr valign=top><td><b>degree</b></td><td>
-<p>The degree of tightness.</p>
+<p>The degree of tightness. Increasingly negative values represent tighter track kerning, while increasingly positive values represent looser track kerning. Value zero means no track kerning.</p>
</td></tr>
</table>
</td></tr></table>
@@ -2986,13 +2997,17 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p></p>
<table cellpadding=3 border=0>
<tr valign=top><td><b>akerning</b></td><td>
-<p>The kerning in 16.16 fractional points.</p>
+<p>The kerning in 16.16 fractional points, to be uniformly applied between all glyphs.</p>
</td></tr>
</table>
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>return</b></em></td></tr><tr><td>
<p>FreeType error code. 0&nbsp;means success.</p>
</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>Currently, only the Type&nbsp;1 font driver supports track kerning, using data from AFM files (if attached with <a href="ft2-base_interface.html#FT_Attach_File">FT_Attach_File</a> or <a href="ft2-base_interface.html#FT_Attach_Stream">FT_Attach_Stream</a>).</p>
+<p>Only very few AFM files come with track kerning data; please refer to the Adobe's AFM specification for more details.</p>
+</td></tr></table>
</td></tr></table>
<hr width="75%">
<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
@@ -3026,7 +3041,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>The glyph index.</p>
</td></tr>
<tr valign=top><td><b>buffer_max</b></td><td>
-<p>The maximal number of bytes available in the buffer.</p>
+<p>The maximum number of bytes available in the buffer.</p>
</td></tr>
</table>
</td></tr></table>
@@ -3236,7 +3251,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>The glyph index. 0&nbsp;means &lsquo;undefined character code&rsquo;.</p>
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
-<p>If you use FreeType to manipulate the contents of font files directly, be aware that the glyph index returned by this function doesn't always correspond to the internal indices used within the file. This is done to ensure that value&nbsp;0 always corresponds to the &lsquo;missing glyph&rsquo;.</p>
+<p>If you use FreeType to manipulate the contents of font files directly, be aware that the glyph index returned by this function doesn't always correspond to the internal indices used within the file. This is done to ensure that value&nbsp;0 always corresponds to the &lsquo;missing glyph&rsquo;. If the first glyph is not named &lsquo;.notdef&rsquo;, then for Type&nbsp;1 and Type&nbsp;42 fonts, &lsquo;.notdef&rsquo; will be moved into the glyph ID&nbsp;0 position, and whatever was there will be moved to the position &lsquo;.notdef&rsquo; had. For Type&nbsp;1 fonts, if there is no &lsquo;.notdef&rsquo; glyph at all, then one will be created at index&nbsp;0 and whatever was there will be moved to the last index -- Type&nbsp;42 fonts are considered invalid under this condition.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
diff --git a/3party/freetype/docs/reference/ft2-basic_types.html b/3party/freetype/docs/reference/ft2-basic_types.html
index 6ddfbfb4b2..2c30328405 100644
--- a/3party/freetype/docs/reference/ft2-basic_types.html
+++ b/3party/freetype/docs/reference/ft2-basic_types.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Basic Data Types
@@ -1122,7 +1122,7 @@ Defined in FT_TYPES_H (freetype/fttypes.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
<p>Client applications often need to associate their own data to a variety of FreeType core objects. For example, a text layout API might want to associate a glyph cache to a given size object.</p>
-<p>Most FreeType object contains a &lsquo;generic&rsquo; field, of type FT_Generic, which usage is left to client applications and font servers.</p>
+<p>Some FreeType object contains a &lsquo;generic&rsquo; field, of type FT_Generic, which usage is left to client applications and font servers.</p>
<p>It can be used to store a pointer to client-specific data, as well as the address of a &lsquo;finalizer&rsquo; function, which will be called by FreeType when the object is destroyed (for example, the previous client example would put the address of the glyph cache destructor in the &lsquo;finalizer&rsquo; field).</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>fields</b></em></td></tr><tr><td>
diff --git a/3party/freetype/docs/reference/ft2-bdf_fonts.html b/3party/freetype/docs/reference/ft2-bdf_fonts.html
index bab95325a2..cfcd1ccebe 100644
--- a/3party/freetype/docs/reference/ft2-bdf_fonts.html
+++ b/3party/freetype/docs/reference/ft2-bdf_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
BDF and PCF Files
diff --git a/3party/freetype/docs/reference/ft2-bitmap_handling.html b/3party/freetype/docs/reference/ft2-bitmap_handling.html
index 31d0e267cb..cce07578e5 100644
--- a/3party/freetype/docs/reference/ft2-bitmap_handling.html
+++ b/3party/freetype/docs/reference/ft2-bitmap_handling.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Bitmap Handling
diff --git a/3party/freetype/docs/reference/ft2-bzip2.html b/3party/freetype/docs/reference/ft2-bzip2.html
index cc5d08a9d2..4c2f1a6a32 100644
--- a/3party/freetype/docs/reference/ft2-bzip2.html
+++ b/3party/freetype/docs/reference/ft2-bzip2.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
BZIP2 Streams
diff --git a/3party/freetype/docs/reference/ft2-cache_subsystem.html b/3party/freetype/docs/reference/ft2-cache_subsystem.html
index 816400545e..061ea35893 100644
--- a/3party/freetype/docs/reference/ft2-cache_subsystem.html
+++ b/3party/freetype/docs/reference/ft2-cache_subsystem.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Cache Sub-System
diff --git a/3party/freetype/docs/reference/ft2-cid_fonts.html b/3party/freetype/docs/reference/ft2-cid_fonts.html
index 0f2a2c7b98..b49188e04f 100644
--- a/3party/freetype/docs/reference/ft2-cid_fonts.html
+++ b/3party/freetype/docs/reference/ft2-cid_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
CID Fonts
diff --git a/3party/freetype/docs/reference/ft2-computations.html b/3party/freetype/docs/reference/ft2-computations.html
index 761016ed8b..08464392cc 100644
--- a/3party/freetype/docs/reference/ft2-computations.html
+++ b/3party/freetype/docs/reference/ft2-computations.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Computations
@@ -69,7 +69,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>A very simple function used to perform the computation &lsquo;(a*b)/c&rsquo; with maximal accuracy (it uses a 64-bit intermediate integer whenever necessary).</p>
+<p>A very simple function used to perform the computation &lsquo;(a*b)/c&rsquo; with maximum accuracy (it uses a 64-bit intermediate integer whenever necessary).</p>
<p>This function isn't necessarily as fast as some processor specific operations, but is at least completely portable.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
@@ -108,7 +108,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>A very simple function used to perform the computation &lsquo;(a*b)/0x10000&rsquo; with maximal accuracy. Most of the time this is used to multiply a given value by a 16.16 fixed float factor.</p>
+<p>A very simple function used to perform the computation &lsquo;(a*b)/0x10000&rsquo; with maximum accuracy. Most of the time this is used to multiply a given value by a 16.16 fixed float factor.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
<p></p>
@@ -147,7 +147,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>A very simple function used to perform the computation &lsquo;(a*0x10000)/b&rsquo; with maximal accuracy. Most of the time, this is used to divide a given value by a 16.16 fixed float factor.</p>
+<p>A very simple function used to perform the computation &lsquo;(a*0x10000)/b&rsquo; with maximum accuracy. Most of the time, this is used to divide a given value by a 16.16 fixed float factor.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
<p></p>
diff --git a/3party/freetype/docs/reference/ft2-font_formats.html b/3party/freetype/docs/reference/ft2-font_formats.html
index d2d5febf91..84ecd48355 100644
--- a/3party/freetype/docs/reference/ft2-font_formats.html
+++ b/3party/freetype/docs/reference/ft2-font_formats.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Font Formats
diff --git a/3party/freetype/docs/reference/ft2-gasp_table.html b/3party/freetype/docs/reference/ft2-gasp_table.html
index 8bfe9cde1e..9b00d55c1b 100644
--- a/3party/freetype/docs/reference/ft2-gasp_table.html
+++ b/3party/freetype/docs/reference/ft2-gasp_table.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Gasp Table
diff --git a/3party/freetype/docs/reference/ft2-glyph_management.html b/3party/freetype/docs/reference/ft2-glyph_management.html
index dad47adc9a..6249dfd6a8 100644
--- a/3party/freetype/docs/reference/ft2-glyph_management.html
+++ b/3party/freetype/docs/reference/ft2-glyph_management.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Glyph Management
diff --git a/3party/freetype/docs/reference/ft2-glyph_stroker.html b/3party/freetype/docs/reference/ft2-glyph_stroker.html
index 85be03871f..7822ab055d 100644
--- a/3party/freetype/docs/reference/ft2-glyph_stroker.html
+++ b/3party/freetype/docs/reference/ft2-glyph_stroker.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Glyph Stroker
@@ -876,6 +876,7 @@ Defined in FT_STROKER_H (freetype/ftstroke.h).
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
<p>The source glyph is untouched in case of error.</p>
+<p>Adding stroke may yield a significantly wider and taller glyph depending on how large of a radius was used to stroke the glyph. You may need to manually adjust horizontal and vertical advance amounts to account for this added size.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -927,6 +928,7 @@ Defined in FT_STROKER_H (freetype/ftstroke.h).
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
<p>The source glyph is untouched in case of error.</p>
+<p>Adding stroke may yield a significantly wider and taller glyph depending on how large of a radius was used to stroke the glyph. You may need to manually adjust horizontal and vertical advance amounts to account for this added size.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
diff --git a/3party/freetype/docs/reference/ft2-glyph_variants.html b/3party/freetype/docs/reference/ft2-glyph_variants.html
index 72fb3fd1f7..a654a268f4 100644
--- a/3party/freetype/docs/reference/ft2-glyph_variants.html
+++ b/3party/freetype/docs/reference/ft2-glyph_variants.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Glyph Variants
@@ -49,7 +49,9 @@ Glyph Variants
<table align=center width="87%"><tr><td>
<p>Many CJK characters have variant forms. They are a sort of grey area somewhere between being totally irrelevant and semantically distinct; for this reason, the Unicode consortium decided to introduce Ideographic Variation Sequences (IVS), consisting of a Unicode base character and one of 240 variant selectors (U+E0100-U+E01EF), instead of further extending the already huge code range for CJK characters.</p>
-<p>An IVS is registered and unique; for further details please refer to Unicode Technical Report #37, the Ideographic Variation Database. To date (October 2007), the character with the most variants is U+908A, having 8&nbsp;such IVS.</p>
+<p>An IVS is registered and unique; for further details please refer to Unicode Technical Standard #37, the Ideographic Variation Database:</p>
+<p>http://www.unicode.org/reports/tr37/</p>
+<p>To date (November 2012), the character with the most variants is U+9089, having 31 such IVS.</p>
<p>Adobe and MS decided to support IVS with a new cmap subtable (format&nbsp;14). It is an odd subtable because it is not a mapping of input code points to glyphs, but contains lists of all variants supported by the font.</p>
<p>A variant may be either &lsquo;default&rsquo; or &lsquo;non-default&rsquo;. A default variant is the one you will get for that code point if you look it up in the standard Unicode cmap. A non-default variant is a different glyph.</p>
</td></tr></table><br>
diff --git a/3party/freetype/docs/reference/ft2-gx_validation.html b/3party/freetype/docs/reference/ft2-gx_validation.html
index 38fe64f0a3..d155948244 100644
--- a/3party/freetype/docs/reference/ft2-gx_validation.html
+++ b/3party/freetype/docs/reference/ft2-gx_validation.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
TrueTypeGX/AAT Validation
diff --git a/3party/freetype/docs/reference/ft2-gzip.html b/3party/freetype/docs/reference/ft2-gzip.html
index 5964ab864a..538347901c 100644
--- a/3party/freetype/docs/reference/ft2-gzip.html
+++ b/3party/freetype/docs/reference/ft2-gzip.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
GZIP Streams
diff --git a/3party/freetype/docs/reference/ft2-header_file_macros.html b/3party/freetype/docs/reference/ft2-header_file_macros.html
index 85875ea28a..95d821b337 100644
--- a/3party/freetype/docs/reference/ft2-header_file_macros.html
+++ b/3party/freetype/docs/reference/ft2-header_file_macros.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,28 +35,29 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Header File Macros
</h1></center>
<h2>Synopsis</h2>
<table align=center cellspacing=5 cellpadding=0 border=0>
-<tr><td></td><td><a href="#FT_CONFIG_CONFIG_H">FT_CONFIG_CONFIG_H</a></td><td></td><td><a href="#FT_WINFONTS_H">FT_WINFONTS_H</a></td></tr>
-<tr><td></td><td><a href="#FT_CONFIG_STANDARD_LIBRARY_H">FT_CONFIG_STANDARD_LIBRARY_H</a></td><td></td><td><a href="#FT_GLYPH_H">FT_GLYPH_H</a></td></tr>
-<tr><td></td><td><a href="#FT_CONFIG_OPTIONS_H">FT_CONFIG_OPTIONS_H</a></td><td></td><td><a href="#FT_BITMAP_H">FT_BITMAP_H</a></td></tr>
-<tr><td></td><td><a href="#FT_CONFIG_MODULES_H">FT_CONFIG_MODULES_H</a></td><td></td><td><a href="#FT_BBOX_H">FT_BBOX_H</a></td></tr>
-<tr><td></td><td><a href="#FT_FREETYPE_H">FT_FREETYPE_H</a></td><td></td><td><a href="#FT_CACHE_H">FT_CACHE_H</a></td></tr>
-<tr><td></td><td><a href="#FT_ERRORS_H">FT_ERRORS_H</a></td><td></td><td><a href="#FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a></td></tr>
-<tr><td></td><td><a href="#FT_MODULE_ERRORS_H">FT_MODULE_ERRORS_H</a></td><td></td><td><a href="#FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a></td></tr>
-<tr><td></td><td><a href="#FT_SYSTEM_H">FT_SYSTEM_H</a></td><td></td><td><a href="#FT_CACHE_CHARMAP_H">FT_CACHE_CHARMAP_H</a></td></tr>
-<tr><td></td><td><a href="#FT_IMAGE_H">FT_IMAGE_H</a></td><td></td><td><a href="#FT_MAC_H">FT_MAC_H</a></td></tr>
-<tr><td></td><td><a href="#FT_TYPES_H">FT_TYPES_H</a></td><td></td><td><a href="#FT_MULTIPLE_MASTERS_H">FT_MULTIPLE_MASTERS_H</a></td></tr>
-<tr><td></td><td><a href="#FT_LIST_H">FT_LIST_H</a></td><td></td><td><a href="#FT_SFNT_NAMES_H">FT_SFNT_NAMES_H</a></td></tr>
-<tr><td></td><td><a href="#FT_OUTLINE_H">FT_OUTLINE_H</a></td><td></td><td><a href="#FT_OPENTYPE_VALIDATE_H">FT_OPENTYPE_VALIDATE_H</a></td></tr>
-<tr><td></td><td><a href="#FT_SIZES_H">FT_SIZES_H</a></td><td></td><td><a href="#FT_GX_VALIDATE_H">FT_GX_VALIDATE_H</a></td></tr>
-<tr><td></td><td><a href="#FT_MODULE_H">FT_MODULE_H</a></td><td></td><td><a href="#FT_PFR_H">FT_PFR_H</a></td></tr>
-<tr><td></td><td><a href="#FT_RENDER_H">FT_RENDER_H</a></td><td></td><td><a href="#FT_STROKER_H">FT_STROKER_H</a></td></tr>
+<tr><td></td><td><a href="#FT_CONFIG_CONFIG_H">FT_CONFIG_CONFIG_H</a></td><td></td><td><a href="#FT_BZIP2_H">FT_BZIP2_H</a></td></tr>
+<tr><td></td><td><a href="#FT_CONFIG_STANDARD_LIBRARY_H">FT_CONFIG_STANDARD_LIBRARY_H</a></td><td></td><td><a href="#FT_WINFONTS_H">FT_WINFONTS_H</a></td></tr>
+<tr><td></td><td><a href="#FT_CONFIG_OPTIONS_H">FT_CONFIG_OPTIONS_H</a></td><td></td><td><a href="#FT_GLYPH_H">FT_GLYPH_H</a></td></tr>
+<tr><td></td><td><a href="#FT_CONFIG_MODULES_H">FT_CONFIG_MODULES_H</a></td><td></td><td><a href="#FT_BITMAP_H">FT_BITMAP_H</a></td></tr>
+<tr><td></td><td><a href="#FT_FREETYPE_H">FT_FREETYPE_H</a></td><td></td><td><a href="#FT_BBOX_H">FT_BBOX_H</a></td></tr>
+<tr><td></td><td><a href="#FT_ERRORS_H">FT_ERRORS_H</a></td><td></td><td><a href="#FT_CACHE_H">FT_CACHE_H</a></td></tr>
+<tr><td></td><td><a href="#FT_MODULE_ERRORS_H">FT_MODULE_ERRORS_H</a></td><td></td><td><a href="#FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a></td></tr>
+<tr><td></td><td><a href="#FT_SYSTEM_H">FT_SYSTEM_H</a></td><td></td><td><a href="#FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a></td></tr>
+<tr><td></td><td><a href="#FT_IMAGE_H">FT_IMAGE_H</a></td><td></td><td><a href="#FT_CACHE_CHARMAP_H">FT_CACHE_CHARMAP_H</a></td></tr>
+<tr><td></td><td><a href="#FT_TYPES_H">FT_TYPES_H</a></td><td></td><td><a href="#FT_MAC_H">FT_MAC_H</a></td></tr>
+<tr><td></td><td><a href="#FT_LIST_H">FT_LIST_H</a></td><td></td><td><a href="#FT_MULTIPLE_MASTERS_H">FT_MULTIPLE_MASTERS_H</a></td></tr>
+<tr><td></td><td><a href="#FT_OUTLINE_H">FT_OUTLINE_H</a></td><td></td><td><a href="#FT_SFNT_NAMES_H">FT_SFNT_NAMES_H</a></td></tr>
+<tr><td></td><td><a href="#FT_SIZES_H">FT_SIZES_H</a></td><td></td><td><a href="#FT_OPENTYPE_VALIDATE_H">FT_OPENTYPE_VALIDATE_H</a></td></tr>
+<tr><td></td><td><a href="#FT_MODULE_H">FT_MODULE_H</a></td><td></td><td><a href="#FT_GX_VALIDATE_H">FT_GX_VALIDATE_H</a></td></tr>
+<tr><td></td><td><a href="#FT_RENDER_H">FT_RENDER_H</a></td><td></td><td><a href="#FT_PFR_H">FT_PFR_H</a></td></tr>
+<tr><td></td><td><a href="#FT_AUTOHINTER_H">FT_AUTOHINTER_H</a></td><td></td><td><a href="#FT_STROKER_H">FT_STROKER_H</a></td></tr>
<tr><td></td><td><a href="#FT_TYPE1_TABLES_H">FT_TYPE1_TABLES_H</a></td><td></td><td><a href="#FT_SYNTHESIS_H">FT_SYNTHESIS_H</a></td></tr>
<tr><td></td><td><a href="#FT_TRUETYPE_IDS_H">FT_TRUETYPE_IDS_H</a></td><td></td><td><a href="#FT_XFREE86_H">FT_XFREE86_H</a></td></tr>
<tr><td></td><td><a href="#FT_TRUETYPE_TABLES_H">FT_TRUETYPE_TABLES_H</a></td><td></td><td><a href="#FT_TRIGONOMETRY_H">FT_TRIGONOMETRY_H</a></td></tr>
@@ -65,7 +66,6 @@ Header File Macros
<tr><td></td><td><a href="#FT_CID_H">FT_CID_H</a></td><td></td><td><a href="#FT_INCREMENTAL_H">FT_INCREMENTAL_H</a></td></tr>
<tr><td></td><td><a href="#FT_GZIP_H">FT_GZIP_H</a></td><td></td><td><a href="#FT_GASP_H">FT_GASP_H</a></td></tr>
<tr><td></td><td><a href="#FT_LZW_H">FT_LZW_H</a></td><td></td><td><a href="#FT_ADVANCES_H">FT_ADVANCES_H</a></td></tr>
-<tr><td></td><td><a href="#FT_BZIP2_H">FT_BZIP2_H</a></td><td></td><td></td></tr>
</table><br><br>
<table align=center width="87%"><tr><td>
@@ -332,6 +332,22 @@ Header File Macros
<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
<table align=center width="75%"><tr><td>
+<h4><a name="FT_AUTOHINTER_H">FT_AUTOHINTER_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_AUTOHINTER_H</b> &lt;freetype/ftautoh.h&gt;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>A macro used in #include statements to name the file containing structures and macros related to the auto-hinting module.</p>
+</td></tr></table><br>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
<h4><a name="FT_TYPE1_TABLES_H">FT_TYPE1_TABLES_H</a></h4>
<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
diff --git a/3party/freetype/docs/reference/ft2-incremental.html b/3party/freetype/docs/reference/ft2-incremental.html
index 1c2a011fef..2e693f752a 100644
--- a/3party/freetype/docs/reference/ft2-incremental.html
+++ b/3party/freetype/docs/reference/ft2-incremental.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Incremental Loading
diff --git a/3party/freetype/docs/reference/ft2-index.html b/3party/freetype/docs/reference/ft2-index.html
index 28ed2f35a3..76aa35f586 100644
--- a/3party/freetype/docs/reference/ft2-index.html
+++ b/3party/freetype/docs/reference/ft2-index.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -34,261 +34,265 @@
<table align=center><tr><td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<table align=center border=0 cellpadding=0 cellspacing=0>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_ATOM</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LcdFilter</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ParseOutline">FT_Stroker_ParseOutline</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_CARDINAL</a></td><td><a href="ft2-header_file_macros.html#FT_LIST_H">FT_LIST_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Rewind">FT_Stroker_Rewind</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_INTEGER</a></td><td><a href="ft2-base_interface.html#FT_Library">FT_Library</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Set">FT_Stroker_Set</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_NONE</a></td><td><a href="ft2-lcd_filtering.html#FT_Library_SetLcdFilter">FT_Library_SetLcdFilter</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_StrokerBorder</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#BDF_Property">BDF_Property</a></td><td><a href="ft2-lcd_filtering.html#FT_Library_SetLcdFilterWeights">FT_Library_SetLcdFilterWeights</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_2X2</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#BDF_PropertyRec">BDF_PropertyRec</a></td><td><a href="ft2-version.html#FT_Library_Version">FT_Library_Version</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_WORDS</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceDict">CID_FaceDict</a></td><td><a href="ft2-list_processing.html#FT_List">FT_List</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceDictRec">CID_FaceDictRec</a></td><td><a href="ft2-list_processing.html#FT_List_Add">FT_List_Add</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ROUND_XY_TO_GRID</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceInfo">CID_FaceInfo</a></td><td><a href="ft2-list_processing.html#FT_List_Destructor">FT_List_Destructor</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_SCALE</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceInfoRec">CID_FaceInfoRec</a></td><td><a href="ft2-list_processing.html#FT_List_Finalize">FT_List_Finalize</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_USE_MY_METRICS</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_Info">CID_Info</a></td><td><a href="ft2-list_processing.html#FT_List_Find">FT_List_Find</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XXX</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MAJOR</a></td><td><a href="ft2-list_processing.html#FT_List_Insert">FT_List_Insert</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XY_SCALE</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MINOR</a></td><td><a href="ft2-list_processing.html#FT_List_Iterate">FT_List_Iterate</a></td><td><a href="ft2-base_interface.html#FT_SubGlyph">FT_SubGlyph</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a></td><td><a href="ft2-list_processing.html#FT_List_Iterator">FT_List_Iterator</a></td><td><a href="ft2-header_file_macros.html#FT_SYNTHESIS_H">FT_SYNTHESIS_H</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_XXX</a></td><td><a href="ft2-list_processing.html#FT_List_Remove">FT_List_Remove</a></td><td><a href="ft2-header_file_macros.html#FT_SYSTEM_H">FT_SYSTEM_H</a></td></tr>
-<tr><td><a href="ft2-sizes_management.html#FT_Activate_Size">FT_Activate_Size</a></td><td><a href="ft2-list_processing.html#FT_List_Up">FT_List_Up</a></td><td><a href="ft2-basic_types.html#FT_Tag">FT_Tag</a></td></tr>
-<tr><td><a href="ft2-quick_advance.html#FT_ADVANCE_FLAG_FAST_ONLY">FT_ADVANCE_FLAG_FAST_ONLY</a></td><td><a href="ft2-list_processing.html#FT_ListNode">FT_ListNode</a></td><td><a href="ft2-computations.html#FT_Tan">FT_Tan</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_ADVANCES_H">FT_ADVANCES_H</a></td><td><a href="ft2-list_processing.html#FT_ListNodeRec">FT_ListNodeRec</a></td><td><a href="ft2-header_file_macros.html#FT_TRIGONOMETRY_H">FT_TRIGONOMETRY_H</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Add_Default_Modules">FT_Add_Default_Modules</a></td><td><a href="ft2-list_processing.html#FT_ListRec">FT_ListRec</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_NONE</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Add_Module">FT_Add_Module</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_CROP_BITMAP</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_PATENTED</a></td></tr>
-<tr><td><a href="ft2-system_interface.html#FT_Alloc_Func">FT_Alloc_Func</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_DEFAULT</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_UNPATENTED</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_2PI">FT_ANGLE_2PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_FORCE_AUTOHINT</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_IDS_H">FT_TRUETYPE_IDS_H</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_PI">FT_ANGLE_PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TABLES_H">FT_TRUETYPE_TABLES_H</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_PI2">FT_ANGLE_PI2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_TRANSFORM</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TAGS_H">FT_TRUETYPE_TAGS_H</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_PI4">FT_ANGLE_PI4</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_LINEAR_DESIGN</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TrueTypeEngineType</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Angle">FT_Angle</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Free">FT_TrueTypeGX_Free</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Angle_Diff">FT_Angle_Diff</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_AUTOHINT</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Validate">FT_TrueTypeGX_Validate</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Atan2">FT_Atan2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_BITMAP</a></td><td><a href="ft2-header_file_macros.html#FT_TYPE1_TABLES_H">FT_TYPE1_TABLES_H</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Attach_File">FT_Attach_File</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a></td><td><a href="ft2-header_file_macros.html#FT_TYPES_H">FT_TYPES_H</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Attach_Stream">FT_Attach_Stream</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_RECURSE</a></td><td><a href="ft2-basic_types.html#FT_UFWord">FT_UFWord</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_BBOX_H">FT_BBOX_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_SCALE</a></td><td><a href="ft2-basic_types.html#FT_UInt">FT_UInt</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_BBox">FT_BBox</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_PEDANTIC</a></td><td><a href="ft2-basic_types.html#FT_UInt16">FT_UInt16</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_BDF_H">FT_BDF_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a></td><td><a href="ft2-basic_types.html#FT_UInt32">FT_UInt32</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_BITMAP_H">FT_BITMAP_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD</a></td><td><a href="ft2-basic_types.html#FT_ULong">FT_ULong</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Bitmap">FT_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD_V</a></td><td><a href="ft2-header_file_macros.html#FT_UNPATENTED_HINTING_H">FT_UNPATENTED_HINTING_H</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Convert">FT_Bitmap_Convert</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LIGHT</a></td><td><a href="ft2-basic_types.html#FT_UnitVector">FT_UnitVector</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Copy">FT_Bitmap_Copy</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_MODE">FT_LOAD_TARGET_MODE</a></td><td><a href="ft2-basic_types.html#FT_UShort">FT_UShort</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Done">FT_Bitmap_Done</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_MONO</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_APPLE</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Embolden">FT_Bitmap_Embolden</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_NORMAL</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_BASE</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_New">FT_Bitmap_New</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_XXX</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_bsln</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Bitmap_Size">FT_Bitmap_Size</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_VERTICAL_LAYOUT</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERN</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyph">FT_BitmapGlyph</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_XXX</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERNXXX</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyphRec">FT_BitmapGlyphRec</a></td><td><a href="ft2-base_interface.html#FT_Load_Char">FT_Load_Char</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_feat</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Bool">FT_Bool</a></td><td><a href="ft2-base_interface.html#FT_Load_Glyph">FT_Load_Glyph</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GDEF</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Byte">FT_Byte</a></td><td><a href="ft2-truetype_tables.html#FT_Load_Sfnt_Table">FT_Load_Sfnt_Table</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GPOS</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Bytes">FT_Bytes</a></td><td><a href="ft2-basic_types.html#FT_Long">FT_Long</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GSUB</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_BZIP2_H">FT_BZIP2_H</a></td><td><a href="ft2-header_file_macros.html#FT_LZW_H">FT_LZW_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GX</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_CHARMAP_H">FT_CACHE_CHARMAP_H</a></td><td><a href="ft2-header_file_macros.html#FT_MAC_H">FT_MAC_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GX_LENGTH">FT_VALIDATE_GX_LENGTH</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a></td><td><a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GXXXX</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a></td><td><a href="ft2-basic_types.html#FT_Matrix">FT_Matrix</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_JSTF</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a></td><td><a href="ft2-computations.html#FT_Matrix_Invert">FT_Matrix_Invert</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_just</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_CeilFix">FT_CeilFix</a></td><td><a href="ft2-computations.html#FT_Matrix_Multiply">FT_Matrix_Multiply</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_kern</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Char">FT_Char</a></td><td><a href="ft2-system_interface.html#FT_Memory">FT_Memory</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_lcar</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_CharMap">FT_CharMap</a></td><td><a href="ft2-system_interface.html#FT_MemoryRec">FT_MemoryRec</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_MATH</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_CharMapRec">FT_CharMapRec</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Axis">FT_MM_Axis</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_MS</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CID_H">FT_CID_H</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Var">FT_MM_Var</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_mort</a></td></tr>
-<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Free">FT_ClassicKern_Free</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_ERRORS_H">FT_MODULE_ERRORS_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_morx</a></td></tr>
-<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Validate">FT_ClassicKern_Validate</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_H">FT_MODULE_H</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OT</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_CONFIG_H">FT_CONFIG_CONFIG_H</a></td><td><a href="ft2-base_interface.html#FT_Module">FT_Module</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OTXXX</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_MODULES_H">FT_CONFIG_MODULES_H</a></td><td><a href="ft2-module_management.html#FT_Module_Class">FT_Module_Class</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_opbd</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_OPTIONS_H">FT_CONFIG_OPTIONS_H</a></td><td><a href="ft2-module_management.html#FT_Module_Constructor">FT_Module_Constructor</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_prop</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_STANDARD_LIBRARY_H">FT_CONFIG_STANDARD_LIBRARY_H</a></td><td><a href="ft2-module_management.html#FT_Module_Destructor">FT_Module_Destructor</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_trak</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Cos">FT_Cos</a></td><td><a href="ft2-module_management.html#FT_Module_Requester">FT_Module_Requester</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Axis">FT_Var_Axis</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Data">FT_Data</a></td><td><a href="ft2-header_file_macros.html#FT_MULTIPLE_MASTERS_H">FT_MULTIPLE_MASTERS_H</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Named_Style">FT_Var_Named_Style</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_DivFix">FT_DivFix</a></td><td><a href="ft2-computations.html#FT_MulDiv">FT_MulDiv</a></td><td><a href="ft2-basic_types.html#FT_Vector">FT_Vector</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Done_Face">FT_Done_Face</a></td><td><a href="ft2-computations.html#FT_MulFix">FT_MulFix</a></td><td><a href="ft2-computations.html#FT_Vector_From_Polar">FT_Vector_From_Polar</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Done_FreeType">FT_Done_FreeType</a></td><td><a href="ft2-multiple_masters.html#FT_Multi_Master">FT_Multi_Master</a></td><td><a href="ft2-computations.html#FT_Vector_Length">FT_Vector_Length</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Done_Glyph">FT_Done_Glyph</a></td><td><a href="ft2-base_interface.html#FT_New_Face">FT_New_Face</a></td><td><a href="ft2-computations.html#FT_Vector_Polarize">FT_Vector_Polarize</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Done_Library">FT_Done_Library</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FOND">FT_New_Face_From_FOND</a></td><td><a href="ft2-computations.html#FT_Vector_Rotate">FT_Vector_Rotate</a></td></tr>
-<tr><td><a href="ft2-sizes_management.html#FT_Done_Size">FT_Done_Size</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSRef">FT_New_Face_From_FSRef</a></td><td><a href="ft2-computations.html#FT_Vector_Transform">FT_Vector_Transform</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Driver">FT_Driver</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSSpec">FT_New_Face_From_FSSpec</a></td><td><a href="ft2-computations.html#FT_Vector_Unit">FT_Vector_Unit</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_ENC_TAG">FT_ENC_TAG</a></td><td><a href="ft2-module_management.html#FT_New_Library">FT_New_Library</a></td><td><a href="ft2-header_file_macros.html#FT_WINFONTS_H">FT_WINFONTS_H</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_CUSTOM</a></td><td><a href="ft2-base_interface.html#FT_New_Memory_Face">FT_New_Memory_Face</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_Header">FT_WinFNT_Header</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_EXPERT</a></td><td><a href="ft2-sizes_management.html#FT_New_Size">FT_New_Size</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_HeaderRec">FT_WinFNT_HeaderRec</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_LATIN_1</a></td><td><a href="ft2-basic_types.html#FT_Offset">FT_Offset</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1250</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_STANDARD</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_DRIVER</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1251</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_APPLE_ROMAN</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_MEMORY</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1252</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_BIG5</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PARAMS</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1253</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_GB2312</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PATHNAME</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1254</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_JOHAB</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_STREAM</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1255</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_BIG5</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_XXX</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1256</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_GB2312</a></td><td><a href="ft2-header_file_macros.html#FT_OPENTYPE_VALIDATE_H">FT_OPENTYPE_VALIDATE_H</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1257</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_JOHAB</a></td><td><a href="ft2-base_interface.html#FT_Open_Args">FT_Open_Args</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1258</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SJIS</a></td><td><a href="ft2-base_interface.html#FT_Open_Face">FT_Open_Face</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1361</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SYMBOL</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Free">FT_OpenType_Free</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP874</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_WANSUNG</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Validate">FT_OpenType_Validate</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP932</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_NONE</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_LEFT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP936</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_OLD_LATIN_2</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_RIGHT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP949</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_SJIS</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_NONE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP950</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_UNICODE</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_POSTSCRIPT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_DEFAULT</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_WANSUNG</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_TRUETYPE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_MAC</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_Encoding</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_Orientation</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_OEM</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_ERRORS_H">FT_ERRORS_H</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_EVEN_ODD_FILL</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_SYMBOL</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Error">FT_Error</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_FLAGS</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_F26Dot6">FT_F26Dot6</a></td><td><a href="ft2-header_file_macros.html#FT_OUTLINE_H">FT_OUTLINE_H</a></td><td><a href="ft2-header_file_macros.html#FT_XFREE86_H">FT_XFREE86_H</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_F2Dot14">FT_F2Dot14</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_HIGH_PRECISION</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache">FTC_CMapCache</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_CID_KEYED</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_Lookup">FTC_CMapCache_Lookup</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_EXTERNAL_STREAM</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_INCLUDE_STUBS</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_New">FTC_CMapCache_New</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FAST_GLYPHS</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_NONE</a></td><td><a href="ft2-cache_subsystem.html#FTC_Face_Requester">FTC_Face_Requester</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_SIZES</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_OWNER</a></td><td><a href="ft2-cache_subsystem.html#FTC_FaceID">FTC_FaceID</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_WIDTH</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_REVERSE_FILL</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache">FTC_ImageCache</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_GLYPH_NAMES</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SINGLE_PASS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_Lookup">FTC_ImageCache_Lookup</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HINTER</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SMART_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_LookupScaler">FTC_ImageCache_LookupScaler</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HORIZONTAL</a></td><td><a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_New">FTC_ImageCache_New</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_KERNING</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Check">FT_Outline_Check</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageType">FTC_ImageType</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_MULTIPLE_MASTERS</a></td><td><a href="ft2-outline_processing.html#FT_Outline_ConicToFunc">FT_Outline_ConicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageTypeRec">FTC_ImageTypeRec</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SCALABLE</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Copy">FT_Outline_Copy</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager">FTC_Manager</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SFNT</a></td><td><a href="ft2-outline_processing.html#FT_Outline_CubicToFunc">FT_Outline_CubicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Done">FTC_Manager_Done</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_TRICKY</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Decompose">FT_Outline_Decompose</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupFace">FTC_Manager_LookupFace</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_VERTICAL</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Done">FT_Outline_Done</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupSize">FTC_Manager_LookupSize</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_XXX</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Embolden">FT_Outline_Embolden</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_New">FTC_Manager_New</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Face">FT_Face</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Funcs">FT_Outline_Funcs</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_RemoveFaceID">FTC_Manager_RemoveFaceID</a></td></tr>
-<tr><td><a href="ft2-version.html#FT_Face_CheckTrueTypePatents">FT_Face_CheckTrueTypePatents</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_BBox">FT_Outline_Get_BBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Reset">FTC_Manager_Reset</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharsOfVariant">FT_Face_GetCharsOfVariant</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Bitmap">FT_Outline_Get_Bitmap</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node">FTC_Node</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIndex">FT_Face_GetCharVariantIndex</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_CBox">FT_Outline_Get_CBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node_Unref">FTC_Node_Unref</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIsDefault">FT_Face_GetCharVariantIsDefault</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Orientation">FT_Outline_Get_Orientation</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBit">FTC_SBit</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantSelectors">FT_Face_GetVariantSelectors</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetInsideBorder">FT_Outline_GetInsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache">FTC_SBitCache</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantsOfChar">FT_Face_GetVariantsOfChar</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetOutsideBorder">FT_Outline_GetOutsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_Lookup">FTC_SBitCache_Lookup</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Face_Internal">FT_Face_Internal</a></td><td><a href="ft2-outline_processing.html#FT_Outline_LineToFunc">FT_Outline_LineToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_LookupScaler">FTC_SBitCache_LookupScaler</a></td></tr>
-<tr><td><a href="ft2-version.html#FT_Face_SetUnpatentedHinting">FT_Face_SetUnpatentedHinting</a></td><td><a href="ft2-outline_processing.html#FT_Outline_MoveToFunc">FT_Outline_MoveToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_New">FTC_SBitCache_New</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a></td><td><a href="ft2-outline_processing.html#FT_Outline_New">FT_Outline_New</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitRec">FTC_SBitRec</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Fixed">FT_Fixed</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Render">FT_Outline_Render</a></td><td><a href="ft2-cache_subsystem.html#FTC_Scaler">FTC_Scaler</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_FloorFix">FT_FloorFix</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Reverse">FT_Outline_Reverse</a></td><td><a href="ft2-cache_subsystem.html#FTC_ScalerRec">FTC_ScalerRec</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Transform">FT_Outline_Transform</a></td><td><a href="ft2-base_interface.html#ft_encoding_xxx">ft_encoding_xxx</a></td></tr>
-<tr><td><a href="ft2-system_interface.html#FT_Free_Func">FT_Free_Func</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Translate">FT_Outline_Translate</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_gridfit</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_BITMAP_EMBEDDING_ONLY</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyph">FT_OutlineGlyph</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_pixels</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_EDITABLE_EMBEDDING</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyphRec">FT_OutlineGlyphRec</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_subpixels</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_INSTALLABLE_EMBEDDING</a></td><td><a href="ft2-sfnt_names.html#FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_truncate</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_NO_SUBSETTING</a></td><td><a href="ft2-sfnt_names.html#FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_unscaled</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING</a></td><td><a href="ft2-incremental.html#FT_PARAM_TAG_INCREMENTAL">FT_PARAM_TAG_INCREMENTAL</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_xxx</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING</a></td><td><a href="ft2-truetype_tables.html#FT_PARAM_TAG_UNPATENTED_HINTING">FT_PARAM_TAG_UNPATENTED_HINTING</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_bitmap</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_XXX</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">FT_Palette_Mode</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_composite</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_FWord">FT_FWord</a></td><td><a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_none</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRAY</a></td><td><a href="ft2-header_file_macros.html#FT_PFR_H">FT_PFR_H</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_outline</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRIDFIT</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_plotter</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GASP_H">FT_GASP_H</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY2</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_xxx</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_NO_TABLE</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY4</a></td><td><a href="ft2-base_interface.html#ft_kerning_default">ft_kerning_default</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_GRIDFIT</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD</a></td><td><a href="ft2-base_interface.html#ft_kerning_unfitted">ft_kerning_unfitted</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_SMOOTHING</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD_V</a></td><td><a href="ft2-base_interface.html#ft_kerning_unscaled">ft_kerning_unscaled</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_XXX</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_MONO</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_driver</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Generic">FT_Generic</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_NONE</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_memory</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Generic_Finalizer">FT_Generic_Finalizer</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_Pixel_Mode</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_params</a></td></tr>
-<tr><td><a href="ft2-quick_advance.html#FT_Get_Advance">FT_Get_Advance</a></td><td><a href="ft2-basic_types.html#FT_Pointer">FT_Pointer</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_pathname</a></td></tr>
-<tr><td><a href="ft2-quick_advance.html#FT_Get_Advances">FT_Get_Advances</a></td><td><a href="ft2-basic_types.html#FT_Pos">FT_Pos</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_stream</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Charset_ID">FT_Get_BDF_Charset_ID</a></td><td><a href="ft2-bdf_fonts.html#FT_PropertyType">FT_PropertyType</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_even_odd_fill</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Property">FT_Get_BDF_Property</a></td><td><a href="ft2-basic_types.html#FT_PtrDist">FT_PtrDist</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_flags</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Char_Index">FT_Get_Char_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_AA</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_high_precision</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Charmap_Index">FT_Get_Charmap_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_CLIP</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_ignore_dropouts</a></td></tr>
-<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_From_Glyph_Index">FT_Get_CID_From_Glyph_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DEFAULT</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_none</a></td></tr>
-<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Is_Internally_CID_Keyed">FT_Get_CID_Is_Internally_CID_Keyed</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DIRECT</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_owner</a></td></tr>
-<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Registry_Ordering_Supplement">FT_Get_CID_Registry_Ordering_Supplement</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_XXX</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_reverse_fill</a></td></tr>
-<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Format">FT_Get_CMap_Format</a></td><td><a href="ft2-raster.html#FT_Raster">FT_Raster</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_single_pass</a></td></tr>
-<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Language_ID">FT_Get_CMap_Language_ID</a></td><td><a href="ft2-raster.html#FT_Raster_BitSet_Func">FT_Raster_BitSet_Func</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgb</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_First_Char">FT_Get_First_Char</a></td><td><a href="ft2-raster.html#FT_Raster_BitTest_Func">FT_Raster_BitTest_Func</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgba</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_FSType_Flags">FT_Get_FSType_Flags</a></td><td><a href="ft2-raster.html#FT_Raster_DoneFunc">FT_Raster_DoneFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_grays</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_Get_Gasp">FT_Get_Gasp</a></td><td><a href="ft2-raster.html#FT_Raster_Funcs">FT_Raster_Funcs</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_mono</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Get_Glyph">FT_Get_Glyph</a></td><td><a href="ft2-raster.html#FT_Raster_NewFunc">FT_Raster_NewFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_none</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Glyph_Name">FT_Get_Glyph_Name</a></td><td><a href="ft2-raster.html#FT_Raster_Params">FT_Raster_Params</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal2</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Kerning">FT_Get_Kerning</a></td><td><a href="ft2-raster.html#FT_Raster_RenderFunc">FT_Raster_RenderFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal4</a></td></tr>
-<tr><td><a href="ft2-multiple_masters.html#FT_Get_MM_Var">FT_Get_MM_Var</a></td><td><a href="ft2-raster.html#FT_Raster_ResetFunc">FT_Raster_ResetFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_xxx</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Get_Module">FT_Get_Module</a></td><td><a href="ft2-raster.html#FT_Raster_SetModeFunc">FT_Raster_SetModeFunc</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_mono</a></td></tr>
-<tr><td><a href="ft2-multiple_masters.html#FT_Get_Multi_Master">FT_Get_Multi_Master</a></td><td><a href="ft2-header_file_macros.html#FT_RENDER_H">FT_RENDER_H</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_normal</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Name_Index">FT_Get_Name_Index</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_xxx</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Next_Char">FT_Get_Next_Char</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD_V</a></td><td><a href="ft2-type1_tables.html#PS_Dict_Keys">PS_Dict_Keys</a></td></tr>
-<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Advance">FT_Get_PFR_Advance</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LIGHT</a></td><td><a href="ft2-type1_tables.html#PS_FontInfo">PS_FontInfo</a></td></tr>
-<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Kerning">FT_Get_PFR_Kerning</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_MONO</a></td><td><a href="ft2-type1_tables.html#PS_FontInfoRec">PS_FontInfoRec</a></td></tr>
-<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Metrics">FT_Get_PFR_Metrics</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_NORMAL</a></td><td><a href="ft2-type1_tables.html#PS_Private">PS_Private</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Postscript_Name">FT_Get_Postscript_Name</a></td><td><a href="ft2-system_interface.html#FT_Realloc_Func">FT_Realloc_Func</a></td><td><a href="ft2-type1_tables.html#PS_PrivateRec">PS_PrivateRec</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Info">FT_Get_PS_Font_Info</a></td><td><a href="ft2-base_interface.html#FT_Reference_Face">FT_Reference_Face</a></td><td><a href="ft2-type1_tables.html#T1_Blend_Flags">T1_Blend_Flags</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Private">FT_Get_PS_Font_Private</a></td><td><a href="ft2-module_management.html#FT_Reference_Library">FT_Reference_Library</a></td><td><a href="ft2-type1_tables.html#T1_EncodingType">T1_EncodingType</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Value">FT_Get_PS_Font_Value</a></td><td><a href="ft2-module_management.html#FT_Remove_Module">FT_Remove_Module</a></td><td><a href="ft2-type1_tables.html#T1_FontInfo">T1_FontInfo</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Get_Renderer">FT_Get_Renderer</a></td><td><a href="ft2-base_interface.html#FT_Render_Glyph">FT_Render_Glyph</a></td><td><a href="ft2-type1_tables.html#T1_Private">T1_Private</a></td></tr>
-<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name">FT_Get_Sfnt_Name</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_Render_Mode</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_CUSTOM</a></td></tr>
-<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name_Count">FT_Get_Sfnt_Name_Count</a></td><td><a href="ft2-base_interface.html#FT_Renderer">FT_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_EXPERT</a></td></tr>
-<tr><td><a href="ft2-truetype_tables.html#FT_Get_Sfnt_Table">FT_Get_Sfnt_Table</a></td><td><a href="ft2-module_management.html#FT_Renderer_Class">FT_Renderer_Class</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_LATIN_1</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_SubGlyph_Info">FT_Get_SubGlyph_Info</a></td><td><a href="ft2-base_interface.html#FT_Request_Size">FT_Request_Size</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_STANDARD</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Track_Kerning">FT_Get_Track_Kerning</a></td><td><a href="ft2-computations.html#FT_RoundFix">FT_RoundFix</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-truetype_engine.html#FT_Get_TrueType_Engine_Type">FT_Get_TrueType_Engine_Type</a></td><td><a href="ft2-base_interface.html#FT_Select_Charmap">FT_Select_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_DEFAULT</a></td></tr>
-<tr><td><a href="ft2-winfnt_fonts.html#FT_Get_WinFNT_Header">FT_Get_WinFNT_Header</a></td><td><a href="ft2-base_interface.html#FT_Select_Size">FT_Select_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_ISO_10646</a></td></tr>
-<tr><td><a href="ft2-font_formats.html#FT_Get_X11_Font_Format">FT_Get_X11_Font_Format</a></td><td><a href="ft2-base_interface.html#FT_Set_Char_Size">FT_Set_Char_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_1_1</a></td></tr>
-<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_ATS_Name">FT_GetFile_From_Mac_ATS_Name</a></td><td><a href="ft2-base_interface.html#FT_Set_Charmap">FT_Set_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_2_0</a></td></tr>
-<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_Name">FT_GetFile_From_Mac_Name</a></td><td><a href="ft2-module_management.html#FT_Set_Debug_Hook">FT_Set_Debug_Hook</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_32</a></td></tr>
-<tr><td><a href="ft2-mac_specific.html#FT_GetFilePath_From_Mac_ATS_Name">FT_GetFilePath_From_Mac_ATS_Name</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Blend_Coordinates">FT_Set_MM_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_VARIANT_SELECTOR</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_GRIDFIT</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Design_Coordinates">FT_Set_MM_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_PIXELS</a></td><td><a href="ft2-base_interface.html#FT_Set_Pixel_Sizes">FT_Set_Pixel_Sizes</a></td><td><a href="ft2-truetype_tables.html#TT_Header">TT_Header</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_SUBPIXELS</a></td><td><a href="ft2-module_management.html#FT_Set_Renderer">FT_Set_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_HoriHeader">TT_HoriHeader</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_TRUNCATE</a></td><td><a href="ft2-base_interface.html#FT_Set_Transform">FT_Set_Transform</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_10646</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_UNSCALED</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Blend_Coordinates">FT_Set_Var_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_7BIT_ASCII</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_BITMAP</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Design_Coordinates">FT_Set_Var_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_8859_1</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_COMPOSITE</a></td><td><a href="ft2-header_file_macros.html#FT_SFNT_NAMES_H">FT_SFNT_NAMES_H</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_NONE</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Table_Info">FT_Sfnt_Table_Info</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARABIC</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_OUTLINE</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Tag">FT_Sfnt_Tag</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARMENIAN</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_PLOTTER</a></td><td><a href="ft2-sfnt_names.html#FT_SfntName">FT_SfntName</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BENGALI</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GLYPH_H">FT_GLYPH_H</a></td><td><a href="ft2-basic_types.html#FT_Short">FT_Short</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BURMESE</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph">FT_Glyph</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_BBOX</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_DEVANAGARI</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_Glyph_BBox_Mode</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_CELL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEEZ</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Copy">FT_Glyph_Copy</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_NOMINAL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEORGIAN</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_Glyph_Format</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_REAL_DIM</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GREEK</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Get_CBox">FT_Glyph_Get_CBox</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_SCALES</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GUJARATI</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Glyph_Metrics">FT_Glyph_Metrics</a></td><td><a href="ft2-header_file_macros.html#FT_SIZES_H">FT_SIZES_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GURMUKHI</a></td></tr>
-<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_Stroke">FT_Glyph_Stroke</a></td><td><a href="ft2-computations.html#FT_Sin">FT_Sin</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_HEBREW</a></td></tr>
-<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_StrokeBorder">FT_Glyph_StrokeBorder</a></td><td><a href="ft2-base_interface.html#FT_Size">FT_Size</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_JAPANESE</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_To_Bitmap">FT_Glyph_To_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_Size_Internal">FT_Size_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KANNADA</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Transform">FT_Glyph_Transform</a></td><td><a href="ft2-base_interface.html#FT_Size_Metrics">FT_Size_Metrics</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KHMER</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_GlyphRec">FT_GlyphRec</a></td><td><a href="ft2-base_interface.html#FT_Size_Request">FT_Size_Request</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KOREAN</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_GlyphSlot">FT_GlyphSlot</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_Size_Request_Type</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_LAOTIAN</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_GlyphSlot_Own_Bitmap">FT_GlyphSlot_Own_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_Size_RequestRec">FT_Size_RequestRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALAYALAM</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_GlyphSlotRec">FT_GlyphSlotRec</a></td><td><a href="ft2-base_interface.html#FT_SizeRec">FT_SizeRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALDIVIAN</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GX_VALIDATE_H">FT_GX_VALIDATE_H</a></td><td><a href="ft2-base_interface.html#FT_Slot_Internal">FT_Slot_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MONGOLIAN</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GZIP_H">FT_GZIP_H</a></td><td><a href="ft2-raster.html#FT_Span">FT_Span</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ORIYA</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_FAST_GLYPHS">FT_HAS_FAST_GLYPHS</a></td><td><a href="ft2-raster.html#FT_SpanFunc">FT_SpanFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ROMAN</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_FIXED_SIZES">FT_HAS_FIXED_SIZES</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_LEFT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RSYMBOL</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_GLYPH_NAMES">FT_HAS_GLYPH_NAMES</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_RIGHT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RUSSIAN</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_HORIZONTAL">FT_HAS_HORIZONTAL</a></td><td><a href="ft2-header_file_macros.html#FT_STROKER_H">FT_STROKER_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SIMPLIFIED_CHINESE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_KERNING">FT_HAS_KERNING</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_BUTT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINDHI</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_MULTIPLE_MASTERS">FT_HAS_MULTIPLE_MASTERS</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINHALESE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_VERTICAL">FT_HAS_VERTICAL</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_SQUARE</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SLAVIC</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#FT_Has_PS_Glyph_Names">FT_Has_PS_Glyph_Names</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_BEVEL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TAMIL</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_IMAGE_H">FT_IMAGE_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TELUGU</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_IMAGE_TAG">FT_IMAGE_TAG</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER_FIXED</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_THAI</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_INCREMENTAL_H">FT_INCREMENTAL_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER_VARIABLE</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TIBETAN</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental">FT_Incremental</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TRADITIONAL_CHINESE</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_FreeGlyphDataFunc">FT_Incremental_FreeGlyphDataFunc</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_BOLD</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_UNINTERP</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_FuncsRec">FT_Incremental_FuncsRec</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_ITALIC</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_VIETNAMESE</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphDataFunc">FT_Incremental_GetGlyphDataFunc</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_XXX</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphMetricsFunc">FT_Incremental_GetGlyphMetricsFunc</a></td><td><a href="ft2-system_interface.html#FT_Stream">FT_Stream</a></td><td><a href="ft2-truetype_tables.html#TT_MaxProfile">TT_MaxProfile</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_Interface">FT_Incremental_Interface</a></td><td><a href="ft2-system_interface.html#FT_Stream_CloseFunc">FT_Stream_CloseFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_BIG_5</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_InterfaceRec">FT_Incremental_InterfaceRec</a></td><td><a href="ft2-system_interface.html#FT_Stream_IoFunc">FT_Stream_IoFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_GB2312</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_Metrics">FT_Incremental_Metrics</a></td><td><a href="ft2-bzip2.html#FT_Stream_OpenBzip2">FT_Stream_OpenBzip2</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_JOHAB</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_MetricsRec">FT_Incremental_MetricsRec</a></td><td><a href="ft2-gzip.html#FT_Stream_OpenGzip">FT_Stream_OpenGzip</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SJIS</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Init_FreeType">FT_Init_FreeType</a></td><td><a href="ft2-lzw.html#FT_Stream_OpenLZW">FT_Stream_OpenLZW</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SYMBOL_CS</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Int">FT_Int</a></td><td><a href="ft2-system_interface.html#FT_StreamDesc">FT_StreamDesc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UCS_4</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Int16">FT_Int16</a></td><td><a href="ft2-system_interface.html#FT_StreamRec">FT_StreamRec</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UNICODE_CS</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Int32">FT_Int32</a></td><td><a href="ft2-basic_types.html#FT_String">FT_String</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_WANSUNG</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_CID_KEYED">FT_IS_CID_KEYED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker">FT_Stroker</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_FIXED_WIDTH">FT_IS_FIXED_WIDTH</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_BeginSubPath">FT_Stroker_BeginSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_OS2">TT_OS2</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_SCALABLE">FT_IS_SCALABLE</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ConicTo">FT_Stroker_ConicTo</a></td><td><a href="ft2-truetype_tables.html#TT_PCLT">TT_PCLT</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_SFNT">FT_IS_SFNT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_CubicTo">FT_Stroker_CubicTo</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ADOBE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_TRICKY">FT_IS_TRICKY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Done">FT_Stroker_Done</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_APPLE_UNICODE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_EndSubPath">FT_Stroker_EndSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_CUSTOM</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNFITTED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Export">FT_Stroker_Export</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ISO</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNSCALED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ExportBorder">FT_Stroker_ExportBorder</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MACINTOSH</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_Kerning_Mode</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetBorderCounts">FT_Stroker_GetBorderCounts</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MICROSOFT</a></td></tr>
-<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetCounts">FT_Stroker_GetCounts</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_XXX</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_LCD_FILTER_H">FT_LCD_FILTER_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_Stroker_LineCap</a></td><td><a href="ft2-truetype_tables.html#TT_Postscript">TT_Postscript</a></td></tr>
-<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LEGACY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_Stroker_LineJoin</a></td><td><a href="ft2-truetype_tables.html#TT_VertHeader">TT_VertHeader</a></td></tr>
-<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LIGHT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineTo">FT_Stroker_LineTo</a></td><td></td></tr>
-<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_NONE</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_New">FT_Stroker_New</a></td><td></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_ATOM</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LIGHT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_Stroker_LineJoin</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_CARDINAL</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_NONE</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineTo">FT_Stroker_LineTo</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_INTEGER</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LcdFilter</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_New">FT_Stroker_New</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_NONE</a></td><td><a href="ft2-header_file_macros.html#FT_LIST_H">FT_LIST_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ParseOutline">FT_Stroker_ParseOutline</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#BDF_Property">BDF_Property</a></td><td><a href="ft2-base_interface.html#FT_Library">FT_Library</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Rewind">FT_Stroker_Rewind</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#BDF_PropertyRec">BDF_PropertyRec</a></td><td><a href="ft2-lcd_filtering.html#FT_Library_SetLcdFilter">FT_Library_SetLcdFilter</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Set">FT_Stroker_Set</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceDict">CID_FaceDict</a></td><td><a href="ft2-lcd_filtering.html#FT_Library_SetLcdFilterWeights">FT_Library_SetLcdFilterWeights</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_StrokerBorder</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceDictRec">CID_FaceDictRec</a></td><td><a href="ft2-version.html#FT_Library_Version">FT_Library_Version</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_2X2</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceInfo">CID_FaceInfo</a></td><td><a href="ft2-list_processing.html#FT_List">FT_List</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_WORDS</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceInfoRec">CID_FaceInfoRec</a></td><td><a href="ft2-list_processing.html#FT_List_Add">FT_List_Add</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_Info">CID_Info</a></td><td><a href="ft2-list_processing.html#FT_List_Destructor">FT_List_Destructor</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ROUND_XY_TO_GRID</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MAJOR</a></td><td><a href="ft2-list_processing.html#FT_List_Finalize">FT_List_Finalize</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_SCALE</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MINOR</a></td><td><a href="ft2-list_processing.html#FT_List_Find">FT_List_Find</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_USE_MY_METRICS</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a></td><td><a href="ft2-list_processing.html#FT_List_Insert">FT_List_Insert</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XXX</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_XXX</a></td><td><a href="ft2-list_processing.html#FT_List_Iterate">FT_List_Iterate</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XY_SCALE</a></td></tr>
+<tr><td><a href="ft2-sizes_management.html#FT_Activate_Size">FT_Activate_Size</a></td><td><a href="ft2-list_processing.html#FT_List_Iterator">FT_List_Iterator</a></td><td><a href="ft2-base_interface.html#FT_SubGlyph">FT_SubGlyph</a></td></tr>
+<tr><td><a href="ft2-quick_advance.html#FT_ADVANCE_FLAG_FAST_ONLY">FT_ADVANCE_FLAG_FAST_ONLY</a></td><td><a href="ft2-list_processing.html#FT_List_Remove">FT_List_Remove</a></td><td><a href="ft2-header_file_macros.html#FT_SYNTHESIS_H">FT_SYNTHESIS_H</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_ADVANCES_H">FT_ADVANCES_H</a></td><td><a href="ft2-list_processing.html#FT_List_Up">FT_List_Up</a></td><td><a href="ft2-header_file_macros.html#FT_SYSTEM_H">FT_SYSTEM_H</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Add_Default_Modules">FT_Add_Default_Modules</a></td><td><a href="ft2-list_processing.html#FT_ListNode">FT_ListNode</a></td><td><a href="ft2-basic_types.html#FT_Tag">FT_Tag</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Add_Module">FT_Add_Module</a></td><td><a href="ft2-list_processing.html#FT_ListNodeRec">FT_ListNodeRec</a></td><td><a href="ft2-computations.html#FT_Tan">FT_Tan</a></td></tr>
+<tr><td><a href="ft2-system_interface.html#FT_Alloc_Func">FT_Alloc_Func</a></td><td><a href="ft2-list_processing.html#FT_ListRec">FT_ListRec</a></td><td><a href="ft2-header_file_macros.html#FT_TRIGONOMETRY_H">FT_TRIGONOMETRY_H</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_2PI">FT_ANGLE_2PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_CROP_BITMAP</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_NONE</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_PI">FT_ANGLE_PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_DEFAULT</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_PATENTED</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_PI2">FT_ANGLE_PI2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_FORCE_AUTOHINT</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_UNPATENTED</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_PI4">FT_ANGLE_PI4</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_IDS_H">FT_TRUETYPE_IDS_H</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Angle">FT_Angle</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_TRANSFORM</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TABLES_H">FT_TRUETYPE_TABLES_H</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Angle_Diff">FT_Angle_Diff</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_LINEAR_DESIGN</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TAGS_H">FT_TRUETYPE_TAGS_H</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Atan2">FT_Atan2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TrueTypeEngineType</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Attach_File">FT_Attach_File</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_AUTOHINT</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Free">FT_TrueTypeGX_Free</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Attach_Stream">FT_Attach_Stream</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_BITMAP</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Validate">FT_TrueTypeGX_Validate</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_AUTOHINTER_H">FT_AUTOHINTER_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a></td><td><a href="ft2-header_file_macros.html#FT_TYPE1_TABLES_H">FT_TYPE1_TABLES_H</a></td></tr>
+<tr><td><a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_CJK</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_RECURSE</a></td><td><a href="ft2-header_file_macros.html#FT_TYPES_H">FT_TYPES_H</a></td></tr>
+<tr><td><a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_INDIC</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_SCALE</a></td><td><a href="ft2-basic_types.html#FT_UFWord">FT_UFWord</a></td></tr>
+<tr><td><a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_LATIN</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_PEDANTIC</a></td><td><a href="ft2-basic_types.html#FT_UInt">FT_UInt</a></td></tr>
+<tr><td><a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_NONE</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a></td><td><a href="ft2-basic_types.html#FT_UInt16">FT_UInt16</a></td></tr>
+<tr><td><a href="ft2-auto_hinter.html#FT_AUTOHINTER_SCRIPT_XXX">FT_AUTOHINTER_SCRIPT_XXX</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD</a></td><td><a href="ft2-basic_types.html#FT_UInt32">FT_UInt32</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_BBOX_H">FT_BBOX_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD_V</a></td><td><a href="ft2-basic_types.html#FT_ULong">FT_ULong</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_BBox">FT_BBox</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LIGHT</a></td><td><a href="ft2-header_file_macros.html#FT_UNPATENTED_HINTING_H">FT_UNPATENTED_HINTING_H</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_BDF_H">FT_BDF_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_MODE">FT_LOAD_TARGET_MODE</a></td><td><a href="ft2-basic_types.html#FT_UnitVector">FT_UnitVector</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_BITMAP_H">FT_BITMAP_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_MONO</a></td><td><a href="ft2-basic_types.html#FT_UShort">FT_UShort</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Bitmap">FT_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_NORMAL</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_APPLE</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Convert">FT_Bitmap_Convert</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_XXX</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_BASE</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Copy">FT_Bitmap_Copy</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_VERTICAL_LAYOUT</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_bsln</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Done">FT_Bitmap_Done</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_XXX</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERN</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Embolden">FT_Bitmap_Embolden</a></td><td><a href="ft2-base_interface.html#FT_Load_Char">FT_Load_Char</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERNXXX</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_New">FT_Bitmap_New</a></td><td><a href="ft2-base_interface.html#FT_Load_Glyph">FT_Load_Glyph</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_feat</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Bitmap_Size">FT_Bitmap_Size</a></td><td><a href="ft2-truetype_tables.html#FT_Load_Sfnt_Table">FT_Load_Sfnt_Table</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GDEF</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyph">FT_BitmapGlyph</a></td><td><a href="ft2-basic_types.html#FT_Long">FT_Long</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GPOS</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyphRec">FT_BitmapGlyphRec</a></td><td><a href="ft2-header_file_macros.html#FT_LZW_H">FT_LZW_H</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GSUB</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Bool">FT_Bool</a></td><td><a href="ft2-header_file_macros.html#FT_MAC_H">FT_MAC_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GX</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Byte">FT_Byte</a></td><td><a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GX_LENGTH">FT_VALIDATE_GX_LENGTH</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Bytes">FT_Bytes</a></td><td><a href="ft2-basic_types.html#FT_Matrix">FT_Matrix</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GXXXX</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_BZIP2_H">FT_BZIP2_H</a></td><td><a href="ft2-computations.html#FT_Matrix_Invert">FT_Matrix_Invert</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_JSTF</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_CHARMAP_H">FT_CACHE_CHARMAP_H</a></td><td><a href="ft2-computations.html#FT_Matrix_Multiply">FT_Matrix_Multiply</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_just</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a></td><td><a href="ft2-system_interface.html#FT_Memory">FT_Memory</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_kern</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a></td><td><a href="ft2-system_interface.html#FT_MemoryRec">FT_MemoryRec</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_lcar</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Axis">FT_MM_Axis</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_MATH</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_CeilFix">FT_CeilFix</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Var">FT_MM_Var</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_MS</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Char">FT_Char</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_ERRORS_H">FT_MODULE_ERRORS_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_mort</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_CharMap">FT_CharMap</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_H">FT_MODULE_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_morx</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_CharMapRec">FT_CharMapRec</a></td><td><a href="ft2-base_interface.html#FT_Module">FT_Module</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OT</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CID_H">FT_CID_H</a></td><td><a href="ft2-module_management.html#FT_Module_Class">FT_Module_Class</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OTXXX</a></td></tr>
+<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Free">FT_ClassicKern_Free</a></td><td><a href="ft2-module_management.html#FT_Module_Constructor">FT_Module_Constructor</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_opbd</a></td></tr>
+<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Validate">FT_ClassicKern_Validate</a></td><td><a href="ft2-module_management.html#FT_Module_Destructor">FT_Module_Destructor</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_prop</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_CONFIG_H">FT_CONFIG_CONFIG_H</a></td><td><a href="ft2-module_management.html#FT_Module_Requester">FT_Module_Requester</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_trak</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_MODULES_H">FT_CONFIG_MODULES_H</a></td><td><a href="ft2-header_file_macros.html#FT_MULTIPLE_MASTERS_H">FT_MULTIPLE_MASTERS_H</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Axis">FT_Var_Axis</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_OPTIONS_H">FT_CONFIG_OPTIONS_H</a></td><td><a href="ft2-computations.html#FT_MulDiv">FT_MulDiv</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Named_Style">FT_Var_Named_Style</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_STANDARD_LIBRARY_H">FT_CONFIG_STANDARD_LIBRARY_H</a></td><td><a href="ft2-computations.html#FT_MulFix">FT_MulFix</a></td><td><a href="ft2-basic_types.html#FT_Vector">FT_Vector</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Cos">FT_Cos</a></td><td><a href="ft2-multiple_masters.html#FT_Multi_Master">FT_Multi_Master</a></td><td><a href="ft2-computations.html#FT_Vector_From_Polar">FT_Vector_From_Polar</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Data">FT_Data</a></td><td><a href="ft2-base_interface.html#FT_New_Face">FT_New_Face</a></td><td><a href="ft2-computations.html#FT_Vector_Length">FT_Vector_Length</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_DivFix">FT_DivFix</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FOND">FT_New_Face_From_FOND</a></td><td><a href="ft2-computations.html#FT_Vector_Polarize">FT_Vector_Polarize</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Done_Face">FT_Done_Face</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSRef">FT_New_Face_From_FSRef</a></td><td><a href="ft2-computations.html#FT_Vector_Rotate">FT_Vector_Rotate</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Done_FreeType">FT_Done_FreeType</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSSpec">FT_New_Face_From_FSSpec</a></td><td><a href="ft2-computations.html#FT_Vector_Transform">FT_Vector_Transform</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Done_Glyph">FT_Done_Glyph</a></td><td><a href="ft2-module_management.html#FT_New_Library">FT_New_Library</a></td><td><a href="ft2-computations.html#FT_Vector_Unit">FT_Vector_Unit</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Done_Library">FT_Done_Library</a></td><td><a href="ft2-base_interface.html#FT_New_Memory_Face">FT_New_Memory_Face</a></td><td><a href="ft2-header_file_macros.html#FT_WINFONTS_H">FT_WINFONTS_H</a></td></tr>
+<tr><td><a href="ft2-sizes_management.html#FT_Done_Size">FT_Done_Size</a></td><td><a href="ft2-sizes_management.html#FT_New_Size">FT_New_Size</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_Header">FT_WinFNT_Header</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Driver">FT_Driver</a></td><td><a href="ft2-basic_types.html#FT_Offset">FT_Offset</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_HeaderRec">FT_WinFNT_HeaderRec</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_ENC_TAG">FT_ENC_TAG</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_DRIVER</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1250</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_CUSTOM</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_MEMORY</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1251</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_EXPERT</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PARAMS</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1252</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_LATIN_1</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PATHNAME</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1253</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_STANDARD</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_STREAM</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1254</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_APPLE_ROMAN</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_XXX</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1255</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_BIG5</a></td><td><a href="ft2-header_file_macros.html#FT_OPENTYPE_VALIDATE_H">FT_OPENTYPE_VALIDATE_H</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1256</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_GB2312</a></td><td><a href="ft2-base_interface.html#FT_Open_Args">FT_Open_Args</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1257</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_JOHAB</a></td><td><a href="ft2-base_interface.html#FT_Open_Face">FT_Open_Face</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1258</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_BIG5</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Free">FT_OpenType_Free</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1361</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_GB2312</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Validate">FT_OpenType_Validate</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP874</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_JOHAB</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_LEFT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP932</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SJIS</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_RIGHT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP936</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SYMBOL</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_NONE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP949</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_WANSUNG</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_POSTSCRIPT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP950</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_NONE</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_TRUETYPE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_DEFAULT</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_OLD_LATIN_2</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_Orientation</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_MAC</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_SJIS</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_EVEN_ODD_FILL</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_OEM</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_UNICODE</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_FLAGS</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_SYMBOL</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_WANSUNG</a></td><td><a href="ft2-header_file_macros.html#FT_OUTLINE_H">FT_OUTLINE_H</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_Encoding</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_HIGH_PRECISION</a></td><td><a href="ft2-header_file_macros.html#FT_XFREE86_H">FT_XFREE86_H</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_ERRORS_H">FT_ERRORS_H</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache">FTC_CMapCache</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Error">FT_Error</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_INCLUDE_STUBS</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_Lookup">FTC_CMapCache_Lookup</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_F26Dot6">FT_F26Dot6</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_NONE</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_New">FTC_CMapCache_New</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_F2Dot14">FT_F2Dot14</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_OWNER</a></td><td><a href="ft2-cache_subsystem.html#FTC_Face_Requester">FTC_Face_Requester</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_CID_KEYED</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_REVERSE_FILL</a></td><td><a href="ft2-cache_subsystem.html#FTC_FaceID">FTC_FaceID</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_EXTERNAL_STREAM</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SINGLE_PASS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache">FTC_ImageCache</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FAST_GLYPHS</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SMART_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_Lookup">FTC_ImageCache_Lookup</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_SIZES</a></td><td><a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_LookupScaler">FTC_ImageCache_LookupScaler</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_WIDTH</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Check">FT_Outline_Check</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_New">FTC_ImageCache_New</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_GLYPH_NAMES</a></td><td><a href="ft2-outline_processing.html#FT_Outline_ConicToFunc">FT_Outline_ConicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageType">FTC_ImageType</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HINTER</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Copy">FT_Outline_Copy</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageTypeRec">FTC_ImageTypeRec</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HORIZONTAL</a></td><td><a href="ft2-outline_processing.html#FT_Outline_CubicToFunc">FT_Outline_CubicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager">FTC_Manager</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_KERNING</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Decompose">FT_Outline_Decompose</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Done">FTC_Manager_Done</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_MULTIPLE_MASTERS</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Done">FT_Outline_Done</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupFace">FTC_Manager_LookupFace</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SCALABLE</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Embolden">FT_Outline_Embolden</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupSize">FTC_Manager_LookupSize</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SFNT</a></td><td><a href="ft2-outline_processing.html#FT_Outline_EmboldenXY">FT_Outline_EmboldenXY</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_New">FTC_Manager_New</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_TRICKY</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Funcs">FT_Outline_Funcs</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_RemoveFaceID">FTC_Manager_RemoveFaceID</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_VERTICAL</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_BBox">FT_Outline_Get_BBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Reset">FTC_Manager_Reset</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_XXX</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Bitmap">FT_Outline_Get_Bitmap</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node">FTC_Node</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Face">FT_Face</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_CBox">FT_Outline_Get_CBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node_Unref">FTC_Node_Unref</a></td></tr>
+<tr><td><a href="ft2-version.html#FT_Face_CheckTrueTypePatents">FT_Face_CheckTrueTypePatents</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Orientation">FT_Outline_Get_Orientation</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBit">FTC_SBit</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharsOfVariant">FT_Face_GetCharsOfVariant</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetInsideBorder">FT_Outline_GetInsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache">FTC_SBitCache</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIndex">FT_Face_GetCharVariantIndex</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetOutsideBorder">FT_Outline_GetOutsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_Lookup">FTC_SBitCache_Lookup</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIsDefault">FT_Face_GetCharVariantIsDefault</a></td><td><a href="ft2-outline_processing.html#FT_Outline_LineToFunc">FT_Outline_LineToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_LookupScaler">FTC_SBitCache_LookupScaler</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantSelectors">FT_Face_GetVariantSelectors</a></td><td><a href="ft2-outline_processing.html#FT_Outline_MoveToFunc">FT_Outline_MoveToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_New">FTC_SBitCache_New</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantsOfChar">FT_Face_GetVariantsOfChar</a></td><td><a href="ft2-outline_processing.html#FT_Outline_New">FT_Outline_New</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitRec">FTC_SBitRec</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Face_Internal">FT_Face_Internal</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Render">FT_Outline_Render</a></td><td><a href="ft2-cache_subsystem.html#FTC_Scaler">FTC_Scaler</a></td></tr>
+<tr><td><a href="ft2-version.html#FT_Face_SetUnpatentedHinting">FT_Face_SetUnpatentedHinting</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Reverse">FT_Outline_Reverse</a></td><td><a href="ft2-cache_subsystem.html#FTC_ScalerRec">FTC_ScalerRec</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Transform">FT_Outline_Transform</a></td><td><a href="ft2-auto_hinter.html#fallback-script">fallback-script</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Fixed">FT_Fixed</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Translate">FT_Outline_Translate</a></td><td><a href="ft2-base_interface.html#ft_encoding_xxx">ft_encoding_xxx</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_FloorFix">FT_FloorFix</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyph">FT_OutlineGlyph</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_gridfit</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyphRec">FT_OutlineGlyphRec</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_pixels</a></td></tr>
+<tr><td><a href="ft2-system_interface.html#FT_Free_Func">FT_Free_Func</a></td><td><a href="ft2-sfnt_names.html#FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_subpixels</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_BITMAP_EMBEDDING_ONLY</a></td><td><a href="ft2-sfnt_names.html#FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_truncate</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_EDITABLE_EMBEDDING</a></td><td><a href="ft2-incremental.html#FT_PARAM_TAG_INCREMENTAL">FT_PARAM_TAG_INCREMENTAL</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_unscaled</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_INSTALLABLE_EMBEDDING</a></td><td><a href="ft2-truetype_tables.html#FT_PARAM_TAG_UNPATENTED_HINTING">FT_PARAM_TAG_UNPATENTED_HINTING</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_xxx</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_NO_SUBSETTING</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">FT_Palette_Mode</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_bitmap</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING</a></td><td><a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_composite</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING</a></td><td><a href="ft2-header_file_macros.html#FT_PFR_H">FT_PFR_H</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_none</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_XXX</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_outline</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_FWord">FT_FWord</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY2</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_plotter</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRAY</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY4</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_xxx</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRIDFIT</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD</a></td><td><a href="ft2-base_interface.html#ft_kerning_default">ft_kerning_default</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GASP_H">FT_GASP_H</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD_V</a></td><td><a href="ft2-base_interface.html#ft_kerning_unfitted">ft_kerning_unfitted</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_NO_TABLE</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_MONO</a></td><td><a href="ft2-base_interface.html#ft_kerning_unscaled">ft_kerning_unscaled</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_GRIDFIT</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_NONE</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_driver</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_SMOOTHING</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_Pixel_Mode</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_memory</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_XXX</a></td><td><a href="ft2-basic_types.html#FT_Pointer">FT_Pointer</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_params</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Generic">FT_Generic</a></td><td><a href="ft2-basic_types.html#FT_Pos">FT_Pos</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_pathname</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Generic_Finalizer">FT_Generic_Finalizer</a></td><td><a href="ft2-auto_hinter.html#FT_Prop_GlyphToScriptMap">FT_Prop_GlyphToScriptMap</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_stream</a></td></tr>
+<tr><td><a href="ft2-quick_advance.html#FT_Get_Advance">FT_Get_Advance</a></td><td><a href="ft2-auto_hinter.html#FT_Prop_IncreaseXHeight">FT_Prop_IncreaseXHeight</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_even_odd_fill</a></td></tr>
+<tr><td><a href="ft2-quick_advance.html#FT_Get_Advances">FT_Get_Advances</a></td><td><a href="ft2-module_management.html#FT_Property_Get">FT_Property_Get</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_flags</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Charset_ID">FT_Get_BDF_Charset_ID</a></td><td><a href="ft2-module_management.html#FT_Property_Set">FT_Property_Set</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_high_precision</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Property">FT_Get_BDF_Property</a></td><td><a href="ft2-bdf_fonts.html#FT_PropertyType">FT_PropertyType</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_ignore_dropouts</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Char_Index">FT_Get_Char_Index</a></td><td><a href="ft2-basic_types.html#FT_PtrDist">FT_PtrDist</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_none</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Charmap_Index">FT_Get_Charmap_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_AA</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_owner</a></td></tr>
+<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_From_Glyph_Index">FT_Get_CID_From_Glyph_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_CLIP</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_reverse_fill</a></td></tr>
+<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Is_Internally_CID_Keyed">FT_Get_CID_Is_Internally_CID_Keyed</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DEFAULT</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_single_pass</a></td></tr>
+<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Registry_Ordering_Supplement">FT_Get_CID_Registry_Ordering_Supplement</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DIRECT</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgb</a></td></tr>
+<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Format">FT_Get_CMap_Format</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_XXX</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgba</a></td></tr>
+<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Language_ID">FT_Get_CMap_Language_ID</a></td><td><a href="ft2-raster.html#FT_Raster">FT_Raster</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_grays</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_First_Char">FT_Get_First_Char</a></td><td><a href="ft2-raster.html#FT_Raster_BitSet_Func">FT_Raster_BitSet_Func</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_mono</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_FSType_Flags">FT_Get_FSType_Flags</a></td><td><a href="ft2-raster.html#FT_Raster_BitTest_Func">FT_Raster_BitTest_Func</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_none</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_Get_Gasp">FT_Get_Gasp</a></td><td><a href="ft2-raster.html#FT_Raster_DoneFunc">FT_Raster_DoneFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal2</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Get_Glyph">FT_Get_Glyph</a></td><td><a href="ft2-raster.html#FT_Raster_Funcs">FT_Raster_Funcs</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal4</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Glyph_Name">FT_Get_Glyph_Name</a></td><td><a href="ft2-raster.html#FT_Raster_NewFunc">FT_Raster_NewFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_xxx</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Kerning">FT_Get_Kerning</a></td><td><a href="ft2-raster.html#FT_Raster_Params">FT_Raster_Params</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_mono</a></td></tr>
+<tr><td><a href="ft2-multiple_masters.html#FT_Get_MM_Var">FT_Get_MM_Var</a></td><td><a href="ft2-raster.html#FT_Raster_RenderFunc">FT_Raster_RenderFunc</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_normal</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Get_Module">FT_Get_Module</a></td><td><a href="ft2-raster.html#FT_Raster_ResetFunc">FT_Raster_ResetFunc</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_xxx</a></td></tr>
+<tr><td><a href="ft2-multiple_masters.html#FT_Get_Multi_Master">FT_Get_Multi_Master</a></td><td><a href="ft2-raster.html#FT_Raster_SetModeFunc">FT_Raster_SetModeFunc</a></td><td><a href="ft2-auto_hinter.html#glyph-to-script-map">glyph-to-script-map</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Name_Index">FT_Get_Name_Index</a></td><td><a href="ft2-header_file_macros.html#FT_RENDER_H">FT_RENDER_H</a></td><td><a href="ft2-auto_hinter.html#increase-x-height">increase-x-height</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Next_Char">FT_Get_Next_Char</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD</a></td><td><a href="ft2-type1_tables.html#PS_Dict_Keys">PS_Dict_Keys</a></td></tr>
+<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Advance">FT_Get_PFR_Advance</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD_V</a></td><td><a href="ft2-type1_tables.html#PS_FontInfo">PS_FontInfo</a></td></tr>
+<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Kerning">FT_Get_PFR_Kerning</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LIGHT</a></td><td><a href="ft2-type1_tables.html#PS_FontInfoRec">PS_FontInfoRec</a></td></tr>
+<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Metrics">FT_Get_PFR_Metrics</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_MONO</a></td><td><a href="ft2-type1_tables.html#PS_Private">PS_Private</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Postscript_Name">FT_Get_Postscript_Name</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_NORMAL</a></td><td><a href="ft2-type1_tables.html#PS_PrivateRec">PS_PrivateRec</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Info">FT_Get_PS_Font_Info</a></td><td><a href="ft2-system_interface.html#FT_Realloc_Func">FT_Realloc_Func</a></td><td><a href="ft2-type1_tables.html#T1_Blend_Flags">T1_Blend_Flags</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Private">FT_Get_PS_Font_Private</a></td><td><a href="ft2-base_interface.html#FT_Reference_Face">FT_Reference_Face</a></td><td><a href="ft2-type1_tables.html#T1_EncodingType">T1_EncodingType</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Value">FT_Get_PS_Font_Value</a></td><td><a href="ft2-module_management.html#FT_Reference_Library">FT_Reference_Library</a></td><td><a href="ft2-type1_tables.html#T1_FontInfo">T1_FontInfo</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Get_Renderer">FT_Get_Renderer</a></td><td><a href="ft2-module_management.html#FT_Remove_Module">FT_Remove_Module</a></td><td><a href="ft2-type1_tables.html#T1_Private">T1_Private</a></td></tr>
+<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name">FT_Get_Sfnt_Name</a></td><td><a href="ft2-base_interface.html#FT_Render_Glyph">FT_Render_Glyph</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_CUSTOM</a></td></tr>
+<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name_Count">FT_Get_Sfnt_Name_Count</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_Render_Mode</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_EXPERT</a></td></tr>
+<tr><td><a href="ft2-truetype_tables.html#FT_Get_Sfnt_Table">FT_Get_Sfnt_Table</a></td><td><a href="ft2-base_interface.html#FT_Renderer">FT_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_LATIN_1</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_SubGlyph_Info">FT_Get_SubGlyph_Info</a></td><td><a href="ft2-module_management.html#FT_Renderer_Class">FT_Renderer_Class</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_STANDARD</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Track_Kerning">FT_Get_Track_Kerning</a></td><td><a href="ft2-base_interface.html#FT_Request_Size">FT_Request_Size</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-truetype_engine.html#FT_Get_TrueType_Engine_Type">FT_Get_TrueType_Engine_Type</a></td><td><a href="ft2-computations.html#FT_RoundFix">FT_RoundFix</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_DEFAULT</a></td></tr>
+<tr><td><a href="ft2-winfnt_fonts.html#FT_Get_WinFNT_Header">FT_Get_WinFNT_Header</a></td><td><a href="ft2-base_interface.html#FT_Select_Charmap">FT_Select_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_ISO_10646</a></td></tr>
+<tr><td><a href="ft2-font_formats.html#FT_Get_X11_Font_Format">FT_Get_X11_Font_Format</a></td><td><a href="ft2-base_interface.html#FT_Select_Size">FT_Select_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_1_1</a></td></tr>
+<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_ATS_Name">FT_GetFile_From_Mac_ATS_Name</a></td><td><a href="ft2-base_interface.html#FT_Set_Char_Size">FT_Set_Char_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_2_0</a></td></tr>
+<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_Name">FT_GetFile_From_Mac_Name</a></td><td><a href="ft2-base_interface.html#FT_Set_Charmap">FT_Set_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_32</a></td></tr>
+<tr><td><a href="ft2-mac_specific.html#FT_GetFilePath_From_Mac_ATS_Name">FT_GetFilePath_From_Mac_ATS_Name</a></td><td><a href="ft2-module_management.html#FT_Set_Debug_Hook">FT_Set_Debug_Hook</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_VARIANT_SELECTOR</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_GRIDFIT</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Blend_Coordinates">FT_Set_MM_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_PIXELS</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Design_Coordinates">FT_Set_MM_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_Header">TT_Header</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_SUBPIXELS</a></td><td><a href="ft2-base_interface.html#FT_Set_Pixel_Sizes">FT_Set_Pixel_Sizes</a></td><td><a href="ft2-truetype_tables.html#TT_HoriHeader">TT_HoriHeader</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_TRUNCATE</a></td><td><a href="ft2-module_management.html#FT_Set_Renderer">FT_Set_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_10646</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_UNSCALED</a></td><td><a href="ft2-base_interface.html#FT_Set_Transform">FT_Set_Transform</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_7BIT_ASCII</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_BITMAP</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Blend_Coordinates">FT_Set_Var_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_8859_1</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_COMPOSITE</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Design_Coordinates">FT_Set_Var_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_NONE</a></td><td><a href="ft2-header_file_macros.html#FT_SFNT_NAMES_H">FT_SFNT_NAMES_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARABIC</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_OUTLINE</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Table_Info">FT_Sfnt_Table_Info</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARMENIAN</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_PLOTTER</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Tag">FT_Sfnt_Tag</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BENGALI</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GLYPH_H">FT_GLYPH_H</a></td><td><a href="ft2-sfnt_names.html#FT_SfntName">FT_SfntName</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BURMESE</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph">FT_Glyph</a></td><td><a href="ft2-basic_types.html#FT_Short">FT_Short</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_DEVANAGARI</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_Glyph_BBox_Mode</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_BBOX</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEEZ</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Copy">FT_Glyph_Copy</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_CELL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEORGIAN</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_Glyph_Format</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_NOMINAL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GREEK</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Get_CBox">FT_Glyph_Get_CBox</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_REAL_DIM</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GUJARATI</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Glyph_Metrics">FT_Glyph_Metrics</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_SCALES</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GURMUKHI</a></td></tr>
+<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_Stroke">FT_Glyph_Stroke</a></td><td><a href="ft2-header_file_macros.html#FT_SIZES_H">FT_SIZES_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_HEBREW</a></td></tr>
+<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_StrokeBorder">FT_Glyph_StrokeBorder</a></td><td><a href="ft2-computations.html#FT_Sin">FT_Sin</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_JAPANESE</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_To_Bitmap">FT_Glyph_To_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_Size">FT_Size</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KANNADA</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Transform">FT_Glyph_Transform</a></td><td><a href="ft2-base_interface.html#FT_Size_Internal">FT_Size_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KHMER</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_GlyphRec">FT_GlyphRec</a></td><td><a href="ft2-base_interface.html#FT_Size_Metrics">FT_Size_Metrics</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KOREAN</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_GlyphSlot">FT_GlyphSlot</a></td><td><a href="ft2-base_interface.html#FT_Size_Request">FT_Size_Request</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_LAOTIAN</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_GlyphSlot_Own_Bitmap">FT_GlyphSlot_Own_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_Size_Request_Type</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALAYALAM</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_GlyphSlotRec">FT_GlyphSlotRec</a></td><td><a href="ft2-base_interface.html#FT_Size_RequestRec">FT_Size_RequestRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALDIVIAN</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GX_VALIDATE_H">FT_GX_VALIDATE_H</a></td><td><a href="ft2-base_interface.html#FT_SizeRec">FT_SizeRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MONGOLIAN</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GZIP_H">FT_GZIP_H</a></td><td><a href="ft2-base_interface.html#FT_Slot_Internal">FT_Slot_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ORIYA</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_FAST_GLYPHS">FT_HAS_FAST_GLYPHS</a></td><td><a href="ft2-raster.html#FT_Span">FT_Span</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ROMAN</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_FIXED_SIZES">FT_HAS_FIXED_SIZES</a></td><td><a href="ft2-raster.html#FT_SpanFunc">FT_SpanFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RSYMBOL</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_GLYPH_NAMES">FT_HAS_GLYPH_NAMES</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_LEFT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RUSSIAN</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_HORIZONTAL">FT_HAS_HORIZONTAL</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_RIGHT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SIMPLIFIED_CHINESE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_KERNING">FT_HAS_KERNING</a></td><td><a href="ft2-header_file_macros.html#FT_STROKER_H">FT_STROKER_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINDHI</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_MULTIPLE_MASTERS">FT_HAS_MULTIPLE_MASTERS</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_BUTT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINHALESE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_VERTICAL">FT_HAS_VERTICAL</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SLAVIC</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#FT_Has_PS_Glyph_Names">FT_Has_PS_Glyph_Names</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_SQUARE</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TAMIL</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_IMAGE_H">FT_IMAGE_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_BEVEL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TELUGU</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_IMAGE_TAG">FT_IMAGE_TAG</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_THAI</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_INCREMENTAL_H">FT_INCREMENTAL_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER_FIXED</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TIBETAN</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental">FT_Incremental</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER_VARIABLE</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TRADITIONAL_CHINESE</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_FreeGlyphDataFunc">FT_Incremental_FreeGlyphDataFunc</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_UNINTERP</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_FuncsRec">FT_Incremental_FuncsRec</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_BOLD</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_VIETNAMESE</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphDataFunc">FT_Incremental_GetGlyphDataFunc</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_ITALIC</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphMetricsFunc">FT_Incremental_GetGlyphMetricsFunc</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_XXX</a></td><td><a href="ft2-truetype_tables.html#TT_MaxProfile">TT_MaxProfile</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_Interface">FT_Incremental_Interface</a></td><td><a href="ft2-system_interface.html#FT_Stream">FT_Stream</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_BIG_5</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_InterfaceRec">FT_Incremental_InterfaceRec</a></td><td><a href="ft2-system_interface.html#FT_Stream_CloseFunc">FT_Stream_CloseFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_GB2312</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_Metrics">FT_Incremental_Metrics</a></td><td><a href="ft2-system_interface.html#FT_Stream_IoFunc">FT_Stream_IoFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_JOHAB</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_MetricsRec">FT_Incremental_MetricsRec</a></td><td><a href="ft2-bzip2.html#FT_Stream_OpenBzip2">FT_Stream_OpenBzip2</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SJIS</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Init_FreeType">FT_Init_FreeType</a></td><td><a href="ft2-gzip.html#FT_Stream_OpenGzip">FT_Stream_OpenGzip</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SYMBOL_CS</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Int">FT_Int</a></td><td><a href="ft2-lzw.html#FT_Stream_OpenLZW">FT_Stream_OpenLZW</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UCS_4</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Int16">FT_Int16</a></td><td><a href="ft2-system_interface.html#FT_StreamDesc">FT_StreamDesc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UNICODE_CS</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Int32">FT_Int32</a></td><td><a href="ft2-system_interface.html#FT_StreamRec">FT_StreamRec</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_WANSUNG</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_CID_KEYED">FT_IS_CID_KEYED</a></td><td><a href="ft2-basic_types.html#FT_String">FT_String</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_FIXED_WIDTH">FT_IS_FIXED_WIDTH</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker">FT_Stroker</a></td><td><a href="ft2-truetype_tables.html#TT_OS2">TT_OS2</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_SCALABLE">FT_IS_SCALABLE</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_BeginSubPath">FT_Stroker_BeginSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_PCLT">TT_PCLT</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_SFNT">FT_IS_SFNT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ConicTo">FT_Stroker_ConicTo</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ADOBE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_TRICKY">FT_IS_TRICKY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_CubicTo">FT_Stroker_CubicTo</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_APPLE_UNICODE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Done">FT_Stroker_Done</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_CUSTOM</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNFITTED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_EndSubPath">FT_Stroker_EndSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ISO</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNSCALED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Export">FT_Stroker_Export</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MACINTOSH</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_Kerning_Mode</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ExportBorder">FT_Stroker_ExportBorder</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MICROSOFT</a></td></tr>
+<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetBorderCounts">FT_Stroker_GetBorderCounts</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_XXX</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_LCD_FILTER_H">FT_LCD_FILTER_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetCounts">FT_Stroker_GetCounts</a></td><td><a href="ft2-truetype_tables.html#TT_Postscript">TT_Postscript</a></td></tr>
+<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LEGACY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_Stroker_LineCap</a></td><td><a href="ft2-truetype_tables.html#TT_VertHeader">TT_VertHeader</a></td></tr>
</table>
<hr>
<table><tr><td width="100%"></td>
<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><font size=-2>generated on Tue Nov 15 07:53:40 2011</font></center></body>
+<center><font size=-2>generated on Thu Dec 20 08:35:15 2012</font></center></body>
</html>
diff --git a/3party/freetype/docs/reference/ft2-lcd_filtering.html b/3party/freetype/docs/reference/ft2-lcd_filtering.html
index 237c7aba24..9965c432d7 100644
--- a/3party/freetype/docs/reference/ft2-lcd_filtering.html
+++ b/3party/freetype/docs/reference/ft2-lcd_filtering.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
LCD Filtering
diff --git a/3party/freetype/docs/reference/ft2-list_processing.html b/3party/freetype/docs/reference/ft2-list_processing.html
index 7ecb4bb6be..cbb43eb7e9 100644
--- a/3party/freetype/docs/reference/ft2-list_processing.html
+++ b/3party/freetype/docs/reference/ft2-list_processing.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
List Processing
diff --git a/3party/freetype/docs/reference/ft2-lzw.html b/3party/freetype/docs/reference/ft2-lzw.html
index 661f8cd68e..0fdd4dcf56 100644
--- a/3party/freetype/docs/reference/ft2-lzw.html
+++ b/3party/freetype/docs/reference/ft2-lzw.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
LZW Streams
diff --git a/3party/freetype/docs/reference/ft2-mac_specific.html b/3party/freetype/docs/reference/ft2-mac_specific.html
index 07eb928ded..ca837e8dd1 100644
--- a/3party/freetype/docs/reference/ft2-mac_specific.html
+++ b/3party/freetype/docs/reference/ft2-mac_specific.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Mac Specific Interface
diff --git a/3party/freetype/docs/reference/ft2-module_management.html b/3party/freetype/docs/reference/ft2-module_management.html
index 5507899882..227bca3c8e 100644
--- a/3party/freetype/docs/reference/ft2-module_management.html
+++ b/3party/freetype/docs/reference/ft2-module_management.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,22 +35,45 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Module Management
</h1></center>
<h2>Synopsis</h2>
<table align=center cellspacing=5 cellpadding=0 border=0>
-<tr><td></td><td><a href="#FT_Module_Constructor">FT_Module_Constructor</a></td><td></td><td><a href="#FT_Get_Module">FT_Get_Module</a></td><td></td><td><a href="#FT_Set_Debug_Hook">FT_Set_Debug_Hook</a></td></tr>
-<tr><td></td><td><a href="#FT_Module_Destructor">FT_Module_Destructor</a></td><td></td><td><a href="#FT_Remove_Module">FT_Remove_Module</a></td><td></td><td><a href="#FT_Add_Default_Modules">FT_Add_Default_Modules</a></td></tr>
-<tr><td></td><td><a href="#FT_Module_Requester">FT_Module_Requester</a></td><td></td><td><a href="#FT_Reference_Library">FT_Reference_Library</a></td><td></td><td><a href="#FT_Renderer_Class">FT_Renderer_Class</a></td></tr>
-<tr><td></td><td><a href="#FT_Module_Class">FT_Module_Class</a></td><td></td><td><a href="#FT_New_Library">FT_New_Library</a></td><td></td><td><a href="#FT_Get_Renderer">FT_Get_Renderer</a></td></tr>
-<tr><td></td><td><a href="#FT_Add_Module">FT_Add_Module</a></td><td></td><td><a href="#FT_Done_Library">FT_Done_Library</a></td><td></td><td><a href="#FT_Set_Renderer">FT_Set_Renderer</a></td></tr>
+<tr><td></td><td><a href="#FT_Module_Constructor">FT_Module_Constructor</a></td><td></td><td><a href="#FT_Remove_Module">FT_Remove_Module</a></td><td></td><td><a href="#FT_Set_Debug_Hook">FT_Set_Debug_Hook</a></td></tr>
+<tr><td></td><td><a href="#FT_Module_Destructor">FT_Module_Destructor</a></td><td></td><td><a href="#FT_Property_Set">FT_Property_Set</a></td><td></td><td><a href="#FT_Add_Default_Modules">FT_Add_Default_Modules</a></td></tr>
+<tr><td></td><td><a href="#FT_Module_Requester">FT_Module_Requester</a></td><td></td><td><a href="#FT_Property_Get">FT_Property_Get</a></td><td></td><td><a href="#FT_Renderer_Class">FT_Renderer_Class</a></td></tr>
+<tr><td></td><td><a href="#FT_Module_Class">FT_Module_Class</a></td><td></td><td><a href="#FT_Reference_Library">FT_Reference_Library</a></td><td></td><td><a href="#FT_Get_Renderer">FT_Get_Renderer</a></td></tr>
+<tr><td></td><td><a href="#FT_Add_Module">FT_Add_Module</a></td><td></td><td><a href="#FT_New_Library">FT_New_Library</a></td><td></td><td><a href="#FT_Set_Renderer">FT_Set_Renderer</a></td></tr>
+<tr><td></td><td><a href="#FT_Get_Module">FT_Get_Module</a></td><td></td><td><a href="#FT_Done_Library">FT_Done_Library</a></td><td></td><td></td></tr>
</table><br><br>
<table align=center width="87%"><tr><td>
-<p>The definitions below are used to manage modules within FreeType. Modules can be added, upgraded, and removed at runtime.</p>
+<p>The definitions below are used to manage modules within FreeType. Modules can be added, upgraded, and removed at runtime. Additionally, some module properties can be controlled also.</p>
+<p>Here is a list of possible values of the &lsquo;module_name&rsquo; field in the <a href="ft2-module_management.html#FT_Module_Class">FT_Module_Class</a> structure.</p>
+<pre class="colored">
+ autofitter
+ bdf
+ cff
+ gxvalid
+ otvalid
+ pcf
+ pfr
+ psaux
+ pshinter
+ psnames
+ raster1, raster5
+ sfnt
+ smooth, smooth-lcd, smooth-lcdv
+ truetype
+ type1
+ type42
+ t1cid
+ winfonts
+</pre>
+<p>Note that the FreeType Cache sub-system is not a FreeType module.</p>
</td></tr></table><br>
<table align=center width="75%"><tr><td>
<h4><a name="FT_Module_Constructor">FT_Module_Constructor</a></h4>
@@ -127,7 +150,7 @@ Defined in FT_MODULE_H (freetype/ftmodapi.h).
<p></p>
<table cellpadding=3 border=0>
<tr valign=top><td><b>module</b></td><td>
-<p>The module to finalize.</p>
+<p>The module to be searched.</p>
</td></tr>
<tr valign=top><td><b>name</b></td><td>
<p>The name of the interface in the module.</p>
@@ -327,6 +350,134 @@ Defined in FT_MODULE_H (freetype/ftmodapi.h).
<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
<table align=center width="75%"><tr><td>
+<h4><a name="FT_Property_Set">FT_Property_Set</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_MODULE_H (freetype/ftmodapi.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <a href="ft2-basic_types.html#FT_Error">FT_Error</a>
+ <b>FT_Property_Set</b>( <a href="ft2-base_interface.html#FT_Library">FT_Library</a> library,
+ <span class="keyword">const</span> <a href="ft2-basic_types.html#FT_String">FT_String</a>* module_name,
+ <span class="keyword">const</span> <a href="ft2-basic_types.html#FT_String">FT_String</a>* property_name,
+ <span class="keyword">const</span> <span class="keyword">void</span>* value );
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>Set a property for a given module.</p>
+</td></tr></table><br>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
+<p></p>
+<table cellpadding=3 border=0>
+<tr valign=top><td><b>library</b></td><td>
+<p>A handle to the library the module is part of.</p>
+</td></tr>
+<tr valign=top><td><b>module_name</b></td><td>
+<p>The module name.</p>
+</td></tr>
+<tr valign=top><td><b>property_name</b></td><td>
+<p>The property name. Properties are described in the &lsquo;Synopsis&rsquo; subsection of the module's documentation.</p>
+<p>Note that only a few modules have properties.</p>
+</td></tr>
+<tr valign=top><td><b>value</b></td><td>
+<p>A generic pointer to a variable or structure which gives the new value of the property. The exact definition of &lsquo;value&rsquo; is dependent on the property; see the &lsquo;Synopsis&rsquo; subsection of the module's documentation.</p>
+</td></tr>
+</table>
+</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>return</b></em></td></tr><tr><td>
+<p>FreeType error code. 0&nbsp;means success.</p>
+</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>If &lsquo;module_name&rsquo; isn't a valid module name, or &lsquo;property_name&rsquo; doesn't specify a valid property, or if &lsquo;value&rsquo; doesn't represent a valid value for the given property, an error is returned.</p>
+<p>The following example sets property &lsquo;bar&rsquo; (a simple integer) in module &lsquo;foo&rsquo; to value&nbsp;1.</p>
+<pre class="colored">
+ FT_UInt bar;
+
+
+ bar = 1;
+ FT_Property_Set( library, "foo", "bar", &amp;bar );
+</pre>
+<p>It is not possible to set properties of the FreeType Cache sub-system with FT_Property_Set; use ?FTC_Property_Set? instead.</p>
+</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>since</b></em></td></tr><tr><td>
+<p>2.4.11</p>
+</td></tr></table>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
+<h4><a name="FT_Property_Get">FT_Property_Get</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_MODULE_H (freetype/ftmodapi.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <a href="ft2-basic_types.html#FT_Error">FT_Error</a>
+ <b>FT_Property_Get</b>( <a href="ft2-base_interface.html#FT_Library">FT_Library</a> library,
+ <span class="keyword">const</span> <a href="ft2-basic_types.html#FT_String">FT_String</a>* module_name,
+ <span class="keyword">const</span> <a href="ft2-basic_types.html#FT_String">FT_String</a>* property_name,
+ <span class="keyword">void</span>* value );
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>Get a module's property value.</p>
+</td></tr></table><br>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
+<p></p>
+<table cellpadding=3 border=0>
+<tr valign=top><td><b>library</b></td><td>
+<p>A handle to the library the module is part of.</p>
+</td></tr>
+<tr valign=top><td><b>module_name</b></td><td>
+<p>The module name.</p>
+</td></tr>
+<tr valign=top><td><b>property_name</b></td><td>
+<p>The property name. Properties are described in the &lsquo;Synopsis&rsquo; subsection of the module's documentation.</p>
+</td></tr>
+</table>
+</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>inout</b></em></td></tr><tr><td>
+<p></p>
+<table cellpadding=3 border=0>
+<tr valign=top><td><b>value</b></td><td>
+<p>A generic pointer to a variable or structure which gives the value of the property. The exact definition of &lsquo;value&rsquo; is dependent on the property; see the &lsquo;Synopsis&rsquo; subsection of the module's documentation.</p>
+</td></tr>
+</table>
+</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>return</b></em></td></tr><tr><td>
+<p>FreeType error code. 0&nbsp;means success.</p>
+</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>If &lsquo;module_name&rsquo; isn't a valid module name, or &lsquo;property_name&rsquo; doesn't specify a valid property, or if &lsquo;value&rsquo; doesn't represent a valid value for the given property, an error is returned.</p>
+<p>The following example gets property &lsquo;baz&rsquo; (a range) in module &lsquo;foo&rsquo;.</p>
+<pre class="colored">
+ typedef range_
+ {
+ FT_Int32 min;
+ FT_Int32 max;
+
+ } range;
+
+ range baz;
+
+
+ FT_Property_Get( library, "foo", "baz", &amp;baz );
+</pre>
+<p>It is not possible to retrieve properties of the FreeType Cache sub-system with FT_Property_Get; use ?FTC_Property_Get? instead.</p>
+</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>since</b></em></td></tr><tr><td>
+<p>2.4.11</p>
+</td></tr></table>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
<h4><a name="FT_Reference_Library">FT_Reference_Library</a></h4>
<table align=center width="87%"><tr><td>
Defined in FT_MODULE_H (freetype/ftmodapi.h).
diff --git a/3party/freetype/docs/reference/ft2-multiple_masters.html b/3party/freetype/docs/reference/ft2-multiple_masters.html
index ab44553b17..bdb592bc07 100644
--- a/3party/freetype/docs/reference/ft2-multiple_masters.html
+++ b/3party/freetype/docs/reference/ft2-multiple_masters.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Multiple Masters
diff --git a/3party/freetype/docs/reference/ft2-ot_validation.html b/3party/freetype/docs/reference/ft2-ot_validation.html
index 394896bcbc..7f61dd2642 100644
--- a/3party/freetype/docs/reference/ft2-ot_validation.html
+++ b/3party/freetype/docs/reference/ft2-ot_validation.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
OpenType Validation
diff --git a/3party/freetype/docs/reference/ft2-outline_processing.html b/3party/freetype/docs/reference/ft2-outline_processing.html
index 99f854db57..54d0c16802 100644
--- a/3party/freetype/docs/reference/ft2-outline_processing.html
+++ b/3party/freetype/docs/reference/ft2-outline_processing.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,25 +35,25 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Outline Processing
</h1></center>
<h2>Synopsis</h2>
<table align=center cellspacing=5 cellpadding=0 border=0>
-<tr><td></td><td><a href="#FT_Outline">FT_Outline</a></td><td></td><td><a href="#FT_Outline_MoveToFunc">FT_Outline_MoveToFunc</a></td></tr>
-<tr><td></td><td><a href="#FT_OUTLINE_FLAGS">FT_OUTLINE_FLAGS</a></td><td></td><td><a href="#FT_Outline_LineToFunc">FT_Outline_LineToFunc</a></td></tr>
-<tr><td></td><td><a href="#FT_Outline_New">FT_Outline_New</a></td><td></td><td><a href="#FT_Outline_ConicToFunc">FT_Outline_ConicToFunc</a></td></tr>
-<tr><td></td><td><a href="#FT_Outline_Done">FT_Outline_Done</a></td><td></td><td><a href="#FT_Outline_CubicToFunc">FT_Outline_CubicToFunc</a></td></tr>
-<tr><td></td><td><a href="#FT_Outline_Copy">FT_Outline_Copy</a></td><td></td><td><a href="#FT_Outline_Funcs">FT_Outline_Funcs</a></td></tr>
-<tr><td></td><td><a href="#FT_Outline_Translate">FT_Outline_Translate</a></td><td></td><td><a href="#FT_Outline_Decompose">FT_Outline_Decompose</a></td></tr>
-<tr><td></td><td><a href="#FT_Outline_Transform">FT_Outline_Transform</a></td><td></td><td><a href="#FT_Outline_Get_CBox">FT_Outline_Get_CBox</a></td></tr>
-<tr><td></td><td><a href="#FT_Outline_Embolden">FT_Outline_Embolden</a></td><td></td><td><a href="#FT_Outline_Get_Bitmap">FT_Outline_Get_Bitmap</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline">FT_Outline</a></td><td></td><td><a href="#ft_outline_flags">ft_outline_flags</a></td></tr>
+<tr><td></td><td><a href="#FT_OUTLINE_FLAGS">FT_OUTLINE_FLAGS</a></td><td></td><td><a href="#FT_Outline_MoveToFunc">FT_Outline_MoveToFunc</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline_New">FT_Outline_New</a></td><td></td><td><a href="#FT_Outline_LineToFunc">FT_Outline_LineToFunc</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline_Done">FT_Outline_Done</a></td><td></td><td><a href="#FT_Outline_ConicToFunc">FT_Outline_ConicToFunc</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline_Copy">FT_Outline_Copy</a></td><td></td><td><a href="#FT_Outline_CubicToFunc">FT_Outline_CubicToFunc</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline_Translate">FT_Outline_Translate</a></td><td></td><td><a href="#FT_Outline_Funcs">FT_Outline_Funcs</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline_Transform">FT_Outline_Transform</a></td><td></td><td><a href="#FT_Outline_Decompose">FT_Outline_Decompose</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline_Embolden">FT_Outline_Embolden</a></td><td></td><td><a href="#FT_Outline_Get_CBox">FT_Outline_Get_CBox</a></td></tr>
+<tr><td></td><td><a href="#FT_Outline_EmboldenXY">FT_Outline_EmboldenXY</a></td><td></td><td><a href="#FT_Outline_Get_Bitmap">FT_Outline_Get_Bitmap</a></td></tr>
<tr><td></td><td><a href="#FT_Outline_Reverse">FT_Outline_Reverse</a></td><td></td><td><a href="#FT_Outline_Render">FT_Outline_Render</a></td></tr>
<tr><td></td><td><a href="#FT_Outline_Check">FT_Outline_Check</a></td><td></td><td><a href="#FT_Orientation">FT_Orientation</a></td></tr>
<tr><td></td><td><a href="#FT_Outline_Get_BBox">FT_Outline_Get_BBox</a></td><td></td><td><a href="#FT_Outline_Get_Orientation">FT_Outline_Get_Orientation</a></td></tr>
-<tr><td></td><td><a href="#ft_outline_flags">ft_outline_flags</a></td><td></td><td></td></tr>
</table><br><br>
<table align=center width="87%"><tr><td>
@@ -226,10 +226,10 @@ Defined in FT_OUTLINE_H (freetype/ftoutln.h).
<p>A handle to the library object from where the outline is allocated. Note however that the new outline will <b>not</b> necessarily be <b>freed</b>, when destroying the library, by <a href="ft2-base_interface.html#FT_Done_FreeType">FT_Done_FreeType</a>.</p>
</td></tr>
<tr valign=top><td><b>numPoints</b></td><td>
-<p>The maximal number of points within the outline.</p>
+<p>The maximum number of points within the outline.</p>
</td></tr>
<tr valign=top><td><b>numContours</b></td><td>
-<p>The maximal number of contours within the outline.</p>
+<p>The maximum number of contours within the outline.</p>
</td></tr>
</table>
</td></tr></table>
@@ -470,6 +470,28 @@ Defined in FT_OUTLINE_H (freetype/ftoutln.h).
<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
<table align=center width="75%"><tr><td>
+<h4><a name="FT_Outline_EmboldenXY">FT_Outline_EmboldenXY</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_OUTLINE_H (freetype/ftoutln.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ FT_EXPORT( <a href="ft2-basic_types.html#FT_Error">FT_Error</a> )
+ <b>FT_Outline_EmboldenXY</b>( <a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a>* outline,
+ <a href="ft2-basic_types.html#FT_Pos">FT_Pos</a> xstrength,
+ <a href="ft2-basic_types.html#FT_Pos">FT_Pos</a> ystrength );
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>Embolden an outline. The new outline will be &lsquo;xstrength&rsquo; pixels wider and &lsquo;ystrength&rsquo; pixels higher. Otherwise, it is similar to <a href="ft2-outline_processing.html#FT_Outline_Embolden">FT_Outline_Embolden</a>, which uses the same strength in both directions.</p>
+</td></tr></table><br>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
<h4><a name="FT_Outline_Reverse">FT_Outline_Reverse</a></h4>
<table align=center width="87%"><tr><td>
Defined in FT_OUTLINE_H (freetype/ftoutln.h).
diff --git a/3party/freetype/docs/reference/ft2-pfr_fonts.html b/3party/freetype/docs/reference/ft2-pfr_fonts.html
index d6ab64d1ea..4c18415262 100644
--- a/3party/freetype/docs/reference/ft2-pfr_fonts.html
+++ b/3party/freetype/docs/reference/ft2-pfr_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
PFR Fonts
diff --git a/3party/freetype/docs/reference/ft2-quick_advance.html b/3party/freetype/docs/reference/ft2-quick_advance.html
index f6a693ee77..36677e3840 100644
--- a/3party/freetype/docs/reference/ft2-quick_advance.html
+++ b/3party/freetype/docs/reference/ft2-quick_advance.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Quick retrieval of advance values
diff --git a/3party/freetype/docs/reference/ft2-raster.html b/3party/freetype/docs/reference/ft2-raster.html
index 6fee7b073b..06b6547327 100644
--- a/3party/freetype/docs/reference/ft2-raster.html
+++ b/3party/freetype/docs/reference/ft2-raster.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Scanline Converter
diff --git a/3party/freetype/docs/reference/ft2-sfnt_names.html b/3party/freetype/docs/reference/ft2-sfnt_names.html
index 4c9841b65f..39a27418ac 100644
--- a/3party/freetype/docs/reference/ft2-sfnt_names.html
+++ b/3party/freetype/docs/reference/ft2-sfnt_names.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
SFNT Names
diff --git a/3party/freetype/docs/reference/ft2-sizes_management.html b/3party/freetype/docs/reference/ft2-sizes_management.html
index 536f4a9f86..c11e8e8755 100644
--- a/3party/freetype/docs/reference/ft2-sizes_management.html
+++ b/3party/freetype/docs/reference/ft2-sizes_management.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Size Management
diff --git a/3party/freetype/docs/reference/ft2-system_interface.html b/3party/freetype/docs/reference/ft2-system_interface.html
index 6d2192543d..eebe91a63c 100644
--- a/3party/freetype/docs/reference/ft2-system_interface.html
+++ b/3party/freetype/docs/reference/ft2-system_interface.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
System Interface
diff --git a/3party/freetype/docs/reference/ft2-toc.html b/3party/freetype/docs/reference/ft2-toc.html
index ca6f8edf31..d354b012d4 100644
--- a/3party/freetype/docs/reference/ft2-toc.html
+++ b/3party/freetype/docs/reference/ft2-toc.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -34,7 +34,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>Table of Contents</h1></center>
<br><table align=center width="75%"><tr><td><h2>General Remarks</h2><ul class="empty"><li>
@@ -125,6 +125,14 @@
</td></tr>
</table>
</li></ul></td></tr></table>
+<br><table align=center width="75%"><tr><td><h2>The Auto-Hinter</h2><ul class="empty"><li>
+<table cellpadding=5>
+<tr valign=top><td class="left">
+<a href="ft2-auto_hinter.html">The auto-hinter</a></td><td>
+<p>Controlling the auto-hinting module.</p>
+</td></tr>
+</table>
+</li></ul></td></tr></table>
<br><table align=center width="75%"><tr><td><h2>Cache Sub-System</h2><ul class="empty"><li>
<table cellpadding=5>
<tr valign=top><td class="left">
@@ -169,7 +177,7 @@
</td></tr>
<tr valign=top><td class="left">
<a href="ft2-module_management.html">Module Management</a></td><td>
-<p>How to add, upgrade, and remove modules from FreeType.</p>
+<p>How to add, upgrade, remove, and control modules from FreeType.</p>
</td></tr>
<tr valign=top><td class="left">
<a href="ft2-gzip.html">GZIP Streams</a></td><td>
@@ -196,10 +204,6 @@
<p>An API to validate OpenType tables.</p>
</td></tr>
<tr valign=top><td class="left">
-<a href="ft2-incremental.html">Incremental Loading</a></td><td>
-<p>Custom Glyph Loading.</p>
-</td></tr>
-<tr valign=top><td class="left">
<a href="ft2-truetype_engine.html">The TrueType Engine</a></td><td>
<p>TrueType bytecode support.</p>
</td></tr>
@@ -207,6 +211,10 @@
<a href="ft2-gx_validation.html">TrueTypeGX/AAT Validation</a></td><td>
<p>An API to validate TrueTypeGX/AAT tables.</p>
</td></tr>
+<tr valign=top><td class="left">
+<a href="ft2-incremental.html">Incremental Loading</a></td><td>
+<p>Custom Glyph Loading.</p>
+</td></tr>
</table>
</li></ul></td></tr></table>
<br><table align=center width="75%"><tr><td><h2><a href="ft2-index.html">Global Index</a></h2><ul class="empty"><li></li></ul></td></tr></table>
@@ -215,5 +223,5 @@
<td width="100%"></td>
</tr></table>
-<center><font size=-2>generated on Tue Nov 15 07:53:40 2011</font></center></body>
+<center><font size=-2>generated on Thu Dec 20 08:35:15 2012</font></center></body>
</html>
diff --git a/3party/freetype/docs/reference/ft2-truetype_engine.html b/3party/freetype/docs/reference/ft2-truetype_engine.html
index 64f6e5b879..088f0a6217 100644
--- a/3party/freetype/docs/reference/ft2-truetype_engine.html
+++ b/3party/freetype/docs/reference/ft2-truetype_engine.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
The TrueType Engine
diff --git a/3party/freetype/docs/reference/ft2-truetype_tables.html b/3party/freetype/docs/reference/ft2-truetype_tables.html
index c7e48d589c..0ac0ae7662 100644
--- a/3party/freetype/docs/reference/ft2-truetype_tables.html
+++ b/3party/freetype/docs/reference/ft2-truetype_tables.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
TrueType Tables
@@ -1000,6 +1000,14 @@ Defined in FT_TRUETYPE_TABLES_H (freetype/tttables.h).
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
<p>The table is owned by the face object and disappears with it.</p>
<p>This function is only useful to access SFNT tables that are loaded by the sfnt, truetype, and opentype drivers. See <a href="ft2-truetype_tables.html#FT_Sfnt_Tag">FT_Sfnt_Tag</a> for a list.</p>
+<p>Here an example how to access the &lsquo;vhea&rsquo; table:</p>
+<pre class="colored">
+ TT_VertHeader* vert_header;
+
+
+ vert_header =
+ (TT_VertHeader*)FT_Get_Sfnt_Table( face, ft_sfnt_vhea );
+</pre>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -1130,7 +1138,7 @@ Defined in FT_TRUETYPE_TABLES_H (freetype/tttables.h).
<p>FreeType error code. 0&nbsp;means success.</p>
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
-<p>SFNT tables with length zero are treated as missing.</p>
+<p>While parsing fonts, FreeType handles SFNT tables with length zero as missing.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -1162,6 +1170,7 @@ Defined in FT_TRUETYPE_TABLES_H (freetype/tttables.h).
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>return</b></em></td></tr><tr><td>
<p>The language ID of &lsquo;charmap&rsquo;. If &lsquo;charmap&rsquo; doesn't belong to a TrueType/sfnt face, just return&nbsp;0 as the default value.</p>
+<p>For a format&nbsp;14 cmap (to access Unicode IVS), the return value is 0xFFFFFFFF.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
diff --git a/3party/freetype/docs/reference/ft2-type1_tables.html b/3party/freetype/docs/reference/ft2-type1_tables.html
index 7182a6f0ea..481a4574f1 100644
--- a/3party/freetype/docs/reference/ft2-type1_tables.html
+++ b/3party/freetype/docs/reference/ft2-type1_tables.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Type 1 Tables
@@ -600,7 +600,7 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
PS_DICT_NOTICE, /* <a href="ft2-basic_types.html#FT_String">FT_String</a>* */
PS_DICT_FULL_NAME, /* <a href="ft2-basic_types.html#FT_String">FT_String</a>* */
PS_DICT_FAMILY_NAME, /* <a href="ft2-basic_types.html#FT_String">FT_String</a>* */
- PS_DICT_WEIGHT, /* <a href="ft2-basic_types.html#FT_String">FT_String</a> */
+ PS_DICT_WEIGHT, /* <a href="ft2-basic_types.html#FT_String">FT_String</a>* */
PS_DICT_IS_FIXED_PITCH, /* <a href="ft2-basic_types.html#FT_Bool">FT_Bool</a> */
PS_DICT_UNDERLINE_POSITION, /* <a href="ft2-basic_types.html#FT_Short">FT_Short</a> */
PS_DICT_UNDERLINE_THICKNESS, /* <a href="ft2-basic_types.html#FT_UShort">FT_UShort</a> */
diff --git a/3party/freetype/docs/reference/ft2-user_allocation.html b/3party/freetype/docs/reference/ft2-user_allocation.html
index d58df11b15..2a05805822 100644
--- a/3party/freetype/docs/reference/ft2-user_allocation.html
+++ b/3party/freetype/docs/reference/ft2-user_allocation.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
User allocation
diff --git a/3party/freetype/docs/reference/ft2-version.html b/3party/freetype/docs/reference/ft2-version.html
index a8f2c4ce15..981f0c4b8b 100644
--- a/3party/freetype/docs/reference/ft2-version.html
+++ b/3party/freetype/docs/reference/ft2-version.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
FreeType Version
@@ -58,7 +58,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MAJOR</a> 2
#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MINOR</a> 4
-#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a> 8
+#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a> 11
</pre></table><br>
<table align=center width="87%"><tr><td>
diff --git a/3party/freetype/docs/reference/ft2-winfnt_fonts.html b/3party/freetype/docs/reference/ft2-winfnt_fonts.html
index 983b7b111e..04ef19cc2b 100644
--- a/3party/freetype/docs/reference/ft2-winfnt_fonts.html
+++ b/3party/freetype/docs/reference/ft2-winfnt_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.4.8 API Reference</title>
+<title>FreeType-2.4.11 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.4.8 API Reference</h1></center>
+<center><h1>FreeType-2.4.11 API Reference</h1></center>
<center><h1>
Window FNT Files
diff --git a/3party/freetype/docs/release b/3party/freetype/docs/release
index 5e2d51f880..65ce078e88 100644
--- a/3party/freetype/docs/release
+++ b/3party/freetype/docs/release
@@ -51,6 +51,13 @@ How to prepare a new release
TODO: Tag the home page CVS on savannah.nongnu.org.
+. Check with
+
+ git clean -ndx
+
+ that the git directory is really clean (and remove extraneous files
+ if necessary).
+
. Say `make dist' in both the freetype2 and freetype2-demos modules
to generate the .tar.gz, .tar.bz2, and .zip files.
@@ -70,7 +77,7 @@ How to prepare a new release
#!/bin/sh
- VERSION=2.3.11
+ VERSION=2.4.8
SAVANNAH_USER=wl
SOURCEFORGE_USER=wlemb
@@ -149,10 +156,24 @@ How to prepare a new release
# EOF
-. While files on savannah.gnu.org are automatically moved to the right
- directory, it must be done manually on SourceForge. Do that now.
+. Prepare a README for SourceForge and upload it with the following
+ script (with updated `$VERSION' and $SOURCEFORGE_USER variables).
+
+ #!/bin/sh
+
+ VERSION=2.4.8
+ SOURCEFORGE_USER=wlemb
+
+ #####################################################################
+
+ rsync -avP -e ssh README \
+ $SOURCEFORGE_USER,freetype@frs.sf.net:/home/frs/project/f/fr/freetype/freetype2/$VERSION/
+
+ # EOF
-. Update the FreeType release notes on SourceForge.
+. On SourceForge, tag the just uploaded `ftXXXX.zip' and
+ `freetype-XXX.tar.bz2' files as the default files to download for
+ `Windows' and `Others', respectively.
. Copy the reference files (generated by `make dist') to
@@ -182,7 +203,7 @@ How to prepare a new release
----------------------------------------------------------------------
-Copyright 2003, 2005, 2006, 2007, 2009 by
+Copyright 2003, 2005-2007, 2009, 2011-2012 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/3party/freetype/freetype.pro b/3party/freetype/freetype.pro
index 12a09988fb..0ffe35cfb5 100644
--- a/3party/freetype/freetype.pro
+++ b/3party/freetype/freetype.pro
@@ -2,7 +2,6 @@ TEMPLATE = lib
CONFIG += staticlib
INCLUDEPATH += ./include
DEFINES += FT2_BUILD_LIBRARY \
- DARWIN_NO_CARBON \
ROOT_DIR = ../..
DEPENDENCIES =
@@ -92,15 +91,16 @@ SOURCES += \
src/truetype/ttinterp.c \
src/truetype/ttobjs.c \
src/truetype/ttpload.c \
- src/type1/t1afm.c \
- src/type1/t1driver.c \
- src/type1/t1gload.c \
- src/type1/t1load.c \
- src/type1/t1objs.c \
- src/type1/t1parse.c \
- src/type42/t42drivr.c \
- src/type42/t42objs.c \
- src/type42/t42parse.c \
- src/winfonts/winfnt.c \
+ src/truetype/truetype.c \
+ #src/type1/t1afm.c \
+ #src/type1/t1driver.c \
+ #src/type1/t1gload.c \
+ #src/type1/t1load.c \
+ #src/type1/t1objs.c \
+ #src/type1/t1parse.c \
+ #src/type42/t42drivr.c \
+ #src/type42/t42objs.c \
+ #src/type42/t42parse.c \
+ #src/winfonts/winfnt.c \
src/cache/ftstrokedcache.c
diff --git a/3party/freetype/include/freetype/config/ftconfig.h b/3party/freetype/include/freetype/config/ftconfig.h
index a9e767cdbd..4502fd83d9 100644
--- a/3party/freetype/include/freetype/config/ftconfig.h
+++ b/3party/freetype/include/freetype/config/ftconfig.h
@@ -120,8 +120,7 @@ FT_BEGIN_HEADER
/* This is the only necessary change, so it is defined here instead */
/* providing a new configuration file. */
/* */
-#if ( defined( __APPLE__ ) && !defined( DARWIN_NO_CARBON ) ) || \
- ( defined( __MWERKS__ ) && defined( macintosh ) )
+#if defined( __APPLE__ ) || ( defined( __MWERKS__ ) && defined( macintosh ) )
/* no Carbon frameworks for 64bit 10.4.x */
/* AvailabilityMacros.h is available since Mac OS X 10.2, */
/* so guess the system version by maximum errno before inclusion */
@@ -131,9 +130,7 @@ FT_BEGIN_HEADER
#endif
#if defined( __LP64__ ) && \
( MAC_OS_X_VERSION_MIN_REQUIRED <= MAC_OS_X_VERSION_10_4 )
-#define DARWIN_NO_CARBON 1
-#else
-#define FT_MACINTOSH 1
+#undef FT_MACINTOSH
#endif
#elif defined( __SC__ ) || defined( __MRC__ )
@@ -358,7 +355,8 @@ FT_BEGIN_HEADER
"mov %0, %1, lsr #16\n\t" /* %0 = %1 >> 16 */
"orr %0, %0, %2, lsl #16\n\t" /* %0 |= %2 << 16 */
: "=r"(a), "=&r"(t2), "=&r"(t)
- : "r"(a), "r"(b) );
+ : "r"(a), "r"(b)
+ : "cc" );
return a;
}
diff --git a/3party/freetype/include/freetype/config/ftheader.h b/3party/freetype/include/freetype/config/ftheader.h
index 2a7b8c4e0d..33d6b4054b 100644
--- a/3party/freetype/include/freetype/config/ftheader.h
+++ b/3party/freetype/include/freetype/config/ftheader.h
@@ -4,7 +4,7 @@
/* */
/* Build macros of the FreeType 2 library. */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2010 by */
+/* Copyright 1996-2008, 2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -318,6 +318,19 @@
/*************************************************************************
*
* @macro:
+ * FT_AUTOHINTER_H
+ *
+ * @description:
+ * A macro used in #include statements to name the file containing
+ * structures and macros related to the auto-hinting module.
+ *
+ */
+#define FT_AUTOHINTER_H <freetype/ftautoh.h>
+
+
+ /*************************************************************************
+ *
+ * @macro:
* FT_TYPE1_TABLES_H
*
* @description:
diff --git a/3party/freetype/include/freetype/config/ftmodule.h b/3party/freetype/include/freetype/config/ftmodule.h
index 76d271a74b..c57cab617e 100644
--- a/3party/freetype/include/freetype/config/ftmodule.h
+++ b/3party/freetype/include/freetype/config/ftmodule.h
@@ -12,12 +12,12 @@
FT_USE_MODULE( FT_Module_Class, autofit_module_class )
FT_USE_MODULE( FT_Driver_ClassRec, tt_driver_class )
-FT_USE_MODULE( FT_Driver_ClassRec, t1_driver_class )
+//FT_USE_MODULE( FT_Driver_ClassRec, t1_driver_class )
FT_USE_MODULE( FT_Driver_ClassRec, cff_driver_class )
FT_USE_MODULE( FT_Driver_ClassRec, t1cid_driver_class )
FT_USE_MODULE( FT_Driver_ClassRec, pfr_driver_class )
-FT_USE_MODULE( FT_Driver_ClassRec, t42_driver_class )
-FT_USE_MODULE( FT_Driver_ClassRec, winfnt_driver_class )
+//FT_USE_MODULE( FT_Driver_ClassRec, t42_driver_class )
+//FT_USE_MODULE( FT_Driver_ClassRec, winfnt_driver_class )
FT_USE_MODULE( FT_Driver_ClassRec, pcf_driver_class )
FT_USE_MODULE( FT_Module_Class, psaux_module_class )
FT_USE_MODULE( FT_Module_Class, psnames_module_class )
diff --git a/3party/freetype/include/freetype/config/ftstdlib.h b/3party/freetype/include/freetype/config/ftstdlib.h
index 11d5d0e65b..b940efc427 100644
--- a/3party/freetype/include/freetype/config/ftstdlib.h
+++ b/3party/freetype/include/freetype/config/ftstdlib.h
@@ -5,7 +5,7 @@
/* ANSI-specific library and header configuration file (specification */
/* only). */
/* */
-/* Copyright 2002-2007, 2009, 2011 by */
+/* Copyright 2002-2007, 2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -159,7 +159,7 @@
/* on certain platforms */
#define ft_longjmp longjmp
-#define ft_setjmp( b ) setjmp( *(jmp_buf*) &(b) ) /* same thing here */
+#define ft_setjmp( b ) setjmp( *(ft_jmp_buf*) &(b) ) /* same thing here */
/* the following is only used for debugging purposes, i.e., if */
diff --git a/3party/freetype/include/freetype/freetype.h b/3party/freetype/include/freetype/freetype.h
index f1f55f09b4..8df4828f6f 100644
--- a/3party/freetype/include/freetype/freetype.h
+++ b/3party/freetype/include/freetype/freetype.h
@@ -4,7 +4,7 @@
/* */
/* FreeType high-level API and common types (specification only). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -16,6 +16,10 @@
/***************************************************************************/
+#ifndef __FREETYPE_H__
+#define __FREETYPE_H__
+
+
#ifndef FT_FREETYPE_H
#error "`ft2build.h' hasn't been included yet!"
#error "Please always use macros to include FreeType header files."
@@ -25,10 +29,6 @@
#endif
-#ifndef __FREETYPE_H__
-#define __FREETYPE_H__
-
-
#include <ft2build.h>
#include FT_CONFIG_CONFIG_H
#include FT_ERRORS_H
@@ -237,6 +237,10 @@ FT_BEGIN_HEADER
/* If not disabled with @FT_LOAD_NO_HINTING, the values represent */
/* dimensions of the hinted glyph (in case hinting is applicable). */
/* */
+ /* Stroking a glyph with an outside border does not increase */
+ /* `horiAdvance' or `vertAdvance'; you have to manually adjust these */
+ /* values to account for the added width and height. */
+ /* */
typedef struct FT_Glyph_Metrics_
{
FT_Pos width;
@@ -844,8 +848,8 @@ FT_BEGIN_HEADER
/* expressed in font units (see */
/* `units_per_EM'). The box is large enough */
/* to contain any glyph from the font. Thus, */
- /* `bbox.yMax' can be seen as the `maximal */
- /* ascender', and `bbox.yMin' as the `minimal */
+ /* `bbox.yMax' can be seen as the `maximum */
+ /* ascender', and `bbox.yMin' as the `minimum */
/* descender'. Only relevant for scalable */
/* formats. */
/* */
@@ -877,13 +881,13 @@ FT_BEGIN_HEADER
/* positive. Only relevant for scalable */
/* formats. */
/* */
- /* max_advance_width :: The maximal advance width, in font units, */
+ /* max_advance_width :: The maximum advance width, in font units, */
/* for all glyphs in this face. This can be */
/* used to make word wrapping computations */
/* faster. Only relevant for scalable */
/* formats. */
/* */
- /* max_advance_height :: The maximal advance height, in font units, */
+ /* max_advance_height :: The maximum advance height, in font units, */
/* for all glyphs in this face. This is only */
/* relevant for vertical layouts, and is set */
/* to `height' for fonts that do not provide */
@@ -958,8 +962,8 @@ FT_BEGIN_HEADER
FT_ListRec sizes_list;
- FT_Generic autohint;
- void* extensions;
+ FT_Generic autohint; /* face-specific auto-hinter data */
+ void* extensions; /* unused */
FT_Face_Internal internal;
@@ -1105,8 +1109,8 @@ FT_BEGIN_HEADER
* FT_HAS_VERTICAL( face )
*
* @description:
- * A macro that returns true whenever a face object contains vertical
- * metrics.
+ * A macro that returns true whenever a face object contains real
+ * vertical metrics (and not only synthesized ones).
*
*/
#define FT_HAS_VERTICAL( face ) \
@@ -1338,7 +1342,7 @@ FT_BEGIN_HEADER
/* height :: The height in 26.6 fractional pixels. See */
/* @FT_FaceRec for the details. */
/* */
- /* max_advance :: The maximal advance width in 26.6 fractional */
+ /* max_advance :: The maximum advance width in 26.6 fractional */
/* pixels. See @FT_FaceRec for the details. */
/* */
/* <Note> */
@@ -1668,6 +1672,9 @@ FT_BEGIN_HEADER
/* use @FT_New_Library instead, followed by a call to */
/* @FT_Add_Default_Modules (or a series of calls to @FT_Add_Module). */
/* */
+ /* For multi-threading applications each thread should have its own */
+ /* FT_Library object. */
+ /* */
FT_EXPORT( FT_Error )
FT_Init_FreeType( FT_Library *alibrary );
@@ -1953,6 +1960,10 @@ FT_BEGIN_HEADER
/* Each new face object created with this function also owns a */
/* default @FT_Size object, accessible as `face->size'. */
/* */
+ /* One @FT_Library instance can have multiple face objects, this is, */
+ /* @FT_Open_Face and its siblings can be called multiple times using */
+ /* the same `library' argument. */
+ /* */
/* See the discussion of reference counters in the description of */
/* @FT_Reference_Face. */
/* */
@@ -2220,6 +2231,12 @@ FT_BEGIN_HEADER
/* particular bitmap strike. Use @FT_Select_Size instead in that */
/* case. */
/* */
+ /* The relation between the requested size and the resulting glyph */
+ /* size is dependent entirely on how the size is defined in the */
+ /* source face. The font designer chooses the final size of each */
+ /* glyph relative to this size. For more information refer to */
+ /* `http://www.freetype.org/freetype2/docs/glyphs/glyphs-2.html' */
+ /* */
FT_EXPORT( FT_Error )
FT_Request_Size( FT_Face face,
FT_Size_Request req );
@@ -2289,6 +2306,11 @@ FT_BEGIN_HEADER
/* <Return> */
/* FreeType error code. 0~means success. */
/* */
+ /* <Note> */
+ /* You should not rely on the resulting glyphs matching, or being */
+ /* constrained, to this pixel size. Refer to @FT_Request_Size to */
+ /* understand how requested sizes relate to actual sizes. */
+ /* */
FT_EXPORT( FT_Error )
FT_Set_Pixel_Sizes( FT_Face face,
FT_UInt pixel_width,
@@ -2402,14 +2424,20 @@ FT_BEGIN_HEADER
* behaviour to more specific and useful cases.
*
* FT_LOAD_NO_SCALE ::
- * Don't scale the outline glyph loaded, but keep it in font units.
+ * Don't scale the loaded outline glyph but keep it in font units.
*
* This flag implies @FT_LOAD_NO_HINTING and @FT_LOAD_NO_BITMAP, and
* unsets @FT_LOAD_RENDER.
*
+ * If the font is `tricky' (see @FT_FACE_FLAG_TRICKY for more), using
+ * FT_LOAD_NO_SCALE usually yields meaningless outlines because the
+ * subglyphs must be scaled and positioned with hinting instructions.
+ * This can be solved by loading the font without FT_LOAD_NO_SCALE and
+ * setting the character size to `font->units_per_EM'.
+ *
* FT_LOAD_NO_HINTING ::
- * Disable hinting. This generally generates `blurrier' bitmap glyph
- * when the glyph is rendered in any of the anti-aliased modes. See
+ * Disable hinting. This generally generates `blurrier' bitmap glyphs
+ * when the glyph are rendered in any of the anti-aliased modes. See
* also the note below.
*
* This flag is implied by @FT_LOAD_NO_SCALE.
@@ -2428,8 +2456,14 @@ FT_BEGIN_HEADER
* @FT_LOAD_NO_SCALE always sets this flag.
*
* FT_LOAD_VERTICAL_LAYOUT ::
- * Load the glyph for vertical text layout. _Don't_ use it as it is
- * problematic currently.
+ * Load the glyph for vertical text layout. In particular, the
+ * `advance' value in the @FT_GlyphSlotRec structure is set to the
+ * `vertAdvance' value of the `metrics' field.
+ *
+ * In case @FT_HAS_VERTICAL doesn't return true, you shouldn't use
+ * this flag currently. Reason is that in this case vertical metrics
+ * get synthesized, and those values are not always consistent across
+ * various font formats.
*
* FT_LOAD_FORCE_AUTOHINT ::
* Indicates that the auto-hinter is preferred over the font's native
@@ -2445,6 +2479,11 @@ FT_BEGIN_HEADER
* during glyph loading. This is mostly used to detect broken glyphs
* in fonts. By default, FreeType tries to handle broken fonts also.
*
+ * In particular, errors from the TrueType bytecode engine are not
+ * passed to the application if this flag is not set; this might
+ * result in partially hinted or distorted glyphs in case a glyph's
+ * bytecode is buggy.
+ *
* FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ::
* Ignored. Deprecated.
*
@@ -2495,28 +2534,35 @@ FT_BEGIN_HEADER
* Besides deciding which hinter to use, you can also decide which
* hinting algorithm to use. See @FT_LOAD_TARGET_XXX for details.
*
+ * Note that the auto-hinter needs a valid Unicode cmap (either a native
+ * one or synthesized by FreeType) for producing correct results. If a
+ * font provides an incorrect mapping (for example, assigning the
+ * character code U+005A, LATIN CAPITAL LETTER Z, to a glyph depicting a
+ * mathematical integral sign), the auto-hinter might produce useless
+ * results.
+ *
*/
#define FT_LOAD_DEFAULT 0x0
-#define FT_LOAD_NO_SCALE 0x1
-#define FT_LOAD_NO_HINTING 0x2
-#define FT_LOAD_RENDER 0x4
-#define FT_LOAD_NO_BITMAP 0x8
-#define FT_LOAD_VERTICAL_LAYOUT 0x10
-#define FT_LOAD_FORCE_AUTOHINT 0x20
-#define FT_LOAD_CROP_BITMAP 0x40
-#define FT_LOAD_PEDANTIC 0x80
-#define FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH 0x200
-#define FT_LOAD_NO_RECURSE 0x400
-#define FT_LOAD_IGNORE_TRANSFORM 0x800
-#define FT_LOAD_MONOCHROME 0x1000
-#define FT_LOAD_LINEAR_DESIGN 0x2000
-#define FT_LOAD_NO_AUTOHINT 0x8000U
+#define FT_LOAD_NO_SCALE ( 1L << 0 )
+#define FT_LOAD_NO_HINTING ( 1L << 1 )
+#define FT_LOAD_RENDER ( 1L << 2 )
+#define FT_LOAD_NO_BITMAP ( 1L << 3 )
+#define FT_LOAD_VERTICAL_LAYOUT ( 1L << 4 )
+#define FT_LOAD_FORCE_AUTOHINT ( 1L << 5 )
+#define FT_LOAD_CROP_BITMAP ( 1L << 6 )
+#define FT_LOAD_PEDANTIC ( 1L << 7 )
+#define FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ( 1L << 9 )
+#define FT_LOAD_NO_RECURSE ( 1L << 10 )
+#define FT_LOAD_IGNORE_TRANSFORM ( 1L << 11 )
+#define FT_LOAD_MONOCHROME ( 1L << 12 )
+#define FT_LOAD_LINEAR_DESIGN ( 1L << 13 )
+#define FT_LOAD_NO_AUTOHINT ( 1L << 15 )
/* */
/* used internally only by certain font drivers! */
-#define FT_LOAD_ADVANCE_ONLY 0x100
-#define FT_LOAD_SBITS_ONLY 0x4000
+#define FT_LOAD_ADVANCE_ONLY ( 1L << 8 )
+#define FT_LOAD_SBITS_ONLY ( 1L << 14 )
/**************************************************************************
@@ -2568,7 +2614,8 @@ FT_BEGIN_HEADER
*
* If @FT_LOAD_RENDER is also set, the glyph is rendered in the
* corresponding mode (i.e., the mode which matches the used algorithm
- * best) unless @FT_LOAD_MONOCHROME is set.
+ * best). An exeption is FT_LOAD_TARGET_MONO since it implies
+ * @FT_LOAD_MONOCHROME.
*
* You can use a hinting algorithm that doesn't correspond to the same
* rendering mode. As an example, it is possible to use the `light'
@@ -2869,14 +2916,26 @@ FT_BEGIN_HEADER
/* */
/* point_size :: The point size in 16.16 fractional points. */
/* */
- /* degree :: The degree of tightness. */
+ /* degree :: The degree of tightness. Increasingly negative */
+ /* values represent tighter track kerning, while */
+ /* increasingly positive values represent looser track */
+ /* kerning. Value zero means no track kerning. */
/* */
/* <Output> */
- /* akerning :: The kerning in 16.16 fractional points. */
+ /* akerning :: The kerning in 16.16 fractional points, to be */
+ /* uniformly applied between all glyphs. */
/* */
/* <Return> */
/* FreeType error code. 0~means success. */
/* */
+ /* <Note> */
+ /* Currently, only the Type~1 font driver supports track kerning, */
+ /* using data from AFM files (if attached with @FT_Attach_File or */
+ /* @FT_Attach_Stream). */
+ /* */
+ /* Only very few AFM files come with track kerning data; please refer */
+ /* to the Adobe's AFM specification for more details. */
+ /* */
FT_EXPORT( FT_Error )
FT_Get_Track_Kerning( FT_Face face,
FT_Fixed point_size,
@@ -2898,7 +2957,7 @@ FT_BEGIN_HEADER
/* */
/* glyph_index :: The glyph index. */
/* */
- /* buffer_max :: The maximal number of bytes available in the */
+ /* buffer_max :: The maximum number of bytes available in the */
/* buffer. */
/* */
/* <Output> */
@@ -3057,9 +3116,15 @@ FT_BEGIN_HEADER
/* <Note> */
/* If you use FreeType to manipulate the contents of font files */
/* directly, be aware that the glyph index returned by this function */
- /* doesn't always correspond to the internal indices used within */
- /* the file. This is done to ensure that value~0 always corresponds */
- /* to the `missing glyph'. */
+ /* doesn't always correspond to the internal indices used within the */
+ /* file. This is done to ensure that value~0 always corresponds to */
+ /* the `missing glyph'. If the first glyph is not named `.notdef', */
+ /* then for Type~1 and Type~42 fonts, `.notdef' will be moved into */
+ /* the glyph ID~0 position, and whatever was there will be moved to */
+ /* the position `.notdef' had. For Type~1 fonts, if there is no */
+ /* `.notdef' glyph at all, then one will be created at index~0 and */
+ /* whatever was there will be moved to the last index -- Type~42 */
+ /* fonts are considered invalid under this condition. */
/* */
FT_EXPORT( FT_UInt )
FT_Get_Char_Index( FT_Face face,
@@ -3359,9 +3424,13 @@ FT_BEGIN_HEADER
/* code range for CJK characters. */
/* */
/* An IVS is registered and unique; for further details please refer */
- /* to Unicode Technical Report #37, the Ideographic Variation */
- /* Database. To date (October 2007), the character with the most */
- /* variants is U+908A, having 8~such IVS. */
+ /* to Unicode Technical Standard #37, the Ideographic Variation */
+ /* Database: */
+ /* */
+ /* http://www.unicode.org/reports/tr37/ */
+ /* */
+ /* To date (November 2012), the character with the most variants is */
+ /* U+9089, having 31 such IVS. */
/* */
/* Adobe and MS decided to support IVS with a new cmap subtable */
/* (format~14). It is an odd subtable because it is not a mapping of */
@@ -3590,7 +3659,7 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* A very simple function used to perform the computation `(a*b)/c' */
- /* with maximal accuracy (it uses a 64-bit intermediate integer */
+ /* with maximum accuracy (it uses a 64-bit intermediate integer */
/* whenever necessary). */
/* */
/* This function isn't necessarily as fast as some processor specific */
@@ -3625,7 +3694,7 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* A very simple function used to perform the computation */
- /* `(a*b)/0x10000' with maximal accuracy. Most of the time this is */
+ /* `(a*b)/0x10000' with maximum accuracy. Most of the time this is */
/* used to multiply a given value by a 16.16 fixed float factor. */
/* */
/* <Input> */
@@ -3670,7 +3739,7 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* A very simple function used to perform the computation */
- /* `(a*0x10000)/b' with maximal accuracy. Most of the time, this is */
+ /* `(a*0x10000)/b' with maximum accuracy. Most of the time, this is */
/* used to divide a given value by a 16.16 fixed float factor. */
/* */
/* <Input> */
@@ -3810,7 +3879,7 @@ FT_BEGIN_HEADER
*/
#define FREETYPE_MAJOR 2
#define FREETYPE_MINOR 4
-#define FREETYPE_PATCH 8
+#define FREETYPE_PATCH 11
/*************************************************************************/
diff --git a/3party/freetype/include/freetype/ftautoh.h b/3party/freetype/include/freetype/ftautoh.h
new file mode 100644
index 0000000000..b427c4dd0d
--- /dev/null
+++ b/3party/freetype/include/freetype/ftautoh.h
@@ -0,0 +1,349 @@
+/***************************************************************************/
+/* */
+/* ftautoh.h */
+/* */
+/* FreeType API for controlling the auto-hinter (specification only). */
+/* */
+/* Copyright 2012 by */
+/* David Turner, Robert Wilhelm, and Werner Lemberg. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __FTAUTOH_H__
+#define __FTAUTOH_H__
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
+
+FT_BEGIN_HEADER
+
+
+ /**************************************************************************
+ *
+ * @section:
+ * auto_hinter
+ *
+ * @title:
+ * The auto-hinter
+ *
+ * @abstract:
+ * Controlling the auto-hinting module.
+ *
+ * @description:
+ * While FreeType's auto-hinter doesn't expose API functions by itself,
+ * it is possible to control its behaviour with @FT_Property_Set and
+ * @FT_Property_Get. The following lists the available properties
+ * together with the necessary macros and structures.
+ *
+ * Note that the auto-hinter's module name is `autofitter' for
+ * historical reasons.
+ *
+ */
+
+
+ /**************************************************************************
+ *
+ * @property:
+ * glyph-to-script-map
+ *
+ * @description:
+ * The auto-hinter provides various script modules to hint glyphs.
+ * Examples of supported scripts are Latin or CJK. Before a glyph is
+ * auto-hinted, the Unicode character map of the font gets examined, and
+ * the script is then determined based on Unicode character ranges, see
+ * below.
+ *
+ * OpenType fonts, however, often provide much more glyphs than
+ * character codes (small caps, superscripts, ligatures, swashes, etc.),
+ * to be controlled by so-called `features'. Handling OpenType features
+ * can be quite complicated and thus needs a separate library on top of
+ * FreeType.
+ *
+ * The mapping between glyph indices and scripts (in the auto-hinter
+ * sense, see the @FT_AUTOHINTER_SCRIPT_XXX values) is stored as an
+ * array with `num_glyphs' elements, as found in the font's @FT_Face
+ * structure. The `glyph-to-script-map' property returns a pointer to
+ * this array which can be modified as needed. Note that the
+ * modification should happen before the first glyph gets processed by
+ * the auto-hinter so that the global analysis of the font shapes
+ * actually uses the modified mapping.
+ *
+ * The following example code demonstrates how to access it (omitting
+ * the error handling).
+ *
+ * {
+ * FT_Library library;
+ * FT_Face face;
+ * FT_Prop_GlyphToScriptMap prop;
+ *
+ *
+ * FT_Init_FreeType( &library );
+ * FT_New_Face( library, "foo.ttf", 0, &face );
+ *
+ * prop.face = face;
+ *
+ * FT_Property_Get( library, "autofitter",
+ * "glyph-to-script-map", &prop );
+ *
+ * // adjust `prop.map' as needed right here
+ *
+ * FT_Load_Glyph( face, ..., FT_LOAD_FORCE_AUTOHINT );
+ * }
+ *
+ */
+
+
+ /**************************************************************************
+ *
+ * @enum:
+ * FT_AUTOHINTER_SCRIPT_XXX
+ *
+ * @description:
+ * A list of constants used for the @glyph-to-script-map property to
+ * specify the script submodule the auto-hinter should use for hinting a
+ * particular glyph.
+ *
+ * @values:
+ * FT_AUTOHINTER_SCRIPT_NONE ::
+ * Don't auto-hint this glyph.
+ *
+ * FT_AUTOHINTER_SCRIPT_LATIN ::
+ * Apply the latin auto-hinter. For the auto-hinter, `latin' is a
+ * very broad term, including Cyrillic and Greek also since characters
+ * from those scripts share the same design constraints.
+ *
+ * By default, characters from the following Unicode ranges are
+ * assigned to this submodule.
+ *
+ * {
+ * U+0020 - U+007F // Basic Latin (no control characters)
+ * U+00A0 - U+00FF // Latin-1 Supplement (no control characters)
+ * U+0100 - U+017F // Latin Extended-A
+ * U+0180 - U+024F // Latin Extended-B
+ * U+0250 - U+02AF // IPA Extensions
+ * U+02B0 - U+02FF // Spacing Modifier Letters
+ * U+0300 - U+036F // Combining Diacritical Marks
+ * U+0370 - U+03FF // Greek and Coptic
+ * U+0400 - U+04FF // Cyrillic
+ * U+0500 - U+052F // Cyrillic Supplement
+ * U+1D00 - U+1D7F // Phonetic Extensions
+ * U+1D80 - U+1DBF // Phonetic Extensions Supplement
+ * U+1DC0 - U+1DFF // Combining Diacritical Marks Supplement
+ * U+1E00 - U+1EFF // Latin Extended Additional
+ * U+1F00 - U+1FFF // Greek Extended
+ * U+2000 - U+206F // General Punctuation
+ * U+2070 - U+209F // Superscripts and Subscripts
+ * U+20A0 - U+20CF // Currency Symbols
+ * U+2150 - U+218F // Number Forms
+ * U+2460 - U+24FF // Enclosed Alphanumerics
+ * U+2C60 - U+2C7F // Latin Extended-C
+ * U+2DE0 - U+2DFF // Cyrillic Extended-A
+ * U+2E00 - U+2E7F // Supplemental Punctuation
+ * U+A640 - U+A69F // Cyrillic Extended-B
+ * U+A720 - U+A7FF // Latin Extended-D
+ * U+FB00 - U+FB06 // Alphab. Present. Forms (Latin Ligatures)
+ * U+1D400 - U+1D7FF // Mathematical Alphanumeric Symbols
+ * U+1F100 - U+1F1FF // Enclosed Alphanumeric Supplement
+ * }
+ *
+ * FT_AUTOHINTER_SCRIPT_CJK ::
+ * Apply the CJK auto-hinter, covering Chinese, Japanese, Korean, old
+ * Vietnamese, and some other scripts.
+ *
+ * By default, characters from the following Unicode ranges are
+ * assigned to this submodule.
+ *
+ * {
+ * U+1100 - U+11FF // Hangul Jamo
+ * U+2E80 - U+2EFF // CJK Radicals Supplement
+ * U+2F00 - U+2FDF // Kangxi Radicals
+ * U+2FF0 - U+2FFF // Ideographic Description Characters
+ * U+3000 - U+303F // CJK Symbols and Punctuation
+ * U+3040 - U+309F // Hiragana
+ * U+30A0 - U+30FF // Katakana
+ * U+3100 - U+312F // Bopomofo
+ * U+3130 - U+318F // Hangul Compatibility Jamo
+ * U+3190 - U+319F // Kanbun
+ * U+31A0 - U+31BF // Bopomofo Extended
+ * U+31C0 - U+31EF // CJK Strokes
+ * U+31F0 - U+31FF // Katakana Phonetic Extensions
+ * U+3200 - U+32FF // Enclosed CJK Letters and Months
+ * U+3300 - U+33FF // CJK Compatibility
+ * U+3400 - U+4DBF // CJK Unified Ideographs Extension A
+ * U+4DC0 - U+4DFF // Yijing Hexagram Symbols
+ * U+4E00 - U+9FFF // CJK Unified Ideographs
+ * U+A960 - U+A97F // Hangul Jamo Extended-A
+ * U+AC00 - U+D7AF // Hangul Syllables
+ * U+D7B0 - U+D7FF // Hangul Jamo Extended-B
+ * U+F900 - U+FAFF // CJK Compatibility Ideographs
+ * U+FE10 - U+FE1F // Vertical forms
+ * U+FE30 - U+FE4F // CJK Compatibility Forms
+ * U+FF00 - U+FFEF // Halfwidth and Fullwidth Forms
+ * U+1B000 - U+1B0FF // Kana Supplement
+ * U+1D300 - U+1D35F // Tai Xuan Hing Symbols
+ * U+1F200 - U+1F2FF // Enclosed Ideographic Supplement
+ * U+20000 - U+2A6DF // CJK Unified Ideographs Extension B
+ * U+2A700 - U+2B73F // CJK Unified Ideographs Extension C
+ * U+2B740 - U+2B81F // CJK Unified Ideographs Extension D
+ * U+2F800 - U+2FA1F // CJK Compatibility Ideographs Supplement
+ * }
+ *
+ * FT_AUTOHINTER_SCRIPT_INDIC ::
+ * Apply the indic auto-hinter, covering all major scripts from the
+ * Indian sub-continent and some other related scripts like Thai, Lao,
+ * or Tibetan.
+ *
+ * By default, characters from the following Unicode ranges are
+ * assigned to this submodule.
+ *
+ * {
+ * U+0900 - U+0DFF // Indic Range
+ * U+0F00 - U+0FFF // Tibetan
+ * U+1900 - U+194F // Limbu
+ * U+1B80 - U+1BBF // Sundanese
+ * U+1C80 - U+1CDF // Meetei Mayak
+ * U+A800 - U+A82F // Syloti Nagri
+ * U+11800 - U+118DF // Sharada
+ * }
+ *
+ * Note that currently Indic support is rudimentary only, missing blue
+ * zone support.
+ *
+ */
+#define FT_AUTOHINTER_SCRIPT_NONE 0
+#define FT_AUTOHINTER_SCRIPT_LATIN 1
+#define FT_AUTOHINTER_SCRIPT_CJK 2
+#define FT_AUTOHINTER_SCRIPT_INDIC 3
+
+
+ /**************************************************************************
+ *
+ * @struct:
+ * FT_Prop_GlyphToScriptMap
+ *
+ * @description:
+ * The data exchange structure for the @glyph-to-script-map property.
+ *
+ */
+ typedef struct FT_Prop_GlyphToScriptMap_
+ {
+ FT_Face face;
+ FT_Byte* map;
+
+ } FT_Prop_GlyphToScriptMap;
+
+
+ /**************************************************************************
+ *
+ * @property:
+ * fallback-script
+ *
+ * @description:
+ * If no auto-hinter script module can be assigned to a glyph, a
+ * fallback script gets assigned to it (see also the
+ * @glyph-to-script-map property). By default, this is
+ * @FT_AUTOHINTER_SCRIPT_CJK. Using the `fallback-script' property,
+ * this fallback value can be changed.
+ *
+ * {
+ * FT_Library library;
+ * FT_UInt fallback_script = FT_AUTOHINTER_SCRIPT_NONE;
+ *
+ *
+ * FT_Init_FreeType( &library );
+ *
+ * FT_Property_Set( library, "autofitter",
+ * "fallback-script", &fallback_script );
+ * }
+ *
+ * @note:
+ * This property can be used with @FT_Property_Get also.
+ *
+ * It's important to use the right timing for changing this value: The
+ * creation of the glyph-to-script map which eventually uses the
+ * fallback script value gets triggered either by setting or reading a
+ * face-specific property like @glyph-to-script-map, or by auto-hinting
+ * any glyph from that face. In particular, if you have already created
+ * an @FT_Face structure but not loaded any glyph (using the
+ * auto-hinter), a change of the fallback glyph will affect this face.
+ *
+ */
+
+
+ /**************************************************************************
+ *
+ * @property:
+ * increase-x-height
+ *
+ * @description:
+ * For ppem values in the range 6~<= ppem <= `increase-x-height', round
+ * up the font's x~height much more often than normally. If the value
+ * is set to~0, which is the default, this feature is switched off. Use
+ * this property to improve the legibility of small font sizes if
+ * necessary.
+ *
+ * {
+ * FT_Library library;
+ * FT_Face face;
+ * FT_Prop_IncreaseXHeight prop;
+ *
+ *
+ * FT_Init_FreeType( &library );
+ * FT_New_Face( library, "foo.ttf", 0, &face );
+ * FT_Set_Char_Size( face, 10 * 64, 0, 72, 0 );
+ *
+ * prop.face = face;
+ * prop.limit = 14;
+ *
+ * FT_Property_Set( library, "autofitter",
+ * "increase-x-height", &prop );
+ * }
+ *
+ * @note:
+ * This property can be used with @FT_Property_Get also.
+ *
+ * Set this value right after calling @FT_Set_Char_Size, but before
+ * loading any glyph (using the auto-hinter).
+ *
+ */
+
+
+ /**************************************************************************
+ *
+ * @struct:
+ * FT_Prop_IncreaseXHeight
+ *
+ * @description:
+ * The data exchange structure for the @increase-x-height property.
+ *
+ */
+ typedef struct FT_Prop_IncreaseXHeight_
+ {
+ FT_Face face;
+ FT_UInt limit;
+
+ } FT_Prop_IncreaseXHeight;
+
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __FTAUTOH_H__ */
+
+
+/* END */
diff --git a/3party/freetype/include/freetype/ftchapters.h b/3party/freetype/include/freetype/ftchapters.h
index 6cdf54e495..984eef3728 100644
--- a/3party/freetype/include/freetype/ftchapters.h
+++ b/3party/freetype/include/freetype/ftchapters.h
@@ -67,6 +67,20 @@
/***************************************************************************/
/* */
/* <Chapter> */
+/* auto_hinter */
+/* */
+/* <Title> */
+/* The Auto-Hinter */
+/* */
+/* <Sections> */
+/* auto_hinter */
+/* */
+/***************************************************************************/
+
+
+/***************************************************************************/
+/* */
+/* <Chapter> */
/* cache_subsystem */
/* */
/* <Title> */
diff --git a/3party/freetype/include/freetype/fterrdef.h b/3party/freetype/include/freetype/fterrdef.h
index d4e7287f2e..bb06d79e9a 100644
--- a/3party/freetype/include/freetype/fterrdef.h
+++ b/3party/freetype/include/freetype/fterrdef.h
@@ -4,7 +4,7 @@
/* */
/* FreeType error codes (specification). */
/* */
-/* Copyright 2002, 2004, 2006, 2007, 2010 by */
+/* Copyright 2002, 2004, 2006, 2007, 2010-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -54,6 +54,10 @@
"broken offset within table" )
FT_ERRORDEF_( Array_Too_Large, 0x0A, \
"array allocation size too large" )
+ FT_ERRORDEF_( Missing_Module, 0x0B, \
+ "missing module" )
+ FT_ERRORDEF_( Missing_Property, 0x0C, \
+ "missing property" )
/* glyph/character errors */
diff --git a/3party/freetype/include/freetype/fterrors.h b/3party/freetype/include/freetype/fterrors.h
index 6600dadd0d..a54699f87f 100644
--- a/3party/freetype/include/freetype/fterrors.h
+++ b/3party/freetype/include/freetype/fterrors.h
@@ -192,12 +192,13 @@
#undef FT_NOERRORDEF_
#undef FT_NEED_EXTERN_C
-#undef FT_ERR_CONCAT
#undef FT_ERR_BASE
/* FT_KEEP_ERR_PREFIX is needed for ftvalid.h */
#ifndef FT_KEEP_ERR_PREFIX
#undef FT_ERR_PREFIX
+#else
+#undef FT_KEEP_ERR_PREFIX
#endif
#endif /* __FTERRORS_H__ */
diff --git a/3party/freetype/include/freetype/ftgasp.h b/3party/freetype/include/freetype/ftgasp.h
index 5e978e5c14..453d4fa42c 100644
--- a/3party/freetype/include/freetype/ftgasp.h
+++ b/3party/freetype/include/freetype/ftgasp.h
@@ -62,12 +62,12 @@
* It is up to the client to decide what to do.
*
* FT_GASP_DO_GRIDFIT ::
- * Grid-fitting and hinting should be performed at the specified ppem.
+ * Grid-fitting and hinting should be performed at the specified ppem.
* This *really* means TrueType bytecode interpretation. If this bit
* is not set, no hinting gets applied.
*
* FT_GASP_DO_GRAY ::
- * Anti-aliased rendering should be performed at the specified ppem.
+ * Anti-aliased rendering should be performed at the specified ppem.
* If not set, do monochrome rendering.
*
* FT_GASP_SYMMETRIC_SMOOTHING ::
diff --git a/3party/freetype/include/freetype/ftmodapi.h b/3party/freetype/include/freetype/ftmodapi.h
index 8f2e017947..aedfc54df2 100644
--- a/3party/freetype/include/freetype/ftmodapi.h
+++ b/3party/freetype/include/freetype/ftmodapi.h
@@ -4,7 +4,7 @@
/* */
/* FreeType modules public interface (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2006, 2008, 2009, 2010 by */
+/* Copyright 1996-2003, 2006, 2008-2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -42,11 +42,38 @@ FT_BEGIN_HEADER
/* Module Management */
/* */
/* <Abstract> */
- /* How to add, upgrade, and remove modules from FreeType. */
+ /* How to add, upgrade, remove, and control modules from FreeType. */
/* */
/* <Description> */
/* The definitions below are used to manage modules within FreeType. */
/* Modules can be added, upgraded, and removed at runtime. */
+ /* Additionally, some module properties can be controlled also. */
+ /* */
+ /* Here is a list of possible values of the `module_name' field in */
+ /* the @FT_Module_Class structure. */
+ /* */
+ /* { */
+ /* autofitter */
+ /* bdf */
+ /* cff */
+ /* gxvalid */
+ /* otvalid */
+ /* pcf */
+ /* pfr */
+ /* psaux */
+ /* pshinter */
+ /* psnames */
+ /* raster1, raster5 */
+ /* sfnt */
+ /* smooth, smooth-lcd, smooth-lcdv */
+ /* truetype */
+ /* type1 */
+ /* type42 */
+ /* t1cid */
+ /* winfonts */
+ /* } */
+ /* */
+ /* Note that the FreeType Cache sub-system is not a FreeType module. */
/* */
/*************************************************************************/
@@ -118,7 +145,7 @@ FT_BEGIN_HEADER
/* A function used to query a given module for a specific interface. */
/* */
/* <Input> */
- /* module :: The module to finalize. */
+ /* module :: The module to be searched. */
/* */
/* name :: The name of the interface in the module. */
/* */
@@ -249,6 +276,130 @@ FT_BEGIN_HEADER
FT_Module module );
+ /**********************************************************************
+ *
+ * @function:
+ * FT_Property_Set
+ *
+ * @description:
+ * Set a property for a given module.
+ *
+ * @input:
+ * library ::
+ * A handle to the library the module is part of.
+ *
+ * module_name ::
+ * The module name.
+ *
+ * property_name ::
+ * The property name. Properties are described in the `Synopsis'
+ * subsection of the module's documentation.
+ *
+ * Note that only a few modules have properties.
+ *
+ * value ::
+ * A generic pointer to a variable or structure which gives the new
+ * value of the property. The exact definition of `value' is
+ * dependent on the property; see the `Synopsis' subsection of the
+ * module's documentation.
+ *
+ * @return:
+ * FreeType error code. 0~means success.
+ *
+ * @note:
+ * If `module_name' isn't a valid module name, or `property_name'
+ * doesn't specify a valid property, or if `value' doesn't represent a
+ * valid value for the given property, an error is returned.
+ *
+ * The following example sets property `bar' (a simple integer) in
+ * module `foo' to value~1.
+ *
+ * {
+ * FT_UInt bar;
+ *
+ *
+ * bar = 1;
+ * FT_Property_Set( library, "foo", "bar", &bar );
+ * }
+ *
+ * It is not possible to set properties of the FreeType Cache
+ * sub-system with FT_Property_Set; use @FTC_Property_Set instead.
+ *
+ * @since:
+ * 2.4.11
+ *
+ */
+ FT_Error
+ FT_Property_Set( FT_Library library,
+ const FT_String* module_name,
+ const FT_String* property_name,
+ const void* value );
+
+
+ /**********************************************************************
+ *
+ * @function:
+ * FT_Property_Get
+ *
+ * @description:
+ * Get a module's property value.
+ *
+ * @input:
+ * library ::
+ * A handle to the library the module is part of.
+ *
+ * module_name ::
+ * The module name.
+ *
+ * property_name ::
+ * The property name. Properties are described in the `Synopsis'
+ * subsection of the module's documentation.
+ *
+ * @inout:
+ * value ::
+ * A generic pointer to a variable or structure which gives the
+ * value of the property. The exact definition of `value' is
+ * dependent on the property; see the `Synopsis' subsection of the
+ * module's documentation.
+ *
+ * @return:
+ * FreeType error code. 0~means success.
+ *
+ * @note:
+ * If `module_name' isn't a valid module name, or `property_name'
+ * doesn't specify a valid property, or if `value' doesn't represent a
+ * valid value for the given property, an error is returned.
+ *
+ * The following example gets property `baz' (a range) in module `foo'.
+ *
+ * {
+ * typedef range_
+ * {
+ * FT_Int32 min;
+ * FT_Int32 max;
+ *
+ * } range;
+ *
+ * range baz;
+ *
+ *
+ * FT_Property_Get( library, "foo", "baz", &baz );
+ * }
+ *
+ * It is not possible to retrieve properties of the FreeType Cache
+ * sub-system with FT_Property_Get; use @FTC_Property_Get instead.
+ *
+ * @since:
+ * 2.4.11
+ *
+ */
+ FT_Error
+ FT_Property_Get( FT_Library library,
+ const FT_String* module_name,
+ const FT_String* property_name,
+ void* value );
+
+
/*************************************************************************/
/* */
/* <Function> */
@@ -430,13 +581,13 @@ FT_BEGIN_HEADER
* scale glyph components with bytecode instructions. It produces
* bad output for most other fonts.
*
- * FT_TRUETYPE_ENGINE_TYPE_PATENTED ::
+ * FT_TRUETYPE_ENGINE_TYPE_PATENTED ::
* The library implements a bytecode interpreter that covers
* the full instruction set of the TrueType virtual machine (this
* was governed by patents until May 2010, hence the name).
*
* @since:
- * 2.2
+ * 2.2
*
*/
typedef enum FT_TrueTypeEngineType_
diff --git a/3party/freetype/include/freetype/ftoutln.h b/3party/freetype/include/freetype/ftoutln.h
index 1cf3c3f800..e733f391ea 100644
--- a/3party/freetype/include/freetype/ftoutln.h
+++ b/3party/freetype/include/freetype/ftoutln.h
@@ -5,7 +5,7 @@
/* Support for the FT_Outline type used to store glyph shapes of */
/* most scalable font formats (specification). */
/* */
-/* Copyright 1996-2003, 2005-2011 by */
+/* Copyright 1996-2003, 2005-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -59,6 +59,7 @@ FT_BEGIN_HEADER
/* FT_Outline_Translate */
/* FT_Outline_Transform */
/* FT_Outline_Embolden */
+ /* FT_Outline_EmboldenXY */
/* FT_Outline_Reverse */
/* FT_Outline_Check */
/* */
@@ -124,9 +125,9 @@ FT_BEGIN_HEADER
/* outline will *not* necessarily be *freed*, when */
/* destroying the library, by @FT_Done_FreeType. */
/* */
- /* numPoints :: The maximal number of points within the outline. */
+ /* numPoints :: The maximum number of points within the outline. */
/* */
- /* numContours :: The maximal number of contours within the outline. */
+ /* numContours :: The maximum number of contours within the outline. */
/* */
/* <Output> */
/* anoutline :: A handle to the new outline. */
@@ -353,6 +354,23 @@ FT_BEGIN_HEADER
/*************************************************************************/
/* */
/* <Function> */
+ /* FT_Outline_EmboldenXY */
+ /* */
+ /* <Description> */
+ /* Embolden an outline. The new outline will be `xstrength' pixels */
+ /* wider and `ystrength' pixels higher. Otherwise, it is similar to */
+ /* @FT_Outline_Embolden, which uses the same strength in both */
+ /* directions. */
+ /* */
+ FT_EXPORT( FT_Error )
+ FT_Outline_EmboldenXY( FT_Outline* outline,
+ FT_Pos xstrength,
+ FT_Pos ystrength );
+
+
+ /*************************************************************************/
+ /* */
+ /* <Function> */
/* FT_Outline_Reverse */
/* */
/* <Description> */
diff --git a/3party/freetype/include/freetype/ftstroke.h b/3party/freetype/include/freetype/ftstroke.h
index dbda6d23de..c3eb85a676 100644
--- a/3party/freetype/include/freetype/ftstroke.h
+++ b/3party/freetype/include/freetype/ftstroke.h
@@ -4,7 +4,7 @@
/* */
/* FreeType path stroker (specification). */
/* */
-/* Copyright 2002-2006, 2008, 2009, 2011 by */
+/* Copyright 2002-2006, 2008, 2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -85,25 +85,25 @@ FT_BEGIN_HEADER
* miter limit is exceeded. The outer edges of the strokes
* for the two segments are extended until they meet at an
* angle. If the segments meet at too sharp an angle (such
- * that the miter would extend from the intersection of the
- * segments a distance greater than the product of the miter
- * limit value and the border radius), then a bevel join (see
- * above) is used instead. This prevents long spikes being
- * created. FT_STROKER_LINEJOIN_MITER_FIXED generates a miter
+ * that the miter would extend from the intersection of the
+ * segments a distance greater than the product of the miter
+ * limit value and the border radius), then a bevel join (see
+ * above) is used instead. This prevents long spikes being
+ * created. FT_STROKER_LINEJOIN_MITER_FIXED generates a miter
* line join as used in PostScript and PDF.
*
* FT_STROKER_LINEJOIN_MITER_VARIABLE ::
* FT_STROKER_LINEJOIN_MITER ::
* Used to render mitered line joins, with variable bevels if
- * the miter limit is exceeded. The intersection of the
- * strokes is clipped at a line perpendicular to the bisector
- * of the angle between the strokes, at the distance from the
- * intersection of the segments equal to the product of the
- * miter limit value and the border radius. This prevents
- * long spikes being created.
- * FT_STROKER_LINEJOIN_MITER_VARIABLE generates a mitered line
- * join as used in XPS. FT_STROKER_LINEJOIN_MITER is an alias
- * for FT_STROKER_LINEJOIN_MITER_VARIABLE, retained for
+ * the miter limit is exceeded. The intersection of the
+ * strokes is clipped at a line perpendicular to the bisector
+ * of the angle between the strokes, at the distance from the
+ * intersection of the segments equal to the product of the
+ * miter limit value and the border radius. This prevents
+ * long spikes being created.
+ * FT_STROKER_LINEJOIN_MITER_VARIABLE generates a mitered line
+ * join as used in XPS. FT_STROKER_LINEJOIN_MITER is an alias
+ * for FT_STROKER_LINEJOIN_MITER_VARIABLE, retained for
* backwards compatibility.
*/
typedef enum FT_Stroker_LineJoin_
@@ -682,6 +682,11 @@ FT_BEGIN_HEADER
*
* @note:
* The source glyph is untouched in case of error.
+ *
+ * Adding stroke may yield a significantly wider and taller glyph
+ * depending on how large of a radius was used to stroke the glyph. You
+ * may need to manually adjust horizontal and vertical advance amounts
+ * to account for this added size.
*/
FT_EXPORT( FT_Error )
FT_Glyph_Stroke( FT_Glyph *pglyph,
@@ -719,6 +724,11 @@ FT_BEGIN_HEADER
*
* @note:
* The source glyph is untouched in case of error.
+ *
+ * Adding stroke may yield a significantly wider and taller glyph
+ * depending on how large of a radius was used to stroke the glyph. You
+ * may need to manually adjust horizontal and vertical advance amounts
+ * to account for this added size.
*/
FT_EXPORT( FT_Error )
FT_Glyph_StrokeBorder( FT_Glyph *pglyph,
diff --git a/3party/freetype/include/freetype/ftsynth.h b/3party/freetype/include/freetype/ftsynth.h
index a068b7928d..2074503cf6 100644
--- a/3party/freetype/include/freetype/ftsynth.h
+++ b/3party/freetype/include/freetype/ftsynth.h
@@ -5,7 +5,7 @@
/* FreeType synthesizing code for emboldening and slanting */
/* (specification). */
/* */
-/* Copyright 2000-2001, 2003, 2006, 2008 by */
+/* Copyright 2000-2001, 2003, 2006, 2008, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -61,8 +61,9 @@ FT_BEGIN_HEADER
/* taste). This function is actually a convenience function, providing */
/* a wrapper for @FT_Outline_Embolden and @FT_Bitmap_Embolden. */
/* */
- /* For emboldened outlines the metrics are estimates only; if you need */
- /* precise values you should call @FT_Outline_Get_CBox. */
+ /* For emboldened outlines the height, width, and advance metrics are */
+ /* increased by the strength of the emboldening. You can also call */
+ /* @FT_Outline_Get_CBox to get precise values. */
FT_EXPORT( void )
FT_GlyphSlot_Embolden( FT_GlyphSlot slot );
diff --git a/3party/freetype/include/freetype/fttypes.h b/3party/freetype/include/freetype/fttypes.h
index a57ffa69bd..3255527449 100644
--- a/3party/freetype/include/freetype/fttypes.h
+++ b/3party/freetype/include/freetype/fttypes.h
@@ -4,7 +4,7 @@
/* */
/* FreeType simple types definitions (specification only). */
/* */
-/* Copyright 1996-2001, 2002, 2004, 2006, 2007, 2008 by */
+/* Copyright 1996-2002, 2004, 2006-2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -434,7 +434,7 @@ FT_BEGIN_HEADER
/* variety of FreeType core objects. For example, a text layout API */
/* might want to associate a glyph cache to a given size object. */
/* */
- /* Most FreeType object contains a `generic' field, of type */
+ /* Some FreeType object contains a `generic' field, of type */
/* FT_Generic, which usage is left to client applications and font */
/* servers. */
/* */
diff --git a/3party/freetype/include/freetype/internal/autohint.h b/3party/freetype/include/freetype/internal/autohint.h
index 7e3a08a051..545de938c2 100644
--- a/3party/freetype/include/freetype/internal/autohint.h
+++ b/3party/freetype/include/freetype/internal/autohint.h
@@ -4,7 +4,7 @@
/* */
/* High-level `autohint' module-specific interface (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2007 by */
+/* Copyright 1996-2002, 2007, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -86,20 +86,20 @@ FT_BEGIN_HEADER
/* FT_AutoHinter_GlobalGetFunc */
/* */
/* <Description> */
- /* Retrieves the global hints computed for a given face object the */
+ /* Retrieve the global hints computed for a given face object. The */
/* resulting data is dissociated from the face and will survive a */
/* call to FT_Done_Face(). It must be discarded through the API */
/* FT_AutoHinter_GlobalDoneFunc(). */
/* */
/* <Input> */
- /* hinter :: A handle to the source auto-hinter. */
+ /* hinter :: A handle to the source auto-hinter. */
/* */
- /* face :: A handle to the source face object. */
+ /* face :: A handle to the source face object. */
/* */
/* <Output> */
- /* global_hints :: A typeless pointer to the global hints. */
+ /* global_hints :: A typeless pointer to the global hints. */
/* */
- /* global_len :: The size in bytes of the global hints. */
+ /* global_len :: The size in bytes of the global hints. */
/* */
typedef void
(*FT_AutoHinter_GlobalGetFunc)( FT_AutoHinter hinter,
@@ -114,7 +114,7 @@ FT_BEGIN_HEADER
/* FT_AutoHinter_GlobalDoneFunc */
/* */
/* <Description> */
- /* Discards the global hints retrieved through */
+ /* Discard the global hints retrieved through */
/* FT_AutoHinter_GlobalGetFunc(). This is the only way these hints */
/* are freed from memory. */
/* */
@@ -168,8 +168,8 @@ FT_BEGIN_HEADER
/* This function is capable of loading composite glyphs by hinting */
/* each sub-glyph independently (which improves quality). */
/* */
- /* It will call the font driver with FT_Load_Glyph(), with */
- /* FT_LOAD_NO_SCALE set. */
+ /* It will call the font driver with @FT_Load_Glyph, with */
+ /* @FT_LOAD_NO_SCALE set. */
/* */
typedef FT_Error
(*FT_AutoHinter_GlyphLoadFunc)( FT_AutoHinter hinter,
@@ -182,46 +182,59 @@ FT_BEGIN_HEADER
/*************************************************************************/
/* */
/* <Struct> */
- /* FT_AutoHinter_ServiceRec */
+ /* FT_AutoHinter_InterfaceRec */
/* */
/* <Description> */
/* The auto-hinter module's interface. */
/* */
- typedef struct FT_AutoHinter_ServiceRec_
+ typedef struct FT_AutoHinter_InterfaceRec_
{
FT_AutoHinter_GlobalResetFunc reset_face;
FT_AutoHinter_GlobalGetFunc get_global_hints;
FT_AutoHinter_GlobalDoneFunc done_global_hints;
FT_AutoHinter_GlyphLoadFunc load_glyph;
- } FT_AutoHinter_ServiceRec, *FT_AutoHinter_Service;
+ } FT_AutoHinter_InterfaceRec, *FT_AutoHinter_Interface;
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_AUTOHINTER_SERVICE(class_, reset_face_, get_global_hints_, \
- done_global_hints_, load_glyph_) \
- FT_CALLBACK_TABLE_DEF \
- const FT_AutoHinter_ServiceRec class_ = \
- { \
- reset_face_, get_global_hints_, done_global_hints_, load_glyph_ \
+#define FT_DEFINE_AUTOHINTER_INTERFACE( \
+ class_, \
+ reset_face_, \
+ get_global_hints_, \
+ done_global_hints_, \
+ load_glyph_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_AutoHinter_InterfaceRec class_ = \
+ { \
+ reset_face_, \
+ get_global_hints_, \
+ done_global_hints_, \
+ load_glyph_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DEFINE_AUTOHINTER_SERVICE(class_, reset_face_, get_global_hints_, \
- done_global_hints_, load_glyph_) \
- void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_AutoHinter_ServiceRec* clazz) \
- { \
- FT_UNUSED(library); \
- clazz->reset_face = reset_face_; \
- clazz->get_global_hints = get_global_hints_; \
- clazz->done_global_hints = done_global_hints_; \
- clazz->load_glyph = load_glyph_; \
- }
-
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_AUTOHINTER_INTERFACE( \
+ class_, \
+ reset_face_, \
+ get_global_hints_, \
+ done_global_hints_, \
+ load_glyph_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_AutoHinter_InterfaceRec* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ clazz->reset_face = reset_face_; \
+ clazz->get_global_hints = get_global_hints_; \
+ clazz->done_global_hints = done_global_hints_; \
+ clazz->load_glyph = load_glyph_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
FT_END_HEADER
diff --git a/3party/freetype/include/freetype/internal/ftcalc.h b/3party/freetype/include/freetype/internal/ftcalc.h
index f8b4324777..a6a5e05f6f 100644
--- a/3party/freetype/include/freetype/internal/ftcalc.h
+++ b/3party/freetype/include/freetype/internal/ftcalc.h
@@ -4,7 +4,7 @@
/* */
/* Arithmetic computations (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008, 2009 by */
+/* Copyright 1996-2006, 2008, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -78,8 +78,6 @@ FT_BEGIN_HEADER
/*************************************************************************/
-#ifdef TT_USE_BYTECODE_INTERPRETER
-
/*************************************************************************/
/* */
/* <Function> */
@@ -87,7 +85,7 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* A very simple function used to perform the computation `(a*b)/c' */
- /* (without rounding) with maximal accuracy (it uses a 64-bit */
+ /* (without rounding) with maximum accuracy (it uses a 64-bit */
/* intermediate integer whenever necessary). */
/* */
/* This function isn't necessarily as fast as some processor specific */
@@ -108,8 +106,6 @@ FT_BEGIN_HEADER
FT_Long b,
FT_Long c );
-#endif /* TT_USE_BYTECODE_INTERPRETER */
-
/*
* A variant of FT_Matrix_Multiply which scales its result afterwards.
diff --git a/3party/freetype/include/freetype/internal/ftdriver.h b/3party/freetype/include/freetype/internal/ftdriver.h
index 1d06997bd1..093b14b4f5 100644
--- a/3party/freetype/include/freetype/internal/ftdriver.h
+++ b/3party/freetype/include/freetype/internal/ftdriver.h
@@ -4,7 +4,7 @@
/* */
/* FreeType font driver interface (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2006, 2008 by */
+/* Copyright 1996-2003, 2006, 2008, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -162,10 +162,9 @@ FT_BEGIN_HEADER
/* starting at `first'. The `vertical' flag must */
/* be set to get vertical advance heights. The */
/* `advances' buffer is caller-allocated. */
- /* Currently not implemented. The idea of this */
- /* function is to be able to perform */
- /* device-independent text layout without loading */
- /* a single glyph image. */
+ /* The idea of this function is to be able to */
+ /* perform device-independent text layout without */
+ /* loading a single glyph image. */
/* */
/* request_size :: A handle to a function used to request the new */
/* character size. Can be set to 0 if the */
@@ -182,37 +181,37 @@ FT_BEGIN_HEADER
/* */
typedef struct FT_Driver_ClassRec_
{
- FT_Module_Class root;
+ FT_Module_Class root;
- FT_Long face_object_size;
- FT_Long size_object_size;
- FT_Long slot_object_size;
+ FT_Long face_object_size;
+ FT_Long size_object_size;
+ FT_Long slot_object_size;
- FT_Face_InitFunc init_face;
- FT_Face_DoneFunc done_face;
+ FT_Face_InitFunc init_face;
+ FT_Face_DoneFunc done_face;
- FT_Size_InitFunc init_size;
- FT_Size_DoneFunc done_size;
+ FT_Size_InitFunc init_size;
+ FT_Size_DoneFunc done_size;
- FT_Slot_InitFunc init_slot;
- FT_Slot_DoneFunc done_slot;
+ FT_Slot_InitFunc init_slot;
+ FT_Slot_DoneFunc done_slot;
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- FT_Size_ResetPointsFunc set_char_sizes;
- FT_Size_ResetPixelsFunc set_pixel_sizes;
+ FT_Size_ResetPointsFunc set_char_sizes;
+ FT_Size_ResetPixelsFunc set_pixel_sizes;
#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */
- FT_Slot_LoadFunc load_glyph;
+ FT_Slot_LoadFunc load_glyph;
- FT_Face_GetKerningFunc get_kerning;
- FT_Face_AttachFunc attach_file;
- FT_Face_GetAdvancesFunc get_advances;
+ FT_Face_GetKerningFunc get_kerning;
+ FT_Face_AttachFunc attach_file;
+ FT_Face_GetAdvancesFunc get_advances;
/* since version 2.2 */
- FT_Size_RequestFunc request_size;
- FT_Size_SelectFunc select_size;
+ FT_Size_RequestFunc request_size;
+ FT_Size_SelectFunc select_size;
} FT_Driver_ClassRec, *FT_Driver_Class;
@@ -240,14 +239,15 @@ FT_BEGIN_HEADER
#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */
+
/*************************************************************************/
/* */
/* <Macro> */
/* FT_DECLARE_DRIVER */
/* */
/* <Description> */
- /* Used to create a forward declaration of a */
- /* FT_Driver_ClassRec stract instance. */
+ /* Used to create a forward declaration of an FT_Driver_ClassRec */
+ /* struct instance. */
/* */
/* <Macro> */
/* FT_DEFINE_DRIVER */
@@ -255,161 +255,220 @@ FT_BEGIN_HEADER
/* <Description> */
/* Used to initialize an instance of FT_Driver_ClassRec struct. */
/* */
- /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
- /* to called with a pointer where the allocated stracture is returned.*/
- /* And when it is no longer needed a Destroy function needs */
- /* to be called to release that allocation. */
- /* fcinit.c (ft_create_default_module_classes) already contains */
- /* a mechanism to call these functions for the default modules */
- /* described in ftmodule.h */
+ /* When FT_CONFIG_OPTION_PIC is defined a `create' function has to be */
+ /* called with a pointer where the allocated structure is returned. */
+ /* And when it is no longer needed a `destroy' function needs to be */
+ /* called to release that allocation. */
+ /* */
+ /* `fcinit.c' (ft_create_default_module_classes) already contains a */
+ /* mechanism to call these functions for the default modules */
+ /* described in `ftmodule.h'. */
/* */
- /* Notice that the created Create and Destroy functions call */
- /* pic_init and pic_free function to allow you to manually allocate */
- /* and initialize any additional global data, like module specific */
+ /* Notice that the created `create' and `destroy' functions call */
+ /* `pic_init' and `pic_free' to allow you to manually allocate and */
+ /* initialize any additional global data, like a module specific */
/* interface, and put them in the global pic container defined in */
- /* ftpic.h. if you don't need them just implement the functions as */
- /* empty to resolve the link error. */
+ /* `ftpic.h'. If you don't need them just implement the functions as */
+ /* empty to resolve the link error. Also the `pic_init' and */
+ /* `pic_free' functions should be declared in `pic.h', to be referred */
+ /* by driver definition calling `FT_DEFINE_DRIVER' in following. */
/* */
/* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
- /* allocated in the global scope (or the scope where the macro */
- /* is used). */
+ /* allocated in the global scope (or the scope where the macro is */
+ /* used). */
/* */
#ifndef FT_CONFIG_OPTION_PIC
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
-#define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_) \
- a_, b_,
+#define FT_DEFINE_DRIVERS_OLD_INTERNALS( a_, b_ ) \
+ a_, b_,
#else
- #define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_)
+#define FT_DEFINE_DRIVERS_OLD_INTERNALS( a_, b_ ) /* empty */
#endif
-#define FT_DECLARE_DRIVER(class_) \
- FT_CALLBACK_TABLE \
- const FT_Driver_ClassRec class_;
-
-#define FT_DEFINE_DRIVER(class_, \
- flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_, \
- face_object_size_, size_object_size_, \
- slot_object_size_, init_face_, done_face_, \
- init_size_, done_size_, init_slot_, done_slot_, \
- old_set_char_sizes_, old_set_pixel_sizes_, \
- load_glyph_, get_kerning_, attach_file_, \
- get_advances_, request_size_, select_size_ ) \
- FT_CALLBACK_TABLE_DEF \
- const FT_Driver_ClassRec class_ = \
- { \
- FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_,interface_, \
- init_,done_,get_interface_) \
- \
- face_object_size_, \
- size_object_size_, \
- slot_object_size_, \
- \
- init_face_, \
- done_face_, \
- \
- init_size_, \
- done_size_, \
- \
- init_slot_, \
- done_slot_, \
- \
- FT_DEFINE_DRIVERS_OLD_INTERNALS(old_set_char_sizes_, old_set_pixel_sizes_) \
- \
- load_glyph_, \
- \
- get_kerning_, \
- attach_file_, \
- get_advances_, \
- \
- request_size_, \
- select_size_ \
+#define FT_DECLARE_DRIVER( class_ ) \
+ FT_CALLBACK_TABLE \
+ const FT_Driver_ClassRec class_;
+
+#define FT_DEFINE_DRIVER( \
+ class_, \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_, \
+ face_object_size_, \
+ size_object_size_, \
+ slot_object_size_, \
+ init_face_, \
+ done_face_, \
+ init_size_, \
+ done_size_, \
+ init_slot_, \
+ done_slot_, \
+ old_set_char_sizes_, \
+ old_set_pixel_sizes_, \
+ load_glyph_, \
+ get_kerning_, \
+ attach_file_, \
+ get_advances_, \
+ request_size_, \
+ select_size_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Driver_ClassRec class_ = \
+ { \
+ FT_DEFINE_ROOT_MODULE( flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ \
+ face_object_size_, \
+ size_object_size_, \
+ slot_object_size_, \
+ \
+ init_face_, \
+ done_face_, \
+ \
+ init_size_, \
+ done_size_, \
+ \
+ init_slot_, \
+ done_slot_, \
+ \
+ FT_DEFINE_DRIVERS_OLD_INTERNALS( old_set_char_sizes_, \
+ old_set_pixel_sizes_ ) \
+ \
+ load_glyph_, \
+ \
+ get_kerning_, \
+ attach_file_, \
+ get_advances_, \
+ \
+ request_size_, \
+ select_size_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
-#define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_) \
- clazz->set_char_sizes = a_; \
- clazz->set_pixel_sizes = b_;
+#define FT_DEFINE_DRIVERS_OLD_INTERNALS( a_, b_ ) \
+ clazz->set_char_sizes = a_; \
+ clazz->set_pixel_sizes = b_;
#else
- #define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_)
+#define FT_DEFINE_DRIVERS_OLD_INTERNALS( a_, b_ ) /* empty */
#endif
-#define FT_DECLARE_DRIVER(class_) FT_DECLARE_MODULE(class_)
-
-#define FT_DEFINE_DRIVER(class_, \
- flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_, \
- face_object_size_, size_object_size_, \
- slot_object_size_, init_face_, done_face_, \
- init_size_, done_size_, init_slot_, done_slot_, \
- old_set_char_sizes_, old_set_pixel_sizes_, \
- load_glyph_, get_kerning_, attach_file_, \
- get_advances_, request_size_, select_size_ ) \
- void class_##_pic_free( FT_Library library ); \
- FT_Error class_##_pic_init( FT_Library library ); \
- \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_Module_Class* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- FT_Driver_Class dclazz = (FT_Driver_Class)clazz; \
- class_##_pic_free( library ); \
- if ( dclazz ) \
- FT_FREE( dclazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_Module_Class** output_class ) \
- { \
- FT_Driver_Class clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz) ) ) \
- return error; \
- \
- error = class_##_pic_init( library ); \
- if(error) \
- { \
- FT_FREE( clazz ); \
- return error; \
- } \
- \
- FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_,interface_, \
- init_,done_,get_interface_) \
- \
- clazz->face_object_size = face_object_size_; \
- clazz->size_object_size = size_object_size_; \
- clazz->slot_object_size = slot_object_size_; \
- \
- clazz->init_face = init_face_; \
- clazz->done_face = done_face_; \
- \
- clazz->init_size = init_size_; \
- clazz->done_size = done_size_; \
- \
- clazz->init_slot = init_slot_; \
- clazz->done_slot = done_slot_; \
- \
- FT_DEFINE_DRIVERS_OLD_INTERNALS(old_set_char_sizes_, old_set_pixel_sizes_) \
- \
- clazz->load_glyph = load_glyph_; \
- \
- clazz->get_kerning = get_kerning_; \
- clazz->attach_file = attach_file_; \
- clazz->get_advances = get_advances_; \
- \
- clazz->request_size = request_size_; \
- clazz->select_size = select_size_; \
- \
- *output_class = (FT_Module_Class*)clazz; \
- return FT_Err_Ok; \
- }
+#define FT_DECLARE_DRIVER( class_ ) FT_DECLARE_MODULE( class_ )
+
+#define FT_DEFINE_DRIVER( \
+ class_, \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_, \
+ face_object_size_, \
+ size_object_size_, \
+ slot_object_size_, \
+ init_face_, \
+ done_face_, \
+ init_size_, \
+ done_size_, \
+ init_slot_, \
+ done_slot_, \
+ old_set_char_sizes_, \
+ old_set_pixel_sizes_, \
+ load_glyph_, \
+ get_kerning_, \
+ attach_file_, \
+ get_advances_, \
+ request_size_, \
+ select_size_ ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_Module_Class* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ FT_Driver_Class dclazz = (FT_Driver_Class)clazz; \
+ \
+ \
+ class_ ## _pic_free( library ); \
+ if ( dclazz ) \
+ FT_FREE( dclazz ); \
+ } \
+ \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_Module_Class** output_class ) \
+ { \
+ FT_Driver_Class clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) ) ) \
+ return error; \
+ \
+ error = class_ ## _pic_init( library ); \
+ if ( error ) \
+ { \
+ FT_FREE( clazz ); \
+ return error; \
+ } \
+ \
+ FT_DEFINE_ROOT_MODULE( flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ \
+ clazz->face_object_size = face_object_size_; \
+ clazz->size_object_size = size_object_size_; \
+ clazz->slot_object_size = slot_object_size_; \
+ \
+ clazz->init_face = init_face_; \
+ clazz->done_face = done_face_; \
+ \
+ clazz->init_size = init_size_; \
+ clazz->done_size = done_size_; \
+ \
+ clazz->init_slot = init_slot_; \
+ clazz->done_slot = done_slot_; \
+ \
+ FT_DEFINE_DRIVERS_OLD_INTERNALS( old_set_char_sizes_, \
+ old_set_pixel_sizes_ ) \
+ \
+ clazz->load_glyph = load_glyph_; \
+ \
+ clazz->get_kerning = get_kerning_; \
+ clazz->attach_file = attach_file_; \
+ clazz->get_advances = get_advances_; \
+ \
+ clazz->request_size = request_size_; \
+ clazz->select_size = select_size_; \
+ \
+ *output_class = (FT_Module_Class*)clazz; \
+ \
+ return FT_Err_Ok; \
+ }
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/include/freetype/internal/ftobjs.h b/3party/freetype/include/freetype/internal/ftobjs.h
index 670eb78a84..28132a4a1e 100644
--- a/3party/freetype/include/freetype/internal/ftobjs.h
+++ b/3party/freetype/include/freetype/internal/ftobjs.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType private base classes (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008, 2010 by */
+/* Copyright 1996-2006, 2008, 2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -206,46 +206,79 @@ FT_BEGIN_HEADER
} FT_CMap_ClassRec;
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DECLARE_CMAP_CLASS(class_) \
- FT_CALLBACK_TABLE const FT_CMap_ClassRec class_;
-
-#define FT_DEFINE_CMAP_CLASS(class_, size_, init_, done_, char_index_, \
- char_next_, char_var_index_, char_var_default_, variant_list_, \
- charvariant_list_, variantchar_list_) \
- FT_CALLBACK_TABLE_DEF \
- const FT_CMap_ClassRec class_ = \
- { \
- size_, init_, done_, char_index_, char_next_, char_var_index_, \
- char_var_default_, variant_list_, charvariant_list_, variantchar_list_ \
+#define FT_DECLARE_CMAP_CLASS( class_ ) \
+ FT_CALLBACK_TABLE const FT_CMap_ClassRec class_;
+
+#define FT_DEFINE_CMAP_CLASS( \
+ class_, \
+ size_, \
+ init_, \
+ done_, \
+ char_index_, \
+ char_next_, \
+ char_var_index_, \
+ char_var_default_, \
+ variant_list_, \
+ charvariant_list_, \
+ variantchar_list_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_CMap_ClassRec class_ = \
+ { \
+ size_, \
+ init_, \
+ done_, \
+ char_index_, \
+ char_next_, \
+ char_var_index_, \
+ char_var_default_, \
+ variant_list_, \
+ charvariant_list_, \
+ variantchar_list_ \
};
+
#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DECLARE_CMAP_CLASS(class_) \
- void FT_Init_Class_##class_( FT_Library library, FT_CMap_ClassRec* clazz);
-
-#define FT_DEFINE_CMAP_CLASS(class_, size_, init_, done_, char_index_, \
- char_next_, char_var_index_, char_var_default_, variant_list_, \
- charvariant_list_, variantchar_list_) \
- void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_CMap_ClassRec* clazz) \
- { \
- FT_UNUSED(library); \
- clazz->size = size_; \
- clazz->init = init_; \
- clazz->done = done_; \
- clazz->char_index = char_index_; \
- clazz->char_next = char_next_; \
- clazz->char_var_index = char_var_index_; \
- clazz->char_var_default = char_var_default_; \
- clazz->variant_list = variant_list_; \
- clazz->charvariant_list = charvariant_list_; \
- clazz->variantchar_list = variantchar_list_; \
- }
+#define FT_DECLARE_CMAP_CLASS( class_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_CMap_ClassRec* clazz );
+
+#define FT_DEFINE_CMAP_CLASS( \
+ class_, \
+ size_, \
+ init_, \
+ done_, \
+ char_index_, \
+ char_next_, \
+ char_var_index_, \
+ char_var_default_, \
+ variant_list_, \
+ charvariant_list_, \
+ variantchar_list_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_CMap_ClassRec* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ clazz->size = size_; \
+ clazz->init = init_; \
+ clazz->done = done_; \
+ clazz->char_index = char_index_; \
+ clazz->char_next = char_next_; \
+ clazz->char_var_index = char_var_index_; \
+ clazz->char_var_default = char_var_default_; \
+ clazz->variant_list = variant_list_; \
+ clazz->charvariant_list = charvariant_list_; \
+ clazz->variantchar_list = variantchar_list_; \
+ }
+
#endif /* FT_CONFIG_OPTION_PIC */
+
/* create a new charmap and add it to charmap->face */
FT_BASE( FT_Error )
FT_CMap_New( FT_CMap_Class clazz,
@@ -270,13 +303,13 @@ FT_BEGIN_HEADER
/* */
/* <Fields> */
/* max_points :: */
- /* The maximal number of points used to store the vectorial outline */
+ /* The maximum number of points used to store the vectorial outline */
/* of any glyph in this face. If this value cannot be known in */
/* advance, or if the face isn't scalable, this should be set to 0. */
/* Only relevant for scalable formats. */
/* */
/* max_contours :: */
- /* The maximal number of contours used to store the vectorial */
+ /* The maximum number of contours used to store the vectorial */
/* outline of any glyph in this face. If this value cannot be */
/* known in advance, or if the face isn't scalable, this should be */
/* set to 0. Only relevant for scalable formats. */
@@ -411,6 +444,7 @@ FT_BEGIN_HEADER
/*************************************************************************/
/*************************************************************************/
+ /*************************************************************************/
/**** ****/
/**** ****/
/**** M O D U L E S ****/
@@ -436,19 +470,16 @@ FT_BEGIN_HEADER
/* */
/* memory :: A handle to the memory manager. */
/* */
- /* generic :: A generic structure for user-level extensibility (?). */
- /* */
typedef struct FT_ModuleRec_
{
FT_Module_Class* clazz;
FT_Library library;
FT_Memory memory;
- FT_Generic generic;
} FT_ModuleRec;
- /* typecast an object to a FT_Module */
+ /* typecast an object to an FT_Module */
#define FT_MODULE( x ) ((FT_Module)( x ))
#define FT_MODULE_CLASS( x ) FT_MODULE( x )->clazz
#define FT_MODULE_LIBRARY( x ) FT_MODULE( x )->library
@@ -506,7 +537,7 @@ FT_BEGIN_HEADER
ft_module_get_service( FT_Module module,
const char* service_id );
- /* */
+ /* */
/*************************************************************************/
@@ -514,7 +545,7 @@ FT_BEGIN_HEADER
/*************************************************************************/
/**** ****/
/**** ****/
- /**** FACE, SIZE & GLYPH SLOT OBJECTS ****/
+ /**** F A C E, S I Z E & G L Y P H S L O T O B J E C T S ****/
/**** ****/
/**** ****/
/*************************************************************************/
@@ -711,10 +742,6 @@ FT_BEGIN_HEADER
/* faces_list :: The list of faces currently opened by this */
/* driver. */
/* */
- /* extensions :: A typeless pointer to the driver's extensions */
- /* registry, if they are supported through the */
- /* configuration macro FT_CONFIG_OPTION_EXTENSIONS. */
- /* */
/* glyph_loader :: The glyph loader for all faces managed by this */
/* driver. This object isn't defined for unscalable */
/* formats. */
@@ -723,10 +750,7 @@ FT_BEGIN_HEADER
{
FT_ModuleRec root;
FT_Driver_Class clazz;
-
FT_ListRec faces_list;
- void* extensions;
-
FT_GlyphLoader glyph_loader;
} FT_DriverRec;
@@ -776,9 +800,6 @@ FT_BEGIN_HEADER
/* memory :: The library's memory object. Manages memory */
/* allocation. */
/* */
- /* generic :: Client data variable. Used to extend the */
- /* Library class by higher levels and clients. */
- /* */
/* version_major :: The major version number of the library. */
/* */
/* version_minor :: The minor version number of the library. */
@@ -838,8 +859,6 @@ FT_BEGIN_HEADER
{
FT_Memory memory; /* library's memory manager */
- FT_Generic generic;
-
FT_Int version_major;
FT_Int version_minor;
FT_Int version_patch;
@@ -941,12 +960,13 @@ FT_BEGIN_HEADER
FT_EXPORT_VAR( FT_Raster_Funcs ) ft_default_raster;
#endif
+
/*************************************************************************/
/*************************************************************************/
/*************************************************************************/
/**** ****/
/**** ****/
- /**** PIC-Support Macros for ftimage.h ****/
+ /**** P I C S U P P O R T ****/
/**** ****/
/**** ****/
/*************************************************************************/
@@ -954,6 +974,9 @@ FT_BEGIN_HEADER
/*************************************************************************/
+ /* PIC support macros for ftimage.h */
+
+
/*************************************************************************/
/* */
/* <Macro> */
@@ -962,37 +985,56 @@ FT_BEGIN_HEADER
/* <Description> */
/* Used to initialize an instance of FT_Outline_Funcs struct. */
/* When FT_CONFIG_OPTION_PIC is defined an init funtion will need to */
- /* called with a pre-allocated stracture to be filled. */
+ /* be called with a pre-allocated structure to be filled. */
/* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
/* allocated in the global scope (or the scope where the macro */
/* is used). */
/* */
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_OUTLINE_FUNCS(class_, move_to_, line_to_, conic_to_, \
- cubic_to_, shift_, delta_) \
- static const FT_Outline_Funcs class_ = \
- { \
- move_to_, line_to_, conic_to_, cubic_to_, shift_, delta_ \
+#define FT_DEFINE_OUTLINE_FUNCS( \
+ class_, \
+ move_to_, \
+ line_to_, \
+ conic_to_, \
+ cubic_to_, \
+ shift_, \
+ delta_ ) \
+ static const FT_Outline_Funcs class_ = \
+ { \
+ move_to_, \
+ line_to_, \
+ conic_to_, \
+ cubic_to_, \
+ shift_, \
+ delta_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_OUTLINE_FUNCS( \
+ class_, \
+ move_to_, \
+ line_to_, \
+ conic_to_, \
+ cubic_to_, \
+ shift_, \
+ delta_ ) \
+ static FT_Error \
+ Init_Class_ ## class_( FT_Outline_Funcs* clazz ) \
+ { \
+ clazz->move_to = move_to_; \
+ clazz->line_to = line_to_; \
+ clazz->conic_to = conic_to_; \
+ clazz->cubic_to = cubic_to_; \
+ clazz->shift = shift_; \
+ clazz->delta = delta_; \
+ \
+ return FT_Err_Ok; \
+ }
-#define FT_DEFINE_OUTLINE_FUNCS(class_, move_to_, line_to_, conic_to_, \
- cubic_to_, shift_, delta_) \
- static FT_Error \
- Init_Class_##class_( FT_Outline_Funcs* clazz ) \
- { \
- clazz->move_to = move_to_; \
- clazz->line_to = line_to_; \
- clazz->conic_to = conic_to_; \
- clazz->cubic_to = cubic_to_; \
- clazz->shift = shift_; \
- clazz->delta = delta_; \
- return FT_Err_Ok; \
- }
+#endif /* FT_CONFIG_OPTION_PIC */
-#endif /* FT_CONFIG_OPTION_PIC */
/*************************************************************************/
/* */
@@ -1002,51 +1044,56 @@ FT_BEGIN_HEADER
/* <Description> */
/* Used to initialize an instance of FT_Raster_Funcs struct. */
/* When FT_CONFIG_OPTION_PIC is defined an init funtion will need to */
- /* called with a pre-allocated stracture to be filled. */
+ /* be called with a pre-allocated structure to be filled. */
/* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
/* allocated in the global scope (or the scope where the macro */
/* is used). */
/* */
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_RASTER_FUNCS(class_, glyph_format_, raster_new_, \
- raster_reset_, raster_set_mode_, \
- raster_render_, raster_done_) \
- const FT_Raster_Funcs class_ = \
- { \
- glyph_format_, raster_new_, raster_reset_, \
- raster_set_mode_, raster_render_, raster_done_ \
+#define FT_DEFINE_RASTER_FUNCS( \
+ class_, \
+ glyph_format_, \
+ raster_new_, \
+ raster_reset_, \
+ raster_set_mode_, \
+ raster_render_, \
+ raster_done_ ) \
+ const FT_Raster_Funcs class_ = \
+ { \
+ glyph_format_, \
+ raster_new_, \
+ raster_reset_, \
+ raster_set_mode_, \
+ raster_render_, \
+ raster_done_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_RASTER_FUNCS(class_, glyph_format_, raster_new_, \
- raster_reset_, raster_set_mode_, raster_render_, raster_done_) \
- void \
- FT_Init_Class_##class_( FT_Raster_Funcs* clazz ) \
- { \
- clazz->glyph_format = glyph_format_; \
- clazz->raster_new = raster_new_; \
- clazz->raster_reset = raster_reset_; \
- clazz->raster_set_mode = raster_set_mode_; \
- clazz->raster_render = raster_render_; \
- clazz->raster_done = raster_done_; \
- }
+#define FT_DEFINE_RASTER_FUNCS( \
+ class_, \
+ glyph_format_, \
+ raster_new_, \
+ raster_reset_, \
+ raster_set_mode_, \
+ raster_render_, \
+ raster_done_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Raster_Funcs* clazz ) \
+ { \
+ clazz->glyph_format = glyph_format_; \
+ clazz->raster_new = raster_new_; \
+ clazz->raster_reset = raster_reset_; \
+ clazz->raster_set_mode = raster_set_mode_; \
+ clazz->raster_render = raster_render_; \
+ clazz->raster_done = raster_done_; \
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
- /*************************************************************************/
- /*************************************************************************/
- /*************************************************************************/
- /**** ****/
- /**** ****/
- /**** PIC-Support Macros for ftrender.h ****/
- /**** ****/
- /**** ****/
- /*************************************************************************/
- /*************************************************************************/
- /*************************************************************************/
+ /* PIC support macros for ftrender.h */
/*************************************************************************/
@@ -1057,39 +1104,63 @@ FT_BEGIN_HEADER
/* <Description> */
/* Used to initialize an instance of FT_Glyph_Class struct. */
/* When FT_CONFIG_OPTION_PIC is defined an init funtion will need to */
- /* called with a pre-allocated stracture to be filled. */
+ /* be called with a pre-allocated stcture to be filled. */
/* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
/* allocated in the global scope (or the scope where the macro */
/* is used). */
/* */
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_GLYPH(class_, size_, format_, init_, done_, copy_, \
- transform_, bbox_, prepare_) \
- FT_CALLBACK_TABLE_DEF \
- const FT_Glyph_Class class_ = \
- { \
- size_, format_, init_, done_, copy_, transform_, bbox_, prepare_ \
+#define FT_DEFINE_GLYPH( \
+ class_, \
+ size_, \
+ format_, \
+ init_, \
+ done_, \
+ copy_, \
+ transform_, \
+ bbox_, \
+ prepare_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Glyph_Class class_ = \
+ { \
+ size_, \
+ format_, \
+ init_, \
+ done_, \
+ copy_, \
+ transform_, \
+ bbox_, \
+ prepare_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_GLYPH( \
+ class_, \
+ size_, \
+ format_, \
+ init_, \
+ done_, \
+ copy_, \
+ transform_, \
+ bbox_, \
+ prepare_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Glyph_Class* clazz ) \
+ { \
+ clazz->glyph_size = size_; \
+ clazz->glyph_format = format_; \
+ clazz->glyph_init = init_; \
+ clazz->glyph_done = done_; \
+ clazz->glyph_copy = copy_; \
+ clazz->glyph_transform = transform_; \
+ clazz->glyph_bbox = bbox_; \
+ clazz->glyph_prepare = prepare_; \
+ }
-#define FT_DEFINE_GLYPH(class_, size_, format_, init_, done_, copy_, \
- transform_, bbox_, prepare_) \
- void \
- FT_Init_Class_##class_( FT_Glyph_Class* clazz ) \
- { \
- clazz->glyph_size = size_; \
- clazz->glyph_format = format_; \
- clazz->glyph_init = init_; \
- clazz->glyph_done = done_; \
- clazz->glyph_copy = copy_; \
- clazz->glyph_transform = transform_; \
- clazz->glyph_bbox = bbox_; \
- clazz->glyph_prepare = prepare_; \
- }
+#endif /* FT_CONFIG_OPTION_PIC */
-#endif /* FT_CONFIG_OPTION_PIC */
/*************************************************************************/
/* */
@@ -1098,7 +1169,7 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* Used to create a forward declaration of a */
- /* FT_Renderer_Class stract instance. */
+ /* FT_Renderer_Class struct instance. */
/* */
/* <Macro> */
/* FT_DEFINE_RENDERER */
@@ -1106,20 +1177,23 @@ FT_BEGIN_HEADER
/* <Description> */
/* Used to initialize an instance of FT_Renderer_Class struct. */
/* */
- /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
- /* to called with a pointer where the allocated stracture is returned.*/
- /* And when it is no longer needed a Destroy function needs */
- /* to be called to release that allocation. */
- /* fcinit.c (ft_create_default_module_classes) already contains */
+ /* When FT_CONFIG_OPTION_PIC is defined a `create' funtion will need */
+ /* to be called with a pointer where the allocated structure is */
+ /* returned. And when it is no longer needed a `destroy' function */
+ /* needs to be called to release that allocation. */
+ /* `fcinit.c' (ft_create_default_module_classes) already contains */
/* a mechanism to call these functions for the default modules */
- /* described in ftmodule.h */
+ /* described in `ftmodule.h'. */
/* */
- /* Notice that the created Create and Destroy functions call */
- /* pic_init and pic_free function to allow you to manually allocate */
- /* and initialize any additional global data, like module specific */
+ /* Notice that the created `create' and `destroy' functions call */
+ /* `pic_init' and `pic_free' to allow you to manually allocate and */
+ /* initialize any additional global data, like a module specific */
/* interface, and put them in the global pic container defined in */
- /* ftpic.h. if you don't need them just implement the functions as */
- /* empty to resolve the link error. */
+ /* `ftpic.h'. If you don't need them just implement the functions as */
+ /* empty to resolve the link error. Also the `pic_init' and */
+ /* `pic_free' functions should be declared in `pic.h', to be referred */
+ /* by the renderer definition calling `FT_DEFINE_RENDERER' in the */
+ /* following. */
/* */
/* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
/* allocated in the global scope (or the scope where the macro */
@@ -1127,101 +1201,130 @@ FT_BEGIN_HEADER
/* */
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DECLARE_RENDERER(class_) \
- FT_EXPORT_VAR( const FT_Renderer_Class ) class_;
-
-#define FT_DEFINE_RENDERER(class_, \
- flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_, \
- glyph_format_, render_glyph_, transform_glyph_, \
- get_glyph_cbox_, set_mode_, raster_class_ ) \
- FT_CALLBACK_TABLE_DEF \
- const FT_Renderer_Class class_ = \
- { \
- FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_, \
- interface_,init_,done_,get_interface_) \
- glyph_format_, \
- \
- render_glyph_, \
- transform_glyph_, \
- get_glyph_cbox_, \
- set_mode_, \
- \
- raster_class_ \
+#define FT_DECLARE_RENDERER( class_ ) \
+ FT_EXPORT_VAR( const FT_Renderer_Class ) class_;
+
+#define FT_DEFINE_RENDERER( \
+ class_, \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_, \
+ glyph_format_, \
+ render_glyph_, \
+ transform_glyph_, \
+ get_glyph_cbox_, \
+ set_mode_, \
+ raster_class_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Renderer_Class class_ = \
+ { \
+ FT_DEFINE_ROOT_MODULE( flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ glyph_format_, \
+ \
+ render_glyph_, \
+ transform_glyph_, \
+ get_glyph_cbox_, \
+ set_mode_, \
+ \
+ raster_class_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DECLARE_RENDERER(class_) FT_DECLARE_MODULE(class_)
-
-#define FT_DEFINE_RENDERER(class_, \
- flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_, \
- glyph_format_, render_glyph_, transform_glyph_, \
- get_glyph_cbox_, set_mode_, raster_class_ ) \
- void class_##_pic_free( FT_Library library ); \
- FT_Error class_##_pic_init( FT_Library library ); \
- \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_Module_Class* clazz ) \
- { \
- FT_Renderer_Class* rclazz = (FT_Renderer_Class*)clazz; \
- FT_Memory memory = library->memory; \
- class_##_pic_free( library ); \
- if ( rclazz ) \
- FT_FREE( rclazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_Module_Class** output_class ) \
- { \
- FT_Renderer_Class* clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz) ) ) \
- return error; \
- \
- error = class_##_pic_init( library ); \
- if(error) \
- { \
- FT_FREE( clazz ); \
- return error; \
- } \
- \
- FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_, \
- interface_,init_,done_,get_interface_) \
- \
- clazz->glyph_format = glyph_format_; \
- \
- clazz->render_glyph = render_glyph_; \
- clazz->transform_glyph = transform_glyph_; \
- clazz->get_glyph_cbox = get_glyph_cbox_; \
- clazz->set_mode = set_mode_; \
- \
- clazz->raster_class = raster_class_; \
- \
- *output_class = (FT_Module_Class*)clazz; \
- return FT_Err_Ok; \
- }
-
-
-
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
- /*************************************************************************/
- /*************************************************************************/
- /*************************************************************************/
- /**** ****/
- /**** ****/
- /**** PIC-Support Macros for ftmodapi.h ****/
- /**** ****/
- /**** ****/
- /*************************************************************************/
- /*************************************************************************/
- /*************************************************************************/
+#define FT_DECLARE_RENDERER( class_ ) FT_DECLARE_MODULE( class_ )
+
+#define FT_DEFINE_RENDERER( \
+ class_, \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_, \
+ glyph_format_, \
+ render_glyph_, \
+ transform_glyph_, \
+ get_glyph_cbox_, \
+ set_mode_, \
+ raster_class_ ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_Module_Class* clazz ) \
+ { \
+ FT_Renderer_Class* rclazz = (FT_Renderer_Class*)clazz; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ class_ ## _pic_free( library ); \
+ if ( rclazz ) \
+ FT_FREE( rclazz ); \
+ } \
+ \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_Module_Class** output_class ) \
+ { \
+ FT_Renderer_Class* clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) ) ) \
+ return error; \
+ \
+ error = class_ ## _pic_init( library ); \
+ if ( error ) \
+ { \
+ FT_FREE( clazz ); \
+ return error; \
+ } \
+ \
+ FT_DEFINE_ROOT_MODULE( flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ \
+ clazz->glyph_format = glyph_format_; \
+ \
+ clazz->render_glyph = render_glyph_; \
+ clazz->transform_glyph = transform_glyph_; \
+ clazz->get_glyph_cbox = get_glyph_cbox_; \
+ clazz->set_mode = set_mode_; \
+ \
+ clazz->raster_class = raster_class_; \
+ \
+ *output_class = (FT_Module_Class*)clazz; \
+ \
+ return FT_Err_Ok; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+ /* PIC support macros for ftmodapi.h **/
#ifdef FT_CONFIG_OPTION_PIC
@@ -1262,6 +1365,7 @@ FT_BEGIN_HEADER
#endif
+
/*************************************************************************/
/* */
/* <Macro> */
@@ -1269,28 +1373,31 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* Used to create a forward declaration of a */
- /* FT_Module_Class stract instance. */
+ /* FT_Module_Class struct instance. */
/* */
/* <Macro> */
/* FT_DEFINE_MODULE */
/* */
/* <Description> */
- /* Used to initialize an instance of FT_Module_Class struct. */
+ /* Used to initialize an instance of an FT_Module_Class struct. */
/* */
- /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
- /* to called with a pointer where the allocated stracture is returned.*/
- /* And when it is no longer needed a Destroy function needs */
- /* to be called to release that allocation. */
- /* fcinit.c (ft_create_default_module_classes) already contains */
+ /* When FT_CONFIG_OPTION_PIC is defined a `create' funtion needs to */
+ /* be called with a pointer where the allocated structure is */
+ /* returned. And when it is no longer needed a `destroy' function */
+ /* needs to be called to release that allocation. */
+ /* `fcinit.c' (ft_create_default_module_classes) already contains */
/* a mechanism to call these functions for the default modules */
- /* described in ftmodule.h */
+ /* described in `ftmodule.h'. */
/* */
- /* Notice that the created Create and Destroy functions call */
- /* pic_init and pic_free function to allow you to manually allocate */
- /* and initialize any additional global data, like module specific */
+ /* Notice that the created `create' and `destroy' functions call */
+ /* `pic_init' and `pic_free' to allow you to manually allocate and */
+ /* initialize any additional global data, like a module specific */
/* interface, and put them in the global pic container defined in */
- /* ftpic.h. if you don't need them just implement the functions as */
- /* empty to resolve the link error. */
+ /* `ftpic.h'. If you don't need them just implement the functions as */
+ /* empty to resolve the link error. Also the `pic_init' and */
+ /* `pic_free' functions should be declared in `pic.h', to be referred */
+ /* by the module definition calling `FT_DEFINE_MODULE' in the */
+ /* following. */
/* */
/* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
/* allocated in the global scope (or the scope where the macro */
@@ -1300,122 +1407,160 @@ FT_BEGIN_HEADER
/* FT_DEFINE_ROOT_MODULE */
/* */
/* <Description> */
- /* Used to initialize an instance of FT_Module_Class struct inside */
- /* another stract that contains it or in a function that initializes */
- /* that containing stract */
+ /* Used to initialize an instance of an FT_Module_Class struct inside */
+ /* another struct that contains it or in a function that initializes */
+ /* that containing struct. */
/* */
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DECLARE_MODULE(class_) \
- FT_CALLBACK_TABLE \
- const FT_Module_Class class_; \
-
-#define FT_DEFINE_ROOT_MODULE(flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_) \
- { \
- flags_, \
- size_, \
- \
- name_, \
- version_, \
- requires_, \
- \
- interface_, \
- \
- init_, \
- done_, \
- get_interface_, \
+#define FT_DECLARE_MODULE( class_ ) \
+ FT_CALLBACK_TABLE \
+ const FT_Module_Class class_;
+
+#define FT_DEFINE_ROOT_MODULE( \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ { \
+ flags_, \
+ size_, \
+ \
+ name_, \
+ version_, \
+ requires_, \
+ \
+ interface_, \
+ \
+ init_, \
+ done_, \
+ get_interface_, \
},
-#define FT_DEFINE_MODULE(class_, flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_) \
- FT_CALLBACK_TABLE_DEF \
- const FT_Module_Class class_ = \
- { \
- flags_, \
- size_, \
- \
- name_, \
- version_, \
- requires_, \
- \
- interface_, \
- \
- init_, \
- done_, \
- get_interface_, \
+#define FT_DEFINE_MODULE( \
+ class_, \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Module_Class class_ = \
+ { \
+ flags_, \
+ size_, \
+ \
+ name_, \
+ version_, \
+ requires_, \
+ \
+ interface_, \
+ \
+ init_, \
+ done_, \
+ get_interface_, \
};
#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DECLARE_MODULE(class_) \
- FT_Error FT_Create_Class_##class_( FT_Library library, \
- FT_Module_Class** output_class ); \
- void FT_Destroy_Class_##class_( FT_Library library, \
- FT_Module_Class* clazz );
-
-#define FT_DEFINE_ROOT_MODULE(flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_) \
- clazz->root.module_flags = flags_; \
- clazz->root.module_size = size_; \
- clazz->root.module_name = name_; \
- clazz->root.module_version = version_; \
- clazz->root.module_requires = requires_; \
- \
- clazz->root.module_interface = interface_; \
- \
- clazz->root.module_init = init_; \
- clazz->root.module_done = done_; \
- clazz->root.get_interface = get_interface_;
-
-#define FT_DEFINE_MODULE(class_, flags_, size_, name_, version_, requires_, \
- interface_, init_, done_, get_interface_) \
- void class_##_pic_free( FT_Library library ); \
- FT_Error class_##_pic_init( FT_Library library ); \
- \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_Module_Class* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- class_##_pic_free( library ); \
- if ( clazz ) \
- FT_FREE( clazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_Module_Class** output_class ) \
- { \
- FT_Memory memory = library->memory; \
- FT_Module_Class* clazz; \
- FT_Error error; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz) ) ) \
- return error; \
- error = class_##_pic_init( library ); \
- if(error) \
- { \
- FT_FREE( clazz ); \
- return error; \
- } \
- \
- clazz->module_flags = flags_; \
- clazz->module_size = size_; \
- clazz->module_name = name_; \
- clazz->module_version = version_; \
- clazz->module_requires = requires_; \
- \
- clazz->module_interface = interface_; \
- \
- clazz->module_init = init_; \
- clazz->module_done = done_; \
- clazz->get_interface = get_interface_; \
- \
- *output_class = clazz; \
- return FT_Err_Ok; \
- }
+#define FT_DECLARE_MODULE( class_ ) \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_Module_Class** output_class ); \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_Module_Class* clazz );
+
+#define FT_DEFINE_ROOT_MODULE( \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ clazz->root.module_flags = flags_; \
+ clazz->root.module_size = size_; \
+ clazz->root.module_name = name_; \
+ clazz->root.module_version = version_; \
+ clazz->root.module_requires = requires_; \
+ \
+ clazz->root.module_interface = interface_; \
+ \
+ clazz->root.module_init = init_; \
+ clazz->root.module_done = done_; \
+ clazz->root.get_interface = get_interface_;
+
+#define FT_DEFINE_MODULE( \
+ class_, \
+ flags_, \
+ size_, \
+ name_, \
+ version_, \
+ requires_, \
+ interface_, \
+ init_, \
+ done_, \
+ get_interface_ ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_Module_Class* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ class_ ## _pic_free( library ); \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_Module_Class** output_class ) \
+ { \
+ FT_Memory memory = library->memory; \
+ FT_Module_Class* clazz = NULL; \
+ FT_Error error; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) ) ) \
+ return error; \
+ error = class_ ## _pic_init( library ); \
+ if ( error ) \
+ { \
+ FT_FREE( clazz ); \
+ return error; \
+ } \
+ \
+ clazz->module_flags = flags_; \
+ clazz->module_size = size_; \
+ clazz->module_name = name_; \
+ clazz->module_version = version_; \
+ clazz->module_requires = requires_; \
+ \
+ clazz->module_interface = interface_; \
+ \
+ clazz->module_init = init_; \
+ clazz->module_done = done_; \
+ clazz->get_interface = get_interface_; \
+ \
+ *output_class = clazz; \
+ \
+ return FT_Err_Ok; \
+ }
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/include/freetype/internal/ftpic.h b/3party/freetype/include/freetype/internal/ftpic.h
index 1b31957d70..485ce7a24e 100644
--- a/3party/freetype/include/freetype/internal/ftpic.h
+++ b/3party/freetype/include/freetype/internal/ftpic.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services (declaration). */
/* */
-/* Copyright 2009 by */
+/* Copyright 2009, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -26,34 +26,38 @@
#ifndef __FTPIC_H__
#define __FTPIC_H__
-
+
FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
- typedef struct FT_PIC_Container_
+ typedef struct FT_PIC_Container_
{
/* pic containers for base */
- void* base;
+ void* base;
+
/* pic containers for modules */
- void* autofit;
- void* cff;
- void* pshinter;
- void* psnames;
- void* raster;
- void* sfnt;
- void* smooth;
- void* truetype;
+ void* autofit;
+ void* cff;
+ void* pshinter;
+ void* psnames;
+ void* raster;
+ void* sfnt;
+ void* smooth;
+ void* truetype;
+
} FT_PIC_Container;
- /* Initialize the various function tables, structs, etc. stored in the container. */
+
+ /* Initialize the various function tables, structs, etc. */
+ /* stored in the container. */
FT_BASE( FT_Error )
- ft_pic_container_init( FT_Library library );
+ ft_pic_container_init( FT_Library library );
/* Destroy the contents of the container. */
FT_BASE( void )
- ft_pic_container_destroy( FT_Library library );
+ ft_pic_container_destroy( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/include/freetype/internal/ftrfork.h b/3party/freetype/include/freetype/internal/ftrfork.h
index aa573c8705..6307f2d0c5 100644
--- a/3party/freetype/include/freetype/internal/ftrfork.h
+++ b/3party/freetype/include/freetype/internal/ftrfork.h
@@ -4,7 +4,7 @@
/* */
/* Embedded resource forks accessor (specification). */
/* */
-/* Copyright 2004, 2006, 2007 by */
+/* Copyright 2004, 2006, 2007, 2012 by */
/* Masatake YAMATO and Redhat K.K. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -48,6 +48,68 @@ FT_BEGIN_HEADER
} FT_RFork_Ref;
+#ifdef FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK
+ typedef FT_Error
+ (*ft_raccess_guess_func)( FT_Library library,
+ FT_Stream stream,
+ char *base_file_name,
+ char **result_file_name,
+ FT_Long *result_offset );
+
+ typedef enum FT_RFork_Rule_ {
+ FT_RFork_Rule_invalid = -2,
+ FT_RFork_Rule_uknown, /* -1 */
+ FT_RFork_Rule_apple_double,
+ FT_RFork_Rule_apple_single,
+ FT_RFork_Rule_darwin_ufs_export,
+ FT_RFork_Rule_darwin_newvfs,
+ FT_RFork_Rule_darwin_hfsplus,
+ FT_RFork_Rule_vfat,
+ FT_RFork_Rule_linux_cap,
+ FT_RFork_Rule_linux_double,
+ FT_RFork_Rule_linux_netatalk
+ } FT_RFork_Rule;
+
+ /* For fast translation between rule index and rule type,
+ * the macros FT_RFORK_xxx should be kept consistent with
+ * the raccess_guess_funcs table
+ */
+ typedef struct ft_raccess_guess_rec_ {
+ ft_raccess_guess_func func;
+ FT_RFork_Rule type;
+ } ft_raccess_guess_rec;
+
+#ifndef FT_CONFIG_OPTION_PIC
+
+ /* this array is a storage in non-PIC mode, so ; is needed in END */
+#define CONST_FT_RFORK_RULE_ARRAY_BEGIN( name, type ) \
+ const type name[] = {
+#define CONST_FT_RFORK_RULE_ARRAY_ENTRY( func_suffix, type_suffix ) \
+ { raccess_guess_ ## func_suffix, \
+ FT_RFork_Rule_ ## type_suffix },
+#define CONST_FT_RFORK_RULE_ARRAY_END };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+ /* this array is a function in PIC mode, so no ; is needed in END */
+#define CONST_FT_RFORK_RULE_ARRAY_BEGIN( name, type ) \
+ void \
+ FT_Init_ ## name( type* storage ) \
+ { \
+ type* local = storage; \
+ \
+ \
+ int i = 0;
+#define CONST_FT_RFORK_RULE_ARRAY_ENTRY( func_suffix, type_suffix ) \
+ local[i].func = raccess_guess_ ## func_suffix; \
+ local[i].type = FT_RFork_Rule_ ## type_suffix; \
+ i++;
+#define CONST_FT_RFORK_RULE_ARRAY_END }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+#endif /* FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK */
+
/*************************************************************************/
/* */
diff --git a/3party/freetype/include/freetype/internal/ftserv.h b/3party/freetype/include/freetype/internal/ftserv.h
index 569b9f7e0e..1d4ded54ff 100644
--- a/3party/freetype/include/freetype/internal/ftserv.h
+++ b/3party/freetype/include/freetype/internal/ftserv.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType services (specification only). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 2003-2007, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -92,6 +92,7 @@ FT_BEGIN_HEADER
#endif /* !C++ */
+
/*
* @macro:
* FT_FACE_FIND_GLOBAL_SERVICE
@@ -163,298 +164,371 @@ FT_BEGIN_HEADER
typedef const FT_ServiceDescRec* FT_ServiceDesc;
+
/*************************************************************************/
/* */
/* <Macro> */
- /* FT_DEFINE_SERVICEDESCREC1 .. FT_DEFINE_SERVICEDESCREC6 */
+ /* FT_DEFINE_SERVICEDESCREC1 */
+ /* FT_DEFINE_SERVICEDESCREC2 */
+ /* FT_DEFINE_SERVICEDESCREC3 */
+ /* FT_DEFINE_SERVICEDESCREC4 */
+ /* FT_DEFINE_SERVICEDESCREC5 */
+ /* FT_DEFINE_SERVICEDESCREC6 */
/* */
/* <Description> */
- /* Used to initialize an array of FT_ServiceDescRec structs. */
+ /* Used to initialize an array of FT_ServiceDescRec structures. */
/* */
- /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
- /* to called with a pointer where the allocated array is returned. */
- /* And when it is no longer needed a Destroy function needs */
- /* to be called to release that allocation. */
+ /* When FT_CONFIG_OPTION_PIC is defined a `create' function needs to */
+ /* be called with a pointer to return an allocated array. As soon as */
+ /* it is no longer needed, a `destroy' function needs to be called to */
+ /* release that allocation. */
/* */
- /* These functions should be manyally called from the pic_init and */
- /* pic_free functions of your module (see FT_DEFINE_MODULE) */
+ /* These functions should be manually called from the `pic_init' and */
+ /* `pic_free' functions of your module (see FT_DEFINE_MODULE). */
/* */
/* When FT_CONFIG_OPTION_PIC is not defined the array will be */
- /* allocated in the global scope (or the scope where the macro */
- /* is used). */
+ /* allocated in the global scope (or the scope where the macro is */
+ /* used). */
/* */
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICEDESCREC1(class_, serv_id_1, serv_data_1) \
- static const FT_ServiceDescRec class_[] = \
- { \
- {serv_id_1, serv_data_1}, \
- {NULL, NULL} \
+#define FT_DEFINE_SERVICEDESCREC1( class_, \
+ serv_id_1, serv_data_1 ) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ { serv_id_1, serv_data_1 }, \
+ { NULL, NULL } \
};
-#define FT_DEFINE_SERVICEDESCREC2(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2) \
- static const FT_ServiceDescRec class_[] = \
- { \
- {serv_id_1, serv_data_1}, \
- {serv_id_2, serv_data_2}, \
- {NULL, NULL} \
+
+#define FT_DEFINE_SERVICEDESCREC2( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2 ) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ { serv_id_1, serv_data_1 }, \
+ { serv_id_2, serv_data_2 }, \
+ { NULL, NULL } \
};
-#define FT_DEFINE_SERVICEDESCREC3(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3) \
- static const FT_ServiceDescRec class_[] = \
- { \
- {serv_id_1, serv_data_1}, \
- {serv_id_2, serv_data_2}, \
- {serv_id_3, serv_data_3}, \
- {NULL, NULL} \
+
+#define FT_DEFINE_SERVICEDESCREC3( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3 ) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ { serv_id_1, serv_data_1 }, \
+ { serv_id_2, serv_data_2 }, \
+ { serv_id_3, serv_data_3 }, \
+ { NULL, NULL } \
};
-#define FT_DEFINE_SERVICEDESCREC4(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
- serv_id_4, serv_data_4) \
- static const FT_ServiceDescRec class_[] = \
- { \
- {serv_id_1, serv_data_1}, \
- {serv_id_2, serv_data_2}, \
- {serv_id_3, serv_data_3}, \
- {serv_id_4, serv_data_4}, \
- {NULL, NULL} \
+
+#define FT_DEFINE_SERVICEDESCREC4( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4 ) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ { serv_id_1, serv_data_1 }, \
+ { serv_id_2, serv_data_2 }, \
+ { serv_id_3, serv_data_3 }, \
+ { serv_id_4, serv_data_4 }, \
+ { NULL, NULL } \
};
-#define FT_DEFINE_SERVICEDESCREC5(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
- serv_id_4, serv_data_4, serv_id_5, serv_data_5) \
- static const FT_ServiceDescRec class_[] = \
- { \
- {serv_id_1, serv_data_1}, \
- {serv_id_2, serv_data_2}, \
- {serv_id_3, serv_data_3}, \
- {serv_id_4, serv_data_4}, \
- {serv_id_5, serv_data_5}, \
- {NULL, NULL} \
+
+#define FT_DEFINE_SERVICEDESCREC5( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4, \
+ serv_id_5, serv_data_5 ) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ { serv_id_1, serv_data_1 }, \
+ { serv_id_2, serv_data_2 }, \
+ { serv_id_3, serv_data_3 }, \
+ { serv_id_4, serv_data_4 }, \
+ { serv_id_5, serv_data_5 }, \
+ { NULL, NULL } \
};
-#define FT_DEFINE_SERVICEDESCREC6(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
- serv_id_4, serv_data_4, serv_id_5, serv_data_5, \
- serv_id_6, serv_data_6) \
- static const FT_ServiceDescRec class_[] = \
- { \
- {serv_id_1, serv_data_1}, \
- {serv_id_2, serv_data_2}, \
- {serv_id_3, serv_data_3}, \
- {serv_id_4, serv_data_4}, \
- {serv_id_5, serv_data_5}, \
- {serv_id_6, serv_data_6}, \
- {NULL, NULL} \
+
+#define FT_DEFINE_SERVICEDESCREC6( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4, \
+ serv_id_5, serv_data_5, \
+ serv_id_6, serv_data_6 ) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ { serv_id_1, serv_data_1 }, \
+ { serv_id_2, serv_data_2 }, \
+ { serv_id_3, serv_data_3 }, \
+ { serv_id_4, serv_data_4 }, \
+ { serv_id_5, serv_data_5 }, \
+ { serv_id_6, serv_data_6 }, \
+ { NULL, NULL } \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DEFINE_SERVICEDESCREC1(class_, serv_id_1, serv_data_1) \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_ServiceDescRec* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- if ( clazz ) \
- FT_FREE( clazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_ServiceDescRec** output_class) \
- { \
- FT_ServiceDescRec* clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz)*2 ) ) \
- return error; \
- clazz[0].serv_id = serv_id_1; \
- clazz[0].serv_data = serv_data_1; \
- clazz[1].serv_id = NULL; \
- clazz[1].serv_data = NULL; \
- *output_class = clazz; \
- return FT_Err_Ok; \
- }
-
-#define FT_DEFINE_SERVICEDESCREC2(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2) \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_ServiceDescRec* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- if ( clazz ) \
- FT_FREE( clazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_ServiceDescRec** output_class) \
- { \
- FT_ServiceDescRec* clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz)*3 ) ) \
- return error; \
- clazz[0].serv_id = serv_id_1; \
- clazz[0].serv_data = serv_data_1; \
- clazz[1].serv_id = serv_id_2; \
- clazz[1].serv_data = serv_data_2; \
- clazz[2].serv_id = NULL; \
- clazz[2].serv_data = NULL; \
- *output_class = clazz; \
- return FT_Err_Ok; \
- }
-
-#define FT_DEFINE_SERVICEDESCREC3(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3) \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_ServiceDescRec* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- if ( clazz ) \
- FT_FREE( clazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_ServiceDescRec** output_class) \
- { \
- FT_ServiceDescRec* clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz)*4 ) ) \
- return error; \
- clazz[0].serv_id = serv_id_1; \
- clazz[0].serv_data = serv_data_1; \
- clazz[1].serv_id = serv_id_2; \
- clazz[1].serv_data = serv_data_2; \
- clazz[2].serv_id = serv_id_3; \
- clazz[2].serv_data = serv_data_3; \
- clazz[3].serv_id = NULL; \
- clazz[3].serv_data = NULL; \
- *output_class = clazz; \
- return FT_Err_Ok; \
- }
-
-#define FT_DEFINE_SERVICEDESCREC4(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
- serv_id_4, serv_data_4) \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_ServiceDescRec* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- if ( clazz ) \
- FT_FREE( clazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_ServiceDescRec** output_class) \
- { \
- FT_ServiceDescRec* clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz)*5 ) ) \
- return error; \
- clazz[0].serv_id = serv_id_1; \
- clazz[0].serv_data = serv_data_1; \
- clazz[1].serv_id = serv_id_2; \
- clazz[1].serv_data = serv_data_2; \
- clazz[2].serv_id = serv_id_3; \
- clazz[2].serv_data = serv_data_3; \
- clazz[3].serv_id = serv_id_4; \
- clazz[3].serv_data = serv_data_4; \
- clazz[4].serv_id = NULL; \
- clazz[4].serv_data = NULL; \
- *output_class = clazz; \
- return FT_Err_Ok; \
- }
-
-#define FT_DEFINE_SERVICEDESCREC5(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3, serv_id_4, \
- serv_data_4, serv_id_5, serv_data_5) \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_ServiceDescRec* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- if ( clazz ) \
- FT_FREE( clazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_ServiceDescRec** output_class) \
- { \
- FT_ServiceDescRec* clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz)*6 ) ) \
- return error; \
- clazz[0].serv_id = serv_id_1; \
- clazz[0].serv_data = serv_data_1; \
- clazz[1].serv_id = serv_id_2; \
- clazz[1].serv_data = serv_data_2; \
- clazz[2].serv_id = serv_id_3; \
- clazz[2].serv_data = serv_data_3; \
- clazz[3].serv_id = serv_id_4; \
- clazz[3].serv_data = serv_data_4; \
- clazz[4].serv_id = serv_id_5; \
- clazz[4].serv_data = serv_data_5; \
- clazz[5].serv_id = NULL; \
- clazz[5].serv_data = NULL; \
- *output_class = clazz; \
- return FT_Err_Ok; \
- }
-
-#define FT_DEFINE_SERVICEDESCREC6(class_, serv_id_1, serv_data_1, \
- serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
- serv_id_4, serv_data_4, serv_id_5, serv_data_5, \
- serv_id_6, serv_data_6) \
- void \
- FT_Destroy_Class_##class_( FT_Library library, \
- FT_ServiceDescRec* clazz ) \
- { \
- FT_Memory memory = library->memory; \
- if ( clazz ) \
- FT_FREE( clazz ); \
- } \
- \
- FT_Error \
- FT_Create_Class_##class_( FT_Library library, \
- FT_ServiceDescRec** output_class) \
- { \
- FT_ServiceDescRec* clazz; \
- FT_Error error; \
- FT_Memory memory = library->memory; \
- \
- if ( FT_ALLOC( clazz, sizeof(*clazz)*7 ) ) \
- return error; \
- clazz[0].serv_id = serv_id_1; \
- clazz[0].serv_data = serv_data_1; \
- clazz[1].serv_id = serv_id_2; \
- clazz[1].serv_data = serv_data_2; \
- clazz[2].serv_id = serv_id_3; \
- clazz[2].serv_data = serv_data_3; \
- clazz[3].serv_id = serv_id_4; \
- clazz[3].serv_data = serv_data_4; \
- clazz[4].serv_id = serv_id_5; \
- clazz[4].serv_data = serv_data_5; \
- clazz[5].serv_id = serv_id_6; \
- clazz[5].serv_data = serv_data_6; \
- clazz[6].serv_id = NULL; \
- clazz[6].serv_data = NULL; \
- *output_class = clazz; \
- return FT_Err_Ok; \
- }
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICEDESCREC1( class_, \
+ serv_id_1, serv_data_1 ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec** output_class ) \
+ { \
+ FT_ServiceDescRec* clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) * 2 ) ) \
+ return error; \
+ \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = NULL; \
+ clazz[1].serv_data = NULL; \
+ \
+ *output_class = clazz; \
+ \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC2( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2 ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec** output_class ) \
+ { \
+ FT_ServiceDescRec* clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) * 3 ) ) \
+ return error; \
+ \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = NULL; \
+ clazz[2].serv_data = NULL; \
+ \
+ *output_class = clazz; \
+ \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC3( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3 ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec** output_class ) \
+ { \
+ FT_ServiceDescRec* clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) * 4 ) ) \
+ return error; \
+ \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = NULL; \
+ clazz[3].serv_data = NULL; \
+ \
+ *output_class = clazz; \
+ \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC4( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4 ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec** output_class ) \
+ { \
+ FT_ServiceDescRec* clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) * 5 ) ) \
+ return error; \
+ \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = serv_id_4; \
+ clazz[3].serv_data = serv_data_4; \
+ clazz[4].serv_id = NULL; \
+ clazz[4].serv_data = NULL; \
+ \
+ *output_class = clazz; \
+ \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC5( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4, \
+ serv_id_5, serv_data_5 ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec** output_class ) \
+ { \
+ FT_ServiceDescRec* clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) * 6 ) ) \
+ return error; \
+ \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = serv_id_4; \
+ clazz[3].serv_data = serv_data_4; \
+ clazz[4].serv_id = serv_id_5; \
+ clazz[4].serv_data = serv_data_5; \
+ clazz[5].serv_id = NULL; \
+ clazz[5].serv_data = NULL; \
+ \
+ *output_class = clazz; \
+ \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC6( class_, \
+ serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, \
+ serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4, \
+ serv_id_5, serv_data_5, \
+ serv_id_6, serv_data_6 ) \
+ void \
+ FT_Destroy_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_ ## class_( FT_Library library, \
+ FT_ServiceDescRec** output_class) \
+ { \
+ FT_ServiceDescRec* clazz = NULL; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ \
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) * 7 ) ) \
+ return error; \
+ \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = serv_id_4; \
+ clazz[3].serv_data = serv_data_4; \
+ clazz[4].serv_id = serv_id_5; \
+ clazz[4].serv_data = serv_data_5; \
+ clazz[5].serv_id = serv_id_6; \
+ clazz[5].serv_data = serv_data_6; \
+ clazz[6].serv_id = NULL; \
+ clazz[6].serv_data = NULL; \
+ \
+ *output_class = clazz; \
+ \
+ return FT_Err_Ok; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/*
* Parse a list of FT_ServiceDescRec descriptors and look for
@@ -505,7 +579,7 @@ FT_BEGIN_HEADER
/*
* A magic number used within the services cache.
*/
-#define FT_SERVICE_UNAVAILABLE ((FT_Pointer)-2) /* magic number */
+#define FT_SERVICE_UNAVAILABLE ((FT_Pointer)~1) /* magic number */
/*
@@ -603,6 +677,7 @@ FT_BEGIN_HEADER
#define FT_SERVICE_POSTSCRIPT_CMAPS_H <freetype/internal/services/svpscmap.h>
#define FT_SERVICE_POSTSCRIPT_INFO_H <freetype/internal/services/svpsinfo.h>
#define FT_SERVICE_POSTSCRIPT_NAME_H <freetype/internal/services/svpostnm.h>
+#define FT_SERVICE_PROPERTIES_H <freetype/internal/services/svprop.h>
#define FT_SERVICE_SFNT_H <freetype/internal/services/svsfnt.h>
#define FT_SERVICE_TRUETYPE_ENGINE_H <freetype/internal/services/svtteng.h>
#define FT_SERVICE_TT_CMAP_H <freetype/internal/services/svttcmap.h>
diff --git a/3party/freetype/include/freetype/internal/fttrace.h b/3party/freetype/include/freetype/internal/fttrace.h
index fbefdbdf49..6e6cb49fad 100644
--- a/3party/freetype/include/freetype/internal/fttrace.h
+++ b/3party/freetype/include/freetype/internal/fttrace.h
@@ -4,7 +4,7 @@
/* */
/* Tracing handling (specification only). */
/* */
-/* Copyright 2002, 2004-2007, 2009, 2011 by */
+/* Copyright 2002, 2004-2007, 2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -73,6 +73,7 @@ FT_TRACE_DEF( t1parse )
/* PostScript helper module `psaux' */
FT_TRACE_DEF( t1decode )
FT_TRACE_DEF( psobjs )
+FT_TRACE_DEF( psconv )
/* PostScript hinting module `pshinter' */
FT_TRACE_DEF( pshrec )
@@ -136,6 +137,8 @@ FT_TRACE_DEF( gxvprop )
FT_TRACE_DEF( gxvlcar )
/* autofit components */
+FT_TRACE_DEF( afmodule )
+FT_TRACE_DEF( afhints )
FT_TRACE_DEF( afcjk )
FT_TRACE_DEF( aflatin )
FT_TRACE_DEF( aflatin2 )
diff --git a/3party/freetype/include/freetype/internal/psaux.h b/3party/freetype/include/freetype/internal/psaux.h
index a96e0dfa86..a46cb6a3dc 100644
--- a/3party/freetype/include/freetype/internal/psaux.h
+++ b/3party/freetype/include/freetype/internal/psaux.h
@@ -5,7 +5,7 @@
/* Auxiliary functions and data structures related to PostScript fonts */
/* (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2008, 2009 by */
+/* Copyright 1996-2004, 2006, 2008, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -225,7 +225,7 @@ FT_BEGIN_HEADER
T1_Field_ParseFunc reader;
FT_UInt offset; /* offset of field in object */
FT_Byte size; /* size of field in bytes */
- FT_UInt array_max; /* maximal number of elements for */
+ FT_UInt array_max; /* maximum number of elements for */
/* array */
FT_UInt count_offset; /* offset of element count for */
/* arrays; must not be zero if in */
@@ -531,7 +531,7 @@ FT_BEGIN_HEADER
/* */
/* max_points :: maximum points in builder outline */
/* */
- /* max_contours :: Maximal number of contours in builder outline. */
+ /* max_contours :: Maximum number of contours in builder outline. */
/* */
/* pos_x :: The horizontal translation (if composite glyph). */
/* */
diff --git a/3party/freetype/include/freetype/internal/pshints.h b/3party/freetype/include/freetype/internal/pshints.h
index 0c357651be..3fb18dc2d5 100644
--- a/3party/freetype/include/freetype/internal/pshints.h
+++ b/3party/freetype/include/freetype/internal/pshints.h
@@ -6,7 +6,7 @@
/* recorders (specification only). These are used to support native */
/* T1/T2 hints in the `type1', `cid', and `cff' font drivers. */
/* */
-/* Copyright 2001, 2002, 2003, 2005, 2006, 2007, 2009 by */
+/* Copyright 2001-2003, 2005-2007, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -679,30 +679,40 @@ FT_BEGIN_HEADER
typedef PSHinter_Interface* PSHinter_Service;
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_PSHINTER_INTERFACE(class_, get_globals_funcs_, \
- get_t1_funcs_, get_t2_funcs_) \
- static const PSHinter_Interface class_ = \
- { \
- get_globals_funcs_, get_t1_funcs_, get_t2_funcs_ \
+#define FT_DEFINE_PSHINTER_INTERFACE( \
+ class_, \
+ get_globals_funcs_, \
+ get_t1_funcs_, \
+ get_t2_funcs_ ) \
+ static const PSHinter_Interface class_ = \
+ { \
+ get_globals_funcs_, \
+ get_t1_funcs_, \
+ get_t2_funcs_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DEFINE_PSHINTER_INTERFACE(class_, get_globals_funcs_, \
- get_t1_funcs_, get_t2_funcs_) \
- void \
- FT_Init_Class_##class_( FT_Library library, \
- PSHinter_Interface* clazz) \
- { \
- FT_UNUSED(library); \
- clazz->get_globals_funcs = get_globals_funcs_; \
- clazz->get_t1_funcs = get_t1_funcs_; \
- clazz->get_t2_funcs = get_t2_funcs_; \
- }
-
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_PSHINTER_INTERFACE( \
+ class_, \
+ get_globals_funcs_, \
+ get_t1_funcs_, \
+ get_t2_funcs_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ PSHinter_Interface* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ clazz->get_globals_funcs = get_globals_funcs_; \
+ clazz->get_t1_funcs = get_t1_funcs_; \
+ clazz->get_t2_funcs = get_t2_funcs_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
FT_END_HEADER
diff --git a/3party/freetype/include/freetype/internal/services/svbdf.h b/3party/freetype/include/freetype/internal/services/svbdf.h
index 9264239146..0974752a79 100644
--- a/3party/freetype/include/freetype/internal/services/svbdf.h
+++ b/3party/freetype/include/freetype/internal/services/svbdf.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType BDF services (specification). */
/* */
-/* Copyright 2003 by */
+/* Copyright 2003, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -45,25 +45,30 @@ FT_BEGIN_HEADER
FT_BDF_GetPropertyFunc get_property;
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_BDFRec(class_, get_charset_id_, get_property_) \
- static const FT_Service_BDFRec class_ = \
+#define FT_DEFINE_SERVICE_BDFRec( class_, \
+ get_charset_id_, \
+ get_property_ ) \
+ static const FT_Service_BDFRec class_ = \
{ \
get_charset_id_, get_property_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_SERVICE_BDFRec(class_, get_charset_id_, get_property_) \
+#define FT_DEFINE_SERVICE_BDFRec( class_, \
+ get_charset_id_, \
+ get_property_ ) \
void \
- FT_Init_Class_##class_( FT_Service_BDFRec* clazz ) \
+ FT_Init_Class_ ## class_( FT_Service_BDFRec* clazz ) \
{ \
clazz->get_charset_id = get_charset_id_; \
- clazz->get_property = get_property_; \
- }
+ clazz->get_property = get_property_; \
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svcid.h b/3party/freetype/include/freetype/internal/services/svcid.h
index 9b874b5e72..6be3f9374d 100644
--- a/3party/freetype/include/freetype/internal/services/svcid.h
+++ b/3party/freetype/include/freetype/internal/services/svcid.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType CID font services (specification). */
/* */
-/* Copyright 2007, 2009 by Derek Clegg, Michael Toftdal. */
+/* Copyright 2007, 2009, 2012 by Derek Clegg, Michael Toftdal. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
@@ -46,30 +46,36 @@ FT_BEGIN_HEADER
FT_CID_GetCIDFromGlyphIndexFunc get_cid_from_glyph_index;
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_CIDREC(class_, get_ros_, \
- get_is_cid_, get_cid_from_glyph_index_ ) \
- static const FT_Service_CIDRec class_ = \
- { \
- get_ros_, get_is_cid_, get_cid_from_glyph_index_ \
+#define FT_DEFINE_SERVICE_CIDREC( class_, \
+ get_ros_, \
+ get_is_cid_, \
+ get_cid_from_glyph_index_ ) \
+ static const FT_Service_CIDRec class_ = \
+ { \
+ get_ros_, get_is_cid_, get_cid_from_glyph_index_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DEFINE_SERVICE_CIDREC(class_, get_ros_, \
- get_is_cid_, get_cid_from_glyph_index_ ) \
- void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_Service_CIDRec* clazz) \
- { \
- FT_UNUSED(library); \
- clazz->get_ros = get_ros_; \
- clazz->get_is_cid = get_is_cid_; \
- clazz->get_cid_from_glyph_index = get_cid_from_glyph_index_; \
- }
-
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_CIDREC( class_, \
+ get_ros_, \
+ get_is_cid_, \
+ get_cid_from_glyph_index_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_Service_CIDRec* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ clazz->get_ros = get_ros_; \
+ clazz->get_is_cid = get_is_cid_; \
+ clazz->get_cid_from_glyph_index = get_cid_from_glyph_index_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svgldict.h b/3party/freetype/include/freetype/internal/services/svgldict.h
index d66a41d5ae..1d12534725 100644
--- a/3party/freetype/include/freetype/internal/services/svgldict.h
+++ b/3party/freetype/include/freetype/internal/services/svgldict.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType glyph dictionary services (specification). */
/* */
-/* Copyright 2003 by */
+/* Copyright 2003, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -51,27 +51,33 @@ FT_BEGIN_HEADER
FT_GlyphDict_NameIndexFunc name_index; /* optional */
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_GLYPHDICTREC(class_, get_name_, name_index_) \
- static const FT_Service_GlyphDictRec class_ = \
+#define FT_DEFINE_SERVICE_GLYPHDICTREC( class_, \
+ get_name_, \
+ name_index_) \
+ static const FT_Service_GlyphDictRec class_ = \
{ \
get_name_, name_index_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_SERVICE_GLYPHDICTREC(class_, get_name_, name_index_) \
+#define FT_DEFINE_SERVICE_GLYPHDICTREC( class_, \
+ get_name_, \
+ name_index_) \
void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_Service_GlyphDictRec* clazz) \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_Service_GlyphDictRec* clazz ) \
{ \
- FT_UNUSED(library); \
- clazz->get_name = get_name_; \
+ FT_UNUSED( library ); \
+ \
+ clazz->get_name = get_name_; \
clazz->name_index = name_index_; \
- }
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svmm.h b/3party/freetype/include/freetype/internal/services/svmm.h
index 66e1da22f1..b08a663d66 100644
--- a/3party/freetype/include/freetype/internal/services/svmm.h
+++ b/3party/freetype/include/freetype/internal/services/svmm.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType Multiple Masters and GX var services (specification). */
/* */
-/* Copyright 2003, 2004 by */
+/* Copyright 2003, 2004, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -68,30 +68,39 @@ FT_BEGIN_HEADER
FT_Set_Var_Design_Func set_var_design;
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_MULTIMASTERSREC(class_, get_mm_, set_mm_design_, \
- set_mm_blend_, get_mm_var_, set_var_design_) \
- static const FT_Service_MultiMastersRec class_ = \
- { \
- get_mm_, set_mm_design_, set_mm_blend_, get_mm_var_, set_var_design_ \
+#define FT_DEFINE_SERVICE_MULTIMASTERSREC( class_, \
+ get_mm_, \
+ set_mm_design_, \
+ set_mm_blend_, \
+ get_mm_var_, \
+ set_var_design_ ) \
+ static const FT_Service_MultiMastersRec class_ = \
+ { \
+ get_mm_, set_mm_design_, set_mm_blend_, get_mm_var_, set_var_design_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DEFINE_SERVICE_MULTIMASTERSREC(class_, get_mm_, set_mm_design_, \
- set_mm_blend_, get_mm_var_, set_var_design_) \
- void \
- FT_Init_Class_##class_( FT_Service_MultiMastersRec* clazz ) \
- { \
- clazz->get_mm = get_mm_; \
- clazz->set_mm_design = set_mm_design_; \
- clazz->set_mm_blend = set_mm_blend_; \
- clazz->get_mm_var = get_mm_var_; \
- clazz->set_var_design = set_var_design_; \
- }
-
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_MULTIMASTERSREC( class_, \
+ get_mm_, \
+ set_mm_design_, \
+ set_mm_blend_, \
+ get_mm_var_, \
+ set_var_design_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Service_MultiMastersRec* clazz ) \
+ { \
+ clazz->get_mm = get_mm_; \
+ clazz->set_mm_design = set_mm_design_; \
+ clazz->set_mm_blend = set_mm_blend_; \
+ clazz->get_mm_var = get_mm_var_; \
+ clazz->set_var_design = set_var_design_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svpostnm.h b/3party/freetype/include/freetype/internal/services/svpostnm.h
index 106c54f853..a76b4fe057 100644
--- a/3party/freetype/include/freetype/internal/services/svpostnm.h
+++ b/3party/freetype/include/freetype/internal/services/svpostnm.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType PostScript name services (specification). */
/* */
-/* Copyright 2003, 2007 by */
+/* Copyright 2003, 2007, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -46,26 +46,28 @@ FT_BEGIN_HEADER
FT_PsName_GetFunc get_ps_font_name;
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_PSFONTNAMEREC(class_, get_ps_font_name_) \
- static const FT_Service_PsFontNameRec class_ = \
- { \
- get_ps_font_name_ \
+#define FT_DEFINE_SERVICE_PSFONTNAMEREC( class_, get_ps_font_name_ ) \
+ static const FT_Service_PsFontNameRec class_ = \
+ { \
+ get_ps_font_name_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_SERVICE_PSFONTNAMEREC(class_, get_ps_font_name_) \
- void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_Service_PsFontNameRec* clazz) \
- { \
- FT_UNUSED(library); \
- clazz->get_ps_font_name = get_ps_font_name_; \
- }
+#define FT_DEFINE_SERVICE_PSFONTNAMEREC( class_, get_ps_font_name_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_Service_PsFontNameRec* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ clazz->get_ps_font_name = get_ps_font_name_; \
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svprop.h b/3party/freetype/include/freetype/internal/services/svprop.h
new file mode 100644
index 0000000000..22da0bbc69
--- /dev/null
+++ b/3party/freetype/include/freetype/internal/services/svprop.h
@@ -0,0 +1,81 @@
+/***************************************************************************/
+/* */
+/* svprop.h */
+/* */
+/* The FreeType property service (specification). */
+/* */
+/* Copyright 2012 by */
+/* David Turner, Robert Wilhelm, and Werner Lemberg. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __SVPROP_H__
+#define __SVPROP_H__
+
+
+FT_BEGIN_HEADER
+
+
+#define FT_SERVICE_ID_PROPERTIES "properties"
+
+
+ typedef FT_Error
+ (*FT_Properties_SetFunc)( FT_Module module,
+ const char* property_name,
+ const void* value );
+
+ typedef FT_Error
+ (*FT_Properties_GetFunc)( FT_Module module,
+ const char* property_name,
+ void* value );
+
+
+ FT_DEFINE_SERVICE( Properties )
+ {
+ FT_Properties_SetFunc set_property;
+ FT_Properties_GetFunc get_property;
+ };
+
+
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_PROPERTIESREC( class_, \
+ set_property_, \
+ get_property_ ) \
+ static const FT_Service_PropertiesRec class_ = \
+ { \
+ set_property_, \
+ get_property_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_PROPERTIESREC( class_, \
+ set_property_, \
+ get_property_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Service_PropertiesRec* clazz ) \
+ { \
+ clazz->set_property = set_property_; \
+ clazz->get_property = get_property_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+
+FT_END_HEADER
+
+
+#endif /* __SVPROP_H__ */
+
+
+/* END */
diff --git a/3party/freetype/include/freetype/internal/services/svpscmap.h b/3party/freetype/include/freetype/internal/services/svpscmap.h
index 961030cc39..030948ea64 100644
--- a/3party/freetype/include/freetype/internal/services/svpscmap.h
+++ b/3party/freetype/include/freetype/internal/services/svpscmap.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType PostScript charmap service (specification). */
/* */
-/* Copyright 2003, 2006 by */
+/* Copyright 2003, 2006, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -120,37 +120,50 @@ FT_BEGIN_HEADER
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_PSCMAPSREC(class_, unicode_value_, unicodes_init_, \
- unicodes_char_index_, unicodes_char_next_, macintosh_name_, \
- adobe_std_strings_, adobe_std_encoding_, adobe_expert_encoding_) \
- static const FT_Service_PsCMapsRec class_ = \
- { \
- unicode_value_, unicodes_init_, \
- unicodes_char_index_, unicodes_char_next_, macintosh_name_, \
- adobe_std_strings_, adobe_std_encoding_, adobe_expert_encoding_ \
+#define FT_DEFINE_SERVICE_PSCMAPSREC( class_, \
+ unicode_value_, \
+ unicodes_init_, \
+ unicodes_char_index_, \
+ unicodes_char_next_, \
+ macintosh_name_, \
+ adobe_std_strings_, \
+ adobe_std_encoding_, \
+ adobe_expert_encoding_ ) \
+ static const FT_Service_PsCMapsRec class_ = \
+ { \
+ unicode_value_, unicodes_init_, \
+ unicodes_char_index_, unicodes_char_next_, macintosh_name_, \
+ adobe_std_strings_, adobe_std_encoding_, adobe_expert_encoding_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DEFINE_SERVICE_PSCMAPSREC(class_, unicode_value_, unicodes_init_, \
- unicodes_char_index_, unicodes_char_next_, macintosh_name_, \
- adobe_std_strings_, adobe_std_encoding_, adobe_expert_encoding_) \
- void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_Service_PsCMapsRec* clazz) \
- { \
- FT_UNUSED(library); \
- clazz->unicode_value = unicode_value_; \
- clazz->unicodes_init = unicodes_init_; \
- clazz->unicodes_char_index = unicodes_char_index_; \
- clazz->unicodes_char_next = unicodes_char_next_; \
- clazz->macintosh_name = macintosh_name_; \
- clazz->adobe_std_strings = adobe_std_strings_; \
- clazz->adobe_std_encoding = adobe_std_encoding_; \
- clazz->adobe_expert_encoding = adobe_expert_encoding_; \
- }
-
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_PSCMAPSREC( class_, \
+ unicode_value_, \
+ unicodes_init_, \
+ unicodes_char_index_, \
+ unicodes_char_next_, \
+ macintosh_name_, \
+ adobe_std_strings_, \
+ adobe_std_encoding_, \
+ adobe_expert_encoding_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_Service_PsCMapsRec* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ clazz->unicode_value = unicode_value_; \
+ clazz->unicodes_init = unicodes_init_; \
+ clazz->unicodes_char_index = unicodes_char_index_; \
+ clazz->unicodes_char_next = unicodes_char_next_; \
+ clazz->macintosh_name = macintosh_name_; \
+ clazz->adobe_std_strings = adobe_std_strings_; \
+ clazz->adobe_std_encoding = adobe_std_encoding_; \
+ clazz->adobe_expert_encoding = adobe_expert_encoding_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svpsinfo.h b/3party/freetype/include/freetype/internal/services/svpsinfo.h
index 84d6a78a1e..4bfb506711 100644
--- a/3party/freetype/include/freetype/internal/services/svpsinfo.h
+++ b/3party/freetype/include/freetype/internal/services/svpsinfo.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType PostScript info service (specification). */
/* */
-/* Copyright 2003, 2004, 2009, 2011 by */
+/* Copyright 2003, 2004, 2009, 2011, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -38,7 +38,7 @@ FT_BEGIN_HEADER
PS_FontExtraRec* afont_extra );
typedef FT_Int
- (*PS_HasGlyphNamesFunc)( FT_Face face );
+ (*PS_HasGlyphNamesFunc)( FT_Face face );
typedef FT_Error
(*PS_GetFontPrivateFunc)( FT_Face face,
@@ -61,35 +61,43 @@ FT_BEGIN_HEADER
PS_GetFontValueFunc ps_get_font_value;
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_PSINFOREC(class_, get_font_info_, \
- ps_get_font_extra_, has_glyph_names_, get_font_private_, \
- get_font_value_) \
- static const FT_Service_PsInfoRec class_ = \
+#define FT_DEFINE_SERVICE_PSINFOREC( class_, \
+ get_font_info_, \
+ ps_get_font_extra_, \
+ has_glyph_names_, \
+ get_font_private_, \
+ get_font_value_ ) \
+ static const FT_Service_PsInfoRec class_ = \
{ \
get_font_info_, ps_get_font_extra_, has_glyph_names_, \
get_font_private_, get_font_value_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_SERVICE_PSINFOREC(class_, get_font_info_, \
- ps_get_font_extra_, has_glyph_names_, get_font_private_, \
- get_font_value_) \
+#define FT_DEFINE_SERVICE_PSINFOREC( class_, \
+ get_font_info_, \
+ ps_get_font_extra_, \
+ has_glyph_names_, \
+ get_font_private_, \
+ get_font_value_ ) \
void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_Service_PsInfoRec* clazz) \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_Service_PsInfoRec* clazz ) \
{ \
- FT_UNUSED(library); \
- clazz->ps_get_font_info = get_font_info_; \
- clazz->ps_get_font_extra = ps_get_font_extra_; \
- clazz->ps_has_glyph_names = has_glyph_names_; \
+ FT_UNUSED( library ); \
+ \
+ clazz->ps_get_font_info = get_font_info_; \
+ clazz->ps_get_font_extra = ps_get_font_extra_; \
+ clazz->ps_has_glyph_names = has_glyph_names_; \
clazz->ps_get_font_private = get_font_private_; \
- clazz->ps_get_font_value = get_font_value_; \
- }
+ clazz->ps_get_font_value = get_font_value_; \
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svsfnt.h b/3party/freetype/include/freetype/internal/services/svsfnt.h
index 30bb1620fe..d3835aa1c2 100644
--- a/3party/freetype/include/freetype/internal/services/svsfnt.h
+++ b/3party/freetype/include/freetype/internal/services/svsfnt.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType SFNT table loading service (specification). */
/* */
-/* Copyright 2003, 2004 by */
+/* Copyright 2003, 2004, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -69,26 +69,27 @@ FT_BEGIN_HEADER
FT_SFNT_TableInfoFunc table_info;
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_SFNT_TABLEREC(class_, load_, get_, info_) \
- static const FT_Service_SFNT_TableRec class_ = \
- { \
- load_, get_, info_ \
+#define FT_DEFINE_SERVICE_SFNT_TABLEREC( class_, load_, get_, info_ ) \
+ static const FT_Service_SFNT_TableRec class_ = \
+ { \
+ load_, get_, info_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_SERVICE_SFNT_TABLEREC(class_, load_, get_, info_) \
- void \
- FT_Init_Class_##class_( FT_Service_SFNT_TableRec* clazz ) \
- { \
- clazz->load_table = load_; \
- clazz->get_table = get_; \
- clazz->table_info = info_; \
- }
+#define FT_DEFINE_SERVICE_SFNT_TABLEREC( class_, load_, get_, info_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Service_SFNT_TableRec* clazz ) \
+ { \
+ clazz->load_table = load_; \
+ clazz->get_table = get_; \
+ clazz->table_info = info_; \
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svttcmap.h b/3party/freetype/include/freetype/internal/services/svttcmap.h
index 8af00351d9..83994aaf8a 100644
--- a/3party/freetype/include/freetype/internal/services/svttcmap.h
+++ b/3party/freetype/include/freetype/internal/services/svttcmap.h
@@ -7,7 +7,7 @@
/* Copyright 2003 by */
/* Masatake YAMATO, Redhat K.K. */
/* */
-/* Copyright 2003, 2008 by */
+/* Copyright 2003, 2008, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -31,7 +31,7 @@
FT_BEGIN_HEADER
-#define FT_SERVICE_ID_TT_CMAP "tt-cmaps"
+#define FT_SERVICE_ID_TT_CMAP "tt-cmaps"
/*************************************************************************/
@@ -58,8 +58,8 @@ FT_BEGIN_HEADER
/* */
typedef struct TT_CMapInfo_
{
- FT_ULong language;
- FT_Long format;
+ FT_ULong language;
+ FT_Long format;
} TT_CMapInfo;
@@ -76,24 +76,25 @@ FT_BEGIN_HEADER
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_TTCMAPSREC(class_, get_cmap_info_) \
- static const FT_Service_TTCMapsRec class_ = \
- { \
- get_cmap_info_ \
+#define FT_DEFINE_SERVICE_TTCMAPSREC( class_, get_cmap_info_ ) \
+ static const FT_Service_TTCMapsRec class_ = \
+ { \
+ get_cmap_info_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_SERVICE_TTCMAPSREC(class_, get_cmap_info_) \
- void \
- FT_Init_Class_##class_( FT_Library library, \
- FT_Service_TTCMapsRec* clazz) \
- { \
- FT_UNUSED(library); \
- clazz->get_cmap_info = get_cmap_info_; \
- }
+#define FT_DEFINE_SERVICE_TTCMAPSREC( class_, get_cmap_info_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ FT_Service_TTCMapsRec* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ clazz->get_cmap_info = get_cmap_info_; \
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/services/svttglyf.h b/3party/freetype/include/freetype/internal/services/svttglyf.h
index ab2dc9a9fe..369eb8421b 100644
--- a/3party/freetype/include/freetype/internal/services/svttglyf.h
+++ b/3party/freetype/include/freetype/internal/services/svttglyf.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType TrueType glyph service. */
/* */
-/* Copyright 2007 by David Turner. */
+/* Copyright 2007, 2009, 2012 by David Turner. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
@@ -24,7 +24,7 @@
FT_BEGIN_HEADER
-#define FT_SERVICE_ID_TT_GLYF "tt-glyf"
+#define FT_SERVICE_ID_TT_GLYF "tt-glyf"
typedef FT_ULong
@@ -37,24 +37,25 @@ FT_BEGIN_HEADER
TT_Glyf_GetLocationFunc get_location;
};
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_SERVICE_TTGLYFREC(class_, get_location_ ) \
- static const FT_Service_TTGlyfRec class_ = \
+#define FT_DEFINE_SERVICE_TTGLYFREC( class_, get_location_ ) \
+ static const FT_Service_TTGlyfRec class_ = \
{ \
get_location_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
-#define FT_DEFINE_SERVICE_TTGLYFREC(class_, get_location_ ) \
+#define FT_DEFINE_SERVICE_TTGLYFREC( class_, get_location_ ) \
void \
- FT_Init_Class_##class_( FT_Service_TTGlyfRec* clazz ) \
+ FT_Init_Class_ ## class_( FT_Service_TTGlyfRec* clazz ) \
{ \
clazz->get_location = get_location_; \
- }
+ }
-#endif /* FT_CONFIG_OPTION_PIC */
+#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/include/freetype/internal/sfnt.h b/3party/freetype/include/freetype/internal/sfnt.h
index 6326debd00..aab4f8531c 100644
--- a/3party/freetype/include/freetype/internal/sfnt.h
+++ b/3party/freetype/include/freetype/internal/sfnt.h
@@ -4,7 +4,7 @@
/* */
/* High-level `sfnt' driver interface (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006 by */
+/* Copyright 1996-2006, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -756,138 +756,215 @@ FT_BEGIN_HEADER
#ifndef FT_CONFIG_OPTION_PIC
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
-#define FT_DEFINE_DRIVERS_OLD_INTERNAL(a) \
- a,
+#define FT_DEFINE_DRIVERS_OLD_INTERNAL( a ) \
+ a,
#else
- #define FT_DEFINE_DRIVERS_OLD_INTERNAL(a)
+#define FT_DEFINE_DRIVERS_OLD_INTERNAL( a ) /* empty */
#endif
-#define FT_INTERNAL(a) \
- a,
-
-#define FT_DEFINE_SFNT_INTERFACE(class_, \
- goto_table_, init_face_, load_face_, done_face_, get_interface_, \
- load_any_, load_sfnt_header_, load_directory_, load_head_, \
- load_hhea_, load_cmap_, load_maxp_, load_os2_, load_post_, \
- load_name_, free_name_, load_hdmx_stub_, free_hdmx_stub_, \
- load_kern_, load_gasp_, load_pclt_, load_bhed_, \
- set_sbit_strike_stub_, load_sbits_stub_, find_sbit_image_, \
- load_sbit_metrics_, load_sbit_image_, free_sbits_stub_, \
- get_psname_, free_psnames_, load_charmap_stub_, free_charmap_stub_, \
- get_kerning_, load_font_dir_, load_hmtx_, load_eblc_, free_eblc_, \
- set_sbit_strike_, load_strike_metrics_, get_metrics_ ) \
- static const SFNT_Interface class_ = \
- { \
- FT_INTERNAL(goto_table_) \
- FT_INTERNAL(init_face_) \
- FT_INTERNAL(load_face_) \
- FT_INTERNAL(done_face_) \
- FT_INTERNAL(get_interface_) \
- FT_INTERNAL(load_any_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sfnt_header_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_directory_) \
- FT_INTERNAL(load_head_) \
- FT_INTERNAL(load_hhea_) \
- FT_INTERNAL(load_cmap_) \
- FT_INTERNAL(load_maxp_) \
- FT_INTERNAL(load_os2_) \
- FT_INTERNAL(load_post_) \
- FT_INTERNAL(load_name_) \
- FT_INTERNAL(free_name_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_hdmx_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(free_hdmx_stub_) \
- FT_INTERNAL(load_kern_) \
- FT_INTERNAL(load_gasp_) \
- FT_INTERNAL(load_pclt_) \
- FT_INTERNAL(load_bhed_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(set_sbit_strike_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbits_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(find_sbit_image_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbit_metrics_) \
- FT_INTERNAL(load_sbit_image_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(free_sbits_stub_) \
- FT_INTERNAL(get_psname_) \
- FT_INTERNAL(free_psnames_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_charmap_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(free_charmap_stub_) \
- FT_INTERNAL(get_kerning_) \
- FT_INTERNAL(load_font_dir_) \
- FT_INTERNAL(load_hmtx_) \
- FT_INTERNAL(load_eblc_) \
- FT_INTERNAL(free_eblc_) \
- FT_INTERNAL(set_sbit_strike_) \
- FT_INTERNAL(load_strike_metrics_) \
- FT_INTERNAL(get_metrics_) \
+
+#define FT_INTERNAL( a ) \
+ a,
+
+#define FT_DEFINE_SFNT_INTERFACE( \
+ class_, \
+ goto_table_, \
+ init_face_, \
+ load_face_, \
+ done_face_, \
+ get_interface_, \
+ load_any_, \
+ load_sfnt_header_, \
+ load_directory_, \
+ load_head_, \
+ load_hhea_, \
+ load_cmap_, \
+ load_maxp_, \
+ load_os2_, \
+ load_post_, \
+ load_name_, \
+ free_name_, \
+ load_hdmx_stub_, \
+ free_hdmx_stub_, \
+ load_kern_, \
+ load_gasp_, \
+ load_pclt_, \
+ load_bhed_, \
+ set_sbit_strike_stub_, \
+ load_sbits_stub_, \
+ find_sbit_image_, \
+ load_sbit_metrics_, \
+ load_sbit_image_, \
+ free_sbits_stub_, \
+ get_psname_, \
+ free_psnames_, \
+ load_charmap_stub_, \
+ free_charmap_stub_, \
+ get_kerning_, \
+ load_font_dir_, \
+ load_hmtx_, \
+ load_eblc_, \
+ free_eblc_, \
+ set_sbit_strike_, \
+ load_strike_metrics_, \
+ get_metrics_ ) \
+ static const SFNT_Interface class_ = \
+ { \
+ FT_INTERNAL( goto_table_ ) \
+ FT_INTERNAL( init_face_ ) \
+ FT_INTERNAL( load_face_ ) \
+ FT_INTERNAL( done_face_ ) \
+ FT_INTERNAL( get_interface_ ) \
+ FT_INTERNAL( load_any_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_sfnt_header_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_directory_ ) \
+ FT_INTERNAL( load_head_ ) \
+ FT_INTERNAL( load_hhea_ ) \
+ FT_INTERNAL( load_cmap_ ) \
+ FT_INTERNAL( load_maxp_ ) \
+ FT_INTERNAL( load_os2_ ) \
+ FT_INTERNAL( load_post_ ) \
+ FT_INTERNAL( load_name_ ) \
+ FT_INTERNAL( free_name_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_hdmx_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( free_hdmx_stub_ ) \
+ FT_INTERNAL( load_kern_ ) \
+ FT_INTERNAL( load_gasp_ ) \
+ FT_INTERNAL( load_pclt_ ) \
+ FT_INTERNAL( load_bhed_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( set_sbit_strike_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_sbits_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( find_sbit_image_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_sbit_metrics_ ) \
+ FT_INTERNAL( load_sbit_image_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( free_sbits_stub_ ) \
+ FT_INTERNAL( get_psname_ ) \
+ FT_INTERNAL( free_psnames_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_charmap_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( free_charmap_stub_ ) \
+ FT_INTERNAL( get_kerning_ ) \
+ FT_INTERNAL( load_font_dir_ ) \
+ FT_INTERNAL( load_hmtx_ ) \
+ FT_INTERNAL( load_eblc_ ) \
+ FT_INTERNAL( free_eblc_ ) \
+ FT_INTERNAL( set_sbit_strike_ ) \
+ FT_INTERNAL( load_strike_metrics_ ) \
+ FT_INTERNAL( get_metrics_ ) \
};
-#else /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
-#define FT_DEFINE_DRIVERS_OLD_INTERNAL(a, a_) \
- clazz->a = a_;
+#define FT_DEFINE_DRIVERS_OLD_INTERNAL( a, a_ ) \
+ clazz->a = a_;
#else
- #define FT_DEFINE_DRIVERS_OLD_INTERNAL(a, a_)
+#define FT_DEFINE_DRIVERS_OLD_INTERNAL( a, a_ ) /* empty */
#endif
-#define FT_INTERNAL(a, a_) \
- clazz->a = a_;
-
-#define FT_DEFINE_SFNT_INTERFACE(class_, \
- goto_table_, init_face_, load_face_, done_face_, get_interface_, \
- load_any_, load_sfnt_header_, load_directory_, load_head_, \
- load_hhea_, load_cmap_, load_maxp_, load_os2_, load_post_, \
- load_name_, free_name_, load_hdmx_stub_, free_hdmx_stub_, \
- load_kern_, load_gasp_, load_pclt_, load_bhed_, \
- set_sbit_strike_stub_, load_sbits_stub_, find_sbit_image_, \
- load_sbit_metrics_, load_sbit_image_, free_sbits_stub_, \
- get_psname_, free_psnames_, load_charmap_stub_, free_charmap_stub_, \
- get_kerning_, load_font_dir_, load_hmtx_, load_eblc_, free_eblc_, \
- set_sbit_strike_, load_strike_metrics_, get_metrics_ ) \
- void \
- FT_Init_Class_##class_( FT_Library library, SFNT_Interface* clazz ) \
- { \
- FT_UNUSED(library); \
- FT_INTERNAL(goto_table,goto_table_) \
- FT_INTERNAL(init_face,init_face_) \
- FT_INTERNAL(load_face,load_face_) \
- FT_INTERNAL(done_face,done_face_) \
- FT_INTERNAL(get_interface,get_interface_) \
- FT_INTERNAL(load_any,load_any_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sfnt_header,load_sfnt_header_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_directory,load_directory_) \
- FT_INTERNAL(load_head,load_head_) \
- FT_INTERNAL(load_hhea,load_hhea_) \
- FT_INTERNAL(load_cmap,load_cmap_) \
- FT_INTERNAL(load_maxp,load_maxp_) \
- FT_INTERNAL(load_os2,load_os2_) \
- FT_INTERNAL(load_post,load_post_) \
- FT_INTERNAL(load_name,load_name_) \
- FT_INTERNAL(free_name,free_name_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_hdmx_stub,load_hdmx_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(free_hdmx_stub,free_hdmx_stub_) \
- FT_INTERNAL(load_kern,load_kern_) \
- FT_INTERNAL(load_gasp,load_gasp_) \
- FT_INTERNAL(load_pclt,load_pclt_) \
- FT_INTERNAL(load_bhed,load_bhed_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(set_sbit_strike_stub,set_sbit_strike_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbits_stub,load_sbits_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(find_sbit_image,find_sbit_image_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbit_metrics,load_sbit_metrics_) \
- FT_INTERNAL(load_sbit_image,load_sbit_image_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(free_sbits_stub,free_sbits_stub_) \
- FT_INTERNAL(get_psname,get_psname_) \
- FT_INTERNAL(free_psnames,free_psnames_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(load_charmap_stub,load_charmap_stub_) \
- FT_DEFINE_DRIVERS_OLD_INTERNAL(free_charmap_stub,free_charmap_stub_) \
- FT_INTERNAL(get_kerning,get_kerning_) \
- FT_INTERNAL(load_font_dir,load_font_dir_) \
- FT_INTERNAL(load_hmtx,load_hmtx_) \
- FT_INTERNAL(load_eblc,load_eblc_) \
- FT_INTERNAL(free_eblc,free_eblc_) \
- FT_INTERNAL(set_sbit_strike,set_sbit_strike_) \
- FT_INTERNAL(load_strike_metrics,load_strike_metrics_) \
- FT_INTERNAL(get_metrics,get_metrics_) \
- }
-
-#endif /* FT_CONFIG_OPTION_PIC */
+
+#define FT_INTERNAL( a, a_ ) \
+ clazz->a = a_;
+
+#define FT_DEFINE_SFNT_INTERFACE( \
+ class_, \
+ goto_table_, \
+ init_face_, \
+ load_face_, \
+ done_face_, \
+ get_interface_, \
+ load_any_, \
+ load_sfnt_header_, \
+ load_directory_, \
+ load_head_, \
+ load_hhea_, \
+ load_cmap_, \
+ load_maxp_, \
+ load_os2_, \
+ load_post_, \
+ load_name_, \
+ free_name_, \
+ load_hdmx_stub_, \
+ free_hdmx_stub_, \
+ load_kern_, \
+ load_gasp_, \
+ load_pclt_, \
+ load_bhed_, \
+ set_sbit_strike_stub_, \
+ load_sbits_stub_, \
+ find_sbit_image_, \
+ load_sbit_metrics_, \
+ load_sbit_image_, \
+ free_sbits_stub_, \
+ get_psname_, \
+ free_psnames_, \
+ load_charmap_stub_, \
+ free_charmap_stub_, \
+ get_kerning_, \
+ load_font_dir_, \
+ load_hmtx_, \
+ load_eblc_, \
+ free_eblc_, \
+ set_sbit_strike_, \
+ load_strike_metrics_, \
+ get_metrics_ ) \
+ void \
+ FT_Init_Class_ ## class_( FT_Library library, \
+ SFNT_Interface* clazz ) \
+ { \
+ FT_UNUSED( library ); \
+ \
+ FT_INTERNAL( goto_table, goto_table_ ) \
+ FT_INTERNAL( init_face, init_face_ ) \
+ FT_INTERNAL( load_face, load_face_ ) \
+ FT_INTERNAL( done_face, done_face_ ) \
+ FT_INTERNAL( get_interface, get_interface_ ) \
+ FT_INTERNAL( load_any, load_any_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_sfnt_header, \
+ load_sfnt_header_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_directory, \
+ load_directory_ ) \
+ FT_INTERNAL( load_head, load_head_ ) \
+ FT_INTERNAL( load_hhea, load_hhea_ ) \
+ FT_INTERNAL( load_cmap, load_cmap_ ) \
+ FT_INTERNAL( load_maxp, load_maxp_ ) \
+ FT_INTERNAL( load_os2, load_os2_ ) \
+ FT_INTERNAL( load_post, load_post_ ) \
+ FT_INTERNAL( load_name, load_name_ ) \
+ FT_INTERNAL( free_name, free_name_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_hdmx_stub, \
+ load_hdmx_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( free_hdmx_stub, \
+ free_hdmx_stub_ ) \
+ FT_INTERNAL( load_kern, load_kern_ ) \
+ FT_INTERNAL( load_gasp, load_gasp_ ) \
+ FT_INTERNAL( load_pclt, load_pclt_ ) \
+ FT_INTERNAL( load_bhed, load_bhed_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( set_sbit_strike_stub, \
+ set_sbit_strike_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_sbits_stub, \
+ load_sbits_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( find_sbit_image, \
+ find_sbit_image_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_sbit_metrics, \
+ load_sbit_metrics_ ) \
+ FT_INTERNAL( load_sbit_image, load_sbit_image_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( free_sbits_stub, \
+ free_sbits_stub_ ) \
+ FT_INTERNAL( get_psname, get_psname_ ) \
+ FT_INTERNAL( free_psnames, free_psnames_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( load_charmap_stub, \
+ load_charmap_stub_ ) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL( free_charmap_stub, \
+ free_charmap_stub_ ) \
+ FT_INTERNAL( get_kerning, get_kerning_ ) \
+ FT_INTERNAL( load_font_dir, load_font_dir_ ) \
+ FT_INTERNAL( load_hmtx, load_hmtx_ ) \
+ FT_INTERNAL( load_eblc, load_eblc_ ) \
+ FT_INTERNAL( free_eblc, free_eblc_ ) \
+ FT_INTERNAL( set_sbit_strike, set_sbit_strike_ ) \
+ FT_INTERNAL( load_strike_metrics, load_strike_metrics_ ) \
+ FT_INTERNAL( get_metrics, get_metrics_ ) \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
FT_END_HEADER
diff --git a/3party/freetype/include/freetype/internal/tttypes.h b/3party/freetype/include/freetype/internal/tttypes.h
index acbb863b0f..5eee3cd6ca 100644
--- a/3party/freetype/include/freetype/internal/tttypes.h
+++ b/3party/freetype/include/freetype/internal/tttypes.h
@@ -5,7 +5,7 @@
/* Basic SFNT/TrueType type definitions and interface (specification */
/* only). */
/* */
-/* Copyright 1996-2001, 2002, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2002, 2004-2008, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -1401,7 +1401,7 @@ FT_BEGIN_HEADER
FT_Byte* vert_metrics;
FT_ULong vert_metrics_size;
- FT_ULong num_locations; /* in broken TTF, gid > 0xFFFF */
+ FT_ULong num_locations; /* in broken TTF, gid > 0xFFFF */
FT_Byte* glyph_locations;
FT_Byte* hdmx_table;
@@ -1443,7 +1443,7 @@ FT_BEGIN_HEADER
/* <Fields> */
/* memory :: A handle to the memory manager. */
/* */
- /* max_points :: The maximal size in points of the zone. */
+ /* max_points :: The maximum size in points of the zone. */
/* */
/* max_contours :: Max size in links contours of the zone. */
/* */
diff --git a/3party/freetype/include/freetype/t1tables.h b/3party/freetype/include/freetype/t1tables.h
index db1a91e69b..a14255e5f5 100644
--- a/3party/freetype/include/freetype/t1tables.h
+++ b/3party/freetype/include/freetype/t1tables.h
@@ -570,7 +570,7 @@ FT_BEGIN_HEADER
PS_DICT_NOTICE, /* FT_String* */
PS_DICT_FULL_NAME, /* FT_String* */
PS_DICT_FAMILY_NAME, /* FT_String* */
- PS_DICT_WEIGHT, /* FT_String */
+ PS_DICT_WEIGHT, /* FT_String* */
PS_DICT_IS_FIXED_PITCH, /* FT_Bool */
PS_DICT_UNDERLINE_POSITION, /* FT_Short */
PS_DICT_UNDERLINE_THICKNESS, /* FT_UShort */
diff --git a/3party/freetype/include/freetype/ttnameid.h b/3party/freetype/include/freetype/ttnameid.h
index 66aef0432e..173f88c950 100644
--- a/3party/freetype/include/freetype/ttnameid.h
+++ b/3party/freetype/include/freetype/ttnameid.h
@@ -4,7 +4,7 @@
/* */
/* TrueType name ID definitions (specification only). */
/* */
-/* Copyright 1996-2002, 2003, 2004, 2006, 2007, 2008 by */
+/* Copyright 1996-2004, 2006-2008, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -316,11 +316,12 @@ FT_BEGIN_HEADER
/* */
/* Possible values of the language identifier field in the name records */
/* of the TTF `name' table if the `platform' identifier code is */
- /* TT_PLATFORM_MACINTOSH. */
+ /* TT_PLATFORM_MACINTOSH. These values are also used as return values */
+ /* for function @FT_Get_CMap_Language_ID. */
/* */
/* The canonical source for the Apple assigned Language ID's is at */
/* */
- /* http://fonts.apple.com/TTRefMan/RM06/Chap6name.html */
+ /* https://developer.apple.com/fonts/TTRefMan/RM06/Chap6name.html */
/* */
#define TT_MAC_LANGID_ENGLISH 0
#define TT_MAC_LANGID_FRENCH 1
@@ -461,21 +462,10 @@ FT_BEGIN_HEADER
/* of the TTF `name' table if the `platform' identifier code is */
/* TT_PLATFORM_MICROSOFT. */
/* */
- /* The canonical source for the MS assigned LCID's (seems to) be at */
+ /* The canonical source for the MS assigned LCIDs is */
/* */
/* http://www.microsoft.com/globaldev/reference/lcid-all.mspx */
/* */
- /* It used to be at various places, among them */
- /* */
- /* http://www.microsoft.com/typography/OTSPEC/lcid-cp.txt */
- /* http://www.microsoft.com/globaldev/reference/loclanghome.asp */
- /* http://support.microsoft.com/support/kb/articles/Q224/8/04.ASP */
- /* http://msdn.microsoft.com/library/en-us/passport25/ */
- /* NET_Passport_VBScript_Documentation/Single_Sign_In/ */
- /* Advanced_Single_Sign_In/Localization_and_LCIDs.asp */
- /* */
- /* Hopefully, it seems now that the Globaldev site prevails... */
- /* (updated by Antoine, 2004-02-17) */
#define TT_MS_LANGID_ARABIC_GENERAL 0x0001
#define TT_MS_LANGID_ARABIC_SAUDI_ARABIA 0x0401
diff --git a/3party/freetype/include/freetype/tttables.h b/3party/freetype/include/freetype/tttables.h
index 02236c2005..fe07117b0b 100644
--- a/3party/freetype/include/freetype/tttables.h
+++ b/3party/freetype/include/freetype/tttables.h
@@ -5,7 +5,7 @@
/* Basic SFNT/TrueType tables definitions and interface */
/* (specification only). */
/* */
-/* Copyright 1996-2005, 2008-2011 by */
+/* Copyright 1996-2005, 2008-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -600,6 +600,16 @@ FT_BEGIN_HEADER
/* by the sfnt, truetype, and opentype drivers. See @FT_Sfnt_Tag for */
/* a list. */
/* */
+ /* Here an example how to access the `vhea' table: */
+ /* */
+ /* { */
+ /* TT_VertHeader* vert_header; */
+ /* */
+ /* */
+ /* vert_header = */
+ /* (TT_VertHeader*)FT_Get_Sfnt_Table( face, ft_sfnt_vhea ); */
+ /* } */
+ /* */
FT_EXPORT( void* )
FT_Get_Sfnt_Table( FT_Face face,
FT_Sfnt_Tag tag );
@@ -702,7 +712,8 @@ FT_BEGIN_HEADER
* FreeType error code. 0~means success.
*
* @note:
- * SFNT tables with length zero are treated as missing.
+ * While parsing fonts, FreeType handles SFNT tables with length zero as
+ * missing.
*
*/
FT_EXPORT( FT_Error )
@@ -729,6 +740,9 @@ FT_BEGIN_HEADER
/* The language ID of `charmap'. If `charmap' doesn't belong to a */
/* TrueType/sfnt face, just return~0 as the default value. */
/* */
+ /* For a format~14 cmap (to access Unicode IVS), the return value is */
+ /* 0xFFFFFFFF. */
+ /* */
FT_EXPORT( FT_ULong )
FT_Get_CMap_Language_ID( FT_CharMap charmap );
diff --git a/3party/freetype/modules.cfg b/3party/freetype/modules.cfg
index 8d5b6b598f..a85378ee7c 100644
--- a/3party/freetype/modules.cfg
+++ b/3party/freetype/modules.cfg
@@ -1,6 +1,6 @@
# modules.cfg
#
-# Copyright 2005, 2006, 2007, 2009, 2010 by
+# Copyright 2005-2007, 2009-2011 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -54,7 +54,7 @@ FONT_MODULES += pfr
# PostScript Type 42 font driver.
#
-# This driver needs the `truetype' module.
+# This driver needs the `truetype' and `psaux' modules.
FONT_MODULES += type42
# Windows FONT/FNT font driver. See optional extension ftwinfnt.c below
diff --git a/3party/freetype/src/autofit/afangles.c b/3party/freetype/src/autofit/afangles.c
index 790af1779c..b44a5ba2c6 100644
--- a/3party/freetype/src/autofit/afangles.c
+++ b/3party/freetype/src/autofit/afangles.c
@@ -5,7 +5,7 @@
/* Routines used to compute vector angles with limited accuracy */
/* and very high speed. It also contains sorting routines (body). */
/* */
-/* Copyright 2003-2006, 2011 by */
+/* Copyright 2003-2006, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -255,7 +255,7 @@
{
for ( j = i; j > 0; j-- )
{
- if ( table[j] > table[j - 1] )
+ if ( table[j] >= table[j - 1] )
break;
swap = table[j];
@@ -267,18 +267,26 @@
FT_LOCAL_DEF( void )
- af_sort_widths( FT_UInt count,
- AF_Width table )
+ af_sort_and_quantize_widths( FT_UInt* count,
+ AF_Width table,
+ FT_Pos threshold )
{
FT_UInt i, j;
+ FT_UInt cur_idx;
+ FT_Pos cur_val;
+ FT_Pos sum;
AF_WidthRec swap;
- for ( i = 1; i < count; i++ )
+ if ( *count == 1 )
+ return;
+
+ /* sort */
+ for ( i = 1; i < *count; i++ )
{
for ( j = i; j > 0; j-- )
{
- if ( table[j].org > table[j - 1].org )
+ if ( table[j].org >= table[j - 1].org )
break;
swap = table[j];
@@ -286,6 +294,51 @@
table[j - 1] = swap;
}
}
+
+ cur_idx = 0;
+ cur_val = table[cur_idx].org;
+
+ /* compute and use mean values for clusters not larger than */
+ /* `threshold'; this is very primitive and might not yield */
+ /* the best result, but normally, using reference character */
+ /* `o', `*count' is 2, so the code below is fully sufficient */
+ for ( i = 1; i < *count; i++ )
+ {
+ if ( table[i].org - cur_val > threshold ||
+ i == *count - 1 )
+ {
+ sum = 0;
+
+ /* fix loop for end of array */
+ if ( table[i].org - cur_val <= threshold &&
+ i == *count - 1 )
+ i++;
+
+ for ( j = cur_idx; j < i; j++ )
+ {
+ sum += table[j].org;
+ table[j].org = 0;
+ }
+ table[cur_idx].org = sum / j;
+
+ if ( i < *count - 1 )
+ {
+ cur_idx = i + 1;
+ cur_val = table[cur_idx].org;
+ }
+ }
+ }
+
+ cur_idx = 1;
+
+ /* compress array to remove zero values */
+ for ( i = 1; i < *count; i++ )
+ {
+ if ( table[i].org )
+ table[cur_idx++] = table[i];
+ }
+
+ *count = cur_idx;
}
diff --git a/3party/freetype/src/autofit/afcjk.c b/3party/freetype/src/autofit/afcjk.c
index 0acef9c85e..38325f6d03 100644
--- a/3party/freetype/src/autofit/afcjk.c
+++ b/3party/freetype/src/autofit/afcjk.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for CJK script (body). */
/* */
-/* Copyright 2006-2011 by */
+/* Copyright 2006-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -67,8 +67,7 @@
FT_LOCAL_DEF( void )
af_cjk_metrics_init_widths( AF_CJKMetrics metrics,
- FT_Face face,
- FT_ULong charcode )
+ FT_Face face )
{
/* scan the array of segments in each direction */
AF_GlyphHintsRec hints[1];
@@ -87,7 +86,8 @@
AF_Scaler scaler = &dummy->root.scaler;
- glyph_index = FT_Get_Char_Index( face, charcode );
+ glyph_index = FT_Get_Char_Index( face,
+ metrics->root.clazz->standard_char );
if ( glyph_index == 0 )
goto Exit;
@@ -150,7 +150,10 @@
}
}
- af_sort_widths( num_widths, axis->widths );
+ /* this also replaces multiple almost identical stem widths */
+ /* with a single one (the value 100 is heuristic) */
+ af_sort_and_quantize_widths( &num_widths, axis->widths,
+ dummy->units_per_em / 100 );
axis->width_count = num_widths;
}
@@ -556,7 +559,7 @@
face->charmap = NULL;
else
{
- af_cjk_metrics_init_widths( metrics, face, 0x7530 );
+ af_cjk_metrics_init_widths( metrics, face );
af_cjk_metrics_init_blues( metrics, face, af_cjk_hani_blue_chars );
af_cjk_metrics_check_digits( metrics, face );
}
@@ -1610,7 +1613,7 @@
goto Exit;
}
- offset = cur_len % 64;
+ offset = cur_len & 63;
if ( offset < 32 )
{
@@ -2190,6 +2193,7 @@
static const AF_Script_UniRangeRec af_cjk_uniranges[] =
{
+ AF_UNIRANGE_REC( 0x1100UL, 0x11FFUL ), /* Hangul Jamo */
AF_UNIRANGE_REC( 0x2E80UL, 0x2EFFUL ), /* CJK Radicals Supplement */
AF_UNIRANGE_REC( 0x2F00UL, 0x2FDFUL ), /* Kangxi Radicals */
AF_UNIRANGE_REC( 0x2FF0UL, 0x2FFFUL ), /* Ideographic Description Characters */
@@ -2225,11 +2229,12 @@
};
- AF_DEFINE_SCRIPT_CLASS(af_cjk_script_class,
+ AF_DEFINE_SCRIPT_CLASS( af_cjk_script_class,
AF_SCRIPT_CJK,
af_cjk_uniranges,
+ 0x7530, /* ç”° */
- sizeof( AF_CJKMetricsRec ),
+ sizeof ( AF_CJKMetricsRec ),
(AF_Script_InitMetricsFunc) af_cjk_metrics_init,
(AF_Script_ScaleMetricsFunc)af_cjk_metrics_scale,
@@ -2247,11 +2252,12 @@
};
- AF_DEFINE_SCRIPT_CLASS(af_cjk_script_class,
+ AF_DEFINE_SCRIPT_CLASS( af_cjk_script_class,
AF_SCRIPT_CJK,
af_cjk_uniranges,
+ 0,
- sizeof( AF_CJKMetricsRec ),
+ sizeof ( AF_CJKMetricsRec ),
(AF_Script_InitMetricsFunc) NULL,
(AF_Script_ScaleMetricsFunc)NULL,
diff --git a/3party/freetype/src/autofit/afcjk.h b/3party/freetype/src/autofit/afcjk.h
index 8416c0d021..ab816f20b1 100644
--- a/3party/freetype/src/autofit/afcjk.h
+++ b/3party/freetype/src/autofit/afcjk.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for CJK script (specification). */
/* */
-/* Copyright 2006, 2007, 2011 by */
+/* Copyright 2006, 2007, 2011, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -28,7 +28,7 @@ FT_BEGIN_HEADER
/* the CJK-specific script class */
- AF_DECLARE_SCRIPT_CLASS(af_cjk_script_class)
+ AF_DECLARE_SCRIPT_CLASS( af_cjk_script_class )
/* CJK (global) metrics management */
@@ -103,6 +103,7 @@ FT_BEGIN_HEADER
} AF_CJKMetricsRec, *AF_CJKMetrics;
+#ifdef AF_CONFIG_OPTION_CJK
FT_LOCAL( FT_Error )
af_cjk_metrics_init( AF_CJKMetrics metrics,
FT_Face face );
@@ -120,15 +121,15 @@ FT_BEGIN_HEADER
FT_Outline* outline,
AF_CJKMetrics metrics );
- /* Shared. called from afindic.c */
+ /* shared; called from afindic.c */
FT_LOCAL( void )
af_cjk_metrics_check_digits( AF_CJKMetrics metrics,
FT_Face face );
FT_LOCAL( void )
af_cjk_metrics_init_widths( AF_CJKMetrics metrics,
- FT_Face face,
- FT_ULong charcode );
+ FT_Face face );
+#endif /* AF_CONFIG_OPTION_CJK */
/* */
diff --git a/3party/freetype/src/autofit/afdummy.c b/3party/freetype/src/autofit/afdummy.c
index c71265131e..2258a198a3 100644
--- a/3party/freetype/src/autofit/afdummy.c
+++ b/3party/freetype/src/autofit/afdummy.c
@@ -44,10 +44,11 @@
AF_DEFINE_SCRIPT_CLASS( af_dummy_script_class,
- AF_SCRIPT_NONE,
+ AF_SCRIPT_DUMMY,
NULL,
+ 0,
- sizeof( AF_ScriptMetricsRec ),
+ sizeof ( AF_ScriptMetricsRec ),
(AF_Script_InitMetricsFunc) NULL,
(AF_Script_ScaleMetricsFunc)NULL,
diff --git a/3party/freetype/src/autofit/aferrors.h b/3party/freetype/src/autofit/aferrors.h
index c2ed5fe2ab..50e1a22dd5 100644
--- a/3party/freetype/src/autofit/aferrors.h
+++ b/3party/freetype/src/autofit/aferrors.h
@@ -4,7 +4,7 @@
/* */
/* Autofitter error codes (specification only). */
/* */
-/* Copyright 2005 by */
+/* Copyright 2005, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX AF_Err_
#define FT_ERR_BASE FT_Mod_Err_Autofit
diff --git a/3party/freetype/src/autofit/afglobal.c b/3party/freetype/src/autofit/afglobal.c
index 3c5f02ec6e..3c1e837ed1 100644
--- a/3party/freetype/src/autofit/afglobal.c
+++ b/3party/freetype/src/autofit/afglobal.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter routines to compute global hinting values (body). */
/* */
-/* Copyright 2003-2011 by */
+/* Copyright 2003-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -43,35 +43,12 @@
#endif
&af_latin_script_class,
&af_cjk_script_class,
- &af_indic_script_class,
+ &af_indic_script_class,
NULL /* do not remove */
};
#endif /* !FT_CONFIG_OPTION_PIC */
- /* index of default script in `af_script_classes' */
-#define AF_SCRIPT_LIST_DEFAULT 2
- /* a bit mask indicating an uncovered glyph */
-#define AF_SCRIPT_LIST_NONE 0x7F
- /* if this flag is set, we have an ASCII digit */
-#define AF_DIGIT 0x80
-
-
- /*
- * Note that glyph_scripts[] is used to map each glyph into
- * an index into the `af_script_classes' array.
- *
- */
- typedef struct AF_FaceGlobalsRec_
- {
- FT_Face face;
- FT_Long glyph_count; /* same as face->num_glyphs */
- FT_Byte* glyph_scripts;
-
- AF_ScriptMetrics metrics[AF_SCRIPT_MAX];
-
- } AF_FaceGlobalsRec;
-
/* Compute the script index of each glyph within a given face. */
@@ -82,19 +59,20 @@
FT_Face face = globals->face;
FT_CharMap old_charmap = face->charmap;
FT_Byte* gscripts = globals->glyph_scripts;
- FT_UInt ss, i;
+ FT_UInt ss;
+ FT_UInt i;
- /* the value AF_SCRIPT_LIST_NONE means `uncovered glyph' */
+ /* the value AF_SCRIPT_NONE means `uncovered glyph' */
FT_MEM_SET( globals->glyph_scripts,
- AF_SCRIPT_LIST_NONE,
+ AF_SCRIPT_NONE,
globals->glyph_count );
error = FT_Select_Charmap( face, FT_ENCODING_UNICODE );
if ( error )
{
/*
- * Ignore this error; we simply use the default script.
+ * Ignore this error; we simply use the fallback script.
* XXX: Shouldn't we rather disable hinting?
*/
error = AF_Err_Ok;
@@ -112,7 +90,7 @@
continue;
/*
- * Scan all unicode points in the range and set the corresponding
+ * Scan all Unicode points in the range and set the corresponding
* glyph script index.
*/
for ( range = clazz->script_uni_ranges; range->first != 0; range++ )
@@ -125,7 +103,7 @@
if ( gindex != 0 &&
gindex < (FT_ULong)globals->glyph_count &&
- gscripts[gindex] == AF_SCRIPT_LIST_NONE )
+ gscripts[gindex] == AF_SCRIPT_NONE )
gscripts[gindex] = (FT_Byte)ss;
for (;;)
@@ -136,7 +114,7 @@
break;
if ( gindex < (FT_ULong)globals->glyph_count &&
- gscripts[gindex] == AF_SCRIPT_LIST_NONE )
+ gscripts[gindex] == AF_SCRIPT_NONE )
gscripts[gindex] = (FT_Byte)ss;
}
}
@@ -154,19 +132,20 @@
Exit:
/*
- * By default, all uncovered glyphs are set to the latin script.
+ * By default, all uncovered glyphs are set to the fallback script.
* XXX: Shouldn't we disable hinting or do something similar?
*/
+ if ( globals->module->fallback_script != AF_SCRIPT_NONE )
{
FT_Long nn;
for ( nn = 0; nn < globals->glyph_count; nn++ )
{
- if ( ( gscripts[nn] & ~AF_DIGIT ) == AF_SCRIPT_LIST_NONE )
+ if ( ( gscripts[nn] & ~AF_DIGIT ) == AF_SCRIPT_NONE )
{
- gscripts[nn] &= ~AF_SCRIPT_LIST_NONE;
- gscripts[nn] |= AF_SCRIPT_LIST_DEFAULT;
+ gscripts[nn] &= ~AF_SCRIPT_NONE;
+ gscripts[nn] |= globals->module->fallback_script;
}
}
}
@@ -178,7 +157,8 @@
FT_LOCAL_DEF( FT_Error )
af_face_globals_new( FT_Face face,
- AF_FaceGlobals *aglobals )
+ AF_FaceGlobals *aglobals,
+ AF_Module module )
{
FT_Error error;
FT_Memory memory;
@@ -187,21 +167,25 @@
memory = face->memory;
- if ( !FT_ALLOC( globals, sizeof ( *globals ) +
- face->num_glyphs * sizeof ( FT_Byte ) ) )
- {
- globals->face = face;
- globals->glyph_count = face->num_glyphs;
- globals->glyph_scripts = (FT_Byte*)( globals + 1 );
+ if ( FT_ALLOC( globals, sizeof ( *globals ) +
+ face->num_glyphs * sizeof ( FT_Byte ) ) )
+ goto Exit;
- error = af_face_globals_compute_script_coverage( globals );
- if ( error )
- {
- af_face_globals_free( globals );
- globals = NULL;
- }
+ globals->face = face;
+ globals->glyph_count = face->num_glyphs;
+ globals->glyph_scripts = (FT_Byte*)( globals + 1 );
+ globals->module = module;
+
+ error = af_face_globals_compute_script_coverage( globals );
+ if ( error )
+ {
+ af_face_globals_free( globals );
+ globals = NULL;
}
+ globals->increase_x_height = AF_PROP_INCREASE_X_HEIGHT_MAX;
+
+ Exit:
*aglobals = globals;
return error;
}
@@ -264,7 +248,7 @@
gidx = script;
if ( gidx == 0 || gidx + 1 >= script_max )
- gidx = globals->glyph_scripts[gindex] & AF_SCRIPT_LIST_NONE;
+ gidx = globals->glyph_scripts[gindex] & AF_SCRIPT_NONE;
clazz = AF_SCRIPT_CLASSES_GET[gidx];
if ( script == 0 )
@@ -273,14 +257,15 @@
metrics = globals->metrics[clazz->script];
if ( metrics == NULL )
{
- /* create the global metrics object when needed */
+ /* create the global metrics object if necessary */
FT_Memory memory = globals->face->memory;
if ( FT_ALLOC( metrics, clazz->script_metrics_size ) )
goto Exit;
- metrics->clazz = clazz;
+ metrics->clazz = clazz;
+ metrics->globals = globals;
if ( clazz->script_metrics_init )
{
diff --git a/3party/freetype/src/autofit/afglobal.h b/3party/freetype/src/autofit/afglobal.h
index cc6860b260..2e24900822 100644
--- a/3party/freetype/src/autofit/afglobal.h
+++ b/3party/freetype/src/autofit/afglobal.h
@@ -5,7 +5,7 @@
/* Auto-fitter routines to compute global hinting values */
/* (specification). */
/* */
-/* Copyright 2003-2005, 2007, 2009, 2011 by */
+/* Copyright 2003-2005, 2007, 2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -22,11 +22,29 @@
#include "aftypes.h"
+#include "afmodule.h"
FT_BEGIN_HEADER
+ /*
+ * Default values and flags for both autofitter globals (found in
+ * AF_ModuleRec) and face globals (in AF_FaceGlobalsRec).
+ */
+
+ /* index of fallback script in `af_script_classes' */
+#define AF_SCRIPT_FALLBACK 2
+ /* a bit mask indicating an uncovered glyph */
+#define AF_SCRIPT_NONE 0x7F
+ /* if this flag is set, we have an ASCII digit */
+#define AF_DIGIT 0x80
+
+ /* `increase-x-height' property */
+#define AF_PROP_INCREASE_X_HEIGHT_MIN 6
+#define AF_PROP_INCREASE_X_HEIGHT_MAX 0
+
+
/************************************************************************/
/************************************************************************/
/***** *****/
@@ -37,15 +55,35 @@ FT_BEGIN_HEADER
/*
+ * Note that glyph_scripts[] is used to map each glyph into
+ * an index into the `af_script_classes' array.
+ *
+ */
+ typedef struct AF_FaceGlobalsRec_
+ {
+ FT_Face face;
+ FT_Long glyph_count; /* same as face->num_glyphs */
+ FT_Byte* glyph_scripts;
+
+ /* per-face auto-hinter properties */
+ FT_UInt increase_x_height;
+
+ AF_ScriptMetrics metrics[AF_SCRIPT_MAX];
+
+ AF_Module module; /* to access global properties */
+
+ } AF_FaceGlobalsRec;
+
+
+ /*
* model the global hints data for a given face, decomposed into
* script-specific items
*/
- typedef struct AF_FaceGlobalsRec_* AF_FaceGlobals;
-
FT_LOCAL( FT_Error )
af_face_globals_new( FT_Face face,
- AF_FaceGlobals *aglobals );
+ AF_FaceGlobals *aglobals,
+ AF_Module module );
FT_LOCAL( FT_Error )
af_face_globals_get_metrics( AF_FaceGlobals globals,
diff --git a/3party/freetype/src/autofit/afhints.c b/3party/freetype/src/autofit/afhints.c
index f51066f02f..8aca8e7bad 100644
--- a/3party/freetype/src/autofit/afhints.c
+++ b/3party/freetype/src/autofit/afhints.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines (body). */
/* */
-/* Copyright 2003-2007, 2009-2011 by */
+/* Copyright 2003-2007, 2009-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,6 +19,17 @@
#include "afhints.h"
#include "aferrors.h"
#include FT_INTERNAL_CALC_H
+#include FT_INTERNAL_DEBUG_H
+
+
+ /*************************************************************************/
+ /* */
+ /* The macro FT_COMPONENT is used in trace mode. It is an implicit */
+ /* parameter of the FT_TRACE() and FT_ERROR() macros, used to print/log */
+ /* messages during execution. */
+ /* */
+#undef FT_COMPONENT
+#define FT_COMPONENT trace_afhints
/* Get new segment for given axis. */
@@ -70,7 +81,7 @@
FT_Int fpos,
AF_Direction dir,
FT_Memory memory,
- AF_Edge *aedge )
+ AF_Edge *anedge )
{
FT_Error error = AF_Err_Ok;
AF_Edge edge = NULL;
@@ -124,7 +135,7 @@
edge->dir = (FT_Char)dir;
Exit:
- *aedge = edge;
+ *anedge = edge;
return error;
}
@@ -175,29 +186,27 @@
AF_Point point;
- printf( "Table of points:\n" );
- printf( " [ index | xorg | yorg | xscale | yscale"
- " | xfit | yfit | flags ]\n" );
+ FT_TRACE7(( "Table of points:\n"
+ " [ index | xorg | yorg | xscale | yscale"
+ " | xfit | yfit | flags ]\n" ));
for ( point = points; point < limit; point++ )
- {
- printf( " [ %5d | %5d | %5d | %6.2f | %6.2f"
- " | %5.2f | %5.2f | %c%c%c%c%c%c ]\n",
- point - points,
- point->fx,
- point->fy,
- point->ox / 64.0,
- point->oy / 64.0,
- point->x / 64.0,
- point->y / 64.0,
- ( point->flags & AF_FLAG_WEAK_INTERPOLATION ) ? 'w' : ' ',
- ( point->flags & AF_FLAG_INFLECTION ) ? 'i' : ' ',
- ( point->flags & AF_FLAG_EXTREMA_X ) ? '<' : ' ',
- ( point->flags & AF_FLAG_EXTREMA_Y ) ? 'v' : ' ',
- ( point->flags & AF_FLAG_ROUND_X ) ? '(' : ' ',
- ( point->flags & AF_FLAG_ROUND_Y ) ? 'u' : ' ');
- }
- printf( "\n" );
+ FT_TRACE7(( " [ %5d | %5d | %5d | %6.2f | %6.2f"
+ " | %5.2f | %5.2f | %c%c%c%c%c%c ]\n",
+ point - points,
+ point->fx,
+ point->fy,
+ point->ox / 64.0,
+ point->oy / 64.0,
+ point->x / 64.0,
+ point->y / 64.0,
+ ( point->flags & AF_FLAG_WEAK_INTERPOLATION ) ? 'w' : ' ',
+ ( point->flags & AF_FLAG_INFLECTION ) ? 'i' : ' ',
+ ( point->flags & AF_FLAG_EXTREMA_X ) ? '<' : ' ',
+ ( point->flags & AF_FLAG_EXTREMA_Y ) ? 'v' : ' ',
+ ( point->flags & AF_FLAG_ROUND_X ) ? '(' : ' ',
+ ( point->flags & AF_FLAG_ROUND_Y ) ? 'u' : ' '));
+ FT_TRACE7(( "\n" ));
}
#ifdef __cplusplus
}
@@ -226,7 +235,7 @@
if ( pos == 0 )
return "normal";
- temp[pos] = 0;
+ temp[pos] = '\0';
return temp;
}
@@ -246,30 +255,41 @@
for ( dimension = 1; dimension >= 0; dimension-- )
{
AF_AxisHints axis = &hints->axis[dimension];
+ AF_Point points = hints->points;
+ AF_Edge edges = axis->edges;
AF_Segment segments = axis->segments;
AF_Segment limit = segments + axis->num_segments;
AF_Segment seg;
- printf ( "Table of %s segments:\n",
- dimension == AF_DIMENSION_HORZ ? "vertical" : "horizontal" );
- printf ( " [ index | pos | dir | link | serif |"
- " height | extra | flags ]\n" );
+ FT_TRACE7(( "Table of %s segments:\n",
+ dimension == AF_DIMENSION_HORZ ? "vertical"
+ : "horizontal" ));
+ if (axis->num_segments)
+ FT_TRACE7(( " [ index | pos | dir | from"
+ " | to | link | serif | edge"
+ " | height | extra | flags ]\n" ));
+ else
+ FT_TRACE7(( " (none)\n" ));
for ( seg = segments; seg < limit; seg++ )
- {
- printf ( " [ %5d | %5.2g | %5s | %4d | %5d | %6d | %5d | %11s ]\n",
- seg - segments,
- dimension == AF_DIMENSION_HORZ ? (int)seg->first->ox / 64.0
- : (int)seg->first->oy / 64.0,
- af_dir_str( (AF_Direction)seg->dir ),
- AF_INDEX_NUM( seg->link, segments ),
- AF_INDEX_NUM( seg->serif, segments ),
- seg->height,
- seg->height - ( seg->max_coord - seg->min_coord ),
- af_edge_flags_to_string( (AF_Edge_Flags)seg->flags ) );
- }
- printf( "\n" );
+ FT_TRACE7(( " [ %5d | %5.2g | %5s | %4d"
+ " | %4d | %4d | %5d | %4d"
+ " | %6d | %5d | %11s ]\n",
+ seg - segments,
+ dimension == AF_DIMENSION_HORZ
+ ? (int)seg->first->ox / 64.0
+ : (int)seg->first->oy / 64.0,
+ af_dir_str( (AF_Direction)seg->dir ),
+ AF_INDEX_NUM( seg->first, points ),
+ AF_INDEX_NUM( seg->last, points ),
+ AF_INDEX_NUM( seg->link, segments ),
+ AF_INDEX_NUM( seg->serif, segments ),
+ AF_INDEX_NUM( seg->edge, edges ),
+ seg->height,
+ seg->height - ( seg->max_coord - seg->min_coord ),
+ af_edge_flags_to_string( (AF_Edge_Flags)seg->flags ) ));
+ FT_TRACE7(( "\n" ));
}
}
#ifdef __cplusplus
@@ -363,26 +383,28 @@
* note: AF_DIMENSION_HORZ corresponds to _vertical_ edges
* since they have a constant X coordinate.
*/
- printf ( "Table of %s edges:\n",
- dimension == AF_DIMENSION_HORZ ? "vertical" : "horizontal" );
- printf ( " [ index | pos | dir | link |"
- " serif | blue | opos | pos | flags ]\n" );
+ FT_TRACE7(( "Table of %s edges:\n",
+ dimension == AF_DIMENSION_HORZ ? "vertical"
+ : "horizontal" ));
+ if ( axis->num_edges )
+ FT_TRACE7(( " [ index | pos | dir | link"
+ " | serif | blue | opos | pos | flags ]\n" ));
+ else
+ FT_TRACE7(( " (none)\n" ));
for ( edge = edges; edge < limit; edge++ )
- {
- printf ( " [ %5d | %5.2g | %5s | %4d |"
- " %5d | %c | %5.2f | %5.2f | %11s ]\n",
- edge - edges,
- (int)edge->opos / 64.0,
- af_dir_str( (AF_Direction)edge->dir ),
- AF_INDEX_NUM( edge->link, edges ),
- AF_INDEX_NUM( edge->serif, edges ),
- edge->blue_edge ? 'y' : 'n',
- edge->opos / 64.0,
- edge->pos / 64.0,
- af_edge_flags_to_string( (AF_Edge_Flags)edge->flags ) );
- }
- printf( "\n" );
+ FT_TRACE7(( " [ %5d | %5.2g | %5s | %4d"
+ " | %5d | %c | %5.2f | %5.2f | %11s ]\n",
+ edge - edges,
+ (int)edge->opos / 64.0,
+ af_dir_str( (AF_Direction)edge->dir ),
+ AF_INDEX_NUM( edge->link, edges ),
+ AF_INDEX_NUM( edge->serif, edges ),
+ edge->blue_edge ? 'y' : 'n',
+ edge->opos / 64.0,
+ edge->pos / 64.0,
+ af_edge_flags_to_string( (AF_Edge_Flags)edge->flags ) ));
+ FT_TRACE7(( "\n" ));
}
}
#ifdef __cplusplus
@@ -494,8 +516,8 @@
}
}
- /* return no direction if arm lengths differ too much */
- /* (value 14 is heuristic) */
+ /* return no direction if arm lengths differ too much */
+ /* (value 14 is heuristic, corresponding to approx. 4.1 degrees) */
ss *= 14;
if ( FT_ABS( ll ) <= FT_ABS( ss ) )
dir = AF_DIR_NONE;
@@ -516,40 +538,40 @@
FT_LOCAL_DEF( void )
af_glyph_hints_done( AF_GlyphHints hints )
{
- if ( hints && hints->memory )
- {
- FT_Memory memory = hints->memory;
- int dim;
+ FT_Memory memory = hints->memory;
+ int dim;
- /*
- * note that we don't need to free the segment and edge
- * buffers since they are really within the hints->points array
- */
- for ( dim = 0; dim < AF_DIMENSION_MAX; dim++ )
- {
- AF_AxisHints axis = &hints->axis[dim];
+ if ( !( hints && hints->memory ) )
+ return;
+ /*
+ * note that we don't need to free the segment and edge
+ * buffers since they are really within the hints->points array
+ */
+ for ( dim = 0; dim < AF_DIMENSION_MAX; dim++ )
+ {
+ AF_AxisHints axis = &hints->axis[dim];
- axis->num_segments = 0;
- axis->max_segments = 0;
- FT_FREE( axis->segments );
- axis->num_edges = 0;
- axis->max_edges = 0;
- FT_FREE( axis->edges );
- }
+ axis->num_segments = 0;
+ axis->max_segments = 0;
+ FT_FREE( axis->segments );
- FT_FREE( hints->contours );
- hints->max_contours = 0;
- hints->num_contours = 0;
+ axis->num_edges = 0;
+ axis->max_edges = 0;
+ FT_FREE( axis->edges );
+ }
- FT_FREE( hints->points );
- hints->num_points = 0;
- hints->max_points = 0;
+ FT_FREE( hints->contours );
+ hints->max_contours = 0;
+ hints->num_contours = 0;
- hints->memory = NULL;
- }
+ FT_FREE( hints->points );
+ hints->num_points = 0;
+ hints->max_points = 0;
+
+ hints->memory = NULL;
}
@@ -745,7 +767,7 @@
/* check for weak points */
- if ( point->flags & ( AF_FLAG_CONIC | AF_FLAG_CUBIC ) )
+ if ( point->flags & AF_FLAG_CONTROL )
{
Is_Weak_Point:
point->flags |= AF_FLAG_WEAK_INTERPOLATION;
diff --git a/3party/freetype/src/autofit/afhints.h b/3party/freetype/src/autofit/afhints.h
index 1c52e0de7e..776b3c844e 100644
--- a/3party/freetype/src/autofit/afhints.h
+++ b/3party/freetype/src/autofit/afhints.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines (specification). */
/* */
-/* Copyright 2003-2008, 2010-2011 by */
+/* Copyright 2003-2008, 2010-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -254,7 +254,7 @@ FT_BEGIN_HEADER
FT_Char out_dir; /* direction of outwards vector */
FT_Pos ox, oy; /* original, scaled position */
- FT_Short fx, fy; /* original, unscaled position (font units) */
+ FT_Short fx, fy; /* original, unscaled position (in font units) */
FT_Pos x, y; /* current position */
FT_Pos u, v; /* current (x,y) or (y,x) depending on context */
@@ -290,19 +290,19 @@ FT_BEGIN_HEADER
typedef struct AF_EdgeRec_
{
- FT_Short fpos; /* original, unscaled position (font units) */
- FT_Pos opos; /* original, scaled position */
- FT_Pos pos; /* current position */
+ FT_Short fpos; /* original, unscaled position (in font units) */
+ FT_Pos opos; /* original, scaled position */
+ FT_Pos pos; /* current position */
FT_Byte flags; /* edge flags */
FT_Char dir; /* edge direction */
FT_Fixed scale; /* used to speed up interpolation between edges */
- AF_Width blue_edge; /* non-NULL if this is a blue edge */
- AF_Edge link; /* link edge */
- AF_Edge serif; /* primary edge for serifs */
- FT_Short num_linked; /* number of linked edges */
- FT_Int score; /* used during stem matching */
+ AF_Width blue_edge; /* non-NULL if this is a blue edge */
+ AF_Edge link; /* link edge */
+ AF_Edge serif; /* primary edge for serifs */
+ FT_Short num_linked; /* number of linked edges */
+ FT_Int score; /* used during stem matching */
AF_Segment first; /* first segment in edge */
AF_Segment last; /* last segment in edge */
diff --git a/3party/freetype/src/autofit/afindic.c b/3party/freetype/src/autofit/afindic.c
index c232cff783..70de70ba99 100644
--- a/3party/freetype/src/autofit/afindic.c
+++ b/3party/freetype/src/autofit/afindic.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for Indic scripts (body). */
/* */
-/* Copyright 2007, 2011 by */
+/* Copyright 2007, 2011, 2012 by */
/* Rahul Bhalerao <rahul.bhalerao@redhat.com>, <b.rahul.pm@gmail.com>. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -46,7 +46,7 @@
face->charmap = NULL;
else
{
- af_cjk_metrics_init_widths( metrics, face, 0x7530 );
+ af_cjk_metrics_init_widths( metrics, face );
#if 0
/* either need indic specific blue_chars[] or just skip blue zones */
af_cjk_metrics_init_blues( metrics, face, af_cjk_blue_chars );
@@ -113,11 +113,12 @@
};
- AF_DEFINE_SCRIPT_CLASS(af_indic_script_class,
+ AF_DEFINE_SCRIPT_CLASS( af_indic_script_class,
AF_SCRIPT_INDIC,
af_indic_uniranges,
+ 'o', /* XXX */
- sizeof( AF_CJKMetricsRec ),
+ sizeof ( AF_CJKMetricsRec ),
(AF_Script_InitMetricsFunc) af_indic_metrics_init,
(AF_Script_ScaleMetricsFunc)af_indic_metrics_scale,
@@ -135,11 +136,12 @@
};
- AF_DEFINE_SCRIPT_CLASS(af_indic_script_class,
+ AF_DEFINE_SCRIPT_CLASS( af_indic_script_class,
AF_SCRIPT_INDIC,
af_indic_uniranges,
+ 0,
- sizeof( AF_CJKMetricsRec ),
+ sizeof ( AF_CJKMetricsRec ),
(AF_Script_InitMetricsFunc) NULL,
(AF_Script_ScaleMetricsFunc)NULL,
diff --git a/3party/freetype/src/autofit/afindic.h b/3party/freetype/src/autofit/afindic.h
index 662a982200..c252cf20da 100644
--- a/3party/freetype/src/autofit/afindic.h
+++ b/3party/freetype/src/autofit/afindic.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for Indic scripts (specification). */
/* */
-/* Copyright 2007 by */
+/* Copyright 2007, 2012 by */
/* Rahul Bhalerao <rahul.bhalerao@redhat.com>, <b.rahul.pm@gmail.com>. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -27,7 +27,7 @@ FT_BEGIN_HEADER
/* the Indic-specific script class */
- AF_DECLARE_SCRIPT_CLASS(af_indic_script_class)
+ AF_DECLARE_SCRIPT_CLASS( af_indic_script_class )
/* */
diff --git a/3party/freetype/src/autofit/aflatin.c b/3party/freetype/src/autofit/aflatin.c
index 54fcf7f0aa..8ebd49681a 100644
--- a/3party/freetype/src/autofit/aflatin.c
+++ b/3party/freetype/src/autofit/aflatin.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for latin script (body). */
/* */
-/* Copyright 2003-2011 by */
+/* Copyright 2003-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,6 +20,7 @@
#include FT_ADVANCES_H
#include FT_INTERNAL_DEBUG_H
+#include "afglobal.h"
#include "aflatin.h"
#include "aferrors.h"
@@ -53,30 +54,36 @@
FT_LOCAL_DEF( void )
af_latin_metrics_init_widths( AF_LatinMetrics metrics,
- FT_Face face,
- FT_ULong charcode )
+ FT_Face face )
{
/* scan the array of segments in each direction */
AF_GlyphHintsRec hints[1];
+ FT_TRACE5(( "standard widths computation\n"
+ "===========================\n\n" ));
+
af_glyph_hints_init( hints, face->memory );
metrics->axis[AF_DIMENSION_HORZ].width_count = 0;
metrics->axis[AF_DIMENSION_VERT].width_count = 0;
{
- FT_Error error;
- FT_UInt glyph_index;
- int dim;
- AF_LatinMetricsRec dummy[1];
- AF_Scaler scaler = &dummy->root.scaler;
+ FT_Error error;
+ FT_UInt glyph_index;
+ int dim;
+ AF_LatinMetricsRec dummy[1];
+ AF_Scaler scaler = &dummy->root.scaler;
- glyph_index = FT_Get_Char_Index( face, charcode );
+ glyph_index = FT_Get_Char_Index( face,
+ metrics->root.clazz->standard_char );
if ( glyph_index == 0 )
goto Exit;
+ FT_TRACE5(( "standard character: 0x%X (glyph index %d)\n",
+ metrics->root.clazz->standard_char, glyph_index ));
+
error = FT_Load_Glyph( face, glyph_index, FT_LOAD_NO_SCALE );
if ( error || face->glyph->outline.n_points <= 0 )
goto Exit;
@@ -138,7 +145,10 @@
}
}
- af_sort_widths( num_widths, axis->widths );
+ /* this also replaces multiple almost identical stem widths */
+ /* with a single one (the value 100 is heuristic) */
+ af_sort_and_quantize_widths( &num_widths, axis->widths,
+ dummy->units_per_em / 100 );
axis->width_count = num_widths;
}
@@ -157,9 +167,28 @@
axis->edge_distance_threshold = stdw / 5;
axis->standard_width = stdw;
axis->extra_light = 0;
+
+#ifdef FT_DEBUG_LEVEL_TRACE
+ {
+ FT_UInt i;
+
+
+ FT_TRACE5(( "%s widths:\n",
+ dim == AF_DIMENSION_VERT ? "horizontal"
+ : "vertical" ));
+
+ FT_TRACE5(( " %d (standard)", axis->standard_width ));
+ for ( i = 1; i < axis->width_count; i++ )
+ FT_TRACE5(( " %d", axis->widths[i].org ));
+
+ FT_TRACE5(( "\n" ));
+ }
+#endif
}
}
+ FT_TRACE5(( "\n" ));
+
af_glyph_hints_done( hints );
}
@@ -195,15 +224,15 @@
AF_LatinBlue blue;
FT_Error error;
AF_LatinAxis axis = &metrics->axis[AF_DIMENSION_VERT];
- FT_GlyphSlot glyph = face->glyph;
+ FT_Outline outline;
/* we compute the blues simply by loading each character from the */
/* `af_latin_blue_chars[blues]' string, then finding its top-most or */
/* bottom-most points (depending on `AF_IS_TOP_BLUE') */
- FT_TRACE5(( "blue zones computation\n" ));
- FT_TRACE5(( "------------------------------------------------\n" ));
+ FT_TRACE5(( "blue zones computation\n"
+ "======================\n\n" ));
for ( bb = 0; bb < AF_LATIN_BLUE_MAX; bb++ )
{
@@ -213,7 +242,7 @@
FT_Pos* blue_shoot;
- FT_TRACE5(( "blue %3d: ", bb ));
+ FT_TRACE5(( "blue zone %d:\n", bb ));
num_flats = 0;
num_rounds = 0;
@@ -222,28 +251,27 @@
{
FT_UInt glyph_index;
FT_Pos best_y; /* same as points.y */
- FT_Int best_point, best_first, best_last;
+ FT_Int best_point, best_contour_first, best_contour_last;
FT_Vector* points;
FT_Bool round = 0;
- FT_TRACE5(( "'%c'", *p ));
-
/* load the character in the face -- skip unknown or empty ones */
glyph_index = FT_Get_Char_Index( face, (FT_UInt)*p );
if ( glyph_index == 0 )
continue;
- error = FT_Load_Glyph( face, glyph_index, FT_LOAD_NO_SCALE );
- if ( error || glyph->outline.n_points <= 0 )
+ error = FT_Load_Glyph( face, glyph_index, FT_LOAD_NO_SCALE );
+ outline = face->glyph->outline;
+ if ( error || outline.n_points <= 0 )
continue;
/* now compute min or max point indices and coordinates */
- points = glyph->outline.points;
- best_point = -1;
- best_y = 0; /* make compiler happy */
- best_first = 0; /* ditto */
- best_last = 0; /* ditto */
+ points = outline.points;
+ best_point = -1;
+ best_y = 0; /* make compiler happy */
+ best_contour_first = 0; /* ditto */
+ best_contour_last = 0; /* ditto */
{
FT_Int nn;
@@ -251,15 +279,13 @@
FT_Int last = -1;
- for ( nn = 0;
- nn < glyph->outline.n_contours;
- first = last + 1, nn++ )
+ for ( nn = 0; nn < outline.n_contours; first = last + 1, nn++ )
{
FT_Int old_best_point = best_point;
FT_Int pp;
- last = glyph->outline.contours[nn];
+ last = outline.contours[nn];
/* Avoid single-point contours since they are never rasterized. */
/* In some fonts, they correspond to mark attachment points */
@@ -288,11 +314,11 @@
if ( best_point != old_best_point )
{
- best_first = first;
- best_last = last;
+ best_contour_first = first;
+ best_contour_last = last;
}
}
- FT_TRACE5(( "%5d", best_y ));
+ FT_TRACE5(( " %c %ld", *p, best_y ));
}
/* now check whether the point belongs to a straight or round */
@@ -300,47 +326,86 @@
/* lies, then inspect its previous and next points */
if ( best_point >= 0 )
{
+ FT_Pos best_x = points[best_point].x;
FT_Int prev, next;
+ FT_Int best_on_point_first, best_on_point_last;
FT_Pos dist;
- /* now look for the previous and next points that are not on the */
- /* same Y coordinate. Threshold the `closeness'... */
+ if ( FT_CURVE_TAG( outline.tags[best_point] ) == FT_CURVE_TAG_ON )
+ {
+ best_on_point_first = best_point;
+ best_on_point_last = best_point;
+ }
+ else
+ {
+ best_on_point_first = -1;
+ best_on_point_last = -1;
+ }
+
+ /* look for the previous and next points that are not on the */
+ /* same Y coordinate, then threshold the `closeness'... */
prev = best_point;
next = prev;
do
{
- if ( prev > best_first )
+ if ( prev > best_contour_first )
prev--;
else
- prev = best_last;
+ prev = best_contour_last;
- dist = points[prev].y - best_y;
- if ( dist < -5 || dist > 5 )
- break;
+ dist = FT_ABS( points[prev].y - best_y );
+ /* accept a small distance or a small angle (both values are */
+ /* heuristic; value 20 corresponds to approx. 2.9 degrees) */
+ if ( dist > 5 )
+ if ( FT_ABS( points[prev].x - best_x ) <= 20 * dist )
+ break;
+
+ if ( FT_CURVE_TAG( outline.tags[prev] ) == FT_CURVE_TAG_ON )
+ {
+ best_on_point_first = prev;
+ if ( best_on_point_last < 0 )
+ best_on_point_last = prev;
+ }
} while ( prev != best_point );
do
{
- if ( next < best_last )
+ if ( next < best_contour_last )
next++;
else
- next = best_first;
+ next = best_contour_first;
- dist = points[next].y - best_y;
- if ( dist < -5 || dist > 5 )
- break;
+ dist = FT_ABS( points[next].y - best_y );
+ if ( dist > 5 )
+ if ( FT_ABS( points[next].x - best_x ) <= 20 * dist )
+ break;
+
+ if ( FT_CURVE_TAG( outline.tags[next] ) == FT_CURVE_TAG_ON )
+ {
+ best_on_point_last = next;
+ if ( best_on_point_first < 0 )
+ best_on_point_first = next;
+ }
} while ( next != best_point );
/* now set the `round' flag depending on the segment's kind */
- round = FT_BOOL(
- FT_CURVE_TAG( glyph->outline.tags[prev] ) != FT_CURVE_TAG_ON ||
- FT_CURVE_TAG( glyph->outline.tags[next] ) != FT_CURVE_TAG_ON );
+ /* (value 8 is heuristic) */
+ if ( best_on_point_first >= 0 &&
+ best_on_point_last >= 0 &&
+ (FT_UInt)( FT_ABS( points[best_on_point_last].x -
+ points[best_on_point_first].x ) ) >
+ metrics->units_per_em / 8 )
+ round = 0;
+ else
+ round = FT_BOOL(
+ FT_CURVE_TAG( outline.tags[prev] ) != FT_CURVE_TAG_ON ||
+ FT_CURVE_TAG( outline.tags[next] ) != FT_CURVE_TAG_ON );
- FT_TRACE5(( "%c ", round ? 'r' : 'f' ));
+ FT_TRACE5(( " (%s)\n", round ? "round" : "flat" ));
}
if ( round )
@@ -349,15 +414,13 @@
flats[num_flats++] = best_y;
}
- FT_TRACE5(( "\n" ));
-
if ( num_flats == 0 && num_rounds == 0 )
{
/*
* we couldn't find a single glyph to compute this blue zone,
* we will simply ignore it then
*/
- FT_TRACE5(( "empty\n" ));
+ FT_TRACE5(( " empty\n" ));
continue;
}
@@ -400,8 +463,13 @@
if ( AF_LATIN_IS_TOP_BLUE( bb ) ^ over_ref )
+ {
*blue_ref =
*blue_shoot = ( shoot + ref ) / 2;
+
+ FT_TRACE5(( " [overshoot smaller than reference,"
+ " taking mean value]\n" ));
+ }
}
blue->flags = 0;
@@ -416,7 +484,9 @@
if ( bb == AF_LATIN_BLUE_SMALL_TOP )
blue->flags |= AF_LATIN_BLUE_ADJUSTMENT;
- FT_TRACE5(( "-- ref = %ld, shoot = %ld\n", *blue_ref, *blue_shoot ));
+ FT_TRACE5(( " -> reference = %ld\n"
+ " overshoot = %ld\n",
+ *blue_ref, *blue_shoot ));
}
FT_TRACE5(( "\n" ));
@@ -478,35 +548,14 @@
af_latin_metrics_init( AF_LatinMetrics metrics,
FT_Face face )
{
- FT_Error error = AF_Err_Ok;
FT_CharMap oldmap = face->charmap;
- FT_UInt ee;
-
- static const FT_Encoding latin_encodings[] =
- {
- FT_ENCODING_UNICODE,
- FT_ENCODING_APPLE_ROMAN,
- FT_ENCODING_ADOBE_STANDARD,
- FT_ENCODING_ADOBE_LATIN_1,
-
- FT_ENCODING_NONE /* end of list */
- };
metrics->units_per_em = face->units_per_EM;
- /* do we have a latin charmap in there? */
- for ( ee = 0; latin_encodings[ee] != FT_ENCODING_NONE; ee++ )
- {
- error = FT_Select_Charmap( face, latin_encodings[ee] );
- if ( !error )
- break;
- }
-
- if ( !error )
+ if ( !FT_Select_Charmap( face, FT_ENCODING_UNICODE ) )
{
- /* For now, compute the standard width and height from the `o'. */
- af_latin_metrics_init_widths( metrics, face, 'o' );
+ af_latin_metrics_init_widths( metrics, face );
af_latin_metrics_init_blues( metrics, face );
af_latin_metrics_check_digits( metrics, face );
}
@@ -569,9 +618,26 @@
if ( blue )
{
- FT_Pos scaled = FT_MulFix( blue->shoot.org, scaler->y_scale );
- FT_Pos fitted = ( scaled + 40 ) & ~63;
+ FT_Pos scaled;
+ FT_Pos threshold;
+ FT_Pos fitted;
+ FT_UInt limit;
+ FT_UInt ppem;
+
+
+ scaled = FT_MulFix( blue->shoot.org, scaler->y_scale );
+ ppem = metrics->root.scaler.face->size->metrics.x_ppem;
+ limit = metrics->root.globals->increase_x_height;
+ threshold = 40;
+
+ /* if the `increase-x-height' property is active, */
+ /* we round up much more often */
+ if ( limit &&
+ ppem <= limit &&
+ ppem >= AF_PROP_INCREASE_X_HEIGHT_MIN )
+ threshold = 52;
+ fitted = ( scaled + threshold ) & ~63;
if ( scaled != fitted )
{
@@ -705,6 +771,7 @@
{
metrics->root.scaler.render_mode = scaler->render_mode;
metrics->root.scaler.face = scaler->face;
+ metrics->root.scaler.flags = scaler->flags;
af_latin_metrics_scale_dim( metrics, scaler, AF_DIMENSION_HORZ );
af_latin_metrics_scale_dim( metrics, scaler, AF_DIMENSION_VERT );
@@ -848,7 +915,7 @@
on_edge = 0;
segment = NULL;
- /* fallthrough */
+ /* fall through */
}
}
@@ -884,8 +951,8 @@
} /* contours */
- /* now slightly increase the height of segments when this makes */
- /* sense -- this is used to better detect and ignore serifs */
+ /* now slightly increase the height of segments if this makes */
+ /* sense -- this is used to better detect and ignore serifs */
{
AF_Segment segments = axis->segments;
AF_Segment segments_end = segments + axis->num_segments;
@@ -1169,17 +1236,17 @@
}
- /*********************************************************************/
- /* */
- /* Good, we will now compute each edge's properties according to */
- /* the segments found on its position. Basically, these are */
- /* */
- /* - the edge's main direction */
- /* - stem edge, serif edge or both (which defaults to stem then) */
- /* - rounded edge, straight or both (which defaults to straight) */
- /* - link for edge */
- /* */
- /*********************************************************************/
+ /******************************************************************/
+ /* */
+ /* Good, we now compute each edge's properties according to the */
+ /* segments found on its position. Basically, these are */
+ /* */
+ /* - the edge's main direction */
+ /* - stem edge, serif edge or both (which defaults to stem then) */
+ /* - rounded edge, straight or both (which defaults to straight) */
+ /* - link for edge */
+ /* */
+ /******************************************************************/
/* first of all, set the `edge' field in each segment -- this is */
/* required in order to compute edge links */
@@ -1367,7 +1434,7 @@
/* for each horizontal edge search the blue zone which is closest */
for ( ; edge < edge_limit; edge++ )
{
- FT_Int bb;
+ FT_UInt bb;
AF_Width best_blue = NULL;
FT_Pos best_dist; /* initial threshold */
@@ -1380,7 +1447,7 @@
if ( best_dist > 64 / 2 )
best_dist = 64 / 2;
- for ( bb = 0; bb < AF_LATIN_BLUE_MAX; bb++ )
+ for ( bb = 0; bb < latin->blue_count; bb++ )
{
AF_LatinBlue blue = latin->blues + bb;
FT_Bool is_top_blue, is_major_dir;
@@ -1476,9 +1543,7 @@
#if 0 /* #ifdef AF_CONFIG_OPTION_USE_WARPER */
if ( mode == FT_RENDER_MODE_LCD || mode == FT_RENDER_MODE_LCD_V )
- {
metrics->root.scaler.render_mode = mode = FT_RENDER_MODE_NORMAL;
- }
#endif
scaler_flags = hints->scaler_flags;
@@ -1762,7 +1827,7 @@
stem_edge->pos = base_edge->pos + fitted_width;
- FT_TRACE5(( " LINK: edge %d (opos=%.2f) linked to (%.2f),"
+ FT_TRACE5(( " LINK: edge %d (opos=%.2f) linked to %.2f,"
" dist was %.2f, now %.2f\n",
stem_edge-hints->axis[dim].edges, stem_edge->opos / 64.0,
stem_edge->pos / 64.0, dist / 64.0, fitted_width / 64.0 ));
@@ -1808,9 +1873,13 @@
AF_Edge anchor = NULL;
FT_Int has_serifs = 0;
+#ifdef FT_DEBUG_LEVEL_TRACE
+ FT_UInt num_actions = 0;
+#endif
+
- FT_TRACE5(("%s edge hinting\n", dim == AF_DIMENSION_VERT ? "horizontal"
- : "vertical"));
+ FT_TRACE5(( "%s edge hinting\n",
+ dim == AF_DIMENSION_VERT ? "horizontal" : "vertical" ));
/* we begin by aligning all stems relative to the blue zone */
/* if needed -- that's only for horizontal edges */
@@ -1844,10 +1913,20 @@
if ( !edge1 )
continue;
- FT_TRACE5(( " BLUE: edge %d (opos=%.2f) snapped to (%.2f),"
- " was (%.2f)\n",
- edge1 - edges, edge1->opos / 64.0, blue->fit / 64.0,
- edge1->pos / 64.0 ));
+#ifdef FT_DEBUG_LEVEL_TRACE
+ if (!anchor)
+ FT_TRACE5(( " BLUE_ANCHOR: edge %d (opos=%.2f) snapped to %.2f,"
+ " was %.2f (anchor=edge %d)\n",
+ edge1 - edges, edge1->opos / 64.0, blue->fit / 64.0,
+ edge1->pos / 64.0, edge - edges ));
+ else
+ FT_TRACE5(( " BLUE: edge %d (opos=%.2f) snapped to %.2f,"
+ " was %.2f\n",
+ edge1 - edges, edge1->opos / 64.0, blue->fit / 64.0,
+ edge1->pos / 64.0 ));
+
+ num_actions++;
+#endif
edge1->pos = blue->fit;
edge1->flags |= AF_EDGE_DONE;
@@ -1856,6 +1935,10 @@
{
af_latin_align_linked_edge( hints, dim, edge1, edge2 );
edge2->flags |= AF_EDGE_DONE;
+
+#ifdef FT_DEBUG_LEVEL_TRACE
+ num_actions++;
+#endif
}
if ( !anchor )
@@ -1890,6 +1973,10 @@
af_latin_align_linked_edge( hints, dim, edge2, edge );
edge->flags |= AF_EDGE_DONE;
+
+#ifdef FT_DEBUG_LEVEL_TRACE
+ num_actions++;
+#endif
continue;
}
@@ -1947,16 +2034,20 @@
else
edge->pos = FT_PIX_ROUND( edge->opos );
+ anchor = edge;
+ edge->flags |= AF_EDGE_DONE;
+
FT_TRACE5(( " ANCHOR: edge %d (opos=%.2f) and %d (opos=%.2f)"
- " snapped to (%.2f) (%.2f)\n",
+ " snapped to %.2f and %.2f\n",
edge - edges, edge->opos / 64.0,
edge2 - edges, edge2->opos / 64.0,
edge->pos / 64.0, edge2->pos / 64.0 ));
- anchor = edge;
-
- edge->flags |= AF_EDGE_DONE;
af_latin_align_linked_edge( hints, dim, edge, edge2 );
+
+#ifdef FT_DEBUG_LEVEL_TRACE
+ num_actions += 2;
+#endif
}
else
{
@@ -2016,12 +2107,13 @@
edge->pos = cur_pos1 - cur_len / 2;
edge2->pos = cur_pos1 + cur_len / 2;
- FT_TRACE5(( " STEM: %d (opos=%.2f) to %d (opos=%.2f)"
- " snapped to (%.2f) and (%.2f)\n",
+ FT_TRACE5(( " STEM: edge %d (opos=%.2f) linked to %d (opos=%.2f)"
+ " snapped to %.2f and %.2f\n",
edge - edges, edge->opos / 64.0,
edge2 - edges, edge2->opos / 64.0,
edge->pos / 64.0, edge2->pos / 64.0 ));
}
+
else
{
org_pos = anchor->pos + ( edge->opos - anchor->opos );
@@ -2046,20 +2138,29 @@
edge->pos = ( delta1 < delta2 ) ? cur_pos1 : cur_pos2;
edge2->pos = edge->pos + cur_len;
- FT_TRACE5(( " STEM: %d (opos=%.2f) to %d (opos=%.2f)"
- " snapped to (%.2f) and (%.2f)\n",
+ FT_TRACE5(( " STEM: edge %d (opos=%.2f) linked to %d (opos=%.2f)"
+ " snapped to %.2f and %.2f\n",
edge - edges, edge->opos / 64.0,
edge2 - edges, edge2->opos / 64.0,
edge->pos / 64.0, edge2->pos / 64.0 ));
}
+#ifdef FT_DEBUG_LEVEL_TRACE
+ num_actions++;
+#endif
+
edge->flags |= AF_EDGE_DONE;
edge2->flags |= AF_EDGE_DONE;
if ( edge > edges && edge->pos < edge[-1].pos )
{
- FT_TRACE5(( " BOUND: %d (pos=%.2f) to (%.2f)\n",
+#ifdef FT_DEBUG_LEVEL_TRACE
+ FT_TRACE5(( " BOUND: edge %d (pos=%.2f) moved to %.2f\n",
edge - edges, edge->pos / 64.0, edge[-1].pos / 64.0 ));
+
+ num_actions++;
+#endif
+
edge->pos = edge[-1].pos;
}
}
@@ -2154,7 +2255,7 @@
{
af_latin_align_serif_edge( hints, edge->serif, edge );
FT_TRACE5(( " SERIF: edge %d (opos=%.2f) serif to %d (opos=%.2f)"
- " aligned to (%.2f)\n",
+ " aligned to %.2f\n",
edge - edges, edge->opos / 64.0,
edge->serif - edges, edge->serif->opos / 64.0,
edge->pos / 64.0 ));
@@ -2164,7 +2265,7 @@
edge->pos = FT_PIX_ROUND( edge->opos );
anchor = edge;
FT_TRACE5(( " SERIF_ANCHOR: edge %d (opos=%.2f)"
- " snapped to (%.2f)\n",
+ " snapped to %.2f\n",
edge-edges, edge->opos / 64.0, edge->pos / 64.0 ));
}
else
@@ -2191,7 +2292,7 @@
after->pos - before->pos,
after->opos - before->opos );
- FT_TRACE5(( " SERIF_LINK1: edge %d (opos=%.2f) snapped to (%.2f)"
+ FT_TRACE5(( " SERIF_LINK1: edge %d (opos=%.2f) snapped to %.2f"
" from %d (opos=%.2f)\n",
edge - edges, edge->opos / 64.0,
edge->pos / 64.0,
@@ -2201,26 +2302,49 @@
{
edge->pos = anchor->pos +
( ( edge->opos - anchor->opos + 16 ) & ~31 );
-
FT_TRACE5(( " SERIF_LINK2: edge %d (opos=%.2f)"
- " snapped to (%.2f)\n",
+ " snapped to %.2f\n",
edge - edges, edge->opos / 64.0, edge->pos / 64.0 ));
}
}
+#ifdef FT_DEBUG_LEVEL_TRACE
+ num_actions++;
+#endif
edge->flags |= AF_EDGE_DONE;
if ( edge > edges && edge->pos < edge[-1].pos )
+ {
+#ifdef FT_DEBUG_LEVEL_TRACE
+ FT_TRACE5(( " BOUND: edge %d (pos=%.2f) moved to %.2f\n",
+ edge - edges, edge->pos / 64.0, edge[-1].pos / 64.0 ));
+
+ num_actions++;
+#endif
edge->pos = edge[-1].pos;
+ }
if ( edge + 1 < edge_limit &&
edge[1].flags & AF_EDGE_DONE &&
edge->pos > edge[1].pos )
+ {
+#ifdef FT_DEBUG_LEVEL_TRACE
+ FT_TRACE5(( " BOUND: edge %d (pos=%.2f) moved to %.2f\n",
+ edge - edges, edge->pos / 64.0, edge[1].pos / 64.0 ));
+
+ num_actions++;
+#endif
+
edge->pos = edge[1].pos;
+ }
}
}
+#ifdef FT_DEBUG_LEVEL_TRACE
+ if ( !num_actions )
+ FT_TRACE5(( " (none)\n" ));
FT_TRACE5(( "\n" ));
+#endif
}
@@ -2333,19 +2457,22 @@
AF_UNIRANGE_REC( 0x2460UL, 0x24FFUL ), /* Enclosed Alphanumerics */
AF_UNIRANGE_REC( 0x2C60UL, 0x2C7FUL ), /* Latin Extended-C */
AF_UNIRANGE_REC( 0x2DE0UL, 0x2DFFUL ), /* Cyrillic Extended-A */
+ AF_UNIRANGE_REC( 0x2E00UL, 0x2E7FUL ), /* Supplemental Punctuation */
AF_UNIRANGE_REC( 0xA640UL, 0xA69FUL ), /* Cyrillic Extended-B */
AF_UNIRANGE_REC( 0xA720UL, 0xA7FFUL ), /* Latin Extended-D */
AF_UNIRANGE_REC( 0xFB00UL, 0xFB06UL ), /* Alphab. Present. Forms (Latin Ligs) */
AF_UNIRANGE_REC( 0x1D400UL, 0x1D7FFUL ), /* Mathematical Alphanumeric Symbols */
+ AF_UNIRANGE_REC( 0x1F100UL, 0x1F1FFUL ), /* Enclosed Alphanumeric Supplement */
AF_UNIRANGE_REC( 0UL, 0UL )
};
- AF_DEFINE_SCRIPT_CLASS(af_latin_script_class,
+ AF_DEFINE_SCRIPT_CLASS( af_latin_script_class,
AF_SCRIPT_LATIN,
af_latin_uniranges,
+ 'o',
- sizeof( AF_LatinMetricsRec ),
+ sizeof ( AF_LatinMetricsRec ),
(AF_Script_InitMetricsFunc) af_latin_metrics_init,
(AF_Script_ScaleMetricsFunc)af_latin_metrics_scale,
diff --git a/3party/freetype/src/autofit/aflatin.h b/3party/freetype/src/autofit/aflatin.h
index c5c2d13f8d..d9170b3dcc 100644
--- a/3party/freetype/src/autofit/aflatin.h
+++ b/3party/freetype/src/autofit/aflatin.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for latin script (specification). */
/* */
-/* Copyright 2003-2007, 2009, 2011 by */
+/* Copyright 2003-2007, 2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -27,7 +27,7 @@ FT_BEGIN_HEADER
/* the latin-specific script class */
- AF_DECLARE_SCRIPT_CLASS(af_latin_script_class)
+ AF_DECLARE_SCRIPT_CLASS( af_latin_script_class )
/* constants are given with units_per_em == 2048 in mind */
@@ -133,8 +133,7 @@ FT_BEGIN_HEADER
FT_LOCAL( void )
af_latin_metrics_init_widths( AF_LatinMetrics metrics,
- FT_Face face,
- FT_ULong charcode );
+ FT_Face face );
FT_LOCAL( void )
af_latin_metrics_check_digits( AF_LatinMetrics metrics,
@@ -174,25 +173,17 @@ FT_BEGIN_HEADER
/*
- * This shouldn't normally be exported. However, other scripts might
- * like to use this function as-is.
+ * The next functions shouldn't normally be exported. However, other
+ * scripts might like to use these functions as-is.
*/
FT_LOCAL( FT_Error )
af_latin_hints_compute_segments( AF_GlyphHints hints,
AF_Dimension dim );
- /*
- * This shouldn't normally be exported. However, other scripts might
- * want to use this function as-is.
- */
FT_LOCAL( void )
af_latin_hints_link_segments( AF_GlyphHints hints,
AF_Dimension dim );
- /*
- * This shouldn't normally be exported. However, other scripts might
- * want to use this function as-is.
- */
FT_LOCAL( FT_Error )
af_latin_hints_compute_edges( AF_GlyphHints hints,
AF_Dimension dim );
diff --git a/3party/freetype/src/autofit/aflatin2.c b/3party/freetype/src/autofit/aflatin2.c
index 23558b8790..40a5ffd6ad 100644
--- a/3party/freetype/src/autofit/aflatin2.c
+++ b/3party/freetype/src/autofit/aflatin2.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for latin script (body). */
/* */
-/* Copyright 2003-2011 by */
+/* Copyright 2003-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,6 +18,7 @@
#include FT_ADVANCES_H
+#include "afglobal.h"
#include "aflatin.h"
#include "aflatin2.h"
#include "aferrors.h"
@@ -56,8 +57,7 @@
FT_LOCAL_DEF( void )
af_latin2_metrics_init_widths( AF_LatinMetrics metrics,
- FT_Face face,
- FT_ULong charcode )
+ FT_Face face )
{
/* scan the array of segments in each direction */
AF_GlyphHintsRec hints[1];
@@ -76,7 +76,8 @@
AF_Scaler scaler = &dummy->root.scaler;
- glyph_index = FT_Get_Char_Index( face, charcode );
+ glyph_index = FT_Get_Char_Index( face,
+ metrics->root.clazz->standard_char );
if ( glyph_index == 0 )
goto Exit;
@@ -133,7 +134,7 @@
dist = -dist;
if ( num_widths < AF_LATIN_MAX_WIDTHS )
- axis->widths[ num_widths++ ].org = dist;
+ axis->widths[num_widths++].org = dist;
}
}
@@ -198,8 +199,8 @@
/* 'af_latin2_blue_chars[blues]' string, then compute its top-most or */
/* bottom-most points (depending on `AF_IS_TOP_BLUE') */
- FT_TRACE5(( "blue zones computation\n" ));
- FT_TRACE5(( "------------------------------------------------\n" ));
+ FT_TRACE5(( "blue zones computation\n"
+ "======================\n\n" ));
for ( bb = 0; bb < AF_LATIN_BLUE_MAX; bb++ )
{
@@ -209,7 +210,7 @@
FT_Pos* blue_shoot;
- FT_TRACE5(( "blue %3d: ", bb ));
+ FT_TRACE5(( "blue zone %d:\n", bb ));
num_flats = 0;
num_rounds = 0;
@@ -222,8 +223,6 @@
FT_Bool round;
- FT_TRACE5(( "'%c'", *p ));
-
/* load the character in the face -- skip unknown or empty ones */
glyph_index = FT_Get_Char_Index( face, (FT_UInt)*p );
if ( glyph_index == 0 )
@@ -285,13 +284,14 @@
best_last = last;
}
}
- FT_TRACE5(( "%5d", best_y ));
+ FT_TRACE5(( " %c %d", *p, best_y ));
}
/* now check whether the point belongs to a straight or round */
/* segment; we first need to find in which contour the extremum */
/* lies, then inspect its previous and next points */
{
+ FT_Pos best_x = points[best_point].x;
FT_Int start, end, prev, next;
FT_Pos dist;
@@ -302,13 +302,16 @@
do
{
- prev = start-1;
+ prev = start - 1;
if ( prev < best_first )
prev = best_last;
- dist = points[prev].y - best_y;
- if ( dist < -5 || dist > 5 )
- break;
+ dist = FT_ABS( points[prev].y - best_y );
+ /* accept a small distance or a small angle (both values are */
+ /* heuristic; value 20 corresponds to approx. 2.9 degrees) */
+ if ( dist > 5 )
+ if ( FT_ABS( points[prev].x - best_x ) <= 20 * dist )
+ break;
start = prev;
@@ -316,13 +319,14 @@
do
{
- next = end+1;
+ next = end + 1;
if ( next > best_last )
next = best_first;
- dist = points[next].y - best_y;
- if ( dist < -5 || dist > 5 )
- break;
+ dist = FT_ABS( points[next].y - best_y );
+ if ( dist > 5 )
+ if ( FT_ABS( points[next].x - best_x ) <= 20 * dist )
+ break;
end = next;
@@ -333,7 +337,7 @@
FT_CURVE_TAG( glyph->outline.tags[start] ) != FT_CURVE_TAG_ON ||
FT_CURVE_TAG( glyph->outline.tags[ end ] ) != FT_CURVE_TAG_ON );
- FT_TRACE5(( "%c ", round ? 'r' : 'f' ));
+ FT_TRACE5(( " (%s)\n", round ? "round" : "flat" ));
}
if ( round )
@@ -342,15 +346,13 @@
flats[num_flats++] = best_y;
}
- FT_TRACE5(( "\n" ));
-
if ( num_flats == 0 && num_rounds == 0 )
{
/*
* we couldn't find a single glyph to compute this blue zone,
* we will simply ignore it then
*/
- FT_TRACE5(( "empty\n" ));
+ FT_TRACE5(( " empty\n" ));
continue;
}
@@ -393,7 +395,13 @@
if ( AF_LATIN_IS_TOP_BLUE( bb ) ^ over_ref )
- *blue_shoot = *blue_ref = ( shoot + ref ) / 2;
+ {
+ *blue_ref =
+ *blue_shoot = ( shoot + ref ) / 2;
+
+ FT_TRACE5(( " [overshoot smaller than reference,"
+ " taking mean value]\n" ));
+ }
}
blue->flags = 0;
@@ -408,7 +416,9 @@
if ( bb == AF_LATIN_BLUE_SMALL_TOP )
blue->flags |= AF_LATIN_BLUE_ADJUSTMENT;
- FT_TRACE5(( "-- ref = %ld, shoot = %ld\n", *blue_ref, *blue_shoot ));
+ FT_TRACE5(( " -> reference = %ld\n"
+ " overshoot = %ld\n",
+ *blue_ref, *blue_shoot ));
}
return;
@@ -491,8 +501,7 @@
if ( !error )
{
- /* For now, compute the standard width and height from the `o'. */
- af_latin2_metrics_init_widths( metrics, face, 'o' );
+ af_latin2_metrics_init_widths( metrics, face );
af_latin2_metrics_init_blues( metrics, face );
af_latin2_metrics_check_digits( metrics, face );
}
@@ -553,8 +562,26 @@
if ( blue )
{
- FT_Pos scaled = FT_MulFix( blue->shoot.org, scaler->y_scale );
- FT_Pos fitted = ( scaled + 40 ) & ~63;
+ FT_Pos scaled;
+ FT_Pos threshold;
+ FT_Pos fitted;
+ FT_UInt limit;
+ FT_UInt ppem;
+
+
+ scaled = FT_MulFix( blue->shoot.org, scaler->y_scale );
+ ppem = metrics->root.scaler.face->size->metrics.x_ppem;
+ limit = metrics->root.globals->increase_x_height;
+ threshold = 40;
+
+ /* if the `increase-x-height' property is active, */
+ /* we round up much more often */
+ if ( limit &&
+ ppem <= limit &&
+ ppem >= AF_PROP_INCREASE_X_HEIGHT_MIN )
+ threshold = 52;
+
+ fitted = ( scaled + threshold ) & ~63;
#if 1
if ( scaled != fitted )
@@ -658,6 +685,7 @@
{
metrics->root.scaler.render_mode = scaler->render_mode;
metrics->root.scaler.face = scaler->face;
+ metrics->root.scaler.flags = scaler->flags;
af_latin2_metrics_scale_dim( metrics, scaler, AF_DIMENSION_HORZ );
af_latin2_metrics_scale_dim( metrics, scaler, AF_DIMENSION_VERT );
@@ -1359,10 +1387,10 @@
af_latin2_hints_compute_blue_edges( AF_GlyphHints hints,
AF_LatinMetrics metrics )
{
- AF_AxisHints axis = &hints->axis[ AF_DIMENSION_VERT ];
+ AF_AxisHints axis = &hints->axis[AF_DIMENSION_VERT];
AF_Edge edge = axis->edges;
AF_Edge edge_limit = edge + axis->num_edges;
- AF_LatinAxis latin = &metrics->axis[ AF_DIMENSION_VERT ];
+ AF_LatinAxis latin = &metrics->axis[AF_DIMENSION_VERT];
FT_Fixed scale = latin->scale;
FT_Pos best_dist0; /* initial threshold */
@@ -2356,11 +2384,12 @@
};
- AF_DEFINE_SCRIPT_CLASS(af_latin2_script_class,
+ AF_DEFINE_SCRIPT_CLASS( af_latin2_script_class,
AF_SCRIPT_LATIN2,
af_latin2_uniranges,
+ 'o',
- sizeof( AF_LatinMetricsRec ),
+ sizeof ( AF_LatinMetricsRec ),
(AF_Script_InitMetricsFunc) af_latin2_metrics_init,
(AF_Script_ScaleMetricsFunc)af_latin2_metrics_scale,
diff --git a/3party/freetype/src/autofit/aflatin2.h b/3party/freetype/src/autofit/aflatin2.h
index 925c6214db..cbfa395522 100644
--- a/3party/freetype/src/autofit/aflatin2.h
+++ b/3party/freetype/src/autofit/aflatin2.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for latin script (specification). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 2003-2007, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -27,7 +27,7 @@ FT_BEGIN_HEADER
/* the latin-specific script class */
- AF_DECLARE_SCRIPT_CLASS(af_latin2_script_class)
+ AF_DECLARE_SCRIPT_CLASS( af_latin2_script_class )
/* */
diff --git a/3party/freetype/src/autofit/afloader.c b/3party/freetype/src/autofit/afloader.c
index 966a0df73d..f280beda20 100644
--- a/3party/freetype/src/autofit/afloader.c
+++ b/3party/freetype/src/autofit/afloader.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter glyph loading routines (body). */
/* */
-/* Copyright 2003-2009, 2011 by */
+/* Copyright 2003-2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -16,18 +16,22 @@
/***************************************************************************/
+#include "afglobal.h"
#include "afloader.h"
#include "afhints.h"
-#include "afglobal.h"
#include "aferrors.h"
+#include "afmodule.h"
/* Initialize glyph loader. */
FT_LOCAL_DEF( FT_Error )
- af_loader_init( AF_Loader loader,
- FT_Memory memory )
+ af_loader_init( AF_Module module )
{
+ AF_Loader loader = module->loader;
+ FT_Memory memory = module->root.library->memory;
+
+
FT_ZERO( loader );
af_glyph_hints_init( &loader->hints, memory );
@@ -41,10 +45,11 @@
/* Reset glyph loader and compute globals if necessary. */
FT_LOCAL_DEF( FT_Error )
- af_loader_reset( AF_Loader loader,
+ af_loader_reset( AF_Module module,
FT_Face face )
{
- FT_Error error = AF_Err_Ok;
+ FT_Error error = AF_Err_Ok;
+ AF_Loader loader = module->loader;
loader->face = face;
@@ -54,7 +59,7 @@
if ( loader->globals == NULL )
{
- error = af_face_globals_new( face, &loader->globals );
+ error = af_face_globals_new( face, &loader->globals, module );
if ( !error )
{
face->autohint.data =
@@ -71,8 +76,11 @@
/* Finalize glyph loader. */
FT_LOCAL_DEF( void )
- af_loader_done( AF_Loader loader )
+ af_loader_done( AF_Module module )
{
+ AF_Loader loader = module->loader;
+
+
af_glyph_hints_done( &loader->hints );
loader->face = NULL;
@@ -104,9 +112,11 @@
AF_GlyphHints hints = &loader->hints;
FT_GlyphSlot slot = face->glyph;
FT_Slot_Internal internal = slot->internal;
+ FT_Int32 flags;
- error = FT_Load_Glyph( face, glyph_index, load_flags );
+ flags = load_flags | FT_LOAD_LINEAR_DESIGN;
+ error = FT_Load_Glyph( face, glyph_index, flags );
if ( error )
goto Exit;
@@ -124,10 +134,6 @@
FT_Vector_Transform( &loader->trans_delta, &inverse );
}
- /* set linear metrics */
- slot->linearHoriAdvance = slot->metrics.horiAdvance;
- slot->linearVertAdvance = slot->metrics.vertAdvance;
-
switch ( slot->format )
{
case FT_GLYPH_FORMAT_OUTLINE:
@@ -137,8 +143,8 @@
loader->trans_delta.x,
loader->trans_delta.y );
- /* copy the outline points in the loader's current */
- /* extra points which is used to keep original glyph coordinates */
+ /* copy the outline points in the loader's current */
+ /* extra points which are used to keep original glyph coordinates */
error = FT_GLYPHLOADER_CHECK_POINTS( gloader,
slot->outline.n_points + 4,
slot->outline.n_contours );
@@ -349,8 +355,8 @@
l += num_base_points;
- /* for now, only use the current point coordinates; */
- /* we may consider another approach in the near future */
+ /* for now, only use the current point coordinates; */
+ /* we eventually may consider another approach */
p1 = gloader->base.outline.points + start_point + k;
p2 = gloader->base.outline.points + start_point + l;
@@ -433,9 +439,10 @@
slot->metrics.horiAdvance = FT_MulFix( slot->metrics.horiAdvance,
x_scale );
#else
- if ( FT_IS_FIXED_WIDTH( slot->face ) ||
- ( af_face_globals_is_digit( loader->globals, glyph_index ) &&
- metrics->digits_have_same_width ) )
+ if ( scaler->render_mode != FT_RENDER_MODE_LIGHT &&
+ ( FT_IS_FIXED_WIDTH( slot->face ) ||
+ ( af_face_globals_is_digit( loader->globals, glyph_index ) &&
+ metrics->digits_have_same_width ) ) )
{
slot->metrics.horiAdvance = FT_MulFix( slot->metrics.horiAdvance,
metrics->scaler.x_scale );
@@ -465,7 +472,13 @@
if ( error )
goto Exit;
- slot->outline = internal->loader->base.outline;
+ /* reassign all outline fields except flags to protect them */
+ slot->outline.n_contours = internal->loader->base.outline.n_contours;
+ slot->outline.n_points = internal->loader->base.outline.n_points;
+ slot->outline.points = internal->loader->base.outline.points;
+ slot->outline.tags = internal->loader->base.outline.tags;
+ slot->outline.contours = internal->loader->base.outline.contours;
+
slot->format = FT_GLYPH_FORMAT_OUTLINE;
}
@@ -477,13 +490,14 @@
/* Load a glyph. */
FT_LOCAL_DEF( FT_Error )
- af_loader_load_glyph( AF_Loader loader,
+ af_loader_load_glyph( AF_Module module,
FT_Face face,
FT_UInt gindex,
- FT_UInt32 load_flags )
+ FT_Int32 load_flags )
{
FT_Error error;
- FT_Size size = face->size;
+ FT_Size size = face->size;
+ AF_Loader loader = module->loader;
AF_ScalerRec scaler;
@@ -501,7 +515,7 @@
scaler.render_mode = FT_LOAD_TARGET_MODE( load_flags );
scaler.flags = 0; /* XXX: fix this */
- error = af_loader_reset( loader, face );
+ error = af_loader_reset( module, face );
if ( !error )
{
AF_ScriptMetrics metrics;
diff --git a/3party/freetype/src/autofit/afloader.h b/3party/freetype/src/autofit/afloader.h
index 3f91e1a225..1f34d17cce 100644
--- a/3party/freetype/src/autofit/afloader.h
+++ b/3party/freetype/src/autofit/afloader.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter glyph loading routines (specification). */
/* */
-/* Copyright 2003-2005, 2011 by */
+/* Copyright 2003-2005, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -25,11 +25,24 @@
FT_BEGIN_HEADER
- typedef struct AF_LoaderRec_
+ typedef struct AF_ModuleRec_* AF_Module;
+
+ /*
+ * The autofitter module's (global) data structure to communicate with
+ * actual fonts. If necessary, `local' data like the current face, the
+ * current face's auto-hint data, or the current glyph's parameters
+ * relevant to auto-hinting are `swapped in'. Cf. functions like
+ * `af_loader_reset' and `af_loader_load_g'.
+ */
+
+ typedef struct AF_LoaderRec_
{
- FT_Face face; /* current face */
- AF_FaceGlobals globals; /* current face globals */
- FT_GlyphLoader gloader; /* glyph loader */
+ /* current face data */
+ FT_Face face;
+ AF_FaceGlobals globals;
+
+ /* current glyph data */
+ FT_GlyphLoader gloader;
AF_GlyphHintsRec hints;
AF_ScriptMetrics metrics;
FT_Bool transformed;
@@ -43,24 +56,23 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Error )
- af_loader_init( AF_Loader loader,
- FT_Memory memory );
+ af_loader_init( AF_Module module );
FT_LOCAL( FT_Error )
- af_loader_reset( AF_Loader loader,
+ af_loader_reset( AF_Module module,
FT_Face face );
FT_LOCAL( void )
- af_loader_done( AF_Loader loader );
+ af_loader_done( AF_Module module );
FT_LOCAL( FT_Error )
- af_loader_load_glyph( AF_Loader loader,
+ af_loader_load_glyph( AF_Module module,
FT_Face face,
FT_UInt gindex,
- FT_UInt32 load_flags );
+ FT_Int32 load_flags );
/* */
diff --git a/3party/freetype/src/autofit/afmodule.c b/3party/freetype/src/autofit/afmodule.c
index 20b6218382..f46cff9ec7 100644
--- a/3party/freetype/src/autofit/afmodule.c
+++ b/3party/freetype/src/autofit/afmodule.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter module implementation (body). */
/* */
-/* Copyright 2003-2006, 2009, 2011 by */
+/* Copyright 2003-2006, 2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -16,8 +16,10 @@
/***************************************************************************/
+#include "afglobal.h"
#include "afmodule.h"
#include "afloader.h"
+#include "aferrors.h"
#include "afpic.h"
#ifdef FT_DEBUG_AUTOFIT
@@ -28,66 +30,229 @@
#endif
#include FT_INTERNAL_OBJECTS_H
+#include FT_INTERNAL_DEBUG_H
+#include FT_AUTOHINTER_H
+#include FT_SERVICE_PROPERTIES_H
- typedef struct FT_AutofitterRec_
+ /*************************************************************************/
+ /* */
+ /* The macro FT_COMPONENT is used in trace mode. It is an implicit */
+ /* parameter of the FT_TRACE() and FT_ERROR() macros, used to print/log */
+ /* messages during execution. */
+ /* */
+#undef FT_COMPONENT
+#define FT_COMPONENT trace_afmodule
+
+
+ FT_Error
+ af_property_get_face_globals( FT_Face face,
+ AF_FaceGlobals* aglobals,
+ AF_Module module )
+ {
+ FT_Error error = AF_Err_Ok;
+ AF_FaceGlobals globals;
+
+
+ if ( !face )
+ return AF_Err_Invalid_Argument;
+
+ globals = (AF_FaceGlobals)face->autohint.data;
+ if ( !globals )
+ {
+ /* trigger computation of the global script data */
+ /* in case it hasn't been done yet */
+ error = af_face_globals_new( face, &globals, module );
+ if ( !error )
+ {
+ face->autohint.data =
+ (FT_Pointer)globals;
+ face->autohint.finalizer =
+ (FT_Generic_Finalizer)af_face_globals_free;
+ }
+ }
+
+ if ( !error )
+ *aglobals = globals;
+
+ return error;
+ }
+
+
+ FT_Error
+ af_property_set( FT_Module ft_module,
+ const char* property_name,
+ const void* value )
+ {
+ FT_Error error = AF_Err_Ok;
+ AF_Module module = (AF_Module)ft_module;
+
+
+ if ( !ft_strcmp( property_name, "fallback-script" ) )
+ {
+ FT_UInt* fallback_script = (FT_UInt*)value;
+
+
+ module->fallback_script = *fallback_script;
+
+ return error;
+ }
+ else if ( !ft_strcmp( property_name, "increase-x-height" ) )
+ {
+ FT_Prop_IncreaseXHeight* prop = (FT_Prop_IncreaseXHeight*)value;
+ AF_FaceGlobals globals;
+
+
+ error = af_property_get_face_globals( prop->face, &globals, module );
+ if ( !error )
+ globals->increase_x_height = prop->limit;
+
+ return error;
+ }
+
+ FT_TRACE0(( "af_property_get: missing property `%s'\n",
+ property_name ));
+ return AF_Err_Missing_Property;
+ }
+
+
+ FT_Error
+ af_property_get( FT_Module ft_module,
+ const char* property_name,
+ void* value )
{
- FT_ModuleRec root;
- AF_LoaderRec loader[1];
+ FT_Error error = AF_Err_Ok;
+ AF_Module module = (AF_Module)ft_module;
+ FT_UInt fallback_script = module->fallback_script;
+
+
+ if ( !ft_strcmp( property_name, "glyph-to-script-map" ) )
+ {
+ FT_Prop_GlyphToScriptMap* prop = (FT_Prop_GlyphToScriptMap*)value;
+ AF_FaceGlobals globals;
- } FT_AutofitterRec, *FT_Autofitter;
+
+ error = af_property_get_face_globals( prop->face, &globals, module );
+ if ( !error )
+ prop->map = globals->glyph_scripts;
+
+ return error;
+ }
+ else if ( !ft_strcmp( property_name, "fallback-script" ) )
+ {
+ FT_UInt* val = (FT_UInt*)value;
+
+
+ *val = fallback_script;
+
+ return error;
+ }
+ else if ( !ft_strcmp( property_name, "increase-x-height" ) )
+ {
+ FT_Prop_IncreaseXHeight* prop = (FT_Prop_IncreaseXHeight*)value;
+ AF_FaceGlobals globals;
+
+
+ error = af_property_get_face_globals( prop->face, &globals, module );
+ if ( !error )
+ prop->limit = globals->increase_x_height;
+
+ return error;
+ }
+
+
+ FT_TRACE0(( "af_property_get: missing property `%s'\n",
+ property_name ));
+ return AF_Err_Missing_Property;
+ }
+
+
+ FT_DEFINE_SERVICE_PROPERTIESREC(
+ af_service_properties,
+ (FT_Properties_SetFunc)af_property_set,
+ (FT_Properties_GetFunc)af_property_get )
+
+
+ FT_DEFINE_SERVICEDESCREC1(
+ af_services,
+ FT_SERVICE_ID_PROPERTIES, &AF_SERVICE_PROPERTIES_GET )
+
+
+ FT_CALLBACK_DEF( FT_Module_Interface )
+ af_get_interface( FT_Module module,
+ const char* module_interface )
+ {
+ /* AF_SERVICES_GET derefers `library' in PIC mode */
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_Library library;
+
+
+ if ( !module )
+ return NULL;
+ library = module->library;
+ if ( !library )
+ return NULL;
+#else
+ FT_UNUSED( module );
+#endif
+
+ return ft_service_list_lookup( AF_SERVICES_GET, module_interface );
+ }
FT_CALLBACK_DEF( FT_Error )
- af_autofitter_init( FT_Autofitter module )
+ af_autofitter_init( AF_Module module )
{
- return af_loader_init( module->loader, module->root.library->memory );
+ module->fallback_script = AF_SCRIPT_FALLBACK;
+
+ return af_loader_init( module );
}
FT_CALLBACK_DEF( void )
- af_autofitter_done( FT_Autofitter module )
+ af_autofitter_done( AF_Module module )
{
- af_loader_done( module->loader );
+ af_loader_done( module );
}
FT_CALLBACK_DEF( FT_Error )
- af_autofitter_load_glyph( FT_Autofitter module,
- FT_GlyphSlot slot,
- FT_Size size,
- FT_UInt glyph_index,
- FT_Int32 load_flags )
+ af_autofitter_load_glyph( AF_Module module,
+ FT_GlyphSlot slot,
+ FT_Size size,
+ FT_UInt glyph_index,
+ FT_Int32 load_flags )
{
FT_UNUSED( size );
- return af_loader_load_glyph( module->loader, slot->face,
+ return af_loader_load_glyph( module, slot->face,
glyph_index, load_flags );
}
- FT_DEFINE_AUTOHINTER_SERVICE(
- af_autofitter_service,
- NULL,
- NULL,
- NULL,
- (FT_AutoHinter_GlyphLoadFunc)af_autofitter_load_glyph )
+ FT_DEFINE_AUTOHINTER_INTERFACE(
+ af_autofitter_interface,
+ NULL, /* reset_face */
+ NULL, /* get_global_hints */
+ NULL, /* done_global_hints */
+ (FT_AutoHinter_GlyphLoadFunc)af_autofitter_load_glyph ) /* load_glyph */
+
FT_DEFINE_MODULE(
autofit_module_class,
FT_MODULE_HINTER,
- sizeof ( FT_AutofitterRec ),
+ sizeof ( AF_ModuleRec ),
"autofitter",
0x10000L, /* version 1.0 of the autofitter */
0x20000L, /* requires FreeType 2.0 or above */
- (const void*)&AF_AF_AUTOFITTER_SERVICE_GET,
+ (const void*)&AF_INTERFACE_GET,
(FT_Module_Constructor)af_autofitter_init,
(FT_Module_Destructor) af_autofitter_done,
- (FT_Module_Requester) NULL )
+ (FT_Module_Requester) af_get_interface )
/* END */
diff --git a/3party/freetype/src/autofit/afmodule.h b/3party/freetype/src/autofit/afmodule.h
index d9792399b6..c4e8f8f66a 100644
--- a/3party/freetype/src/autofit/afmodule.h
+++ b/3party/freetype/src/autofit/afmodule.h
@@ -23,9 +23,30 @@
#include FT_INTERNAL_OBJECTS_H
#include FT_MODULE_H
+#include "afloader.h"
+
FT_BEGIN_HEADER
+
+ /*
+ * This is the `extended' FT_Module structure which holds the
+ * autofitter's global data. Right before hinting a glyph, the data
+ * specific to the glyph's face (blue zones, stem widths, etc.) are
+ * loaded into `loader' (see function `af_loader_reset').
+ */
+
+ typedef struct AF_ModuleRec_
+ {
+ FT_ModuleRec root;
+
+ FT_UInt fallback_script;
+
+ AF_LoaderRec loader[1];
+
+ } AF_ModuleRec;
+
+
FT_DECLARE_MODULE(autofit_module_class)
diff --git a/3party/freetype/src/autofit/afpic.c b/3party/freetype/src/autofit/afpic.c
index 3aefbc51ce..e6022f9301 100644
--- a/3party/freetype/src/autofit/afpic.c
+++ b/3party/freetype/src/autofit/afpic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for autofit module. */
/* */
-/* Copyright 2009, 2010, 2011 by */
+/* Copyright 2009-2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,20 +20,38 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include "afpic.h"
+#include "aferrors.h"
+
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from afmodule.c */
- void FT_Init_Class_af_autofitter_service( FT_Library,
- FT_AutoHinter_ServiceRec* );
+ FT_Error
+ FT_Create_Class_af_services( FT_Library library,
+ FT_ServiceDescRec** output_class );
+
+ void
+ FT_Destroy_Class_af_services( FT_Library library,
+ FT_ServiceDescRec* clazz );
+
+ void
+ FT_Init_Class_af_service_properties( FT_Service_PropertiesRec* clazz );
+
+ void FT_Init_Class_af_autofitter_interface(
+ FT_Library library,
+ FT_AutoHinter_InterfaceRec* clazz );
+
/* forward declaration of PIC init functions from script classes */
#include "aflatin.h"
+#ifdef FT_OPTION_AUTOFIT2
#include "aflatin2.h"
+#endif
#include "afcjk.h"
#include "afdummy.h"
#include "afindic.h"
+
void
autofit_module_class_pic_free( FT_Library library )
{
@@ -43,7 +61,15 @@
if ( pic_container->autofit )
{
- FT_FREE( pic_container->autofit );
+ AFModulePIC* container = (AFModulePIC*)pic_container->autofit;
+
+
+ if ( container->af_services )
+ FT_Destroy_Class_af_services( library,
+ container->af_services );
+ container->af_services = NULL;
+
+ FT_FREE( container );
pic_container->autofit = NULL;
}
}
@@ -55,7 +81,7 @@
FT_PIC_Container* pic_container = &library->pic_container;
FT_UInt ss;
FT_Error error = AF_Err_Ok;
- AFModulePIC* container;
+ AFModulePIC* container = NULL;
FT_Memory memory = library->memory;
@@ -67,13 +93,20 @@
/* initialize pointer table - */
/* this is how the module usually expects this data */
+ error = FT_Create_Class_af_services( library,
+ &container->af_services );
+ if ( error )
+ goto Exit;
+
+ FT_Init_Class_af_service_properties( &container->af_service_properties );
+
for ( ss = 0 ; ss < AF_SCRIPT_CLASSES_REC_COUNT ; ss++ )
{
container->af_script_classes[ss] =
&container->af_script_classes_rec[ss];
}
container->af_script_classes[AF_SCRIPT_CLASSES_COUNT - 1] = NULL;
-
+
/* add call to initialization function when you add new scripts */
ss = 0;
FT_Init_Class_af_dummy_script_class(
@@ -89,17 +122,15 @@
FT_Init_Class_af_indic_script_class(
&container->af_script_classes_rec[ss++] );
- FT_Init_Class_af_autofitter_service(
- library, &container->af_autofitter_service );
-
-/* Exit: */
+ FT_Init_Class_af_autofitter_interface(
+ library, &container->af_autofitter_interface );
+ Exit:
if ( error )
autofit_module_class_pic_free( library );
return error;
}
-
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/autofit/afpic.h b/3party/freetype/src/autofit/afpic.h
index c1632e76e9..7a07bdf4cc 100644
--- a/3party/freetype/src/autofit/afpic.h
+++ b/3party/freetype/src/autofit/afpic.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for autofit module. */
/* */
-/* Copyright 2009, 2011 by */
+/* Copyright 2009, 2011-2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,43 +19,70 @@
#ifndef __AFPIC_H__
#define __AFPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
+
#ifndef FT_CONFIG_OPTION_PIC
-#define AF_SCRIPT_CLASSES_GET af_script_classes
-#define AF_AF_AUTOFITTER_SERVICE_GET af_autofitter_service
+#define AF_SERVICES_GET af_services
+#define AF_SERVICE_PROPERTIES_GET af_service_properties
+
+#define AF_SCRIPT_CLASSES_GET af_script_classes
+#define AF_INTERFACE_GET af_autofitter_interface
#else /* FT_CONFIG_OPTION_PIC */
+ /* some include files required for members of AFModulePIC */
+#include FT_SERVICE_PROPERTIES_H
+
#include "aftypes.h"
/* increase these when you add new scripts, */
/* and update autofit_module_class_pic_init */
#ifdef FT_OPTION_AUTOFIT2
-#define AF_SCRIPT_CLASSES_COUNT 6
+#define AF_SCRIPT_CLASSES_COUNT 6
#else
-#define AF_SCRIPT_CLASSES_COUNT 5
+#define AF_SCRIPT_CLASSES_COUNT 5
#endif
-#define AF_SCRIPT_CLASSES_REC_COUNT ( AF_SCRIPT_CLASSES_COUNT - 1 )
- typedef struct AFModulePIC_
+#define AF_SCRIPT_CLASSES_REC_COUNT ( AF_SCRIPT_CLASSES_COUNT - 1 )
+
+
+ typedef struct AFModulePIC_
{
- AF_ScriptClass af_script_classes[AF_SCRIPT_CLASSES_COUNT];
- AF_ScriptClassRec af_script_classes_rec[AF_SCRIPT_CLASSES_REC_COUNT];
- FT_AutoHinter_ServiceRec af_autofitter_service;
+ FT_ServiceDescRec* af_services;
+ FT_Service_PropertiesRec af_service_properties;
+
+ AF_ScriptClass af_script_classes[AF_SCRIPT_CLASSES_COUNT];
+ AF_ScriptClassRec af_script_classes_rec[AF_SCRIPT_CLASSES_REC_COUNT];
+ FT_AutoHinter_InterfaceRec af_autofitter_interface;
} AFModulePIC;
-#define GET_PIC( lib ) \
+
+#define GET_PIC( lib ) \
( (AFModulePIC*)((lib)->pic_container.autofit) )
-#define AF_SCRIPT_CLASSES_GET \
- ( GET_PIC( FT_FACE_LIBRARY(globals->face) )->af_script_classes )
-#define AF_AF_AUTOFITTER_SERVICE_GET \
- ( GET_PIC( library )->af_autofitter_service )
+
+#define AF_SERVICES_GET \
+ ( GET_PIC( library )->af_services )
+#define AF_SERVICE_PROPERTIES_GET \
+ ( GET_PIC( library)->af_service_properties )
+
+#define AF_SCRIPT_CLASSES_GET \
+ ( GET_PIC( FT_FACE_LIBRARY( globals->face ) )->af_script_classes )
+#define AF_INTERFACE_GET \
+ ( GET_PIC( library )->af_autofitter_interface )
+
+
+ /* see afpic.c for the implementation */
+ void
+ autofit_module_class_pic_free( FT_Library library );
+
+ FT_Error
+ autofit_module_class_pic_init( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/autofit/aftypes.h b/3party/freetype/src/autofit/aftypes.h
index 44997d1e22..9acd7ad6d2 100644
--- a/3party/freetype/src/autofit/aftypes.h
+++ b/3party/freetype/src/autofit/aftypes.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter types (specification only). */
/* */
-/* Copyright 2003-2009, 2011 by */
+/* Copyright 2003-2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -87,8 +87,9 @@ extern void* _af_debug_hints;
FT_Pos* table );
FT_LOCAL( void )
- af_sort_widths( FT_UInt count,
- AF_Width widths );
+ af_sort_and_quantize_widths( FT_UInt* count,
+ AF_Width widths,
+ FT_Pos threshold );
/*************************************************************************/
@@ -228,12 +229,12 @@ extern void* _af_debug_hints;
typedef enum AF_Script_
{
- AF_SCRIPT_NONE = 0,
+ AF_SCRIPT_DUMMY = 0,
AF_SCRIPT_LATIN = 1,
AF_SCRIPT_CJK = 2,
- AF_SCRIPT_INDIC = 3,
+ AF_SCRIPT_INDIC = 3,
#ifdef FT_OPTION_AUTOFIT2
- AF_SCRIPT_LATIN2,
+ AF_SCRIPT_LATIN2 = 4,
#endif
/* add new scripts here. Don't forget to update the list in */
@@ -245,6 +246,7 @@ extern void* _af_debug_hints;
typedef struct AF_ScriptClassRec_ const* AF_ScriptClass;
+ typedef struct AF_FaceGlobalsRec_* AF_FaceGlobals;
typedef struct AF_ScriptMetricsRec_
{
@@ -252,6 +254,8 @@ extern void* _af_debug_hints;
AF_ScalerRec scaler;
FT_Bool digits_have_same_width;
+ AF_FaceGlobals globals; /* to access properties */
+
} AF_ScriptMetricsRec, *AF_ScriptMetrics;
@@ -294,8 +298,9 @@ extern void* _af_debug_hints;
typedef struct AF_ScriptClassRec_
{
- AF_Script script;
- AF_Script_UniRange script_uni_ranges; /* last must be { 0, 0 } */
+ AF_Script script;
+ AF_Script_UniRange script_uni_ranges; /* last must be { 0, 0 } */
+ FT_UInt32 standard_char; /* for default width and height */
FT_Offset script_metrics_size;
AF_Script_InitMetricsFunc script_metrics_init;
@@ -315,13 +320,14 @@ extern void* _af_debug_hints;
FT_CALLBACK_TABLE const AF_ScriptClassRec \
script_class;
-#define AF_DEFINE_SCRIPT_CLASS( script_class, script_, ranges, m_size, \
+#define AF_DEFINE_SCRIPT_CLASS( script_class, script_, ranges, def_char, \
+ m_size, \
m_init, m_scale, m_done, h_init, h_apply ) \
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec \
- script_class = \
+ FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec script_class = \
{ \
script_, \
ranges, \
+ def_char, \
\
m_size, \
\
@@ -335,17 +341,19 @@ extern void* _af_debug_hints;
#else /* FT_CONFIG_OPTION_PIC */
-#define AF_DECLARE_SCRIPT_CLASS( script_class ) \
- FT_LOCAL( void ) \
- FT_Init_Class_##script_class( AF_ScriptClassRec* ac );
+#define AF_DECLARE_SCRIPT_CLASS( script_class ) \
+ FT_LOCAL( void ) \
+ FT_Init_Class_ ## script_class( AF_ScriptClassRec* ac );
-#define AF_DEFINE_SCRIPT_CLASS( script_class, script_, ranges, m_size, \
+#define AF_DEFINE_SCRIPT_CLASS( script_class, script_, ranges, def_char, \
+ m_size, \
m_init, m_scale, m_done, h_init, h_apply ) \
FT_LOCAL_DEF( void ) \
- FT_Init_Class_##script_class( AF_ScriptClassRec* ac ) \
+ FT_Init_Class_ ## script_class( AF_ScriptClassRec* ac ) \
{ \
ac->script = script_; \
ac->script_uni_ranges = ranges; \
+ ac->default_char = def_char; \
\
ac->script_metrics_size = m_size; \
\
diff --git a/3party/freetype/src/autofit/afwarp.c b/3party/freetype/src/autofit/afwarp.c
index d0d4850bdc..34a97ffc57 100644
--- a/3party/freetype/src/autofit/afwarp.c
+++ b/3party/freetype/src/autofit/afwarp.c
@@ -352,7 +352,7 @@
{
FT_Fixed best_scale = warper->best_scale;
FT_Pos best_delta = warper->best_delta;
-
+
hints->xmin_delta = FT_MulFix( X1, best_scale - org_scale )
+ best_delta;
diff --git a/3party/freetype/src/base/basepic.c b/3party/freetype/src/base/basepic.c
index c0bccb6959..5268e7c67a 100644
--- a/3party/freetype/src/base/basepic.c
+++ b/3party/freetype/src/base/basepic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for base. */
/* */
-/* Copyright 2009 by */
+/* Copyright 2009, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -21,24 +21,42 @@
#include FT_INTERNAL_OBJECTS_H
#include "basepic.h"
+
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from ftglyph.c */
- void FT_Init_Class_ft_outline_glyph_class(FT_Glyph_Class*);
- void FT_Init_Class_ft_bitmap_glyph_class(FT_Glyph_Class*);
+ void
+ FT_Init_Class_ft_outline_glyph_class( FT_Glyph_Class* clazz );
+
+ void
+ FT_Init_Class_ft_bitmap_glyph_class( FT_Glyph_Class* clazz );
+
+#ifdef FT_CONFIG_OPTION_MAC_FONTS
+ /* forward declaration of PIC init function from ftrfork.c */
+ /* (not modularized) */
+ void
+ FT_Init_Table_raccess_guess_table( ft_raccess_guess_rec* record );
+#endif
/* forward declaration of PIC init functions from ftinit.c */
- FT_Error ft_create_default_module_classes(FT_Library);
- void ft_destroy_default_module_classes(FT_Library);
+ FT_Error
+ ft_create_default_module_classes( FT_Library library );
void
- ft_base_pic_free( FT_Library library )
+ ft_destroy_default_module_classes( FT_Library library );
+
+
+ void
+ ft_base_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->base )
{
- /* Destroy default module classes (in case FT_Add_Default_Modules was used) */
+ /* destroy default module classes */
+ /* (in case FT_Add_Default_Modules was used) */
ft_destroy_default_module_classes( library );
FT_FREE( pic_container->base );
@@ -48,17 +66,18 @@
FT_Error
- ft_base_pic_init( FT_Library library )
+ ft_base_pic_init( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Error error = FT_Err_Ok;
- BasePIC* container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ BasePIC* container = NULL;
+ FT_Memory memory = library->memory;
+
/* allocate pointer, clear and set global container pointer */
if ( FT_ALLOC ( container, sizeof ( *container ) ) )
return error;
- FT_MEM_SET( container, 0, sizeof(*container) );
+ FT_MEM_SET( container, 0, sizeof ( *container ) );
pic_container->base = container;
/* initialize default modules list and pointers */
@@ -66,13 +85,20 @@
if ( error )
goto Exit;
- /* initialize pointer table - this is how the module usually expects this data */
- FT_Init_Class_ft_outline_glyph_class(&container->ft_outline_glyph_class);
- FT_Init_Class_ft_bitmap_glyph_class(&container->ft_bitmap_glyph_class);
+ /* initialize pointer table - */
+ /* this is how the module usually expects this data */
+ FT_Init_Class_ft_outline_glyph_class(
+ &container->ft_outline_glyph_class );
+ FT_Init_Class_ft_bitmap_glyph_class(
+ &container->ft_bitmap_glyph_class );
+#ifdef FT_CONFIG_OPTION_MAC_FONTS
+ FT_Init_Table_raccess_guess_table(
+ (ft_raccess_guess_rec*)&container->ft_raccess_guess_table );
+#endif
Exit:
- if(error)
- ft_base_pic_free(library);
+ if( error )
+ ft_base_pic_free( library );
return error;
}
diff --git a/3party/freetype/src/base/basepic.h b/3party/freetype/src/base/basepic.h
index bb17745769..bf90bef0be 100644
--- a/3party/freetype/src/base/basepic.h
+++ b/3party/freetype/src/base/basepic.h
@@ -19,7 +19,7 @@
#ifndef __BASEPIC_H__
#define __BASEPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
@@ -28,28 +28,43 @@ FT_BEGIN_HEADER
#define FT_OUTLINE_GLYPH_CLASS_GET &ft_outline_glyph_class
#define FT_BITMAP_GLYPH_CLASS_GET &ft_bitmap_glyph_class
#define FT_DEFAULT_MODULES_GET ft_default_modules
+#ifdef FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK
+#define FT_RACCESS_GUESS_TABLE_GET ft_raccess_guess_table
+#endif
#else /* FT_CONFIG_OPTION_PIC */
#include FT_GLYPH_H
+#ifdef FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK
+#include FT_INTERNAL_RFORK_H
+#endif
+
+
typedef struct BasePIC_
{
FT_Module_Class** default_module_classes;
FT_Glyph_Class ft_outline_glyph_class;
FT_Glyph_Class ft_bitmap_glyph_class;
+#ifdef FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK
+ ft_raccess_guess_rec ft_raccess_guess_table[FT_RACCESS_N_RULES];
+#endif
} BasePIC;
#define GET_PIC(lib) ((BasePIC*)((lib)->pic_container.base))
#define FT_OUTLINE_GLYPH_CLASS_GET (&GET_PIC(library)->ft_outline_glyph_class)
#define FT_BITMAP_GLYPH_CLASS_GET (&GET_PIC(library)->ft_bitmap_glyph_class)
#define FT_DEFAULT_MODULES_GET (GET_PIC(library)->default_module_classes)
+#ifdef FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK
+#define FT_RACCESS_GUESS_TABLE_GET (GET_PIC(library)->ft_raccess_guess_table)
+#endif
+ /* see basepic.c for the implementation. */
void
- ft_base_pic_free( FT_Library library );
+ ft_base_pic_free( FT_Library library );
FT_Error
- ft_base_pic_init( FT_Library library );
+ ft_base_pic_init( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/src/base/ftadvanc.c b/3party/freetype/src/base/ftadvanc.c
index 8ab7fcb927..a8bb43d3d0 100644
--- a/3party/freetype/src/base/ftadvanc.c
+++ b/3party/freetype/src/base/ftadvanc.c
@@ -4,7 +4,7 @@
/* */
/* Quick computation of advance widths (body). */
/* */
-/* Copyright 2008, 2009 by */
+/* Copyright 2008, 2009, 2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -129,7 +129,7 @@
{
error = func( face, start, count, flags, padvances );
if ( !error )
- goto Exit;
+ return _ft_face_scale_advances( face, padvances, count, flags );
if ( error != FT_ERROR_BASE( FT_Err_Unimplemented_Feature ) )
return error;
@@ -147,16 +147,13 @@
if ( error )
break;
+ /* scale from 26.6 to 16.16 */
padvances[nn] = ( flags & FT_LOAD_VERTICAL_LAYOUT )
- ? face->glyph->advance.y
- : face->glyph->advance.x;
+ ? face->glyph->advance.y << 10
+ : face->glyph->advance.x << 10;
}
- if ( error )
- return error;
-
- Exit:
- return _ft_face_scale_advances( face, padvances, count, flags );
+ return error;
}
diff --git a/3party/freetype/src/base/ftbase.c b/3party/freetype/src/base/ftbase.c
index 6a27ea95a6..5e5d70ec4b 100644
--- a/3party/freetype/src/base/ftbase.c
+++ b/3party/freetype/src/base/ftbase.c
@@ -34,7 +34,7 @@
#include "fttrigon.c"
#include "ftutil.c"
-#if defined( FT_MACINTOSH ) && !defined ( DARWIN_NO_CARBON )
+#ifdef FT_MACINTOSH
#include "ftmac.c"
#endif
diff --git a/3party/freetype/src/base/ftbase.h b/3party/freetype/src/base/ftbase.h
index 516f4bb7fd..51a1db18b8 100644
--- a/3party/freetype/src/base/ftbase.h
+++ b/3party/freetype/src/base/ftbase.h
@@ -49,15 +49,15 @@ FT_BEGIN_HEADER
FT_Face *aface );
-#if defined( FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK ) && \
- ( !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON ) )
+#if defined( FT_CONFIG_OPTION_GUESSING_EMBEDDED_RFORK ) && \
+ !defined( FT_MACINTOSH )
/* 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 */
/* on Darwin VFS should be grouped and skip the rest methods after */
/* 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 );
+ ft_raccess_rule_by_darwin_vfs( FT_Library library, FT_UInt rule_index );
#endif
diff --git a/3party/freetype/src/base/ftbitmap.c b/3party/freetype/src/base/ftbitmap.c
index 15c9d6559a..84fa322753 100644
--- a/3party/freetype/src/base/ftbitmap.c
+++ b/3party/freetype/src/base/ftbitmap.c
@@ -231,7 +231,7 @@
if ( ( ( FT_PIX_ROUND( xStrength ) >> 6 ) > FT_INT_MAX ) ||
( ( FT_PIX_ROUND( yStrength ) >> 6 ) > FT_INT_MAX ) )
return FT_Err_Invalid_Argument;
-
+
xstr = (FT_Int)FT_PIX_ROUND( xStrength ) >> 6;
ystr = (FT_Int)FT_PIX_ROUND( yStrength ) >> 6;
diff --git a/3party/freetype/src/base/ftcalc.c b/3party/freetype/src/base/ftcalc.c
index 3892fabfe9..2aeea0459b 100644
--- a/3party/freetype/src/base/ftcalc.c
+++ b/3party/freetype/src/base/ftcalc.c
@@ -4,7 +4,7 @@
/* */
/* Arithmetic computations (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008 by */
+/* Copyright 1996-2006, 2008, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -307,7 +307,7 @@
q <<= 1;
r |= lo >> 31;
- if ( r >= (FT_UInt32)y )
+ if ( r >= y )
{
r -= y;
q |= 1;
@@ -373,7 +373,7 @@
if ( a <= 46340L && b <= 46340L && c <= 176095L && c > 0 )
a = ( a * b + ( c >> 1 ) ) / c;
- else if ( c > 0 )
+ else if ( (FT_Int32)c > 0 )
{
FT_Int64 temp, temp2;
@@ -412,7 +412,7 @@
if ( a <= 46340L && b <= 46340L && c > 0 )
a = a * b / c;
- else if ( c > 0 )
+ else if ( (FT_Int32)c > 0 )
{
FT_Int64 temp;
@@ -464,7 +464,7 @@
* Unfortunately, it doesn't work (at least not portably).
*
* It makes the assumption that right-shift on a negative signed value
- * fills the leftmost bits by copying the sign bit. This is wrong.
+ * fills the leftmost bits by copying the sign bit. This is wrong.
* According to K&R 2nd ed, section `A7.8 Shift Operators' on page 206,
* the result of right-shift of a negative signed value is
* implementation-defined. At least one implementation fills the
@@ -544,7 +544,7 @@
s = (FT_Int32)a; a = FT_ABS( a );
s ^= (FT_Int32)b; b = FT_ABS( b );
- if ( b == 0 )
+ if ( (FT_UInt32)b == 0 )
{
/* check for division by 0 */
q = (FT_UInt32)0x7FFFFFFFL;
@@ -552,15 +552,16 @@
else if ( ( a >> 16 ) == 0 )
{
/* compute result directly */
- q = (FT_UInt32)( (a << 16) + (b >> 1) ) / (FT_UInt32)b;
+ q = (FT_UInt32)( ( a << 16 ) + ( b >> 1 ) ) / (FT_UInt32)b;
}
else
{
/* we need more bits; we have to do it by hand */
FT_Int64 temp, temp2;
- temp.hi = (FT_Int32) (a >> 16);
- temp.lo = (FT_UInt32)(a << 16);
+
+ temp.hi = (FT_Int32) ( a >> 16 );
+ temp.lo = (FT_UInt32)( a << 16 );
temp2.hi = 0;
temp2.lo = (FT_UInt32)( b >> 1 );
FT_Add64( &temp, &temp2, &temp );
diff --git a/3party/freetype/src/base/ftgloadr.c b/3party/freetype/src/base/ftgloadr.c
index 8483450192..3a5615e5e5 100644
--- a/3party/freetype/src/base/ftgloadr.c
+++ b/3party/freetype/src/base/ftgloadr.c
@@ -318,7 +318,7 @@
}
- /* add current glyph to the base image - and prepare for another */
+ /* add current glyph to the base image -- and prepare for another */
FT_BASE_DEF( void )
FT_GlyphLoader_Add( FT_GlyphLoader loader )
{
diff --git a/3party/freetype/src/base/ftglyph.c b/3party/freetype/src/base/ftglyph.c
index b22050800b..7363c7dceb 100644
--- a/3party/freetype/src/base/ftglyph.c
+++ b/3party/freetype/src/base/ftglyph.c
@@ -4,7 +4,7 @@
/* */
/* FreeType convenience functions to handle glyphs (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2007, 2008, 2010 by */
+/* Copyright 1996-2005, 2007, 2008, 2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -254,7 +254,7 @@
}
- FT_DEFINE_GLYPH( ft_outline_glyph_class,
+ FT_DEFINE_GLYPH( ft_outline_glyph_class,
sizeof ( FT_OutlineGlyphRec ),
FT_GLYPH_FORMAT_OUTLINE,
@@ -510,47 +510,47 @@
FT_GlyphSlotRec dummy;
FT_GlyphSlot_InternalRec dummy_internal;
FT_Error error = FT_Err_Ok;
- FT_Glyph glyph;
+ FT_Glyph b, glyph;
FT_BitmapGlyph bitmap = NULL;
-
const FT_Glyph_Class* clazz;
-#ifdef FT_CONFIG_OPTION_PIC
- FT_Library library = FT_GLYPH( glyph )->library;
-#endif
+ /* FT_BITMAP_GLYPH_CLASS_GET derefers `library' in PIC mode */
+ FT_Library library;
/* check argument */
if ( !the_glyph )
goto Bad;
-
- /* we render the glyph into a glyph bitmap using a `dummy' glyph slot */
- /* then calling FT_Render_Glyph_Internal() */
-
glyph = *the_glyph;
if ( !glyph )
goto Bad;
- clazz = glyph->clazz;
+ clazz = glyph->clazz;
+ library = glyph->library;
+ if ( !library || !clazz )
+ goto Bad;
/* when called with a bitmap glyph, do nothing and return successfully */
if ( clazz == FT_BITMAP_GLYPH_CLASS_GET )
goto Exit;
- if ( !clazz || !clazz->glyph_prepare )
+ if ( !clazz->glyph_prepare )
goto Bad;
+ /* we render the glyph into a glyph bitmap using a `dummy' glyph slot */
+ /* then calling FT_Render_Glyph_Internal() */
+
FT_MEM_ZERO( &dummy, sizeof ( dummy ) );
FT_MEM_ZERO( &dummy_internal, sizeof ( dummy_internal ) );
dummy.internal = &dummy_internal;
- dummy.library = glyph->library;
+ dummy.library = library;
dummy.format = clazz->glyph_format;
/* create result bitmap glyph */
- error = ft_new_glyph( glyph->library, FT_BITMAP_GLYPH_CLASS_GET,
- (FT_Glyph*)(void*)&bitmap );
+ error = ft_new_glyph( library, FT_BITMAP_GLYPH_CLASS_GET, &b );
if ( error )
goto Exit;
+ bitmap = (FT_BitmapGlyph)b;
#if 1
/* if `origin' is set, translate the glyph image */
diff --git a/3party/freetype/src/base/ftinit.c b/3party/freetype/src/base/ftinit.c
index 305177a7e1..0d8b568be1 100644
--- a/3party/freetype/src/base/ftinit.c
+++ b/3party/freetype/src/base/ftinit.c
@@ -4,7 +4,7 @@
/* */
/* FreeType initialization layer (body). */
/* */
-/* Copyright 1996-2001, 2002, 2005, 2007, 2009 by */
+/* Copyright 1996-2002, 2005, 2007, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -54,8 +54,10 @@
#undef FT_COMPONENT
#define FT_COMPONENT trace_init
+
#ifndef FT_CONFIG_OPTION_PIC
+
#undef FT_USE_MODULE
#ifdef __cplusplus
#define FT_USE_MODULE( type, x ) extern "C" const type x;
@@ -63,10 +65,8 @@
#define FT_USE_MODULE( type, x ) extern const type x;
#endif
-
#include FT_CONFIG_MODULES_H
-
#undef FT_USE_MODULE
#define FT_USE_MODULE( type, x ) (const FT_Module_Class*)&(x),
@@ -77,8 +77,10 @@
0
};
+
#else /* FT_CONFIG_OPTION_PIC */
+
#ifdef __cplusplus
#define FT_EXTERNC extern "C"
#else
@@ -87,16 +89,19 @@
/* declare the module's class creation/destruction functions */
#undef FT_USE_MODULE
-#define FT_USE_MODULE( type, x ) \
- FT_EXTERNC FT_Error FT_Create_Class_##x( FT_Library library, FT_Module_Class** output_class ); \
- FT_EXTERNC void FT_Destroy_Class_##x( FT_Library library, FT_Module_Class* clazz );
+#define FT_USE_MODULE( type, x ) \
+ FT_EXTERNC FT_Error \
+ FT_Create_Class_ ## x( FT_Library library, \
+ FT_Module_Class* *output_class ); \
+ FT_EXTERNC void \
+ FT_Destroy_Class_ ## x( FT_Library library, \
+ FT_Module_Class* clazz );
#include FT_CONFIG_MODULES_H
-
/* count all module classes */
#undef FT_USE_MODULE
-#define FT_USE_MODULE( type, x ) MODULE_CLASS_##x,
+#define FT_USE_MODULE( type, x ) MODULE_CLASS_ ## x,
enum
{
@@ -104,26 +109,31 @@
FT_NUM_MODULE_CLASSES
};
- /* destroy all module classes */
+ /* destroy all module classes */
#undef FT_USE_MODULE
-#define FT_USE_MODULE( type, x ) \
- if ( classes[i] ) { FT_Destroy_Class_##x(library, classes[i]); } \
- i++; \
+#define FT_USE_MODULE( type, x ) \
+ if ( classes[i] ) \
+ { \
+ FT_Destroy_Class_ ## x( library, classes[i] ); \
+ } \
+ i++;
+
FT_BASE_DEF( void )
ft_destroy_default_module_classes( FT_Library library )
{
- FT_Module_Class** classes;
- FT_Memory memory;
- FT_UInt i;
- BasePIC* pic_container = (BasePIC*)library->pic_container.base;
+ FT_Module_Class* *classes;
+ FT_Memory memory;
+ FT_UInt i;
+ BasePIC* pic_container = (BasePIC*)library->pic_container.base;
+
if ( !pic_container->default_module_classes )
return;
- memory = library->memory;
+ memory = library->memory;
classes = pic_container->default_module_classes;
- i = 0;
+ i = 0;
#include FT_CONFIG_MODULES_H
@@ -131,30 +141,37 @@
pic_container->default_module_classes = 0;
}
+
/* initialize all module classes and the pointer table */
#undef FT_USE_MODULE
-#define FT_USE_MODULE( type, x ) \
- error = FT_Create_Class_##x(library, &clazz); \
- if (error) goto Exit; \
+#define FT_USE_MODULE( type, x ) \
+ error = FT_Create_Class_ ## x( library, &clazz ); \
+ if ( error ) \
+ goto Exit; \
classes[i++] = clazz;
+
FT_BASE_DEF( FT_Error )
ft_create_default_module_classes( FT_Library library )
{
- FT_Error error;
- FT_Memory memory;
- FT_Module_Class** classes;
- FT_Module_Class* clazz;
- FT_UInt i;
- BasePIC* pic_container = (BasePIC*)library->pic_container.base;
-
- memory = library->memory;
+ FT_Error error;
+ FT_Memory memory;
+ FT_Module_Class* *classes = NULL;
+ FT_Module_Class* clazz;
+ FT_UInt i;
+ BasePIC* pic_container = (BasePIC*)library->pic_container.base;
+
+
+ memory = library->memory;
+
pic_container->default_module_classes = 0;
- if ( FT_ALLOC(classes, sizeof(FT_Module_Class*) * (FT_NUM_MODULE_CLASSES + 1) ) )
+ if ( FT_ALLOC( classes, sizeof ( FT_Module_Class* ) *
+ ( FT_NUM_MODULE_CLASSES + 1 ) ) )
return error;
+
/* initialize all pointers to 0, especially the last one */
- for (i = 0; i < FT_NUM_MODULE_CLASSES; i++)
+ for ( i = 0; i < FT_NUM_MODULE_CLASSES; i++ )
classes[i] = 0;
classes[FT_NUM_MODULE_CLASSES] = 0;
@@ -162,16 +179,19 @@
#include FT_CONFIG_MODULES_H
-Exit:
- if (error) ft_destroy_default_module_classes( library );
- else pic_container->default_module_classes = classes;
+ Exit:
+ if ( error )
+ ft_destroy_default_module_classes( library );
+ else
+ pic_container->default_module_classes = classes;
- return error;
+ return error;
}
#endif /* FT_CONFIG_OPTION_PIC */
+
/* documentation is in ftmodapi.h */
FT_EXPORT_DEF( void )
@@ -181,9 +201,18 @@ Exit:
const FT_Module_Class* const* cur;
- /* test for valid `library' delayed to FT_Add_Module() */
+ /* FT_DEFAULT_MODULES_GET dereferences `library' in PIC mode */
+#ifdef FT_CONFIG_OPTION_PIC
+ if ( !library )
+ return;
+#endif
+
+ /* GCC 4.6 warns the type difference:
+ * FT_Module_Class** != const FT_Module_Class* const*
+ */
+ cur = (const FT_Module_Class* const*)FT_DEFAULT_MODULES_GET;
- cur = FT_DEFAULT_MODULES_GET;
+ /* test for valid `library' delayed to FT_Add_Module() */
while ( *cur )
{
error = FT_Add_Module( library, *cur );
diff --git a/3party/freetype/src/base/ftmac.c b/3party/freetype/src/base/ftmac.c
index 63f927d57d..f2007485d1 100644
--- a/3party/freetype/src/base/ftmac.c
+++ b/3party/freetype/src/base/ftmac.c
@@ -119,6 +119,8 @@
#endif
+#ifdef FT_MACINTOSH
+
/* This function is deprecated because FSSpec is deprecated in Mac OS X */
FT_EXPORT_DEF( FT_Error )
FT_GetFile_From_Mac_Name( const char* fontName,
@@ -144,7 +146,7 @@
{
#if defined( MAC_OS_X_VERSION_10_5 ) && \
( MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5 )
-
+
OSStatus err;
err = ATSFontGetFileReference( ats_font_id, ats_font_ref );
@@ -1053,5 +1055,7 @@
#endif
}
+#endif /* FT_MACINTOSH */
+
/* END */
diff --git a/3party/freetype/src/base/ftobjs.c b/3party/freetype/src/base/ftobjs.c
index 64575af59e..09ddaee9ea 100644
--- a/3party/freetype/src/base/ftobjs.c
+++ b/3party/freetype/src/base/ftobjs.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType private base classes (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,8 @@
#include FT_TRUETYPE_TAGS_H
#include FT_TRUETYPE_IDS_H
+#include FT_INTERNAL_SERVICE_H
+#include FT_SERVICE_PROPERTIES_H
#include FT_SERVICE_SFNT_H
#include FT_SERVICE_POSTSCRIPT_NAME_H
#include FT_SERVICE_GLYPH_DICT_H
@@ -445,6 +447,10 @@
else
prev->next = cur->next;
+ /* finalize client-specific data */
+ if ( slot->generic.finalizer )
+ slot->generic.finalizer( slot );
+
ft_glyphslot_done( slot );
FT_FREE( slot );
break;
@@ -647,7 +653,7 @@
if ( autohint )
{
- FT_AutoHinter_Service hinting;
+ FT_AutoHinter_Interface hinting;
/* try to load embedded bitmaps first if available */
@@ -676,7 +682,7 @@
internal->transform_flags = 0;
/* load auto-hinted outline */
- hinting = (FT_AutoHinter_Service)hinter->clazz->module_interface;
+ hinting = (FT_AutoHinter_Interface)hinter->clazz->module_interface;
error = hinting->load_glyph( (FT_AutoHinter)hinter,
slot, face->size,
@@ -1187,7 +1193,7 @@
/* there's a Mac-specific extended implementation of FT_New_Face() */
/* in src/base/ftmac.c */
-#if !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON )
+#ifndef FT_MACINTOSH
/* documentation is in freetype.h */
@@ -1211,7 +1217,7 @@
return FT_Open_Face( library, &args, face_index, aface );
}
-#endif /* defined( FT_MACINTOSH ) && !defined( DARWIN_NO_CARBON ) */
+#endif
/* documentation is in freetype.h */
@@ -1520,7 +1526,7 @@
}
-#if !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON )
+#ifndef FT_MACINTOSH
/* The resource header says we've got resource_cnt `POST' (type1) */
/* resources in this file. They all need to be coalesced into */
@@ -1875,7 +1881,7 @@
for ( i = 0; i < FT_RACCESS_N_RULES; i++ )
{
- is_darwin_vfs = raccess_rule_by_darwin_vfs( i );
+ is_darwin_vfs = ft_raccess_rule_by_darwin_vfs( library, i );
if ( is_darwin_vfs && vfs_rfork_has_no_font )
{
FT_TRACE3(( "Skip rule %d: darwin vfs resource fork"
@@ -2051,11 +2057,12 @@
}
else
{
+ error = FT_Err_Missing_Module;
+
/* check each font driver for an appropriate format */
cur = library->modules;
limit = cur + library->num_modules;
-
for ( ; cur < limit; cur++ )
{
/* not all modules are font drivers, so check... */
@@ -2105,30 +2112,30 @@
}
}
- Fail3:
- /* If we are on the mac, and we get an FT_Err_Invalid_Stream_Operation */
- /* it may be because we have an empty data fork, so we need to check */
- /* the resource fork. */
- if ( FT_ERROR_BASE( error ) != FT_Err_Cannot_Open_Stream &&
- FT_ERROR_BASE( error ) != FT_Err_Unknown_File_Format &&
- FT_ERROR_BASE( error ) != FT_Err_Invalid_Stream_Operation )
- goto Fail2;
+ Fail3:
+ /* If we are on the mac, and we get an */
+ /* FT_Err_Invalid_Stream_Operation it may be because we have an */
+ /* empty data fork, so we need to check the resource fork. */
+ if ( FT_ERROR_BASE( error ) != FT_Err_Cannot_Open_Stream &&
+ FT_ERROR_BASE( error ) != FT_Err_Unknown_File_Format &&
+ FT_ERROR_BASE( error ) != FT_Err_Invalid_Stream_Operation )
+ goto Fail2;
#if !defined( FT_MACINTOSH ) && defined( FT_CONFIG_OPTION_MAC_FONTS )
- error = load_mac_face( library, stream, face_index, aface, args );
- if ( !error )
- {
- /* We don't want to go to Success here. We've already done that. */
- /* On the other hand, if we succeeded we still need to close this */
- /* stream (we opened a different stream which extracted the */
- /* interesting information out of this stream here. That stream */
- /* will still be open and the face will point to it). */
- FT_Stream_Free( stream, external_stream );
- return error;
- }
+ error = load_mac_face( library, stream, face_index, aface, args );
+ if ( !error )
+ {
+ /* We don't want to go to Success here. We've already done that. */
+ /* On the other hand, if we succeeded we still need to close this */
+ /* stream (we opened a different stream which extracted the */
+ /* interesting information out of this stream here. That stream */
+ /* will still be open and the face will point to it). */
+ FT_Stream_Free( stream, external_stream );
+ return error;
+ }
- if ( FT_ERROR_BASE( error ) != FT_Err_Unknown_File_Format )
- goto Fail2;
+ if ( FT_ERROR_BASE( error ) != FT_Err_Unknown_File_Format )
+ goto Fail2;
#endif /* !FT_MACINTOSH && FT_CONFIG_OPTION_MAC_FONTS */
/* no driver is able to handle this format */
@@ -4085,10 +4092,10 @@
/* all child faces. */
/* */
/* <InOut> */
- /* module :: A handle to the target driver object. */
+ /* module :: A handle to the target driver object. */
/* */
/* <Note> */
- /* The driver _must_ be LOCKED! */
+ /* The driver _must_ be LOCKED! */
/* */
static void
Destroy_Module( FT_Module module )
@@ -4098,10 +4105,6 @@
FT_Library library = module->library;
- /* finalize client-data - before anything else */
- if ( module->generic.finalizer )
- module->generic.finalizer( module );
-
if ( library && library->auto_hinter == module )
library->auto_hinter = 0;
@@ -4301,23 +4304,23 @@
{
FT_Pointer result = NULL;
+
if ( module )
{
FT_ASSERT( module->clazz && module->clazz->get_interface );
- /* first, look for the service in the module
- */
+ /* first, look for the service in the module */
if ( module->clazz->get_interface )
result = module->clazz->get_interface( module, service_id );
if ( result == NULL )
{
- /* we didn't find it, look in all other modules then
- */
+ /* we didn't find it, look in all other modules then */
FT_Library library = module->library;
FT_Module* cur = library->modules;
FT_Module* limit = cur + library->num_modules;
+
for ( ; cur < limit; cur++ )
{
if ( cur[0] != module )
@@ -4381,6 +4384,118 @@
}
+ FT_Error
+ ft_property_do( FT_Library library,
+ const FT_String* module_name,
+ const FT_String* property_name,
+ void* value,
+ FT_Bool set )
+ {
+ FT_Module* cur;
+ FT_Module* limit;
+ FT_Module_Interface interface;
+
+ FT_Service_Properties service;
+
+#ifdef FT_DEBUG_LEVEL_ERROR
+ const FT_String* set_name = "FT_Property_Set";
+ const FT_String* get_name = "FT_Property_Get";
+ const FT_String* func_name = set ? set_name : get_name;
+#endif
+
+ FT_Bool missing_func;
+
+
+ if ( !library )
+ return FT_Err_Invalid_Library_Handle;
+
+ if ( !module_name || !property_name || !value )
+ return FT_Err_Invalid_Argument;
+
+ cur = library->modules;
+ limit = cur + library->num_modules;
+
+ /* search module */
+ for ( ; cur < limit; cur++ )
+ if ( !ft_strcmp( cur[0]->clazz->module_name, module_name ) )
+ break;
+
+ if ( cur == limit )
+ {
+ FT_ERROR(( "%s: can't find module `%s'\n",
+ func_name, module_name ));
+ return FT_Err_Missing_Module;
+ }
+
+ /* check whether we have a service interface */
+ if ( !cur[0]->clazz->get_interface )
+ {
+ FT_ERROR(( "%s: module `%s' doesn't support properties\n",
+ func_name, module_name ));
+ return FT_Err_Unimplemented_Feature;
+ }
+
+ /* search property service */
+ interface = cur[0]->clazz->get_interface( cur[0],
+ FT_SERVICE_ID_PROPERTIES );
+ if ( !interface )
+ {
+ FT_ERROR(( "%s: module `%s' doesn't support properties\n",
+ func_name, module_name ));
+ return FT_Err_Unimplemented_Feature;
+ }
+
+ service = (FT_Service_Properties)interface;
+
+ if ( set )
+ missing_func = !service->set_property;
+ else
+ missing_func = !service->get_property;
+
+ if ( missing_func )
+ {
+ FT_ERROR(( "%s: property service of module `%s' is broken\n",
+ func_name, module_name ));
+ return FT_Err_Unimplemented_Feature;
+ }
+
+ return set ? service->set_property( cur[0], property_name, value )
+ : service->get_property( cur[0], property_name, value );
+ }
+
+
+ /* documentation is in ftmodapi.h */
+
+ FT_Error
+ FT_Property_Set( FT_Library library,
+ const FT_String* module_name,
+ const FT_String* property_name,
+ const void* value )
+ {
+ return ft_property_do( library,
+ module_name,
+ property_name,
+ (void*)value,
+ TRUE );
+ }
+
+
+ /* documentation is in ftmodapi.h */
+
+ FT_Error
+ FT_Property_Get( FT_Library library,
+ const FT_String* module_name,
+ const FT_String* property_name,
+ void* value )
+ {
+ return ft_property_do( library,
+ module_name,
+ property_name,
+ value,
+ FALSE );
+ }
+
+
/*************************************************************************/
/*************************************************************************/
/*************************************************************************/
@@ -4511,10 +4626,6 @@
memory = library->memory;
- /* Discard client-data */
- if ( library->generic.finalizer )
- library->generic.finalizer( library );
-
/*
* Close all faces in the library. If we don't do this, we can have
* some subtle memory leaks.
diff --git a/3party/freetype/src/base/ftoutln.c b/3party/freetype/src/base/ftoutln.c
index 356b156116..c4fd2660a1 100644
--- a/3party/freetype/src/base/ftoutln.c
+++ b/3party/freetype/src/base/ftoutln.c
@@ -4,7 +4,7 @@
/* */
/* FreeType outline management (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2010 by */
+/* Copyright 1996-2008, 2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -771,7 +771,7 @@
return 1;
}
- return ( n % 2 );
+ return n & 1;
}
@@ -882,9 +882,19 @@
FT_Outline_Embolden( FT_Outline* outline,
FT_Pos strength )
{
+ return FT_Outline_EmboldenXY( outline, strength, strength );
+ }
+
+
+ /* documentation is in ftoutln.h */
+
+ FT_EXPORT_DEF( FT_Error )
+ FT_Outline_EmboldenXY( FT_Outline* outline,
+ FT_Pos xstrength,
+ FT_Pos ystrength )
+ {
FT_Vector* points;
FT_Vector v_prev, v_first, v_next, v_cur;
- FT_Angle rotate, angle_in, angle_out;
FT_Int c, n, first;
FT_Int orientation;
@@ -892,8 +902,9 @@
if ( !outline )
return FT_Err_Invalid_Argument;
- strength /= 2;
- if ( strength == 0 )
+ xstrength /= 2;
+ ystrength /= 2;
+ if ( xstrength == 0 && ystrength == 0 )
return FT_Err_Ok;
orientation = FT_Outline_Get_Orientation( outline );
@@ -905,62 +916,78 @@
return FT_Err_Ok;
}
- if ( orientation == FT_ORIENTATION_TRUETYPE )
- rotate = -FT_ANGLE_PI2;
- else
- rotate = FT_ANGLE_PI2;
-
points = outline->points;
first = 0;
for ( c = 0; c < outline->n_contours; c++ )
{
- int last = outline->contours[c];
+ FT_Vector in, out, shift;
+ FT_Fixed l_in, l_out, l, q, d;
+ int last = outline->contours[c];
v_first = points[first];
v_prev = points[last];
v_cur = v_first;
+ /* compute the incoming vector and its length */
+ in.x = v_cur.x - v_prev.x;
+ in.y = v_cur.y - v_prev.y;
+ l_in = FT_Vector_Length( &in );
+
for ( n = first; n <= last; n++ )
{
- FT_Vector in, out;
- FT_Angle angle_diff;
- FT_Pos d;
- FT_Fixed scale;
-
-
if ( n < last )
v_next = points[n + 1];
else
v_next = v_first;
- /* compute the in and out vectors */
- in.x = v_cur.x - v_prev.x;
- in.y = v_cur.y - v_prev.y;
-
+ /* compute the outgoing vector and its length */
out.x = v_next.x - v_cur.x;
out.y = v_next.y - v_cur.y;
+ l_out = FT_Vector_Length( &out );
- angle_in = FT_Atan2( in.x, in.y );
- angle_out = FT_Atan2( out.x, out.y );
- angle_diff = FT_Angle_Diff( angle_in, angle_out );
- scale = FT_Cos( angle_diff / 2 );
+ d = l_in * l_out + in.x * out.x + in.y * out.y;
- if ( scale < 0x4000L && scale > -0x4000L )
- in.x = in.y = 0;
- else
+ /* shift only if turn is less then ~160 degrees */
+ if ( 16 * d > l_in * l_out )
{
- d = FT_DivFix( strength, scale );
-
- FT_Vector_From_Polar( &in, d, angle_in + angle_diff / 2 - rotate );
+ /* shift components are aligned along bisector */
+ /* and directed according to the outline orientation. */
+ shift.x = l_out * in.y + l_in * out.y;
+ shift.y = l_out * in.x + l_in * out.x;
+
+ if ( orientation == FT_ORIENTATION_TRUETYPE )
+ shift.x = -shift.x;
+ else
+ shift.y = -shift.y;
+
+ /* threshold strength to better handle collapsing segments */
+ l = FT_MIN( l_in, l_out );
+ q = out.x * in.y - out.y * in.x;
+ if ( orientation == FT_ORIENTATION_TRUETYPE )
+ q = -q;
+
+ if ( FT_MulDiv( xstrength, q, l ) < d )
+ shift.x = FT_MulDiv( shift.x, xstrength, d );
+ else
+ shift.x = FT_MulDiv( shift.x, l, q );
+
+
+ if ( FT_MulDiv( ystrength, q, l ) < d )
+ shift.y = FT_MulDiv( shift.y, ystrength, d );
+ else
+ shift.y = FT_MulDiv( shift.y, l, q );
}
+ else
+ shift.x = shift.y = 0;
- outline->points[n].x = v_cur.x + strength + in.x;
- outline->points[n].y = v_cur.y + strength + in.y;
+ outline->points[n].x = v_cur.x + xstrength + shift.x;
+ outline->points[n].y = v_cur.y + ystrength + shift.y;
- v_prev = v_cur;
- v_cur = v_next;
+ in = out;
+ l_in = l_out;
+ v_cur = v_next;
}
first = last + 1;
@@ -975,23 +1002,10 @@
FT_EXPORT_DEF( FT_Orientation )
FT_Outline_Get_Orientation( FT_Outline* outline )
{
- FT_Pos xmin = 32768L;
- FT_Pos xmin_ymin = 32768L;
- FT_Pos xmin_ymax = -32768L;
- FT_Vector* xmin_first = NULL;
- FT_Vector* xmin_last = NULL;
-
- short* contour;
-
- FT_Vector* first;
- FT_Vector* last;
- FT_Vector* prev;
- FT_Vector* point;
-
- int i;
- FT_Pos ray_y[3];
- FT_Orientation result[3] =
- { FT_ORIENTATION_NONE, FT_ORIENTATION_NONE, FT_ORIENTATION_NONE };
+ FT_Vector* points;
+ FT_Vector v_prev, v_cur;
+ FT_Int c, n, first;
+ FT_Pos area = 0;
if ( !outline || outline->n_points <= 0 )
@@ -1002,127 +1016,32 @@
/* cubic or quadratic curves, this test deals with the polygon */
/* only which is spanned up by the control points. */
- first = outline->points;
- for ( contour = outline->contours;
- contour < outline->contours + outline->n_contours;
- contour++, first = last + 1 )
- {
- FT_Pos contour_xmin = 32768L;
- FT_Pos contour_xmax = -32768L;
- FT_Pos contour_ymin = 32768L;
- FT_Pos contour_ymax = -32768L;
-
-
- last = outline->points + *contour;
-
- /* skip degenerate contours */
- if ( last < first + 2 )
- continue;
-
- for ( point = first; point <= last; ++point )
- {
- if ( point->x < contour_xmin )
- contour_xmin = point->x;
-
- if ( point->x > contour_xmax )
- contour_xmax = point->x;
-
- if ( point->y < contour_ymin )
- contour_ymin = point->y;
-
- if ( point->y > contour_ymax )
- contour_ymax = point->y;
- }
-
- if ( contour_xmin < xmin &&
- contour_xmin != contour_xmax &&
- contour_ymin != contour_ymax )
- {
- xmin = contour_xmin;
- xmin_ymin = contour_ymin;
- xmin_ymax = contour_ymax;
- xmin_first = first;
- xmin_last = last;
- }
- }
-
- if ( xmin == 32768L )
- return FT_ORIENTATION_TRUETYPE;
-
- ray_y[0] = ( xmin_ymin * 3 + xmin_ymax ) >> 2;
- ray_y[1] = ( xmin_ymin + xmin_ymax ) >> 1;
- ray_y[2] = ( xmin_ymin + xmin_ymax * 3 ) >> 2;
+ points = outline->points;
- for ( i = 0; i < 3; i++ )
+ first = 0;
+ for ( c = 0; c < outline->n_contours; c++ )
{
- FT_Pos left_x;
- FT_Pos right_x;
- FT_Vector* left1;
- FT_Vector* left2;
- FT_Vector* right1;
- FT_Vector* right2;
-
+ FT_Int last = outline->contours[c];
- RedoRay:
- left_x = 32768L;
- right_x = -32768L;
- left1 = left2 = right1 = right2 = NULL;
+ v_prev = points[last];
- prev = xmin_last;
- for ( point = xmin_first; point <= xmin_last; prev = point, ++point )
+ for ( n = first; n <= last; n++ )
{
- FT_Pos tmp_x;
-
-
- if ( point->y == ray_y[i] || prev->y == ray_y[i] )
- {
- ray_y[i]++;
- goto RedoRay;
- }
-
- if ( ( point->y < ray_y[i] && prev->y < ray_y[i] ) ||
- ( point->y > ray_y[i] && prev->y > ray_y[i] ) )
- continue;
-
- tmp_x = FT_MulDiv( point->x - prev->x,
- ray_y[i] - prev->y,
- point->y - prev->y ) + prev->x;
-
- if ( tmp_x < left_x )
- {
- left_x = tmp_x;
- left1 = prev;
- left2 = point;
- }
-
- if ( tmp_x > right_x )
- {
- right_x = tmp_x;
- right1 = prev;
- right2 = point;
- }
+ v_cur = points[n];
+ area += ( v_cur.y - v_prev.y ) * ( v_cur.x + v_prev.x );
+ v_prev = v_cur;
}
- if ( left1 && right1 )
- {
- if ( left1->y < left2->y && right1->y > right2->y )
- result[i] = FT_ORIENTATION_TRUETYPE;
- else if ( left1->y > left2->y && right1->y < right2->y )
- result[i] = FT_ORIENTATION_POSTSCRIPT;
- else
- result[i] = FT_ORIENTATION_NONE;
- }
+ first = last + 1;
}
- if ( result[0] != FT_ORIENTATION_NONE &&
- ( result[0] == result[1] || result[0] == result[2] ) )
- return result[0];
-
- if ( result[1] != FT_ORIENTATION_NONE && result[1] == result[2] )
- return result[1];
-
- return FT_ORIENTATION_TRUETYPE;
+ if ( area > 0 )
+ return FT_ORIENTATION_POSTSCRIPT;
+ else if ( area < 0 )
+ return FT_ORIENTATION_TRUETYPE;
+ else
+ return FT_ORIENTATION_NONE;
}
diff --git a/3party/freetype/src/base/ftpic.c b/3party/freetype/src/base/ftpic.c
index d5271a9726..b74e90dad3 100644
--- a/3party/freetype/src/base/ftpic.c
+++ b/3party/freetype/src/base/ftpic.c
@@ -26,15 +26,15 @@
/* documentation is in ftpic.h */
FT_BASE_DEF( FT_Error )
- ft_pic_container_init( FT_Library library )
+ ft_pic_container_init( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Error error = FT_Err_Ok;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
- FT_MEM_SET( pic_container, 0, sizeof(*pic_container) );
+ FT_MEM_SET( pic_container, 0, sizeof ( *pic_container ) );
error = ft_base_pic_init( library );
- if(error)
+ if ( error )
return error;
return FT_Err_Ok;
@@ -43,7 +43,7 @@
/* Destroy the contents of the container. */
FT_BASE_DEF( void )
- ft_pic_container_destroy( FT_Library library )
+ ft_pic_container_destroy( FT_Library library )
{
ft_base_pic_free( library );
}
diff --git a/3party/freetype/src/base/ftrfork.c b/3party/freetype/src/base/ftrfork.c
index 33768b0e39..dcefdd28d6 100644
--- a/3party/freetype/src/base/ftrfork.c
+++ b/3party/freetype/src/base/ftrfork.c
@@ -28,7 +28,7 @@
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_RFORK_H
-
+#include "basepic.h"
#undef FT_COMPONENT
#define FT_COMPONENT trace_raccess
@@ -253,14 +253,6 @@
/*************************************************************************/
/*************************************************************************/
- typedef FT_Error
- (*raccess_guess_func)( FT_Library library,
- FT_Stream stream,
- char *base_file_name,
- char **result_file_name,
- FT_Long *result_offset );
-
-
static FT_Error
raccess_guess_apple_double( FT_Library library,
FT_Stream stream,
@@ -325,6 +317,20 @@
FT_Long *result_offset );
+ CONST_FT_RFORK_RULE_ARRAY_BEGIN(ft_raccess_guess_table,
+ ft_raccess_guess_rec)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(apple_double, apple_double)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(apple_single, apple_single)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(darwin_ufs_export, darwin_ufs_export)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(darwin_newvfs, darwin_newvfs)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(darwin_hfsplus, darwin_hfsplus)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(vfat, vfat)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(linux_cap, linux_cap)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(linux_double, linux_double)
+ CONST_FT_RFORK_RULE_ARRAY_ENTRY(linux_netatalk, linux_netatalk)
+ CONST_FT_RFORK_RULE_ARRAY_END
+
+
/*************************************************************************/
/**** ****/
/**** Helper functions ****/
@@ -348,43 +354,6 @@
const char *original_name,
const char *insertion );
-
- typedef enum FT_RFork_Rule_ {
- FT_RFork_Rule_invalid = -2,
- FT_RFork_Rule_uknown, /* -1 */
- FT_RFork_Rule_apple_double,
- FT_RFork_Rule_apple_single,
- FT_RFork_Rule_darwin_ufs_export,
- FT_RFork_Rule_darwin_newvfs,
- FT_RFork_Rule_darwin_hfsplus,
- FT_RFork_Rule_vfat,
- FT_RFork_Rule_linux_cap,
- FT_RFork_Rule_linux_double,
- FT_RFork_Rule_linux_netatalk
- } FT_RFork_Rule;
-
- /* For fast translation between rule index and rule type,
- * the macros FT_RFORK_xxx should be kept consistent with
- * the raccess_guess_funcs table
- */
- typedef struct raccess_guess_rec_ {
- raccess_guess_func func;
- FT_RFork_Rule type;
- } raccess_guess_rec;
-
- static raccess_guess_rec raccess_guess_table[FT_RACCESS_N_RULES] =
- {
- { raccess_guess_apple_double, FT_RFork_Rule_apple_double, },
- { raccess_guess_apple_single, FT_RFork_Rule_apple_single, },
- { raccess_guess_darwin_ufs_export, FT_RFork_Rule_darwin_ufs_export, },
- { raccess_guess_darwin_newvfs, FT_RFork_Rule_darwin_newvfs, },
- { raccess_guess_darwin_hfsplus, FT_RFork_Rule_darwin_hfsplus, },
- { raccess_guess_vfat, FT_RFork_Rule_vfat, },
- { raccess_guess_linux_cap, FT_RFork_Rule_linux_cap, },
- { raccess_guess_linux_double, FT_RFork_Rule_linux_double, },
- { raccess_guess_linux_netatalk, FT_RFork_Rule_linux_netatalk, },
- };
-
FT_BASE_DEF( void )
FT_Raccess_Guess( FT_Library library,
FT_Stream stream,
@@ -393,7 +362,7 @@
FT_Long *offsets,
FT_Error *errors )
{
- FT_Long i;
+ FT_Int i;
for ( i = 0; i < FT_RACCESS_N_RULES; i++ )
@@ -407,7 +376,7 @@
if ( errors[i] )
continue ;
- errors[i] = (raccess_guess_table[i].func)( library,
+ errors[i] = (FT_RACCESS_GUESS_TABLE_GET[i].func)( library,
stream, base_name,
&(new_names[i]),
&(offsets[i]) );
@@ -417,21 +386,28 @@
}
-#if !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON )
+#ifndef FT_MACINTOSH
static FT_RFork_Rule
- raccess_get_rule_type_from_rule_index( FT_UInt rule_index )
+ raccess_get_rule_type_from_rule_index( FT_Library library,
+ FT_UInt rule_index )
{
+ FT_UNUSED( library );
+
if ( rule_index >= FT_RACCESS_N_RULES )
return FT_RFork_Rule_invalid;
- return raccess_guess_table[rule_index].type;
+ return FT_RACCESS_GUESS_TABLE_GET[rule_index].type;
}
+ /*
+ * For this function, refer ftbase.h.
+ */
FT_LOCAL_DEF( FT_Bool )
- raccess_rule_by_darwin_vfs( FT_UInt rule_index )
+ ft_raccess_rule_by_darwin_vfs( FT_Library library,
+ FT_UInt rule_index )
{
- switch( raccess_get_rule_type_from_rule_index( rule_index ) )
+ switch( raccess_get_rule_type_from_rule_index( library, rule_index ) )
{
case FT_RFork_Rule_darwin_newvfs:
case FT_RFork_Rule_darwin_hfsplus:
@@ -851,7 +827,7 @@
FT_Long *offsets,
FT_Error *errors )
{
- int i;
+ FT_Int i;
FT_UNUSED( library );
FT_UNUSED( stream );
diff --git a/3party/freetype/src/base/ftstroke.c b/3party/freetype/src/base/ftstroke.c
index 5399efe9d3..fd6a0c10bc 100644
--- a/3party/freetype/src/base/ftstroke.c
+++ b/3party/freetype/src/base/ftstroke.c
@@ -789,7 +789,7 @@
FT_Stroker_New( FT_Library library,
FT_Stroker *astroker )
{
- FT_Error error;
+ FT_Error error; /* assigned in FT_NEW */
FT_Memory memory;
FT_Stroker stroker = NULL;
@@ -1126,9 +1126,8 @@
middle.y += stroker->center.y;
/* compute first angle point */
- length = FT_MulFix( radius,
- FT_DivFix( 0x10000L - sigma,
- ft_pos_abs( FT_Sin( theta ) ) ) );
+ length = FT_MulDiv( radius, 0x10000L - sigma,
+ ft_pos_abs( FT_Sin( theta ) ) );
FT_Vector_From_Polar( &delta, length, phi + rotate );
delta.x += middle.x;
@@ -1495,7 +1494,7 @@
sinA = ft_pos_abs( FT_Sin( alpha1 - gamma ) );
sinB = ft_pos_abs( FT_Sin( beta - gamma ) );
- alen = FT_DivFix( FT_MulFix( blen, sinA ), sinB );
+ alen = FT_MulDiv( blen, sinA, sinB );
FT_Vector_From_Polar( &delta, alen, beta );
delta.x += start.x;
@@ -1702,7 +1701,7 @@
sinA = ft_pos_abs( FT_Sin( alpha1 - gamma ) );
sinB = ft_pos_abs( FT_Sin( beta - gamma ) );
- alen = FT_DivFix( FT_MulFix( blen, sinA ), sinB );
+ alen = FT_MulDiv( blen, sinA, sinB );
FT_Vector_From_Polar( &delta, alen, beta );
delta.x += start.x;
diff --git a/3party/freetype/src/base/ftsynth.c b/3party/freetype/src/base/ftsynth.c
index d4ec0da570..241d37f426 100644
--- a/3party/freetype/src/base/ftsynth.c
+++ b/3party/freetype/src/base/ftsynth.c
@@ -4,7 +4,7 @@
/* */
/* FreeType synthesizing code for emboldening and slanting (body). */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2010 by */
+/* Copyright 2000-2006, 2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -33,6 +33,7 @@
#undef FT_COMPONENT
#define FT_COMPONENT trace_synth
+
/*************************************************************************/
/*************************************************************************/
/**** ****/
@@ -62,7 +63,7 @@
transform.xx = 0x10000L;
transform.yx = 0x00000L;
- transform.xy = 0x06000L;
+ transform.xy = 0x0366AL;
transform.yy = 0x10000L;
FT_Outline_Transform( outline, &transform );
@@ -72,7 +73,7 @@
/*************************************************************************/
/*************************************************************************/
/**** ****/
- /**** EXPERIMENTAL EMBOLDENING/OUTLINING SUPPORT ****/
+ /**** EXPERIMENTAL EMBOLDENING SUPPORT ****/
/**** ****/
/*************************************************************************/
/*************************************************************************/
@@ -101,12 +102,7 @@
if ( slot->format == FT_GLYPH_FORMAT_OUTLINE )
{
/* ignore error */
- (void)FT_Outline_Embolden( &slot->outline, xstr );
-
- /* this is more than enough for most glyphs; if you need accurate */
- /* values, you have to call FT_Outline_Get_CBox */
- xstr = xstr * 2;
- ystr = xstr;
+ (void)FT_Outline_EmboldenXY( &slot->outline, xstr, ystr );
}
else /* slot->format == FT_GLYPH_FORMAT_BITMAP */
{
@@ -143,13 +139,10 @@
if ( slot->advance.y )
slot->advance.y += ystr;
- slot->metrics.width += xstr;
- slot->metrics.height += ystr;
- slot->metrics.horiBearingY += ystr;
- slot->metrics.horiAdvance += xstr;
- slot->metrics.vertBearingX -= xstr / 2;
- slot->metrics.vertBearingY += ystr;
- slot->metrics.vertAdvance += ystr;
+ slot->metrics.width += xstr;
+ slot->metrics.height += ystr;
+ slot->metrics.horiAdvance += xstr;
+ slot->metrics.vertAdvance += ystr;
/* XXX: 16-bit overflow case must be excluded before here */
if ( slot->format == FT_GLYPH_FORMAT_BITMAP )
diff --git a/3party/freetype/src/base/fttrigon.c b/3party/freetype/src/base/fttrigon.c
index fdf433ab86..52395388b1 100644
--- a/3party/freetype/src/base/fttrigon.c
+++ b/3party/freetype/src/base/fttrigon.c
@@ -4,7 +4,7 @@
/* */
/* FreeType trigonometric functions (body). */
/* */
-/* Copyright 2001, 2002, 2003, 2004, 2005 by */
+/* Copyright 2001-2005, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -21,25 +21,30 @@
#include FT_TRIGONOMETRY_H
- /* the following is 0.2715717684432231 * 2^30 */
-#define FT_TRIG_COSCALE 0x11616E8EUL
+#ifdef FT_LONG64
+ typedef FT_INT64 FT_Int64;
+#endif
+
+
+ /* the Cordic shrink factor 0.607252935008887 * 2^32 */
+#define FT_TRIG_SCALE 0x9B74EDA8UL
+
+ /* the following is 0.607252935008887 * 2^30 */
+#define FT_TRIG_COSCALE 0x26DD3B6AUL
/* this table was generated for FT_PI = 180L << 16, i.e. degrees */
#define FT_TRIG_MAX_ITERS 23
static const FT_Fixed
- ft_trig_arctan_table[24] =
+ ft_trig_arctan_table[23] =
{
- 4157273L, 2949120L, 1740967L, 919879L, 466945L, 234379L, 117304L,
- 58666L, 29335L, 14668L, 7334L, 3667L, 1833L, 917L, 458L, 229L, 115L,
+ 2949120L, 1740967L, 919879L, 466945L, 234379L, 117304L, 58666L,
+ 29335L, 14668L, 7334L, 3667L, 1833L, 917L, 458L, 229L, 115L,
57L, 29L, 14L, 7L, 4L, 2L, 1L
};
- /* the Cordic shrink factor, multiplied by 2^32 */
-#define FT_TRIG_SCALE 1166391785UL /* 0x4585BA38UL */
-
-#ifdef FT_CONFIG_HAS_INT64
+#ifdef FT_LONG64
/* multiply a given value by the CORDIC shrink factor */
static FT_Fixed
@@ -58,7 +63,7 @@
return ( s >= 0 ) ? val : -val;
}
-#else /* !FT_CONFIG_HAS_INT64 */
+#else /* !FT_LONG64 */
/* multiply a given value by the CORDIC shrink factor */
static FT_Fixed
@@ -72,10 +77,10 @@
val = ( val >= 0 ) ? val : -val;
v1 = (FT_UInt32)val >> 16;
- v2 = (FT_UInt32)(val & 0xFFFFL);
+ v2 = (FT_UInt32)( val & 0xFFFFL );
- k1 = (FT_UInt32)FT_TRIG_SCALE >> 16; /* constant */
- k2 = (FT_UInt32)(FT_TRIG_SCALE & 0xFFFFL); /* constant */
+ k1 = (FT_UInt32)FT_TRIG_SCALE >> 16; /* constant */
+ k2 = (FT_UInt32)( FT_TRIG_SCALE & 0xFFFFL ); /* constant */
hi = k1 * v1;
lo1 = k1 * v2 + k2 * v1; /* can't overflow */
@@ -93,7 +98,7 @@
return ( s >= 0 ) ? val : -val;
}
-#endif /* !FT_CONFIG_HAS_INT64 */
+#endif /* !FT_LONG64 */
static FT_Int
@@ -209,25 +214,9 @@
theta -= FT_ANGLE_PI;
}
- /* Initial pseudorotation, with left shift */
arctanptr = ft_trig_arctan_table;
- if ( theta < 0 )
- {
- xtemp = x + ( y << 1 );
- y = y - ( x << 1 );
- x = xtemp;
- theta += *arctanptr++;
- }
- else
- {
- xtemp = x - ( y << 1 );
- y = y + ( x << 1 );
- x = xtemp;
- theta -= *arctanptr++;
- }
-
- /* Subsequent pseudorotations, with right shifts */
+ /* Pseudorotations, with right shifts */
i = 0;
do
{
@@ -255,9 +244,9 @@
static void
ft_trig_pseudo_polarize( FT_Vector* vec )
{
- FT_Fixed theta;
- FT_Fixed yi, i;
- FT_Fixed x, y;
+ FT_Angle theta;
+ FT_Int i;
+ FT_Fixed x, y, xtemp;
const FT_Fixed *arctanptr;
@@ -278,41 +267,23 @@
arctanptr = ft_trig_arctan_table;
- if ( y < 0 )
- {
- /* Rotate positive */
- yi = y + ( x << 1 );
- x = x - ( y << 1 );
- y = yi;
- theta -= *arctanptr++; /* Subtract angle */
- }
- else
- {
- /* Rotate negative */
- yi = y - ( x << 1 );
- x = x + ( y << 1 );
- y = yi;
- theta += *arctanptr++; /* Add angle */
- }
-
+ /* Pseudorotations, with right shifts */
i = 0;
do
{
- if ( y < 0 )
+ if ( y > 0 )
{
- /* Rotate positive */
- yi = y + ( x >> i );
- x = x - ( y >> i );
- y = yi;
- theta -= *arctanptr++;
+ xtemp = x + ( y >> i );
+ y = y - ( x >> i );
+ x = xtemp;
+ theta += *arctanptr++;
}
else
{
- /* Rotate negative */
- yi = y - ( x >> i );
- x = x + ( y >> i );
- y = yi;
- theta += *arctanptr++;
+ xtemp = x - ( y >> i );
+ y = y + ( x >> i );
+ x = xtemp;
+ theta -= *arctanptr++;
}
} while ( ++i < FT_TRIG_MAX_ITERS );
diff --git a/3party/freetype/src/bdf/bdf.h b/3party/freetype/src/bdf/bdf.h
index 561b4158a5..d11be6f147 100644
--- a/3party/freetype/src/bdf/bdf.h
+++ b/3party/freetype/src/bdf/bdf.h
@@ -1,6 +1,6 @@
/*
* Copyright 2000 Computing Research Labs, New Mexico State University
- * Copyright 2001, 2002, 2003, 2004 Francesco Zappa Nardelli
+ * Copyright 2001-2004, 2011 Francesco Zappa Nardelli
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
@@ -226,8 +226,10 @@ FT_BEGIN_HEADER
void* internal; /* Internal data for the font. */
- unsigned long nmod[2048]; /* Bitmap indicating modified glyphs. */
- unsigned long umod[2048]; /* Bitmap indicating modified */
+ /* The size of the next two arrays must be in sync with the */
+ /* size of the `have' array in the `bdf_parse_t' structure. */
+ unsigned long nmod[34816]; /* Bitmap indicating modified glyphs. */
+ unsigned long umod[34816]; /* Bitmap indicating modified */
/* unencoded glyphs. */
unsigned short modified; /* Boolean indicating font modified. */
unsigned short bpp; /* Bits per pixel. */
diff --git a/3party/freetype/src/bdf/bdfdrivr.c b/3party/freetype/src/bdf/bdfdrivr.c
index 47d0eae89f..0edcc77b6c 100644
--- a/3party/freetype/src/bdf/bdfdrivr.c
+++ b/3party/freetype/src/bdf/bdfdrivr.c
@@ -2,7 +2,7 @@
FreeType font driver for bdf files
- Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by
+ Copyright (C) 2001-2008, 2011 by
Francesco Zappa Nardelli
Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -30,7 +30,7 @@ THE SOFTWARE.
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_OBJECTS_H
#include FT_BDF_H
-#include FT_TRUETYPE_IDS_H
+#include FT_TRUETYPE_IDS_H
#include FT_SERVICE_BDF_H
#include FT_SERVICE_XFREE86_NAME_H
@@ -332,8 +332,6 @@ THE SOFTWARE.
FT_FREE( bdfface->available_sizes );
FT_FREE( face->bdffont );
-
- FT_TRACE4(( "BDF_Face_Done: done face\n" ));
}
@@ -356,6 +354,8 @@ THE SOFTWARE.
FT_UNUSED( face_index );
+ FT_TRACE2(( "BDF driver\n" ));
+
if ( FT_STREAM_SEEK( 0 ) )
goto Exit;
@@ -367,7 +367,7 @@ THE SOFTWARE.
error = bdf_load_font( stream, memory, &options, &font );
if ( error == BDF_Err_Missing_Startfont_Field )
{
- FT_TRACE2(( "[not a valid BDF file]\n" ));
+ FT_TRACE2(( " not a BDF file\n" ));
goto Fail;
}
else if ( error )
@@ -379,10 +379,10 @@ THE SOFTWARE.
bdf_property_t* prop = NULL;
- FT_TRACE4(( "number of glyphs: %d (%d)\n",
+ FT_TRACE4(( " number of glyphs: allocated %d (used %d)\n",
font->glyphs_size,
font->glyphs_used ));
- FT_TRACE4(( "number of unencoded glyphs: %d (%d)\n",
+ FT_TRACE4(( " number of unencoded glyphs: allocated %d (used %d)\n",
font->unencoded_size,
font->unencoded_used ));
@@ -482,7 +482,7 @@ THE SOFTWARE.
for ( n = 0; n < font->glyphs_size; n++ )
{
(face->en_table[n]).enc = cur[n].encoding;
- FT_TRACE4(( "idx %d, val 0x%lX\n", n, cur[n].encoding ));
+ FT_TRACE4(( " idx %d, val 0x%lX\n", n, cur[n].encoding ));
(face->en_table[n]).glyph = (FT_Short)n;
if ( cur[n].encoding == font->default_char )
@@ -490,7 +490,8 @@ THE SOFTWARE.
if ( n < FT_UINT_MAX )
face->default_glyph = (FT_UInt)n;
else
- FT_TRACE1(( "idx %d is too large for this system\n", n ));
+ FT_TRACE1(( "BDF_Face_Init:"
+ " idx %d is too large for this system\n", n ));
}
}
}
@@ -761,8 +762,8 @@ THE SOFTWARE.
case BDF_INTEGER:
if ( prop->value.l > 0x7FFFFFFFL || prop->value.l < ( -1 - 0x7FFFFFFFL ) )
{
- FT_TRACE1(( "bdf_get_bdf_property: " ));
- FT_TRACE1(( "too large integer 0x%x is truncated\n" ));
+ FT_TRACE1(( "bdf_get_bdf_property:"
+ " too large integer 0x%x is truncated\n" ));
}
aproperty->type = BDF_PROPERTY_TYPE_INTEGER;
aproperty->u.integer = (FT_Int32)prop->value.l;
@@ -771,8 +772,8 @@ THE SOFTWARE.
case BDF_CARDINAL:
if ( prop->value.ul > 0xFFFFFFFFUL )
{
- FT_TRACE1(( "bdf_get_bdf_property: " ));
- FT_TRACE1(( "too large cardinal 0x%x is truncated\n" ));
+ FT_TRACE1(( "bdf_get_bdf_property:"
+ " too large cardinal 0x%x is truncated\n" ));
}
aproperty->type = BDF_PROPERTY_TYPE_CARDINAL;
aproperty->u.cardinal = (FT_UInt32)prop->value.ul;
@@ -847,9 +848,9 @@ THE SOFTWARE.
0,
- (FT_Module_Constructor)0,
- (FT_Module_Destructor) 0,
- (FT_Module_Requester) bdf_driver_requester
+ 0, /* FT_Module_Constructor */
+ 0, /* FT_Module_Destructor */
+ bdf_driver_requester
},
sizeof ( BDF_FaceRec ),
@@ -869,9 +870,9 @@ THE SOFTWARE.
#endif
BDF_Glyph_Load,
- 0, /* FT_Face_GetKerningFunc */
- 0, /* FT_Face_AttachFunc */
- 0, /* FT_Face_GetAdvancesFunc */
+ 0, /* FT_Face_GetKerningFunc */
+ 0, /* FT_Face_AttachFunc */
+ 0, /* FT_Face_GetAdvancesFunc */
BDF_Size_Request,
BDF_Size_Select
diff --git a/3party/freetype/src/bdf/bdfdrivr.h b/3party/freetype/src/bdf/bdfdrivr.h
index db7093bb45..ca0dae50d2 100644
--- a/3party/freetype/src/bdf/bdfdrivr.h
+++ b/3party/freetype/src/bdf/bdfdrivr.h
@@ -38,7 +38,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
typedef struct BDF_encoding_el_
diff --git a/3party/freetype/src/bdf/bdferror.h b/3party/freetype/src/bdf/bdferror.h
index b27fa333bb..ea545aca06 100644
--- a/3party/freetype/src/bdf/bdferror.h
+++ b/3party/freetype/src/bdf/bdferror.h
@@ -1,5 +1,5 @@
/*
- * Copyright 2001, 2002 Francesco Zappa Nardelli
+ * Copyright 2001, 2002, 2012 Francesco Zappa Nardelli
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
@@ -33,6 +33,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX BDF_Err_
#define FT_ERR_BASE FT_Mod_Err_BDF
diff --git a/3party/freetype/src/bdf/bdflib.c b/3party/freetype/src/bdf/bdflib.c
index 61bae36b30..7208d99c94 100644
--- a/3party/freetype/src/bdf/bdflib.c
+++ b/3party/freetype/src/bdf/bdflib.c
@@ -1,6 +1,6 @@
/*
* Copyright 2000 Computing Research Labs, New Mexico State University
- * Copyright 2001-2011
+ * Copyright 2001-2012
* Francesco Zappa Nardelli
*
* Permission is hereby granted, free of charge, to any person obtaining a
@@ -169,6 +169,43 @@
sizeof ( _bdf_properties[0] );
+ /* Auto correction messages. */
+#define ACMSG1 "FONT_ASCENT property missing. " \
+ "Added `FONT_ASCENT %hd'.\n"
+#define ACMSG2 "FONT_DESCENT property missing. " \
+ "Added `FONT_DESCENT %hd'.\n"
+#define ACMSG3 "Font width != actual width. Old: %hd New: %hd.\n"
+#define ACMSG4 "Font left bearing != actual left bearing. " \
+ "Old: %hd New: %hd.\n"
+#define ACMSG5 "Font ascent != actual ascent. Old: %hd New: %hd.\n"
+#define ACMSG6 "Font descent != actual descent. Old: %hd New: %hd.\n"
+#define ACMSG7 "Font height != actual height. Old: %hd New: %hd.\n"
+#define ACMSG8 "Glyph scalable width (SWIDTH) adjustments made.\n"
+#define ACMSG9 "SWIDTH field missing at line %ld. Set automatically.\n"
+#define ACMSG10 "DWIDTH field missing at line %ld. Set to glyph width.\n"
+#define ACMSG11 "SIZE bits per pixel field adjusted to %hd.\n"
+#define ACMSG12 "Duplicate encoding %ld (%s) changed to unencoded.\n"
+#define ACMSG13 "Glyph %ld extra rows removed.\n"
+#define ACMSG14 "Glyph %ld extra columns removed.\n"
+#define ACMSG15 "Incorrect glyph count: %ld indicated but %ld found.\n"
+#define ACMSG16 "Glyph %ld missing columns padded with zero bits.\n"
+
+ /* Error messages. */
+#define ERRMSG1 "[line %ld] Missing `%s' line.\n"
+#define ERRMSG2 "[line %ld] Font header corrupted or missing fields.\n"
+#define ERRMSG3 "[line %ld] Font glyphs corrupted or missing fields.\n"
+#define ERRMSG4 "[line %ld] BBX too big.\n"
+#define ERRMSG5 "[line %ld] `%s' value too big.\n"
+#define ERRMSG6 "[line %ld] Input line too long.\n"
+#define ERRMSG7 "[line %ld] Font name too long.\n"
+#define ERRMSG8 "[line %ld] Invalid `%s' value.\n"
+#define ERRMSG9 "[line %ld] Invalid keyword.\n"
+
+ /* Debug messages. */
+#define DBGMSG1 " [%6ld] %s" /* no \n */
+#define DBGMSG2 " (0x%lX)\n"
+
+
/*************************************************************************/
/* */
/* Hash table utilities for the properties. */
@@ -377,7 +414,8 @@
bdf_font_t* font;
bdf_options_t* opts;
- unsigned long have[2048];
+ unsigned long have[34816]; /* must be in sync with `nmod' and `umod' */
+ /* arrays from `bdf_font_t' structure */
_bdf_list_t list;
FT_Memory memory;
@@ -424,7 +462,7 @@
if ( num_items > list->size )
{
unsigned long oldsize = list->size; /* same as _bdf_list_t.size */
- unsigned long newsize = oldsize + ( oldsize >> 1 ) + 4;
+ unsigned long newsize = oldsize + ( oldsize >> 1 ) + 5;
unsigned long bigsize = (unsigned long)( FT_INT_MAX / sizeof ( char* ) );
FT_Memory memory = list->memory;
@@ -507,6 +545,10 @@
}
+ /* The code below ensures that we have at least 4 + 1 `field' */
+ /* elements in `list' (which are possibly NULL) so that we */
+ /* don't have to check the number of fields in most cases. */
+
static FT_Error
_bdf_list_split( _bdf_list_t* list,
char* separators,
@@ -521,6 +563,14 @@
/* Initialize the list. */
list->used = 0;
+ if ( list->size )
+ {
+ list->field[0] = (char*)empty;
+ list->field[1] = (char*)empty;
+ list->field[2] = (char*)empty;
+ list->field[3] = (char*)empty;
+ list->field[4] = (char*)empty;
+ }
/* If the line is empty, then simply return. */
if ( linelen == 0 || line[0] == 0 )
@@ -687,6 +737,7 @@
if ( buf_size >= 65536UL ) /* limit ourselves to 64KByte */
{
+ FT_ERROR(( "_bdf_readstream: " ERRMSG6, lineno ));
error = BDF_Err_Invalid_Argument;
goto Exit;
}
@@ -719,11 +770,11 @@
/* XXX: Use encoding independent value for 0x1a */
if ( buf[start] != '#' && buf[start] != 0x1a && end > start )
{
- error = (*cb)( buf + start, end - start, lineno,
+ error = (*cb)( buf + start, (unsigned long)( end - start ), lineno,
(void*)&cb, client_data );
/* Redo if we have encountered CHARS without properties. */
if ( error == -1 )
- error = (*cb)( buf + start, end - start, lineno,
+ error = (*cb)( buf + start, (unsigned long)( end - start ), lineno,
(void*)&cb, client_data );
if ( error )
break;
@@ -791,9 +842,6 @@
};
-#define isdigok( m, d ) (m[(d) >> 3] & ( 1 << ( (d) & 7 ) ) )
-
-
/* Routine to convert an ASCII string into an unsigned long integer. */
static unsigned long
_bdf_atoul( char* s,
@@ -831,7 +879,7 @@
s += 2;
}
- for ( v = 0; isdigok( dmap, *s ); s++ )
+ for ( v = 0; sbitset( dmap, *s ); s++ )
v = v * base + a2i[(int)*s];
if ( end != 0 )
@@ -886,7 +934,7 @@
s += 2;
}
- for ( v = 0; isdigok( dmap, *s ); s++ )
+ for ( v = 0; sbitset( dmap, *s ); s++ )
v = v * base + a2i[(int)*s];
if ( end != 0 )
@@ -941,7 +989,7 @@
s += 2;
}
- for ( v = 0; isdigok( dmap, *s ); s++ )
+ for ( v = 0; sbitset( dmap, *s ); s++ )
v = (short)( v * base + a2i[(int)*s] );
if ( end != 0 )
@@ -1079,33 +1127,6 @@
#define _BDF_GLYPH_HEIGHT_CHECK 0x80000000UL
- /* Auto correction messages. */
-#define ACMSG1 "FONT_ASCENT property missing. " \
- "Added \"FONT_ASCENT %hd\".\n"
-#define ACMSG2 "FONT_DESCENT property missing. " \
- "Added \"FONT_DESCENT %hd\".\n"
-#define ACMSG3 "Font width != actual width. Old: %hd New: %hd.\n"
-#define ACMSG4 "Font left bearing != actual left bearing. " \
- "Old: %hd New: %hd.\n"
-#define ACMSG5 "Font ascent != actual ascent. Old: %hd New: %hd.\n"
-#define ACMSG6 "Font descent != actual descent. Old: %hd New: %hd.\n"
-#define ACMSG7 "Font height != actual height. Old: %hd New: %hd.\n"
-#define ACMSG8 "Glyph scalable width (SWIDTH) adjustments made.\n"
-#define ACMSG9 "SWIDTH field missing at line %ld. Set automatically.\n"
-#define ACMSG10 "DWIDTH field missing at line %ld. Set to glyph width.\n"
-#define ACMSG11 "SIZE bits per pixel field adjusted to %hd.\n"
-#define ACMSG12 "Duplicate encoding %ld (%s) changed to unencoded.\n"
-#define ACMSG13 "Glyph %ld extra rows removed.\n"
-#define ACMSG14 "Glyph %ld extra columns removed.\n"
-#define ACMSG15 "Incorrect glyph count: %ld indicated but %ld found.\n"
-
- /* Error messages. */
-#define ERRMSG1 "[line %ld] Missing \"%s\" line.\n"
-#define ERRMSG2 "[line %ld] Font header corrupted or missing fields.\n"
-#define ERRMSG3 "[line %ld] Font glyphs corrupted or missing fields.\n"
-#define ERRMSG4 "[line %ld] BBX too big.\n"
-
-
static FT_Error
_bdf_add_comment( bdf_font_t* font,
char* comment,
@@ -1137,7 +1158,8 @@
/* default specified in the options. */
static FT_Error
_bdf_set_default_spacing( bdf_font_t* font,
- bdf_options_t* opts )
+ bdf_options_t* opts,
+ unsigned long lineno )
{
size_t len;
char name[256];
@@ -1162,6 +1184,7 @@
/* Limit ourselves to 256 characters in the font name. */
if ( len >= 256 )
{
+ FT_ERROR(( "_bdf_set_default_spacing: " ERRMSG7, lineno ));
error = BDF_Err_Invalid_Argument;
goto Exit;
}
@@ -1241,7 +1264,8 @@
ep = line + linelen;
/* Trim the leading whitespace if it exists. */
- *sp++ = 0;
+ if ( *sp )
+ *sp++ = 0;
while ( *sp &&
( *sp == ' ' || *sp == '\t' ) )
sp++;
@@ -1265,9 +1289,10 @@
static FT_Error
- _bdf_add_property( bdf_font_t* font,
- char* name,
- char* value )
+ _bdf_add_property( bdf_font_t* font,
+ char* name,
+ char* value,
+ unsigned long lineno )
{
size_t propid;
hashnode hn;
@@ -1405,6 +1430,7 @@
{
if ( !fp->value.atom )
{
+ FT_ERROR(( "_bdf_add_property: " ERRMSG8, lineno, "SPACING" ));
error = BDF_Err_Invalid_File_Format;
goto Exit;
}
@@ -1493,8 +1519,9 @@
/* Limit ourselves to 1,114,112 glyphs in the font (this is the */
/* number of code points available in Unicode). */
- if ( p->cnt >= 1114112UL )
+ if ( p->cnt >= 0x110000UL )
{
+ FT_ERROR(( "_bdf_parse_glyphs: " ERRMSG5, lineno, "CHARS" ));
error = BDF_Err_Invalid_Argument;
goto Exit;
}
@@ -1554,6 +1581,7 @@
if ( !s )
{
+ FT_ERROR(( "_bdf_parse_glyphs: " ERRMSG8, lineno, "STARTCHAR" ));
error = BDF_Err_Invalid_File_Format;
goto Exit;
}
@@ -1565,6 +1593,8 @@
p->flags |= _BDF_GLYPH;
+ FT_TRACE4(( DBGMSG1, lineno, s ));
+
goto Exit;
}
@@ -1585,11 +1615,27 @@
p->glyph_enc = _bdf_atol( p->list.field[1], 0, 10 );
- /* Check that the encoding is in the range [0,65536] because */
- /* otherwise p->have (a bitmap with static size) overflows. */
- if ( p->glyph_enc > 0 &&
- (size_t)p->glyph_enc >= sizeof ( p->have ) * 8 )
+ /* Normalize negative encoding values. The specification only */
+ /* allows -1, but we can be more generous here. */
+ if ( p->glyph_enc < -1 )
+ p->glyph_enc = -1;
+
+ /* Check for alternative encoding format. */
+ if ( p->glyph_enc == -1 && p->list.used > 2 )
+ p->glyph_enc = _bdf_atol( p->list.field[2], 0, 10 );
+
+ if ( p->glyph_enc < -1 )
+ p->glyph_enc = -1;
+
+ FT_TRACE4(( DBGMSG2, p->glyph_enc ));
+
+ /* Check that the encoding is in the Unicode range because */
+ /* otherwise p->have (a bitmap with static size) overflows. */
+ if ( p->glyph_enc > 0 &&
+ (size_t)p->glyph_enc >= sizeof ( p->have ) /
+ sizeof ( unsigned long ) * 32 )
{
+ FT_ERROR(( "_bdf_parse_glyphs: " ERRMSG5, lineno, "ENCODING" ));
error = BDF_Err_Invalid_File_Format;
goto Exit;
}
@@ -1702,19 +1748,32 @@
for ( i = 0; i < nibbles; i++ )
{
c = line[i];
+ if ( !sbitset( hdigits, c ) )
+ break;
*bp = (FT_Byte)( ( *bp << 4 ) + a2i[c] );
if ( i + 1 < nibbles && ( i & 1 ) )
*++bp = 0;
}
+ /* If any line has not enough columns, */
+ /* indicate they have been padded with zero bits. */
+ if ( i < nibbles &&
+ !( p->flags & _BDF_GLYPH_WIDTH_CHECK ) )
+ {
+ FT_TRACE2(( "_bdf_parse_glyphs: " ACMSG16, glyph->encoding ));
+ p->flags |= _BDF_GLYPH_WIDTH_CHECK;
+ font->modified = 1;
+ }
+
/* Remove possible garbage at the right. */
mask_index = ( glyph->bbx.width * p->font->bpp ) & 7;
if ( glyph->bbx.width )
*bp &= nibble_mask[mask_index];
/* If any line has extra columns, indicate they have been removed. */
- if ( ( line[nibbles] == '0' || a2i[(int)line[nibbles]] != 0 ) &&
- !( p->flags & _BDF_GLYPH_WIDTH_CHECK ) )
+ if ( i == nibbles &&
+ sbitset( hdigits, line[nibbles] ) &&
+ !( p->flags & _BDF_GLYPH_WIDTH_CHECK ) )
{
FT_TRACE2(( "_bdf_parse_glyphs: " ACMSG14, glyph->encoding ));
p->flags |= _BDF_GLYPH_WIDTH_CHECK;
@@ -1729,12 +1788,7 @@
if ( ft_memcmp( line, "SWIDTH", 6 ) == 0 )
{
if ( !( p->flags & _BDF_ENCODING ) )
- {
- /* Missing ENCODING field. */
- FT_ERROR(( "_bdf_parse_glyphs: " ERRMSG1, lineno, "ENCODING" ));
- error = BDF_Err_Missing_Encoding_Field;
- goto Exit;
- }
+ goto Missing_Encoding;
error = _bdf_list_split( &p->list, (char *)" +", line, linelen );
if ( error )
@@ -1749,6 +1803,9 @@
/* Expect the DWIDTH (scalable width) field next. */
if ( ft_memcmp( line, "DWIDTH", 6 ) == 0 )
{
+ if ( !( p->flags & _BDF_ENCODING ) )
+ goto Missing_Encoding;
+
error = _bdf_list_split( &p->list, (char *)" +", line, linelen );
if ( error )
goto Exit;
@@ -1774,6 +1831,9 @@
/* Expect the BBX field next. */
if ( ft_memcmp( line, "BBX", 3 ) == 0 )
{
+ if ( !( p->flags & _BDF_ENCODING ) )
+ goto Missing_Encoding;
+
error = _bdf_list_split( &p->list, (char *)" +", line, linelen );
if ( error )
goto Exit;
@@ -1851,10 +1911,10 @@
}
/* Allocate enough space for the bitmap. */
- glyph->bpr = ( glyph->bbx.width * p->font->bpp + 7 ) >> 3;
+ glyph->bpr = ( glyph->bbx.width * p->font->bpp + 7 ) >> 3;
bitmap_size = glyph->bpr * glyph->bbx.height;
- if ( bitmap_size > 0xFFFFU )
+ if ( glyph->bpr > 0xFFFFU || bitmap_size > 0xFFFFU )
{
FT_ERROR(( "_bdf_parse_glyphs: " ERRMSG4, lineno ));
error = BDF_Err_Bbx_Too_Big;
@@ -1872,7 +1932,14 @@
goto Exit;
}
+ FT_ERROR(( "_bdf_parse_glyphs: " ERRMSG9, lineno ));
error = BDF_Err_Invalid_File_Format;
+ goto Exit;
+
+ Missing_Encoding:
+ /* Missing ENCODING field. */
+ FT_ERROR(( "_bdf_parse_glyphs: " ERRMSG1, lineno, "ENCODING" ));
+ error = BDF_Err_Missing_Encoding_Field;
Exit:
if ( error && ( p->flags & _BDF_GLYPH ) )
@@ -1917,7 +1984,8 @@
{
p->font->font_ascent = p->font->bbx.ascent;
ft_sprintf( nbuf, "%hd", p->font->bbx.ascent );
- error = _bdf_add_property( p->font, (char *)"FONT_ASCENT", nbuf );
+ error = _bdf_add_property( p->font, (char *)"FONT_ASCENT",
+ nbuf, lineno );
if ( error )
goto Exit;
@@ -1929,7 +1997,8 @@
{
p->font->font_descent = p->font->bbx.descent;
ft_sprintf( nbuf, "%hd", p->font->bbx.descent );
- error = _bdf_add_property( p->font, (char *)"FONT_DESCENT", nbuf );
+ error = _bdf_add_property( p->font, (char *)"FONT_DESCENT",
+ nbuf, lineno );
if ( error )
goto Exit;
@@ -1955,13 +2024,13 @@
value += 7;
if ( *value )
*value++ = 0;
- error = _bdf_add_property( p->font, name, value );
+ error = _bdf_add_property( p->font, name, value, lineno );
if ( error )
goto Exit;
}
else if ( _bdf_is_atom( line, linelen, &name, &value, p->font ) )
{
- error = _bdf_add_property( p->font, name, value );
+ error = _bdf_add_property( p->font, name, value, lineno );
if ( error )
goto Exit;
}
@@ -1975,7 +2044,7 @@
_bdf_list_shift( &p->list, 1 );
value = _bdf_list_join( &p->list, ' ', &vlen );
- error = _bdf_add_property( p->font, name, value );
+ error = _bdf_add_property( p->font, name, value, lineno );
if ( error )
goto Exit;
}
@@ -2041,7 +2110,8 @@
if ( ft_memcmp( line, "STARTFONT", 9 ) != 0 )
{
- /* No STARTFONT field is a good indication of a problem. */
+ /* we don't emit an error message since this code gets */
+ /* explicitly caught one level higher */
error = BDF_Err_Missing_Startfont_Field;
goto Exit;
}
@@ -2103,7 +2173,10 @@
p->cnt = p->font->props_size = _bdf_atoul( p->list.field[1], 0, 10 );
if ( FT_NEW_ARRAY( p->font->props, p->cnt ) )
+ {
+ p->font->props_size = 0;
goto Exit;
+ }
p->flags |= _BDF_PROPS;
*next = _bdf_parse_properties;
@@ -2154,6 +2227,7 @@
if ( !s )
{
+ FT_ERROR(( "_bdf_parse_start: " ERRMSG8, lineno, "FONT" ));
error = BDF_Err_Invalid_File_Format;
goto Exit;
}
@@ -2167,7 +2241,7 @@
/* If the font name is an XLFD name, set the spacing to the one in */
/* the font name. If there is no spacing fall back on the default. */
- error = _bdf_set_default_spacing( p->font, p->opts );
+ error = _bdf_set_default_spacing( p->font, p->opts, lineno );
if ( error )
goto Exit;
@@ -2248,14 +2322,16 @@
/* for compiling fonts. */
p->font->font_ascent = p->font->bbx.ascent;
ft_sprintf( nbuf, "%hd", p->font->bbx.ascent );
- error = _bdf_add_property( p->font, (char *)"FONT_ASCENT", nbuf );
+ error = _bdf_add_property( p->font, (char *)"FONT_ASCENT",
+ nbuf, lineno );
if ( error )
goto Exit;
FT_TRACE2(( "_bdf_parse_properties: " ACMSG1, p->font->bbx.ascent ));
p->font->font_descent = p->font->bbx.descent;
ft_sprintf( nbuf, "%hd", p->font->bbx.descent );
- error = _bdf_add_property( p->font, (char *)"FONT_DESCENT", nbuf );
+ error = _bdf_add_property( p->font, (char *)"FONT_DESCENT",
+ nbuf, lineno );
if ( error )
goto Exit;
FT_TRACE2(( "_bdf_parse_properties: " ACMSG2, p->font->bbx.descent ));
@@ -2269,6 +2345,7 @@
goto Exit;
}
+ FT_ERROR(( "_bdf_parse_start: " ERRMSG9, lineno ));
error = BDF_Err_Invalid_File_Format;
Exit:
@@ -2381,22 +2458,20 @@
if ( p->flags & _BDF_START )
{
+ /* The ENDFONT field was never reached or did not exist. */
+ if ( !( p->flags & _BDF_GLYPHS ) )
{
- /* The ENDFONT field was never reached or did not exist. */
- if ( !( p->flags & _BDF_GLYPHS ) )
- {
- /* Error happened while parsing header. */
- FT_ERROR(( "bdf_load_font: " ERRMSG2, lineno ));
- error = BDF_Err_Corrupted_Font_Header;
- goto Exit;
- }
- else
- {
- /* Error happened when parsing glyphs. */
- FT_ERROR(( "bdf_load_font: " ERRMSG3, lineno ));
- error = BDF_Err_Corrupted_Font_Glyphs;
- goto Exit;
- }
+ /* Error happened while parsing header. */
+ FT_ERROR(( "bdf_load_font: " ERRMSG2, lineno ));
+ error = BDF_Err_Corrupted_Font_Header;
+ goto Exit;
+ }
+ else
+ {
+ /* Error happened when parsing glyphs. */
+ FT_ERROR(( "bdf_load_font: " ERRMSG3, lineno ));
+ error = BDF_Err_Corrupted_Font_Glyphs;
+ goto Exit;
}
}
diff --git a/3party/freetype/src/bzip2/ftbzip2.c b/3party/freetype/src/bzip2/ftbzip2.c
index e443dc85e8..d60ee3ea0f 100644
--- a/3party/freetype/src/bzip2/ftbzip2.c
+++ b/3party/freetype/src/bzip2/ftbzip2.c
@@ -8,7 +8,7 @@
/* parse compressed PCF fonts, as found with many X11 server */
/* distributions. */
/* */
-/* Copyright 2010 by */
+/* Copyright 2010, 2012 by */
/* Joel Klinghed. */
/* */
/* Based on src/gzip/ftgzip.c, Copyright 2002 - 2010 by */
@@ -35,6 +35,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX Bzip2_Err_
#define FT_ERR_BASE FT_Mod_Err_Bzip2
diff --git a/3party/freetype/src/cache/ftcbasic.c b/3party/freetype/src/cache/ftcbasic.c
index 09d793ecf2..d4fc353c42 100644
--- a/3party/freetype/src/cache/ftcbasic.c
+++ b/3party/freetype/src/cache/ftcbasic.c
@@ -467,7 +467,7 @@
}
-
+
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
/* yet another backwards-legacy structure */
@@ -608,7 +608,7 @@
const FTC_SFamilyClassRec ftc_basic_sbit_family_class =
{
{
- sizeof( FTC_BasicFamilyRec ),
+ sizeof ( FTC_BasicFamilyRec ),
ftc_basic_family_compare,
ftc_basic_family_init,
0, /* FTC_MruNode_ResetFunc */
diff --git a/3party/freetype/src/cache/ftccmap.c b/3party/freetype/src/cache/ftccmap.c
index b7bd2919d9..226c0015cf 100644
--- a/3party/freetype/src/cache/ftccmap.c
+++ b/3party/freetype/src/cache/ftccmap.c
@@ -4,8 +4,7 @@
/* */
/* FreeType CharMap cache (body) */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
-/* 2010, 2011 by */
+/* Copyright 2000-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -121,7 +120,7 @@
/* if (indices[n] == FTC_CMAP_UNKNOWN), we assume that the corresponding */
/* glyph indices haven't been queried through FT_Get_Glyph_Index() yet */
-#define FTC_CMAP_UNKNOWN ( (FT_UInt16)-1 )
+#define FTC_CMAP_UNKNOWN (FT_UInt16)~0
/*************************************************************************/
@@ -320,7 +319,7 @@
/*
* If cmap_index is greater than the maximum number of cachable
- * charmaps, we assume the request is from a legacy rogue client
+ * charmaps, we assume the request is from a legacy rogue client
* using old internal header. See include/config/ftoption.h.
*/
if ( cmap_index > FT_MAX_CHARMAP_CACHEABLE && !no_cmap_change )
diff --git a/3party/freetype/src/cache/ftcerror.h b/3party/freetype/src/cache/ftcerror.h
index 5998d42daf..0e055709bb 100644
--- a/3party/freetype/src/cache/ftcerror.h
+++ b/3party/freetype/src/cache/ftcerror.h
@@ -4,7 +4,7 @@
/* */
/* Caching sub-system error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX FTC_Err_
#define FT_ERR_BASE FT_Mod_Err_Cache
diff --git a/3party/freetype/src/cache/ftcmanag.c b/3party/freetype/src/cache/ftcmanag.c
index 548ebe951f..76a510d049 100644
--- a/3party/freetype/src/cache/ftcmanag.c
+++ b/3party/freetype/src/cache/ftcmanag.c
@@ -28,7 +28,7 @@
#ifdef FT_CONFIG_OPTION_PIC
#error "cache system does not support PIC yet"
-#endif
+#endif
#undef FT_COMPONENT
diff --git a/3party/freetype/src/cache/ftstrokedcache.c b/3party/freetype/src/cache/ftstrokedcache.c
index 2be6da1740..17d0ca7397 100644
--- a/3party/freetype/src/cache/ftstrokedcache.c
+++ b/3party/freetype/src/cache/ftstrokedcache.c
@@ -272,7 +272,7 @@ ftc_stroked_gnode_compare_faceid( FTC_Node ftcgnode,
*/
if ( (FT_ULong)type->width >= 0x10000L )
{
- FTC_OldImageDesc desc = (FTC_OldImageDesc)type;
+ FTC_OldImageDesc desc = (FTC_OldImageDescRec_)type;
query.attrs.scaler.face_id = desc->font.face_id;
diff --git a/3party/freetype/src/cff/cffdrivr.c b/3party/freetype/src/cff/cffdrivr.c
index bf2d016c05..b5fda95d7e 100644
--- a/3party/freetype/src/cff/cffdrivr.c
+++ b/3party/freetype/src/cff/cffdrivr.c
@@ -4,7 +4,7 @@
/* */
/* OpenType font driver implementation (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -125,7 +125,7 @@
/*************************************************************************/
/* */
/* <Function> */
- /* Load_Glyph */
+ /* cff_glyph_load */
/* */
/* <Description> */
/* A driver method used to load a glyph within a given glyph slot. */
@@ -149,10 +149,10 @@
/* FreeType error code. 0 means success. */
/* */
FT_CALLBACK_DEF( FT_Error )
- Load_Glyph( FT_GlyphSlot cffslot, /* CFF_GlyphSlot */
- FT_Size cffsize, /* CFF_Size */
- FT_UInt glyph_index,
- FT_Int32 load_flags )
+ cff_glyph_load( FT_GlyphSlot cffslot, /* CFF_GlyphSlot */
+ FT_Size cffsize, /* CFF_Size */
+ FT_UInt glyph_index,
+ FT_Int32 load_flags )
{
FT_Error error;
CFF_GlyphSlot slot = (CFF_GlyphSlot)cffslot;
@@ -203,7 +203,7 @@
for ( nn = 0; nn < count; nn++ )
{
- error = Load_Glyph( slot, face->size, start + nn, flags );
+ error = cff_glyph_load( slot, face->size, start + nn, flags );
if ( error )
break;
@@ -239,7 +239,7 @@
" cannot get glyph name from CFF & CEF fonts\n"
" "
" without the `PSNames' module\n" ));
- error = CFF_Err_Unknown_File_Format;
+ error = CFF_Err_Missing_Module;
goto Exit;
}
@@ -412,8 +412,8 @@
cmap_info->language = 0;
cmap_info->format = 0;
- if ( cmap->clazz != &FT_CFF_CMAP_ENCODING_CLASS_REC_GET &&
- cmap->clazz != &FT_CFF_CMAP_UNICODE_CLASS_REC_GET )
+ if ( cmap->clazz != &CFF_CMAP_ENCODING_CLASS_REC_GET &&
+ cmap->clazz != &CFF_CMAP_UNICODE_CLASS_REC_GET )
{
FT_Module sfnt = FT_Get_Module( library, "sfnt" );
FT_Service_TTCMaps service =
@@ -466,7 +466,7 @@
dict->cid_registry );
*registry = cff->registry;
}
-
+
if ( ordering )
{
if ( cff->ordering == NULL )
@@ -489,7 +489,7 @@
*supplement = (FT_Int)dict->cid_supplement;
}
}
-
+
Fail:
return error;
}
@@ -579,19 +579,19 @@
#ifndef FT_CONFIG_OPTION_NO_GLYPH_NAMES
FT_DEFINE_SERVICEDESCREC6(cff_services,
FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_CFF,
- FT_SERVICE_ID_POSTSCRIPT_INFO, &FT_CFF_SERVICE_PS_INFO_GET,
- FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_CFF_SERVICE_PS_NAME_GET,
- FT_SERVICE_ID_GLYPH_DICT, &FT_CFF_SERVICE_GLYPH_DICT_GET,
- FT_SERVICE_ID_TT_CMAP, &FT_CFF_SERVICE_GET_CMAP_INFO_GET,
- FT_SERVICE_ID_CID, &FT_CFF_SERVICE_CID_INFO_GET
+ FT_SERVICE_ID_POSTSCRIPT_INFO, &CFF_SERVICE_PS_INFO_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &CFF_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_GLYPH_DICT, &CFF_SERVICE_GLYPH_DICT_GET,
+ FT_SERVICE_ID_TT_CMAP, &CFF_SERVICE_GET_CMAP_INFO_GET,
+ FT_SERVICE_ID_CID, &CFF_SERVICE_CID_INFO_GET
)
#else
FT_DEFINE_SERVICEDESCREC5(cff_services,
FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_CFF,
- FT_SERVICE_ID_POSTSCRIPT_INFO, &FT_CFF_SERVICE_PS_INFO_GET,
- FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_CFF_SERVICE_PS_NAME_GET,
- FT_SERVICE_ID_TT_CMAP, &FT_CFF_SERVICE_GET_CMAP_INFO_GET,
- FT_SERVICE_ID_CID, &FT_CFF_SERVICE_CID_INFO_GET
+ FT_SERVICE_ID_POSTSCRIPT_INFO, &CFF_SERVICE_PS_INFO_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &CFF_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_TT_CMAP, &CFF_SERVICE_GET_CMAP_INFO_GET,
+ FT_SERVICE_ID_CID, &CFF_SERVICE_CID_INFO_GET
)
#endif
@@ -599,19 +599,35 @@
cff_get_interface( FT_Module driver, /* CFF_Driver */
const char* module_interface )
{
+ FT_Library library;
FT_Module sfnt;
FT_Module_Interface result;
- result = ft_service_list_lookup( FT_CFF_SERVICES_GET, module_interface );
+ /* CFF_SERVICES_GET derefers `library' in PIC mode */
+#ifdef FT_CONFIG_OPTION_PIC
+ if ( !driver )
+ return NULL;
+ library = driver->library;
+ if ( !library )
+ return NULL;
+#endif
+
+ result = ft_service_list_lookup( CFF_SERVICES_GET, module_interface );
if ( result != NULL )
- return result;
+ return result;
+ /* `driver' is not yet evaluated in non-PIC mode */
+#ifndef FT_CONFIG_OPTION_PIC
if ( !driver )
return NULL;
+ library = driver->library;
+ if ( !library )
+ return NULL;
+#endif
/* we pass our request to the `sfnt' module */
- sfnt = FT_Get_Module( driver->library, "sfnt" );
+ sfnt = FT_Get_Module( library, "sfnt" );
return sfnt ? sfnt->clazz->get_interface( sfnt, module_interface ) : 0;
}
@@ -625,12 +641,13 @@
#define CFF_SIZE_SELECT 0
#endif
- FT_DEFINE_DRIVER(cff_driver_class,
+ FT_DEFINE_DRIVER( cff_driver_class,
+
FT_MODULE_FONT_DRIVER |
FT_MODULE_DRIVER_SCALABLE |
FT_MODULE_DRIVER_HAS_HINTER,
- sizeof( CFF_DriverRec ),
+ sizeof ( CFF_DriverRec ),
"cff",
0x10000L,
0x20000L,
@@ -642,9 +659,9 @@
cff_get_interface,
/* now the specific driver fields */
- sizeof( TT_FaceRec ),
- sizeof( CFF_SizeRec ),
- sizeof( CFF_GlyphSlotRec ),
+ sizeof ( TT_FaceRec ),
+ sizeof ( CFF_SizeRec ),
+ sizeof ( CFF_GlyphSlotRec ),
cff_face_init,
cff_face_done,
@@ -653,14 +670,14 @@
cff_slot_init,
cff_slot_done,
- ft_stub_set_char_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ ft_stub_set_char_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
ft_stub_set_pixel_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
- Load_Glyph,
+ cff_glyph_load,
cff_get_kerning,
- 0, /* FT_Face_AttachFunc */
- cff_get_advances, /* FT_Face_GetAdvancesFunc */
+ 0, /* FT_Face_AttachFunc */
+ cff_get_advances,
cff_size_request,
diff --git a/3party/freetype/src/cff/cfferrs.h b/3party/freetype/src/cff/cfferrs.h
index 1b2a5c95c8..801d73ec6b 100644
--- a/3party/freetype/src/cff/cfferrs.h
+++ b/3party/freetype/src/cff/cfferrs.h
@@ -4,7 +4,7 @@
/* */
/* CFF error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX CFF_Err_
#define FT_ERR_BASE FT_Mod_Err_CFF
diff --git a/3party/freetype/src/cff/cffgload.c b/3party/freetype/src/cff/cffgload.c
index cb06bdf10a..84847fda57 100644
--- a/3party/freetype/src/cff/cffgload.c
+++ b/3party/freetype/src/cff/cffgload.c
@@ -4,7 +4,7 @@
/* */
/* OpenType Glyph Loader (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -1513,11 +1513,9 @@
goto Stack_Underflow;
/* if num_args isn't of the form 4n or 4n+1, */
- /* we reduce it to 4n+1 */
+ /* we enforce it by clearing the second bit */
- nargs = num_args - num_args % 4;
- if ( num_args - nargs > 0 )
- nargs += 1;
+ nargs = num_args & ~2;
if ( cff_builder_start_point( builder, x, y ) )
goto Fail;
@@ -1560,11 +1558,9 @@
goto Stack_Underflow;
/* if num_args isn't of the form 4n or 4n+1, */
- /* we reduce it to 4n+1 */
+ /* we enforce it by clearing the second bit */
- nargs = num_args - num_args % 4;
- if ( num_args - nargs > 0 )
- nargs += 1;
+ nargs = num_args & ~2;
if ( cff_builder_start_point( builder, x, y ) )
goto Fail;
@@ -1612,11 +1608,9 @@
goto Stack_Underflow;
/* if num_args isn't of the form 8n, 8n+1, 8n+4, or 8n+5, */
- /* we reduce it to the largest one which fits */
+ /* we enforce it by clearing the second bit */
- nargs = num_args - num_args % 4;
- if ( num_args - nargs > 0 )
- nargs += 1;
+ nargs = num_args & ~2;
args -= nargs;
if ( check_points( builder, ( nargs / 4 ) * 3 ) )
@@ -1963,6 +1957,7 @@
/* Save glyph width so that the subglyphs don't overwrite it. */
FT_Pos glyph_width = decoder->glyph_width;
+
error = cff_operator_seac( decoder,
0L, args[-4], args[-3],
(FT_Int)( args[-2] >> 16 ),
@@ -2705,7 +2700,7 @@
FT_Byte fd_index = cff_fd_select_get( &cff->fd_select,
glyph_index );
- if ( fd_index >= cff->num_subfonts )
+ if ( fd_index >= cff->num_subfonts )
fd_index = (FT_Byte)( cff->num_subfonts - 1 );
top_upm = cff->top_font.font_dict.units_per_em;
@@ -2961,7 +2956,7 @@
if ( has_vertical_info )
metrics->vertBearingX = metrics->horiBearingX -
metrics->horiAdvance / 2;
- else
+ else
{
if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
ft_synthesize_vertical_metrics( metrics,
diff --git a/3party/freetype/src/cff/cffload.c b/3party/freetype/src/cff/cffload.c
index 8bbf4743e0..d5433c80bc 100644
--- a/3party/freetype/src/cff/cffload.c
+++ b/3party/freetype/src/cff/cffload.c
@@ -4,7 +4,7 @@
/* */
/* OpenType and CFF data/program tables loader (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -1439,6 +1439,7 @@
FT_ULong base_offset;
CFF_FontRecDict dict;
CFF_IndexRec string_index;
+ FT_Int subfont_index;
FT_ZERO( font );
@@ -1458,7 +1459,7 @@
font->header_size < 4 ||
font->absolute_offsize > 4 )
{
- FT_TRACE2(( "[not a CFF font header]\n" ));
+ FT_TRACE2(( " not a CFF font header\n" ));
error = CFF_Err_Unknown_File_Format;
goto Exit;
}
@@ -1483,13 +1484,35 @@
font->num_strings = string_index.count;
- /* well, we don't really forget the `disabled' fonts... */
- font->num_faces = font->name_index.count;
- if ( face_index >= (FT_Int)font->num_faces )
+ if ( pure_cff )
{
- FT_ERROR(( "cff_font_load: incorrect face index = %d\n",
- face_index ));
- error = CFF_Err_Invalid_Argument;
+ /* well, we don't really forget the `disabled' fonts... */
+ subfont_index = face_index;
+
+ if ( subfont_index >= (FT_Int)font->name_index.count )
+ {
+ FT_ERROR(( "cff_font_load:"
+ " invalid subfont index for pure CFF font (%d)\n",
+ subfont_index ));
+ error = CFF_Err_Invalid_Argument;
+ goto Exit;
+ }
+
+ font->num_faces = font->name_index.count;
+ }
+ else
+ {
+ subfont_index = 0;
+
+ if ( font->name_index.count > 1 )
+ {
+ FT_ERROR(( "cff_font_load:"
+ " invalid CFF font with multiple subfonts\n"
+ " "
+ " in SFNT wrapper\n" ));
+ error = CFF_Err_Invalid_File_Format;
+ goto Exit;
+ }
}
/* in case of a font format check, simply exit now */
@@ -1500,7 +1523,7 @@
FT_TRACE4(( "parsing top-level\n" ));
error = cff_subfont_load( &font->top_font,
&font->font_dict_index,
- face_index,
+ subfont_index,
stream,
base_offset,
library );
@@ -1576,7 +1599,7 @@
if ( dict->charstrings_offset == 0 )
{
FT_ERROR(( "cff_font_load: no charstrings offset\n" ));
- error = CFF_Err_Unknown_File_Format;
+ error = CFF_Err_Invalid_File_Format;
goto Exit;
}
@@ -1615,7 +1638,7 @@
/* get the font name (/CIDFontName for CID-keyed fonts, */
/* /FontName otherwise) */
- font->font_name = cff_index_get_name( font, face_index );
+ font->font_name = cff_index_get_name( font, subfont_index );
Exit:
cff_index_done( &string_index );
diff --git a/3party/freetype/src/cff/cffload.h b/3party/freetype/src/cff/cffload.h
index c755de9a20..804961964b 100644
--- a/3party/freetype/src/cff/cffload.h
+++ b/3party/freetype/src/cff/cffload.h
@@ -60,7 +60,7 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Error )
- cff_font_load( FT_Library library,
+ cff_font_load( FT_Library library,
FT_Stream stream,
FT_Int face_index,
CFF_Font font,
diff --git a/3party/freetype/src/cff/cffobjs.c b/3party/freetype/src/cff/cffobjs.c
index 15707a2a3c..b4dddb747e 100644
--- a/3party/freetype/src/cff/cffobjs.c
+++ b/3party/freetype/src/cff/cffobjs.c
@@ -4,7 +4,7 @@
/* */
/* OpenType objects manager (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -403,7 +403,7 @@
FT_Int32 idx = 0;
FT_Int32 length = strlen( name ) + 1;
FT_Bool continue_search = 1;
-
+
while ( continue_search )
{
@@ -494,13 +494,19 @@
sfnt = (SFNT_Service)FT_Get_Module_Interface(
library, "sfnt" );
if ( !sfnt )
- goto Bad_Format;
+ {
+ FT_ERROR(( "cff_face_init: cannot access `sfnt' module\n" ));
+ error = CFF_Err_Missing_Module;
+ goto Exit;
+ }
FT_FACE_FIND_GLOBAL_SERVICE( face, psnames, POSTSCRIPT_CMAPS );
pshinter = (PSHinter_Service)FT_Get_Module_Interface(
library, "pshinter" );
+ FT_TRACE2(( "CFF driver\n" ));
+
/* create input stream from resource */
if ( FT_STREAM_SEEK( 0 ) )
goto Exit;
@@ -511,22 +517,15 @@
{
if ( face->format_tag != TTAG_OTTO ) /* `OTTO'; OpenType/CFF font */
{
- FT_TRACE2(( "[not a valid OpenType/CFF font]\n" ));
- goto Bad_Format;
+ FT_TRACE2(( " not an OpenType/CFF font\n" ));
+ error = CFF_Err_Unknown_File_Format;
+ goto Exit;
}
/* if we are performing a simple font format check, exit immediately */
if ( face_index < 0 )
return CFF_Err_Ok;
- /* UNDOCUMENTED! A CFF in an SFNT can have only a single font. */
- if ( face_index > 0 )
- {
- FT_ERROR(( "cff_face_init: invalid face index\n" ));
- error = CFF_Err_Invalid_Argument;
- goto Exit;
- }
-
sfnt_format = 1;
/* now, the font can be either an OpenType/CFF font, or an SVG CEF */
@@ -537,7 +536,8 @@
pure_cff = 0;
/* load font directory */
- error = sfnt->load_face( stream, face, 0, num_params, params );
+ error = sfnt->load_face( stream, face, face_index,
+ num_params, params );
if ( error )
goto Exit;
}
@@ -547,10 +547,6 @@
error = sfnt->load_cmap( face, stream );
if ( error )
goto Exit;
-
- /* XXX: we don't load the GPOS table, as OpenType Layout */
- /* support will be added later to a layout library on top of */
- /* FreeType 2 */
}
/* now load the CFF part of the file */
@@ -604,7 +600,8 @@
" cannot open CFF & CEF fonts\n"
" "
" without the `PSNames' module\n" ));
- goto Bad_Format;
+ error = CFF_Err_Missing_Module;
+ goto Exit;
}
#ifdef FT_DEBUG_LEVEL_TRACE
@@ -772,7 +769,7 @@
char* family_name = NULL;
- remove_subset_prefix( cffface->family_name );
+ remove_subset_prefix( cffface->family_name );
if ( dict->family_name )
{
@@ -819,7 +816,7 @@
style_name = cff_strcpy( memory, fullp );
/* remove the style part from the family name (if present) */
- remove_style( cffface->family_name, style_name );
+ remove_style( cffface->family_name, style_name );
}
break;
}
@@ -847,22 +844,22 @@
/* */
/* Compute face flags. */
/* */
- flags = (FT_UInt32)( FT_FACE_FLAG_SCALABLE | /* scalable outlines */
- FT_FACE_FLAG_HORIZONTAL | /* horizontal data */
- FT_FACE_FLAG_HINTER ); /* has native hinter */
+ flags = FT_FACE_FLAG_SCALABLE | /* scalable outlines */
+ FT_FACE_FLAG_HORIZONTAL | /* horizontal data */
+ FT_FACE_FLAG_HINTER; /* has native hinter */
if ( sfnt_format )
- flags |= (FT_UInt32)FT_FACE_FLAG_SFNT;
+ flags |= FT_FACE_FLAG_SFNT;
/* fixed width font? */
if ( dict->is_fixed_pitch )
- flags |= (FT_UInt32)FT_FACE_FLAG_FIXED_WIDTH;
+ flags |= FT_FACE_FLAG_FIXED_WIDTH;
/* XXX: WE DO NOT SUPPORT KERNING METRICS IN THE GPOS TABLE FOR NOW */
#if 0
/* kerning available? */
if ( face->kern_pairs )
- flags |= (FT_UInt32)FT_FACE_FLAG_KERNING;
+ flags |= FT_FACE_FLAG_KERNING;
#endif
cffface->face_flags = flags;
@@ -960,7 +957,7 @@
nn = (FT_UInt)cffface->num_charmaps;
- error = FT_CMap_New( &FT_CFF_CMAP_UNICODE_CLASS_REC_GET, NULL,
+ error = FT_CMap_New( &CFF_CMAP_UNICODE_CLASS_REC_GET, NULL,
&cmaprec, NULL );
if ( error && FT_Err_No_Unicode_Glyph_Name != error )
goto Exit;
@@ -992,19 +989,19 @@
{
cmaprec.encoding_id = TT_ADOBE_ID_STANDARD;
cmaprec.encoding = FT_ENCODING_ADOBE_STANDARD;
- clazz = &FT_CFF_CMAP_ENCODING_CLASS_REC_GET;
+ clazz = &CFF_CMAP_ENCODING_CLASS_REC_GET;
}
else if ( encoding->offset == 1 )
{
cmaprec.encoding_id = TT_ADOBE_ID_EXPERT;
cmaprec.encoding = FT_ENCODING_ADOBE_EXPERT;
- clazz = &FT_CFF_CMAP_ENCODING_CLASS_REC_GET;
+ clazz = &CFF_CMAP_ENCODING_CLASS_REC_GET;
}
else
{
cmaprec.encoding_id = TT_ADOBE_ID_CUSTOM;
cmaprec.encoding = FT_ENCODING_ADOBE_CUSTOM;
- clazz = &FT_CFF_CMAP_ENCODING_CLASS_REC_GET;
+ clazz = &CFF_CMAP_ENCODING_CLASS_REC_GET;
}
error = FT_CMap_New( clazz, NULL, &cmaprec, NULL );
@@ -1014,10 +1011,6 @@
Exit:
return error;
-
- Bad_Format:
- error = CFF_Err_Unknown_File_Format;
- goto Exit;
}
diff --git a/3party/freetype/src/cff/cffparse.c b/3party/freetype/src/cff/cffparse.c
index 61fa87c809..5e58c8bbba 100644
--- a/3party/freetype/src/cff/cffparse.c
+++ b/3party/freetype/src/cff/cffparse.c
@@ -4,7 +4,7 @@
/* */
/* CFF token stream parser (body) */
/* */
-/* Copyright 1996-2004, 2007-2011 by */
+/* Copyright 1996-2004, 2007-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -105,6 +105,7 @@
Bad:
val = 0;
+ FT_TRACE4(( "!!!END OF DATA:!!!" ));
goto Exit;
}
@@ -136,7 +137,7 @@
FT_UInt phase;
FT_Long result, number, exponent;
- FT_Int sign = 0, exponent_sign = 0;
+ FT_Int sign = 0, exponent_sign = 0, have_overflow = 0;
FT_Long exponent_add, integer_length, fraction_length;
@@ -165,7 +166,7 @@
/* Make sure we don't read past the end. */
if ( p >= limit )
- goto Exit;
+ goto Bad;
}
/* Get the nibble. */
@@ -202,7 +203,7 @@
/* Make sure we don't read past the end. */
if ( p >= limit )
- goto Exit;
+ goto Bad;
}
/* Get the nibble. */
@@ -241,7 +242,7 @@
/* Make sure we don't read past the end. */
if ( p >= limit )
- goto Exit;
+ goto Bad;
}
/* Get the nibble. */
@@ -250,17 +251,28 @@
if ( nib >= 10 )
break;
- exponent = exponent * 10 + nib;
-
/* Arbitrarily limit exponent. */
if ( exponent > 1000 )
- goto Exit;
+ have_overflow = 1;
+ else
+ exponent = exponent * 10 + nib;
}
if ( exponent_sign )
exponent = -exponent;
}
+ if ( !number )
+ goto Exit;
+
+ if ( have_overflow )
+ {
+ if ( exponent_sign )
+ goto Underflow;
+ else
+ goto Overflow;
+ }
+
/* We don't check `power_ten' and `exponent_add'. */
exponent += power_ten + exponent_add;
@@ -286,15 +298,20 @@
/* Make `scaling' as small as possible. */
new_fraction_length = FT_MIN( exponent, 5 );
- exponent -= new_fraction_length;
shift = new_fraction_length - fraction_length;
- number *= power_tens[shift];
- if ( number > 0x7FFFL )
+ if ( shift > 0 )
{
- number /= 10;
- exponent += 1;
+ exponent -= new_fraction_length;
+ number *= power_tens[shift];
+ if ( number > 0x7FFFL )
+ {
+ number /= 10;
+ exponent += 1;
+ }
}
+ else
+ exponent -= fraction_length;
}
else
exponent -= fraction_length;
@@ -322,9 +339,10 @@
integer_length += exponent;
fraction_length -= exponent;
- /* Check for overflow and underflow. */
- if ( FT_ABS( integer_length ) > 5 )
- goto Exit;
+ if ( integer_length > 5 )
+ goto Overflow;
+ if ( integer_length < -5 )
+ goto Underflow;
/* Remove non-significant digits. */
if ( integer_length < 0 )
@@ -353,17 +371,32 @@
number *= power_tens[-fraction_length];
if ( number > 0x7FFFL )
- goto Exit;
+ goto Overflow;
result = number << 16;
}
}
+ Exit:
if ( sign )
result = -result;
- Exit:
return result;
+
+ Overflow:
+ result = 0x7FFFFFFFL;
+ FT_TRACE4(( "!!!OVERFLOW:!!!" ));
+ goto Exit;
+
+ Underflow:
+ result = 0;
+ FT_TRACE4(( "!!!UNDERFLOW:!!!" ));
+ goto Exit;
+
+ Bad:
+ result = 0;
+ FT_TRACE4(( "!!!END OF DATA:!!!" ));
+ goto Exit;
}
@@ -378,10 +411,44 @@
/* read a floating point number, either integer or real */
static FT_Fixed
+ do_fixed( FT_Byte** d,
+ FT_Long scaling )
+ {
+ if ( **d == 30 )
+ return cff_parse_real( d[0], d[1], scaling, NULL );
+ else
+ {
+ FT_Long val = cff_parse_integer( d[0], d[1] );
+
+
+ if ( scaling )
+ val *= power_tens[scaling];
+
+ if ( val > 0x7FFF )
+ {
+ val = 0x7FFFFFFFL;
+ goto Overflow;
+ }
+ else if ( val < -0x7FFF )
+ {
+ val = -0x7FFFFFFFL;
+ goto Overflow;
+ }
+
+ return val << 16;
+
+ Overflow:
+ FT_TRACE4(( "!!!OVERFLOW:!!!" ));
+ return val;
+ }
+ }
+
+
+ /* read a floating point number, either integer or real */
+ static FT_Fixed
cff_parse_fixed( FT_Byte** d )
{
- return **d == 30 ? cff_parse_real( d[0], d[1], 0, NULL )
- : cff_parse_integer( d[0], d[1] ) << 16;
+ return do_fixed( d, 0 );
}
@@ -391,9 +458,7 @@
cff_parse_fixed_scaled( FT_Byte** d,
FT_Long scaling )
{
- return **d == 30 ? cff_parse_real( d[0], d[1], scaling, NULL )
- : ( cff_parse_integer( d[0], d[1] ) *
- power_tens[scaling] ) << 16;
+ return do_fixed( d, scaling );
}
@@ -730,7 +795,7 @@
FT_Create_Class_cff_field_handlers( FT_Library library,
CFF_Field_Handler** output_class )
{
- CFF_Field_Handler* clazz;
+ CFF_Field_Handler* clazz = NULL;
FT_Error error;
FT_Memory memory = library->memory;
@@ -944,7 +1009,7 @@
}
code = code | parser->object_code;
- for ( field = FT_CFF_FIELD_HANDLERS_GET; field->kind; field++ )
+ for ( field = CFF_FIELD_HANDLERS_GET; field->kind; field++ )
{
if ( field->code == (FT_Int)code )
{
diff --git a/3party/freetype/src/cff/cffpic.c b/3party/freetype/src/cff/cffpic.c
index 5d01bd45e1..fe4fa496f7 100644
--- a/3party/freetype/src/cff/cffpic.c
+++ b/3party/freetype/src/cff/cffpic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for cff module. */
/* */
-/* Copyright 2009, 2010 by */
+/* Copyright 2009, 2010, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,40 +19,78 @@
#include <ft2build.h>
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
+#include "cffcmap.h"
#include "cffpic.h"
+#include "cfferrs.h"
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from cffdrivr.c */
- FT_Error FT_Create_Class_cff_services( FT_Library, FT_ServiceDescRec**);
- void FT_Destroy_Class_cff_services( FT_Library, FT_ServiceDescRec*);
- void FT_Init_Class_cff_service_ps_info( FT_Library, FT_Service_PsInfoRec*);
- void FT_Init_Class_cff_service_glyph_dict( FT_Library, FT_Service_GlyphDictRec*);
- void FT_Init_Class_cff_service_ps_name( FT_Library, FT_Service_PsFontNameRec*);
- void FT_Init_Class_cff_service_get_cmap_info( FT_Library, FT_Service_TTCMapsRec*);
- void FT_Init_Class_cff_service_cid_info( FT_Library, FT_Service_CIDRec*);
+ FT_Error
+ FT_Create_Class_cff_services(
+ FT_Library library,
+ FT_ServiceDescRec** output_class );
+
+ void
+ FT_Destroy_Class_cff_services(
+ FT_Library library,
+ FT_ServiceDescRec* clazz );
+
+ void
+ FT_Init_Class_cff_service_ps_info(
+ FT_Library library,
+ FT_Service_PsInfoRec* clazz );
+
+ void
+ FT_Init_Class_cff_service_glyph_dict(
+ FT_Library library,
+ FT_Service_GlyphDictRec* clazz );
+
+ void
+ FT_Init_Class_cff_service_ps_name(
+ FT_Library library,
+ FT_Service_PsFontNameRec* clazz );
+
+ void
+ FT_Init_Class_cff_service_get_cmap_info(
+ FT_Library library,
+ FT_Service_TTCMapsRec* clazz );
+
+ void
+ FT_Init_Class_cff_service_cid_info(
+ FT_Library library,
+ FT_Service_CIDRec* clazz );
/* forward declaration of PIC init functions from cffparse.c */
- FT_Error FT_Create_Class_cff_field_handlers( FT_Library, CFF_Field_Handler**);
- void FT_Destroy_Class_cff_field_handlers( FT_Library, CFF_Field_Handler*);
+ FT_Error
+ FT_Create_Class_cff_field_handlers(
+ FT_Library library,
+ CFF_Field_Handler** output_class );
- /* forward declaration of PIC init functions from cffcmap.c */
- void FT_Init_Class_cff_cmap_encoding_class_rec( FT_Library, FT_CMap_ClassRec*);
- void FT_Init_Class_cff_cmap_unicode_class_rec( FT_Library, FT_CMap_ClassRec*);
+ void
+ FT_Destroy_Class_cff_field_handlers(
+ FT_Library library,
+ CFF_Field_Handler* clazz );
void
- cff_driver_class_pic_free( FT_Library library )
+ cff_driver_class_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->cff )
{
- CffModulePIC* container = (CffModulePIC*)pic_container->cff;
- if(container->cff_services)
- FT_Destroy_Class_cff_services(library, container->cff_services);
+ CffModulePIC* container = ( CffModulePIC* )pic_container->cff;
+
+
+ if ( container->cff_services )
+ FT_Destroy_Class_cff_services( library,
+ container->cff_services );
container->cff_services = NULL;
- if(container->cff_field_handlers)
- FT_Destroy_Class_cff_field_handlers(library, container->cff_field_handlers);
+ if ( container->cff_field_handlers )
+ FT_Destroy_Class_cff_field_handlers(
+ library, container->cff_field_handlers );
container->cff_field_handlers = NULL;
FT_FREE( container );
pic_container->cff = NULL;
@@ -65,7 +103,7 @@
{
FT_PIC_Container* pic_container = &library->pic_container;
FT_Error error = CFF_Err_Ok;
- CffModulePIC* container;
+ CffModulePIC* container = NULL;
FT_Memory memory = library->memory;
@@ -76,22 +114,31 @@
pic_container->cff = container;
/* initialize pointer table - this is how the module usually expects this data */
- error = FT_Create_Class_cff_services(library, &container->cff_services);
- if(error)
+ error = FT_Create_Class_cff_services( library,
+ &container->cff_services );
+ if ( error )
goto Exit;
- error = FT_Create_Class_cff_field_handlers(library, &container->cff_field_handlers);
- if(error)
+ error = FT_Create_Class_cff_field_handlers(
+ library, &container->cff_field_handlers );
+ if ( error )
goto Exit;
- FT_Init_Class_cff_service_ps_info(library, &container->cff_service_ps_info);
- FT_Init_Class_cff_service_glyph_dict(library, &container->cff_service_glyph_dict);
- FT_Init_Class_cff_service_ps_name(library, &container->cff_service_ps_name);
- FT_Init_Class_cff_service_get_cmap_info(library, &container->cff_service_get_cmap_info);
- FT_Init_Class_cff_service_cid_info(library, &container->cff_service_cid_info);
- FT_Init_Class_cff_cmap_encoding_class_rec(library, &container->cff_cmap_encoding_class_rec);
- FT_Init_Class_cff_cmap_unicode_class_rec(library, &container->cff_cmap_unicode_class_rec);
+ FT_Init_Class_cff_service_ps_info(
+ library, &container->cff_service_ps_info );
+ FT_Init_Class_cff_service_glyph_dict(
+ library, &container->cff_service_glyph_dict );
+ FT_Init_Class_cff_service_ps_name(
+ library, &container->cff_service_ps_name );
+ FT_Init_Class_cff_service_get_cmap_info(
+ library, &container->cff_service_get_cmap_info );
+ FT_Init_Class_cff_service_cid_info(
+ library, &container->cff_service_cid_info );
+ FT_Init_Class_cff_cmap_encoding_class_rec(
+ library, &container->cff_cmap_encoding_class_rec );
+ FT_Init_Class_cff_cmap_unicode_class_rec(
+ library, &container->cff_cmap_unicode_class_rec );
Exit:
- if(error)
- cff_driver_class_pic_free(library);
+ if ( error )
+ cff_driver_class_pic_free( library );
return error;
}
diff --git a/3party/freetype/src/cff/cffpic.h b/3party/freetype/src/cff/cffpic.h
index e29d068134..b27f093db5 100644
--- a/3party/freetype/src/cff/cffpic.h
+++ b/3party/freetype/src/cff/cffpic.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for cff module. */
/* */
-/* Copyright 2009 by */
+/* Copyright 2009, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,21 +19,23 @@
#ifndef __CFFPIC_H__
#define __CFFPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_CFF_SERVICE_PS_INFO_GET cff_service_ps_info
-#define FT_CFF_SERVICE_GLYPH_DICT_GET cff_service_glyph_dict
-#define FT_CFF_SERVICE_PS_NAME_GET cff_service_ps_name
-#define FT_CFF_SERVICE_GET_CMAP_INFO_GET cff_service_get_cmap_info
-#define FT_CFF_SERVICE_CID_INFO_GET cff_service_cid_info
-#define FT_CFF_SERVICES_GET cff_services
-#define FT_CFF_CMAP_ENCODING_CLASS_REC_GET cff_cmap_encoding_class_rec
-#define FT_CFF_CMAP_UNICODE_CLASS_REC_GET cff_cmap_unicode_class_rec
-#define FT_CFF_FIELD_HANDLERS_GET cff_field_handlers
+
+#define CFF_SERVICE_PS_INFO_GET cff_service_ps_info
+#define CFF_SERVICE_GLYPH_DICT_GET cff_service_glyph_dict
+#define CFF_SERVICE_PS_NAME_GET cff_service_ps_name
+#define CFF_SERVICE_GET_CMAP_INFO_GET cff_service_get_cmap_info
+#define CFF_SERVICE_CID_INFO_GET cff_service_cid_info
+#define CFF_SERVICES_GET cff_services
+#define CFF_CMAP_ENCODING_CLASS_REC_GET cff_cmap_encoding_class_rec
+#define CFF_CMAP_UNICODE_CLASS_REC_GET cff_cmap_unicode_class_rec
+#define CFF_FIELD_HANDLERS_GET cff_field_handlers
#else /* FT_CONFIG_OPTION_PIC */
@@ -44,29 +46,50 @@ FT_BEGIN_HEADER
#include FT_SERVICE_TT_CMAP_H
#include FT_SERVICE_CID_H
- typedef struct CffModulePIC_
+
+ typedef struct CffModulePIC_
{
- FT_ServiceDescRec* cff_services;
- CFF_Field_Handler* cff_field_handlers;
- FT_Service_PsInfoRec cff_service_ps_info;
- FT_Service_GlyphDictRec cff_service_glyph_dict;
- FT_Service_PsFontNameRec cff_service_ps_name;
- FT_Service_TTCMapsRec cff_service_get_cmap_info;
- FT_Service_CIDRec cff_service_cid_info;
- FT_CMap_ClassRec cff_cmap_encoding_class_rec;
- FT_CMap_ClassRec cff_cmap_unicode_class_rec;
+ FT_ServiceDescRec* cff_services;
+ CFF_Field_Handler* cff_field_handlers;
+ FT_Service_PsInfoRec cff_service_ps_info;
+ FT_Service_GlyphDictRec cff_service_glyph_dict;
+ FT_Service_PsFontNameRec cff_service_ps_name;
+ FT_Service_TTCMapsRec cff_service_get_cmap_info;
+ FT_Service_CIDRec cff_service_cid_info;
+ FT_CMap_ClassRec cff_cmap_encoding_class_rec;
+ FT_CMap_ClassRec cff_cmap_unicode_class_rec;
+
} CffModulePIC;
-#define GET_PIC(lib) ((CffModulePIC*)((lib)->pic_container.cff))
-#define FT_CFF_SERVICE_PS_INFO_GET (GET_PIC(library)->cff_service_ps_info)
-#define FT_CFF_SERVICE_GLYPH_DICT_GET (GET_PIC(library)->cff_service_glyph_dict)
-#define FT_CFF_SERVICE_PS_NAME_GET (GET_PIC(library)->cff_service_ps_name)
-#define FT_CFF_SERVICE_GET_CMAP_INFO_GET (GET_PIC(library)->cff_service_get_cmap_info)
-#define FT_CFF_SERVICE_CID_INFO_GET (GET_PIC(library)->cff_service_cid_info)
-#define FT_CFF_SERVICES_GET (GET_PIC(library)->cff_services)
-#define FT_CFF_CMAP_ENCODING_CLASS_REC_GET (GET_PIC(library)->cff_cmap_encoding_class_rec)
-#define FT_CFF_CMAP_UNICODE_CLASS_REC_GET (GET_PIC(library)->cff_cmap_unicode_class_rec)
-#define FT_CFF_FIELD_HANDLERS_GET (GET_PIC(library)->cff_field_handlers)
+
+#define GET_PIC( lib ) \
+ ( (CffModulePIC*)((lib)->pic_container.cff) )
+
+#define CFF_SERVICE_PS_INFO_GET \
+ ( GET_PIC( library )->cff_service_ps_info )
+#define CFF_SERVICE_GLYPH_DICT_GET \
+ ( GET_PIC( library )->cff_service_glyph_dict )
+#define CFF_SERVICE_PS_NAME_GET \
+ ( GET_PIC( library )->cff_service_ps_name )
+#define CFF_SERVICE_GET_CMAP_INFO_GET \
+ ( GET_PIC( library )->cff_service_get_cmap_info )
+#define CFF_SERVICE_CID_INFO_GET \
+ ( GET_PIC( library )->cff_service_cid_info )
+#define CFF_SERVICES_GET \
+ ( GET_PIC( library )->cff_services )
+#define CFF_CMAP_ENCODING_CLASS_REC_GET \
+ ( GET_PIC( library )->cff_cmap_encoding_class_rec )
+#define CFF_CMAP_UNICODE_CLASS_REC_GET \
+ ( GET_PIC( library )->cff_cmap_unicode_class_rec )
+#define CFF_FIELD_HANDLERS_GET \
+ ( GET_PIC( library )->cff_field_handlers )
+
+ /* see cffpic.c for the implementation */
+ void
+ cff_driver_class_pic_free( FT_Library library );
+
+ FT_Error
+ cff_driver_class_pic_init( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/cff/cfftypes.h b/3party/freetype/src/cff/cfftypes.h
index cae368956b..7c99036b50 100644
--- a/3party/freetype/src/cff/cfftypes.h
+++ b/3party/freetype/src/cff/cfftypes.h
@@ -269,7 +269,7 @@ FT_BEGIN_HEADER
/* since version 2.3.6 */
FT_String* registry;
FT_String* ordering;
-
+
} CFF_FontRec, *CFF_Font;
diff --git a/3party/freetype/src/cid/ciderrs.h b/3party/freetype/src/cid/ciderrs.h
index 01813e1898..ef13155504 100644
--- a/3party/freetype/src/cid/ciderrs.h
+++ b/3party/freetype/src/cid/ciderrs.h
@@ -4,7 +4,7 @@
/* */
/* CID error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX CID_Err_
#define FT_ERR_BASE FT_Mod_Err_CID
diff --git a/3party/freetype/src/cid/cidgload.c b/3party/freetype/src/cid/cidgload.c
index 81742d167a..bd84023400 100644
--- a/3party/freetype/src/cid/cidgload.c
+++ b/3party/freetype/src/cid/cidgload.c
@@ -426,7 +426,7 @@
metrics->horiBearingX = cbox.xMin;
metrics->horiBearingY = cbox.yMax;
- if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
+ if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
{
/* make up vertical ones */
ft_synthesize_vertical_metrics( metrics,
diff --git a/3party/freetype/src/cid/cidload.c b/3party/freetype/src/cid/cidload.c
index 5f712bcf17..cbb59850f6 100644
--- a/3party/freetype/src/cid/cidload.c
+++ b/3party/freetype/src/cid/cidload.c
@@ -4,7 +4,7 @@
/* */
/* CID-keyed Type1 font loader (body). */
/* */
-/* Copyright 1996-2006, 2009, 2011 by */
+/* Copyright 1996-2006, 2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -147,8 +147,8 @@
FT_CALLBACK_DEF( FT_Error )
- parse_font_matrix( CID_Face face,
- CID_Parser* parser )
+ cid_parse_font_matrix( CID_Face face,
+ CID_Parser* parser )
{
FT_Matrix* matrix;
FT_Vector* offset;
@@ -168,11 +168,11 @@
temp_scale = FT_ABS( temp[3] );
- /* Set units per EM based on FontMatrix values. We set the value to */
- /* `1000/temp_scale', because temp_scale was already multiplied by */
- /* 1000 (in `t1_tofixed', from psobjs.c). */
- root->units_per_EM = (FT_UShort)( FT_DivFix( 0x10000L,
- FT_DivFix( temp_scale, 1000 ) ) );
+ /* Set Units per EM based on FontMatrix values. We set the value to */
+ /* 1000 / temp_scale, because temp_scale was already multiplied by */
+ /* 1000 (in t1_tofixed, from psobjs.c). */
+
+ root->units_per_EM = (FT_UShort)FT_DivFix( 1000, temp_scale );
/* we need to scale the values by 1.0/temp[3] */
if ( temp_scale != 0x10000L )
@@ -268,7 +268,7 @@
#include "cidtoken.h"
T1_FIELD_CALLBACK( "FDArray", parse_fd_array, 0 )
- T1_FIELD_CALLBACK( "FontMatrix", parse_font_matrix, 0 )
+ T1_FIELD_CALLBACK( "FontMatrix", cid_parse_font_matrix, 0 )
T1_FIELD_CALLBACK( "ExpansionFactor", parse_expansion_factor, 0 )
{ 0, T1_FIELD_LOCATION_CID_INFO, T1_FIELD_TYPE_NONE, 0, 0, 0, 0, 0, 0 }
@@ -513,8 +513,8 @@
static void
- t1_init_loader( CID_Loader* loader,
- CID_Face face )
+ cid_init_loader( CID_Loader* loader,
+ CID_Face face )
{
FT_UNUSED( face );
@@ -522,8 +522,8 @@
}
- static void
- t1_done_loader( CID_Loader* loader )
+ static void
+ cid_done_loader( CID_Loader* loader )
{
CID_Parser* parser = &loader->parser;
@@ -641,7 +641,7 @@
FT_Error error;
- t1_init_loader( &loader, face );
+ cid_init_loader( &loader, face );
parser = &loader.parser;
error = cid_parser_new( parser, face->root.stream, face->root.memory,
@@ -682,7 +682,7 @@
error = cid_read_subrs( face );
Exit:
- t1_done_loader( &loader );
+ cid_done_loader( &loader );
return error;
}
diff --git a/3party/freetype/src/cid/cidobjs.c b/3party/freetype/src/cid/cidobjs.c
index eb82168888..cc2a2008e7 100644
--- a/3party/freetype/src/cid/cidobjs.c
+++ b/3party/freetype/src/cid/cidobjs.c
@@ -4,7 +4,7 @@
/* */
/* CID objects manager (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008, 2010 by */
+/* Copyright 1996-2006, 2008, 2010-2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -299,6 +299,13 @@
psaux = (PSAux_Service)FT_Get_Module_Interface(
FT_FACE_LIBRARY( face ), "psaux" );
+ if ( !psaux )
+ {
+ FT_ERROR(( "cid_face_init: cannot access `psaux' module\n" ));
+ error = CID_Err_Missing_Module;
+ goto Exit;
+ }
+
face->psaux = psaux;
}
@@ -311,6 +318,8 @@
face->pshinter = pshinter;
}
+ FT_TRACE2(( "CID driver\n" ));
+
/* open the tokenizer; this will also check the font format */
if ( FT_STREAM_SEEK( 0 ) )
goto Exit;
diff --git a/3party/freetype/src/cid/cidparse.c b/3party/freetype/src/cid/cidparse.c
index efed618f5a..4d21160cea 100644
--- a/3party/freetype/src/cid/cidparse.c
+++ b/3party/freetype/src/cid/cidparse.c
@@ -73,7 +73,7 @@
if ( ft_strncmp( (char *)stream->cursor,
"%!PS-Adobe-3.0 Resource-CIDFont", 31 ) )
{
- FT_TRACE2(( "[not a valid CID-keyed font]\n" ));
+ FT_TRACE2(( " not a CID-keyed font\n" ));
error = CID_Err_Unknown_File_Format;
}
@@ -99,7 +99,7 @@
if ( stream_len == 0 )
{
FT_TRACE2(( "cid_parser_new: no `StartData' keyword found\n" ));
- error = CID_Err_Unknown_File_Format;
+ error = CID_Err_Invalid_File_Format;
goto Exit;
}
diff --git a/3party/freetype/src/cid/cidriver.c b/3party/freetype/src/cid/cidriver.c
index 86ee3bba34..694070aab7 100644
--- a/3party/freetype/src/cid/cidriver.c
+++ b/3party/freetype/src/cid/cidriver.c
@@ -111,13 +111,13 @@
if ( registry )
*registry = cid->registry;
-
+
if ( ordering )
*ordering = cid->ordering;
if ( supplement )
*supplement = cid->supplement;
-
+
return CID_Err_Ok;
}
@@ -196,7 +196,7 @@
FT_MODULE_DRIVER_SCALABLE |
FT_MODULE_DRIVER_HAS_HINTER,
- sizeof( FT_DriverRec ),
+ sizeof ( FT_DriverRec ),
"t1cid", /* module name */
0x10000L, /* version 1.0 of driver */
0x20000L, /* requires FreeType 2.0 */
@@ -209,9 +209,9 @@
},
/* then the other font drivers fields */
- sizeof( CID_FaceRec ),
- sizeof( CID_SizeRec ),
- sizeof( CID_GlyphSlotRec ),
+ sizeof ( CID_FaceRec ),
+ sizeof ( CID_SizeRec ),
+ sizeof ( CID_GlyphSlotRec ),
cid_face_init,
cid_face_done,
diff --git a/3party/freetype/src/cid/cidriver.h b/3party/freetype/src/cid/cidriver.h
index c7f424bb38..3c45e06886 100644
--- a/3party/freetype/src/cid/cidriver.h
+++ b/3party/freetype/src/cid/cidriver.h
@@ -28,7 +28,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_CALLBACK_TABLE
diff --git a/3party/freetype/src/gxvalid/gxvcommn.c b/3party/freetype/src/gxvalid/gxvcommn.c
index d3c48d4ea6..72efd6ff5d 100644
--- a/3party/freetype/src/gxvalid/gxvcommn.c
+++ b/3party/freetype/src/gxvalid/gxvcommn.c
@@ -1334,7 +1334,7 @@
l[1] = stateArray_length_p;
l[2] = entryTable_length_p;
- gxv_set_length_by_ulong_offset( o, l, buff, 4, table_size, valid );
+ gxv_set_length_by_ulong_offset( o, l, buff, 3, table_size, valid );
}
@@ -1704,9 +1704,9 @@
const FT_String* name,
GXV_odtect_Range odtect )
{
- odtect->range[ odtect->nRanges ].start = start;
- odtect->range[ odtect->nRanges ].length = length;
- odtect->range[ odtect->nRanges ].name = (FT_String*)name;
+ odtect->range[odtect->nRanges].start = start;
+ odtect->range[odtect->nRanges].length = length;
+ odtect->range[odtect->nRanges].name = (FT_String*)name;
odtect->nRanges++;
}
diff --git a/3party/freetype/src/gxvalid/gxvcommn.h b/3party/freetype/src/gxvalid/gxvcommn.h
index 35c043dbd8..1ff87e4423 100644
--- a/3party/freetype/src/gxvalid/gxvcommn.h
+++ b/3party/freetype/src/gxvalid/gxvcommn.h
@@ -4,7 +4,8 @@
/* */
/* TrueTypeGX/AAT common tables validation (specification). */
/* */
-/* Copyright 2004, 2005 by suzuki toshiya, Masatake YAMATO, Red Hat K.K., */
+/* Copyright 2004, 2005, 2012 */
+/* by suzuki toshiya, Masatake YAMATO, Red Hat K.K., */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -316,7 +317,7 @@ FT_BEGIN_HEADER
#define GXV_32BIT_ALIGNMENT_VALIDATE( a ) \
FT_BEGIN_STMNT \
{ \
- if ( 0 != ( (a) % 4 ) ) \
+ if ( (a) & 3 ) \
FT_INVALID_OFFSET ; \
} \
FT_END_STMNT
diff --git a/3party/freetype/src/gxvalid/gxverror.h b/3party/freetype/src/gxvalid/gxverror.h
index 0196199227..7d2ef78097 100644
--- a/3party/freetype/src/gxvalid/gxverror.h
+++ b/3party/freetype/src/gxvalid/gxverror.h
@@ -4,7 +4,8 @@
/* */
/* TrueTypeGX/AAT validation module error codes (specification only). */
/* */
-/* Copyright 2004, 2005 by suzuki toshiya, Masatake YAMATO, Red Hat K.K., */
+/* Copyright 2004, 2005, 2012 */
+/* by suzuki toshiya, Masatake YAMATO, Red Hat K.K., */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -38,6 +39,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX GXV_Err_
#define FT_ERR_BASE FT_Mod_Err_GXV
diff --git a/3party/freetype/src/gxvalid/gxvfeat.c b/3party/freetype/src/gxvalid/gxvfeat.c
index 46792bbf98..6f75650991 100644
--- a/3party/freetype/src/gxvalid/gxvfeat.c
+++ b/3party/freetype/src/gxvalid/gxvfeat.c
@@ -4,7 +4,7 @@
/* */
/* TrueTypeGX/AAT feat table validation (body). */
/* */
-/* Copyright 2004, 2005, 2008 by */
+/* Copyright 2004, 2005, 2008, 2012 by */
/* suzuki toshiya, Masatake YAMATO, Red Hat K.K., */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
@@ -176,7 +176,7 @@
setting = FT_NEXT_USHORT( p );
/* If we have exclusive setting, the setting should be odd. */
- if ( exclusive && ( setting % 2 ) == 0 )
+ if ( exclusive && ( setting & 1 ) == 0 )
FT_INVALID_DATA;
gxv_feat_name_index_validate( p, limit, valid );
diff --git a/3party/freetype/src/gxvalid/gxvmod.c b/3party/freetype/src/gxvalid/gxvmod.c
index b2b16b1ff3..502fe5dca7 100644
--- a/3party/freetype/src/gxvalid/gxvmod.c
+++ b/3party/freetype/src/gxvalid/gxvmod.c
@@ -269,7 +269,7 @@
const FT_Module_Class gxv_module_class =
{
0,
- sizeof( FT_ModuleRec ),
+ sizeof ( FT_ModuleRec ),
"gxvalid",
0x10000L,
0x20000L,
diff --git a/3party/freetype/src/gxvalid/gxvmod.h b/3party/freetype/src/gxvalid/gxvmod.h
index d912a8f838..22732ba992 100644
--- a/3party/freetype/src/gxvalid/gxvmod.h
+++ b/3party/freetype/src/gxvalid/gxvmod.h
@@ -36,7 +36,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_EXPORT_VAR( const FT_Module_Class ) gxv_module_class;
diff --git a/3party/freetype/src/gxvalid/gxvprop.c b/3party/freetype/src/gxvalid/gxvprop.c
index 54777271aa..0be21336f8 100644
--- a/3party/freetype/src/gxvalid/gxvprop.c
+++ b/3party/freetype/src/gxvalid/gxvprop.c
@@ -233,7 +233,7 @@
/* XXX: check range? */
offset = (FT_UShort)( base_value_p->u +
- relative_gindex * sizeof( FT_UShort ) );
+ relative_gindex * sizeof ( FT_UShort ) );
p = valid->lookuptbl_head + offset;
limit = lookuptbl_limit;
diff --git a/3party/freetype/src/gzip/ftgzip.c b/3party/freetype/src/gzip/ftgzip.c
index 52966ece71..f3d2ef94fc 100644
--- a/3party/freetype/src/gzip/ftgzip.c
+++ b/3party/freetype/src/gzip/ftgzip.c
@@ -8,7 +8,7 @@
/* parse compressed PCF fonts, as found with many X11 server */
/* distributions. */
/* */
-/* Copyright 2002-2006, 2009-2011 by */
+/* Copyright 2002-2006, 2009-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -32,6 +32,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX Gzip_Err_
#define FT_ERR_BASE FT_Mod_Err_Gzip
@@ -42,7 +43,7 @@
#ifdef FT_CONFIG_OPTION_PIC
#error "gzip code does not support PIC yet"
-#endif
+#endif
#ifdef FT_CONFIG_OPTION_SYSTEM_ZLIB
diff --git a/3party/freetype/src/lzw/ftlzw.c b/3party/freetype/src/lzw/ftlzw.c
index 7f254999ad..35e392b43c 100644
--- a/3party/freetype/src/lzw/ftlzw.c
+++ b/3party/freetype/src/lzw/ftlzw.c
@@ -8,7 +8,7 @@
/* be used to parse compressed PCF fonts, as found with many X11 server */
/* distributions. */
/* */
-/* Copyright 2004, 2005, 2006, 2009, 2010 by */
+/* Copyright 2004-2006, 2009, 2010, 2012 by */
/* Albert Chin-A-Young. */
/* */
/* Based on code in src/gzip/ftgzip.c, Copyright 2004 by */
@@ -34,6 +34,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX LZW_Err_
#define FT_ERR_BASE FT_Mod_Err_LZW
@@ -44,7 +45,7 @@
#ifdef FT_CONFIG_OPTION_PIC
#error "lzw code does not support PIC yet"
-#endif
+#endif
#include "ftzopen.h"
diff --git a/3party/freetype/src/otvalid/otverror.h b/3party/freetype/src/otvalid/otverror.h
index 041b538368..522f4a2007 100644
--- a/3party/freetype/src/otvalid/otverror.h
+++ b/3party/freetype/src/otvalid/otverror.h
@@ -4,7 +4,7 @@
/* */
/* OpenType validation module error codes (specification only). */
/* */
-/* Copyright 2004, 2005 by */
+/* Copyright 2004, 2005, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX OTV_Err_
#define FT_ERR_BASE FT_Mod_Err_OTvalid
diff --git a/3party/freetype/src/otvalid/otvmod.c b/3party/freetype/src/otvalid/otvmod.c
index 620e45233d..acf213f237 100644
--- a/3party/freetype/src/otvalid/otvmod.c
+++ b/3party/freetype/src/otvalid/otvmod.c
@@ -266,7 +266,7 @@
const FT_Module_Class otv_module_class =
{
0,
- sizeof( FT_ModuleRec ),
+ sizeof ( FT_ModuleRec ),
"otvalid",
0x10000L,
0x20000L,
diff --git a/3party/freetype/src/otvalid/otvmod.h b/3party/freetype/src/otvalid/otvmod.h
index 573b2a0c4b..f7e1550787 100644
--- a/3party/freetype/src/otvalid/otvmod.h
+++ b/3party/freetype/src/otvalid/otvmod.h
@@ -29,7 +29,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_EXPORT_VAR( const FT_Module_Class ) otv_module_class;
diff --git a/3party/freetype/src/pcf/pcfdrivr.c b/3party/freetype/src/pcf/pcfdrivr.c
index af2a2d986f..ba5448842a 100644
--- a/3party/freetype/src/pcf/pcfdrivr.c
+++ b/3party/freetype/src/pcf/pcfdrivr.c
@@ -2,8 +2,7 @@
FreeType font driver for pcf files
- Copyright (C) 2000, 2001, 2002, 2003, 2004, 2006, 2007, 2008, 2009,
- 2010 by
+ Copyright (C) 2000-2004, 2006-2011 by
Francesco Zappa Nardelli
Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -36,7 +35,7 @@ THE SOFTWARE.
#include FT_BZIP2_H
#include FT_ERRORS_H
#include FT_BDF_H
-#include FT_TRUETYPE_IDS_H
+#include FT_TRUETYPE_IDS_H
#include "pcf.h"
#include "pcfdrivr.h"
@@ -248,8 +247,6 @@ THE SOFTWARE.
FT_FREE( face->charset_encoding );
FT_FREE( face->charset_registry );
- FT_TRACE4(( "PCF_Face_Done: done face\n" ));
-
/* close compressed stream if any */
if ( pcfface->stream == &face->comp_stream )
{
@@ -274,6 +271,8 @@ THE SOFTWARE.
FT_UNUSED( face_index );
+ FT_TRACE2(( "PCF driver\n" ));
+
error = pcf_load_font( stream, face );
if ( error )
{
@@ -405,7 +404,7 @@ THE SOFTWARE.
return error;
Fail:
- FT_TRACE2(( "[not a valid PCF file]\n" ));
+ FT_TRACE2(( " not a PCF file\n" ));
PCF_Face_Done( pcfface );
error = PCF_Err_Unknown_File_Format; /* error */
goto Exit;
@@ -684,8 +683,8 @@ THE SOFTWARE.
0,
- 0,
- 0,
+ 0, /* FT_Module_Constructor */
+ 0, /* FT_Module_Destructor */
pcf_driver_requester
},
diff --git a/3party/freetype/src/pcf/pcfdrivr.h b/3party/freetype/src/pcf/pcfdrivr.h
index a81d7309e5..54614951b5 100644
--- a/3party/freetype/src/pcf/pcfdrivr.h
+++ b/3party/freetype/src/pcf/pcfdrivr.h
@@ -35,7 +35,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_EXPORT_VAR( const FT_Driver_ClassRec ) pcf_driver_class;
diff --git a/3party/freetype/src/pcf/pcferror.h b/3party/freetype/src/pcf/pcferror.h
index d75c067aa6..e51fff8ea6 100644
--- a/3party/freetype/src/pcf/pcferror.h
+++ b/3party/freetype/src/pcf/pcferror.h
@@ -4,7 +4,7 @@
/* */
/* PCF error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX PCF_Err_
#define FT_ERR_BASE FT_Mod_Err_PCF
diff --git a/3party/freetype/src/pcf/pcfread.c b/3party/freetype/src/pcf/pcfread.c
index f8c2a239b9..d9914c03a1 100644
--- a/3party/freetype/src/pcf/pcfread.c
+++ b/3party/freetype/src/pcf/pcfread.c
@@ -2,8 +2,7 @@
FreeType font driver for pcf fonts
- Copyright 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009,
- 2010 by
+ Copyright 2000-2010, 2012 by
Francesco Zappa Nardelli
Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -496,7 +495,8 @@ THE SOFTWARE.
goto Bail;
}
- if ( FT_NEW_ARRAY( strings, string_size ) )
+ /* allocate one more byte so that we have a final null byte */
+ if ( FT_NEW_ARRAY( strings, string_size + 1 ) )
goto Bail;
error = FT_Stream_Read( stream, (FT_Byte*)strings, string_size );
diff --git a/3party/freetype/src/pfr/pfrdrivr.c b/3party/freetype/src/pfr/pfrdrivr.c
index 0053050a2a..c59d8ae98b 100644
--- a/3party/freetype/src/pfr/pfrdrivr.c
+++ b/3party/freetype/src/pfr/pfrdrivr.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PFR driver interface (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2006, 2008, 2010 by */
+/* Copyright 2002-2004, 2006, 2008, 2010, 2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -173,7 +173,7 @@
FT_MODULE_FONT_DRIVER |
FT_MODULE_DRIVER_SCALABLE,
- sizeof( FT_DriverRec ),
+ sizeof ( FT_DriverRec ),
"pfr",
0x10000L,
@@ -181,14 +181,14 @@
NULL,
- 0,
- 0,
+ 0, /* FT_Module_Constructor */
+ 0, /* FT_Module_Destructor */
pfr_get_service
},
- sizeof( PFR_FaceRec ),
- sizeof( PFR_SizeRec ),
- sizeof( PFR_SlotRec ),
+ sizeof ( PFR_FaceRec ),
+ sizeof ( PFR_SizeRec ),
+ sizeof ( PFR_SlotRec ),
pfr_face_init,
pfr_face_done,
@@ -205,9 +205,9 @@
pfr_get_kerning,
0, /* FT_Face_AttachFunc */
- 0, /* FT_Face_GetAdvancesFunc */
- 0, /* FT_Size_RequestFunc */
- 0, /* FT_Size_SelectFunc */
+ 0, /* FT_Face_GetAdvancesFunc */
+ 0, /* FT_Size_RequestFunc */
+ 0, /* FT_Size_SelectFunc */
};
diff --git a/3party/freetype/src/pfr/pfrdrivr.h b/3party/freetype/src/pfr/pfrdrivr.h
index da0a1aa634..75f86c5cdd 100644
--- a/3party/freetype/src/pfr/pfrdrivr.h
+++ b/3party/freetype/src/pfr/pfrdrivr.h
@@ -28,7 +28,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_EXPORT_VAR( const FT_Driver_ClassRec ) pfr_driver_class;
diff --git a/3party/freetype/src/pfr/pfrerror.h b/3party/freetype/src/pfr/pfrerror.h
index 2e1c401dd2..94dc8c5e1c 100644
--- a/3party/freetype/src/pfr/pfrerror.h
+++ b/3party/freetype/src/pfr/pfrerror.h
@@ -4,7 +4,7 @@
/* */
/* PFR error codes (specification only). */
/* */
-/* Copyright 2002 by */
+/* Copyright 2002, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX PFR_Err_
#define FT_ERR_BASE FT_Mod_Err_PFR
diff --git a/3party/freetype/src/pfr/pfrobjs.c b/3party/freetype/src/pfr/pfrobjs.c
index 3e5e86e210..c65cf29909 100644
--- a/3party/freetype/src/pfr/pfrobjs.c
+++ b/3party/freetype/src/pfr/pfrobjs.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PFR object methods (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2010 by */
+/* Copyright 2002-2008, 2010-2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -23,7 +23,7 @@
#include "pfrsbit.h"
#include FT_OUTLINE_H
#include FT_INTERNAL_DEBUG_H
-#include FT_TRUETYPE_IDS_H
+#include FT_TRUETYPE_IDS_H
#include "pfrerror.h"
@@ -77,6 +77,8 @@
FT_UNUSED( params );
+ FT_TRACE2(( "PFR driver\n" ));
+
/* load the header and check it */
error = pfr_header_load( &face->header, stream );
if ( error )
@@ -84,7 +86,7 @@
if ( !pfr_header_check( &face->header ) )
{
- FT_TRACE4(( "pfr_face_init: not a valid PFR font\n" ));
+ FT_TRACE2(( " not a PFR font\n" ));
error = PFR_Err_Unknown_File_Format;
goto Exit;
}
diff --git a/3party/freetype/src/psaux/afmparse.c b/3party/freetype/src/psaux/afmparse.c
index d7de3736f7..5f3f9e6158 100644
--- a/3party/freetype/src/psaux/afmparse.c
+++ b/3party/freetype/src/psaux/afmparse.c
@@ -4,7 +4,7 @@
/* */
/* AFM parser (body). */
/* */
-/* Copyright 2006, 2007, 2008, 2009, 2010 by */
+/* Copyright 2006-2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -631,9 +631,6 @@
tk->max_ptsize = shared_vals[3].u.f;
tk->max_kern = shared_vals[4].u.f;
- /* is this correct? */
- if ( tk->degree < 0 && tk->min_kern > 0 )
- tk->min_kern = -tk->min_kern;
break;
case AFM_TOKEN_ENDTRACKKERN:
@@ -754,7 +751,7 @@
case AFM_TOKEN_ENDFONTMETRICS:
fi->NumKernPair = n + 1;
ft_qsort( fi->KernPairs, fi->NumKernPair,
- sizeof( AFM_KernPairRec ),
+ sizeof ( AFM_KernPairRec ),
afm_compare_kern_pairs );
return PSaux_Err_Ok;
diff --git a/3party/freetype/src/psaux/psauxerr.h b/3party/freetype/src/psaux/psauxerr.h
index d0baa3cbb9..d52375f8cb 100644
--- a/3party/freetype/src/psaux/psauxerr.h
+++ b/3party/freetype/src/psaux/psauxerr.h
@@ -4,7 +4,7 @@
/* */
/* PS auxiliary module error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX PSaux_Err_
#define FT_ERR_BASE FT_Mod_Err_PSaux
diff --git a/3party/freetype/src/psaux/psauxmod.c b/3party/freetype/src/psaux/psauxmod.c
index 4c3579f7b8..4b1249d49b 100644
--- a/3party/freetype/src/psaux/psauxmod.c
+++ b/3party/freetype/src/psaux/psauxmod.c
@@ -123,7 +123,7 @@
const FT_Module_Class psaux_module_class =
{
0,
- sizeof( FT_ModuleRec ),
+ sizeof ( FT_ModuleRec ),
"psaux",
0x20000L,
0x20000L,
diff --git a/3party/freetype/src/psaux/psauxmod.h b/3party/freetype/src/psaux/psauxmod.h
index 35e042dbce..1217236924 100644
--- a/3party/freetype/src/psaux/psauxmod.h
+++ b/3party/freetype/src/psaux/psauxmod.h
@@ -28,7 +28,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_EXPORT_VAR( const FT_Module_Class ) psaux_driver_class;
diff --git a/3party/freetype/src/psaux/psconv.c b/3party/freetype/src/psaux/psconv.c
index 1531d8f0fb..b7870c5aec 100644
--- a/3party/freetype/src/psaux/psconv.c
+++ b/3party/freetype/src/psaux/psconv.c
@@ -4,7 +4,7 @@
/* */
/* Some convenience conversions (body). */
/* */
-/* Copyright 2006, 2008, 2009 by */
+/* Copyright 2006, 2008, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,11 +18,22 @@
#include <ft2build.h>
#include FT_INTERNAL_POSTSCRIPT_AUX_H
+#include FT_INTERNAL_DEBUG_H
#include "psconv.h"
#include "psauxerr.h"
+ /*************************************************************************/
+ /* */
+ /* The macro FT_COMPONENT is used in trace mode. It is an implicit */
+ /* parameter of the FT_TRACE() and FT_ERROR() macros, used to print/log */
+ /* messages during execution. */
+ /* */
+#undef FT_COMPONENT
+#define FT_COMPONENT trace_psconv
+
+
/* The following array is used by various functions to quickly convert */
/* digits (both decimal and non-decimal) into numbers. */
@@ -69,18 +80,29 @@
#endif /* 'A' == 193 */
- FT_LOCAL_DEF( FT_Int )
+ FT_LOCAL_DEF( FT_Long )
PS_Conv_Strtol( FT_Byte** cursor,
FT_Byte* limit,
- FT_Int base )
+ FT_Long base )
{
FT_Byte* p = *cursor;
- FT_Int num = 0;
- FT_Bool sign = 0;
+ FT_Long num = 0;
+ FT_Bool sign = 0;
+ FT_Bool have_overflow = 0;
+
+ FT_Long num_limit;
+ FT_Char c_limit;
- if ( p == limit || base < 2 || base > 36 )
+
+ if ( p >= limit )
+ goto Bad;
+
+ if ( base < 2 || base > 36 )
+ {
+ FT_TRACE4(( "!!!INVALID BASE:!!!" ));
return 0;
+ }
if ( *p == '-' || *p == '+' )
{
@@ -88,9 +110,12 @@
p++;
if ( p == limit )
- return 0;
+ goto Bad;
}
+ num_limit = 0x7FFFFFFFL / base;
+ c_limit = (FT_Char)( 0x7FFFFFFFL % base );
+
for ( ; p < limit; p++ )
{
FT_Char c;
@@ -104,54 +129,84 @@
if ( c < 0 || c >= base )
break;
- num = num * base + c;
+ if ( num > num_limit || ( num == num_limit && c > c_limit ) )
+ have_overflow = 1;
+ else
+ num = num * base + c;
+ }
+
+ *cursor = p;
+
+ if ( have_overflow )
+ {
+ num = 0x7FFFFFFFL;
+ FT_TRACE4(( "!!!OVERFLOW:!!!" ));
}
if ( sign )
num = -num;
- *cursor = p;
-
return num;
+
+ Bad:
+ FT_TRACE4(( "!!!END OF DATA:!!!" ));
+ return 0;
}
- FT_LOCAL_DEF( FT_Int )
+ FT_LOCAL_DEF( FT_Long )
PS_Conv_ToInt( FT_Byte** cursor,
FT_Byte* limit )
{
- FT_Byte* p;
- FT_Int num;
+ FT_Byte* p = *cursor;
+ FT_Byte* curp;
+
+ FT_Long num;
- num = PS_Conv_Strtol( cursor, limit, 10 );
- p = *cursor;
+ curp = p;
+ num = PS_Conv_Strtol( &p, limit, 10 );
+
+ if ( p == curp )
+ return 0;
if ( p < limit && *p == '#' )
{
- *cursor = p + 1;
+ p++;
- return PS_Conv_Strtol( cursor, limit, num );
+ curp = p;
+ num = PS_Conv_Strtol( &p, limit, num );
+
+ if ( p == curp )
+ return 0;
}
- else
- return num;
+
+ *cursor = p;
+
+ return num;
}
FT_LOCAL_DEF( FT_Fixed )
PS_Conv_ToFixed( FT_Byte** cursor,
FT_Byte* limit,
- FT_Int power_ten )
+ FT_Long power_ten )
{
FT_Byte* p = *cursor;
- FT_Fixed integral;
- FT_Long decimal = 0, divider = 1;
- FT_Bool sign = 0;
+ FT_Byte* curp;
+ FT_Fixed integral = 0;
+ FT_Long decimal = 0;
+ FT_Long divider = 1;
- if ( p == limit )
- return 0;
+ FT_Bool sign = 0;
+ FT_Bool have_overflow = 0;
+ FT_Bool have_underflow = 0;
+
+
+ if ( p >= limit )
+ goto Bad;
if ( *p == '-' || *p == '+' )
{
@@ -159,13 +214,23 @@
p++;
if ( p == limit )
- return 0;
+ goto Bad;
}
+ /* read the integer part */
if ( *p != '.' )
- integral = PS_Conv_ToInt( &p, limit ) << 16;
- else
- integral = 0;
+ {
+ curp = p;
+ integral = PS_Conv_ToInt( &p, limit );
+
+ if ( p == curp )
+ return 0;
+
+ if ( integral > 0x7FFF )
+ have_overflow = 1;
+ else
+ integral <<= 16;
+ }
/* read the decimal part */
if ( p < limit && *p == '.' )
@@ -185,18 +250,14 @@
if ( c < 0 || c >= 10 )
break;
- if ( !integral && power_ten > 0 )
+ if ( decimal < 0xCCCCCCCL )
{
- power_ten--;
decimal = decimal * 10 + c;
- }
- else
- {
- if ( divider < 10000000L )
- {
- decimal = decimal * 10 + c;
+
+ if ( !integral && power_ten > 0 )
+ power_ten--;
+ else
divider *= 10;
- }
}
}
}
@@ -204,33 +265,94 @@
/* read exponent, if any */
if ( p + 1 < limit && ( *p == 'e' || *p == 'E' ) )
{
+ FT_Long exponent;
+
+
p++;
- power_ten += PS_Conv_ToInt( &p, limit );
+
+ curp = p;
+ exponent = PS_Conv_ToInt( &p, limit );
+
+ if ( curp == p )
+ return 0;
+
+ /* arbitrarily limit exponent */
+ if ( exponent > 1000 )
+ have_overflow = 1;
+ else if ( exponent < -1000 )
+ have_underflow = 1;
+ else
+ power_ten += exponent;
}
+ *cursor = p;
+
+ if ( !integral && !decimal )
+ return 0;
+
+ if ( have_overflow )
+ goto Overflow;
+ if ( have_underflow )
+ goto Underflow;
+
while ( power_ten > 0 )
{
+ if ( integral >= 0xCCCCCCCL )
+ goto Overflow;
integral *= 10;
- decimal *= 10;
+
+ if ( decimal >= 0xCCCCCCCL )
+ {
+ if ( divider == 1 )
+ goto Overflow;
+ divider /= 10;
+ }
+ else
+ decimal *= 10;
+
power_ten--;
}
while ( power_ten < 0 )
{
integral /= 10;
- divider *= 10;
+ if ( divider < 0xCCCCCCCL )
+ divider *= 10;
+ else
+ decimal /= 10;
+
+ if ( !integral && !decimal )
+ goto Underflow;
+
power_ten++;
}
if ( decimal )
- integral += FT_DivFix( decimal, divider );
+ {
+ decimal = FT_DivFix( decimal, divider );
+ /* it's not necessary to check this addition for overflow */
+ /* due to the structure of the real number representation */
+ integral += decimal;
+ }
+ Exit:
if ( sign )
integral = -integral;
- *cursor = p;
-
return integral;
+
+ Bad:
+ FT_TRACE4(( "!!!END OF DATA:!!!" ));
+ return 0;
+
+ Overflow:
+ integral = 0x7FFFFFFFL;
+ FT_TRACE4(( "!!!OVERFLOW:!!!" ));
+ goto Exit;
+
+ Underflow:
+ FT_TRACE4(( "!!!UNDERFLOW:!!!" ));
+ return 0;
}
@@ -346,7 +468,11 @@
#if 1
- p = *cursor;
+ p = *cursor;
+
+ if ( p >= limit )
+ return 0;
+
if ( n > (FT_UInt)( limit - p ) )
n = (FT_UInt)( limit - p );
@@ -434,6 +560,10 @@
#if 1
p = *cursor;
+
+ if ( p >= limit )
+ return 0;
+
if ( n > (FT_UInt)(limit - p) )
n = (FT_UInt)(limit - p);
diff --git a/3party/freetype/src/psaux/psconv.h b/3party/freetype/src/psaux/psconv.h
index 84854ba0d1..d91c762210 100644
--- a/3party/freetype/src/psaux/psconv.h
+++ b/3party/freetype/src/psaux/psconv.h
@@ -4,7 +4,7 @@
/* */
/* Some convenience conversions (specification). */
/* */
-/* Copyright 2006 by */
+/* Copyright 2006, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -26,20 +26,20 @@
FT_BEGIN_HEADER
- FT_LOCAL( FT_Int )
+ FT_LOCAL( FT_Long )
PS_Conv_Strtol( FT_Byte** cursor,
FT_Byte* limit,
- FT_Int base );
+ FT_Long base );
- FT_LOCAL( FT_Int )
+ FT_LOCAL( FT_Long )
PS_Conv_ToInt( FT_Byte** cursor,
FT_Byte* limit );
FT_LOCAL( FT_Fixed )
PS_Conv_ToFixed( FT_Byte** cursor,
FT_Byte* limit,
- FT_Int power_ten );
+ FT_Long power_ten );
#if 0
FT_LOCAL( FT_UInt )
diff --git a/3party/freetype/src/psaux/psobjs.c b/3party/freetype/src/psaux/psobjs.c
index a28b5fc241..06df6e6649 100644
--- a/3party/freetype/src/psaux/psobjs.c
+++ b/3party/freetype/src/psaux/psobjs.c
@@ -4,7 +4,7 @@
/* */
/* Auxiliary functions for PostScript fonts (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -589,7 +589,7 @@
}
Exit:
- if ( cur == parser->cursor )
+ if ( cur < limit && cur == parser->cursor )
{
FT_ERROR(( "ps_parser_skip_PS_token:"
" current token is `%c' which is self-delimiting\n"
diff --git a/3party/freetype/src/psaux/t1cmap.c b/3party/freetype/src/psaux/t1cmap.c
index f933e4da88..9e5bd34ffe 100644
--- a/3party/freetype/src/psaux/t1cmap.c
+++ b/3party/freetype/src/psaux/t1cmap.c
@@ -4,7 +4,7 @@
/* */
/* Type 1 character map support (body). */
/* */
-/* Copyright 2002, 2003, 2006, 2007 by */
+/* Copyright 2002, 2003, 2006, 2007, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -264,8 +264,8 @@
/*************************************************************************/
FT_CALLBACK_DEF( const char * )
- t1_get_glyph_name( T1_Face face,
- FT_UInt idx )
+ psaux_get_glyph_name( T1_Face face,
+ FT_UInt idx )
{
return face->type1.glyph_names[idx];
}
@@ -282,7 +282,7 @@
return psnames->unicodes_init( memory,
unicodes,
face->type1.num_glyphs,
- (PS_GetGlyphNameFunc)&t1_get_glyph_name,
+ (PS_GetGlyphNameFunc)&psaux_get_glyph_name,
(PS_FreeGlyphNameFunc)NULL,
(FT_Pointer)face );
}
diff --git a/3party/freetype/src/psaux/t1decode.c b/3party/freetype/src/psaux/t1decode.c
index b3ccbdde0d..8afe02193a 100644
--- a/3party/freetype/src/psaux/t1decode.c
+++ b/3party/freetype/src/psaux/t1decode.c
@@ -4,7 +4,7 @@
/* */
/* PostScript Type 1 decoding routines (body). */
/* */
-/* Copyright 2000-2011 by */
+/* Copyright 2000-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -199,7 +199,7 @@
#ifdef FT_CONFIG_OPTION_INCREMENTAL
T1_Face face = (T1_Face)decoder->builder.face;
-#endif
+#endif
if ( decoder->seac )
@@ -208,6 +208,12 @@
return PSaux_Err_Syntax_Error;
}
+ if ( decoder->builder.metrics_only )
+ {
+ FT_ERROR(( "t1operator_seac: unexpected seac\n" ));
+ return PSaux_Err_Syntax_Error;
+ }
+
/* seac weirdness */
adx += decoder->builder.left_bearing.x;
@@ -400,7 +406,7 @@
if ( decoder->buildchar && decoder->len_buildchar > 0 )
ft_memset( &decoder->buildchar[0],
0,
- sizeof( decoder->buildchar[0] ) * decoder->len_buildchar );
+ sizeof ( decoder->buildchar[0] ) * decoder->len_buildchar );
FT_TRACE4(( "\n"
"Start charstring\n" ));
@@ -880,7 +886,7 @@
ft_memcpy( &decoder->buildchar[idx],
blend->weight_vector,
blend->num_designs *
- sizeof( blend->weight_vector[0] ) );
+ sizeof ( blend->weight_vector[0] ) );
}
break;
@@ -1113,7 +1119,7 @@
FT_TRACE4(( "BuildCharArray = [ " ));
for ( i = 0; i < decoder->len_buildchar; ++i )
- FT_TRACE4(( "%d ", decoder->buildchar[ i ] ));
+ FT_TRACE4(( "%d ", decoder->buildchar[i] ));
FT_TRACE4(( "]\n" ));
}
diff --git a/3party/freetype/src/pshinter/pshalgo.c b/3party/freetype/src/pshinter/pshalgo.c
index d798978914..f4fbb4d35f 100644
--- a/3party/freetype/src/pshinter/pshalgo.c
+++ b/3party/freetype/src/pshinter/pshalgo.c
@@ -4,8 +4,7 @@
/* */
/* PostScript hinting algorithm (body). */
/* */
-/* Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 */
-/* by */
+/* Copyright 2001-2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used */
@@ -563,7 +562,7 @@
else if ( len > 0 )
{
/* This is a very small stem; we simply align it to the
- * pixel grid, trying to find the minimal displacement.
+ * pixel grid, trying to find the minimum displacement.
*
* left = pos
* right = pos + len
diff --git a/3party/freetype/src/pshinter/pshglob.c b/3party/freetype/src/pshinter/pshglob.c
index 31231ad009..9285efc9e1 100644
--- a/3party/freetype/src/pshinter/pshglob.c
+++ b/3party/freetype/src/pshinter/pshglob.c
@@ -5,7 +5,7 @@
/* PostScript hinter global hinting management (body). */
/* Inspired by the new auto-hinter module. */
/* */
-/* Copyright 2001, 2002, 2003, 2004, 2006, 2010 by */
+/* Copyright 2001-2004, 2006, 2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used */
@@ -522,6 +522,28 @@
}
+ /* calculate the maximum height of given blue zones */
+ static FT_Short
+ psh_calc_max_height( FT_UInt num,
+ const FT_Short* values,
+ FT_Short cur_max )
+ {
+ FT_UInt count;
+
+
+ for ( count = 0; count < num; count += 2 )
+ {
+ FT_Short cur_height = values[count + 1] - values[count];
+
+
+ if ( cur_height > cur_max )
+ cur_max = cur_height;
+ }
+
+ return cur_max;
+ }
+
+
FT_LOCAL_DEF( void )
psh_blues_snap_stem( PSH_Blues blues,
FT_Int stem_top,
@@ -684,7 +706,32 @@
priv->family_blues, priv->num_family_other_blues,
priv->family_other_blues, priv->blue_fuzz, 1 );
- globals->blues.blue_scale = priv->blue_scale;
+ /* limit the BlueScale value to `1 / max_of_blue_zone_heights' */
+ {
+ FT_Fixed max_scale;
+ FT_Short max_height = 1;
+
+
+ max_height = psh_calc_max_height( priv->num_blue_values,
+ priv->blue_values,
+ max_height );
+ max_height = psh_calc_max_height( priv->num_other_blues,
+ priv->other_blues,
+ max_height );
+ max_height = psh_calc_max_height( priv->num_family_blues,
+ priv->family_blues,
+ max_height );
+ max_height = psh_calc_max_height( priv->num_family_other_blues,
+ priv->family_other_blues,
+ max_height );
+
+ /* BlueScale is scaled 1000 times */
+ max_scale = FT_DivFix( 1000, max_height );
+ globals->blues.blue_scale = priv->blue_scale < max_scale
+ ? priv->blue_scale
+ : max_scale;
+ }
+
globals->blues.blue_shift = priv->blue_shift;
globals->blues.blue_fuzz = priv->blue_fuzz;
diff --git a/3party/freetype/src/pshinter/pshmod.c b/3party/freetype/src/pshinter/pshmod.c
index 91da5d7e6b..cdeaca18c9 100644
--- a/3party/freetype/src/pshinter/pshmod.c
+++ b/3party/freetype/src/pshinter/pshmod.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PostScript hinter module implementation (body). */
/* */
-/* Copyright 2001, 2002, 2007 by */
+/* Copyright 2001, 2002, 2007, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -93,14 +93,15 @@
}
- FT_DEFINE_PSHINTER_INTERFACE(pshinter_interface,
+ FT_DEFINE_PSHINTER_INTERFACE(
+ pshinter_interface,
pshinter_get_globals_funcs,
pshinter_get_t1_funcs,
- pshinter_get_t2_funcs
- )
+ pshinter_get_t2_funcs )
- FT_DEFINE_MODULE(pshinter_module_class,
+ FT_DEFINE_MODULE(
+ pshinter_module_class,
0,
sizeof ( PS_Hinter_ModuleRec ),
@@ -108,11 +109,11 @@
0x10000L,
0x20000L,
- &FTPSHINTER_INTERFACE_GET, /* module-specific interface */
+ &PSHINTER_INTERFACE_GET, /* module-specific interface */
(FT_Module_Constructor)ps_hinter_init,
(FT_Module_Destructor) ps_hinter_done,
- (FT_Module_Requester) 0 /* no additional interface for now */
- )
+ (FT_Module_Requester) NULL ) /* no additional interface for now */
+
/* END */
diff --git a/3party/freetype/src/pshinter/pshnterr.h b/3party/freetype/src/pshinter/pshnterr.h
index 3c0029fbf3..7cc180f0ca 100644
--- a/3party/freetype/src/pshinter/pshnterr.h
+++ b/3party/freetype/src/pshinter/pshnterr.h
@@ -4,7 +4,7 @@
/* */
/* PS Hinter error codes (specification only). */
/* */
-/* Copyright 2003 by */
+/* Copyright 2003, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX PSH_Err_
#define FT_ERR_BASE FT_Mod_Err_PShinter
diff --git a/3party/freetype/src/pshinter/pshpic.c b/3party/freetype/src/pshinter/pshpic.c
index 5efb422948..bf7f2009d3 100644
--- a/3party/freetype/src/pshinter/pshpic.c
+++ b/3party/freetype/src/pshinter/pshpic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for pshinter module. */
/* */
-/* Copyright 2009, 2010 by */
+/* Copyright 2009, 2010, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,17 +20,23 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include "pshpic.h"
+#include "pshnterr.h"
+
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from pshmod.c */
- void FT_Init_Class_pshinter_interface( FT_Library, PSHinter_Interface*);
+ void
+ FT_Init_Class_pshinter_interface( FT_Library library,
+ PSHinter_Interface* clazz );
void
- pshinter_module_class_pic_free( FT_Library library )
+ pshinter_module_class_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->pshinter )
{
FT_FREE( pic_container->pshinter );
@@ -44,7 +50,7 @@
{
FT_PIC_Container* pic_container = &library->pic_container;
FT_Error error = PSH_Err_Ok;
- PSHinterPIC* container;
+ PSHinterPIC* container = NULL;
FT_Memory memory = library->memory;
@@ -53,17 +59,17 @@
return error;
FT_MEM_SET( container, 0, sizeof ( *container ) );
pic_container->pshinter = container;
-
+
/* add call to initialization function when you add new scripts */
- FT_Init_Class_pshinter_interface(library, &container->pshinter_interface);
+ FT_Init_Class_pshinter_interface(
+ library, &container->pshinter_interface );
-/*Exit:*/
- if(error)
- pshinter_module_class_pic_free(library);
+ if( error )
+ pshinter_module_class_pic_free( library );
return error;
}
-
#endif /* FT_CONFIG_OPTION_PIC */
+
/* END */
diff --git a/3party/freetype/src/pshinter/pshpic.h b/3party/freetype/src/pshinter/pshpic.h
index 3555d8e851..62abf322cc 100644
--- a/3party/freetype/src/pshinter/pshpic.h
+++ b/3party/freetype/src/pshinter/pshpic.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for pshinter module. */
/* */
-/* Copyright 2009 by */
+/* Copyright 2009, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,27 +19,37 @@
#ifndef __PSHPIC_H__
#define __PSHPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FTPSHINTER_INTERFACE_GET pshinter_interface
+#define PSHINTER_INTERFACE_GET pshinter_interface
#else /* FT_CONFIG_OPTION_PIC */
#include FT_INTERNAL_POSTSCRIPT_HINTS_H
- typedef struct PSHinterPIC_
+ typedef struct PSHinterPIC_
{
- PSHinter_Interface pshinter_interface;
+ PSHinter_Interface pshinter_interface;
+
} PSHinterPIC;
-#define GET_PIC(lib) ((PSHinterPIC*)((lib)->pic_container.autofit))
-#define FTPSHINTER_INTERFACE_GET (GET_PIC(library)->pshinter_interface)
+#define GET_PIC( lib ) ( (PSHinterPIC*)((lib)->pic_container.autofit) )
+
+#define PSHINTER_INTERFACE_GET ( GET_PIC( library )->pshinter_interface )
+
+ /* see pshpic.c for the implementation */
+ void
+ pshinter_module_class_pic_free( FT_Library library );
+
+ FT_Error
+ pshinter_module_class_pic_init( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/psnames/psmodule.c b/3party/freetype/src/psnames/psmodule.c
index 7528696938..cae60ef47c 100644
--- a/3party/freetype/src/psnames/psmodule.c
+++ b/3party/freetype/src/psnames/psmodule.c
@@ -4,7 +4,7 @@
/* */
/* PSNames module implementation (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2003, 2005-2008, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -521,7 +521,9 @@
#ifdef FT_CONFIG_OPTION_ADOBE_GLYPH_LIST
- FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface,
+
+ FT_DEFINE_SERVICE_PSCMAPSREC(
+ pscmaps_interface,
(PS_Unicode_ValueFunc) ps_unicode_value,
(PS_Unicodes_InitFunc) ps_unicodes_init,
(PS_Unicodes_CharIndexFunc)ps_unicodes_char_index,
@@ -531,54 +533,64 @@
(PS_Adobe_Std_StringsFunc) ps_get_standard_strings,
t1_standard_encoding,
- t1_expert_encoding
- )
+ t1_expert_encoding )
#else
- FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface,
- 0,
- 0,
- 0,
- 0,
+ FT_DEFINE_SERVICE_PSCMAPSREC(
+ pscmaps_interface,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
(PS_Macintosh_NameFunc) ps_get_macintosh_name,
(PS_Adobe_Std_StringsFunc) ps_get_standard_strings,
t1_standard_encoding,
- t1_expert_encoding
- )
+ t1_expert_encoding )
#endif /* FT_CONFIG_OPTION_ADOBE_GLYPH_LIST */
- FT_DEFINE_SERVICEDESCREC1(pscmaps_services,
- FT_SERVICE_ID_POSTSCRIPT_CMAPS, &FT_PSCMAPS_INTERFACE_GET
- )
-
-
+ FT_DEFINE_SERVICEDESCREC1(
+ pscmaps_services,
+ FT_SERVICE_ID_POSTSCRIPT_CMAPS, &PSCMAPS_INTERFACE_GET )
static FT_Pointer
psnames_get_service( FT_Module module,
const char* service_id )
{
+ /* PSCMAPS_SERVICES_GET derefers `library' in PIC mode */
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_Library library;
+
+
+ if ( !module )
+ return NULL;
+ library = module->library;
+ if ( !library )
+ return NULL;
+#else
FT_UNUSED( module );
+#endif
- return ft_service_list_lookup( FT_PSCMAPS_SERVICES_GET, service_id );
+ return ft_service_list_lookup( PSCMAPS_SERVICES_GET, service_id );
}
#endif /* FT_CONFIG_OPTION_POSTSCRIPT_NAMES */
#ifndef FT_CONFIG_OPTION_POSTSCRIPT_NAMES
-#define PUT_PS_NAMES_SERVICE(a) 0
+#define PUT_PS_NAMES_SERVICE( a ) NULL
#else
-#define PUT_PS_NAMES_SERVICE(a) a
+#define PUT_PS_NAMES_SERVICE( a ) a
#endif
- FT_DEFINE_MODULE(psnames_module_class,
-
+ FT_DEFINE_MODULE(
+ psnames_module_class,
+
0, /* this is not a font driver, nor a renderer */
sizeof ( FT_ModuleRec ),
@@ -586,12 +598,11 @@
0x10000L, /* driver version */
0x20000L, /* driver requires FreeType 2 or above */
- PUT_PS_NAMES_SERVICE((void*)&FT_PSCMAPS_INTERFACE_GET), /* module specific interface */
- (FT_Module_Constructor)0,
- (FT_Module_Destructor) 0,
- (FT_Module_Requester) PUT_PS_NAMES_SERVICE(psnames_get_service)
- )
-
+ PUT_PS_NAMES_SERVICE(
+ (void*)&PSCMAPS_INTERFACE_GET ), /* module specific interface */
+ (FT_Module_Constructor)NULL,
+ (FT_Module_Destructor) NULL,
+ (FT_Module_Requester) PUT_PS_NAMES_SERVICE( psnames_get_service ) )
/* END */
diff --git a/3party/freetype/src/psnames/psnamerr.h b/3party/freetype/src/psnames/psnamerr.h
index ae1541d960..acda7f967e 100644
--- a/3party/freetype/src/psnames/psnamerr.h
+++ b/3party/freetype/src/psnames/psnamerr.h
@@ -4,7 +4,7 @@
/* */
/* PS names module error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX PSnames_Err_
#define FT_ERR_BASE FT_Mod_Err_PSnames
diff --git a/3party/freetype/src/psnames/pspic.c b/3party/freetype/src/psnames/pspic.c
index b9075d5a5a..dc5374b0b8 100644
--- a/3party/freetype/src/psnames/pspic.c
+++ b/3party/freetype/src/psnames/pspic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for psnames module. */
/* */
-/* Copyright 2009, 2010 by */
+/* Copyright 2009, 2010, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,24 +20,39 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include "pspic.h"
+#include "psnamerr.h"
+
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from psmodule.c */
- FT_Error FT_Create_Class_pscmaps_services( FT_Library, FT_ServiceDescRec**);
- void FT_Destroy_Class_pscmaps_services( FT_Library, FT_ServiceDescRec*);
- void FT_Init_Class_pscmaps_interface( FT_Library, FT_Service_PsCMapsRec*);
+ FT_Error
+ FT_Create_Class_pscmaps_services( FT_Library library,
+ FT_ServiceDescRec** output_class );
+ void
+ FT_Destroy_Class_pscmaps_services( FT_Library library,
+ FT_ServiceDescRec* clazz );
void
- psnames_module_class_pic_free( FT_Library library )
+ FT_Init_Class_pscmaps_interface( FT_Library library,
+ FT_Service_PsCMapsRec* clazz );
+
+
+ void
+ psnames_module_class_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->psnames )
{
- PSModulePIC* container = (PSModulePIC*)pic_container->psnames;
- if(container->pscmaps_services)
- FT_Destroy_Class_pscmaps_services(library, container->pscmaps_services);
+ PSModulePIC* container = (PSModulePIC*)pic_container->psnames;
+
+
+ if ( container->pscmaps_services )
+ FT_Destroy_Class_pscmaps_services( library,
+ container->pscmaps_services );
container->pscmaps_services = NULL;
FT_FREE( container );
pic_container->psnames = NULL;
@@ -50,25 +65,28 @@
{
FT_PIC_Container* pic_container = &library->pic_container;
FT_Error error = PSnames_Err_Ok;
- PSModulePIC* container;
+ PSModulePIC* container = NULL;
FT_Memory memory = library->memory;
/* allocate pointer, clear and set global container pointer */
if ( FT_ALLOC ( container, sizeof ( *container ) ) )
return error;
- FT_MEM_SET( container, 0, sizeof(*container) );
+ FT_MEM_SET( container, 0, sizeof ( *container ) );
pic_container->psnames = container;
- /* initialize pointer table - this is how the module usually expects this data */
- error = FT_Create_Class_pscmaps_services(library, &container->pscmaps_services);
- if(error)
+ /* initialize pointer table - */
+ /* this is how the module usually expects this data */
+ error = FT_Create_Class_pscmaps_services(
+ library, &container->pscmaps_services );
+ if ( error )
goto Exit;
- FT_Init_Class_pscmaps_interface(library, &container->pscmaps_interface);
-
-Exit:
- if(error)
- psnames_module_class_pic_free(library);
+ FT_Init_Class_pscmaps_interface( library,
+ &container->pscmaps_interface );
+
+ Exit:
+ if ( error )
+ psnames_module_class_pic_free( library );
return error;
}
diff --git a/3party/freetype/src/psnames/pspic.h b/3party/freetype/src/psnames/pspic.h
index 75a14fdcb9..6ff002c603 100644
--- a/3party/freetype/src/psnames/pspic.h
+++ b/3party/freetype/src/psnames/pspic.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for psnames module. */
/* */
-/* Copyright 2009 by */
+/* Copyright 2009, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,28 +19,40 @@
#ifndef __PSPIC_H__
#define __PSPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_PSCMAPS_SERVICES_GET pscmaps_services
-#define FT_PSCMAPS_INTERFACE_GET pscmaps_interface
+
+#define PSCMAPS_SERVICES_GET pscmaps_services
+#define PSCMAPS_INTERFACE_GET pscmaps_interface
#else /* FT_CONFIG_OPTION_PIC */
#include FT_SERVICE_POSTSCRIPT_CMAPS_H
- typedef struct PSModulePIC_
+ typedef struct PSModulePIC_
{
- FT_ServiceDescRec* pscmaps_services;
- FT_Service_PsCMapsRec pscmaps_interface;
+ FT_ServiceDescRec* pscmaps_services;
+ FT_Service_PsCMapsRec pscmaps_interface;
+
} PSModulePIC;
-#define GET_PIC(lib) ((PSModulePIC*)((lib)->pic_container.psnames))
-#define FT_PSCMAPS_SERVICES_GET (GET_PIC(library)->pscmaps_services)
-#define FT_PSCMAPS_INTERFACE_GET (GET_PIC(library)->pscmaps_interface)
+
+#define GET_PIC( lib ) \
+ ( (PSModulePIC*)((lib)->pic_container.psnames) )
+#define PSCMAPS_SERVICES_GET ( GET_PIC( library )->pscmaps_services )
+#define PSCMAPS_INTERFACE_GET ( GET_PIC( library )->pscmaps_interface )
+
+
+ /* see pspic.c for the implementation */
+ void
+ psnames_module_class_pic_free( FT_Library library );
+
+ FT_Error
+ psnames_module_class_pic_init( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/raster/ftmisc.h b/3party/freetype/src/raster/ftmisc.h
index 7773924feb..703155a429 100644
--- a/3party/freetype/src/raster/ftmisc.h
+++ b/3party/freetype/src/raster/ftmisc.h
@@ -115,6 +115,27 @@
return ( s > 0 ) ? d : -d;
}
+
+ static FT_Long
+ FT_MulDiv_No_Round( FT_Long a,
+ FT_Long b,
+ FT_Long c )
+ {
+ FT_Int s;
+ FT_Long d;
+
+
+ s = 1;
+ if ( a < 0 ) { a = -a; s = -1; }
+ if ( b < 0 ) { b = -b; s = -s; }
+ if ( c < 0 ) { c = -c; s = -s; }
+
+ d = (FT_Long)( c > 0 ? (FT_Int64)a * b / c
+ : 0x7FFFFFFFL );
+
+ return ( s > 0 ) ? d : -d;
+ }
+
#endif /* __FTMISC_H__ */
diff --git a/3party/freetype/src/raster/ftraster.c b/3party/freetype/src/raster/ftraster.c
index 55e2d0d75a..7d5bcaef56 100644
--- a/3party/freetype/src/raster/ftraster.c
+++ b/3party/freetype/src/raster/ftraster.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType glyph rasterizer (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2005, 2007, 2008, 2009, 2010, 2011 by */
+/* Copyright 1996-2003, 2005, 2007-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -60,7 +60,7 @@
#include <ft2build.h>
#include "ftraster.h"
-#include FT_INTERNAL_CALC_H /* for FT_MulDiv only */
+#include FT_INTERNAL_CALC_H /* for FT_MulDiv and FT_MulDiv_No_Round */
#include "rastpic.h"
@@ -255,7 +255,8 @@
/* On the other hand, SMulDiv means `Slow MulDiv', and is used typically */
/* for clipping computations. It simply uses the FT_MulDiv() function */
/* defined in `ftcalc.h'. */
-#define SMulDiv FT_MulDiv
+#define SMulDiv FT_MulDiv
+#define SMulDiv_No_Round FT_MulDiv_No_Round
/* The rasterizer is a very general purpose component; please leave */
/* the following redefinitions there (you never know your target */
@@ -369,18 +370,23 @@
/* Simple record used to implement a stack of bands, required */
/* by the sub-banding mechanism */
- typedef struct TBand_
+ typedef struct black_TBand_
{
Short y_min; /* band's minimum */
Short y_max; /* band's maximum */
- } TBand;
+ } black_TBand;
#define AlignProfileSize \
( ( sizeof ( TProfile ) + sizeof ( Alignment ) - 1 ) / sizeof ( long ) )
+#undef RAS_ARG
+#undef RAS_ARGS
+#undef RAS_VAR
+#undef RAS_VARS
+
#ifdef FT_STATIC_RASTER
@@ -396,8 +402,8 @@
#else /* !FT_STATIC_RASTER */
-#define RAS_ARGS PWorker worker,
-#define RAS_ARG PWorker worker
+#define RAS_ARGS black_PWorker worker,
+#define RAS_ARG black_PWorker worker
#define RAS_VARS worker,
#define RAS_VAR worker
@@ -408,7 +414,7 @@
#endif /* !FT_STATIC_RASTER */
- typedef struct TWorker_ TWorker, *PWorker;
+ typedef struct black_TWorker_ black_TWorker, *black_PWorker;
/* prototypes used for sweep function dispatch */
@@ -428,6 +434,10 @@
/* NOTE: These operations are only valid on 2's complement processors */
+#undef FLOOR
+#undef CEILING
+#undef TRUNC
+#undef SCALED
#define FLOOR( x ) ( (x) & -ras.precision )
#define CEILING( x ) ( ( (x) + ras.precision - 1 ) & -ras.precision )
@@ -442,7 +452,7 @@
/* Thus, their offset can be coded with less opcodes, resulting in a */
/* smaller executable. */
- struct TWorker_
+ struct black_TWorker_
{
Int precision_bits; /* precision related variables */
Int precision;
@@ -515,8 +525,8 @@
TPoint arcs[3 * MaxBezier + 1]; /* The Bezier stack */
- TBand band_stack[16]; /* band stack used for sub-banding */
- Int band_top; /* band stack top */
+ black_TBand band_stack[16]; /* band stack used for sub-banding */
+ Int band_top; /* band stack top */
#ifdef FT_RASTER_OPTION_ANTI_ALIASING
@@ -540,20 +550,20 @@
};
- typedef struct TRaster_
+ typedef struct black_TRaster_
{
- char* buffer;
- long buffer_size;
- void* memory;
- PWorker worker;
- Byte grays[5];
- Short gray_width;
+ char* buffer;
+ long buffer_size;
+ void* memory;
+ black_PWorker worker;
+ Byte grays[5];
+ Short gray_width;
- } TRaster, *PRaster;
+ } black_TRaster, *black_PRaster;
#ifdef FT_STATIC_RASTER
- static TWorker cur_ras;
+ static black_TWorker cur_ras;
#define ras cur_ras
#else /* !FT_STATIC_RASTER */
@@ -1141,14 +1151,14 @@
if ( Dx > 0 )
{
- Ix = SMulDiv( ras.precision, Dx, Dy);
+ Ix = SMulDiv_No_Round( ras.precision, Dx, Dy );
Rx = ( ras.precision * Dx ) % Dy;
Dx = 1;
}
else
{
- Ix = SMulDiv( ras.precision, -Dx, Dy) * -1;
- Rx = ( ras.precision * -Dx ) % Dy;
+ Ix = -SMulDiv_No_Round( ras.precision, -Dx, Dy );
+ Rx = ( ras.precision * -Dx ) % Dy;
Dx = -1;
}
@@ -3391,7 +3401,7 @@
static void
- ft_black_init( PRaster raster )
+ ft_black_init( black_PRaster raster )
{
#ifdef FT_RASTER_OPTION_ANTI_ALIASING
FT_UInt n;
@@ -3419,7 +3429,7 @@
ft_black_new( void* memory,
FT_Raster *araster )
{
- static TRaster the_raster;
+ static black_TRaster the_raster;
FT_UNUSED( memory );
@@ -3443,11 +3453,11 @@
static int
- ft_black_new( FT_Memory memory,
- PRaster *araster )
+ ft_black_new( FT_Memory memory,
+ black_PRaster *araster )
{
- FT_Error error;
- PRaster raster = NULL;
+ FT_Error error;
+ black_PRaster raster = NULL;
*araster = 0;
@@ -3464,9 +3474,11 @@
static void
- ft_black_done( PRaster raster )
+ ft_black_done( black_PRaster raster )
{
FT_Memory memory = (FT_Memory)raster->memory;
+
+
FT_FREE( raster );
}
@@ -3475,15 +3487,15 @@
static void
- ft_black_reset( PRaster raster,
- char* pool_base,
- long pool_size )
+ ft_black_reset( black_PRaster raster,
+ char* pool_base,
+ long pool_size )
{
if ( raster )
{
- if ( pool_base && pool_size >= (long)sizeof(TWorker) + 2048 )
+ if ( pool_base && pool_size >= (long)sizeof ( black_TWorker ) + 2048 )
{
- PWorker worker = (PWorker)pool_base;
+ black_PWorker worker = (black_PWorker)pool_base;
raster->buffer = pool_base + ( ( sizeof ( *worker ) + 7 ) & ~7 );
@@ -3501,7 +3513,7 @@
static void
- ft_black_set_mode( PRaster raster,
+ ft_black_set_mode( black_PRaster raster,
unsigned long mode,
const char* palette )
{
@@ -3528,12 +3540,12 @@
static int
- ft_black_render( PRaster raster,
+ ft_black_render( black_PRaster raster,
const FT_Raster_Params* params )
{
const FT_Outline* outline = (const FT_Outline*)params->source;
const FT_Bitmap* target_map = params->target;
- PWorker worker;
+ black_PWorker worker;
if ( !raster || !raster->buffer || !raster->buffer_size )
diff --git a/3party/freetype/src/raster/ftrend1.c b/3party/freetype/src/raster/ftrend1.c
index 28b1b58971..859cb7d864 100644
--- a/3party/freetype/src/raster/ftrend1.c
+++ b/3party/freetype/src/raster/ftrend1.c
@@ -244,10 +244,10 @@
}
- FT_DEFINE_RENDERER(ft_raster1_renderer_class,
-
+ FT_DEFINE_RENDERER( ft_raster1_renderer_class,
+
FT_MODULE_RENDERER,
- sizeof( FT_RendererRec ),
+ sizeof ( FT_RendererRec ),
"raster1",
0x10000L,
@@ -275,11 +275,10 @@
/* to register it by hand in your application. It should only be */
/* used for backwards-compatibility with FT 1.x anyway. */
/* */
- FT_DEFINE_RENDERER(ft_raster5_renderer_class,
-
-
+ FT_DEFINE_RENDERER( ft_raster5_renderer_class,
+
FT_MODULE_RENDERER,
- sizeof( FT_RendererRec ),
+ sizeof ( FT_RendererRec ),
"raster5",
0x10000L,
diff --git a/3party/freetype/src/raster/rasterrs.h b/3party/freetype/src/raster/rasterrs.h
index 5df9a7ab1e..ab85c002a3 100644
--- a/3party/freetype/src/raster/rasterrs.h
+++ b/3party/freetype/src/raster/rasterrs.h
@@ -4,7 +4,7 @@
/* */
/* monochrome renderer error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX Raster_Err_
#define FT_ERR_BASE FT_Mod_Err_Raster
diff --git a/3party/freetype/src/raster/rastpic.c b/3party/freetype/src/raster/rastpic.c
index e31c549763..853286309e 100644
--- a/3party/freetype/src/raster/rastpic.c
+++ b/3party/freetype/src/raster/rastpic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for raster module. */
/* */
-/* Copyright 2009, 2010 by */
+/* Copyright 2009, 2010, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,21 +20,25 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include "rastpic.h"
+#include "rasterrs.h"
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from ftraster.c */
- void FT_Init_Class_ft_standard_raster(FT_Raster_Funcs*);
+ void
+ FT_Init_Class_ft_standard_raster( FT_Raster_Funcs* funcs );
void
- ft_raster1_renderer_class_pic_free( FT_Library library )
+ ft_raster1_renderer_class_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->raster )
{
RasterPIC* container = (RasterPIC*)pic_container->raster;
- if(--container->ref_count)
+ if ( --container->ref_count )
return;
FT_FREE( container );
pic_container->raster = NULL;
@@ -43,15 +47,15 @@
FT_Error
- ft_raster1_renderer_class_pic_init( FT_Library library )
+ ft_raster1_renderer_class_pic_init( FT_Library library )
{
FT_PIC_Container* pic_container = &library->pic_container;
FT_Error error = Raster_Err_Ok;
- RasterPIC* container;
+ RasterPIC* container = NULL;
FT_Memory memory = library->memory;
- /* since this function also serve raster5 renderer,
+ /* since this function also serve raster5 renderer,
it implements reference counting */
if ( pic_container->raster )
{
@@ -60,28 +64,31 @@
}
/* allocate pointer, clear and set global container pointer */
- if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ if ( FT_ALLOC( container, sizeof ( *container ) ) )
return error;
- FT_MEM_SET( container, 0, sizeof(*container) );
+ FT_MEM_SET( container, 0, sizeof ( *container ) );
pic_container->raster = container;
container->ref_count = 1;
/* initialize pointer table - this is how the module usually expects this data */
- FT_Init_Class_ft_standard_raster(&container->ft_standard_raster);
+ FT_Init_Class_ft_standard_raster( &container->ft_standard_raster );
/*Exit:*/
- if(error)
- ft_raster1_renderer_class_pic_free(library);
+ if( error )
+ ft_raster1_renderer_class_pic_free( library );
return error;
}
/* re-route these init and free functions to the above functions */
- FT_Error ft_raster5_renderer_class_pic_init(FT_Library library)
+ FT_Error
+ ft_raster5_renderer_class_pic_init( FT_Library library )
{
- return ft_raster1_renderer_class_pic_init(library);
+ return ft_raster1_renderer_class_pic_init( library );
}
- void ft_raster5_renderer_class_pic_free(FT_Library library)
+
+ void
+ ft_raster5_renderer_class_pic_free( FT_Library library )
{
- ft_raster1_renderer_class_pic_free(library);
+ ft_raster1_renderer_class_pic_free( library );
}
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/raster/rastpic.h b/3party/freetype/src/raster/rastpic.h
index dcd82b8ca8..7822a24b48 100644
--- a/3party/freetype/src/raster/rastpic.h
+++ b/3party/freetype/src/raster/rastpic.h
@@ -19,7 +19,7 @@
#ifndef __RASTPIC_H__
#define __RASTPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
@@ -38,6 +38,19 @@ FT_BEGIN_HEADER
#define GET_PIC(lib) ((RasterPIC*)((lib)->pic_container.raster))
#define FT_STANDARD_RASTER_GET (GET_PIC(library)->ft_standard_raster)
+ /* see rastpic.c for the implementation */
+ void
+ ft_raster1_renderer_class_pic_free( FT_Library library );
+
+ void
+ ft_raster5_renderer_class_pic_free( FT_Library library );
+
+ FT_Error
+ ft_raster1_renderer_class_pic_init( FT_Library library );
+
+ FT_Error
+ ft_raster5_renderer_class_pic_init( FT_Library library );
+
#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/src/sfnt/sfdriver.c b/3party/freetype/src/sfnt/sfdriver.c
index 247aa67998..2b7f80fc93 100644
--- a/3party/freetype/src/sfnt/sfdriver.c
+++ b/3party/freetype/src/sfnt/sfdriver.c
@@ -4,7 +4,7 @@
/* */
/* High-level SFNT driver interface (body). */
/* */
-/* Copyright 1996-2007, 2009-2011 by */
+/* Copyright 1996-2007, 2009-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -50,6 +50,7 @@
#include FT_SERVICE_SFNT_H
#include FT_SERVICE_TT_CMAP_H
+
/*************************************************************************/
/* */
/* The macro FT_COMPONENT is used in trace mode. It is an implicit */
@@ -60,10 +61,10 @@
#define FT_COMPONENT trace_sfdriver
- /*
- * SFNT TABLE SERVICE
- *
- */
+ /*
+ * SFNT TABLE SERVICE
+ *
+ */
static void*
get_sfnt_table( TT_Face face,
@@ -136,19 +137,19 @@
}
- FT_DEFINE_SERVICE_SFNT_TABLEREC(sfnt_service_sfnt_table,
+ FT_DEFINE_SERVICE_SFNT_TABLEREC(
+ sfnt_service_sfnt_table,
(FT_SFNT_TableLoadFunc)tt_face_load_any,
(FT_SFNT_TableGetFunc) get_sfnt_table,
- (FT_SFNT_TableInfoFunc)sfnt_table_info
- )
+ (FT_SFNT_TableInfoFunc)sfnt_table_info )
#ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
- /*
- * GLYPH DICT SERVICE
- *
- */
+ /*
+ * GLYPH DICT SERVICE
+ *
+ */
static FT_Error
sfnt_get_glyph_name( TT_Face face,
@@ -172,17 +173,18 @@
sfnt_get_name_index( TT_Face face,
FT_String* glyph_name )
{
- FT_Face root = &face->root;
- FT_UInt i, max_gid = FT_UINT_MAX;
+ FT_Face root = &face->root;
+
+ FT_UInt i, max_gid = FT_UINT_MAX;
if ( root->num_glyphs < 0 )
return 0;
- else if ( ( FT_ULong ) root->num_glyphs < FT_UINT_MAX )
- max_gid = ( FT_UInt ) root->num_glyphs;
+ else if ( (FT_ULong)root->num_glyphs < FT_UINT_MAX )
+ max_gid = (FT_UInt)root->num_glyphs;
else
FT_TRACE0(( "Ignore glyph names for invalid GID 0x%08x - 0x%08x\n",
- FT_UINT_MAX, root->num_glyphs ));
+ FT_UINT_MAX, root->num_glyphs ));
for ( i = 0; i < max_gid; i++ )
{
@@ -201,18 +203,19 @@
}
- FT_DEFINE_SERVICE_GLYPHDICTREC(sfnt_service_glyph_dict,
+ FT_DEFINE_SERVICE_GLYPHDICTREC(
+ sfnt_service_glyph_dict,
(FT_GlyphDict_GetNameFunc) sfnt_get_glyph_name,
- (FT_GlyphDict_NameIndexFunc)sfnt_get_name_index
- )
+ (FT_GlyphDict_NameIndexFunc)sfnt_get_name_index )
+
#endif /* TT_CONFIG_OPTION_POSTSCRIPT_NAMES */
- /*
- * POSTSCRIPT NAME SERVICE
- *
- */
+ /*
+ * POSTSCRIPT NAME SERVICE
+ *
+ */
static const char*
sfnt_get_ps_name( TT_Face face )
@@ -324,17 +327,18 @@
return result;
}
- FT_DEFINE_SERVICE_PSFONTNAMEREC(sfnt_service_ps_name,
- (FT_PsName_GetFunc)sfnt_get_ps_name
- )
+
+ FT_DEFINE_SERVICE_PSFONTNAMEREC(
+ sfnt_service_ps_name,
+ (FT_PsName_GetFunc)sfnt_get_ps_name )
/*
* TT CMAP INFO
*/
- FT_DEFINE_SERVICE_TTCMAPSREC(tt_service_get_cmap_info,
- (TT_CMap_Info_GetFunc)tt_get_cmap_info
- )
+ FT_DEFINE_SERVICE_TTCMAPSREC(
+ tt_service_get_cmap_info,
+ (TT_CMap_Info_GetFunc)tt_get_cmap_info )
#ifdef TT_CONFIG_OPTION_BDF
@@ -375,10 +379,11 @@
}
- FT_DEFINE_SERVICE_BDFRec(sfnt_service_bdf,
- (FT_BDF_GetCharsetIdFunc) sfnt_get_charset_id,
- (FT_BDF_GetPropertyFunc) tt_face_find_bdf_prop
- )
+ FT_DEFINE_SERVICE_BDFRec(
+ sfnt_service_bdf,
+ (FT_BDF_GetCharsetIdFunc)sfnt_get_charset_id,
+ (FT_BDF_GetPropertyFunc) tt_face_find_bdf_prop )
+
#endif /* TT_CONFIG_OPTION_BDF */
@@ -388,33 +393,33 @@
*/
#if defined TT_CONFIG_OPTION_POSTSCRIPT_NAMES && defined TT_CONFIG_OPTION_BDF
- FT_DEFINE_SERVICEDESCREC5(sfnt_services,
- FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
- FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
- FT_SERVICE_ID_GLYPH_DICT, &FT_SFNT_SERVICE_GLYPH_DICT_GET,
- FT_SERVICE_ID_BDF, &FT_SFNT_SERVICE_BDF_GET,
- FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
- )
+ FT_DEFINE_SERVICEDESCREC5(
+ sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_GLYPH_DICT, &SFNT_SERVICE_GLYPH_DICT_GET,
+ FT_SERVICE_ID_BDF, &SFNT_SERVICE_BDF_GET,
+ FT_SERVICE_ID_TT_CMAP, &TT_SERVICE_CMAP_INFO_GET )
#elif defined TT_CONFIG_OPTION_POSTSCRIPT_NAMES
- FT_DEFINE_SERVICEDESCREC4(sfnt_services,
- FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
- FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
- FT_SERVICE_ID_GLYPH_DICT, &FT_SFNT_SERVICE_GLYPH_DICT_GET,
- FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
- )
+ FT_DEFINE_SERVICEDESCREC4(
+ sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_GLYPH_DICT, &SFNT_SERVICE_GLYPH_DICT_GET,
+ FT_SERVICE_ID_TT_CMAP, &TT_SERVICE_CMAP_INFO_GET )
#elif defined TT_CONFIG_OPTION_BDF
- FT_DEFINE_SERVICEDESCREC4(sfnt_services,
- FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
- FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
- FT_SERVICE_ID_BDF, &FT_SFNT_SERVICE_BDF_GET,
- FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
- )
+ FT_DEFINE_SERVICEDESCREC4(
+ sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_BDF, &SFNT_SERVICE_BDF_GET,
+ FT_SERVICE_ID_TT_CMAP, &TT_SERVICE_CMAP_INFO_GET )
#else
- FT_DEFINE_SERVICEDESCREC3(sfnt_services,
- FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
- FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
- FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
- )
+ FT_DEFINE_SERVICEDESCREC3(
+ sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_TT_CMAP, &TT_SERVICE_CMAP_INFO_GET )
#endif
@@ -422,9 +427,21 @@
sfnt_get_interface( FT_Module module,
const char* module_interface )
{
+ /* SFNT_SERVICES_GET derefers `library' in PIC mode */
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_Library library;
+
+
+ if ( !module )
+ return NULL;
+ library = module->library;
+ if ( !library )
+ return NULL;
+#else
FT_UNUSED( module );
+#endif
- return ft_service_list_lookup( FT_SFNT_SERVICES_GET, module_interface );
+ return ft_service_list_lookup( SFNT_SERVICES_GET, module_interface );
}
@@ -555,18 +572,21 @@
#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */
+
#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
-#define PUT_EMBEDDED_BITMAPS(a) a
+#define PUT_EMBEDDED_BITMAPS( a ) a
#else
-#define PUT_EMBEDDED_BITMAPS(a) 0
+#define PUT_EMBEDDED_BITMAPS( a ) NULL
#endif
+
#ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
-#define PUT_PS_NAMES(a) a
+#define PUT_PS_NAMES( a ) a
#else
-#define PUT_PS_NAMES(a) 0
+#define PUT_PS_NAMES( a ) NULL
#endif
- FT_DEFINE_SFNT_INTERFACE(sfnt_interface,
+ FT_DEFINE_SFNT_INTERFACE(
+ sfnt_interface,
tt_face_goto_table,
sfnt_init_face,
@@ -577,7 +597,7 @@
tt_face_load_any,
tt_face_load_sfnt_header_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
- tt_face_load_directory_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_face_load_directory_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
tt_face_load_head,
tt_face_load_hhea,
@@ -597,21 +617,21 @@
tt_face_load_pclt,
/* see `ttload.h' */
- PUT_EMBEDDED_BITMAPS(tt_face_load_bhed),
+ PUT_EMBEDDED_BITMAPS( tt_face_load_bhed ),
tt_face_set_sbit_strike_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
- tt_face_load_sbit_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_face_load_sbit_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
- tt_find_sbit_image, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_find_sbit_image, /* FT_CONFIG_OPTION_OLD_INTERNALS */
tt_load_sbit_metrics, /* FT_CONFIG_OPTION_OLD_INTERNALS */
- PUT_EMBEDDED_BITMAPS(tt_face_load_sbit_image),
+ PUT_EMBEDDED_BITMAPS( tt_face_load_sbit_image ),
tt_face_free_sbit_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
/* see `ttpost.h' */
- PUT_PS_NAMES(tt_face_get_ps_name),
- PUT_PS_NAMES(tt_face_free_ps_names),
+ PUT_PS_NAMES( tt_face_get_ps_name ),
+ PUT_PS_NAMES( tt_face_free_ps_names ),
tt_face_load_charmap_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
tt_face_free_charmap_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
@@ -626,31 +646,31 @@
tt_face_load_hmtx,
/* see `ttsbit.h' and `sfnt.h' */
- PUT_EMBEDDED_BITMAPS(tt_face_load_eblc),
- PUT_EMBEDDED_BITMAPS(tt_face_free_eblc),
+ PUT_EMBEDDED_BITMAPS( tt_face_load_eblc ),
+ PUT_EMBEDDED_BITMAPS( tt_face_free_eblc ),
- PUT_EMBEDDED_BITMAPS(tt_face_set_sbit_strike),
- PUT_EMBEDDED_BITMAPS(tt_face_load_strike_metrics),
+ PUT_EMBEDDED_BITMAPS( tt_face_set_sbit_strike ),
+ PUT_EMBEDDED_BITMAPS( tt_face_load_strike_metrics ),
tt_face_get_metrics
)
- FT_DEFINE_MODULE(sfnt_module_class,
-
+ FT_DEFINE_MODULE(
+ sfnt_module_class,
+
0, /* not a font driver or renderer */
- sizeof( FT_ModuleRec ),
+ sizeof ( FT_ModuleRec ),
"sfnt", /* driver name */
0x10000L, /* driver version 1.0 */
0x20000L, /* driver requires FreeType 2.0 or higher */
- (const void*)&FT_SFNT_INTERFACE_GET, /* module specific interface */
+ (const void*)&SFNT_INTERFACE_GET, /* module specific interface */
(FT_Module_Constructor)0,
(FT_Module_Destructor) 0,
- (FT_Module_Requester) sfnt_get_interface
- )
+ (FT_Module_Requester) sfnt_get_interface )
/* END */
diff --git a/3party/freetype/src/sfnt/sferrors.h b/3party/freetype/src/sfnt/sferrors.h
index 27f90de285..564a3fe394 100644
--- a/3party/freetype/src/sfnt/sferrors.h
+++ b/3party/freetype/src/sfnt/sferrors.h
@@ -4,7 +4,7 @@
/* */
/* SFNT error codes (specification only). */
/* */
-/* Copyright 2001, 2004 by */
+/* Copyright 2001, 2004, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX SFNT_Err_
#define FT_ERR_BASE FT_Mod_Err_SFNT
diff --git a/3party/freetype/src/sfnt/sfntpic.c b/3party/freetype/src/sfnt/sfntpic.c
index 53aca17b51..220998ecca 100644
--- a/3party/freetype/src/sfnt/sfntpic.c
+++ b/3party/freetype/src/sfnt/sfntpic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for sfnt module. */
/* */
-/* Copyright 2009, 2010 by */
+/* Copyright 2009, 2010, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,37 +20,78 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include "sfntpic.h"
+#include "sferrors.h"
+
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from sfdriver.c */
- FT_Error FT_Create_Class_sfnt_services( FT_Library, FT_ServiceDescRec**);
- void FT_Destroy_Class_sfnt_services( FT_Library, FT_ServiceDescRec*);
- void FT_Init_Class_sfnt_service_bdf( FT_Service_BDFRec*);
- void FT_Init_Class_sfnt_interface( FT_Library, SFNT_Interface*);
- void FT_Init_Class_sfnt_service_glyph_dict( FT_Library, FT_Service_GlyphDictRec*);
- void FT_Init_Class_sfnt_service_ps_name( FT_Library, FT_Service_PsFontNameRec*);
- void FT_Init_Class_tt_service_get_cmap_info( FT_Library, FT_Service_TTCMapsRec*);
- void FT_Init_Class_sfnt_service_sfnt_table( FT_Service_SFNT_TableRec*);
+ FT_Error
+ FT_Create_Class_sfnt_services( FT_Library library,
+ FT_ServiceDescRec** output_class );
+
+ void
+ FT_Destroy_Class_sfnt_services( FT_Library library,
+ FT_ServiceDescRec* clazz );
+
+ void
+ FT_Init_Class_sfnt_service_bdf( FT_Service_BDFRec* clazz );
+
+ void
+ FT_Init_Class_sfnt_interface( FT_Library library,
+ SFNT_Interface* clazz );
+
+ void
+ FT_Init_Class_sfnt_service_glyph_dict(
+ FT_Library library,
+ FT_Service_GlyphDictRec* clazz );
+
+ void
+ FT_Init_Class_sfnt_service_ps_name(
+ FT_Library library,
+ FT_Service_PsFontNameRec* clazz );
+
+ void
+ FT_Init_Class_tt_service_get_cmap_info(
+ FT_Library library,
+ FT_Service_TTCMapsRec* clazz );
+
+ void
+ FT_Init_Class_sfnt_service_sfnt_table(
+ FT_Service_SFNT_TableRec* clazz );
/* forward declaration of PIC init functions from ttcmap.c */
- FT_Error FT_Create_Class_tt_cmap_classes( FT_Library, TT_CMap_Class**);
- void FT_Destroy_Class_tt_cmap_classes( FT_Library, TT_CMap_Class*);
+ FT_Error
+ FT_Create_Class_tt_cmap_classes( FT_Library library,
+ TT_CMap_Class** output_class );
+
+ void
+ FT_Destroy_Class_tt_cmap_classes( FT_Library library,
+ TT_CMap_Class* clazz );
+
void
- sfnt_module_class_pic_free( FT_Library library )
+ sfnt_module_class_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->sfnt )
{
- sfntModulePIC* container = (sfntModulePIC*)pic_container->sfnt;
- if(container->sfnt_services)
- FT_Destroy_Class_sfnt_services(library, container->sfnt_services);
+ sfntModulePIC* container = (sfntModulePIC*)pic_container->sfnt;
+
+
+ if ( container->sfnt_services )
+ FT_Destroy_Class_sfnt_services( library,
+ container->sfnt_services );
container->sfnt_services = NULL;
- if(container->tt_cmap_classes)
- FT_Destroy_Class_tt_cmap_classes(library, container->tt_cmap_classes);
+
+ if ( container->tt_cmap_classes )
+ FT_Destroy_Class_tt_cmap_classes( library,
+ container->tt_cmap_classes );
container->tt_cmap_classes = NULL;
+
FT_FREE( container );
pic_container->sfnt = NULL;
}
@@ -58,12 +99,12 @@
FT_Error
- sfnt_module_class_pic_init( FT_Library library )
+ sfnt_module_class_pic_init( FT_Library library )
{
FT_PIC_Container* pic_container = &library->pic_container;
- FT_Error error = SFNT_Err_Ok;
- sfntModulePIC* container;
- FT_Memory memory = library->memory;
+ FT_Error error = SFNT_Err_Ok;
+ sfntModulePIC* container = NULL;
+ FT_Memory memory = library->memory;
/* allocate pointer, clear and set global container pointer */
@@ -72,30 +113,37 @@
FT_MEM_SET( container, 0, sizeof ( *container ) );
pic_container->sfnt = container;
- /* initialize pointer table - this is how the module usually expects this data */
- error = FT_Create_Class_sfnt_services(library, &container->sfnt_services);
- if(error)
+ /* initialize pointer table - */
+ /* this is how the module usually expects this data */
+ error = FT_Create_Class_sfnt_services( library,
+ &container->sfnt_services );
+ if ( error )
goto Exit;
- error = FT_Create_Class_tt_cmap_classes(library, &container->tt_cmap_classes);
- if(error)
+
+ error = FT_Create_Class_tt_cmap_classes( library,
+ &container->tt_cmap_classes );
+ if ( error )
goto Exit;
- FT_Init_Class_sfnt_service_glyph_dict(library, &container->sfnt_service_glyph_dict);
- FT_Init_Class_sfnt_service_ps_name(library, &container->sfnt_service_ps_name);
- FT_Init_Class_tt_service_get_cmap_info(library, &container->tt_service_get_cmap_info);
- FT_Init_Class_sfnt_service_sfnt_table(&container->sfnt_service_sfnt_table);
+
+ FT_Init_Class_sfnt_service_glyph_dict(
+ library, &container->sfnt_service_glyph_dict );
+ FT_Init_Class_sfnt_service_ps_name(
+ library, &container->sfnt_service_ps_name );
+ FT_Init_Class_tt_service_get_cmap_info(
+ library, &container->tt_service_get_cmap_info );
+ FT_Init_Class_sfnt_service_sfnt_table(
+ &container->sfnt_service_sfnt_table );
#ifdef TT_CONFIG_OPTION_BDF
- FT_Init_Class_sfnt_service_bdf(&container->sfnt_service_bdf);
+ FT_Init_Class_sfnt_service_bdf( &container->sfnt_service_bdf );
#endif
- FT_Init_Class_sfnt_interface(library, &container->sfnt_interface);
+ FT_Init_Class_sfnt_interface( library, &container->sfnt_interface );
-Exit:
- if(error)
- sfnt_module_class_pic_free(library);
+ Exit:
+ if ( error )
+ sfnt_module_class_pic_free( library );
return error;
}
-
-
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/sfnt/sfntpic.h b/3party/freetype/src/sfnt/sfntpic.h
index 6943b4250a..35d0f449fe 100644
--- a/3party/freetype/src/sfnt/sfntpic.h
+++ b/3party/freetype/src/sfnt/sfntpic.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for sfnt module. */
/* */
-/* Copyright 2009 by */
+/* Copyright 2009, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,66 +19,92 @@
#ifndef __SFNTPIC_H__
#define __SFNTPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
- #ifndef FT_CONFIG_OPTION_PIC
-#define FT_SFNT_SERVICES_GET sfnt_services
-#define FT_SFNT_SERVICE_GLYPH_DICT_GET sfnt_service_glyph_dict
-#define FT_SFNT_SERVICE_PS_NAME_GET sfnt_service_ps_name
-#define FT_TT_SERVICE_GET_CMAP_INFO_GET tt_service_get_cmap_info
-#define FT_SFNT_SERVICES_GET sfnt_services
-#define FT_TT_CMAP_CLASSES_GET tt_cmap_classes
-#define FT_SFNT_SERVICE_SFNT_TABLE_GET sfnt_service_sfnt_table
-#define FT_SFNT_SERVICE_BDF_GET sfnt_service_bdf
-#define FT_SFNT_INTERFACE_GET sfnt_interface
+
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define SFNT_SERVICES_GET sfnt_services
+#define SFNT_SERVICE_GLYPH_DICT_GET sfnt_service_glyph_dict
+#define SFNT_SERVICE_PS_NAME_GET sfnt_service_ps_name
+#define TT_SERVICE_CMAP_INFO_GET tt_service_get_cmap_info
+#define SFNT_SERVICES_GET sfnt_services
+#define TT_CMAP_CLASSES_GET tt_cmap_classes
+#define SFNT_SERVICE_SFNT_TABLE_GET sfnt_service_sfnt_table
+#define SFNT_SERVICE_BDF_GET sfnt_service_bdf
+#define SFNT_INTERFACE_GET sfnt_interface
#else /* FT_CONFIG_OPTION_PIC */
-/* some include files required for members of sfntModulePIC */
+ /* some include files required for members of sfntModulePIC */
#include FT_SERVICE_GLYPH_DICT_H
#include FT_SERVICE_POSTSCRIPT_NAME_H
#include FT_SERVICE_SFNT_H
#include FT_SERVICE_TT_CMAP_H
+
#ifdef TT_CONFIG_OPTION_BDF
#include "ttbdf.h"
#include FT_SERVICE_BDF_H
#endif
+
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_SFNT_H
#include "ttcmap.h"
-typedef struct sfntModulePIC_
+
+ typedef struct sfntModulePIC_
{
- FT_ServiceDescRec* sfnt_services;
- FT_Service_GlyphDictRec sfnt_service_glyph_dict;
+ FT_ServiceDescRec* sfnt_services;
+ FT_Service_GlyphDictRec sfnt_service_glyph_dict;
FT_Service_PsFontNameRec sfnt_service_ps_name;
- FT_Service_TTCMapsRec tt_service_get_cmap_info;
- TT_CMap_Class* tt_cmap_classes;
- FT_Service_SFNT_TableRec sfnt_service_sfnt_table;
+ FT_Service_TTCMapsRec tt_service_get_cmap_info;
+ TT_CMap_Class* tt_cmap_classes;
+ FT_Service_SFNT_TableRec sfnt_service_sfnt_table;
#ifdef TT_CONFIG_OPTION_BDF
- FT_Service_BDFRec sfnt_service_bdf;
+ FT_Service_BDFRec sfnt_service_bdf;
#endif
- SFNT_Interface sfnt_interface;
+ SFNT_Interface sfnt_interface;
+
} sfntModulePIC;
-#define GET_PIC(lib) ((sfntModulePIC*)((lib)->pic_container.sfnt))
-#define FT_SFNT_SERVICES_GET (GET_PIC(library)->sfnt_services)
-#define FT_SFNT_SERVICE_GLYPH_DICT_GET (GET_PIC(library)->sfnt_service_glyph_dict)
-#define FT_SFNT_SERVICE_PS_NAME_GET (GET_PIC(library)->sfnt_service_ps_name)
-#define FT_TT_SERVICE_GET_CMAP_INFO_GET (GET_PIC(library)->tt_service_get_cmap_info)
-#define FT_SFNT_SERVICES_GET (GET_PIC(library)->sfnt_services)
-#define FT_TT_CMAP_CLASSES_GET (GET_PIC(library)->tt_cmap_classes)
-#define FT_SFNT_SERVICE_SFNT_TABLE_GET (GET_PIC(library)->sfnt_service_sfnt_table)
-#define FT_SFNT_SERVICE_BDF_GET (GET_PIC(library)->sfnt_service_bdf)
-#define FT_SFNT_INTERFACE_GET (GET_PIC(library)->sfnt_interface)
+
+#define GET_PIC( lib ) \
+ ( (sfntModulePIC*)((lib)->pic_container.sfnt) )
+
+#define SFNT_SERVICES_GET \
+ ( GET_PIC( library )->sfnt_services )
+#define SFNT_SERVICE_GLYPH_DICT_GET \
+ ( GET_PIC( library )->sfnt_service_glyph_dict )
+#define SFNT_SERVICE_PS_NAME_GET \
+ ( GET_PIC( library )->sfnt_service_ps_name )
+#define TT_SERVICE_CMAP_INFO_GET \
+ ( GET_PIC( library )->tt_service_get_cmap_info )
+#define SFNT_SERVICES_GET \
+ ( GET_PIC( library )->sfnt_services )
+#define TT_CMAP_CLASSES_GET \
+ ( GET_PIC( library )->tt_cmap_classes )
+#define SFNT_SERVICE_SFNT_TABLE_GET \
+ ( GET_PIC( library )->sfnt_service_sfnt_table )
+#define SFNT_SERVICE_BDF_GET \
+ ( GET_PIC( library )->sfnt_service_bdf )
+#define SFNT_INTERFACE_GET \
+ ( GET_PIC( library )->sfnt_interface )
+
+
+ /* see sfntpic.c for the implementation */
+ void
+ sfnt_module_class_pic_free( FT_Library library );
+
+ FT_Error
+ sfnt_module_class_pic_init( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
-/* */
+ /* */
FT_END_HEADER
diff --git a/3party/freetype/src/sfnt/sfobjs.c b/3party/freetype/src/sfnt/sfobjs.c
index 44471f6b67..ef4784aeb3 100644
--- a/3party/freetype/src/sfnt/sfobjs.c
+++ b/3party/freetype/src/sfnt/sfobjs.c
@@ -4,7 +4,7 @@
/* */
/* SFNT object management (base). */
/* */
-/* Copyright 1996-2008, 2010-2011 by */
+/* Copyright 1996-2008, 2010-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -64,13 +64,17 @@
for ( n = 0; n < len; n++ )
{
code = FT_NEXT_USHORT( read );
+
+ if ( code == 0 )
+ break;
+
if ( code < 32 || code > 127 )
code = '?';
string[n] = (char)code;
}
- string[len] = 0;
+ string[n] = 0;
return string;
}
@@ -95,13 +99,17 @@
for ( n = 0; n < len; n++ )
{
code = *read++;
+
+ if ( code == 0 )
+ break;
+
if ( code < 32 || code > 127 )
code = '?';
string[n] = (char)code;
}
- string[len] = 0;
+ string[n] = 0;
return string;
}
@@ -376,7 +384,10 @@
tag != TTAG_true &&
tag != TTAG_typ1 &&
tag != 0x00020000UL )
+ {
+ FT_TRACE2(( " not a font using the SFNT container format\n" ));
return SFNT_Err_Unknown_File_Format;
+ }
face->ttc_header.tag = TTAG_ttcf;
@@ -452,7 +463,10 @@
{
sfnt = (SFNT_Service)FT_Get_Module_Interface( library, "sfnt" );
if ( !sfnt )
- return SFNT_Err_Invalid_File_Format;
+ {
+ FT_ERROR(( "sfnt_init_face: cannot access `sfnt' module\n" ));
+ return SFNT_Err_Missing_Module;
+ }
face->sfnt = sfnt;
face->goto_table = sfnt->goto_table;
@@ -460,6 +474,8 @@
FT_FACE_FIND_GLOBAL_SERVICE( face, face->psnames, POSTSCRIPT_CMAPS );
+ FT_TRACE2(( "SFNT driver\n" ));
+
error = sfnt_open_font( stream, face );
if ( error )
return error;
@@ -492,7 +508,7 @@
FT_TRACE2(( "`" #x "' " )); \
FT_TRACE3(( "-->\n" )); \
\
- error = sfnt->load_##x( face, stream ); \
+ error = sfnt->load_ ## x( face, stream ); \
\
FT_TRACE2(( "%s\n", ( !error ) \
? "loaded" \
@@ -508,7 +524,7 @@
vertical ? "vertical " : "" )); \
FT_TRACE3(( "-->\n" )); \
\
- error = sfnt->load_##x( face, stream, vertical ); \
+ error = sfnt->load_ ## x( face, stream, vertical ); \
\
FT_TRACE2(( "%s\n", ( !error ) \
? "loaded" \
@@ -518,11 +534,11 @@
FT_TRACE3(( "\n" )); \
} while ( 0 )
-#define GET_NAME( id, field ) \
- do { \
- error = tt_face_get_name( face, TT_NAME_ID_##id, field ); \
- if ( error ) \
- goto Exit; \
+#define GET_NAME( id, field ) \
+ do { \
+ error = tt_face_get_name( face, TT_NAME_ID_ ## id, field ); \
+ if ( error ) \
+ goto Exit; \
} while ( 0 )
@@ -539,13 +555,14 @@
#endif
FT_Bool has_outline;
FT_Bool is_apple_sbit;
- FT_Bool ignore_preferred_family = FALSE;
+ FT_Bool ignore_preferred_family = FALSE;
FT_Bool ignore_preferred_subfamily = FALSE;
SFNT_Service sfnt = (SFNT_Service)face->sfnt;
FT_UNUSED( face_index );
+
/* Check parameters */
{
@@ -651,7 +668,7 @@
get_glyph_metrics )
{
face->horizontal.number_Of_HMetrics = 0;
- error = SFNT_Err_Ok;
+ error = SFNT_Err_Ok;
}
#endif
}
@@ -678,7 +695,7 @@
get_glyph_metrics )
{
face->horizontal.number_Of_HMetrics = 0;
- error = SFNT_Err_Ok;
+ error = SFNT_Err_Ok;
}
#endif
diff --git a/3party/freetype/src/sfnt/ttcmap.c b/3party/freetype/src/sfnt/ttcmap.c
index 544750ab17..f1504d6217 100644
--- a/3party/freetype/src/sfnt/ttcmap.c
+++ b/3party/freetype/src/sfnt/ttcmap.c
@@ -4,7 +4,7 @@
/* */
/* TrueType character mapping table (cmap) support (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by */
+/* Copyright 2002-2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -165,20 +165,24 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap0_class_rec,
- sizeof ( TT_CMapRec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap0_class_rec,
+ sizeof ( TT_CMapRec ),
- (FT_CMap_InitFunc) tt_cmap_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap0_char_index,
- (FT_CMap_CharNextFunc) tt_cmap0_char_next,
+ (FT_CMap_InitFunc) tt_cmap_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap0_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap0_char_next,
+
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
0,
- (TT_CMap_ValidateFunc) tt_cmap0_validate,
- (TT_CMap_Info_GetFunc) tt_cmap0_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap0_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap0_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_0 */
@@ -541,20 +545,24 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap2_class_rec,
- sizeof ( TT_CMapRec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap2_class_rec,
+ sizeof ( TT_CMapRec ),
- (FT_CMap_InitFunc) tt_cmap_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap2_char_index,
- (FT_CMap_CharNextFunc) tt_cmap2_char_next,
+ (FT_CMap_InitFunc) tt_cmap_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap2_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap2_char_next,
+
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
2,
- (TT_CMap_ValidateFunc) tt_cmap2_validate,
- (TT_CMap_Info_GetFunc) tt_cmap2_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap2_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap2_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_2 */
@@ -1377,19 +1385,23 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap4_class_rec,
- sizeof ( TT_CMap4Rec ),
- (FT_CMap_InitFunc) tt_cmap4_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap4_char_index,
- (FT_CMap_CharNextFunc) tt_cmap4_char_next,
+ FT_DEFINE_TT_CMAP(
+ tt_cmap4_class_rec,
+ sizeof ( TT_CMap4Rec ),
+ (FT_CMap_InitFunc) tt_cmap4_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap4_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap4_char_next,
+
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
4,
- (TT_CMap_ValidateFunc) tt_cmap4_validate,
- (TT_CMap_Info_GetFunc) tt_cmap4_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap4_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap4_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_4 */
@@ -1536,20 +1548,24 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap6_class_rec,
- sizeof ( TT_CMapRec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap6_class_rec,
+ sizeof ( TT_CMapRec ),
- (FT_CMap_InitFunc) tt_cmap_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap6_char_index,
- (FT_CMap_CharNextFunc) tt_cmap6_char_next,
+ (FT_CMap_InitFunc) tt_cmap_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap6_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap6_char_next,
+
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
6,
- (TT_CMap_ValidateFunc) tt_cmap6_validate,
- (TT_CMap_Info_GetFunc) tt_cmap6_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap6_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap6_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_6 */
@@ -1789,20 +1805,24 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap8_class_rec,
- sizeof ( TT_CMapRec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap8_class_rec,
+ sizeof ( TT_CMapRec ),
- (FT_CMap_InitFunc) tt_cmap_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap8_char_index,
- (FT_CMap_CharNextFunc) tt_cmap8_char_next,
+ (FT_CMap_InitFunc) tt_cmap_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap8_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap8_char_next,
+
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
8,
- (TT_CMap_ValidateFunc) tt_cmap8_validate,
- (TT_CMap_Info_GetFunc) tt_cmap8_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap8_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap8_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_8 */
@@ -1938,20 +1958,24 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap10_class_rec,
- sizeof ( TT_CMapRec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap10_class_rec,
+ sizeof ( TT_CMapRec ),
+
+ (FT_CMap_InitFunc) tt_cmap_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap10_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap10_char_next,
- (FT_CMap_InitFunc) tt_cmap_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap10_char_index,
- (FT_CMap_CharNextFunc) tt_cmap10_char_next,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
10,
- (TT_CMap_ValidateFunc) tt_cmap10_validate,
- (TT_CMap_Info_GetFunc) tt_cmap10_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap10_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap10_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_10 */
@@ -2258,20 +2282,24 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap12_class_rec,
- sizeof ( TT_CMap12Rec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap12_class_rec,
+ sizeof ( TT_CMap12Rec ),
+
+ (FT_CMap_InitFunc) tt_cmap12_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap12_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap12_char_next,
- (FT_CMap_InitFunc) tt_cmap12_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap12_char_index,
- (FT_CMap_CharNextFunc) tt_cmap12_char_next,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
12,
- (TT_CMap_ValidateFunc) tt_cmap12_validate,
- (TT_CMap_Info_GetFunc) tt_cmap12_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap12_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap12_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_12 */
@@ -2338,9 +2366,9 @@
tt_cmap13_validate( FT_Byte* table,
FT_Validator valid )
{
- FT_Byte* p;
- FT_ULong length;
- FT_ULong num_groups;
+ FT_Byte* p;
+ FT_ULong length;
+ FT_ULong num_groups;
if ( table + 16 > valid->limit )
@@ -2490,7 +2518,6 @@
/* if `char_code' is not in any group, then `mid' is */
/* the group nearest to `char_code' */
- /* */
if ( char_code > end )
{
@@ -2574,20 +2601,24 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap13_class_rec,
- sizeof ( TT_CMap13Rec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap13_class_rec,
+ sizeof ( TT_CMap13Rec ),
- (FT_CMap_InitFunc) tt_cmap13_init,
- (FT_CMap_DoneFunc) NULL,
- (FT_CMap_CharIndexFunc)tt_cmap13_char_index,
- (FT_CMap_CharNextFunc) tt_cmap13_char_next,
+ (FT_CMap_InitFunc) tt_cmap13_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap13_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap13_char_next,
+
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
- NULL, NULL, NULL, NULL, NULL
- ,
13,
- (TT_CMap_ValidateFunc) tt_cmap13_validate,
- (TT_CMap_Info_GetFunc) tt_cmap13_get_info
- )
+ (TT_CMap_ValidateFunc)tt_cmap13_validate,
+ (TT_CMap_Info_GetFunc)tt_cmap13_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_13 */
@@ -2688,8 +2719,8 @@
FT_UInt32 num_results,
FT_Memory memory )
{
- FT_UInt32 old_max = cmap->max_results;
- FT_Error error = SFNT_Err_Ok;
+ FT_UInt32 old_max = cmap->max_results;
+ FT_Error error = SFNT_Err_Ok;
if ( num_results > cmap->max_results )
@@ -2713,9 +2744,9 @@
cmap->cmap.data = table;
table += 6;
- cmap->num_selectors = FT_PEEK_ULONG( table );
- cmap->max_results = 0;
- cmap->results = NULL;
+ cmap->num_selectors = FT_PEEK_ULONG( table );
+ cmap->max_results = 0;
+ cmap->results = NULL;
return SFNT_Err_Ok;
}
@@ -2791,7 +2822,7 @@
{
FT_Byte* ndp = table + nondefOff;
FT_ULong numMappings = TT_NEXT_ULONG( ndp );
- FT_ULong i, lastUni = 0;
+ FT_ULong i, lastUni = 0;
if ( numMappings * 4 > (FT_ULong)( valid->limit - ndp ) )
@@ -2965,7 +2996,7 @@
tt_cmap14_char_var_index( TT_CMap cmap,
TT_CMap ucmap,
FT_UInt32 charcode,
- FT_UInt32 variantSelector)
+ FT_UInt32 variantSelector )
{
FT_Byte* p = tt_cmap14_find_variant( cmap->data + 6, variantSelector );
FT_ULong defOff;
@@ -3106,9 +3137,9 @@
static FT_UInt32*
- tt_cmap14_get_def_chars( TT_CMap cmap,
- FT_Byte* p,
- FT_Memory memory )
+ tt_cmap14_get_def_chars( TT_CMap cmap,
+ FT_Byte* p,
+ FT_Memory memory )
{
TT_CMap14 cmap14 = (TT_CMap14) cmap;
FT_UInt32 numRanges;
@@ -3124,7 +3155,7 @@
for ( q = cmap14->results; numRanges > 0; --numRanges )
{
- FT_UInt32 uni = (FT_UInt32)TT_NEXT_UINT24( p );
+ FT_UInt32 uni = (FT_UInt32)TT_NEXT_UINT24( p );
cnt = FT_NEXT_BYTE( p ) + 1;
@@ -3133,6 +3164,7 @@
q[0] = uni;
uni += 1;
q += 1;
+
} while ( --cnt != 0 );
}
q[0] = 0;
@@ -3306,25 +3338,25 @@
}
- FT_DEFINE_TT_CMAP(tt_cmap14_class_rec,
- sizeof ( TT_CMap14Rec ),
+ FT_DEFINE_TT_CMAP(
+ tt_cmap14_class_rec,
+ sizeof ( TT_CMap14Rec ),
- (FT_CMap_InitFunc) tt_cmap14_init,
- (FT_CMap_DoneFunc) tt_cmap14_done,
- (FT_CMap_CharIndexFunc)tt_cmap14_char_index,
- (FT_CMap_CharNextFunc) tt_cmap14_char_next,
+ (FT_CMap_InitFunc) tt_cmap14_init,
+ (FT_CMap_DoneFunc) tt_cmap14_done,
+ (FT_CMap_CharIndexFunc)tt_cmap14_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap14_char_next,
+
+ /* Format 14 extension functions */
+ (FT_CMap_CharVarIndexFunc) tt_cmap14_char_var_index,
+ (FT_CMap_CharVarIsDefaultFunc)tt_cmap14_char_var_isdefault,
+ (FT_CMap_VariantListFunc) tt_cmap14_variants,
+ (FT_CMap_CharVariantListFunc) tt_cmap14_char_variants,
+ (FT_CMap_VariantCharListFunc) tt_cmap14_variant_chars,
- /* Format 14 extension functions */
- (FT_CMap_CharVarIndexFunc) tt_cmap14_char_var_index,
- (FT_CMap_CharVarIsDefaultFunc)tt_cmap14_char_var_isdefault,
- (FT_CMap_VariantListFunc) tt_cmap14_variants,
- (FT_CMap_CharVariantListFunc) tt_cmap14_char_variants,
- (FT_CMap_VariantCharListFunc) tt_cmap14_variant_chars
- ,
14,
(TT_CMap_ValidateFunc)tt_cmap14_validate,
- (TT_CMap_Info_GetFunc)tt_cmap14_get_info
- )
+ (TT_CMap_Info_GetFunc)tt_cmap14_get_info )
#endif /* TT_CONFIG_CMAP_FORMAT_14 */
@@ -3333,43 +3365,55 @@
static const TT_CMap_Class tt_cmap_classes[] =
{
-#define TTCMAPCITEM(a) &a,
+#define TTCMAPCITEM( a ) &a,
#include "ttcmapc.h"
NULL,
};
#else /*FT_CONFIG_OPTION_PIC*/
- void FT_Destroy_Class_tt_cmap_classes(FT_Library library, TT_CMap_Class* clazz)
+ void
+ FT_Destroy_Class_tt_cmap_classes( FT_Library library,
+ TT_CMap_Class* clazz )
{
- FT_Memory memory = library->memory;
+ FT_Memory memory = library->memory;
+
+
if ( clazz )
FT_FREE( clazz );
}
- FT_Error FT_Create_Class_tt_cmap_classes(FT_Library library, TT_CMap_Class** output_class)
+
+ FT_Error
+ FT_Create_Class_tt_cmap_classes( FT_Library library,
+ TT_CMap_Class** output_class )
{
- TT_CMap_Class* clazz;
- TT_CMap_ClassRec* recs;
- FT_Error error;
- FT_Memory memory = library->memory;
- int i = 0;
+ TT_CMap_Class* clazz = NULL;
+ TT_CMap_ClassRec* recs;
+ FT_Error error;
+ FT_Memory memory = library->memory;
-#define TTCMAPCITEM(a) i++;
+ int i = 0;
+
+
+#define TTCMAPCITEM( a ) i++;
#include "ttcmapc.h"
- /* allocate enough space for both the pointers +terminator and the class instances */
- if ( FT_ALLOC( clazz, sizeof(*clazz)*(i+1)+sizeof(TT_CMap_ClassRec)*i ) )
+ /* allocate enough space for both the pointers */
+ /* plus terminator and the class instances */
+ if ( FT_ALLOC( clazz, sizeof ( *clazz ) * ( i + 1 ) +
+ sizeof ( TT_CMap_ClassRec ) * i ) )
return error;
/* the location of the class instances follows the array of pointers */
- recs = (TT_CMap_ClassRec*) (((char*)clazz)+(sizeof(*clazz)*(i+1)));
- i=0;
+ recs = (TT_CMap_ClassRec*)( (char*)clazz +
+ sizeof ( *clazz ) * ( i + 1 ) );
+ i = 0;
#undef TTCMAPCITEM
-#define TTCMAPCITEM(a) \
- FT_Init_Class_##a(&recs[i]); \
- clazz[i] = &recs[i]; \
+#define TTCMAPCITEM( a ) \
+ FT_Init_Class_ ## a( &recs[i] ); \
+ clazz[i] = &recs[i]; \
i++;
#include "ttcmapc.h"
@@ -3411,10 +3455,12 @@
}
num_cmaps = TT_NEXT_USHORT( p );
+
#ifdef FT_MAX_CHARMAP_CACHEABLE
if ( num_cmaps > FT_MAX_CHARMAP_CACHEABLE )
- FT_ERROR(( "tt_face_build_cmaps: too many cmap subtables(%d) "
- "subtable#%d and later are loaded but cannot be searched\n",
+ FT_ERROR(( "tt_face_build_cmaps: too many cmap subtables (%d)\n"
+ " subtable #%d and higher are loaded"
+ " but cannot be searched\n",
num_cmaps, FT_MAX_CHARMAP_CACHEABLE + 1 ));
#endif
@@ -3434,7 +3480,7 @@
{
FT_Byte* volatile cmap = table + offset;
volatile FT_UInt format = TT_PEEK_USHORT( cmap );
- const TT_CMap_Class* volatile pclazz = FT_TT_CMAP_CLASSES_GET;
+ const TT_CMap_Class* volatile pclazz = TT_CMAP_CLASSES_GET;
TT_CMap_Class volatile clazz;
@@ -3452,8 +3498,7 @@
valid.num_glyphs = (FT_UInt)face->max_profile.numGlyphs;
- if ( ft_setjmp(
- *((ft_jmp_buf*)&FT_VALIDATOR( &valid )->jump_buffer) ) == 0 )
+ if ( ft_setjmp( FT_VALIDATOR( &valid )->jump_buffer) == 0 )
{
/* validate this cmap sub-table */
error = clazz->validate( cmap, FT_VALIDATOR( &valid ) );
@@ -3464,9 +3509,9 @@
FT_CMap ttcmap;
- /* It might make sense to store the single variation selector */
- /* cmap somewhere special. But it would have to be in the */
- /* public FT_FaceRec, and we can't change that. */
+ /* It might make sense to store the single variation */
+ /* selector cmap somewhere special. But it would have to be */
+ /* in the public FT_FaceRec, and we can't change that. */
if ( !FT_CMap_New( (FT_CMap_Class)clazz,
cmap, &charmap, &ttcmap ) )
diff --git a/3party/freetype/src/sfnt/ttcmap.h b/3party/freetype/src/sfnt/ttcmap.h
index 15a4a21e50..0fde1676bf 100644
--- a/3party/freetype/src/sfnt/ttcmap.h
+++ b/3party/freetype/src/sfnt/ttcmap.h
@@ -4,7 +4,7 @@
/* */
/* TrueType character mapping table (cmap) support (specification). */
/* */
-/* Copyright 2002, 2003, 2004, 2005 by */
+/* Copyright 2002-2005, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -55,46 +55,79 @@ FT_BEGIN_HEADER
} TT_CMap_ClassRec;
+
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_DEFINE_TT_CMAP(class_, size_, init_, done_, char_index_, \
- char_next_, char_var_index_, char_var_default_, variant_list_, \
- charvariant_list_,variantchar_list_, \
- format_, validate_, get_cmap_info_) \
- FT_CALLBACK_TABLE_DEF \
- const TT_CMap_ClassRec class_ = \
- { \
- {size_, init_, done_, char_index_, \
- char_next_, char_var_index_, char_var_default_, variant_list_, \
- charvariant_list_, variantchar_list_}, \
- format_, validate_, get_cmap_info_ \
+#define FT_DEFINE_TT_CMAP( class_, \
+ size_, \
+ init_, \
+ done_, \
+ char_index_, \
+ char_next_, \
+ char_var_index_, \
+ char_var_default_, \
+ variant_list_, \
+ charvariant_list_, \
+ variantchar_list_, \
+ format_, \
+ validate_, \
+ get_cmap_info_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const TT_CMap_ClassRec class_ = \
+ { \
+ { size_, \
+ init_, \
+ done_, \
+ char_index_, \
+ char_next_, \
+ char_var_index_, \
+ char_var_default_, \
+ variant_list_, \
+ charvariant_list_, \
+ variantchar_list_ \
+ }, \
+ \
+ format_, \
+ validate_, \
+ get_cmap_info_ \
};
-#else /* FT_CONFIG_OPTION_PIC */
-
-#define FT_DEFINE_TT_CMAP(class_, size_, init_, done_, char_index_, \
- char_next_, char_var_index_, char_var_default_, variant_list_, \
- charvariant_list_,variantchar_list_, \
- format_, validate_, get_cmap_info_) \
- void \
- FT_Init_Class_##class_( TT_CMap_ClassRec* clazz ) \
- { \
- clazz->clazz.size = size_; \
- clazz->clazz.init = init_; \
- clazz->clazz.done = done_; \
- clazz->clazz.char_index = char_index_; \
- clazz->clazz.char_next = char_next_; \
- clazz->clazz.char_var_index = char_var_index_; \
- clazz->clazz.char_var_default = char_var_default_; \
- clazz->clazz.variant_list = variant_list_; \
- clazz->clazz.charvariant_list = charvariant_list_; \
- clazz->clazz.variantchar_list = variantchar_list_; \
- clazz->format = format_; \
- clazz->validate = validate_; \
- clazz->get_cmap_info = get_cmap_info_; \
- }
-
-#endif /* FT_CONFIG_OPTION_PIC */
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_TT_CMAP( class_, \
+ size_, \
+ init_, \
+ done_, \
+ char_index_, \
+ char_next_, \
+ char_var_index_, \
+ char_var_default_, \
+ variant_list_, \
+ charvariant_list_, \
+ variantchar_list_, \
+ format_, \
+ validate_, \
+ get_cmap_info_ ) \
+ void \
+ FT_Init_Class_ ## class_( TT_CMap_ClassRec* clazz ) \
+ { \
+ clazz->clazz.size = size_; \
+ clazz->clazz.init = init_; \
+ clazz->clazz.done = done_; \
+ clazz->clazz.char_index = char_index_; \
+ clazz->clazz.char_next = char_next_; \
+ clazz->clazz.char_var_index = char_var_index_; \
+ clazz->clazz.char_var_default = char_var_default_; \
+ clazz->clazz.variant_list = variant_list_; \
+ clazz->clazz.charvariant_list = charvariant_list_; \
+ clazz->clazz.variantchar_list = variantchar_list_; \
+ clazz->format = format_; \
+ clazz->validate = validate_; \
+ clazz->get_cmap_info = get_cmap_info_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
typedef struct TT_ValidatorRec_
{
@@ -104,7 +137,7 @@ FT_BEGIN_HEADER
} TT_ValidatorRec, *TT_Validator;
-#define TT_VALIDATOR( x ) ((TT_Validator)( x ))
+#define TT_VALIDATOR( x ) ( (TT_Validator)( x ) )
#define TT_VALID_GLYPH_COUNT( x ) TT_VALIDATOR( x )->num_glyphs
diff --git a/3party/freetype/src/sfnt/ttcmapc.h b/3party/freetype/src/sfnt/ttcmapc.h
index 4c9c6a56f7..2ea204309c 100644
--- a/3party/freetype/src/sfnt/ttcmapc.h
+++ b/3party/freetype/src/sfnt/ttcmapc.h
@@ -17,39 +17,40 @@
#ifdef TT_CONFIG_CMAP_FORMAT_0
- TTCMAPCITEM(tt_cmap0_class_rec)
+ TTCMAPCITEM( tt_cmap0_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_2
- TTCMAPCITEM(tt_cmap2_class_rec)
+ TTCMAPCITEM( tt_cmap2_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_4
- TTCMAPCITEM(tt_cmap4_class_rec)
+ TTCMAPCITEM( tt_cmap4_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_6
- TTCMAPCITEM(tt_cmap6_class_rec)
+ TTCMAPCITEM( tt_cmap6_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_8
- TTCMAPCITEM(tt_cmap8_class_rec)
+ TTCMAPCITEM( tt_cmap8_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_10
- TTCMAPCITEM(tt_cmap10_class_rec)
+ TTCMAPCITEM( tt_cmap10_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_12
- TTCMAPCITEM(tt_cmap12_class_rec)
+ TTCMAPCITEM( tt_cmap12_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_13
- TTCMAPCITEM(tt_cmap13_class_rec)
+ TTCMAPCITEM( tt_cmap13_class_rec )
#endif
#ifdef TT_CONFIG_CMAP_FORMAT_14
- TTCMAPCITEM(tt_cmap14_class_rec)
+ TTCMAPCITEM( tt_cmap14_class_rec )
#endif
+
/* END */
diff --git a/3party/freetype/src/sfnt/ttload.c b/3party/freetype/src/sfnt/ttload.c
index 5fb9aea4e5..7ffdbeefff 100644
--- a/3party/freetype/src/sfnt/ttload.c
+++ b/3party/freetype/src/sfnt/ttload.c
@@ -5,8 +5,7 @@
/* Load the basic TrueType tables, i.e., tables that can be either in */
/* TTF or OTF fonts (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
-/* 2010 by */
+/* Copyright 1996-2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -362,14 +361,17 @@
FT_TRACE2(( "-- Number of tables: %10u\n", sfnt.num_tables ));
FT_TRACE2(( "-- Format version: 0x%08lx\n", sfnt.format_tag ));
- /* check first */
- error = check_table_dir( &sfnt, stream );
- if ( error )
+ if ( sfnt.format_tag != TTAG_OTTO )
{
- FT_TRACE2(( "tt_face_load_font_dir:"
- " invalid table directory for TrueType\n" ));
+ /* check first */
+ error = check_table_dir( &sfnt, stream );
+ if ( error )
+ {
+ FT_TRACE2(( "tt_face_load_font_dir:"
+ " invalid table directory for TrueType\n" ));
- goto Exit;
+ goto Exit;
+ }
}
face->num_tables = sfnt.num_tables;
@@ -624,7 +626,7 @@
FT_Error error;
TT_MaxProfile* maxProfile = &face->max_profile;
- const FT_Frame_Field maxp_fields[] =
+ static const FT_Frame_Field maxp_fields[] =
{
#undef FT_STRUCTURE
#define FT_STRUCTURE TT_MaxProfile
@@ -635,7 +637,7 @@
FT_FRAME_END
};
- const FT_Frame_Field maxp_fields_extra[] =
+ static const FT_Frame_Field maxp_fields_extra[] =
{
FT_FRAME_START( 26 ),
FT_FRAME_USHORT( maxPoints ),
@@ -721,7 +723,7 @@
/*************************************************************************/
/* */
/* <Function> */
- /* tt_face_load_names */
+ /* tt_face_load_name */
/* */
/* <Description> */
/* Loads the name records. */
@@ -952,7 +954,7 @@
FT_Error error;
TT_OS2* os2;
- const FT_Frame_Field os2_fields[] =
+ static const FT_Frame_Field os2_fields[] =
{
#undef FT_STRUCTURE
#define FT_STRUCTURE TT_OS2
@@ -1004,7 +1006,7 @@
FT_FRAME_END
};
- const FT_Frame_Field os2_fields_extra[] =
+ static const FT_Frame_Field os2_fields_extra[] =
{
FT_FRAME_START( 8 ),
FT_FRAME_ULONG( ulCodePageRange1 ),
@@ -1012,7 +1014,7 @@
FT_FRAME_END
};
- const FT_Frame_Field os2_fields_extra2[] =
+ static const FT_Frame_Field os2_fields_extra2[] =
{
FT_FRAME_START( 10 ),
FT_FRAME_SHORT ( sxHeight ),
@@ -1240,11 +1242,11 @@
num_ranges = face->gasp.numRanges;
FT_TRACE3(( "numRanges: %u\n", num_ranges ));
- if ( FT_QNEW_ARRAY( gaspranges, num_ranges ) ||
- FT_FRAME_ENTER( num_ranges * 4L ) )
+ if ( FT_QNEW_ARRAY( face->gasp.gaspRanges, num_ranges ) ||
+ FT_FRAME_ENTER( num_ranges * 4L ) )
goto Exit;
- face->gasp.gaspRanges = gaspranges;
+ gaspranges = face->gasp.gaspRanges;
for ( j = 0; j < num_ranges; j++ )
{
diff --git a/3party/freetype/src/sfnt/ttmtx.c b/3party/freetype/src/sfnt/ttmtx.c
index 73ac8b2d55..8f7b2a93b9 100644
--- a/3party/freetype/src/sfnt/ttmtx.c
+++ b/3party/freetype/src/sfnt/ttmtx.c
@@ -4,7 +4,7 @@
/* */
/* Load the metrics tables common to TTF and OTF fonts (body). */
/* */
-/* Copyright 2006-2009, 2011 by */
+/* Copyright 2006-2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -260,7 +260,7 @@
FT_Error error;
TT_HoriHeader* header;
- const FT_Frame_Field metrics_header_fields[] =
+ static const FT_Frame_Field metrics_header_fields[] =
{
#undef FT_STRUCTURE
#define FT_STRUCTURE TT_HoriHeader
diff --git a/3party/freetype/src/smooth/ftgrays.c b/3party/freetype/src/smooth/ftgrays.c
index 895e748594..f0db123803 100644
--- a/3party/freetype/src/smooth/ftgrays.c
+++ b/3party/freetype/src/smooth/ftgrays.c
@@ -4,7 +4,7 @@
/* */
/* A new `perfect' anti-aliasing renderer (body). */
/* */
-/* Copyright 2000-2003, 2005-2011 by */
+/* Copyright 2000-2003, 2005-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -232,10 +232,15 @@ typedef ptrdiff_t FT_PtrDist;
/* as usual, for the speed hungry :-) */
+#undef RAS_ARG
+#undef RAS_ARG_
+#undef RAS_VAR
+#undef RAS_VAR_
+
#ifndef FT_STATIC_RASTER
-#define RAS_ARG PWorker worker
-#define RAS_ARG_ PWorker worker,
+#define RAS_ARG gray_PWorker worker
+#define RAS_ARG_ gray_PWorker worker,
#define RAS_VAR worker
#define RAS_VAR_ worker,
@@ -253,6 +258,11 @@ typedef ptrdiff_t FT_PtrDist;
/* must be at least 6 bits! */
#define PIXEL_BITS 8
+#undef FLOOR
+#undef CEILING
+#undef TRUNC
+#undef SCALED
+
#define ONE_PIXEL ( 1L << PIXEL_BITS )
#define PIXEL_MASK ( -1L << PIXEL_BITS )
#define TRUNC( x ) ( (TCoord)( (x) >> PIXEL_BITS ) )
@@ -302,7 +312,7 @@ typedef ptrdiff_t FT_PtrDist;
#endif /* PIXEL_BITS >= 8 */
- /* maximal number of gray spans in a call to the span callback */
+ /* maximum number of gray spans in a call to the span callback */
#define FT_MAX_GRAY_SPANS 32
@@ -310,15 +320,15 @@ typedef ptrdiff_t FT_PtrDist;
typedef struct TCell_
{
- TPos x; /* same with TWorker.ex */
- TCoord cover; /* same with TWorker.cover */
- TArea area;
- PCell next;
+ TPos x; /* same with gray_TWorker.ex */
+ TCoord cover; /* same with gray_TWorker.cover */
+ TArea area;
+ PCell next;
} TCell;
- typedef struct TWorker_
+ typedef struct gray_TWorker_
{
TCoord ex, ey;
TPos min_ex, max_ex;
@@ -329,7 +339,7 @@ typedef ptrdiff_t FT_PtrDist;
TCoord cover;
int invalid;
- PCell cells;
+ PCell cells;
FT_PtrDist max_cells;
FT_PtrDist num_cells;
@@ -363,25 +373,25 @@ typedef ptrdiff_t FT_PtrDist;
PCell* ycells;
TPos ycount;
- } TWorker, *PWorker;
+ } gray_TWorker, *gray_PWorker;
#ifndef FT_STATIC_RASTER
#define ras (*worker)
#else
- static TWorker ras;
+ static gray_TWorker ras;
#endif
- typedef struct TRaster_
+ typedef struct gray_TRaster_
{
- void* buffer;
- long buffer_size;
- int band_size;
- void* memory;
- PWorker worker;
+ void* buffer;
+ long buffer_size;
+ int band_size;
+ void* memory;
+ gray_PWorker worker;
- } TRaster, *PRaster;
+ } gray_TRaster, *gray_PRaster;
@@ -878,6 +888,8 @@ typedef ptrdiff_t FT_PtrDist;
FT_Vector* arc;
+ levels = ras.lev_stack;
+
arc = ras.bez_stack;
arc[0].x = UPSCALE( to->x );
arc[0].y = UPSCALE( to->y );
@@ -916,7 +928,6 @@ typedef ptrdiff_t FT_PtrDist;
level++;
} while ( dx > ONE_PIXEL / 4 );
- levels = ras.lev_stack;
levels[0] = level;
do
@@ -1080,11 +1091,11 @@ typedef ptrdiff_t FT_PtrDist;
if ( s > s_limit )
goto Split;
- /* If P1 or P2 is outside P0-P3, split the curve. */
- if ( dy * dy1 + dx * dx1 < 0 ||
- dy * dy2 + dx * dx2 < 0 ||
- dy * (arc[3].y - arc[1].y) + dx * (arc[3].x - arc[1].x) < 0 ||
- dy * (arc[3].y - arc[2].y) + dx * (arc[3].x - arc[2].x) < 0 )
+ /* Split super curvy segments where the off points are so far
+ from the chord that the angles P0-P1-P3 or P0-P2-P3 become
+ acute as detected by appropriate dot products. */
+ if ( dx1 * ( dx1 - dx ) + dy1 * ( dy1 - dy ) > 0 ||
+ dx2 * ( dx2 - dx ) + dy2 * ( dy2 - dy ) > 0 )
goto Split;
/* No reason to split. */
@@ -1109,7 +1120,7 @@ typedef ptrdiff_t FT_PtrDist;
static int
gray_move_to( const FT_Vector* to,
- PWorker worker )
+ gray_PWorker worker )
{
TPos x, y;
@@ -1131,7 +1142,7 @@ typedef ptrdiff_t FT_PtrDist;
static int
gray_line_to( const FT_Vector* to,
- PWorker worker )
+ gray_PWorker worker )
{
gray_render_line( RAS_VAR_ UPSCALE( to->x ), UPSCALE( to->y ) );
return 0;
@@ -1141,7 +1152,7 @@ typedef ptrdiff_t FT_PtrDist;
static int
gray_conic_to( const FT_Vector* control,
const FT_Vector* to,
- PWorker worker )
+ gray_PWorker worker )
{
gray_render_conic( RAS_VAR_ control, to );
return 0;
@@ -1152,7 +1163,7 @@ typedef ptrdiff_t FT_PtrDist;
gray_cubic_to( const FT_Vector* control1,
const FT_Vector* control2,
const FT_Vector* to,
- PWorker worker )
+ gray_PWorker worker )
{
gray_render_cubic( RAS_VAR_ control1, control2, to );
return 0;
@@ -1163,7 +1174,7 @@ typedef ptrdiff_t FT_PtrDist;
gray_render_span( int y,
int count,
const FT_Span* spans,
- PWorker worker )
+ gray_PWorker worker )
{
unsigned char* p;
FT_Bitmap* map = &worker->target;
@@ -1389,7 +1400,26 @@ typedef ptrdiff_t FT_PtrDist;
ras.render_span( ras.span_y, ras.num_gray_spans,
ras.gray_spans, ras.render_span_data );
+#ifdef FT_DEBUG_LEVEL_TRACE
+
+ if ( ras.num_gray_spans > 0 )
+ {
+ FT_Span* span;
+ int n;
+
+
+ FT_TRACE7(( "y = %3d ", ras.span_y ));
+ span = ras.gray_spans;
+ for ( n = 0; n < ras.num_gray_spans; n++, span++ )
+ FT_TRACE7(( "[%d..%d]:%02x ",
+ span->x, span->x + span->len - 1, span->coverage ));
+ FT_TRACE7(( "\n" ));
+ }
+
FT_TRACE7(( "gray_sweep: end\n" ));
+
+#endif /* FT_DEBUG_LEVEL_TRACE */
+
}
@@ -1675,11 +1705,11 @@ typedef ptrdiff_t FT_PtrDist;
#endif /* _STANDALONE_ */
- typedef struct TBand_
+ typedef struct gray_TBand_
{
TPos min, max;
- } TBand;
+ } gray_TBand;
FT_DEFINE_OUTLINE_FUNCS(func_interface,
(FT_Outline_MoveTo_Func) gray_move_to,
@@ -1716,11 +1746,11 @@ typedef ptrdiff_t FT_PtrDist;
static int
gray_convert_glyph( RAS_ARG )
{
- TBand bands[40];
- TBand* volatile band;
- int volatile n, num_bands;
- TPos volatile min, max, max_y;
- FT_BBox* clip;
+ gray_TBand bands[40];
+ gray_TBand* volatile band;
+ int volatile n, num_bands;
+ TPos volatile min, max, max_y;
+ FT_BBox* clip;
/* Set up state in the raster object */
@@ -1784,7 +1814,7 @@ typedef ptrdiff_t FT_PtrDist;
cell_start += sizeof ( TCell ) - cell_mod;
cell_end = ras.buffer_size;
- cell_end -= cell_end % sizeof( TCell );
+ cell_end -= cell_end % sizeof ( TCell );
cells_max = (PCell)( (char*)ras.buffer + cell_end );
ras.cells = (PCell)( (char*)ras.buffer + cell_start );
@@ -1851,12 +1881,12 @@ typedef ptrdiff_t FT_PtrDist;
static int
- gray_raster_render( PRaster raster,
+ gray_raster_render( gray_PRaster raster,
const FT_Raster_Params* params )
{
const FT_Outline* outline = (const FT_Outline*)params->source;
const FT_Bitmap* target_map = params->target;
- PWorker worker;
+ gray_PWorker worker;
if ( !raster || !raster->buffer || !raster->buffer_size )
@@ -1948,7 +1978,7 @@ typedef ptrdiff_t FT_PtrDist;
gray_raster_new( void* memory,
FT_Raster* araster )
{
- static TRaster the_raster;
+ static gray_TRaster the_raster;
FT_UNUSED( memory );
@@ -1973,15 +2003,15 @@ typedef ptrdiff_t FT_PtrDist;
gray_raster_new( FT_Memory memory,
FT_Raster* araster )
{
- FT_Error error;
- PRaster raster = NULL;
+ FT_Error error;
+ gray_PRaster raster = NULL;
*araster = 0;
- if ( !FT_ALLOC( raster, sizeof ( TRaster ) ) )
+ if ( !FT_ALLOC( raster, sizeof ( gray_TRaster ) ) )
{
raster->memory = memory;
- *araster = (FT_Raster)raster;
+ *araster = (FT_Raster)raster;
}
return error;
@@ -1991,7 +2021,7 @@ typedef ptrdiff_t FT_PtrDist;
static void
gray_raster_done( FT_Raster raster )
{
- FT_Memory memory = (FT_Memory)((PRaster)raster)->memory;
+ FT_Memory memory = (FT_Memory)((gray_PRaster)raster)->memory;
FT_FREE( raster );
@@ -2005,19 +2035,20 @@ typedef ptrdiff_t FT_PtrDist;
char* pool_base,
long pool_size )
{
- PRaster rast = (PRaster)raster;
+ gray_PRaster rast = (gray_PRaster)raster;
if ( raster )
{
- if ( pool_base && pool_size >= (long)sizeof ( TWorker ) + 2048 )
+ if ( pool_base && pool_size >= (long)sizeof ( gray_TWorker ) + 2048 )
{
- PWorker worker = (PWorker)pool_base;
+ gray_PWorker worker = (gray_PWorker)pool_base;
rast->worker = worker;
rast->buffer = pool_base +
- ( ( sizeof ( TWorker ) + sizeof ( TCell ) - 1 ) &
+ ( ( sizeof ( gray_TWorker ) +
+ sizeof ( TCell ) - 1 ) &
~( sizeof ( TCell ) - 1 ) );
rast->buffer_size = (long)( ( pool_base + pool_size ) -
(char*)rast->buffer ) &
diff --git a/3party/freetype/src/smooth/ftsmerrs.h b/3party/freetype/src/smooth/ftsmerrs.h
index 0c2a2ecd90..413d2f1f70 100644
--- a/3party/freetype/src/smooth/ftsmerrs.h
+++ b/3party/freetype/src/smooth/ftsmerrs.h
@@ -4,7 +4,7 @@
/* */
/* smooth renderer error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX Smooth_Err_
#define FT_ERR_BASE FT_Mod_Err_Smooth
diff --git a/3party/freetype/src/smooth/ftsmooth.c b/3party/freetype/src/smooth/ftsmooth.c
index 1350a56618..8f5300dbb7 100644
--- a/3party/freetype/src/smooth/ftsmooth.c
+++ b/3party/freetype/src/smooth/ftsmooth.c
@@ -4,7 +4,7 @@
/* */
/* Anti-aliasing renderer interface (body). */
/* */
-/* Copyright 2000-2006, 2009-2011 by */
+/* Copyright 2000-2006, 2009-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -105,9 +105,9 @@
FT_Error error;
FT_Outline* outline = NULL;
FT_BBox cbox;
- FT_UInt width, height, pitch;
+ FT_Pos width, height, pitch;
#ifndef FT_CONFIG_OPTION_SUBPIXEL_RENDERING
- FT_UInt height_org, width_org;
+ FT_Pos height_org, width_org;
#endif
FT_Bitmap* bitmap;
FT_Memory memory;
@@ -117,6 +117,10 @@
FT_Raster_Params params;
+ FT_Bool have_translated_origin = FALSE;
+ FT_Bool have_outline_shifted = FALSE;
+ FT_Bool have_buffer = FALSE;
+
/* check glyph image format */
if ( slot->format != render->glyph_format )
@@ -127,13 +131,19 @@
/* check mode */
if ( mode != required_mode )
- return Smooth_Err_Cannot_Render_Glyph;
+ {
+ error = Smooth_Err_Cannot_Render_Glyph;
+ goto Exit;
+ }
outline = &slot->outline;
/* translate the outline to the new origin if needed */
if ( origin )
+ {
FT_Outline_Translate( outline, origin->x, origin->y );
+ have_translated_origin = TRUE;
+ }
/* compute the control box, and grid fit it */
FT_Outline_Get_CBox( outline, &cbox );
@@ -148,20 +158,22 @@
FT_ERROR(( "ft_smooth_render_generic: glyph too large:"
" xMin = %d, xMax = %d\n",
cbox.xMin >> 6, cbox.xMax >> 6 ));
- return Smooth_Err_Raster_Overflow;
+ error = Smooth_Err_Raster_Overflow;
+ goto Exit;
}
else
- width = (FT_UInt)( ( cbox.xMax - cbox.xMin ) >> 6 );
+ width = ( cbox.xMax - cbox.xMin ) >> 6;
if ( cbox.yMin < 0 && cbox.yMax > FT_INT_MAX + cbox.yMin )
{
FT_ERROR(( "ft_smooth_render_generic: glyph too large:"
" yMin = %d, yMax = %d\n",
cbox.yMin >> 6, cbox.yMax >> 6 ));
- return Smooth_Err_Raster_Overflow;
+ error = Smooth_Err_Raster_Overflow;
+ goto Exit;
}
else
- height = (FT_UInt)( ( cbox.yMax - cbox.yMin ) >> 6 );
+ height = ( cbox.yMax - cbox.yMin ) >> 6;
bitmap = &slot->bitmap;
memory = render->root.memory;
@@ -221,13 +233,14 @@
#if FT_UINT_MAX > 0xFFFFU
- /* Required check is ( pitch * height < FT_ULONG_MAX ), */
- /* but we care realistic cases only. Always pitch <= width. */
- if ( width > 0x7FFFU || height > 0x7FFFU )
+ /* Required check is (pitch * height < FT_ULONG_MAX), */
+ /* but we care realistic cases only. Always pitch <= width. */
+ if ( width > 0x7FFF || height > 0x7FFF )
{
FT_ERROR(( "ft_smooth_render_generic: glyph too large: %u x %u\n",
width, height ));
- return Smooth_Err_Raster_Overflow;
+ error = Smooth_Err_Raster_Overflow;
+ goto Exit;
}
#endif
@@ -240,9 +253,12 @@
/* translate outline to render it into the bitmap */
FT_Outline_Translate( outline, -x_shift, -y_shift );
+ have_outline_shifted = TRUE;
if ( FT_ALLOC( bitmap->buffer, (FT_ULong)pitch * height ) )
goto Exit;
+ else
+ have_buffer = TRUE;
slot->internal->flags |= FT_GLYPH_OWN_BITMAP;
@@ -288,6 +304,9 @@
vec->y /= 3;
}
+ if ( error )
+ goto Exit;
+
if ( slot->library->lcd_filter_func )
slot->library->lcd_filter_func( bitmap, mode, slot->library );
@@ -295,6 +314,8 @@
/* render outline into bitmap */
error = render->raster_render( render->raster, &params );
+ if ( error )
+ goto Exit;
/* expand it horizontally */
if ( hmul )
@@ -346,25 +367,35 @@
#endif /* !FT_CONFIG_OPTION_SUBPIXEL_RENDERING */
- FT_Outline_Translate( outline, x_shift, y_shift );
-
/*
* XXX: on 16bit system, we return an error for huge bitmap
* to prevent an overflow.
*/
if ( x_left > FT_INT_MAX || y_top > FT_INT_MAX )
- return Smooth_Err_Invalid_Pixel_Size;
-
- if ( error )
+ {
+ error = Smooth_Err_Invalid_Pixel_Size;
goto Exit;
+ }
slot->format = FT_GLYPH_FORMAT_BITMAP;
slot->bitmap_left = (FT_Int)x_left;
slot->bitmap_top = (FT_Int)y_top;
+ /* everything is fine; don't deallocate buffer */
+ have_buffer = FALSE;
+
+ error = Smooth_Err_Ok;
+
Exit:
- if ( outline && origin )
+ if ( have_outline_shifted )
+ FT_Outline_Translate( outline, x_shift, y_shift );
+ if ( have_translated_origin )
FT_Outline_Translate( outline, -origin->x, -origin->y );
+ if ( have_buffer )
+ {
+ FT_FREE( bitmap->buffer );
+ slot->internal->flags &= ~FT_GLYPH_OWN_BITMAP;
+ }
return error;
}
@@ -421,10 +452,10 @@
}
- FT_DEFINE_RENDERER(ft_smooth_renderer_class,
+ FT_DEFINE_RENDERER( ft_smooth_renderer_class,
FT_MODULE_RENDERER,
- sizeof( FT_RendererRec ),
+ sizeof ( FT_RendererRec ),
"smooth",
0x10000L,
@@ -448,10 +479,10 @@
)
- FT_DEFINE_RENDERER(ft_smooth_lcd_renderer_class,
-
+ FT_DEFINE_RENDERER( ft_smooth_lcd_renderer_class,
+
FT_MODULE_RENDERER,
- sizeof( FT_RendererRec ),
+ sizeof ( FT_RendererRec ),
"smooth-lcd",
0x10000L,
@@ -474,10 +505,10 @@
(FT_Raster_Funcs*) &FT_GRAYS_RASTER_GET
)
- FT_DEFINE_RENDERER(ft_smooth_lcdv_renderer_class,
+ FT_DEFINE_RENDERER( ft_smooth_lcdv_renderer_class,
FT_MODULE_RENDERER,
- sizeof( FT_RendererRec ),
+ sizeof ( FT_RendererRec ),
"smooth-lcdv",
0x10000L,
diff --git a/3party/freetype/src/smooth/ftspic.c b/3party/freetype/src/smooth/ftspic.c
index 7adaab17d2..4714828fc1 100644
--- a/3party/freetype/src/smooth/ftspic.c
+++ b/3party/freetype/src/smooth/ftspic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for smooth module. */
/* */
-/* Copyright 2009, 2010 by */
+/* Copyright 2009, 2010, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,21 +20,27 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include "ftspic.h"
+#include "ftsmerrs.h"
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from ftgrays.c */
- void FT_Init_Class_ft_grays_raster(FT_Raster_Funcs*);
+ void
+ FT_Init_Class_ft_grays_raster( FT_Raster_Funcs* funcs );
void
- ft_smooth_renderer_class_pic_free( FT_Library library )
+ ft_smooth_renderer_class_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->smooth )
{
- SmoothPIC* container = (SmoothPIC*)pic_container->smooth;
- if(--container->ref_count)
+ SmoothPIC* container = (SmoothPIC*)pic_container->smooth;
+
+
+ if ( --container->ref_count )
return;
FT_FREE( container );
pic_container->smooth = NULL;
@@ -47,13 +53,13 @@
{
FT_PIC_Container* pic_container = &library->pic_container;
FT_Error error = Smooth_Err_Ok;
- SmoothPIC* container;
+ SmoothPIC* container = NULL;
FT_Memory memory = library->memory;
- /* since this function also serve smooth_lcd and smooth_lcdv renderers,
+ /* since this function also serve smooth_lcd and smooth_lcdv renderers,
it implements reference counting */
- if(pic_container->smooth)
+ if ( pic_container->smooth )
{
((SmoothPIC*)pic_container->smooth)->ref_count++;
return error;
@@ -62,34 +68,37 @@
/* allocate pointer, clear and set global container pointer */
if ( FT_ALLOC ( container, sizeof ( *container ) ) )
return error;
- FT_MEM_SET( container, 0, sizeof(*container) );
+ FT_MEM_SET( container, 0, sizeof ( *container ) );
pic_container->smooth = container;
container->ref_count = 1;
/* initialize pointer table - this is how the module usually expects this data */
- FT_Init_Class_ft_grays_raster(&container->ft_grays_raster);
+ FT_Init_Class_ft_grays_raster( &container->ft_grays_raster );
/*Exit:*/
- if(error)
- ft_smooth_renderer_class_pic_free(library);
+ if ( error )
+ ft_smooth_renderer_class_pic_free( library );
return error;
}
/* re-route these init and free functions to the above functions */
- FT_Error ft_smooth_lcd_renderer_class_pic_init(FT_Library library)
+ FT_Error ft_smooth_lcd_renderer_class_pic_init( FT_Library library )
{
- return ft_smooth_renderer_class_pic_init(library);
+ return ft_smooth_renderer_class_pic_init( library );
}
- void ft_smooth_lcd_renderer_class_pic_free(FT_Library library)
+
+ void ft_smooth_lcd_renderer_class_pic_free( FT_Library library )
{
- ft_smooth_renderer_class_pic_free(library);
+ ft_smooth_renderer_class_pic_free( library );
}
- FT_Error ft_smooth_lcdv_renderer_class_pic_init(FT_Library library)
+
+ FT_Error ft_smooth_lcdv_renderer_class_pic_init( FT_Library library )
{
- return ft_smooth_renderer_class_pic_init(library);
+ return ft_smooth_renderer_class_pic_init( library );
}
- void ft_smooth_lcdv_renderer_class_pic_free(FT_Library library)
+
+ void ft_smooth_lcdv_renderer_class_pic_free( FT_Library library )
{
- ft_smooth_renderer_class_pic_free(library);
+ ft_smooth_renderer_class_pic_free( library );
}
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/smooth/ftspic.h b/3party/freetype/src/smooth/ftspic.h
index c7e0ce9d89..4686f5e35b 100644
--- a/3party/freetype/src/smooth/ftspic.h
+++ b/3party/freetype/src/smooth/ftspic.h
@@ -19,7 +19,7 @@
#ifndef __FTSPIC_H__
#define __FTSPIC_H__
-
+
FT_BEGIN_HEADER
#include FT_INTERNAL_PIC_H
@@ -38,6 +38,25 @@ FT_BEGIN_HEADER
#define GET_PIC(lib) ((SmoothPIC*)((lib)->pic_container.smooth))
#define FT_GRAYS_RASTER_GET (GET_PIC(library)->ft_grays_raster)
+ /* see ftspic.c for the implementation */
+ void
+ ft_smooth_renderer_class_pic_free( FT_Library library );
+
+ void
+ ft_smooth_lcd_renderer_class_pic_free( FT_Library library );
+
+ void
+ ft_smooth_lcdv_renderer_class_pic_free( FT_Library library );
+
+ FT_Error
+ ft_smooth_renderer_class_pic_init( FT_Library library );
+
+ FT_Error
+ ft_smooth_lcd_renderer_class_pic_init( FT_Library library );
+
+ FT_Error
+ ft_smooth_lcdv_renderer_class_pic_init( FT_Library library );
+
#endif /* FT_CONFIG_OPTION_PIC */
/* */
diff --git a/3party/freetype/src/tools/apinames.c b/3party/freetype/src/tools/apinames.c
index 99e3028c93..3dc6559e43 100644
--- a/3party/freetype/src/tools/apinames.c
+++ b/3party/freetype/src/tools/apinames.c
@@ -10,7 +10,7 @@
* accepted if you are using GCC for compilation (and probably by
* other compilers too).
*
- * Author: David Turner, 2005, 2006, 2008, 2009, 2010
+ * Author: David Turner, 2005, 2006, 2008-2012
*
* This code is explicitly placed into the public domain.
*
@@ -59,8 +59,9 @@ static void
names_add( const char* name,
const char* end )
{
- int nn, len, h;
- Name nm;
+ unsigned int h;
+ int nn, len;
+ Name nm;
if ( end <= name )
return;
@@ -86,7 +87,8 @@ names_add( const char* name,
if ( num_names >= max_names )
{
max_names += (max_names >> 1) + 4;
- the_names = (NameRec*)realloc( the_names, sizeof(the_names[0])*max_names );
+ the_names = (NameRec*)realloc( the_names,
+ sizeof ( the_names[0] ) * max_names );
if ( the_names == NULL )
panic( "not enough memory" );
}
@@ -115,7 +117,8 @@ name_compare( const void* name1,
static void
names_sort( void )
{
- qsort( the_names, (size_t)num_names, sizeof(the_names[0]), name_compare );
+ qsort( the_names, (size_t)num_names,
+ sizeof ( the_names[0] ), name_compare );
}
@@ -169,7 +172,7 @@ names_dump( FILE* out,
int len = dot - dll_name;
- if ( len > (int)( sizeof( temp ) - 1 ) )
+ if ( len > (int)( sizeof ( temp ) - 1 ) )
len = sizeof ( temp ) - 1;
memcpy( temp, dll_name, len );
@@ -205,7 +208,7 @@ typedef enum State_
static int
read_header_file( FILE* file, int verbose )
{
- static char buff[ LINEBUFF_SIZE+1 ];
+ static char buff[LINEBUFF_SIZE + 1];
State state = STATE_START;
while ( !feof( file ) )
diff --git a/3party/freetype/src/tools/docmaker/content.py b/3party/freetype/src/tools/docmaker/content.py
index b398955b81..26087f7b88 100644
--- a/3party/freetype/src/tools/docmaker/content.py
+++ b/3party/freetype/src/tools/docmaker/content.py
@@ -1,4 +1,4 @@
-# Content (c) 2002, 2004, 2006, 2007, 2008, 2009
+# Content (c) 2002, 2004, 2006-2009, 2012
# David Turner <david@freetype.org>
#
# This file contains routines used to parse the content of documentation
@@ -32,7 +32,7 @@ re_code_end = re.compile( r"(\s*)}\s*$" )
# this regular expression is used to isolate identifiers from
# other text
#
-re_identifier = re.compile( r'(\w*)' )
+re_identifier = re.compile( r'((?:\w|-)*)' )
# we collect macros ending in `_H'; while outputting the object data, we use
diff --git a/3party/freetype/src/tools/docmaker/sources.py b/3party/freetype/src/tools/docmaker/sources.py
index 7b68c07019..490ba25063 100644
--- a/3party/freetype/src/tools/docmaker/sources.py
+++ b/3party/freetype/src/tools/docmaker/sources.py
@@ -1,4 +1,4 @@
-# Sources (c) 2002, 2003, 2004, 2006, 2007, 2008, 2009
+# Sources (c) 2002-2004, 2006-2009, 2012
# David Turner <david@freetype.org>
#
#
@@ -120,8 +120,8 @@ re_source_block_formats = [re_source_block_format1, re_source_block_format2]
#
# notice how each markup tag _must_ begin a new line
#
-re_markup_tag1 = re.compile( r'''\s*<(\w*)>''' ) # <xxxx> format
-re_markup_tag2 = re.compile( r'''\s*@(\w*):''' ) # @xxxx: format
+re_markup_tag1 = re.compile( r'''\s*<((?:\w|-)*)>''' ) # <xxxx> format
+re_markup_tag2 = re.compile( r'''\s*@((?:\w|-)*):''' ) # @xxxx: format
#
# the list of supported markup tags, we could add new ones relatively
@@ -132,7 +132,7 @@ re_markup_tags = [re_markup_tag1, re_markup_tag2]
#
# used to detect a cross-reference, after markup tags have been stripped
#
-re_crossref = re.compile( r'@(\w*)(.*)' )
+re_crossref = re.compile( r'@((?:\w|-)*)(.*)' )
#
# used to detect italic and bold styles in paragraph text
diff --git a/3party/freetype/src/truetype/rules.mk b/3party/freetype/src/truetype/rules.mk
index 507ef16b02..d4b69f578b 100644
--- a/3party/freetype/src/truetype/rules.mk
+++ b/3party/freetype/src/truetype/rules.mk
@@ -3,7 +3,7 @@
#
-# Copyright 1996-2000, 2001, 2003, 2004, 2011 by
+# Copyright 1996-2001, 2003-2004, 2011-2012 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -31,7 +31,8 @@ TT_DRV_SRC := $(TT_DIR)/ttdriver.c \
$(TT_DIR)/ttinterp.c \
$(TT_DIR)/ttobjs.c \
$(TT_DIR)/ttpic.c \
- $(TT_DIR)/ttpload.c
+ $(TT_DIR)/ttpload.c \
+ $(TT_DIR)/ttsubpix.c
# TrueType driver headers
#
diff --git a/3party/freetype/src/truetype/truetype.c b/3party/freetype/src/truetype/truetype.c
index 4bd1209787..576912b219 100644
--- a/3party/freetype/src/truetype/truetype.c
+++ b/3party/freetype/src/truetype/truetype.c
@@ -4,7 +4,7 @@
/* */
/* FreeType TrueType driver component (body only). */
/* */
-/* Copyright 1996-2001, 2004, 2006 by */
+/* Copyright 1996-2001, 2004, 2006, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -27,6 +27,7 @@
#ifdef TT_USE_BYTECODE_INTERPRETER
#include "ttinterp.c"
+#include "ttsubpix.c"
#endif
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
diff --git a/3party/freetype/src/truetype/ttdriver.c b/3party/freetype/src/truetype/ttdriver.c
index e70a611233..60c0f3e132 100644
--- a/3party/freetype/src/truetype/ttdriver.c
+++ b/3party/freetype/src/truetype/ttdriver.c
@@ -4,7 +4,7 @@
/* */
/* TrueType font driver implementation (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -258,7 +258,7 @@
/*************************************************************************/
/* */
/* <Function> */
- /* Load_Glyph */
+ /* tt_glyph_load */
/* */
/* <Description> */
/* A driver method used to load a glyph within a given glyph slot. */
@@ -282,10 +282,10 @@
/* FreeType error code. 0 means success. */
/* */
static FT_Error
- Load_Glyph( FT_GlyphSlot ttslot, /* TT_GlyphSlot */
- FT_Size ttsize, /* TT_Size */
- FT_UInt glyph_index,
- FT_Int32 load_flags )
+ tt_glyph_load( FT_GlyphSlot ttslot, /* TT_GlyphSlot */
+ FT_Size ttsize, /* TT_Size */
+ FT_UInt glyph_index,
+ FT_Int32 load_flags )
{
TT_GlyphSlot slot = (TT_GlyphSlot)ttslot;
TT_Size size = (TT_Size)ttsize;
@@ -313,7 +313,7 @@
if ( load_flags & FT_LOAD_NO_HINTING )
{
/* both FT_LOAD_NO_HINTING and FT_LOAD_NO_AUTOHINT */
- /* are necessary to disable hinting for tricky fonts */
+ /* are necessary to disable hinting for tricky fonts */
if ( FT_IS_TRICKY( face ) )
load_flags &= ~FT_LOAD_NO_HINTING;
@@ -353,13 +353,13 @@
/*************************************************************************/
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
- FT_DEFINE_SERVICE_MULTIMASTERSREC(tt_service_gx_multi_masters,
+ FT_DEFINE_SERVICE_MULTIMASTERSREC(
+ tt_service_gx_multi_masters,
(FT_Get_MM_Func) NULL,
(FT_Set_MM_Design_Func) NULL,
(FT_Set_MM_Blend_Func) TT_Set_MM_Blend,
(FT_Get_MM_Var_Func) TT_Get_MM_Var,
- (FT_Set_Var_Design_Func)TT_Set_Var_Design
- )
+ (FT_Set_Var_Design_Func)TT_Set_Var_Design )
#endif
static const FT_Service_TrueTypeEngineRec tt_service_truetype_engine =
@@ -379,42 +379,59 @@
#endif /* TT_USE_BYTECODE_INTERPRETER */
};
- FT_DEFINE_SERVICE_TTGLYFREC(tt_service_truetype_glyf,
- (TT_Glyf_GetLocationFunc)tt_face_get_location
- )
+ FT_DEFINE_SERVICE_TTGLYFREC(
+ tt_service_truetype_glyf,
+ (TT_Glyf_GetLocationFunc)tt_face_get_location )
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
- FT_DEFINE_SERVICEDESCREC4(tt_services,
+ FT_DEFINE_SERVICEDESCREC4(
+ tt_services,
FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_TRUETYPE,
- FT_SERVICE_ID_MULTI_MASTERS, &FT_TT_SERVICE_GX_MULTI_MASTERS_GET,
+ FT_SERVICE_ID_MULTI_MASTERS, &TT_SERVICE_GX_MULTI_MASTERS_GET,
FT_SERVICE_ID_TRUETYPE_ENGINE, &tt_service_truetype_engine,
- FT_SERVICE_ID_TT_GLYF, &FT_TT_SERVICE_TRUETYPE_GLYF_GET
- )
+ FT_SERVICE_ID_TT_GLYF, &TT_SERVICE_TRUETYPE_GLYF_GET )
#else
- FT_DEFINE_SERVICEDESCREC3(tt_services,
+ FT_DEFINE_SERVICEDESCREC3(
+ tt_services,
FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_TRUETYPE,
FT_SERVICE_ID_TRUETYPE_ENGINE, &tt_service_truetype_engine,
- FT_SERVICE_ID_TT_GLYF, &FT_TT_SERVICE_TRUETYPE_GLYF_GET
- )
+ FT_SERVICE_ID_TT_GLYF, &TT_SERVICE_TRUETYPE_GLYF_GET )
#endif
+
FT_CALLBACK_DEF( FT_Module_Interface )
tt_get_interface( FT_Module driver, /* TT_Driver */
const char* tt_interface )
{
+ FT_Library library;
FT_Module_Interface result;
FT_Module sfntd;
SFNT_Service sfnt;
- result = ft_service_list_lookup( FT_TT_SERVICES_GET, tt_interface );
+
+ /* TT_SERVICES_GET derefers `library' in PIC mode */
+#ifdef FT_CONFIG_OPTION_PIC
+ if ( !driver )
+ return NULL;
+ library = driver->library;
+ if ( !library )
+ return NULL;
+#endif
+
+ result = ft_service_list_lookup( TT_SERVICES_GET, tt_interface );
if ( result != NULL )
return result;
+#ifndef FT_CONFIG_OPTION_PIC
if ( !driver )
return NULL;
+ library = driver->library;
+ if ( !library )
+ return NULL;
+#endif
/* only return the default interface from the SFNT module */
- sfntd = FT_Get_Module( driver->library, "sfnt" );
+ sfntd = FT_Get_Module( library, "sfnt" );
if ( sfntd )
{
sfnt = (SFNT_Service)( sfntd->clazz->module_interface );
@@ -429,22 +446,21 @@
/* The FT_DriverInterface structure is defined in ftdriver.h. */
#ifdef TT_USE_BYTECODE_INTERPRETER
-#define TT_HINTER_FLAG FT_MODULE_DRIVER_HAS_HINTER
+#define TT_HINTER_FLAG FT_MODULE_DRIVER_HAS_HINTER
#else
-#define TT_HINTER_FLAG 0
+#define TT_HINTER_FLAG 0
#endif
#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
-#define TT_SIZE_SELECT tt_size_select
+#define TT_SIZE_SELECT tt_size_select
#else
-#define TT_SIZE_SELECT 0
+#define TT_SIZE_SELECT 0
#endif
- FT_DEFINE_DRIVER(tt_driver_class,
-
-
- FT_MODULE_FONT_DRIVER |
- FT_MODULE_DRIVER_SCALABLE |
+ FT_DEFINE_DRIVER( tt_driver_class,
+
+ FT_MODULE_FONT_DRIVER |
+ FT_MODULE_DRIVER_SCALABLE |
TT_HINTER_FLAG,
sizeof ( TT_DriverRec ),
@@ -468,15 +484,15 @@
tt_size_init,
tt_size_done,
tt_slot_init,
- 0, /* FT_Slot_DoneFunc */
+ 0, /* FT_Slot_DoneFunc */
- ft_stub_set_char_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ ft_stub_set_char_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
ft_stub_set_pixel_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
- Load_Glyph,
+ tt_glyph_load,
tt_get_kerning,
- 0, /* FT_Face_AttachFunc */
+ 0, /* FT_Face_AttachFunc */
tt_get_advances,
tt_size_request,
diff --git a/3party/freetype/src/truetype/tterrors.h b/3party/freetype/src/truetype/tterrors.h
index d317c70e0e..78d138fab2 100644
--- a/3party/freetype/src/truetype/tterrors.h
+++ b/3party/freetype/src/truetype/tterrors.h
@@ -4,7 +4,7 @@
/* */
/* TrueType error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX TT_Err_
#define FT_ERR_BASE FT_Mod_Err_TrueType
diff --git a/3party/freetype/src/truetype/ttgload.c b/3party/freetype/src/truetype/ttgload.c
index f35521e17b..374f89dce3 100644
--- a/3party/freetype/src/truetype/ttgload.c
+++ b/3party/freetype/src/truetype/ttgload.c
@@ -4,7 +4,7 @@
/* */
/* TrueType Glyph Loader (body). */
/* */
-/* Copyright 1996-2011 */
+/* Copyright 1996-2012 */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -32,6 +32,7 @@
#endif
#include "tterrors.h"
+#include "ttsubpix.h"
/*************************************************************************/
@@ -149,6 +150,15 @@
loader->top_bearing = top_bearing;
loader->vadvance = advance_height;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( loader->exec )
+ loader->exec->sph_tweak_flags = 0;
+
+ /* this may not be the right place for this, but it works */
+ if ( loader->exec && loader->exec->ignore_x_mode )
+ sph_set_tweaks( loader, glyph_index );
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
if ( !loader->linear_def )
{
loader->linear_def = 1;
@@ -252,10 +262,6 @@
}
-#undef IS_HINTED
-#define IS_HINTED( flags ) ( ( flags & FT_LOAD_NO_HINTING ) == 0 )
-
-
/*************************************************************************/
/* */
/* The following functions are used by default with TrueType fonts. */
@@ -362,19 +368,21 @@
if ( n_contours >= 0xFFF || p + ( n_contours + 1 ) * 2 > limit )
goto Invalid_Outline;
- prev_cont = FT_NEXT_USHORT( p );
+ prev_cont = FT_NEXT_SHORT( p );
if ( n_contours > 0 )
cont[0] = prev_cont;
+ if ( prev_cont < 0 )
+ goto Invalid_Outline;
+
for ( cont++; cont < cont_limit; cont++ )
{
- cont[0] = FT_NEXT_USHORT( p );
+ cont[0] = FT_NEXT_SHORT( p );
if ( cont[0] <= prev_cont )
{
/* unordered contours: this is invalid */
- error = TT_Err_Invalid_Table;
- goto Fail;
+ goto Invalid_Outline;
}
prev_cont = cont[0];
}
@@ -392,13 +400,6 @@
if ( error )
goto Fail;
- /* we'd better check the contours table right now */
- outline = &gloader->current.outline;
-
- for ( cont = outline->contours + 1; cont < cont_limit; cont++ )
- if ( cont[-1] >= cont[0] )
- goto Invalid_Outline;
-
/* reading the bytecode instructions */
load->glyph->control_len = 0;
load->glyph->control_data = 0;
@@ -439,6 +440,8 @@
p += n_ins;
+ outline = &gloader->current.outline;
+
/* reading the point tags */
flag = (FT_Byte*)outline->tags;
flag_limit = flag + n_points;
@@ -816,6 +819,13 @@
loader->pp4 = zone->cur[zone->n_points - 1];
}
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( loader->exec->sph_tweak_flags & SPH_TWEAK_DEEMBOLDEN )
+ FT_Outline_EmboldenXY( &loader->gloader->current.outline, -24, 0 );
+
+ else if ( loader->exec->sph_tweak_flags & SPH_TWEAK_EMBOLDEN )
+ FT_Outline_EmboldenXY( &loader->gloader->current.outline, 24, 0 );
+#endif
return TT_Err_Ok;
}
@@ -838,6 +848,14 @@
FT_Outline* outline;
FT_Int n_points;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ TT_Face face = (TT_Face)loader->face;
+ FT_String* family = face->root.family_name;
+ FT_Int ppem = loader->size->metrics.x_ppem;
+ FT_String* style = face->root.style_name;
+ FT_Int x_scale_factor = 1000;
+#endif
+
outline = &gloader->current.outline;
n_points = outline->n_points;
@@ -892,6 +910,32 @@
loader->zone.n_points + 4 );
}
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /* scale, but only if enabled and only if TT hinting is being used */
+ if ( IS_HINTED( loader->load_flags ) )
+ x_scale_factor = scale_test_tweak( face, family, ppem, style,
+ loader->glyph_index, X_SCALING_Rules,
+ X_SCALING_RULES_SIZE );
+ /* scale the glyph */
+ if ( ( loader->load_flags & FT_LOAD_NO_SCALE ) == 0 ||
+ x_scale_factor != 1000 )
+ {
+ FT_Vector* vec = outline->points;
+ FT_Vector* limit = outline->points + n_points;
+ FT_Fixed x_scale = FT_MulDiv(
+ ((TT_Size)loader->size)->metrics.x_scale,
+ x_scale_factor, 1000 );
+ FT_Fixed y_scale = ((TT_Size)loader->size)->metrics.y_scale;
+
+
+ /* compensate for any scaling by de/emboldening; */
+ /* the amount was determined via experimentation */
+ if ( x_scale_factor != 1000 && ppem > 11 )
+ FT_Outline_EmboldenXY( outline,
+ FT_MulFix( 1280 * ppem,
+ 1000 - x_scale_factor ),
+ 0 );
+#else
/* scale the glyph */
if ( ( loader->load_flags & FT_LOAD_NO_SCALE ) == 0 )
{
@@ -899,6 +943,7 @@
FT_Vector* limit = outline->points + n_points;
FT_Fixed x_scale = ((TT_Size)loader->size)->metrics.x_scale;
FT_Fixed y_scale = ((TT_Size)loader->size)->metrics.y_scale;
+#endif /* !TT_CONFIG_OPTION_SUBPIXEL_HINTING */
for ( ; vec < limit; vec++ )
@@ -1651,12 +1696,26 @@
{
FT_Byte* widthp;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ FT_Bool ignore_x_mode;
+
+
+ ignore_x_mode = FT_BOOL( FT_LOAD_TARGET_MODE( loader->load_flags ) !=
+ FT_RENDER_MODE_MONO );
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
widthp = tt_face_get_device_metrics( face,
size->root.metrics.x_ppem,
glyph_index );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( widthp &&
+ ( ( ignore_x_mode && loader->exec->compatible_widths ) ||
+ !ignore_x_mode ||
+ SPH_OPTION_BITMAP_WIDTHS ) )
+#else
if ( widthp )
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
glyph->metrics.horiAdvance = *widthp << 6;
}
@@ -1836,7 +1895,9 @@
{
TT_Face face;
FT_Stream stream;
+#ifdef TT_USE_BYTECODE_INTERPRETER
FT_Bool pedantic = FT_BOOL( load_flags & FT_LOAD_PEDANTIC );
+#endif
face = (TT_Face)glyph->face;
@@ -1851,6 +1912,16 @@
{
TT_ExecContext exec;
FT_Bool grayscale;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ FT_Bool subpixel_hinting;
+ FT_Bool grayscale_hinting;
+#if 0
+ FT_Bool compatible_widths;
+ FT_Bool symmetrical_smoothing;
+ FT_Bool bgr;
+ FT_Bool subpixel_positioned;
+#endif
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
if ( !size->cvt_ready )
@@ -1868,11 +1939,90 @@
if ( !exec )
return TT_Err_Could_Not_Find_Context;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+ subpixel_hinting = FT_BOOL( ( FT_LOAD_TARGET_MODE( load_flags )
+ != FT_RENDER_MODE_MONO ) &&
+ SPH_OPTION_SET_SUBPIXEL );
+
+ if ( subpixel_hinting )
+ grayscale = grayscale_hinting = FALSE;
+
+ else if ( SPH_OPTION_SET_GRAYSCALE )
+ {
+ grayscale = grayscale_hinting = TRUE;
+ subpixel_hinting = FALSE;
+ }
+
+ if ( FT_IS_TRICKY( glyph->face ) )
+ subpixel_hinting = grayscale_hinting = FALSE;
+
+ exec->ignore_x_mode = subpixel_hinting || grayscale_hinting;
+ exec->rasterizer_version = SPH_OPTION_SET_RASTERIZER_VERSION;
+ if ( exec->sph_tweak_flags & SPH_TWEAK_RASTERIZER_35 )
+ exec->rasterizer_version = 35;
+
+#if 1
+ exec->compatible_widths = SPH_OPTION_SET_COMPATIBLE_WIDTHS;
+ exec->symmetrical_smoothing = FALSE;
+ exec->bgr = FALSE;
+ exec->subpixel_positioned = TRUE;
+#else /* 0 */
+ exec->compatible_widths =
+ FT_BOOL( FT_LOAD_TARGET_MODE( load_flags ) !=
+ TT_LOAD_COMPATIBLE_WIDTHS );
+ exec->symmetrical_smoothing =
+ FT_BOOL( FT_LOAD_TARGET_MODE( load_flags ) !=
+ TT_LOAD_SYMMETRICAL_SMOOTHING );
+ exec->bgr =
+ FT_BOOL( FT_LOAD_TARGET_MODE( load_flags ) !=
+ TT_LOAD_BGR );
+ exec->subpixel_positioned =
+ FT_BOOL( FT_LOAD_TARGET_MODE( load_flags ) !=
+ TT_LOAD_SUBPIXEL_POSITIONED );
+#endif /* 0 */
+
+#else /* !TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
grayscale =
FT_BOOL( FT_LOAD_TARGET_MODE( load_flags ) != FT_RENDER_MODE_MONO );
+#endif /* !TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
TT_Load_Context( exec, face, size );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+ /* a change from mono to subpixel rendering (and vice versa) */
+ /* requires a re-execution of the CVT program */
+ if ( subpixel_hinting != exec->subpixel_hinting )
+ {
+ FT_UInt i;
+
+
+ exec->subpixel_hinting = subpixel_hinting;
+
+ for ( i = 0; i < size->cvt_size; i++ )
+ size->cvt[i] = FT_MulFix( face->cvt[i], size->ttmetrics.scale );
+ tt_size_run_prep( size, pedantic );
+ }
+
+ /* a change from mono to grayscale rendering (and vice versa) */
+ /* requires a re-execution of the CVT program */
+ if ( grayscale != exec->grayscale_hinting )
+ {
+ FT_UInt i;
+
+
+ exec->grayscale_hinting = grayscale_hinting;
+
+ for ( i = 0; i < size->cvt_size; i++ )
+ size->cvt[i] = FT_MulFix( face->cvt[i], size->ttmetrics.scale );
+ tt_size_run_prep( size, pedantic );
+ }
+
+#else /* !TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
/* a change from mono to grayscale rendering (and vice versa) */
/* requires a re-execution of the CVT program */
if ( grayscale != exec->grayscale )
@@ -1890,6 +2040,8 @@
tt_size_run_prep( size, pedantic );
}
+#endif /* !TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
/* see whether the cvt program has disabled hinting */
if ( exec->GS.instruct_control & 1 )
load_flags |= FT_LOAD_NO_HINTING;
@@ -1986,13 +2138,11 @@
FT_UInt glyph_index,
FT_Int32 load_flags )
{
- TT_Face face;
FT_Error error;
TT_LoaderRec loader;
- face = (TT_Face)glyph->face;
- error = TT_Err_Ok;
+ error = TT_Err_Ok;
#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
@@ -2006,10 +2156,7 @@
error = load_sbit_image( size, glyph, glyph_index, load_flags );
if ( !error )
{
- FT_Face root = &face->root;
-
-
- if ( FT_IS_SCALABLE( root ) )
+ if ( FT_IS_SCALABLE( glyph->face ) )
{
/* for the bbox we need the header only */
(void)tt_loader_init( &loader, size, glyph, load_flags, TRUE );
diff --git a/3party/freetype/src/truetype/ttgxvar.c b/3party/freetype/src/truetype/ttgxvar.c
index 69b702f621..4edcb07abd 100644
--- a/3party/freetype/src/truetype/ttgxvar.c
+++ b/3party/freetype/src/truetype/ttgxvar.c
@@ -4,7 +4,7 @@
/* */
/* TrueType GX Font Variation loader */
/* */
-/* Copyright 2004-2011 by */
+/* Copyright 2004-2012 by */
/* David Turner, Robert Wilhelm, Werner Lemberg, and George Williams. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -91,7 +91,7 @@
/* indicates that there is a delta for every point without needing to */
/* enumerate all of them. */
/* */
-#define ALL_POINTS (FT_UShort*)( -1 )
+#define ALL_POINTS (FT_UShort*)( ~0 )
#define GX_PT_POINTS_ARE_WORDS 0x80
@@ -501,11 +501,9 @@
FT_Fixed* im_end_coords )
{
FT_UInt i;
- FT_Fixed apply;
- FT_Fixed temp;
+ FT_Fixed apply = 0x10000L;
- apply = 0x10000L;
for ( i = 0; i < blend->num_axis; ++i )
{
if ( tuple_coords[i] == 0 )
@@ -525,11 +523,10 @@
else if ( !( tupleIndex & GX_TI_INTERMEDIATE_TUPLE ) )
/* not an intermediate tuple */
- apply = FT_MulDiv( apply,
+ apply = FT_MulFix( apply,
blend->normalizedcoords[i] > 0
? blend->normalizedcoords[i]
- : -blend->normalizedcoords[i],
- 0x10000L );
+ : -blend->normalizedcoords[i] );
else if ( blend->normalizedcoords[i] <= im_start_coords[i] ||
blend->normalizedcoords[i] >= im_end_coords[i] )
@@ -539,20 +536,14 @@
}
else if ( blend->normalizedcoords[i] < tuple_coords[i] )
- {
- temp = FT_MulDiv( blend->normalizedcoords[i] - im_start_coords[i],
- 0x10000L,
- tuple_coords[i] - im_start_coords[i]);
- apply = FT_MulDiv( apply, temp, 0x10000L );
- }
+ apply = FT_MulDiv( apply,
+ blend->normalizedcoords[i] - im_start_coords[i],
+ tuple_coords[i] - im_start_coords[i] );
else
- {
- temp = FT_MulDiv( im_end_coords[i] - blend->normalizedcoords[i],
- 0x10000L,
- im_end_coords[i] - tuple_coords[i] );
- apply = FT_MulDiv( apply, temp, 0x10000L );
- }
+ apply = FT_MulDiv( apply,
+ im_end_coords[i] - blend->normalizedcoords[i],
+ im_end_coords[i] - tuple_coords[i] );
}
return apply;
@@ -712,7 +703,7 @@
mmvar->num_axis =
fvar_head.axisCount;
mmvar->num_designs =
- (FT_UInt)-1; /* meaningless in this context; each glyph */
+ ~0; /* meaningless in this context; each glyph */
/* may have a different number of designs */
/* (or tuples, as called by Apple) */
mmvar->num_namedstyles =
@@ -1034,19 +1025,11 @@
}
if ( coords[i] < a->def )
- {
- normalized[i] = -FT_MulDiv( coords[i] - a->def,
- 0x10000L,
- a->minimum - a->def );
- }
+ normalized[i] = -FT_DivFix( coords[i] - a->def, a->minimum - a->def );
else if ( a->maximum == a->def )
normalized[i] = 0;
else
- {
- normalized[i] = FT_MulDiv( coords[i] - a->def,
- 0x10000L,
- a->maximum - a->def );
- }
+ normalized[i] = FT_DivFix( coords[i] - a->def, a->maximum - a->def );
}
if ( !blend->avar_checked )
@@ -1061,15 +1044,11 @@
if ( normalized[i] < av->correspondence[j].fromCoord )
{
normalized[i] =
- FT_MulDiv(
- FT_MulDiv(
- normalized[i] - av->correspondence[j - 1].fromCoord,
- 0x10000L,
- av->correspondence[j].fromCoord -
- av->correspondence[j - 1].fromCoord ),
- av->correspondence[j].toCoord -
- av->correspondence[j - 1].toCoord,
- 0x10000L ) +
+ FT_MulDiv( normalized[i] - av->correspondence[j - 1].fromCoord,
+ av->correspondence[j].toCoord -
+ av->correspondence[j - 1].toCoord,
+ av->correspondence[j].fromCoord -
+ av->correspondence[j - 1].fromCoord ) +
av->correspondence[j - 1].toCoord;
break;
}
diff --git a/3party/freetype/src/truetype/ttinterp.c b/3party/freetype/src/truetype/ttinterp.c
index c62c589e80..19fb66c173 100644
--- a/3party/freetype/src/truetype/ttinterp.c
+++ b/3party/freetype/src/truetype/ttinterp.c
@@ -4,7 +4,7 @@
/* */
/* TrueType bytecode interpreter (body). */
/* */
-/* Copyright 1996-2011 */
+/* Copyright 1996-2012 */
/* by David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -27,16 +27,15 @@
#include FT_SYSTEM_H
#include "ttinterp.h"
-
#include "tterrors.h"
+#include "ttsubpix.h"
#ifdef TT_USE_BYTECODE_INTERPRETER
-#define TT_MULFIX FT_MulFix
-#define TT_MULDIV FT_MulDiv
-#define TT_MULDIV_NO_ROUND FT_MulDiv_No_Round
+#define xxxSPH_DEBUG
+#define xxxSPH_DEBUG_MORE_VERBOSE
/*************************************************************************/
@@ -52,7 +51,7 @@
/* */
/* In order to detect infinite loops in the code, we set up a counter */
/* within the run loop. A single stroke of interpretation is now */
- /* limited to a maximal number of opcodes defined below. */
+ /* limited to a maximum number of opcodes defined below. */
/* */
#define MAX_RUNNABLE_OPCODES 1000000L
@@ -232,6 +231,14 @@
#define BOUNDS( x, n ) ( (FT_UInt)(x) >= (FT_UInt)(n) )
#define BOUNDSL( x, n ) ( (FT_ULong)(x) >= (FT_ULong)(n) )
+ /*************************************************************************/
+ /* */
+ /* This macro computes (a*2^14)/b and complements TT_MulFix14. */
+ /* */
+#define TT_DivFix14( a, b ) \
+ FT_DivFix( a, (b) << 2 )
+
+
#undef SUCCESS
#define SUCCESS 0
@@ -715,7 +722,7 @@
FT_Error error;
- if ( ( error = TT_Goto_CodeRange( exec, tt_coderange_glyph, 0 ) )
+ if ( ( error = TT_Goto_CodeRange( exec, tt_coderange_glyph, 0 ) )
!= TT_Err_Ok )
return error;
@@ -1463,7 +1470,7 @@
#else
- /* compute (a*b)/2^14 with maximal accuracy and rounding */
+ /* compute (a*b)/2^14 with maximum accuracy and rounding */
static FT_Int32
TT_MulFix14( FT_Int32 a,
FT_Int b )
@@ -1493,7 +1500,7 @@
#endif
- /* compute (ax*bx+ay*by)/2^14 with maximal accuracy and rounding */
+ /* compute (ax*bx+ay*by)/2^14 with maximum accuracy and rounding */
static FT_Int32
TT_DotFix14( FT_Int32 ax,
FT_Int32 ay,
@@ -1661,13 +1668,13 @@
else
{
- FT_Long x, y;
+ FT_F26Dot6 x, y;
- x = TT_MULDIV( CUR.GS.projVector.x,
- CUR.tt_metrics.x_ratio, 0x4000 );
- y = TT_MULDIV( CUR.GS.projVector.y,
- CUR.tt_metrics.y_ratio, 0x4000 );
+ x = TT_MulFix14( CUR.tt_metrics.x_ratio,
+ CUR.GS.projVector.x );
+ y = TT_MulFix14( CUR.tt_metrics.y_ratio,
+ CUR.GS.projVector.y );
CUR.tt_metrics.ratio = TT_VecLen( x, y );
}
}
@@ -1679,7 +1686,7 @@
static FT_Long
Current_Ppem( EXEC_OP )
{
- return TT_MULFIX( CUR.tt_metrics.ppem, CURRENT_Ratio() );
+ return FT_MulFix( CUR.tt_metrics.ppem, CURRENT_Ratio() );
}
@@ -1700,7 +1707,7 @@
FT_CALLBACK_DEF( FT_F26Dot6 )
Read_CVT_Stretched( EXEC_OP_ FT_ULong idx )
{
- return TT_MULFIX( CUR.cvt[idx], CURRENT_Ratio() );
+ return FT_MulFix( CUR.cvt[idx], CURRENT_Ratio() );
}
@@ -1800,7 +1807,7 @@
/* NOTE: Because the last instruction of a program may be a CALL */
/* which will return to the first byte *after* the code */
- /* range, we test for AIP <= Size, instead of AIP < Size. */
+ /* range, we test for aIP <= Size, instead of aIP < Size. */
if ( aIP > range->size )
{
@@ -1850,9 +1857,11 @@
if ( v != 0 )
{
- zone->cur[point].x += TT_MULDIV( distance,
- v * 0x10000L,
- CUR.F_dot_P );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( !CUR.ignore_x_mode ||
+ ( CUR.sph_tweak_flags & SPH_TWEAK_ALLOW_X_DMOVE ) )
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ zone->cur[point].x += FT_MulDiv( distance, v, CUR.F_dot_P );
zone->tags[point] |= FT_CURVE_TAG_TOUCH_X;
}
@@ -1861,9 +1870,7 @@
if ( v != 0 )
{
- zone->cur[point].y += TT_MULDIV( distance,
- v * 0x10000L,
- CUR.F_dot_P );
+ zone->cur[point].y += FT_MulDiv( distance, v, CUR.F_dot_P );
zone->tags[point] |= FT_CURVE_TAG_TOUCH_Y;
}
@@ -1902,16 +1909,12 @@
v = CUR.GS.freeVector.x;
if ( v != 0 )
- zone->org[point].x += TT_MULDIV( distance,
- v * 0x10000L,
- CUR.F_dot_P );
+ zone->org[point].x += FT_MulDiv( distance, v, CUR.F_dot_P );
v = CUR.GS.freeVector.y;
if ( v != 0 )
- zone->org[point].y += TT_MULDIV( distance,
- v * 0x10000L,
- CUR.F_dot_P );
+ zone->org[point].y += FT_MulDiv( distance, v, CUR.F_dot_P );
}
@@ -1932,6 +1935,10 @@
{
FT_UNUSED_EXEC;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( !CUR.ignore_x_mode ||
+ ( CUR.sph_tweak_flags & SPH_TWEAK_ALLOW_X_DMOVEX ) )
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
zone->cur[point].x += distance;
zone->tags[point] |= FT_CURVE_TAG_TOUCH_X;
}
@@ -2193,7 +2200,7 @@
}
else
{
- val = - FT_PIX_CEIL( compensation - distance );
+ val = -FT_PIX_CEIL( compensation - distance );
if ( val > 0 )
val = 0;
}
@@ -2404,8 +2411,9 @@
/* Sets Super Round parameters. */
/* */
/* <Input> */
- /* GridPeriod :: Grid period */
- /* selector :: SROUND opcode */
+ /* GridPeriod :: The grid period. */
+ /* */
+ /* selector :: The SROUND opcode. */
/* */
static void
SetSuperRound( EXEC_OP_ FT_F26Dot6 GridPeriod,
@@ -2617,13 +2625,10 @@
if ( CUR.GS.dualVector.x == 0x4000 )
CUR.func_dualproj = Project_x;
+ else if ( CUR.GS.dualVector.y == 0x4000 )
+ CUR.func_dualproj = Project_y;
else
- {
- if ( CUR.GS.dualVector.y == 0x4000 )
- CUR.func_dualproj = Project_y;
- else
- CUR.func_dualproj = Dual_Project;
- }
+ CUR.func_dualproj = Dual_Project;
/* Force recalculation of cached aspect ratio */
CUR.tt_metrics.ratio = 0;
@@ -2633,61 +2638,50 @@
#endif /* TT_CONFIG_OPTION_UNPATENTED_HINTING */
if ( CUR.GS.freeVector.x == 0x4000 )
- CUR.F_dot_P = CUR.GS.projVector.x * 0x10000L;
+ CUR.F_dot_P = CUR.GS.projVector.x;
+ else if ( CUR.GS.freeVector.y == 0x4000 )
+ CUR.F_dot_P = CUR.GS.projVector.y;
else
- {
- if ( CUR.GS.freeVector.y == 0x4000 )
- CUR.F_dot_P = CUR.GS.projVector.y * 0x10000L;
- else
- CUR.F_dot_P = (FT_Long)CUR.GS.projVector.x * CUR.GS.freeVector.x * 4 +
- (FT_Long)CUR.GS.projVector.y * CUR.GS.freeVector.y * 4;
- }
+ CUR.F_dot_P = ( (FT_Long)CUR.GS.projVector.x * CUR.GS.freeVector.x +
+ (FT_Long)CUR.GS.projVector.y * CUR.GS.freeVector.y ) >>
+ 14;
if ( CUR.GS.projVector.x == 0x4000 )
CUR.func_project = (TT_Project_Func)Project_x;
+ else if ( CUR.GS.projVector.y == 0x4000 )
+ CUR.func_project = (TT_Project_Func)Project_y;
else
- {
- if ( CUR.GS.projVector.y == 0x4000 )
- CUR.func_project = (TT_Project_Func)Project_y;
- else
- CUR.func_project = (TT_Project_Func)Project;
- }
+ CUR.func_project = (TT_Project_Func)Project;
if ( CUR.GS.dualVector.x == 0x4000 )
CUR.func_dualproj = (TT_Project_Func)Project_x;
+ else if ( CUR.GS.dualVector.y == 0x4000 )
+ CUR.func_dualproj = (TT_Project_Func)Project_y;
else
- {
- if ( CUR.GS.dualVector.y == 0x4000 )
- CUR.func_dualproj = (TT_Project_Func)Project_y;
- else
- CUR.func_dualproj = (TT_Project_Func)Dual_Project;
- }
+ CUR.func_dualproj = (TT_Project_Func)Dual_Project;
CUR.func_move = (TT_Move_Func)Direct_Move;
CUR.func_move_orig = (TT_Move_Func)Direct_Move_Orig;
- if ( CUR.F_dot_P == 0x40000000L )
+ if ( CUR.F_dot_P == 0x4000L )
{
if ( CUR.GS.freeVector.x == 0x4000 )
{
CUR.func_move = (TT_Move_Func)Direct_Move_X;
CUR.func_move_orig = (TT_Move_Func)Direct_Move_Orig_X;
}
- else
+ else if ( CUR.GS.freeVector.y == 0x4000 )
{
- if ( CUR.GS.freeVector.y == 0x4000 )
- {
- CUR.func_move = (TT_Move_Func)Direct_Move_Y;
- CUR.func_move_orig = (TT_Move_Func)Direct_Move_Orig_Y;
- }
+ CUR.func_move = (TT_Move_Func)Direct_Move_Y;
+ CUR.func_move_orig = (TT_Move_Func)Direct_Move_Orig_Y;
}
}
/* at small sizes, F_dot_P can become too small, resulting */
/* in overflows and `spikes' in a number of glyphs like `w'. */
- if ( FT_ABS( CUR.F_dot_P ) < 0x4000000L )
- CUR.F_dot_P = 0x40000000L;
+ if ( FT_ABS( CUR.F_dot_P ) < 0x400L )
+ CUR.F_dot_P = 0x4000L;
/* Disable cached aspect ratio */
CUR.tt_metrics.ratio = 0;
@@ -2743,21 +2737,21 @@
return SUCCESS;
}
- R->x = (FT_F2Dot14)FT_MulDiv( Vx, 0x4000L, W );
- R->y = (FT_F2Dot14)FT_MulDiv( Vy, 0x4000L, W );
+ R->x = (FT_F2Dot14)TT_DivFix14( Vx, W );
+ R->y = (FT_F2Dot14)TT_DivFix14( Vy, W );
return SUCCESS;
}
W = TT_VecLen( Vx, Vy );
- Vx = FT_MulDiv( Vx, 0x4000L, W );
- Vy = FT_MulDiv( Vy, 0x4000L, W );
+ Vx = TT_DivFix14( Vx, W );
+ Vy = TT_DivFix14( Vy, W );
W = Vx * Vx + Vy * Vy;
/* Now, we want that Sqrt( W ) = 0x4000 */
- /* Or 0x10000000 <= W < 0x10004000 */
+ /* Or 0x10000000 <= W < 0x10004000 */
if ( Vx < 0 )
{
@@ -3110,14 +3104,9 @@
CUR.GS.single_width_cutin = (FT_F26Dot6)args[0];
- /* XXX: UNDOCUMENTED! or bug in the Windows engine? */
- /* */
- /* It seems that the value that is read here is */
- /* expressed in 16.16 format rather than in font */
- /* units. */
- /* */
-#define DO_SSW \
- CUR.GS.single_width_value = (FT_F26Dot6)( args[0] >> 10 );
+#define DO_SSW \
+ CUR.GS.single_width_value = FT_MulFix( args[0], \
+ CUR.tt_metrics.scale );
#define DO_FLIPON \
@@ -3199,36 +3188,42 @@
}
-#define DO_JROT \
- if ( args[1] != 0 ) \
- { \
- if ( args[0] == 0 && CUR.args == 0 ) \
- CUR.error = TT_Err_Bad_Argument; \
- CUR.IP += args[0]; \
- if ( CUR.IP < 0 ) \
- CUR.error = TT_Err_Bad_Argument; \
- CUR.step_ins = FALSE; \
+#define DO_JROT \
+ if ( args[1] != 0 ) \
+ { \
+ if ( args[0] == 0 && CUR.args == 0 ) \
+ CUR.error = TT_Err_Bad_Argument; \
+ CUR.IP += args[0]; \
+ if ( CUR.IP < 0 || \
+ ( CUR.callTop > 0 && \
+ CUR.IP > CUR.callStack[CUR.callTop - 1].Cur_End ) ) \
+ CUR.error = TT_Err_Bad_Argument; \
+ CUR.step_ins = FALSE; \
}
-#define DO_JMPR \
- if ( args[0] == 0 && CUR.args == 0 ) \
- CUR.error = TT_Err_Bad_Argument; \
- CUR.IP += args[0]; \
- if ( CUR.IP < 0 ) \
- CUR.error = TT_Err_Bad_Argument; \
+#define DO_JMPR \
+ if ( args[0] == 0 && CUR.args == 0 ) \
+ CUR.error = TT_Err_Bad_Argument; \
+ CUR.IP += args[0]; \
+ if ( CUR.IP < 0 || \
+ ( CUR.callTop > 0 && \
+ CUR.IP > CUR.callStack[CUR.callTop - 1].Cur_End ) ) \
+ CUR.error = TT_Err_Bad_Argument; \
CUR.step_ins = FALSE;
-#define DO_JROF \
- if ( args[1] == 0 ) \
- { \
- if ( args[0] == 0 && CUR.args == 0 ) \
- CUR.error = TT_Err_Bad_Argument; \
- CUR.IP += args[0]; \
- if ( CUR.IP < 0 ) \
- CUR.error = TT_Err_Bad_Argument; \
- CUR.step_ins = FALSE; \
+#define DO_JROF \
+ if ( args[1] == 0 ) \
+ { \
+ if ( args[0] == 0 && CUR.args == 0 ) \
+ CUR.error = TT_Err_Bad_Argument; \
+ CUR.IP += args[0]; \
+ if ( CUR.IP < 0 || \
+ ( CUR.callTop > 0 && \
+ CUR.IP > CUR.callStack[CUR.callTop - 1].Cur_End ) ) \
+ CUR.error = TT_Err_Bad_Argument; \
+ CUR.step_ins = FALSE; \
}
@@ -3288,11 +3283,11 @@
if ( args[1] == 0 ) \
CUR.error = TT_Err_Divide_By_Zero; \
else \
- args[0] = TT_MULDIV_NO_ROUND( args[0], 64L, args[1] );
+ args[0] = FT_MulDiv_No_Round( args[0], 64L, args[1] );
#define DO_MUL \
- args[0] = TT_MULDIV( args[0], args[1], 64L );
+ args[0] = FT_MulDiv( args[0], args[1], 64L );
#define DO_ABS \
@@ -3310,6 +3305,34 @@
#define DO_CEILING \
args[0] = FT_PIX_CEIL( args[0] );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+#define DO_RS \
+ { \
+ FT_ULong I = (FT_ULong)args[0]; \
+ \
+ \
+ if ( BOUNDSL( I, CUR.storeSize ) ) \
+ { \
+ if ( CUR.pedantic_hinting ) \
+ ARRAY_BOUND_ERROR; \
+ else \
+ args[0] = 0; \
+ } \
+ else \
+ { \
+ /* subpixel hinting - avoid Typeman Dstroke and */ \
+ /* IStroke and Vacuform rounds */ \
+ \
+ if ( CUR.compatibility_mode && \
+ ( I == 24 || I == 22 || I == 8 ) ) \
+ args[0] = 0; \
+ else \
+ args[0] = CUR.storage[I]; \
+ } \
+ }
+
+#else /* !TT_CONFIG_OPTION_SUBPIXEL_HINTING */
#define DO_RS \
{ \
@@ -3329,6 +3352,8 @@
args[0] = CUR.storage[I]; \
}
+#endif /* !TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
#define DO_WS \
{ \
@@ -3396,7 +3421,7 @@
} \
} \
else \
- CUR.cvt[I] = TT_MULFIX( args[1], CUR.tt_metrics.scale ); \
+ CUR.cvt[I] = FT_MulFix( args[1], CUR.tt_metrics.scale ); \
}
@@ -4471,7 +4496,7 @@
CUR.length = opcode_length[CUR.opcode];
if ( CUR.length < 0 )
{
- if ( CUR.IP + 1 > CUR.codeSize )
+ if ( CUR.IP + 1 >= CUR.codeSize )
goto Fail_Overflow;
CUR.length = 2 - CUR.length * CUR.code[CUR.IP + 1];
}
@@ -4586,6 +4611,27 @@
TT_DefRecord* rec;
TT_DefRecord* limit;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /* arguments to opcodes are skipped by `SKIP_Code' */
+ FT_Byte opcode_pattern[1][12] = {
+ /* #0 TTFautohint bytecode (old) */
+ {
+ 0x20, /* DUP */
+ 0x64, /* ABS */
+ 0xB0, /* PUSHB_1 */
+ /* 32 */
+ 0x60, /* ADD */
+ 0x66, /* FLOOR */
+ 0x23, /* SWAP */
+ 0xB0 /* PUSHB_1 */
+ },
+ };
+ FT_UShort opcode_patterns = 1;
+ FT_UShort opcode_pointer[1] = { 0, };
+ FT_UShort opcode_size[1] = { 7, };
+ FT_UShort i;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
/* some font programs are broken enough to redefine functions! */
/* We will then parse the current table. */
@@ -4619,10 +4665,11 @@
return;
}
- rec->range = CUR.curRange;
- rec->opc = (FT_UInt16)n;
- rec->start = CUR.IP + 1;
- rec->active = TRUE;
+ rec->range = CUR.curRange;
+ rec->opc = (FT_UInt16)n;
+ rec->start = CUR.IP + 1;
+ rec->active = TRUE;
+ rec->inline_delta = FALSE;
if ( n > CUR.maxFunc )
CUR.maxFunc = (FT_UInt16)n;
@@ -4632,6 +4679,46 @@
while ( SKIP_Code() == SUCCESS )
{
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+#ifdef SPH_DEBUG_MORE_VERBOSE
+ printf ( "Opcode: %d ", CUR.opcode );
+#endif
+
+ for ( i = 0; i < opcode_patterns; i++ )
+ {
+ if ( opcode_pointer[i] < opcode_size[i] &&
+ CUR.opcode == opcode_pattern[i][opcode_pointer[i]] )
+ {
+#ifdef SPH_DEBUG_MORE_VERBOSE
+ printf( "function %d, opcode ptrn: %d"
+ " op# %d: %d FOUND \n",
+ n, i, opcode_pointer[i], CUR.opcode );
+#endif
+ opcode_pointer[i] += 1;
+
+ if ( opcode_pointer[i] == opcode_size[i] )
+ {
+#ifdef SPH_DEBUG
+ printf( "Function signature %d detected in FDEF %d\n", i, n);
+#endif
+
+ switch ( i )
+ {
+ case 0:
+ CUR.size->ttfautohinted = TRUE;
+ break;
+ }
+ opcode_pointer[i] = 0;
+ }
+ }
+
+ else
+ opcode_pointer[i] = 0;
+ }
+
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
switch ( CUR.opcode )
{
case 0x89: /* IDEF */
@@ -4640,6 +4727,7 @@
return;
case 0x2D: /* ENDF */
+ rec->end = CUR.IP;
return;
}
}
@@ -4674,6 +4762,15 @@
CUR.step_ins = FALSE;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /*
+ * CUR.ignore_x_mode may be turned off prior to function calls. This
+ * ensures it is turned back on.
+ */
+ CUR.ignore_x_mode = ( CUR.subpixel_hinting || CUR.grayscale_hinting ) &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_PIXEL_HINTING );
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
if ( pRec->Cur_Count > 0 )
{
CUR.callTop++;
@@ -4744,6 +4841,7 @@
if ( !def->active )
goto Fail;
+
/* check the call stack */
if ( CUR.callTop >= CUR.callSize )
{
@@ -4757,6 +4855,7 @@
pCrec->Caller_IP = CUR.IP + 1;
pCrec->Cur_Count = 1;
pCrec->Cur_Restart = def->start;
+ pCrec->Cur_End = def->end;
CUR.callTop++;
@@ -4835,6 +4934,7 @@
pCrec->Caller_IP = CUR.IP + 1;
pCrec->Cur_Count = (FT_Int)args[0];
pCrec->Cur_Restart = def->start;
+ pCrec->Cur_End = def->end;
CUR.callTop++;
@@ -4842,6 +4942,7 @@
CUR.step_ins = FALSE;
}
+
return;
Fail:
@@ -5050,8 +5151,8 @@
/* Opcode range: 0x46-0x47 */
/* Stack: uint32 --> f26.6 */
/* */
- /* BULLSHIT: Measures from the original glyph must be taken along the */
- /* dual projection vector! */
+ /* XXX: UNDOCUMENTED: Measures from the original glyph must be taken */
+ /* along the dual projection vector! */
/* */
static void
Ins_GC( INS_ARG )
@@ -5123,14 +5224,14 @@
/* Opcode range: 0x49-0x4A */
/* Stack: uint32 uint32 --> f26.6 */
/* */
- /* BULLSHIT: Measure taken in the original glyph must be along the dual */
- /* projection vector. */
+ /* XXX: UNDOCUMENTED: Measure taken in the original glyph must be along */
+ /* the dual projection vector. */
/* */
- /* Second BULLSHIT: Flag attributes are inverted! */
- /* 0 => measure distance in original outline */
- /* 1 => measure distance in grid-fitted outline */
+ /* XXX: UNDOCUMENTED: Flag attributes are inverted! */
+ /* 0 => measure distance in original outline */
+ /* 1 => measure distance in grid-fitted outline */
/* */
- /* Third one: `zp0 - zp1', and not `zp2 - zp1! */
+ /* XXX: UNDOCUMENTED: `zp0 - zp1', and not `zp2 - zp1! */
/* */
static void
Ins_MD( INS_ARG )
@@ -5175,15 +5276,15 @@
{
/* this should be faster */
D = CUR_Func_dualproj( vec1, vec2 );
- D = TT_MULFIX( D, CUR.metrics.x_scale );
+ D = FT_MulFix( D, CUR.metrics.x_scale );
}
else
{
FT_Vector vec;
- vec.x = TT_MULFIX( vec1->x - vec2->x, CUR.metrics.x_scale );
- vec.y = TT_MULFIX( vec1->y - vec2->y, CUR.metrics.y_scale );
+ vec.x = FT_MulFix( vec1->x - vec2->x, CUR.metrics.x_scale );
+ vec.y = FT_MulFix( vec1->y - vec2->y, CUR.metrics.y_scale );
D = CUR_fast_dualproj( &vec );
}
@@ -5191,6 +5292,12 @@
}
}
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /* Disable Type 2 Vacuform Rounds - e.g. Arial Narrow */
+ if ( CUR.ignore_x_mode && FT_ABS( D ) == 64 )
+ D += 1;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
args[0] = D;
}
@@ -5648,12 +5755,8 @@
else
#endif
{
- *x = TT_MULDIV( d,
- (FT_Long)CUR.GS.freeVector.x * 0x10000L,
- CUR.F_dot_P );
- *y = TT_MULDIV( d,
- (FT_Long)CUR.GS.freeVector.y * 0x10000L,
- CUR.F_dot_P );
+ *x = FT_MulDiv( d, (FT_Long)CUR.GS.freeVector.x, CUR.F_dot_P );
+ *y = FT_MulDiv( d, (FT_Long)CUR.GS.freeVector.y, CUR.F_dot_P );
}
return SUCCESS;
@@ -5687,7 +5790,12 @@
if ( CUR.GS.freeVector.x != 0 )
{
- CUR.zp2.cur[point].x += dx;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( !CUR.ignore_x_mode ||
+ ( CUR.ignore_x_mode &&
+ ( CUR.sph_tweak_flags & SPH_TWEAK_ALLOW_X_MOVE_ZP2 ) ) )
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ CUR.zp2.cur[point].x += dx;
if ( touch )
CUR.zp2.tags[point] |= FT_CURVE_TAG_TOUCH_X;
}
@@ -5761,21 +5869,25 @@
/* Opcode range: 0x34-35 */
/* Stack: uint32 --> */
/* */
+ /* UNDOCUMENTED: According to Greg Hitchcock, there is one (virtual) */
+ /* contour in the twilight zone, namely contour number */
+ /* zero which includes all points of it. */
+ /* */
static void
Ins_SHC( INS_ARG )
{
- TT_GlyphZoneRec zp;
- FT_UShort refp;
- FT_F26Dot6 dx,
- dy;
+ TT_GlyphZoneRec zp;
+ FT_UShort refp;
+ FT_F26Dot6 dx, dy;
- FT_Short contour;
- FT_UShort first_point, last_point, i;
+ FT_Short contour, bounds;
+ FT_UShort start, limit, i;
contour = (FT_UShort)args[0];
+ bounds = ( CUR.GS.gep2 == 0 ) ? 1 : CUR.zp2.n_contours;
- if ( BOUNDS( contour, CUR.pts.n_contours ) )
+ if ( BOUNDS( contour, bounds ) )
{
if ( CUR.pedantic_hinting )
CUR.error = TT_Err_Invalid_Reference;
@@ -5786,25 +5898,19 @@
return;
if ( contour == 0 )
- first_point = 0;
+ start = 0;
else
- first_point = (FT_UShort)( CUR.pts.contours[contour - 1] + 1 -
- CUR.pts.first_point );
+ start = (FT_UShort)( CUR.zp2.contours[contour - 1] + 1 -
+ CUR.zp2.first_point );
- last_point = (FT_UShort)( CUR.pts.contours[contour] -
- CUR.pts.first_point );
-
- /* XXX: this is probably wrong... at least it prevents memory */
- /* corruption when zp2 is the twilight zone */
- if ( BOUNDS( last_point, CUR.zp2.n_points ) )
- {
- if ( CUR.zp2.n_points > 0 )
- last_point = (FT_UShort)(CUR.zp2.n_points - 1);
- else
- last_point = 0;
- }
+ /* we use the number of points if in the twilight zone */
+ if ( CUR.GS.gep2 == 0 )
+ limit = CUR.zp2.n_points;
+ else
+ limit = (FT_UShort)( CUR.zp2.contours[contour] -
+ CUR.zp2.first_point + 1 );
- for ( i = first_point; i <= last_point; i++ )
+ for ( i = start; i < limit; i++ )
{
if ( zp.cur != CUR.zp2.cur || refp != i )
MOVE_Zp2_Point( i, dx, dy, TRUE );
@@ -5826,7 +5932,7 @@
FT_F26Dot6 dx,
dy;
- FT_UShort last_point, i;
+ FT_UShort limit, i;
if ( BOUNDS( args[0], 2 ) )
@@ -5839,28 +5945,19 @@
if ( COMPUTE_Point_Displacement( &dx, &dy, &zp, &refp ) )
return;
- /* XXX: UNDOCUMENTED! SHZ doesn't move the phantom points. */
- /* Twilight zone has no contours, so use `n_points'. */
- /* Normal zone's `n_points' includes phantoms, so must */
- /* use end of last contour. */
- if ( CUR.GS.gep2 == 0 && CUR.zp2.n_points > 0 )
- last_point = (FT_UShort)( CUR.zp2.n_points - 1 );
+ /* XXX: UNDOCUMENTED! SHZ doesn't move the phantom points. */
+ /* Twilight zone has no real contours, so use `n_points'. */
+ /* Normal zone's `n_points' includes phantoms, so must */
+ /* use end of last contour. */
+ if ( CUR.GS.gep2 == 0 )
+ limit = (FT_UShort)CUR.zp2.n_points;
else if ( CUR.GS.gep2 == 1 && CUR.zp2.n_contours > 0 )
- {
- last_point = (FT_UShort)( CUR.zp2.contours[CUR.zp2.n_contours - 1] );
-
- if ( BOUNDS( last_point, CUR.zp2.n_points ) )
- {
- if ( CUR.pedantic_hinting )
- CUR.error = TT_Err_Invalid_Reference;
- return;
- }
- }
+ limit = (FT_UShort)( CUR.zp2.contours[CUR.zp2.n_contours - 1] + 1 );
else
- last_point = 0;
+ limit = 0;
/* XXX: UNDOCUMENTED! SHZ doesn't touch the points */
- for ( i = 0; i <= last_point; i++ )
+ for ( i = 0; i < limit; i++ )
{
if ( zp.cur != CUR.zp2.cur || refp != i )
MOVE_Zp2_Point( i, dx, dy, FALSE );
@@ -5879,6 +5976,9 @@
{
FT_F26Dot6 dx, dy;
FT_UShort point;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ FT_Int B1, B2;
+#endif
if ( CUR.top < CUR.GS.loop + 1 )
@@ -5893,13 +5993,13 @@
{
if ( CUR.GS.both_x_axis )
{
- dx = TT_MulFix14( (FT_UInt32)args[0], 0x4000 );
+ dx = (FT_UInt32)args[0];
dy = 0;
}
else
{
dx = 0;
- dy = TT_MulFix14( (FT_UInt32)args[0], 0x4000 );
+ dy = (FT_UInt32)args[0];
}
}
else
@@ -5924,7 +6024,80 @@
}
}
else
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ {
+ /* If not using ignore_x_mode rendering, allow ZP2 move. */
+ /* If inline deltas aren't allowed, skip ZP2 move. */
+ /* If using ignore_x_mode rendering, allow ZP2 point move if: */
+ /* - freedom vector is y and compatibility_mode is off */
+ /* - the glyph is composite and the move is in the Y direction */
+ /* - the glyph is specifically set to allow SHPIX moves */
+ /* - the move is on a previously Y-touched point */
+
+ if ( CUR.ignore_x_mode )
+ {
+ /* save point for later comparison */
+ if ( CUR.GS.freeVector.y != 0 )
+ B1 = CUR.zp2.cur[point].y;
+ else
+ B1 = CUR.zp2.cur[point].x;
+
+ if ( CUR.GS.freeVector.y != 0 &&
+ ( CUR.sph_tweak_flags & SPH_TWEAK_SKIP_INLINE_DELTAS ) )
+ goto Skip;
+
+ if ( CUR.ignore_x_mode &&
+ !CUR.compatibility_mode && CUR.GS.freeVector.y != 0 )
+ MOVE_Zp2_Point( point, dx, dy, TRUE );
+
+ else if ( CUR.ignore_x_mode && CUR.compatibility_mode )
+ {
+ if ( CUR.ignore_x_mode &&
+ ( CUR.sph_tweak_flags & SPH_TWEAK_ROUND_NONPIXEL_Y_MOVES ) )
+ {
+ dx = FT_PIX_ROUND( B1 + dx ) - B1;
+ dy = FT_PIX_ROUND( B1 + dy ) - B1;
+ }
+
+ if ( !( CUR.sph_tweak_flags & SPH_TWEAK_ALWAYS_SKIP_DELTAP ) &&
+ ( ( CUR.is_composite && CUR.GS.freeVector.y != 0 ) ||
+ ( CUR.zp2.tags[point] & FT_CURVE_TAG_TOUCH_Y ) ||
+ ( CUR.sph_tweak_flags & SPH_TWEAK_DO_SHPIX ) ) )
+ MOVE_Zp2_Point( point, dx, dy, TRUE );
+ }
+
+ /* save new point */
+ if ( CUR.GS.freeVector.y != 0 )
+ B2 = CUR.zp2.cur[point].y;
+ else
+ B2 = CUR.zp2.cur[point].x;
+
+ /* reverse any disallowed moves */
+ if ( ( ( CUR.sph_tweak_flags & SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES ) &&
+ CUR.GS.freeVector.y != 0 &&
+ B1 % 64 != 0 &&
+ B2 % 64 != 0 &&
+ B1 != B2 ) ||
+ ( ( CUR.sph_tweak_flags & SPH_TWEAK_SKIP_OFFPIXEL_Y_MOVES ) &&
+ CUR.GS.freeVector.y != 0 &&
+ B1 % 64 == 0 &&
+ B2 % 64 != 0 &&
+ B1 != B2 &&
+ !CUR.size->ttfautohinted ) )
+ {
+#ifdef SPH_DEBUG
+ printf( "Reversing ZP2 move\n" );
+#endif
+ MOVE_Zp2_Point( point, -dx, -dy, TRUE );
+ }
+ }
+ else
+ MOVE_Zp2_Point( point, dx, dy, TRUE );
+ }
+ Skip:
+#else
MOVE_Zp2_Point( point, dx, dy, TRUE );
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
CUR.GS.loop--;
}
@@ -5946,8 +6119,18 @@
{
FT_UShort point;
FT_F26Dot6 distance;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ FT_F26Dot6 control_value_cutin;
+ control_value_cutin = CUR.GS.control_value_cutin;
+
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.x != 0 &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_NORMAL_ROUND ) )
+ control_value_cutin = 0;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
point = (FT_UShort)args[0];
if ( BOUNDS( point, CUR.zp1.n_points ) ||
@@ -5970,6 +6153,14 @@
distance = CUR_Func_project( CUR.zp1.cur + point,
CUR.zp0.cur + CUR.GS.rp0 );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /* subpixel hinting - make MSIRP respect CVT cut-in; */
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.x != 0 &&
+ FT_ABS( distance - args[1] ) >= control_value_cutin )
+ distance = args[1];
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
CUR_Func_move( &CUR.zp1, point, args[1] - distance );
CUR.GS.rp1 = CUR.GS.rp0;
@@ -5990,8 +6181,8 @@
Ins_MDAP( INS_ARG )
{
FT_UShort point;
- FT_F26Dot6 cur_dist,
- distance;
+ FT_F26Dot6 cur_dist;
+ FT_F26Dot6 distance;
point = (FT_UShort)args[0];
@@ -6006,8 +6197,17 @@
if ( ( CUR.opcode & 1 ) != 0 )
{
cur_dist = CUR_fast_project( &CUR.zp0.cur[point] );
- distance = CUR_Func_round( cur_dist,
- CUR.tt_metrics.compensations[0] ) - cur_dist;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.x != 0 )
+ distance = ROUND_None(
+ cur_dist,
+ CUR.tt_metrics.compensations[0] ) - cur_dist;
+ else
+#endif
+ distance = CUR_Func_round(
+ cur_dist,
+ CUR.tt_metrics.compensations[0] ) - cur_dist;
}
else
distance = 0;
@@ -6030,12 +6230,21 @@
{
FT_ULong cvtEntry;
FT_UShort point;
- FT_F26Dot6 distance,
- org_dist;
+ FT_F26Dot6 distance;
+ FT_F26Dot6 org_dist;
+ FT_F26Dot6 control_value_cutin;
+
+ control_value_cutin = CUR.GS.control_value_cutin;
+ cvtEntry = (FT_ULong)args[1];
+ point = (FT_UShort)args[0];
- cvtEntry = (FT_ULong)args[1];
- point = (FT_UShort)args[0];
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.x != 0 &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_NORMAL_ROUND ) )
+ control_value_cutin = 0;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
if ( BOUNDS( point, CUR.zp0.n_points ) ||
BOUNDSL( cvtEntry, CUR.cvtSize ) )
@@ -6069,21 +6278,39 @@
if ( CUR.GS.gep0 == 0 ) /* If in twilight zone */
{
- CUR.zp0.org[point].x = TT_MulFix14( (FT_UInt32)distance,
- CUR.GS.freeVector.x );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /* only adjust legacy fonts x otherwise breaks Calibri italic */
+ if ( CUR.compatibility_mode )
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ CUR.zp0.org[point].x = TT_MulFix14( (FT_UInt32)distance,
+ CUR.GS.freeVector.x );
CUR.zp0.org[point].y = TT_MulFix14( (FT_UInt32)distance,
CUR.GS.freeVector.y ),
CUR.zp0.cur[point] = CUR.zp0.org[point];
}
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( ( CUR.sph_tweak_flags & SPH_TWEAK_MIAP_HACK ) &&
+ distance > 0 &&
+ CUR.GS.freeVector.y != 0 )
+ distance = 0;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
org_dist = CUR_fast_project( &CUR.zp0.cur[point] );
- if ( ( CUR.opcode & 1 ) != 0 ) /* rounding and control cutin flag */
+ if ( ( CUR.opcode & 1 ) != 0 ) /* rounding and control cut-in flag */
{
- if ( FT_ABS( distance - org_dist ) > CUR.GS.control_value_cutin )
+ if ( FT_ABS( distance - org_dist ) > control_value_cutin )
distance = org_dist;
- distance = CUR_Func_round( distance, CUR.tt_metrics.compensations[0] );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.x != 0 )
+ distance = ROUND_None( distance,
+ CUR.tt_metrics.compensations[0] );
+ else
+#endif
+ distance = CUR_Func_round( distance,
+ CUR.tt_metrics.compensations[0] );
}
CUR_Func_move( &CUR.zp0, point, distance - org_dist );
@@ -6104,7 +6331,17 @@
Ins_MDRP( INS_ARG )
{
FT_UShort point;
- FT_F26Dot6 org_dist, distance;
+ FT_F26Dot6 org_dist, distance, minimum_distance;
+
+
+ minimum_distance = CUR.GS.minimum_distance;
+
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.x != 0 &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_NORMAL_ROUND ) )
+ minimum_distance = 0;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
point = (FT_UShort)args[0];
@@ -6140,15 +6377,15 @@
{
/* this should be faster */
org_dist = CUR_Func_dualproj( vec1, vec2 );
- org_dist = TT_MULFIX( org_dist, CUR.metrics.x_scale );
+ org_dist = FT_MulFix( org_dist, CUR.metrics.x_scale );
}
else
{
FT_Vector vec;
- vec.x = TT_MULFIX( vec1->x - vec2->x, CUR.metrics.x_scale );
- vec.y = TT_MULFIX( vec1->y - vec2->y, CUR.metrics.y_scale );
+ vec.x = FT_MulFix( vec1->x - vec2->x, CUR.metrics.x_scale );
+ vec.y = FT_MulFix( vec1->y - vec2->y, CUR.metrics.y_scale );
org_dist = CUR_fast_dualproj( &vec );
}
@@ -6168,9 +6405,18 @@
/* round flag */
if ( ( CUR.opcode & 4 ) != 0 )
+ {
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode && CUR.GS.freeVector.x != 0 )
+ distance = ROUND_None(
+ org_dist,
+ CUR.tt_metrics.compensations[CUR.opcode & 3] );
+ else
+#endif
distance = CUR_Func_round(
org_dist,
CUR.tt_metrics.compensations[CUR.opcode & 3] );
+ }
else
distance = ROUND_None(
org_dist,
@@ -6182,13 +6428,13 @@
{
if ( org_dist >= 0 )
{
- if ( distance < CUR.GS.minimum_distance )
- distance = CUR.GS.minimum_distance;
+ if ( distance < minimum_distance )
+ distance = minimum_distance;
}
else
{
- if ( distance > -CUR.GS.minimum_distance )
- distance = -CUR.GS.minimum_distance;
+ if ( distance > -minimum_distance )
+ distance = -minimum_distance;
}
}
@@ -6223,11 +6469,27 @@
FT_F26Dot6 cvt_dist,
distance,
cur_dist,
- org_dist;
-
-
- point = (FT_UShort)args[0];
- cvtEntry = (FT_ULong)( args[1] + 1 );
+ org_dist,
+ control_value_cutin,
+ minimum_distance;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ FT_Int B1;
+ FT_Int B2;
+ FT_Bool reverse_move = FALSE;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
+
+ minimum_distance = CUR.GS.minimum_distance;
+ control_value_cutin = CUR.GS.control_value_cutin;
+ point = (FT_UShort)args[0];
+ cvtEntry = (FT_ULong)( args[1] + 1 );
+
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.x != 0 &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_NORMAL_ROUND ) )
+ control_value_cutin = minimum_distance = 0;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
/* XXX: UNDOCUMENTED! cvt[-1] = 0 always */
@@ -6244,6 +6506,10 @@
cvt_dist = 0;
else
cvt_dist = CUR_Func_read_cvt( cvtEntry - 1 );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.sph_tweak_flags & SPH_TWEAK_MIRP_CVT_ZERO )
+ cvt_dist = 0;
+#endif
/* single width test */
@@ -6266,7 +6532,7 @@
CUR.zp1.org[point].y = CUR.zp0.org[CUR.GS.rp0].y +
TT_MulFix14( (FT_UInt32)cvt_dist,
CUR.GS.freeVector.y );
- CUR.zp1.cur[point] = CUR.zp0.cur[point];
+ CUR.zp1.cur[point] = CUR.zp1.org[point];
}
org_dist = CUR_Func_dualproj( &CUR.zp1.org[point],
@@ -6281,8 +6547,17 @@
if ( ( org_dist ^ cvt_dist ) < 0 )
cvt_dist = -cvt_dist;
}
-
- /* control value cutin and round */
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.GS.freeVector.y != 0 &&
+ ( CUR.sph_tweak_flags & SPH_TWEAK_TIMES_NEW_ROMAN_HACK ) )
+ {
+ if ( cur_dist < -64 )
+ cvt_dist -= 16;
+ else if ( cur_dist > 64 && cur_dist < 84 )
+ cvt_dist += 32;
+ }
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ /* control value cut-in and round */
if ( ( CUR.opcode & 4 ) != 0 )
{
@@ -6303,7 +6578,7 @@
/* `ttinst2.doc', version 1.66, is thus incorrect since */
/* it implies `>=' instead of `>'. */
- if ( FT_ABS( cvt_dist - org_dist ) > CUR.GS.control_value_cutin )
+ if ( FT_ABS( cvt_dist - org_dist ) > control_value_cutin )
cvt_dist = org_dist;
}
@@ -6322,18 +6597,65 @@
{
if ( org_dist >= 0 )
{
- if ( distance < CUR.GS.minimum_distance )
- distance = CUR.GS.minimum_distance;
+ if ( distance < minimum_distance )
+ distance = minimum_distance;
}
else
{
- if ( distance > -CUR.GS.minimum_distance )
- distance = -CUR.GS.minimum_distance;
+ if ( distance > -minimum_distance )
+ distance = -minimum_distance;
}
}
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ B1 = CUR.zp1.cur[point].y;
+
+ /* Round moves if necessary */
+ if ( CUR.ignore_x_mode &&
+ CUR.GS.freeVector.y != 0 &&
+ ( CUR.sph_tweak_flags & SPH_TWEAK_ROUND_NONPIXEL_Y_MOVES ) )
+ distance = FT_PIX_ROUND( B1 + distance - cur_dist ) - B1 + cur_dist;
+
+ if ( CUR.GS.freeVector.y != 0 &&
+ ( CUR.opcode & 16 ) == 0 &&
+ ( CUR.opcode & 8 ) == 0 &&
+ ( CUR.sph_tweak_flags & SPH_TWEAK_COURIER_NEW_2_HACK ) )
+ distance += 64;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
CUR_Func_move( &CUR.zp1, point, distance - cur_dist );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ B2 = CUR.zp1.cur[point].y;
+
+ /* Reverse move if necessary */
+ if ( CUR.ignore_x_mode )
+ {
+ if ( ( CUR.sph_tweak_flags & SPH_TWEAK_SKIP_OFFPIXEL_Y_MOVES ) &&
+ CUR.GS.freeVector.y != 0 &&
+ B1 % 64 == 0 &&
+ B2 % 64 != 0 &&
+ !CUR.size->ttfautohinted )
+ reverse_move = TRUE;
+
+ if ( ( CUR.sph_tweak_flags & SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES ) &&
+ CUR.GS.freeVector.y != 0 &&
+ B2 % 64 != 0 &&
+ B1 % 64 != 0 )
+ reverse_move = TRUE;
+
+ if ( ( CUR.sph_tweak_flags &
+ SPH_TWEAK_DELTAP_SKIP_EXAGGERATED_VALUES ) &&
+ !reverse_move &&
+ FT_ABS( B1 - B2 ) >= 64 )
+ reverse_move = TRUE;
+ }
+
+ if ( reverse_move )
+ CUR_Func_move( &CUR.zp1, point, -( distance - cur_dist ) );
+
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
Fail:
CUR.GS.rp1 = CUR.GS.rp0;
@@ -6359,6 +6681,16 @@
FT_UNUSED_ARG;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode &&
+ CUR.iup_called &&
+ ( CUR.sph_tweak_flags & SPH_TWEAK_NO_ALIGNRP_AFTER_IUP ) )
+ {
+ CUR.error = TT_Err_Invalid_Reference;
+ goto Fail;
+ }
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
if ( CUR.top < CUR.GS.loop ||
BOUNDS( CUR.GS.rp0, CUR.zp0.n_points ) )
{
@@ -6411,7 +6743,7 @@
a0, a1,
b0, b1;
- FT_F26Dot6 discriminant;
+ FT_F26Dot6 discriminant, dotproduct;
FT_F26Dot6 dx, dy,
dax, day,
@@ -6440,6 +6772,8 @@
return;
}
+ /* Cramer's rule */
+
dbx = CUR.zp0.cur[b1].x - CUR.zp0.cur[b0].x;
dby = CUR.zp0.cur[b1].y - CUR.zp0.cur[b0].y;
@@ -6451,15 +6785,25 @@
CUR.zp2.tags[point] |= FT_CURVE_TAG_TOUCH_BOTH;
- discriminant = TT_MULDIV( dax, -dby, 0x40 ) +
- TT_MULDIV( day, dbx, 0x40 );
+ discriminant = FT_MulDiv( dax, -dby, 0x40 ) +
+ FT_MulDiv( day, dbx, 0x40 );
+ dotproduct = FT_MulDiv( dax, dbx, 0x40 ) +
+ FT_MulDiv( day, dby, 0x40 );
- if ( FT_ABS( discriminant ) >= 0x40 )
+ /* The discriminant above is actually a cross product of vectors */
+ /* da and db. Together with the dot product, they can be used as */
+ /* surrogates for sine and cosine of the angle between the vectors. */
+ /* Indeed, */
+ /* dotproduct = |da||db|cos(angle) */
+ /* discriminant = |da||db|sin(angle) . */
+ /* We use these equations to reject grazing intersections by */
+ /* thresholding abs(tan(angle)) at 1/19, corresponding to 3 degrees. */
+ if ( 19 * FT_ABS( discriminant ) > FT_ABS( dotproduct ) )
{
- val = TT_MULDIV( dx, -dby, 0x40 ) + TT_MULDIV( dy, dbx, 0x40 );
+ val = FT_MulDiv( dx, -dby, 0x40 ) + FT_MulDiv( dy, dbx, 0x40 );
- R.x = TT_MULDIV( val, dax, discriminant );
- R.y = TT_MULDIV( val, day, discriminant );
+ R.x = FT_MulDiv( val, dax, discriminant );
+ R.y = FT_MulDiv( val, day, discriminant );
CUR.zp2.cur[point].x = CUR.zp1.cur[a0].x + R.x;
CUR.zp2.cur[point].y = CUR.zp1.cur[a0].y + R.y;
@@ -6575,9 +6919,21 @@
if ( twilight )
old_range = CUR_Func_dualproj( &CUR.zp1.org[CUR.GS.rp2],
orus_base );
- else
+ else if ( CUR.metrics.x_scale == CUR.metrics.y_scale )
old_range = CUR_Func_dualproj( &CUR.zp1.orus[CUR.GS.rp2],
orus_base );
+ else
+ {
+ FT_Vector vec;
+
+
+ vec.x = FT_MulFix( CUR.zp1.orus[CUR.GS.rp2].x - orus_base->x,
+ CUR.metrics.x_scale );
+ vec.y = FT_MulFix( CUR.zp1.orus[CUR.GS.rp2].y - orus_base->y,
+ CUR.metrics.y_scale );
+
+ old_range = CUR_fast_dualproj( &vec );
+ }
cur_range = CUR_Func_project ( &CUR.zp1.cur[CUR.GS.rp2], cur_base );
}
@@ -6601,14 +6957,26 @@
if ( twilight )
org_dist = CUR_Func_dualproj( &CUR.zp2.org[point], orus_base );
- else
+ else if ( CUR.metrics.x_scale == CUR.metrics.y_scale )
org_dist = CUR_Func_dualproj( &CUR.zp2.orus[point], orus_base );
+ else
+ {
+ FT_Vector vec;
+
+
+ vec.x = FT_MulFix( CUR.zp2.orus[point].x - orus_base->x,
+ CUR.metrics.x_scale );
+ vec.y = FT_MulFix( CUR.zp2.orus[point].y - orus_base->y,
+ CUR.metrics.y_scale );
+
+ org_dist = CUR_fast_dualproj( &vec );
+ }
cur_dist = CUR_Func_project ( &CUR.zp2.cur[point], cur_base );
if ( org_dist )
new_dist = ( old_range != 0 )
- ? TT_MULDIV( org_dist, cur_range, old_range )
+ ? FT_MulDiv( org_dist, cur_range, old_range )
: cur_dist;
else
new_dist = 0;
@@ -6769,12 +7137,12 @@
if ( !scale_valid )
{
scale_valid = 1;
- scale = TT_MULDIV( org2 + delta2 - ( org1 + delta1 ),
- 0x10000L, orus2 - orus1 );
+ scale = FT_DivFix( org2 + delta2 - ( org1 + delta1 ),
+ orus2 - orus1 );
}
x = ( org1 + delta1 ) +
- TT_MULFIX( worker->orus[i].x - orus1, scale );
+ FT_MulFix( worker->orus[i].x - orus1, scale );
}
worker->curs[i].x = x;
}
@@ -6829,6 +7197,15 @@
contour = 0;
point = 0;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode )
+ {
+ CUR.iup_called = 1;
+ if ( CUR.sph_tweak_flags & SPH_TWEAK_SKIP_IUP )
+ return;
+ }
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
do
{
end_point = CUR.pts.contours[contour] - CUR.pts.first_point;
@@ -6898,6 +7275,9 @@
FT_UShort A;
FT_ULong C;
FT_Long B;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ FT_UShort B1, B2;
+#endif
#ifdef TT_CONFIG_OPTION_UNPATENTED_HINTING
@@ -6971,7 +7351,69 @@
B++;
B = B * 64 / ( 1L << CUR.GS.delta_shift );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /*
+ * Allow delta move if
+ *
+ * - not using ignore_x_mode rendering
+ * - glyph is specifically set to allow it
+ * - glyph is composite and freedom vector is not subpixel vector
+ */
+ if ( !CUR.ignore_x_mode ||
+ ( CUR.sph_tweak_flags & SPH_TWEAK_ALWAYS_DO_DELTAP ) ||
+ ( CUR.is_composite && CUR.GS.freeVector.y != 0 ) )
+ CUR_Func_move( &CUR.zp0, A, B );
+
+ /* Otherwise apply subpixel hinting and compatibility mode rules */
+ else if ( CUR.ignore_x_mode )
+ {
+ if ( CUR.GS.freeVector.y != 0 )
+ B1 = CUR.zp0.cur[A].y;
+ else
+ B1 = CUR.zp0.cur[A].x;
+
+ /* Standard Subpixel Hinting: Allow y move */
+ if ( !CUR.compatibility_mode && CUR.GS.freeVector.y != 0 )
+ CUR_Func_move( &CUR.zp0, A, B );
+
+ /* Compatibility Mode: Allow x or y move if point touched in
+ Y direction */
+ else if ( CUR.compatibility_mode &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_ALWAYS_SKIP_DELTAP ) )
+ {
+ /* save the y value of the point now; compare after move */
+ B1 = CUR.zp0.cur[A].y;
+
+ if ( ( CUR.sph_tweak_flags & SPH_TWEAK_ROUND_NONPIXEL_Y_MOVES ) )
+ B = FT_PIX_ROUND( B1 + B ) - B1;
+
+ /*
+ * Allow delta move if using compatibility_mode, IUP has not
+ * been called, and point is touched on Y.
+ */
+ if ( !CUR.iup_called &&
+ ( CUR.zp0.tags[A] & FT_CURVE_TAG_TOUCH_Y ) )
+ CUR_Func_move( &CUR.zp0, A, B );
+ }
+
+ B2 = CUR.zp0.cur[A].y;
+
+ /* Reverse this move if it results in a disallowed move */
+ if ( CUR.GS.freeVector.y != 0 &&
+ ( ( ( CUR.sph_tweak_flags &
+ SPH_TWEAK_SKIP_OFFPIXEL_Y_MOVES ) &&
+ B1 % 64 == 0 &&
+ B2 % 64 != 0 &&
+ !CUR.size->ttfautohinted ) ||
+ ( ( CUR.sph_tweak_flags &
+ SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES ) &&
+ B1 % 64 != 0 &&
+ B2 % 64 != 0 ) ) )
+ CUR_Func_move( &CUR.zp0, A, -B );
+ }
+#else
CUR_Func_move( &CUR.zp0, A, B );
+#endif /* *TT_CONFIG_OPTION_SUBPIXEL_HINTING */
}
}
else
@@ -7101,22 +7543,113 @@
K = 0;
- /* We return MS rasterizer version 1.7 for the font scaler. */
- if ( ( args[0] & 1 ) != 0 )
- K = 35;
-
- /* Has the glyph been rotated? */
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ /********************************/
+ /* RASTERIZER VERSION */
+ /* Selector Bit: 0 */
+ /* Return Bit(s): 0-7 */
+ /* */
+ if ( ( args[0] & 1 ) != 0 && CUR.ignore_x_mode )
+ {
+ K = CUR.rasterizer_version;
+#ifdef SPH_DEBUG_MORE_VERBOSE
+ printf(" SETTING AS %d\n", CUR.rasterizer_version );
+#endif
+ }
+ else
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ if ( ( args[0] & 1 ) != 0 )
+ K = 35;
+
+ /********************************/
+ /* GLYPH ROTATED */
+ /* Selector Bit: 1 */
+ /* Return Bit(s): 8 */
+ /* */
if ( ( args[0] & 2 ) != 0 && CUR.tt_metrics.rotated )
K |= 0x80;
- /* Has the glyph been stretched? */
+ /********************************/
+ /* GLYPH STRETCHED */
+ /* Selector Bit: 2 */
+ /* Return Bit(s): 9 */
+ /* */
if ( ( args[0] & 4 ) != 0 && CUR.tt_metrics.stretched )
K |= 1 << 8;
- /* Are we hinting for grayscale? */
+ /********************************/
+ /* HINTING FOR GRAYSCALE */
+ /* Selector Bit: 5 */
+ /* Return Bit(s): 12 */
+ /* */
if ( ( args[0] & 32 ) != 0 && CUR.grayscale )
K |= 1 << 12;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode && CUR.rasterizer_version >= 35 )
+ {
+ /********************************/
+ /* HINTING FOR GRAYSCALE */
+ /* Selector Bit: 5 */
+ /* Return Bit(s): 12 */
+ /* */
+ if ( ( args[0] & 32 ) != 0 && CUR.grayscale_hinting )
+ K |= 1 << 12;
+
+ /********************************/
+ /* HINTING FOR SUBPIXEL */
+ /* Selector Bit: 6 */
+ /* Return Bit(s): 13 */
+ /* */
+ if ( ( args[0] & 64 ) != 0 &&
+ CUR.subpixel_hinting &&
+ CUR.rasterizer_version >= 37 )
+ {
+ K |= 1 << 13;
+
+ /* the stuff below is irrelevant if subpixel_hinting is not set */
+
+ /********************************/
+ /* COMPATIBLE WIDTHS ENABLED */
+ /* Selector Bit: 7 */
+ /* Return Bit(s): 14 */
+ /* */
+ /* Functionality still needs to be added */
+ if ( ( args[0] & 128 ) != 0 && CUR.compatible_widths )
+ K |= 1 << 14;
+
+ /********************************/
+ /* SYMMETRICAL SMOOTHING */
+ /* Selector Bit: 8 */
+ /* Return Bit(s): 15 */
+ /* */
+ /* Functionality still needs to be added */
+ if ( ( args[0] & 256 ) != 0 && CUR.symmetrical_smoothing )
+ K |= 1 << 15;
+
+ /********************************/
+ /* HINTING FOR BGR? */
+ /* Selector Bit: 9 */
+ /* Return Bit(s): 16 */
+ /* */
+ /* Functionality still needs to be added */
+ if ( ( args[0] & 512 ) != 0 && CUR.bgr )
+ K |= 1 << 16;
+
+ if ( CUR.rasterizer_version >= 38 )
+ {
+ /********************************/
+ /* SUBPIXEL POSITIONED? */
+ /* Selector Bit: 10 */
+ /* Return Bit(s): 17 */
+ /* */
+ /* Functionality still needs to be added */
+ if ( ( args[0] & 1024 ) != 0 && CUR.subpixel_positioned )
+ K |= 1 << 17;
+ }
+ }
+ }
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
args[0] = K;
}
@@ -7149,6 +7682,7 @@
call->Caller_IP = CUR.IP + 1;
call->Cur_Count = 1;
call->Cur_Restart = def->start;
+ call->Cur_End = def->end;
INS_Goto_CodeRange( def->range, def->start );
@@ -7491,6 +8025,11 @@
cur = *exc;
#endif
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode )
+ CUR.iup_called = FALSE;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
/* set CVT functions */
CUR.tt_metrics.ratio = 0;
if ( CUR.metrics.x_ppem != CUR.metrics.y_ppem )
@@ -7521,7 +8060,7 @@
if ( ( CUR.length = opcode_length[CUR.opcode] ) < 0 )
{
- if ( CUR.IP + 1 > CUR.codeSize )
+ if ( CUR.IP + 1 >= CUR.codeSize )
goto LErrorCodeOverflow_;
CUR.length = 2 - CUR.length * CUR.code[CUR.IP + 1];
@@ -7762,7 +8301,13 @@
break;
case 0x2B: /* CALL */
- Ins_CALL( EXEC_ARG_ args );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( !CUR.ignore_x_mode ||
+ !CUR.iup_called ||
+ ( CUR.iup_called &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_NO_CALL_AFTER_IUP ) ) )
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ Ins_CALL( EXEC_ARG_ args );
break;
case 0x2C: /* FDEF */
@@ -7778,10 +8323,13 @@
Ins_MDAP( EXEC_ARG_ args );
break;
-
case 0x30: /* IUP */
case 0x31: /* IUP */
- Ins_IUP( EXEC_ARG_ args );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( CUR.ignore_x_mode )
+ CUR.iup_called = TRUE;
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ Ins_IUP( EXEC_ARG_ args );
break;
case 0x32: /* SHP */
@@ -7940,7 +8488,13 @@
break;
case 0x5D: /* DELTAP1 */
- Ins_DELTAP( EXEC_ARG_ args );
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ if ( !CUR.ignore_x_mode ||
+ !CUR.iup_called ||
+ ( CUR.iup_called &&
+ !( CUR.sph_tweak_flags & SPH_TWEAK_NO_DELTAP_AFTER_IUP ) ) )
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+ Ins_DELTAP( EXEC_ARG_ args );
break;
case 0x5E: /* SDB */
@@ -8157,6 +8711,7 @@
callrec->Caller_IP = CUR.IP + 1;
callrec->Cur_Count = 1;
callrec->Cur_Restart = def->start;
+ callrec->Cur_End = def->end;
if ( INS_Goto_CodeRange( def->range, def->start ) == FAILURE )
goto LErrorLabel_;
@@ -8230,7 +8785,7 @@
if ( CUR.error && !CUR.instruction_trap )
{
FT_TRACE1(( " The interpreter returned error 0x%x\n", CUR.error ));
- exc->size->cvt_ready = FALSE;
+ exc->size->cvt_ready = FALSE;
}
return CUR.error;
diff --git a/3party/freetype/src/truetype/ttinterp.h b/3party/freetype/src/truetype/ttinterp.h
index c480dfa506..f4336121b6 100644
--- a/3party/freetype/src/truetype/ttinterp.h
+++ b/3party/freetype/src/truetype/ttinterp.h
@@ -4,7 +4,7 @@
/* */
/* TrueType bytecode interpreter (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2010 by */
+/* Copyright 1996-2007, 2010, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -102,10 +102,53 @@ FT_BEGIN_HEADER
FT_Long Caller_IP;
FT_Long Cur_Count;
FT_Long Cur_Restart;
+ FT_Long Cur_End;
} TT_CallRec, *TT_CallStack;
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+ /*************************************************************************/
+ /* */
+ /* These structures define rules used to tweak subpixel hinting for */
+ /* various fonts. "", 0, "", NULL value indicates to match any value. */
+ /* */
+
+#define MAX_NAME_SIZE 32
+#define MAX_CLASS_MEMBERS 100
+
+ typedef struct SPH_TweakRule_
+ {
+ const char family[MAX_NAME_SIZE];
+ const FT_UInt ppem;
+ const char style[MAX_NAME_SIZE];
+ const FT_ULong glyph;
+
+ } SPH_TweakRule;
+
+
+ typedef struct SPH_ScaleRule_
+ {
+ const char family[MAX_NAME_SIZE];
+ const FT_UInt ppem;
+ const char style[MAX_NAME_SIZE];
+ const FT_ULong glyph;
+ const FT_ULong scale;
+
+ } SPH_ScaleRule;
+
+
+ typedef struct Font_Class_
+ {
+ const char name[MAX_NAME_SIZE];
+ const char member[MAX_CLASS_MEMBERS][MAX_NAME_SIZE];
+
+ } Font_Class;
+
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
+
/*************************************************************************/
/* */
/* The main structure for the interpreter which collects all necessary */
@@ -217,12 +260,43 @@ FT_BEGIN_HEADER
FT_Bool grayscale; /* are we hinting for grayscale? */
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+ TT_Round_Func func_round_sphn; /* subpixel rounding function */
+
+ FT_Bool grayscale_hinting; /* Using grayscale hinting? */
+ FT_Bool subpixel_hinting; /* Using subpixel hinting? */
+ FT_Bool native_hinting; /* Using native hinting? */
+ FT_Bool ignore_x_mode; /* Standard rendering mode for */
+ /* subpixel hinting. On if gray */
+ /* or subpixel hinting is on ) */
+ FT_Bool compatibility_mode;/* Additional exceptions to */
+ /* native TT rules for legacy */
+ /* fonts. Implies */
+ /* ignore_x_mode. */
+
+ /* The following 4 aren't fully implemented but here for MS rasterizer */
+ /* compatibility. */
+ FT_Bool compatible_widths; /* compatible widths? */
+ FT_Bool symmetrical_smoothing; /* symmetrical_smoothing? */
+ FT_Bool bgr; /* bgr instead of rgb? */
+ FT_Bool subpixel_positioned; /* subpixel positioned */
+ /* (DirectWrite ClearType)? */
+
+ FT_Int rasterizer_version; /* MS rasterizer version */
+
+ FT_Bool iup_called; /* IUP called for glyph? */
+
+ FT_ULong sph_tweak_flags; /* flags to control */
+ /* hint tweaks */
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
} TT_ExecContextRec;
extern const TT_GraphicsState tt_default_graphics_state;
+#ifdef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
FT_LOCAL( FT_Error )
TT_Goto_CodeRange( TT_ExecContext exec,
FT_Int range,
@@ -245,6 +319,7 @@ FT_BEGIN_HEADER
FT_Long multiplier,
void* _pbuff,
FT_ULong new_max );
+#endif /* TT_CONFIG_OPTION_BYTECODE_INTERPRETER */
/*************************************************************************/
@@ -269,6 +344,8 @@ FT_BEGIN_HEADER
FT_EXPORT( TT_ExecContext )
TT_New_Context( TT_Driver driver );
+
+#ifdef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
FT_LOCAL( FT_Error )
TT_Done_Context( TT_ExecContext exec );
@@ -284,6 +361,7 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Error )
TT_Run_Context( TT_ExecContext exec,
FT_Bool debug );
+#endif /* TT_CONFIG_OPTION_BYTECODE_INTERPRETER */
/*************************************************************************/
diff --git a/3party/freetype/src/truetype/ttobjs.c b/3party/freetype/src/truetype/ttobjs.c
index d77c3c4210..c61b218c2d 100644
--- a/3party/freetype/src/truetype/ttobjs.c
+++ b/3party/freetype/src/truetype/ttobjs.c
@@ -4,7 +4,7 @@
/* */
/* Objects manager (body). */
/* */
-/* Copyright 1996-2011 */
+/* Copyright 1996-2012 */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -244,7 +244,7 @@
tt_check_trickyness_sfnt_ids( TT_Face face )
{
#define TRICK_SFNT_IDS_PER_FACE 3
-#define TRICK_SFNT_IDS_NUM_FACES 13
+#define TRICK_SFNT_IDS_NUM_FACES 17
static const tt_sfnt_id_rec sfnt_id[TRICK_SFNT_IDS_NUM_FACES]
[TRICK_SFNT_IDS_PER_FACE] = {
@@ -317,6 +317,26 @@
{ 0x00000000, 0x00000000 }, /* cvt */
{ 0x0d3de9cb, 0x00000141 }, /* fpgm */
{ 0xd4127766, 0x00002280 } /* prep */
+ },
+ { /* NEC FA-Gothic, 1996 */
+ { 0x00000000, 0x00000000 }, /* cvt */
+ { 0x4a692698, 0x000001f0 }, /* fpgm */
+ { 0x340d4346, 0x00001fca } /* prep */
+ },
+ { /* NEC FA-Minchou, 1996 */
+ { 0x00000000, 0x00000000 }, /* cvt */
+ { 0xcd34c604, 0x00000166 }, /* fpgm */
+ { 0x6cf31046, 0x000022b0 } /* prep */
+ },
+ { /* NEC FA-RoundGothicB, 1996 */
+ { 0x00000000, 0x00000000 }, /* cvt */
+ { 0x5da75315, 0x0000019d }, /* fpgm */
+ { 0x40745a5f, 0x000022e0 } /* prep */
+ },
+ { /* NEC FA-RoundGothicM, 1996 */
+ { 0x00000000, 0x00000000 }, /* cvt */
+ { 0xf055fc48, 0x000001c2 }, /* fpgm */
+ { 0x3900ded3, 0x00001e18 } /* prep */
}
};
@@ -328,7 +348,7 @@
FT_MEM_SET( num_matched_ids, 0,
- sizeof( int ) * TRICK_SFNT_IDS_NUM_FACES );
+ sizeof ( int ) * TRICK_SFNT_IDS_NUM_FACES );
has_cvt = FALSE;
has_fpgm = FALSE;
has_prep = FALSE;
@@ -493,10 +513,17 @@
TT_Face face = (TT_Face)ttface;
+ FT_TRACE2(( "TTF driver\n" ));
+
library = ttface->driver->root.library;
- sfnt = (SFNT_Service)FT_Get_Module_Interface( library, "sfnt" );
+
+ sfnt = (SFNT_Service)FT_Get_Module_Interface( library, "sfnt" );
if ( !sfnt )
- goto Bad_Format;
+ {
+ FT_ERROR(( "tt_face_init: cannot access `sfnt' module\n" ));
+ error = TT_Err_Missing_Module;
+ goto Exit;
+ }
/* create input stream from resource */
if ( FT_STREAM_SEEK( 0 ) )
@@ -514,7 +541,7 @@
face->format_tag != 0x00020000L && /* CJK fonts for Win 3.1 */
face->format_tag != TTAG_true ) /* Mac fonts */
{
- FT_TRACE2(( "[not a valid TTF font]\n" ));
+ FT_TRACE2(( " not a TTF font\n" ));
goto Bad_Format;
}
@@ -737,7 +764,7 @@
exec->threshold = 0;
exec->instruction_trap = FALSE;
- exec->F_dot_P = 0x10000L;
+ exec->F_dot_P = 0x4000L;
exec->pedantic_hinting = pedantic;
@@ -1163,16 +1190,14 @@
size->ttmetrics.scale = metrics->x_scale;
size->ttmetrics.ppem = metrics->x_ppem;
size->ttmetrics.x_ratio = 0x10000L;
- size->ttmetrics.y_ratio = FT_MulDiv( metrics->y_ppem,
- 0x10000L,
+ size->ttmetrics.y_ratio = FT_DivFix( metrics->y_ppem,
metrics->x_ppem );
}
else
{
size->ttmetrics.scale = metrics->y_scale;
size->ttmetrics.ppem = metrics->y_ppem;
- size->ttmetrics.x_ratio = FT_MulDiv( metrics->x_ppem,
- 0x10000L,
+ size->ttmetrics.x_ratio = FT_DivFix( metrics->x_ppem,
metrics->y_ppem );
size->ttmetrics.y_ratio = 0x10000L;
}
diff --git a/3party/freetype/src/truetype/ttobjs.h b/3party/freetype/src/truetype/ttobjs.h
index 087b3c2e1b..5c3cb067e4 100644
--- a/3party/freetype/src/truetype/ttobjs.h
+++ b/3party/freetype/src/truetype/ttobjs.h
@@ -4,7 +4,7 @@
/* */
/* Objects manager (specification). */
/* */
-/* Copyright 1996-2009, 2011 by */
+/* Copyright 1996-2009, 2011-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -173,10 +173,12 @@ FT_BEGIN_HEADER
/* */
typedef struct TT_DefRecord_
{
- FT_Int range; /* in which code range is it located? */
- FT_Long start; /* where does it start? */
- FT_UInt opc; /* function #, or instruction code */
- FT_Bool active; /* is it active? */
+ FT_Int range; /* in which code range is it located? */
+ FT_Long start; /* where does it start? */
+ FT_Long end; /* where does it end? */
+ FT_UInt opc; /* function #, or instruction code */
+ FT_Bool active; /* is it active? */
+ FT_Bool inline_delta; /* is function that defines inline delta? */
} TT_DefRecord, *TT_DefArray;
@@ -189,7 +191,7 @@ FT_BEGIN_HEADER
{
FT_Fixed xx, xy; /* transformation matrix coefficients */
FT_Fixed yx, yy;
- FT_F26Dot6 ox, oy; /* offsets */
+ FT_F26Dot6 ox, oy; /* offsets */
} TT_Transform;
@@ -332,6 +334,7 @@ FT_BEGIN_HEADER
FT_Bool bytecode_ready;
FT_Bool cvt_ready;
+ FT_Bool ttfautohinted;
#endif /* TT_USE_BYTECODE_INTERPRETER */
@@ -426,6 +429,10 @@ FT_BEGIN_HEADER
tt_slot_init( FT_GlyphSlot slot );
+ /* auxiliary */
+#define IS_HINTED( flags ) ( ( flags & FT_LOAD_NO_HINTING ) == 0 )
+
+
FT_END_HEADER
#endif /* __TTOBJS_H__ */
diff --git a/3party/freetype/src/truetype/ttpic.c b/3party/freetype/src/truetype/ttpic.c
index 5d725742c7..faece4e811 100644
--- a/3party/freetype/src/truetype/ttpic.c
+++ b/3party/freetype/src/truetype/ttpic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for truetype module. */
/* */
-/* Copyright 2009, 2010 by */
+/* Copyright 2009, 2010, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,25 +20,42 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include "ttpic.h"
+#include "tterrors.h"
#ifdef FT_CONFIG_OPTION_PIC
/* forward declaration of PIC init functions from ttdriver.c */
- FT_Error FT_Create_Class_tt_services( FT_Library, FT_ServiceDescRec**);
- void FT_Destroy_Class_tt_services( FT_Library, FT_ServiceDescRec*);
- void FT_Init_Class_tt_service_gx_multi_masters(FT_Service_MultiMastersRec*);
- void FT_Init_Class_tt_service_truetype_glyf(FT_Service_TTGlyfRec*);
+ FT_Error
+ FT_Create_Class_tt_services( FT_Library library,
+ FT_ServiceDescRec** output_class );
+
+ void
+ FT_Destroy_Class_tt_services( FT_Library library,
+ FT_ServiceDescRec* clazz );
+
+ void
+ FT_Init_Class_tt_service_gx_multi_masters(
+ FT_Service_MultiMastersRec* sv_mm );
+
+ void
+ FT_Init_Class_tt_service_truetype_glyf(
+ FT_Service_TTGlyfRec* sv_ttglyf );
+
void
- tt_driver_class_pic_free( FT_Library library )
+ tt_driver_class_pic_free( FT_Library library )
{
- FT_PIC_Container* pic_container = &library->pic_container;
- FT_Memory memory = library->memory;
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+
+
if ( pic_container->truetype )
{
- TTModulePIC* container = (TTModulePIC*)pic_container->truetype;
- if(container->tt_services)
- FT_Destroy_Class_tt_services(library, container->tt_services);
+ TTModulePIC* container = (TTModulePIC*)pic_container->truetype;
+
+
+ if ( container->tt_services )
+ FT_Destroy_Class_tt_services( library, container->tt_services );
container->tt_services = NULL;
FT_FREE( container );
pic_container->truetype = NULL;
@@ -51,27 +68,32 @@
{
FT_PIC_Container* pic_container = &library->pic_container;
FT_Error error = TT_Err_Ok;
- TTModulePIC* container;
+ TTModulePIC* container = NULL;
FT_Memory memory = library->memory;
/* allocate pointer, clear and set global container pointer */
if ( FT_ALLOC ( container, sizeof ( *container ) ) )
return error;
- FT_MEM_SET( container, 0, sizeof(*container) );
+ FT_MEM_SET( container, 0, sizeof ( *container ) );
pic_container->truetype = container;
- /* initialize pointer table - this is how the module usually expects this data */
- error = FT_Create_Class_tt_services(library, &container->tt_services);
- if(error)
+ /* initialize pointer table - this is how the module usually */
+ /* expects this data */
+ error = FT_Create_Class_tt_services( library,
+ &container->tt_services );
+ if ( error )
goto Exit;
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
- FT_Init_Class_tt_service_gx_multi_masters(&container->tt_service_gx_multi_masters);
+ FT_Init_Class_tt_service_gx_multi_masters(
+ &container->tt_service_gx_multi_masters );
#endif
- FT_Init_Class_tt_service_truetype_glyf(&container->tt_service_truetype_glyf);
+ FT_Init_Class_tt_service_truetype_glyf(
+ &container->tt_service_truetype_glyf );
+
Exit:
- if(error)
- tt_driver_class_pic_free(library);
+ if ( error )
+ tt_driver_class_pic_free( library );
return error;
}
diff --git a/3party/freetype/src/truetype/ttpic.h b/3party/freetype/src/truetype/ttpic.h
index 84de0fee9e..625c9f1697 100644
--- a/3party/freetype/src/truetype/ttpic.h
+++ b/3party/freetype/src/truetype/ttpic.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType position independent code services for truetype module. */
/* */
-/* Copyright 2009 by */
+/* Copyright 2009, 2012 by */
/* Oran Agra and Mickey Gabel. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,13 +19,14 @@
#ifndef __TTPIC_H__
#define __TTPIC_H__
-
+
FT_BEGIN_HEADER
#ifndef FT_CONFIG_OPTION_PIC
-#define FT_TT_SERVICES_GET tt_services
-#define FT_TT_SERVICE_GX_MULTI_MASTERS_GET tt_service_gx_multi_masters
-#define FT_TT_SERVICE_TRUETYPE_GLYF_GET tt_service_truetype_glyf
+
+#define TT_SERVICES_GET tt_services
+#define TT_SERVICE_GX_MULTI_MASTERS_GET tt_service_gx_multi_masters
+#define TT_SERVICE_TRUETYPE_GLYF_GET tt_service_truetype_glyf
#else /* FT_CONFIG_OPTION_PIC */
@@ -33,19 +34,34 @@ FT_BEGIN_HEADER
#include FT_SERVICE_MULTIPLE_MASTERS_H
#include FT_SERVICE_TRUETYPE_GLYF_H
- typedef struct TTModulePIC_
+
+ typedef struct TTModulePIC_
{
- FT_ServiceDescRec* tt_services;
+ FT_ServiceDescRec* tt_services;
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
FT_Service_MultiMastersRec tt_service_gx_multi_masters;
#endif
- FT_Service_TTGlyfRec tt_service_truetype_glyf;
+ FT_Service_TTGlyfRec tt_service_truetype_glyf;
+
} TTModulePIC;
-#define GET_PIC(lib) ((TTModulePIC*)((lib)->pic_container.truetype))
-#define FT_TT_SERVICES_GET (GET_PIC(library)->tt_services)
-#define FT_TT_SERVICE_GX_MULTI_MASTERS_GET (GET_PIC(library)->tt_service_gx_multi_masters)
-#define FT_TT_SERVICE_TRUETYPE_GLYF_GET (GET_PIC(library)->tt_service_truetype_glyf)
+
+#define GET_PIC( lib ) \
+ ( (TTModulePIC*)((lib)->pic_container.truetype) )
+#define TT_SERVICES_GET \
+ ( GET_PIC( library )->tt_services )
+#define TT_SERVICE_GX_MULTI_MASTERS_GET \
+ ( GET_PIC( library )->tt_service_gx_multi_masters )
+#define TT_SERVICE_TRUETYPE_GLYF_GET \
+ ( GET_PIC( library )->tt_service_truetype_glyf )
+
+
+ /* see ttpic.c for the implementation */
+ void
+ tt_driver_class_pic_free( FT_Library library );
+
+ FT_Error
+ tt_driver_class_pic_init( FT_Library library );
#endif /* FT_CONFIG_OPTION_PIC */
diff --git a/3party/freetype/src/truetype/ttpload.c b/3party/freetype/src/truetype/ttpload.c
index 818b29d263..bb6005d45e 100644
--- a/3party/freetype/src/truetype/ttpload.c
+++ b/3party/freetype/src/truetype/ttpload.c
@@ -4,7 +4,7 @@
/* */
/* TrueType-specific tables loader (body). */
/* */
-/* Copyright 1996-2002, 2004-2011 by */
+/* Copyright 1996-2002, 2004-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -211,22 +211,22 @@
}
/* Check broken location data */
- if ( pos1 >= face->glyf_len )
+ if ( pos1 > face->glyf_len )
{
FT_TRACE1(( "tt_face_get_location:"
- " too large offset=0x%08lx found for gid=0x%04lx,"
- " exceeding the end of glyf table (0x%08lx)\n",
- pos1, gindex, face->glyf_len ));
+ " too large offset=0x%08lx found for gid=0x%04lx,"
+ " exceeding the end of glyf table (0x%08lx)\n",
+ pos1, gindex, face->glyf_len ));
*asize = 0;
return 0;
}
- if ( pos2 >= face->glyf_len )
+ if ( pos2 > face->glyf_len )
{
FT_TRACE1(( "tt_face_get_location:"
- " too large offset=0x%08lx found for gid=0x%04lx,"
- " truncate at the end of glyf table (0x%08lx)\n",
- pos2, gindex + 1, face->glyf_len ));
+ " too large offset=0x%08lx found for gid=0x%04lx,"
+ " truncate at the end of glyf table (0x%08lx)\n",
+ pos2, gindex + 1, face->glyf_len ));
pos2 = face->glyf_len;
}
diff --git a/3party/freetype/src/truetype/ttsubpix.c b/3party/freetype/src/truetype/ttsubpix.c
new file mode 100644
index 0000000000..d09d3d89d1
--- /dev/null
+++ b/3party/freetype/src/truetype/ttsubpix.c
@@ -0,0 +1,265 @@
+/***************************************************************************/
+/* */
+/* ttsubpix.c */
+/* */
+/* TrueType Subpixel Hinting. */
+/* */
+/* Copyright 2010-2012 by */
+/* David Turner, Robert Wilhelm, and Werner Lemberg. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+#include <ft2build.h>
+#include FT_INTERNAL_DEBUG_H
+#include FT_INTERNAL_CALC_H
+#include FT_INTERNAL_STREAM_H
+#include FT_INTERNAL_SFNT_H
+#include FT_TRUETYPE_TAGS_H
+#include FT_OUTLINE_H
+
+#include "ttsubpix.h"
+
+
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+ FT_LOCAL_DEF( FT_Bool )
+ is_member_of_family_class( const FT_String* detected_font_name,
+ const FT_String* rule_font_name )
+ {
+ FT_UInt i, j;
+
+
+ /* Does font name match rule family? */
+ if ( strcmp( detected_font_name, rule_font_name ) == 0 )
+ return TRUE;
+
+ /* Is font name a wildcard ""? */
+ if ( strcmp( rule_font_name, "" ) == 0 )
+ return TRUE;
+
+ /* Is font name contained in a class list? */
+ for ( i = 0; i < FAMILY_CLASS_RULES_SIZE; i++ )
+ {
+ if ( strcmp( FAMILY_CLASS_Rules[i].name, rule_font_name ) == 0 )
+ {
+ for ( j = 0; j < MAX_CLASS_MEMBERS; j++ )
+ {
+ if ( strcmp( FAMILY_CLASS_Rules[i].member[j], "" ) == 0 )
+ continue;
+ if ( strcmp( FAMILY_CLASS_Rules[i].member[j],
+ detected_font_name ) == 0 )
+ return TRUE;
+ }
+ }
+ }
+
+ return FALSE;
+ }
+
+
+ FT_LOCAL_DEF( FT_Bool )
+ is_member_of_style_class( const FT_String* detected_font_style,
+ const FT_String* rule_font_style )
+ {
+ FT_UInt i, j;
+
+
+ /* Does font style match rule style? */
+ if ( strcmp( detected_font_style, rule_font_style ) == 0 )
+ return TRUE;
+
+ /* Is font style a wildcard ""? */
+ if ( strcmp( rule_font_style, "" ) == 0 )
+ return TRUE;
+
+ /* Is font style contained in a class list? */
+ for ( i = 0; i < STYLE_CLASS_RULES_SIZE; i++ )
+ {
+ if ( strcmp( STYLE_CLASS_Rules[i].name, rule_font_style ) == 0 )
+ {
+ for ( j = 0; j < MAX_CLASS_MEMBERS; j++ )
+ {
+ if ( strcmp( STYLE_CLASS_Rules[i].member[j], "" ) == 0 )
+ continue;
+ if ( strcmp( STYLE_CLASS_Rules[i].member[j],
+ detected_font_style ) == 0 )
+ return TRUE;
+ }
+ }
+ }
+
+ return FALSE;
+ }
+
+
+ FT_LOCAL_DEF( FT_Bool )
+ sph_test_tweak( TT_Face face,
+ FT_String* family,
+ FT_UInt ppem,
+ FT_String* style,
+ FT_UInt glyph_index,
+ SPH_TweakRule* rule,
+ FT_UInt num_rules )
+ {
+ FT_UInt i;
+
+
+ /* rule checks may be able to be optimized further */
+ for ( i = 0; i < num_rules; i++ )
+ {
+ if ( family &&
+ ( is_member_of_family_class ( family, rule[i].family ) ) )
+ if ( rule[i].ppem == 0 ||
+ rule[i].ppem == ppem )
+ if ( style &&
+ is_member_of_style_class ( style, rule[i].style ) )
+ if ( rule[i].glyph == 0 ||
+ FT_Get_Char_Index( (FT_Face)face,
+ rule[i].glyph ) == glyph_index )
+ return TRUE;
+ }
+
+ return FALSE;
+ }
+
+
+ FT_LOCAL_DEF( FT_UInt )
+ scale_test_tweak( TT_Face face,
+ FT_String* family,
+ FT_UInt ppem,
+ FT_String* style,
+ FT_UInt glyph_index,
+ SPH_ScaleRule* rule,
+ FT_UInt num_rules )
+ {
+ FT_UInt i;
+
+
+ /* rule checks may be able to be optimized further */
+ for ( i = 0; i < num_rules; i++ )
+ {
+ if ( family &&
+ ( is_member_of_family_class ( family, rule[i].family ) ) )
+ if ( rule[i].ppem == 0 ||
+ rule[i].ppem == ppem )
+ if ( style &&
+ is_member_of_style_class( style, rule[i].style ) )
+ if ( rule[i].glyph == 0 ||
+ FT_Get_Char_Index( (FT_Face)face,
+ rule[i].glyph ) == glyph_index )
+ return rule[i].scale;
+ }
+
+ return 1000;
+ }
+
+
+#define TWEAK_RULES( x ) \
+ if ( sph_test_tweak( face, family, ppem, style, glyph_index, \
+ x##_Rules, x##_RULES_SIZE ) ) \
+ loader->exec->sph_tweak_flags |= SPH_TWEAK_##x;
+
+#define TWEAK_RULES_EXCEPTIONS( x ) \
+ if ( sph_test_tweak( face, family, ppem, style, glyph_index, \
+ x##_Rules_Exceptions, x##_RULES_EXCEPTIONS_SIZE ) ) \
+ loader->exec->sph_tweak_flags &= ~SPH_TWEAK_##x;
+
+
+ FT_LOCAL_DEF( void )
+ sph_set_tweaks( TT_Loader loader,
+ FT_UInt glyph_index )
+ {
+ TT_Face face = (TT_Face)loader->face;
+ FT_String* family = face->root.family_name;
+ int ppem = loader->size->metrics.x_ppem;
+ FT_String* style = face->root.style_name;
+
+
+ /* don't apply rules if style isn't set */
+ if ( !face->root.style_name )
+ return;
+
+#ifdef SPH_DEBUG_MORE_VERBOSE
+ printf( "%s,%d,%s,%c=%d ",
+ family, ppem, style, glyph_index, glyph_index );
+#endif
+
+ TWEAK_RULES( PIXEL_HINTING );
+
+ if ( loader->exec->sph_tweak_flags & SPH_TWEAK_PIXEL_HINTING )
+ {
+ loader->exec->ignore_x_mode = FALSE;
+ return;
+ }
+
+ TWEAK_RULES( ALLOW_X_DMOVE );
+ TWEAK_RULES( ALLOW_X_DMOVEX );
+ TWEAK_RULES( ALLOW_X_MOVE_ZP2 );
+ TWEAK_RULES( ALWAYS_DO_DELTAP );
+ TWEAK_RULES( ALWAYS_SKIP_DELTAP );
+ TWEAK_RULES( DEEMBOLDEN );
+ TWEAK_RULES( DELTAP_SKIP_EXAGGERATED_VALUES );
+ TWEAK_RULES( DO_SHPIX );
+ TWEAK_RULES( EMBOLDEN );
+ TWEAK_RULES( MIAP_HACK );
+ TWEAK_RULES( NORMAL_ROUND );
+ TWEAK_RULES( NO_ALIGNRP_AFTER_IUP );
+ TWEAK_RULES( NO_CALL_AFTER_IUP );
+ TWEAK_RULES( NO_DELTAP_AFTER_IUP );
+ TWEAK_RULES( RASTERIZER_35 );
+ TWEAK_RULES( SKIP_INLINE_DELTAS );
+ TWEAK_RULES( SKIP_IUP );
+ TWEAK_RULES( MIRP_CVT_ZERO );
+
+ TWEAK_RULES( SKIP_OFFPIXEL_Y_MOVES );
+ TWEAK_RULES_EXCEPTIONS( SKIP_OFFPIXEL_Y_MOVES );
+
+ TWEAK_RULES( SKIP_NONPIXEL_Y_MOVES );
+ TWEAK_RULES_EXCEPTIONS( SKIP_NONPIXEL_Y_MOVES );
+
+ TWEAK_RULES( ROUND_NONPIXEL_Y_MOVES );
+ TWEAK_RULES_EXCEPTIONS( ROUND_NONPIXEL_Y_MOVES );
+
+ if ( loader->exec->sph_tweak_flags & SPH_TWEAK_RASTERIZER_35 )
+ loader->exec->rasterizer_version = 35;
+ else
+ loader->exec->rasterizer_version = SPH_OPTION_SET_RASTERIZER_VERSION;
+
+ /* re-execute fpgm always to avoid problems */
+ loader->exec->size->cvt_ready = FALSE;
+ tt_size_ready_bytecode( loader->exec->size,
+ FT_BOOL( loader->load_flags & FT_LOAD_PEDANTIC ) );
+
+ if ( IS_HINTED( loader->load_flags ) )
+ {
+ TWEAK_RULES( TIMES_NEW_ROMAN_HACK );
+ TWEAK_RULES( COURIER_NEW_2_HACK );
+ }
+
+ if ( sph_test_tweak( face, family, ppem, style, glyph_index,
+ COMPATIBILITY_MODE_Rules, COMPATIBILITY_MODE_RULES_SIZE ) )
+ {
+ loader->exec->compatibility_mode |= TRUE;
+ loader->exec->ignore_x_mode |= TRUE;
+ }
+ else
+ loader->exec->compatibility_mode &= FALSE;
+
+ if ( IS_HINTED( loader->load_flags ) )
+ {
+ if ( sph_test_tweak( face, family, ppem, style, glyph_index,
+ COMPATIBLE_WIDTHS_Rules, COMPATIBLE_WIDTHS_RULES_SIZE ) )
+ loader->exec->compatible_widths |= TRUE;
+ }
+ }
+
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
+
+/* END */
diff --git a/3party/freetype/src/truetype/ttsubpix.h b/3party/freetype/src/truetype/ttsubpix.h
new file mode 100644
index 0000000000..2fbff2681c
--- /dev/null
+++ b/3party/freetype/src/truetype/ttsubpix.h
@@ -0,0 +1,908 @@
+/***************************************************************************/
+/* */
+/* ttsubpix.h */
+/* */
+/* TrueType Subpixel Hinting. */
+/* */
+/* Copyright 2010-2012 by */
+/* David Turner, Robert Wilhelm, and Werner Lemberg. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __TTSUBPIX_H__
+#define __TTSUBPIX_H__
+
+#include <ft2build.h>
+#include "ttobjs.h"
+#include "ttinterp.h"
+
+
+FT_BEGIN_HEADER
+
+
+#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
+
+ /*************************************************************************/
+ /* */
+ /* Tweak flags that are set for each glyph by the below rules. */
+ /* */
+ /* */
+#define SPH_TWEAK_ALLOW_X_DMOVE 0x0000001
+#define SPH_TWEAK_ALLOW_X_DMOVEX 0x0000002
+#define SPH_TWEAK_ALLOW_X_MOVE_ZP2 0x0000004
+#define SPH_TWEAK_ALWAYS_DO_DELTAP 0x0000008
+#define SPH_TWEAK_ALWAYS_SKIP_DELTAP 0x0000010
+#define SPH_TWEAK_COURIER_NEW_2_HACK 0x0000020
+#define SPH_TWEAK_DEEMBOLDEN 0x0000040
+#define SPH_TWEAK_DELTAP_SKIP_EXAGGERATED_VALUES 0x0000080
+#define SPH_TWEAK_DO_SHPIX 0x0000100
+#define SPH_TWEAK_EMBOLDEN 0x0000200
+#define SPH_TWEAK_MIAP_HACK 0x0000400
+#define SPH_TWEAK_NORMAL_ROUND 0x0000800
+#define SPH_TWEAK_NO_ALIGNRP_AFTER_IUP 0x0001000
+#define SPH_TWEAK_NO_CALL_AFTER_IUP 0x0002000
+#define SPH_TWEAK_NO_DELTAP_AFTER_IUP 0x0004000
+#define SPH_TWEAK_PIXEL_HINTING 0x0008000
+#define SPH_TWEAK_RASTERIZER_35 0x0010000
+#define SPH_TWEAK_ROUND_NONPIXEL_Y_MOVES 0x0020000
+#define SPH_TWEAK_SKIP_INLINE_DELTAS 0x0040000
+#define SPH_TWEAK_SKIP_IUP 0x0080000
+#define SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES 0x0100000
+#define SPH_TWEAK_SKIP_OFFPIXEL_Y_MOVES 0x0200000
+#define SPH_TWEAK_TIMES_NEW_ROMAN_HACK 0x0400000
+#define SPH_TWEAK_MIRP_CVT_ZERO 0x0800000
+
+
+ FT_LOCAL( FT_Bool )
+ sph_test_tweak( TT_Face face,
+ FT_String* family,
+ FT_UInt ppem,
+ FT_String* style,
+ FT_UInt glyph_index,
+ SPH_TweakRule* rule,
+ FT_UInt num_rules );
+
+ FT_LOCAL_DEF( FT_UInt )
+ scale_test_tweak( TT_Face face,
+ FT_String* family,
+ FT_UInt ppem,
+ FT_String* style,
+ FT_UInt glyph_index,
+ SPH_ScaleRule* rule,
+ FT_UInt num_rules );
+
+ FT_LOCAL( void )
+ sph_set_tweaks( TT_Loader loader,
+ FT_UInt glyph_index );
+
+
+ /*************************************************************************/
+ /* */
+ /* These rules affect how the TT Interpreter does hinting, with the */
+ /* goal of doing subpixel hinting by (in general) ignoring x moves. */
+ /* Some of these rules are fixes that go above and beyond the */
+ /* stated techniques in the MS whitepaper on Cleartype, due to */
+ /* artifacts in many glyphs. So, these rules make some glyphs render */
+ /* better than they do in the MS rasterizer. */
+ /* */
+ /* "" string or 0 int/char indicates to apply to all glyphs. */
+ /* "-" used as dummy placeholders, but any non-matching string works. */
+ /* */
+ /* Some of this could arguably be implemented in fontconfig, however: */
+ /* */
+ /* - Fontconfig can't set things on a glyph-by-glyph basis. */
+ /* - The tweaks that happen here are very low-level, from an average */
+ /* user's point of view and are best implemented in the hinter. */
+ /* */
+ /* The goal is to make the subpixel hinting techniques as generalized */
+ /* as possible across all fonts to prevent the need for extra rules such */
+ /* as these. */
+ /* */
+ /* The rule structure is designed so that entirely new rules can easily */
+ /* be added when a new compatibility feature is discovered. */
+ /* */
+ /* The rule structures could also use some enhancement to handle ranges. */
+ /* */
+ /* ****************** WORK IN PROGRESS ******************* */
+ /* */
+
+ /* These macros are defined absent a method for setting them */
+#define SPH_OPTION_BITMAP_WIDTHS FALSE
+#define SPH_OPTION_SET_SUBPIXEL TRUE
+#define SPH_OPTION_SET_GRAYSCALE FALSE
+#define SPH_OPTION_SET_COMPATIBLE_WIDTHS FALSE
+#define SPH_OPTION_SET_RASTERIZER_VERSION 38
+
+
+ /* Define this to force natural (i.e. not bitmap-compatible) widths. */
+ /* The default leans strongly towards natural widths except for a few */
+ /* legacy fonts where a selective combination produces nicer results. */
+/* #define FORCE_NATURAL_WIDTHS */
+
+
+ /* These are `classes' of fonts that can be grouped together and used in */
+ /* rules below. A blank entry "" is required at the end of these! */
+#define FAMILY_CLASS_RULES_SIZE 7
+
+ Font_Class FAMILY_CLASS_Rules
+ [FAMILY_CLASS_RULES_SIZE] =
+ {
+ { "MS Legacy Fonts",
+ { "Aharoni",
+ "Andale Mono",
+ "Andalus",
+ "Angsana New",
+ "AngsanaUPC",
+ "Arabic Transparent",
+ "Arial Black",
+ "Arial Narrow",
+ "Arial Unicode MS",
+ "Arial",
+ "Batang",
+ "Browallia New",
+ "BrowalliaUPC",
+ "Comic Sans MS",
+ "Cordia New",
+ "CordiaUPC",
+ "Courier New",
+ "DFKai-SB",
+ "David Transparent",
+ "David",
+ "DilleniaUPC",
+ "Estrangelo Edessa",
+ "EucrosiaUPC",
+ "FangSong_GB2312",
+ "Fixed Miriam Transparent",
+ "FrankRuehl",
+ "Franklin Gothic Medium",
+ "FreesiaUPC",
+ "Garamond",
+ "Gautami",
+ "Georgia",
+ "Gulim",
+ "Impact",
+ "IrisUPC",
+ "JasmineUPC",
+ "KaiTi_GB2312",
+ "KodchiangUPC",
+ "Latha",
+ "Levenim MT",
+ "LilyUPC",
+ "Lucida Console",
+ "Lucida Sans Unicode",
+ "MS Gothic",
+ "MS Mincho",
+ "MV Boli",
+ "Mangal",
+ "Marlett",
+ "Microsoft Sans Serif",
+ "Mingliu",
+ "Miriam Fixed",
+ "Miriam Transparent",
+ "Miriam",
+ "Narkisim",
+ "Palatino Linotype",
+ "Raavi",
+ "Rod Transparent",
+ "Rod",
+ "Shruti",
+ "SimHei",
+ "Simplified Arabic Fixed",
+ "Simplified Arabic",
+ "Simsun",
+ "Sylfaen",
+ "Symbol",
+ "Tahoma",
+ "Times New Roman",
+ "Traditional Arabic",
+ "Trebuchet MS",
+ "Tunga",
+ "Verdana",
+ "Webdings",
+ "Wingdings",
+ "",
+ },
+ },
+ { "Core MS Legacy Fonts",
+ { "Arial Black",
+ "Arial Narrow",
+ "Arial Unicode MS",
+ "Arial",
+ "Comic Sans MS",
+ "Courier New",
+ "Garamond",
+ "Georgia",
+ "Impact",
+ "Lucida Console",
+ "Lucida Sans Unicode",
+ "Microsoft Sans Serif",
+ "Palatino Linotype",
+ "Tahoma",
+ "Times New Roman",
+ "Trebuchet MS",
+ "Verdana",
+ "",
+ },
+ },
+ { "Apple Legacy Fonts",
+ { "Geneva",
+ "Times",
+ "Monaco",
+ "Century",
+ "Chalkboard",
+ "Lobster",
+ "Century Gothic",
+ "Optima",
+ "Lucida Grande",
+ "Gill Sans",
+ "Baskerville",
+ "Helvetica",
+ "Helvetica Neue",
+ "",
+ },
+ },
+ { "Legacy Sans Fonts",
+ { "Andale Mono",
+ "Arial Unicode MS",
+ "Arial",
+ "Century Gothic",
+ "Comic Sans MS",
+ "Franklin Gothic Medium",
+ "Geneva",
+ "Lucida Console",
+ "Lucida Grande",
+ "Lucida Sans Unicode",
+ "Lucida Sans Typewriter",
+ "Microsoft Sans Serif",
+ "Monaco",
+ "Tahoma",
+ "Trebuchet MS",
+ "Verdana",
+ "",
+ },
+ },
+
+ { "Misc Legacy Fonts",
+ { "Dark Courier", "", }, },
+ { "Verdana Clones",
+ { "DejaVu Sans",
+ "Bitstream Vera Sans", "", }, },
+ { "Verdana and Clones",
+ { "DejaVu Sans",
+ "Bitstream Vera Sans",
+ "Verdana", "", }, },
+ };
+
+
+ /* Define `classes' of styles that can be grouped together and used in */
+ /* rules below. A blank entry "" is required at the end of these! */
+#define STYLE_CLASS_RULES_SIZE 5
+
+ Font_Class STYLE_CLASS_Rules
+ [STYLE_CLASS_RULES_SIZE] =
+ {
+ { "Regular Class",
+ { "Regular",
+ "Book",
+ "Medium",
+ "Roman",
+ "Normal",
+ "",
+ },
+ },
+ { "Regular/Italic Class",
+ { "Regular",
+ "Book",
+ "Medium",
+ "Italic",
+ "Oblique",
+ "Roman",
+ "Normal",
+ "",
+ },
+ },
+ { "Bold/BoldItalic Class",
+ { "Bold",
+ "Bold Italic",
+ "Black",
+ "",
+ },
+ },
+ { "Bold/Italic/BoldItalic Class",
+ { "Bold",
+ "Bold Italic",
+ "Black",
+ "Italic",
+ "Oblique",
+ "",
+ },
+ },
+ { "Regular/Bold Class",
+ { "Regular",
+ "Book",
+ "Medium",
+ "Normal",
+ "Roman",
+ "Bold",
+ "Black",
+ "",
+ },
+ },
+ };
+
+
+ /* Special fixes for known legacy fonts; */
+ /* this is the primary workhorse rule for legacy fonts */
+#define COMPATIBILITY_MODE_RULES_SIZE 4
+
+ SPH_TweakRule COMPATIBILITY_MODE_Rules
+ [COMPATIBILITY_MODE_RULES_SIZE] =
+ {
+ { "MS Legacy Fonts", 0, "", 0 },
+ { "Apple Legacy Fonts", 0, "", 0 },
+ { "Misc Legacy Fonts", 0, "", 0 },
+ { "Verdana Clones", 0, "", 0 },
+ };
+
+
+ /* Don't do subpixel (ignore_x_mode) hinting; do normal hinting. */
+#define PIXEL_HINTING_RULES_SIZE 4
+
+ SPH_TweakRule PIXEL_HINTING_Rules
+ [PIXEL_HINTING_RULES_SIZE] =
+ {
+ /* these characters are almost always safe */
+ { "", 0, "", '<' },
+ { "", 0, "", '>' },
+ /* fixes the vanishing stem */
+ { "Times New Roman", 0, "Bold", 'A' },
+ { "Times New Roman", 0, "Bold", 'V' },
+ };
+
+
+ /* According to Greg Hitchcock and the MS whitepaper, this should work */
+ /* on all legacy MS fonts, but creates artifacts with some. Only using */
+ /* where absolutely necessary. */
+#define SKIP_INLINE_DELTAS_RULES_SIZE 1
+
+ SPH_TweakRule SKIP_INLINE_DELTAS_Rules
+ [SKIP_INLINE_DELTAS_RULES_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+ /* Subpixel hinting ignores SHPIX rules on X. Force SHPIX for these. */
+#define DO_SHPIX_RULES_SIZE 1
+
+ SPH_TweakRule DO_SHPIX_Rules
+ [DO_SHPIX_RULES_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+ /* Skip Y moves that start with a point that is not on a Y pixel */
+ /* boundary and don't move that point to a Y pixel boundary. */
+#define SKIP_NONPIXEL_Y_MOVES_RULES_SIZE 10
+
+ SPH_TweakRule SKIP_NONPIXEL_Y_MOVES_Rules
+ [SKIP_NONPIXEL_Y_MOVES_RULES_SIZE] =
+ {
+ /* fix vwxyz thinness*/
+ { "Consolas", 0, "Regular", 0 },
+ /* fix tiny gap at top of m */
+ { "Arial", 0, "Regular", 'm' },
+ /* Fix thin middle stems */
+ { "Core MS Legacy Fonts", 0, "Regular/Bold Class", 'N' },
+ { "Lucida Grande", 0, "", 'N' },
+ { "Lucida Grande", 0, "Bold", 'y' },
+ /* Cyrillic small letter I */
+ { "Legacy Sans Fonts", 0, "", 0x438 },
+ { "Verdana Clones", 0, "",'N' },
+ { "Ubuntu", 0, "Regular Class", 'N' },
+ /* Fix misshapen x */
+ { "Verdana", 0, "Bold", 'x' },
+ /* Fix misshapen s */
+ { "Tahoma", 0, "", 's' },
+ };
+
+
+#define SKIP_NONPIXEL_Y_MOVES_RULES_EXCEPTIONS_SIZE 6
+
+ SPH_TweakRule SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions
+ [SKIP_NONPIXEL_Y_MOVES_RULES_EXCEPTIONS_SIZE] =
+ {
+ { "Tahoma", 0, "", 'N' },
+ { "Comic Sans MS", 0, "", 'N' },
+ { "Verdana", 0, "Regular/Bold Class", 'N' },
+ { "Verdana", 11, "Bold", 'x' },
+ /* Cyrillic small letter I */
+ { "Arial", 0, "", 0x438 },
+ { "Trebuchet MS", 0, "Bold", 0 },
+ };
+
+
+ /* Skip Y moves that move a point off a Y pixel boundary. */
+ /* This fixes Tahoma, Trebuchet oddities and some issues with `$'. */
+#define SKIP_OFFPIXEL_Y_MOVES_RULES_SIZE 5
+
+ SPH_TweakRule SKIP_OFFPIXEL_Y_MOVES_Rules
+ [SKIP_OFFPIXEL_Y_MOVES_RULES_SIZE] =
+ {
+ { "MS Legacy Fonts", 0, "", 0 },
+ { "Apple Legacy Fonts", 0, "", 0 },
+ { "Misc Legacy Fonts", 0, "", 0 },
+ { "Ubuntu", 0, "Regular Class", 0 },
+ { "Verdana Clones", 0, "", 0 },
+ };
+
+
+#define SKIP_OFFPIXEL_Y_MOVES_RULES_EXCEPTIONS_SIZE 1
+
+ SPH_TweakRule SKIP_OFFPIXEL_Y_MOVES_Rules_Exceptions
+ [SKIP_OFFPIXEL_Y_MOVES_RULES_EXCEPTIONS_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+ /* Round moves that don't move a point to a Y pixel boundary. */
+#define ROUND_NONPIXEL_Y_MOVES_RULES_SIZE 3
+
+ SPH_TweakRule ROUND_NONPIXEL_Y_MOVES_Rules
+ [ROUND_NONPIXEL_Y_MOVES_RULES_SIZE] =
+ {
+ /* Droid font instructions don't snap Y to pixels */
+ { "Droid Sans", 0, "Regular/Italic Class", 0 },
+ { "Droid Sans Mono", 0, "", 0 },
+ { "Ubuntu", 0, "", 0 },
+ };
+
+
+#define ROUND_NONPIXEL_Y_MOVES_RULES_EXCEPTIONS_SIZE 3
+
+ SPH_TweakRule ROUND_NONPIXEL_Y_MOVES_Rules_Exceptions
+ [ROUND_NONPIXEL_Y_MOVES_RULES_EXCEPTIONS_SIZE] =
+ {
+ { "Droid Sans", 12, "Bold", 0 },
+ { "Droid Sans", 13, "Bold", 0 },
+ { "Droid Sans", 16, "Bold", 0 },
+ };
+
+
+ /* Allow a Direct_Move_X along X freedom vector if matched. */
+#define ALLOW_X_DMOVEX_RULES_SIZE 1
+
+ SPH_TweakRule ALLOW_X_DMOVEX_Rules
+ [ALLOW_X_DMOVEX_RULES_SIZE] =
+ {
+ { "-", 0, "Regular", 0 },
+ };
+
+
+ /* Allow a Direct_Move along X freedom vector if matched. */
+#define ALLOW_X_DMOVE_RULES_SIZE 1
+
+ SPH_TweakRule ALLOW_X_DMOVE_Rules
+ [ALLOW_X_DMOVE_RULES_SIZE] =
+ {
+ /* Fixes vanishing diagonal in 4 */
+ { "Verdana", 0, "Regular", '4' },
+ };
+
+
+ /* Allow a ZP2 move along freedom vector if matched; */
+ /* This is called from SHP, SHPIX, SHC, SHZ. */
+#define ALLOW_X_MOVE_ZP2_RULES_SIZE 1
+
+ SPH_TweakRule ALLOW_X_MOVE_ZP2_Rules
+ [ALLOW_X_MOVE_ZP2_RULES_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+ /* Return MS rasterizer version 35 if matched. */
+#define RASTERIZER_35_RULES_SIZE 8
+
+ SPH_TweakRule RASTERIZER_35_Rules
+ [RASTERIZER_35_RULES_SIZE] =
+ {
+ /* This seems to be the only way to make these look good */
+ { "Times New Roman", 0, "Regular", 'i' },
+ { "Times New Roman", 0, "Regular", 'j' },
+ { "Times New Roman", 0, "Regular", 'm' },
+ { "Times New Roman", 0, "Regular", 'r' },
+ { "Times New Roman", 0, "Regular", 'a' },
+ { "Times New Roman", 0, "Regular", 'n' },
+ { "Times New Roman", 0, "Regular", 'p' },
+ { "Times", 0, "", 0 },
+ };
+
+
+ /* Don't round to the subpixel grid. Round to pixel grid. */
+#define NORMAL_ROUND_RULES_SIZE 2
+
+ SPH_TweakRule NORMAL_ROUND_Rules
+ [NORMAL_ROUND_RULES_SIZE] =
+ {
+ /* Fix point "explosions" */
+ { "Courier New", 0, "", 0 },
+ { "Verdana", 10, "Regular", '4' },
+ };
+
+
+ /* Skip IUP instructions if matched. */
+#define SKIP_IUP_RULES_SIZE 1
+
+ SPH_TweakRule SKIP_IUP_Rules
+ [SKIP_IUP_RULES_SIZE] =
+ {
+ { "Arial", 13, "Regular", 'a' },
+ };
+
+
+ /* Skip MIAP Twilight hack if matched. */
+#define MIAP_HACK_RULES_SIZE 1
+
+ SPH_TweakRule MIAP_HACK_Rules
+ [MIAP_HACK_RULES_SIZE] =
+ {
+ { "Geneva", 12, "", 0 },
+ };
+
+
+ /* Skip DELTAP instructions if matched. */
+#define ALWAYS_SKIP_DELTAP_RULES_SIZE 16
+
+ SPH_TweakRule ALWAYS_SKIP_DELTAP_Rules
+ [ALWAYS_SKIP_DELTAP_RULES_SIZE] =
+ {
+ { "Georgia", 0, "Regular", 'k' },
+ /* fixes problems with W M w */
+ { "Trebuchet MS", 0, "Italic", 0 },
+ /* fix various problems with e in different versions */
+ { "Trebuchet MS", 14, "Regular", 'e' },
+ { "Trebuchet MS", 13, "Regular", 'e' },
+ { "Trebuchet MS", 15, "Regular", 'e' },
+ { "Arial", 11, "Regular", 's' },
+ { "Verdana", 10, "Regular", 0 },
+ { "Verdana", 9, "Regular", 0 },
+ /* Cyrillic small letter short I */
+ { "Legacy Sans Fonts", 0, "", 0x438 },
+ { "Legacy Sans Fonts", 0, "", 0x439 },
+ { "Arial", 10, "Regular", '6' },
+ { "Arial", 0, "Bold/BoldItalic Class", 'a' },
+ /* Make horizontal stems consistent with the rest */
+ { "Arial", 24, "Bold", 's' },
+ { "Arial", 25, "Bold", 's' },
+ { "Arial", 24, "Bold", 'a' },
+ { "Arial", 25, "Bold", 'a' },
+ };
+
+
+ /* Always do DELTAP instructions if matched. */
+#define ALWAYS_DO_DELTAP_RULES_SIZE 2
+
+ SPH_TweakRule ALWAYS_DO_DELTAP_Rules
+ [ALWAYS_DO_DELTAP_RULES_SIZE] =
+ {
+ { "Verdana Clones", 17, "Regular Class", 'K' },
+ { "Verdana Clones", 17, "Regular Class", 'k' },
+ };
+
+
+ /* Do an extra RTG instruction in DELTAP if matched. */
+#define DELTAP_RTG_RULES_SIZE 1
+
+ SPH_TweakRule DELTAP_RTG_Rules
+ [DELTAP_RTG_RULES_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+ /* Force CVT distance to zero in MIRP. */
+#define MIRP_CVT_ZERO_RULES_SIZE 1
+
+ SPH_TweakRule MIRP_CVT_ZERO_Rules
+ [MIRP_CVT_ZERO_RULES_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+ /* Skip moves that meet or exceed 1 pixel. */
+#define DELTAP_SKIP_EXAGGERATED_VALUES_RULES_SIZE 1
+
+ SPH_TweakRule DELTAP_SKIP_EXAGGERATED_VALUES_Rules
+ [DELTAP_SKIP_EXAGGERATED_VALUES_RULES_SIZE] =
+ {
+ /* Fix vanishing stems */
+ { "Ubuntu", 0, "Regular", 'M' },
+ };
+
+
+ /* Don't allow ALIGNRP after IUP. */
+#define NO_ALIGNRP_AFTER_IUP_RULES_SIZE 4
+
+ SPH_TweakRule NO_ALIGNRP_AFTER_IUP_Rules
+ [NO_ALIGNRP_AFTER_IUP_RULES_SIZE] =
+ {
+ /* Prevent creation of dents in outline */
+ { "Courier New", 0, "Bold", 'C' },
+ { "Courier New", 0, "Bold", 'D' },
+ { "Courier New", 0, "Bold", 'Q' },
+ { "Courier New", 0, "Bold", '0' },
+ };
+
+
+ /* Don't allow DELTAP after IUP. */
+#define NO_DELTAP_AFTER_IUP_RULES_SIZE 2
+
+ SPH_TweakRule NO_DELTAP_AFTER_IUP_Rules
+ [NO_DELTAP_AFTER_IUP_RULES_SIZE] =
+ {
+ { "Arial", 0, "Bold", 'N' },
+ { "Verdana", 0, "Regular", '4' },
+ };
+
+
+ /* Don't allow CALL after IUP. */
+#define NO_CALL_AFTER_IUP_RULES_SIZE 4
+
+ SPH_TweakRule NO_CALL_AFTER_IUP_Rules
+ [NO_CALL_AFTER_IUP_RULES_SIZE] =
+ {
+ /* Prevent creation of dents in outline */
+ { "Courier New", 0, "Bold", 'O' },
+ { "Courier New", 0, "Bold", 'Q' },
+ { "Courier New", 0, "Bold", 'k' },
+ { "Courier New", 0, "Bold Italic", 'M' },
+ };
+
+
+ /* De-embolden these glyphs slightly. */
+#define DEEMBOLDEN_RULES_SIZE 9
+
+ SPH_TweakRule DEEMBOLDEN_Rules
+ [DEEMBOLDEN_RULES_SIZE] =
+ {
+ { "Courier New", 0, "Bold", 'A' },
+ { "Courier New", 0, "Bold", 'W' },
+ { "Courier New", 0, "Bold", 'w' },
+ { "Courier New", 0, "Bold", 'M' },
+ { "Courier New", 0, "Bold", 'X' },
+ { "Courier New", 0, "Bold", 'K' },
+ { "Courier New", 0, "Bold", 'x' },
+ { "Courier New", 0, "Bold", 'z' },
+ { "Courier New", 0, "Bold", 'v' },
+ };
+
+
+ /* Embolden these glyphs slightly. */
+#define EMBOLDEN_RULES_SIZE 5
+
+ SPH_TweakRule EMBOLDEN_Rules
+ [EMBOLDEN_RULES_SIZE] =
+ {
+ { "Courier New", 12, "Italic", 'z' },
+ { "Courier New", 11, "Italic", 'z' },
+ { "Courier New", 10, "Italic", 'z' },
+ { "Courier New", 0, "Regular", 0 },
+ { "Courier New", 0, "Italic", 0 },
+ };
+
+
+ /* Do an extra RDTG instruction in DELTAP if matched. */
+#define DELTAP_RDTG_RULES_SIZE 1
+
+ SPH_TweakRule DELTAP_RDTG_Rules
+ [DELTAP_RDTG_RULES_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+ /* This is a CVT hack that makes thick horizontal stems on 2, 5, 7 */
+ /* similar to Windows XP. */
+#define TIMES_NEW_ROMAN_HACK_RULES_SIZE 12
+
+ SPH_TweakRule TIMES_NEW_ROMAN_HACK_Rules
+ [TIMES_NEW_ROMAN_HACK_RULES_SIZE] =
+ {
+ { "Times New Roman", 16, "Italic", '2' },
+ { "Times New Roman", 16, "Italic", '5' },
+ { "Times New Roman", 16, "Italic", '7' },
+ { "Times New Roman", 16, "Regular", '2' },
+ { "Times New Roman", 16, "Regular", '5' },
+ { "Times New Roman", 16, "Regular", '7' },
+ { "Times New Roman", 17, "Italic", '2' },
+ { "Times New Roman", 17, "Italic", '5' },
+ { "Times New Roman", 17, "Italic", '7' },
+ { "Times New Roman", 17, "Regular", '2' },
+ { "Times New Roman", 17, "Regular", '5' },
+ { "Times New Roman", 17, "Regular", '7' },
+ };
+
+
+ /* This fudges distance on 2 to get rid of the vanishing stem issue. */
+ /* A real solution to this is certainly welcome. */
+#define COURIER_NEW_2_HACK_RULES_SIZE 15
+
+ SPH_TweakRule COURIER_NEW_2_HACK_Rules
+ [COURIER_NEW_2_HACK_RULES_SIZE] =
+ {
+ { "Courier New", 10, "Regular", '2' },
+ { "Courier New", 11, "Regular", '2' },
+ { "Courier New", 12, "Regular", '2' },
+ { "Courier New", 13, "Regular", '2' },
+ { "Courier New", 14, "Regular", '2' },
+ { "Courier New", 15, "Regular", '2' },
+ { "Courier New", 16, "Regular", '2' },
+ { "Courier New", 17, "Regular", '2' },
+ { "Courier New", 18, "Regular", '2' },
+ { "Courier New", 19, "Regular", '2' },
+ { "Courier New", 20, "Regular", '2' },
+ { "Courier New", 21, "Regular", '2' },
+ { "Courier New", 22, "Regular", '2' },
+ { "Courier New", 23, "Regular", '2' },
+ { "Courier New", 24, "Regular", '2' },
+ };
+
+
+#ifndef FORCE_NATURAL_WIDTHS
+
+ /* Use compatible widths with these glyphs. Compatible widths is always */
+ /* on when doing B/W TrueType instructing, but is used selectively here, */
+ /* typically on glyphs with 3 or more vertical stems. */
+#define COMPATIBLE_WIDTHS_RULES_SIZE 38
+
+ SPH_TweakRule COMPATIBLE_WIDTHS_Rules
+ [COMPATIBLE_WIDTHS_RULES_SIZE] =
+ {
+ { "Arial Unicode MS", 12, "Regular Class", 'm' },
+ { "Arial Unicode MS", 14, "Regular Class", 'm' },
+ /* Cyrillic small letter sha */
+ { "Arial", 10, "Regular Class", 0x448 },
+ { "Arial", 11, "Regular Class", 'm' },
+ { "Arial", 12, "Regular Class", 'm' },
+ /* Cyrillic small letter sha */
+ { "Arial", 12, "Regular Class", 0x448 },
+ { "Arial", 13, "Regular Class", 0x448 },
+ { "Arial", 14, "Regular Class", 'm' },
+ /* Cyrillic small letter sha */
+ { "Arial", 14, "Regular Class", 0x448 },
+ { "Arial", 15, "Regular Class", 0x448 },
+ { "Arial", 17, "Regular Class", 'm' },
+ { "DejaVu Sans", 15, "Regular Class", 0 },
+ { "Microsoft Sans Serif", 11, "Regular Class", 0 },
+ { "Microsoft Sans Serif", 12, "Regular Class", 0 },
+ { "Segoe UI", 11, "Regular Class", 0 },
+ { "Monaco", 0, "Regular Class", 0 },
+ { "Segoe UI", 12, "Regular Class", 'm' },
+ { "Segoe UI", 14, "Regular Class", 'm' },
+ { "Tahoma", 11, "Regular Class", 0 },
+ { "Times New Roman", 16, "Regular Class", 'c' },
+ { "Times New Roman", 16, "Regular Class", 'm' },
+ { "Times New Roman", 16, "Regular Class", 'o' },
+ { "Times New Roman", 16, "Regular Class", 'w' },
+ { "Trebuchet MS", 11, "Regular Class", 0 },
+ { "Trebuchet MS", 12, "Regular Class", 0 },
+ { "Trebuchet MS", 14, "Regular Class", 0 },
+ { "Trebuchet MS", 15, "Regular Class", 0 },
+ { "Ubuntu", 12, "Regular Class", 'm' },
+ /* Cyrillic small letter sha */
+ { "Verdana", 10, "Regular Class", 0x448 },
+ { "Verdana", 11, "Regular Class", 0x448 },
+ { "Verdana and Clones", 12, "Regular Class", 'i' },
+ { "Verdana and Clones", 12, "Regular Class", 'j' },
+ { "Verdana and Clones", 12, "Regular Class", 'l' },
+ { "Verdana and Clones", 12, "Regular Class", 'm' },
+ { "Verdana and Clones", 13, "Regular Class", 'i' },
+ { "Verdana and Clones", 13, "Regular Class", 'j' },
+ { "Verdana and Clones", 13, "Regular Class", 'l' },
+ { "Verdana and Clones", 14, "Regular Class", 'm' },
+ };
+
+
+ /* Scaling slightly in the x-direction prior to hinting results in */
+ /* more visually pleasing glyphs in certain cases. */
+ /* This sometimes needs to be coordinated with compatible width rules. */
+ /* A value of 1000 corresponds to a scaled value of 1.0. */
+#define X_SCALING_RULES_SIZE 50
+
+ SPH_ScaleRule X_SCALING_Rules
+ [X_SCALING_RULES_SIZE] =
+ {
+ { "DejaVu Sans", 12, "Regular Class", 'm', 950 },
+ { "Verdana and Clones", 12, "Regular Class", 'a', 1100 },
+ { "Verdana and Clones", 13, "Regular Class", 'a', 1050 },
+ { "Arial", 11, "Regular Class", 'm', 975 },
+ { "Arial", 12, "Regular Class", 'm', 1050 },
+ /* Cyrillic small letter el */
+ { "Arial", 13, "Regular Class", 0x43B, 950 },
+ { "Arial", 13, "Regular Class", 'o', 950 },
+ { "Arial", 13, "Regular Class", 'e', 950 },
+ { "Arial", 14, "Regular Class", 'm', 950 },
+ /* Cyrillic small letter el */
+ { "Arial", 15, "Regular Class", 0x43B, 925 },
+ { "Bitstream Vera Sans", 10, "Regular/Italic Class", 0, 1100 },
+ { "Bitstream Vera Sans", 12, "Regular/Italic Class", 0, 1050 },
+ { "Bitstream Vera Sans", 16, "Regular Class", 0, 1050 },
+ { "Bitstream Vera Sans", 9, "Regular/Italic Class", 0, 1050 },
+ { "DejaVu Sans", 12, "Regular Class", 'l', 975 },
+ { "DejaVu Sans", 12, "Regular Class", 'i', 975 },
+ { "DejaVu Sans", 12, "Regular Class", 'j', 975 },
+ { "DejaVu Sans", 13, "Regular Class", 'l', 950 },
+ { "DejaVu Sans", 13, "Regular Class", 'i', 950 },
+ { "DejaVu Sans", 13, "Regular Class", 'j', 950 },
+ { "DejaVu Sans", 10, "Regular/Italic Class", 0, 1100 },
+ { "DejaVu Sans", 12, "Regular/Italic Class", 0, 1050 },
+ { "Georgia", 10, "", 0, 1050 },
+ { "Georgia", 11, "", 0, 1100 },
+ { "Georgia", 12, "", 0, 1025 },
+ { "Georgia", 13, "", 0, 1050 },
+ { "Georgia", 16, "", 0, 1050 },
+ { "Georgia", 17, "", 0, 1030 },
+ { "Liberation Sans", 12, "Regular Class", 'm', 1100 },
+ { "Lucida Grande", 11, "Regular Class", 'm', 1100 },
+ { "Microsoft Sans Serif", 11, "Regular Class", 'm', 950 },
+ { "Microsoft Sans Serif", 12, "Regular Class", 'm', 1050 },
+ { "Segoe UI", 12, "Regular Class", 'H', 1050 },
+ { "Segoe UI", 12, "Regular Class", 'm', 1050 },
+ { "Segoe UI", 14, "Regular Class", 'm', 1050 },
+ { "Tahoma", 11, "Regular Class", 'i', 975 },
+ { "Tahoma", 11, "Regular Class", 'l', 975 },
+ { "Tahoma", 11, "Regular Class", 'j', 900 },
+ { "Tahoma", 11, "Regular Class", 'm', 918 },
+ { "Verdana", 10, "Regular/Italic Class", 0, 1100 },
+ { "Verdana", 12, "Regular Class", 'm', 975 },
+ { "Verdana", 12, "Regular/Italic Class", 0, 1050 },
+ { "Verdana", 13, "Regular/Italic Class", 'i', 950 },
+ { "Verdana", 13, "Regular/Italic Class", 'j', 950 },
+ { "Verdana", 13, "Regular/Italic Class", 'l', 950 },
+ { "Verdana", 16, "Regular Class", 0, 1050 },
+ { "Verdana", 9, "Regular/Italic Class", 0, 1050 },
+ { "Times New Roman", 16, "Regular Class", 'm', 918 },
+ { "Trebuchet MS", 11, "Regular Class", 'm', 800 },
+ { "Trebuchet MS", 12, "Regular Class", 'm', 800 },
+ };
+
+#else
+
+#define COMPATIBLE_WIDTHS_RULES_SIZE 1
+
+ SPH_TweakRule COMPATIBLE_WIDTHS_Rules
+ [COMPATIBLE_WIDTHS_RULES_SIZE] =
+ {
+ { "-", 0, "", 0 },
+ };
+
+
+#define X_SCALING_RULES_SIZE 1
+
+ SPH_ScaleRule X_SCALING_Rules
+ [X_SCALING_RULES_SIZE] =
+ {
+ { "-", 0, "", 0, 1000 },
+ };
+
+#endif /* FORCE_NATURAL_WIDTHS */
+
+#endif /* TT_CONFIG_OPTION_SUBPIXEL_HINTING */
+
+
+FT_END_HEADER
+
+#endif /* __TTSUBPIX_H__ */
+
+/* END */
diff --git a/3party/freetype/src/type1/t1afm.c b/3party/freetype/src/type1/t1afm.c
index 780ab33bf7..1fff15d73e 100644
--- a/3party/freetype/src/type1/t1afm.c
+++ b/3party/freetype/src/type1/t1afm.c
@@ -4,8 +4,7 @@
/* */
/* AFM support for Type 1 fonts (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
-/* 2010 by */
+/* Copyright 1996-2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -252,7 +251,7 @@
fi->Descender = t1_font->font_bbox.yMin;
psaux = (PSAux_Service)( (T1_Face)t1_face )->psaux;
- if ( psaux && psaux->afm_parser_funcs )
+ if ( psaux->afm_parser_funcs )
{
error = psaux->afm_parser_funcs->init( &parser,
stream->memory,
diff --git a/3party/freetype/src/type1/t1driver.c b/3party/freetype/src/type1/t1driver.c
index 79516aa3e8..e35d7b11d0 100644
--- a/3party/freetype/src/type1/t1driver.c
+++ b/3party/freetype/src/type1/t1driver.c
@@ -195,7 +195,7 @@
if ( idx < sizeof ( type1->font_matrix ) /
sizeof ( type1->font_matrix.xx ) )
{
- FT_Fixed val;
+ FT_Fixed val = 0;
retval = sizeof ( val );
@@ -225,7 +225,7 @@
if ( idx < sizeof ( type1->font_bbox ) /
sizeof ( type1->font_bbox.xMin ) )
{
- FT_Fixed val;
+ FT_Fixed val = 0;
retval = sizeof ( val );
@@ -607,11 +607,11 @@
};
- static FT_Module_Interface
- Get_Interface( FT_Driver driver,
+ FT_CALLBACK_DEF( FT_Module_Interface )
+ Get_Interface( FT_Module module,
const FT_String* t1_interface )
{
- FT_UNUSED( driver );
+ FT_UNUSED( module );
return ft_service_list_lookup( t1_services, t1_interface );
}
@@ -652,11 +652,14 @@
/* They can be implemented by format-specific interfaces. */
/* */
static FT_Error
- Get_Kerning( T1_Face face,
+ Get_Kerning( FT_Face t1face, /* T1_Face */
FT_UInt left_glyph,
FT_UInt right_glyph,
FT_Vector* kerning )
{
+ T1_Face face = (T1_Face)t1face;
+
+
kerning->x = 0;
kerning->y = 0;
@@ -681,7 +684,7 @@
FT_MODULE_DRIVER_SCALABLE |
FT_MODULE_DRIVER_HAS_HINTER,
- sizeof( FT_DriverRec ),
+ sizeof ( FT_DriverRec ),
"type1",
0x10000L,
@@ -689,38 +692,38 @@
0, /* format interface */
- (FT_Module_Constructor)T1_Driver_Init,
- (FT_Module_Destructor) T1_Driver_Done,
- (FT_Module_Requester) Get_Interface,
+ T1_Driver_Init,
+ T1_Driver_Done,
+ Get_Interface,
},
- sizeof( T1_FaceRec ),
- sizeof( T1_SizeRec ),
- sizeof( T1_GlyphSlotRec ),
+ sizeof ( T1_FaceRec ),
+ sizeof ( T1_SizeRec ),
+ sizeof ( T1_GlyphSlotRec ),
- (FT_Face_InitFunc) T1_Face_Init,
- (FT_Face_DoneFunc) T1_Face_Done,
- (FT_Size_InitFunc) T1_Size_Init,
- (FT_Size_DoneFunc) T1_Size_Done,
- (FT_Slot_InitFunc) T1_GlyphSlot_Init,
- (FT_Slot_DoneFunc) T1_GlyphSlot_Done,
+ T1_Face_Init,
+ T1_Face_Done,
+ T1_Size_Init,
+ T1_Size_Done,
+ T1_GlyphSlot_Init,
+ T1_GlyphSlot_Done,
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
ft_stub_set_char_sizes,
ft_stub_set_pixel_sizes,
#endif
- (FT_Slot_LoadFunc) T1_Load_Glyph,
+ T1_Load_Glyph,
#ifdef T1_CONFIG_OPTION_NO_AFM
- (FT_Face_GetKerningFunc) 0,
- (FT_Face_AttachFunc) 0,
+ 0, /* FT_Face_GetKerningFunc */
+ 0, /* FT_Face_AttachFunc */
#else
- (FT_Face_GetKerningFunc) Get_Kerning,
- (FT_Face_AttachFunc) T1_Read_Metrics,
+ Get_Kerning,
+ T1_Read_Metrics,
#endif
- (FT_Face_GetAdvancesFunc) T1_Get_Advances,
- (FT_Size_RequestFunc) T1_Size_Request,
- (FT_Size_SelectFunc) 0
+ T1_Get_Advances,
+ T1_Size_Request,
+ 0 /* FT_Size_SelectFunc */
};
diff --git a/3party/freetype/src/type1/t1driver.h b/3party/freetype/src/type1/t1driver.h
index 9fecbeb0f8..639cd4a7ad 100644
--- a/3party/freetype/src/type1/t1driver.h
+++ b/3party/freetype/src/type1/t1driver.h
@@ -28,7 +28,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_EXPORT_VAR( const FT_Driver_ClassRec ) t1_driver_class;
diff --git a/3party/freetype/src/type1/t1errors.h b/3party/freetype/src/type1/t1errors.h
index 81221c343d..8740530eef 100644
--- a/3party/freetype/src/type1/t1errors.h
+++ b/3party/freetype/src/type1/t1errors.h
@@ -4,7 +4,7 @@
/* */
/* Type 1 error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX T1_Err_
#define FT_ERR_BASE FT_Mod_Err_Type1
diff --git a/3party/freetype/src/type1/t1gload.c b/3party/freetype/src/type1/t1gload.c
index f3fad4f5df..80e5453310 100644
--- a/3party/freetype/src/type1/t1gload.c
+++ b/3party/freetype/src/type1/t1gload.c
@@ -208,12 +208,13 @@
FT_LOCAL_DEF( FT_Error )
- T1_Get_Advances( T1_Face face,
+ T1_Get_Advances( FT_Face t1face, /* T1_Face */
FT_UInt first,
FT_UInt count,
- FT_ULong load_flags,
+ FT_Int32 load_flags,
FT_Fixed* advances )
{
+ T1_Face face = (T1_Face)t1face;
T1_DecoderRec decoder;
T1_Font type1 = &face->type1;
PSAux_Service psaux = (PSAux_Service)face->psaux;
@@ -265,14 +266,15 @@
FT_LOCAL_DEF( FT_Error )
- T1_Load_Glyph( T1_GlyphSlot glyph,
- T1_Size size,
+ T1_Load_Glyph( FT_GlyphSlot t1glyph, /* T1_GlyphSlot */
+ FT_Size t1size, /* T1_Size */
FT_UInt glyph_index,
FT_Int32 load_flags )
{
+ T1_GlyphSlot glyph = (T1_GlyphSlot)t1glyph;
FT_Error error;
T1_DecoderRec decoder;
- T1_Face face = (T1_Face)glyph->root.face;
+ T1_Face face = (T1_Face)t1glyph->face;
FT_Bool hinting;
T1_Font type1 = &face->type1;
PSAux_Service psaux = (PSAux_Service)face->psaux;
@@ -303,10 +305,10 @@
if ( load_flags & FT_LOAD_NO_RECURSE )
load_flags |= FT_LOAD_NO_SCALE | FT_LOAD_NO_HINTING;
- if ( size )
+ if ( t1size )
{
- glyph->x_scale = size->root.metrics.x_scale;
- glyph->y_scale = size->root.metrics.y_scale;
+ glyph->x_scale = t1size->metrics.x_scale;
+ glyph->y_scale = t1size->metrics.y_scale;
}
else
{
@@ -314,18 +316,18 @@
glyph->y_scale = 0x10000L;
}
- glyph->root.outline.n_points = 0;
- glyph->root.outline.n_contours = 0;
+ t1glyph->outline.n_points = 0;
+ t1glyph->outline.n_contours = 0;
hinting = FT_BOOL( ( load_flags & FT_LOAD_NO_SCALE ) == 0 &&
( load_flags & FT_LOAD_NO_HINTING ) == 0 );
- glyph->root.format = FT_GLYPH_FORMAT_OUTLINE;
+ t1glyph->format = FT_GLYPH_FORMAT_OUTLINE;
error = decoder_funcs->init( &decoder,
- (FT_Face)face,
- (FT_Size)size,
- (FT_GlyphSlot)glyph,
+ t1glyph->face,
+ t1size,
+ t1glyph,
(FT_Byte**)type1->glyph_names,
face->blend,
FT_BOOL( hinting ),
@@ -368,19 +370,19 @@
/* bearing the yMax */
if ( !error )
{
- glyph->root.outline.flags &= FT_OUTLINE_OWNER;
- glyph->root.outline.flags |= FT_OUTLINE_REVERSE_FILL;
+ t1glyph->outline.flags &= FT_OUTLINE_OWNER;
+ t1glyph->outline.flags |= FT_OUTLINE_REVERSE_FILL;
/* for composite glyphs, return only left side bearing and */
/* advance width */
if ( load_flags & FT_LOAD_NO_RECURSE )
{
- FT_Slot_Internal internal = glyph->root.internal;
+ FT_Slot_Internal internal = t1glyph->internal;
- glyph->root.metrics.horiBearingX =
+ t1glyph->metrics.horiBearingX =
FIXED_TO_INT( decoder.builder.left_bearing.x );
- glyph->root.metrics.horiAdvance =
+ t1glyph->metrics.horiAdvance =
FIXED_TO_INT( decoder.builder.advance.x );
internal->glyph_matrix = font_matrix;
@@ -390,45 +392,45 @@
else
{
FT_BBox cbox;
- FT_Glyph_Metrics* metrics = &glyph->root.metrics;
+ FT_Glyph_Metrics* metrics = &t1glyph->metrics;
FT_Vector advance;
/* copy the _unscaled_ advance width */
metrics->horiAdvance =
FIXED_TO_INT( decoder.builder.advance.x );
- glyph->root.linearHoriAdvance =
+ t1glyph->linearHoriAdvance =
FIXED_TO_INT( decoder.builder.advance.x );
- glyph->root.internal->glyph_transformed = 0;
+ t1glyph->internal->glyph_transformed = 0;
- if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
+ if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
{
/* make up vertical ones */
metrics->vertAdvance = ( face->type1.font_bbox.yMax -
face->type1.font_bbox.yMin ) >> 16;
- glyph->root.linearVertAdvance = metrics->vertAdvance;
+ t1glyph->linearVertAdvance = metrics->vertAdvance;
}
else
{
metrics->vertAdvance =
FIXED_TO_INT( decoder.builder.advance.y );
- glyph->root.linearVertAdvance =
+ t1glyph->linearVertAdvance =
FIXED_TO_INT( decoder.builder.advance.y );
}
- glyph->root.format = FT_GLYPH_FORMAT_OUTLINE;
+ t1glyph->format = FT_GLYPH_FORMAT_OUTLINE;
- if ( size && size->root.metrics.y_ppem < 24 )
- glyph->root.outline.flags |= FT_OUTLINE_HIGH_PRECISION;
+ if ( t1size && t1size->metrics.y_ppem < 24 )
+ t1glyph->outline.flags |= FT_OUTLINE_HIGH_PRECISION;
#if 1
/* apply the font matrix, if any */
if ( font_matrix.xx != 0x10000L || font_matrix.yy != font_matrix.xx ||
font_matrix.xy != 0 || font_matrix.yx != 0 )
- FT_Outline_Transform( &glyph->root.outline, &font_matrix );
+ FT_Outline_Transform( &t1glyph->outline, &font_matrix );
if ( font_offset.x || font_offset.y )
- FT_Outline_Translate( &glyph->root.outline,
+ FT_Outline_Translate( &t1glyph->outline,
font_offset.x,
font_offset.y );
@@ -466,7 +468,7 @@
}
/* compute the other metrics */
- FT_Outline_Get_CBox( &glyph->root.outline, &cbox );
+ FT_Outline_Get_CBox( &t1glyph->outline, &cbox );
metrics->width = cbox.xMax - cbox.xMin;
metrics->height = cbox.yMax - cbox.yMin;
@@ -474,7 +476,7 @@
metrics->horiBearingX = cbox.xMin;
metrics->horiBearingY = cbox.yMax;
- if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
+ if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
{
/* make up vertical ones */
ft_synthesize_vertical_metrics( metrics,
@@ -484,8 +486,8 @@
/* Set control data to the glyph charstrings. Note that this is */
/* _not_ zero-terminated. */
- glyph->root.control_data = (FT_Byte*)glyph_data.pointer;
- glyph->root.control_len = glyph_data.length;
+ t1glyph->control_data = (FT_Byte*)glyph_data.pointer;
+ t1glyph->control_len = glyph_data.length;
}
@@ -500,8 +502,8 @@
/* Set the control data to null - it is no longer available if */
/* loaded incrementally. */
- glyph->root.control_data = 0;
- glyph->root.control_len = 0;
+ t1glyph->control_data = 0;
+ t1glyph->control_len = 0;
}
#endif
diff --git a/3party/freetype/src/type1/t1gload.h b/3party/freetype/src/type1/t1gload.h
index 100df06e8e..0bdea3a8d5 100644
--- a/3party/freetype/src/type1/t1gload.h
+++ b/3party/freetype/src/type1/t1gload.h
@@ -4,7 +4,7 @@
/* */
/* Type 1 Glyph Loader (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2008, 2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -32,15 +32,15 @@ FT_BEGIN_HEADER
FT_Pos* max_advance );
FT_LOCAL( FT_Error )
- T1_Get_Advances( T1_Face face,
+ T1_Get_Advances( FT_Face face,
FT_UInt first,
FT_UInt count,
- FT_ULong load_flags,
+ FT_Int32 load_flags,
FT_Fixed* advances );
FT_LOCAL( FT_Error )
- T1_Load_Glyph( T1_GlyphSlot glyph,
- T1_Size size,
+ T1_Load_Glyph( FT_GlyphSlot glyph,
+ FT_Size size,
FT_UInt glyph_index,
FT_Int32 load_flags );
diff --git a/3party/freetype/src/type1/t1load.c b/3party/freetype/src/type1/t1load.c
index 1451fe5876..cc21b1154e 100644
--- a/3party/freetype/src/type1/t1load.c
+++ b/3party/freetype/src/type1/t1load.c
@@ -4,7 +4,7 @@
/* */
/* Type 1 font loader (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -71,6 +71,13 @@
#include "t1errors.h"
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+#define IS_INCREMENTAL ( face->root.internal->incremental_interface != 0 )
+#else
+#define IS_INCREMENTAL 0
+#endif
+
+
/*************************************************************************/
/* */
/* The macro FT_COMPONENT is used in trace mode. It is an implicit */
@@ -232,18 +239,11 @@
for ( j = 1; j < axismap->num_points; ++j )
{
if ( ncv <= axismap->blend_points[j] )
- {
- FT_Fixed t = FT_MulDiv( ncv - axismap->blend_points[j - 1],
- 0x10000L,
- axismap->blend_points[j] -
- axismap->blend_points[j - 1] );
-
return INT_TO_FIXED( axismap->design_points[j - 1] ) +
- FT_MulDiv( t,
- axismap->design_points[j] -
- axismap->design_points[j - 1],
- 1L );
- }
+ ( axismap->design_points[j] - axismap->design_points[j - 1] ) *
+ FT_DivFix( ncv - axismap->blend_points[j - 1],
+ axismap->blend_points[j] -
+ axismap->blend_points[j - 1] );
}
return INT_TO_FIXED( axismap->design_points[axismap->num_points - 1] );
@@ -320,7 +320,7 @@
mmvar->num_axis = mmaster.num_axis;
mmvar->num_designs = mmaster.num_designs;
- mmvar->num_namedstyles = (FT_UInt)-1; /* Does not apply */
+ mmvar->num_namedstyles = ~0; /* Does not apply */
mmvar->axis = (FT_Var_Axis*)&mmvar[1];
/* Point to axes after MM_Var struct */
mmvar->namedstyle = NULL;
@@ -333,8 +333,8 @@
mmvar->axis[i].def = ( mmvar->axis[i].minimum +
mmvar->axis[i].maximum ) / 2;
/* Does not apply. But this value is in range */
- mmvar->axis[i].strid = (FT_UInt)-1; /* Does not apply */
- mmvar->axis[i].tag = (FT_ULong)-1; /* Does not apply */
+ mmvar->axis[i].strid = ~0; /* Does not apply */
+ mmvar->axis[i].tag = ~0; /* Does not apply */
if ( ft_strcmp( mmvar->axis[i].name, "Weight" ) == 0 )
mmvar->axis[i].tag = FT_MAKE_TAG( 'w', 'g', 'h', 't' );
@@ -615,7 +615,7 @@
goto Exit;
}
- if ( FT_ALLOC( blend->axis_names[n], len + 1 ) )
+ if ( FT_ALLOC( blend->axis_names[n], (FT_Long)( len + 1 ) ) )
goto Exit;
name = (FT_Byte*)blend->axis_names[n];
@@ -1004,13 +1004,24 @@
max_objects = 0;
}
- if ( field->type == T1_FIELD_TYPE_INTEGER_ARRAY ||
- field->type == T1_FIELD_TYPE_FIXED_ARRAY )
- error = T1_Load_Field_Table( &loader->parser, field,
- objects, max_objects, 0 );
+ if ( *objects )
+ {
+ if ( field->type == T1_FIELD_TYPE_INTEGER_ARRAY ||
+ field->type == T1_FIELD_TYPE_FIXED_ARRAY )
+ error = T1_Load_Field_Table( &loader->parser, field,
+ objects, max_objects, 0 );
+ else
+ error = T1_Load_Field( &loader->parser, field,
+ objects, max_objects, 0 );
+ }
else
- error = T1_Load_Field( &loader->parser, field,
- objects, max_objects, 0 );
+ {
+ FT_TRACE1(( "t1_load_keyword: ignoring keyword `%s'"
+ " which is not valid at this point\n"
+ " (probably due to missing keywords)\n",
+ field->ident ));
+ error = T1_Err_Ok;
+ }
Exit:
return error;
@@ -1030,7 +1041,8 @@
static int
read_binary_data( T1_Parser parser,
FT_Long* size,
- FT_Byte** base )
+ FT_Byte** base,
+ FT_Bool incremental )
{
FT_Byte* cur;
FT_Byte* limit = parser->root.limit;
@@ -1065,8 +1077,12 @@
}
}
- FT_ERROR(( "read_binary_data: invalid size field\n" ));
- parser->root.error = T1_Err_Invalid_File_Format;
+ if( !incremental )
+ {
+ FT_ERROR(( "read_binary_data: invalid size field\n" ));
+ parser->root.error = T1_Err_Invalid_File_Format;
+ }
+
return 0;
}
@@ -1075,8 +1091,8 @@
/* and `/CharStrings' dictionaries. */
static void
- parse_font_matrix( T1_Face face,
- T1_Loader loader )
+ t1_parse_font_matrix( T1_Face face,
+ T1_Loader loader )
{
T1_Parser parser = &loader->parser;
FT_Matrix* matrix = &face->type1.font_matrix;
@@ -1099,7 +1115,7 @@
if ( temp_scale == 0 )
{
- FT_ERROR(( "parse_font_matrix: invalid font matrix\n" ));
+ FT_ERROR(( "t1_parse_font_matrix: invalid font matrix\n" ));
parser->root.error = T1_Err_Invalid_File_Format;
return;
}
@@ -1108,8 +1124,7 @@
/* 1000 / temp_scale, because temp_scale was already multiplied by */
/* 1000 (in t1_tofixed, from psobjs.c). */
- root->units_per_EM = (FT_UShort)( FT_DivFix( 1000 * 0x10000L,
- temp_scale ) >> 16 );
+ root->units_per_EM = (FT_UShort)FT_DivFix( 1000, temp_scale );
/* we need to scale the values by 1.0/temp_scale */
if ( temp_scale != 0x10000L )
@@ -1261,7 +1276,7 @@
cur = parser->root.cursor;
- if ( *cur == '/' && cur + 2 < limit && n < count )
+ if ( cur + 2 < limit && *cur == '/' && n < count )
{
FT_PtrDist len;
@@ -1270,6 +1285,8 @@
parser->root.cursor = cur;
T1_Skip_PS_Token( parser );
+ if ( parser->root.cursor >= limit )
+ return;
if ( parser->root.error )
return;
@@ -1387,15 +1404,17 @@
FT_Byte* base;
- /* If the next token isn't `dup' we are done. */
- if ( ft_strncmp( (char*)parser->root.cursor, "dup", 3 ) != 0 )
+ /* If we are out of data, or if the next token isn't `dup', */
+ /* we are done. */
+ if ( parser->root.cursor + 4 >= parser->root.limit ||
+ ft_strncmp( (char*)parser->root.cursor, "dup", 3 ) != 0 )
break;
T1_Skip_PS_Token( parser ); /* `dup' */
idx = T1_ToInt( parser );
- if ( !read_binary_data( parser, &size, &base ) )
+ if ( !read_binary_data( parser, &size, &base, IS_INCREMENTAL ) )
return;
/* The binary string is followed by one token, e.g. `NP' */
@@ -1407,7 +1426,8 @@
return;
T1_Skip_Spaces ( parser );
- if ( ft_strncmp( (char*)parser->root.cursor, "put", 3 ) == 0 )
+ if ( parser->root.cursor + 4 < parser->root.limit &&
+ ft_strncmp( (char*)parser->root.cursor, "put", 3 ) == 0 )
{
T1_Skip_PS_Token( parser ); /* skip `put' */
T1_Skip_Spaces ( parser );
@@ -1486,6 +1506,12 @@
num_glyphs = (FT_Int)T1_ToInt( parser );
+ if ( num_glyphs < 0 )
+ {
+ error = T1_Err_Invalid_File_Format;
+ goto Fail;
+ }
+
/* some fonts like Optima-Oblique not only define the /CharStrings */
/* array but access it also */
if ( num_glyphs == 0 || parser->root.error )
@@ -1580,7 +1606,7 @@
cur++; /* skip `/' */
len = parser->root.cursor - cur;
- if ( !read_binary_data( parser, &size, &base ) )
+ if ( !read_binary_data( parser, &size, &base, IS_INCREMENTAL ) )
return;
/* for some non-standard fonts like `Optima' which provides */
@@ -1772,7 +1798,7 @@
#include "t1tokens.h"
/* now add the special functions... */
- T1_FIELD_CALLBACK( "FontMatrix", parse_font_matrix,
+ T1_FIELD_CALLBACK( "FontMatrix", t1_parse_font_matrix,
T1_FIELD_DICT_FONTDICT )
T1_FIELD_CALLBACK( "Encoding", parse_encoding,
T1_FIELD_DICT_FONTDICT )
@@ -1869,7 +1895,7 @@
parser->root.cursor = start_binary;
- if ( !read_binary_data( parser, &s, &b ) )
+ if ( !read_binary_data( parser, &s, &b, IS_INCREMENTAL ) )
return T1_Err_Invalid_File_Format;
have_integer = 0;
}
@@ -1882,7 +1908,7 @@
parser->root.cursor = start_binary;
- if ( !read_binary_data( parser, &s, &b ) )
+ if ( !read_binary_data( parser, &s, &b, IS_INCREMENTAL ) )
return T1_Err_Invalid_File_Format;
have_integer = 0;
}
@@ -1955,8 +1981,8 @@
if ( !( dict & keyword->dict ) )
{
- FT_TRACE1(( "parse_dict: found %s but ignoring it "
- "since it is in the wrong dictionary\n",
+ FT_TRACE1(( "parse_dict: found `%s' but ignoring it"
+ " since it is in the wrong dictionary\n",
keyword->ident ));
break;
}
@@ -2158,9 +2184,7 @@
type1->subrs_len = loader.subrs.lengths;
}
-#ifdef FT_CONFIG_OPTION_INCREMENTAL
- if ( !face->root.internal->incremental_interface )
-#endif
+ if ( !IS_INCREMENTAL )
if ( !loader.charstrings.init )
{
FT_ERROR(( "T1_Open_Face: no `/CharStrings' array in face\n" ));
diff --git a/3party/freetype/src/type1/t1objs.c b/3party/freetype/src/type1/t1objs.c
index 58632109c7..b685f2f1bf 100644
--- a/3party/freetype/src/type1/t1objs.c
+++ b/3party/freetype/src/type1/t1objs.c
@@ -4,7 +4,7 @@
/* */
/* Type 1 objects manager (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
+/* Copyright 1996-2009, 2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -72,8 +72,11 @@
FT_LOCAL_DEF( void )
- T1_Size_Done( T1_Size size )
+ T1_Size_Done( FT_Size t1size ) /* T1_Size */
{
+ T1_Size size = (T1_Size)t1size;
+
+
if ( size->root.internal )
{
PSH_Globals_Funcs funcs;
@@ -89,8 +92,9 @@
FT_LOCAL_DEF( FT_Error )
- T1_Size_Init( T1_Size size )
+ T1_Size_Init( FT_Size t1size ) /* T1_Size */
{
+ T1_Size size = (T1_Size)t1size;
FT_Error error = T1_Err_Ok;
PSH_Globals_Funcs funcs = T1_Size_Get_Globals_Funcs( size );
@@ -112,9 +116,10 @@
FT_LOCAL_DEF( FT_Error )
- T1_Size_Request( T1_Size size,
+ T1_Size_Request( FT_Size t1size, /* T1_Size */
FT_Size_Request req )
{
+ T1_Size size = (T1_Size)t1size;
PSH_Globals_Funcs funcs = T1_Size_Get_Globals_Funcs( size );
@@ -137,20 +142,20 @@
/*************************************************************************/
FT_LOCAL_DEF( void )
- T1_GlyphSlot_Done( T1_GlyphSlot slot )
+ T1_GlyphSlot_Done( FT_GlyphSlot slot )
{
- slot->root.internal->glyph_hints = 0;
+ slot->internal->glyph_hints = 0;
}
FT_LOCAL_DEF( FT_Error )
- T1_GlyphSlot_Init( T1_GlyphSlot slot )
+ T1_GlyphSlot_Init( FT_GlyphSlot slot )
{
T1_Face face;
PSHinter_Service pshinter;
- face = (T1_Face)slot->root.face;
+ face = (T1_Face)slot->face;
pshinter = (PSHinter_Service)face->pshinter;
if ( pshinter )
@@ -158,15 +163,18 @@
FT_Module module;
- module = FT_Get_Module( slot->root.face->driver->root.library, "pshinter" );
- if (module)
+ module = FT_Get_Module( slot->face->driver->root.library,
+ "pshinter" );
+ if ( module )
{
T1_Hints_Funcs funcs;
+
funcs = pshinter->get_t1_funcs( module );
- slot->root.internal->glyph_hints = (void*)funcs;
+ slot->internal->glyph_hints = (void*)funcs;
}
}
+
return 0;
}
@@ -190,8 +198,9 @@
/* face :: A typeless pointer to the face object to destroy. */
/* */
FT_LOCAL_DEF( void )
- T1_Face_Done( T1_Face face )
+ T1_Face_Done( FT_Face t1face ) /* T1_Face */
{
+ T1_Face face = (T1_Face)t1face;
FT_Memory memory;
T1_Font type1;
@@ -289,11 +298,12 @@
/* */
FT_LOCAL_DEF( FT_Error )
T1_Face_Init( FT_Stream stream,
- T1_Face face,
+ FT_Face t1face, /* T1_Face */
FT_Int face_index,
FT_Int num_params,
FT_Parameter* params )
{
+ T1_Face face = (T1_Face)t1face;
FT_Error error;
FT_Service_PsCMaps psnames;
PSAux_Service psaux;
@@ -313,10 +323,18 @@
face->psaux = FT_Get_Module_Interface( FT_FACE_LIBRARY( face ),
"psaux" );
psaux = (PSAux_Service)face->psaux;
+ if ( !psaux )
+ {
+ FT_ERROR(( "T1_Face_Init: cannot access `psaux' module\n" ));
+ error = T1_Err_Missing_Module;
+ goto Exit;
+ }
face->pshinter = FT_Get_Module_Interface( FT_FACE_LIBRARY( face ),
"pshinter" );
+ FT_TRACE2(( "Type 1 driver\n" ));
+
/* open the tokenizer; this will also check the font format */
error = T1_Open_Face( face );
if ( error )
@@ -447,7 +465,7 @@
root->bbox.xMax = ( type1->font_bbox.xMax + 0xFFFF ) >> 16;
root->bbox.yMax = ( type1->font_bbox.yMax + 0xFFFF ) >> 16;
- /* Set units_per_EM if we didn't set it in parse_font_matrix. */
+ /* Set units_per_EM if we didn't set it in t1_parse_font_matrix. */
if ( !root->units_per_EM )
root->units_per_EM = 1000;
@@ -484,7 +502,7 @@
FT_Face root = &face->root;
- if ( psnames && psaux )
+ if ( psnames )
{
FT_CharMapRec charmap;
T1_CMap_Classes cmap_classes = psaux->t1_cmap_classes;
@@ -568,7 +586,7 @@
/* FreeType error code. 0 means success. */
/* */
FT_LOCAL_DEF( FT_Error )
- T1_Driver_Init( T1_Driver driver )
+ T1_Driver_Init( FT_Module driver )
{
FT_UNUSED( driver );
@@ -588,7 +606,7 @@
/* driver :: A handle to the target Type 1 driver. */
/* */
FT_LOCAL_DEF( void )
- T1_Driver_Done( T1_Driver driver )
+ T1_Driver_Done( FT_Module driver )
{
FT_UNUSED( driver );
}
diff --git a/3party/freetype/src/type1/t1objs.h b/3party/freetype/src/type1/t1objs.h
index e5e90293d7..54ccbb996a 100644
--- a/3party/freetype/src/type1/t1objs.h
+++ b/3party/freetype/src/type1/t1objs.h
@@ -4,7 +4,7 @@
/* */
/* Type 1 objects manager (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2006 by */
+/* Copyright 1996-2001, 2002, 2006, 2011 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -37,17 +37,6 @@ FT_BEGIN_HEADER
/*************************************************************************/
/* */
/* <Type> */
- /* T1_Driver */
- /* */
- /* <Description> */
- /* A handle to a Type 1 driver object. */
- /* */
- typedef struct T1_DriverRec_ *T1_Driver;
-
-
- /*************************************************************************/
- /* */
- /* <Type> */
/* T1_Size */
/* */
/* <Description> */
@@ -106,14 +95,14 @@ FT_BEGIN_HEADER
FT_LOCAL( void )
- T1_Size_Done( T1_Size size );
+ T1_Size_Done( FT_Size size );
FT_LOCAL( FT_Error )
- T1_Size_Request( T1_Size size,
+ T1_Size_Request( FT_Size size,
FT_Size_Request req );
FT_LOCAL( FT_Error )
- T1_Size_Init( T1_Size size );
+ T1_Size_Init( FT_Size size );
/*************************************************************************/
@@ -142,25 +131,25 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Error )
T1_Face_Init( FT_Stream stream,
- T1_Face face,
+ FT_Face face,
FT_Int face_index,
FT_Int num_params,
FT_Parameter* params );
FT_LOCAL( void )
- T1_Face_Done( T1_Face face );
+ T1_Face_Done( FT_Face face );
FT_LOCAL( FT_Error )
- T1_GlyphSlot_Init( T1_GlyphSlot slot );
+ T1_GlyphSlot_Init( FT_GlyphSlot slot );
FT_LOCAL( void )
- T1_GlyphSlot_Done( T1_GlyphSlot slot );
+ T1_GlyphSlot_Done( FT_GlyphSlot slot );
FT_LOCAL( FT_Error )
- T1_Driver_Init( T1_Driver driver );
+ T1_Driver_Init( FT_Module driver );
FT_LOCAL( void )
- T1_Driver_Done( T1_Driver driver );
+ T1_Driver_Done( FT_Module driver );
FT_END_HEADER
diff --git a/3party/freetype/src/type1/t1parse.c b/3party/freetype/src/type1/t1parse.c
index 2a762279fd..b48651a013 100644
--- a/3party/freetype/src/type1/t1parse.c
+++ b/3party/freetype/src/type1/t1parse.c
@@ -4,7 +4,7 @@
/* */
/* Type 1 parser (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2008, 2009 by */
+/* Copyright 1996-2005, 2008, 2009, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -164,7 +164,7 @@
error = check_type1_format( stream, "%!FontType", 10 );
if ( error )
{
- FT_TRACE2(( "[not a Type1 font]\n" ));
+ FT_TRACE2(( " not a Type 1 font\n" ));
goto Exit;
}
}
@@ -342,7 +342,7 @@
{
c = cur[0];
if ( c == 'e' && cur + 9 < limit ) /* 9 = 5 letters for `eexec' + */
- /* newline + 4 chars */
+ /* whitespace + 4 chars */
{
if ( cur[1] == 'e' &&
cur[2] == 'x' &&
@@ -364,7 +364,8 @@
/* or string (as e.g. in u003043t.gsf from ghostscript) */
parser->root.cursor = parser->base_dict;
- parser->root.limit = cur + 9;
+ /* set limit to `eexec' + whitespace + 4 characters */
+ parser->root.limit = cur + 10;
cur = parser->root.cursor;
limit = parser->root.limit;
@@ -396,7 +397,8 @@
parser->root.limit = parser->base_dict + parser->base_len;
T1_Skip_PS_Token( parser );
- cur = parser->root.cursor;
+ cur = parser->root.cursor;
+ limit = parser->root.limit;
/* according to the Type1 spec, the first cipher byte must not be */
/* an ASCII whitespace character code (blank, tab, carriage return */
@@ -404,7 +406,7 @@
/* characters... So skip now all whitespace character codes. */
while ( cur < limit &&
( *cur == ' ' ||
- *cur == '\t' ||
+ *cur == '\t' ||
*cur == '\r' ||
*cur == '\n' ) )
++cur;
@@ -437,11 +439,12 @@
/* now determine whether the private dictionary is encoded in binary */
/* or hexadecimal ASCII format -- decode it accordingly */
- /* we need to access the next 4 bytes (after the final \r following */
- /* the `eexec' keyword); if they all are hexadecimal digits, then */
- /* we have a case of ASCII storage */
+ /* we need to access the next 4 bytes (after the final whitespace */
+ /* following the `eexec' keyword); if they all are hexadecimal */
+ /* digits, then we have a case of ASCII storage */
- if ( ft_isxdigit( cur[0] ) && ft_isxdigit( cur[1] ) &&
+ if ( cur + 3 < limit &&
+ ft_isxdigit( cur[0] ) && ft_isxdigit( cur[1] ) &&
ft_isxdigit( cur[2] ) && ft_isxdigit( cur[3] ) )
{
/* ASCII hexadecimal encoding */
@@ -467,6 +470,14 @@
/* we now decrypt the encoded binary private dictionary */
psaux->t1_decrypt( parser->private_dict, parser->private_len, 55665U );
+ if ( parser->private_len < 4 )
+ {
+ FT_ERROR(( "T1_Get_Private_Dict:"
+ " invalid private dictionary section\n" ));
+ error = T1_Err_Invalid_File_Format;
+ goto Fail;
+ }
+
/* replace the four random bytes at the beginning with whitespace */
parser->private_dict[0] = ' ';
parser->private_dict[1] = ' ';
diff --git a/3party/freetype/src/type1/t1tokens.h b/3party/freetype/src/type1/t1tokens.h
index 2d692f0e61..e37276b908 100644
--- a/3party/freetype/src/type1/t1tokens.h
+++ b/3party/freetype/src/type1/t1tokens.h
@@ -96,7 +96,7 @@
T1_FIELD_DICT_PRIVATE )
T1_FIELD_BOOL ( "ForceBold", force_bold,
T1_FIELD_DICT_PRIVATE )
-
+
#undef FT_STRUCTURE
#define FT_STRUCTURE T1_FontRec
diff --git a/3party/freetype/src/type42/t42drivr.c b/3party/freetype/src/type42/t42drivr.c
index f56d6e773c..9b93209ad1 100644
--- a/3party/freetype/src/type42/t42drivr.c
+++ b/3party/freetype/src/type42/t42drivr.c
@@ -184,11 +184,11 @@
};
- static FT_Module_Interface
- T42_Get_Interface( FT_Driver driver,
+ FT_CALLBACK_DEF( FT_Module_Interface )
+ T42_Get_Interface( FT_Module module,
const FT_String* t42_interface )
{
- FT_UNUSED( driver );
+ FT_UNUSED( module );
return ft_service_list_lookup( t42_services, t42_interface );
}
@@ -213,34 +213,34 @@
0, /* format interface */
- (FT_Module_Constructor)T42_Driver_Init,
- (FT_Module_Destructor) T42_Driver_Done,
- (FT_Module_Requester) T42_Get_Interface,
+ T42_Driver_Init,
+ T42_Driver_Done,
+ T42_Get_Interface,
},
sizeof ( T42_FaceRec ),
sizeof ( T42_SizeRec ),
sizeof ( T42_GlyphSlotRec ),
- (FT_Face_InitFunc) T42_Face_Init,
- (FT_Face_DoneFunc) T42_Face_Done,
- (FT_Size_InitFunc) T42_Size_Init,
- (FT_Size_DoneFunc) T42_Size_Done,
- (FT_Slot_InitFunc) T42_GlyphSlot_Init,
- (FT_Slot_DoneFunc) T42_GlyphSlot_Done,
+ T42_Face_Init,
+ T42_Face_Done,
+ T42_Size_Init,
+ T42_Size_Done,
+ T42_GlyphSlot_Init,
+ T42_GlyphSlot_Done,
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
ft_stub_set_char_sizes,
ft_stub_set_pixel_sizes,
#endif
- (FT_Slot_LoadFunc) T42_GlyphSlot_Load,
+ T42_GlyphSlot_Load,
- (FT_Face_GetKerningFunc) 0,
- (FT_Face_AttachFunc) 0,
+ 0, /* FT_Face_GetKerningFunc */
+ 0, /* FT_Face_AttachFunc */
- (FT_Face_GetAdvancesFunc) 0,
- (FT_Size_RequestFunc) T42_Size_Request,
- (FT_Size_SelectFunc) T42_Size_Select
+ 0, /* FT_Face_GetAdvancesFunc */
+ T42_Size_Request,
+ T42_Size_Select
};
diff --git a/3party/freetype/src/type42/t42drivr.h b/3party/freetype/src/type42/t42drivr.h
index 4717e4613f..9a1e97e30e 100644
--- a/3party/freetype/src/type42/t42drivr.h
+++ b/3party/freetype/src/type42/t42drivr.h
@@ -27,7 +27,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
FT_EXPORT_VAR( const FT_Driver_ClassRec ) t42_driver_class;
diff --git a/3party/freetype/src/type42/t42error.h b/3party/freetype/src/type42/t42error.h
index b230910012..217ae8bd52 100644
--- a/3party/freetype/src/type42/t42error.h
+++ b/3party/freetype/src/type42/t42error.h
@@ -4,7 +4,7 @@
/* */
/* Type 42 error codes (specification only). */
/* */
-/* Copyright 2002, 2003 by */
+/* Copyright 2002, 2003, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,6 +29,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX T42_Err_
#define FT_ERR_BASE FT_Mod_Err_Type42
diff --git a/3party/freetype/src/type42/t42objs.c b/3party/freetype/src/type42/t42objs.c
index a5e0ee5e81..c6053afed2 100644
--- a/3party/freetype/src/type42/t42objs.c
+++ b/3party/freetype/src/type42/t42objs.c
@@ -4,7 +4,7 @@
/* */
/* Type 42 objects manager (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 */
+/* Copyright 2002-2009, 2011 */
/* by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -21,7 +21,7 @@
#include "t42error.h"
#include FT_INTERNAL_DEBUG_H
#include FT_LIST_H
-#include FT_TRUETYPE_IDS_H
+#include FT_TRUETYPE_IDS_H
#undef FT_COMPONENT
@@ -61,6 +61,8 @@
if ( type1->font_type != 42 )
{
+ FT_ERROR(( "T42_Open_Face: cannot handle FontType %d\n",
+ type1->font_type ));
error = T42_Err_Unknown_File_Format;
goto Exit;
}
@@ -152,11 +154,12 @@
FT_LOCAL_DEF( FT_Error )
T42_Face_Init( FT_Stream stream,
- T42_Face face,
+ FT_Face t42face, /* T42_Face */
FT_Int face_index,
FT_Int num_params,
FT_Parameter* params )
{
+ T42_Face face = (T42_Face)t42face;
FT_Error error;
FT_Service_PsCMaps psnames;
PSAux_Service psaux;
@@ -179,6 +182,14 @@
face->psaux = FT_Get_Module_Interface( FT_FACE_LIBRARY( face ),
"psaux" );
psaux = (PSAux_Service)face->psaux;
+ if ( !psaux )
+ {
+ FT_ERROR(( "T42_Face_Init: cannot access `psaux' module\n" ));
+ error = T42_Err_Missing_Module;
+ goto Exit;
+ }
+
+ FT_TRACE2(( "Type 42 driver\n" ));
/* open the tokenizer, this will also check the font format */
error = T42_Open_Face( face );
@@ -321,7 +332,7 @@
root->face_flags |= FT_FACE_FLAG_VERTICAL;
{
- if ( psnames && psaux )
+ if ( psnames )
{
FT_CharMapRec charmap;
T1_CMap_Classes cmap_classes = psaux->t1_cmap_classes;
@@ -390,8 +401,9 @@
FT_LOCAL_DEF( void )
- T42_Face_Done( T42_Face face )
+ T42_Face_Done( FT_Face t42face )
{
+ T42_Face face = (T42_Face)t42face;
T1_Font type1;
PS_FontInfo info;
FT_Memory memory;
@@ -459,12 +471,19 @@
/* FreeType error code. 0 means success. */
/* */
FT_LOCAL_DEF( FT_Error )
- T42_Driver_Init( T42_Driver driver )
+ T42_Driver_Init( FT_Module module ) /* T42_Driver */
{
- FT_Module ttmodule;
+ T42_Driver driver = (T42_Driver)module;
+ FT_Module ttmodule;
- ttmodule = FT_Get_Module( FT_MODULE(driver)->library, "truetype" );
+ ttmodule = FT_Get_Module( module->library, "truetype" );
+ if ( !ttmodule )
+ {
+ FT_ERROR(( "T42_Driver_Init: cannot access `truetype' module\n" ));
+ return T42_Err_Missing_Module;
+ }
+
driver->ttclazz = (FT_Driver_Class)ttmodule->clazz;
return T42_Err_Ok;
@@ -472,23 +491,24 @@
FT_LOCAL_DEF( void )
- T42_Driver_Done( T42_Driver driver )
+ T42_Driver_Done( FT_Module module )
{
- FT_UNUSED( driver );
+ FT_UNUSED( module );
}
FT_LOCAL_DEF( FT_Error )
- T42_Size_Init( T42_Size size )
+ T42_Size_Init( FT_Size size ) /* T42_Size */
{
- FT_Face face = size->root.face;
+ T42_Size t42size = (T42_Size)size;
+ FT_Face face = size->face;
T42_Face t42face = (T42_Face)face;
FT_Size ttsize;
FT_Error error = T42_Err_Ok;
error = FT_New_Size( t42face->ttf_face, &ttsize );
- size->ttsize = ttsize;
+ t42size->ttsize = ttsize;
FT_Activate_Size( ttsize );
@@ -497,10 +517,11 @@
FT_LOCAL_DEF( FT_Error )
- T42_Size_Request( T42_Size size,
+ T42_Size_Request( FT_Size t42size, /* T42_Size */
FT_Size_Request req )
{
- T42_Face face = (T42_Face)size->root.face;
+ T42_Size size = (T42_Size)t42size;
+ T42_Face face = (T42_Face)t42size->face;
FT_Error error;
@@ -508,17 +529,18 @@
error = FT_Request_Size( face->ttf_face, req );
if ( !error )
- ( (FT_Size)size )->metrics = face->ttf_face->size->metrics;
+ t42size->metrics = face->ttf_face->size->metrics;
return error;
}
FT_LOCAL_DEF( FT_Error )
- T42_Size_Select( T42_Size size,
+ T42_Size_Select( FT_Size t42size, /* T42_Size */
FT_ULong strike_index )
{
- T42_Face face = (T42_Face)size->root.face;
+ T42_Size size = (T42_Size)t42size;
+ T42_Face face = (T42_Face)t42size->face;
FT_Error error;
@@ -526,7 +548,7 @@
error = FT_Select_Size( face->ttf_face, (FT_Int)strike_index );
if ( !error )
- ( (FT_Size)size )->metrics = face->ttf_face->size->metrics;
+ t42size->metrics = face->ttf_face->size->metrics;
return error;
@@ -534,9 +556,10 @@
FT_LOCAL_DEF( void )
- T42_Size_Done( T42_Size size )
+ T42_Size_Done( FT_Size t42size ) /* T42_Size */
{
- FT_Face face = size->root.face;
+ T42_Size size = (T42_Size)t42size;
+ FT_Face face = t42size->face;
T42_Face t42face = (T42_Face)face;
FT_ListNode node;
@@ -551,12 +574,13 @@
FT_LOCAL_DEF( FT_Error )
- T42_GlyphSlot_Init( T42_GlyphSlot slot )
+ T42_GlyphSlot_Init( FT_GlyphSlot t42slot ) /* T42_GlyphSlot */
{
- FT_Face face = slot->root.face;
- T42_Face t42face = (T42_Face)face;
- FT_GlyphSlot ttslot;
- FT_Error error = T42_Err_Ok;
+ T42_GlyphSlot slot = (T42_GlyphSlot)t42slot;
+ FT_Face face = t42slot->face;
+ T42_Face t42face = (T42_Face)face;
+ FT_GlyphSlot ttslot;
+ FT_Error error = T42_Err_Ok;
if ( face->glyph == NULL )
@@ -575,8 +599,11 @@
FT_LOCAL_DEF( void )
- T42_GlyphSlot_Done( T42_GlyphSlot slot )
+ T42_GlyphSlot_Done( FT_GlyphSlot t42slot ) /* T42_GlyphSlot */
{
+ T42_GlyphSlot slot = (T42_GlyphSlot)t42slot;
+
+
FT_Done_GlyphSlot( slot->ttslot );
}
diff --git a/3party/freetype/src/type42/t42objs.h b/3party/freetype/src/type42/t42objs.h
index 289dedcc69..02d13259be 100644
--- a/3party/freetype/src/type42/t42objs.h
+++ b/3party/freetype/src/type42/t42objs.h
@@ -4,7 +4,7 @@
/* */
/* Type 42 objects manager (specification). */
/* */
-/* Copyright 2002, 2003, 2006, 2007 by Roberto Alameda. */
+/* Copyright 2002, 2003, 2006, 2007, 2011 by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
@@ -65,36 +65,36 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Error )
T42_Face_Init( FT_Stream stream,
- T42_Face face,
+ FT_Face face,
FT_Int face_index,
FT_Int num_params,
FT_Parameter* params );
FT_LOCAL( void )
- T42_Face_Done( T42_Face face );
+ T42_Face_Done( FT_Face face );
FT_LOCAL( FT_Error )
- T42_Size_Init( T42_Size size );
+ T42_Size_Init( FT_Size size );
FT_LOCAL( FT_Error )
- T42_Size_Request( T42_Size size,
+ T42_Size_Request( FT_Size size,
FT_Size_Request req );
FT_LOCAL( FT_Error )
- T42_Size_Select( T42_Size size,
+ T42_Size_Select( FT_Size size,
FT_ULong strike_index );
FT_LOCAL( void )
- T42_Size_Done( T42_Size size );
+ T42_Size_Done( FT_Size size );
FT_LOCAL( FT_Error )
- T42_GlyphSlot_Init( T42_GlyphSlot slot );
+ T42_GlyphSlot_Init( FT_GlyphSlot slot );
FT_LOCAL( FT_Error )
@@ -104,14 +104,14 @@ FT_BEGIN_HEADER
FT_Int32 load_flags );
FT_LOCAL( void )
- T42_GlyphSlot_Done( T42_GlyphSlot slot );
+ T42_GlyphSlot_Done( FT_GlyphSlot slot );
FT_LOCAL( FT_Error )
- T42_Driver_Init( T42_Driver driver );
+ T42_Driver_Init( FT_Module module );
FT_LOCAL( void )
- T42_Driver_Done( T42_Driver driver );
+ T42_Driver_Done( FT_Module module );
/* */
diff --git a/3party/freetype/src/type42/t42parse.c b/3party/freetype/src/type42/t42parse.c
index 577426917b..2b28240303 100644
--- a/3party/freetype/src/type42/t42parse.c
+++ b/3party/freetype/src/type42/t42parse.c
@@ -4,7 +4,7 @@
/* */
/* Type 42 font parser (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by */
+/* Copyright 2002-2012 by */
/* Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -175,7 +175,7 @@
if ( ft_memcmp( stream->cursor, "%!PS-TrueTypeFont", 17 ) != 0 )
{
- FT_TRACE2(( "not a Type42 font\n" ));
+ FT_TRACE2(( " not a Type42 font\n" ));
error = T42_Err_Unknown_File_Format;
}
@@ -265,8 +265,7 @@
/* 1000 / temp_scale, because temp_scale was already multiplied by */
/* 1000 (in t1_tofixed, from psobjs.c). */
- root->units_per_EM = (FT_UShort)( FT_DivFix( 1000 * 0x10000L,
- temp_scale ) >> 16 );
+ root->units_per_EM = (FT_UShort)FT_DivFix( 1000, temp_scale );
/* we need to scale the values by 1.0/temp_scale */
if ( temp_scale != 0x10000L )
@@ -607,8 +606,9 @@
goto Fail;
}
- /* A string can have a trailing zero byte for padding. Ignore it. */
- if ( string_buf[string_size - 1] == 0 && ( string_size % 2 == 1 ) )
+ /* A string can have a trailing zero (odd) byte for padding. */
+ /* Ignore it. */
+ if ( ( string_size & 1 ) && string_buf[string_size - 1] == 0 )
string_size--;
if ( !string_size )
diff --git a/3party/freetype/src/winfonts/fnterrs.h b/3party/freetype/src/winfonts/fnterrs.h
index ea80909715..463ba77ee2 100644
--- a/3party/freetype/src/winfonts/fnterrs.h
+++ b/3party/freetype/src/winfonts/fnterrs.h
@@ -4,7 +4,7 @@
/* */
/* Win FNT/FON error codes (specification only). */
/* */
-/* Copyright 2001 by */
+/* Copyright 2001, 2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#undef __FTERRORS_H__
+#undef FT_ERR_PREFIX
#define FT_ERR_PREFIX FNT_Err_
#define FT_ERR_BASE FT_Mod_Err_Winfonts
diff --git a/3party/freetype/src/winfonts/winfnt.c b/3party/freetype/src/winfonts/winfnt.c
index ee17d16659..a551896644 100644
--- a/3party/freetype/src/winfonts/winfnt.c
+++ b/3party/freetype/src/winfonts/winfnt.c
@@ -4,7 +4,7 @@
/* */
/* FreeType font driver for Windows FNT/FON files */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008, 2009, 2010 by */
+/* Copyright 1996-2004, 2006-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* Copyright 2003 Huw D M Davies for Codeweavers */
/* Copyright 2007 Dmitry Timoshkov for Codeweavers */
@@ -23,7 +23,7 @@
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_OBJECTS_H
-#include FT_TRUETYPE_IDS_H
+#include FT_TRUETYPE_IDS_H
#include "winfnt.h"
#include "fnterrs.h"
@@ -224,7 +224,7 @@
if ( header->version != 0x200 &&
header->version != 0x300 )
{
- FT_TRACE2(( "[not a valid FNT file]\n" ));
+ FT_TRACE2(( " not a Windows FNT file\n" ));
error = FNT_Err_Unknown_File_Format;
goto Exit;
}
@@ -234,7 +234,7 @@
if ( header->file_size < size )
{
- FT_TRACE2(( "[not a valid FNT file]\n" ));
+ FT_TRACE2(( " not a Windows FNT file\n" ));
error = FNT_Err_Unknown_File_Format;
goto Exit;
}
@@ -665,8 +665,9 @@
static void
- FNT_Face_Done( FNT_Face face )
+ FNT_Face_Done( FT_Face fntface ) /* FNT_Face */
{
+ FNT_Face face = (FNT_Face)fntface;
FT_Memory memory;
@@ -677,18 +678,19 @@
fnt_font_done( face );
- FT_FREE( face->root.available_sizes );
- face->root.num_fixed_sizes = 0;
+ FT_FREE( fntface->available_sizes );
+ fntface->num_fixed_sizes = 0;
}
static FT_Error
FNT_Face_Init( FT_Stream stream,
- FNT_Face face,
+ FT_Face fntface, /* FNT_Face */
FT_Int face_index,
FT_Int num_params,
FT_Parameter* params )
{
+ FNT_Face face = (FNT_Face)fntface;
FT_Error error;
FT_Memory memory = FT_FACE_MEMORY( face );
@@ -696,6 +698,8 @@
FT_UNUSED( params );
+ FT_TRACE2(( "Windows FNT driver\n" ));
+
/* try to load font from a DLL */
error = fnt_face_get_dll_font( face, face_index );
if ( !error && face_index < 0 )
@@ -709,7 +713,7 @@
if ( FT_NEW( face->font ) )
goto Exit;
- face->root.num_faces = 1;
+ fntface->num_faces = 1;
font = face->font;
font->offset = 0;
@@ -827,7 +831,14 @@
root->charmap = root->charmaps[0];
}
- /* setup remaining flags */
+ /* set up remaining flags */
+
+ if ( font->header.last_char < font->header.first_char )
+ {
+ FT_TRACE2(( "invalid number of glyphs\n" ));
+ error = FNT_Err_Invalid_File_Format;
+ goto Fail;
+ }
/* reserve one slot for the .notdef glyph at index 0 */
root->num_glyphs = font->header.last_char -
@@ -874,7 +885,7 @@
goto Exit;
Fail:
- FNT_Face_Done( face );
+ FNT_Face_Done( fntface );
Exit:
return error;
@@ -882,11 +893,14 @@
static FT_Error
- FNT_Size_Select( FT_Size size )
+ FNT_Size_Select( FT_Size size,
+ FT_ULong strike_index )
{
FNT_Face face = (FNT_Face)size->face;
FT_WinFNT_Header header = &face->font->header;
+ FT_UNUSED( strike_index );
+
FT_Select_Metrics( size->face, 0 );
@@ -933,7 +947,7 @@
if ( error )
return error;
else
- return FNT_Size_Select( size );
+ return FNT_Size_Select( size, 0 );
}
@@ -1086,10 +1100,10 @@
static FT_Module_Interface
- winfnt_get_service( FT_Driver driver,
+ winfnt_get_service( FT_Module module,
const FT_String* service_id )
{
- FT_UNUSED( driver );
+ FT_UNUSED( module );
return ft_service_list_lookup( winfnt_services, service_id );
}
@@ -1111,34 +1125,34 @@
0,
- (FT_Module_Constructor)0,
- (FT_Module_Destructor) 0,
- (FT_Module_Requester) winfnt_get_service
+ 0, /* FT_Module_Constructor */
+ 0, /* FT_Module_Destructor */
+ winfnt_get_service
},
- sizeof( FNT_FaceRec ),
- sizeof( FT_SizeRec ),
- sizeof( FT_GlyphSlotRec ),
+ sizeof ( FNT_FaceRec ),
+ sizeof ( FT_SizeRec ),
+ sizeof ( FT_GlyphSlotRec ),
- (FT_Face_InitFunc) FNT_Face_Init,
- (FT_Face_DoneFunc) FNT_Face_Done,
- (FT_Size_InitFunc) 0,
- (FT_Size_DoneFunc) 0,
- (FT_Slot_InitFunc) 0,
- (FT_Slot_DoneFunc) 0,
+ FNT_Face_Init,
+ FNT_Face_Done,
+ 0, /* FT_Size_InitFunc */
+ 0, /* FT_Size_DoneFunc */
+ 0, /* FT_Slot_InitFunc */
+ 0, /* FT_Slot_DoneFunc */
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
ft_stub_set_char_sizes,
ft_stub_set_pixel_sizes,
#endif
- (FT_Slot_LoadFunc) FNT_Load_Glyph,
+ FNT_Load_Glyph,
- (FT_Face_GetKerningFunc) 0,
- (FT_Face_AttachFunc) 0,
- (FT_Face_GetAdvancesFunc) 0,
+ 0, /* FT_Face_GetKerningFunc */
+ 0, /* FT_Face_AttachFunc */
+ 0, /* FT_Face_GetAdvancesFunc */
- (FT_Size_RequestFunc) FNT_Size_Request,
- (FT_Size_SelectFunc) FNT_Size_Select
+ FNT_Size_Request,
+ FNT_Size_Select
};
diff --git a/3party/freetype/src/winfonts/winfnt.h b/3party/freetype/src/winfonts/winfnt.h
index 70a90861ab..b7a80736d8 100644
--- a/3party/freetype/src/winfonts/winfnt.h
+++ b/3party/freetype/src/winfonts/winfnt.h
@@ -30,7 +30,7 @@ FT_BEGIN_HEADER
#ifdef FT_CONFIG_OPTION_PIC
#error "this module does not support PIC yet"
-#endif
+#endif
typedef struct WinMZ_HeaderRec_
{