1 2013-12-08 Werner Lemberg <wl@gnu.org>
3 * Version 2.5.2 released.
4 =========================
7 Tag sources with `VER-2-5-2'.
9 * docs/VERSION.DLL: Update documentation and bump version number to
12 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
13 builds/windows/vc2005/index.html,
14 builds/windows/vc2008/freetype.vcproj,
15 builds/windows/vc2008/index.html,
16 builds/windows/vc2010/freetype.vcxproj,
17 builds/windows/vc2010/index.html,
18 builds/windows/visualc/freetype.dsp,
19 builds/windows/visualc/freetype.vcproj,
20 builds/windows/visualc/index.html,
21 builds/windows/visualce/freetype.dsp,
22 builds/windows/visualce/freetype.vcproj,
23 builds/windows/visualce/index.html,
24 builds/wince/vc2005-ce/freetype.vcproj,
25 builds/wince/vc2005-ce/index.html,
26 builds/wince/vc2008-ce/freetype.vcproj,
27 builds/wince/vc2008-ce/index.html: s/2.5.1/2.5.2/, s/251/252/.
29 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
31 * builds/unix/configure.raw (version_info): Set to 17:1:11.
32 * docs/CHANGES: Updated.
34 2013-12-07 Werner Lemberg <wl@gnu.org>
36 [truetype] Next round in phantom point handling.
38 Greg Hitchcock provided very interesting insights into the
39 complicated history of the horizontal positions of the TSB and BSB
42 * src/truetype/ttgload.c (TT_LOADER_SET_PP)
43 [TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Use `subpixel_hinting' and
44 `grayscale_hinting' flags as conditionals for the x position of TSB
47 2013-12-05 Werner Lemberg <wl@gnu.org>
49 * builds/freetype.mk (FT_CC): Removed. Unused.
51 2013-12-04 Werner Lemberg <wl@gnu.org>
53 [sfnt] Fix handling of embedded bitmap strikes.
55 This corrects the commit from 2013-11-21. Problem reported by
56 Andrey Panov <panov@canopus.iacp.dvo.ru>.
58 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Fix logic to
59 detect excessive bytes for bit-aligned bitmaps.
61 2013-12-03 Werner Lemberg <wl@gnu.org>
63 [truetype] Remove dead code.
65 Reported by Nigel Tao <nigeltao@golang.org>.
67 * include/internal/tttypes.h (TT_LoaderRec): Remove unused
69 * src/truetype/ttgload.c (TT_Hint_Glyph): Updated.
71 2013-12-03 Werner Lemberg <wl@gnu.org>
73 [truetype] Fix phantom point handling.
75 This is a further improvement to the changes from 2013-11-06.
77 * src/truetype/ttgload.c (TT_Hint_Glyph): Horizontal phantom points
78 are rounded horizontally, vertical ones are rounded vertically.
79 (TT_LOADER_SET_PP): The horizontal position of vertical phantom
80 points in pre-ClearType mode is zero, as shown in the OpenType
83 2013-12-02 Werner Lemberg <wl@gnu.org>
85 [truetype] Fix change from 2013-11-20.
87 Problem reported by Akira Kakuto <kakuto@fuk.kindai.ac.jp>.
89 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Protect call to
90 `Update_Max' with both a TT_USE_BYTECODE_INTERPRETER guard and a
92 Also remove redundant check using `maxSizeOfInstructions' – in
93 simple glyphs, the bytecode data comes before the outline data, and
94 a validity test for this is already present.
96 2013-11-27 Werner Lemberg <wl@gnu.org>
98 [autofit] Fix use of dumping functions in `ftgrid' demo program.
100 * src/autofit/afhints.c (AF_DUMP) [FT_DEBUG_AUTOFIT]: New macro.
101 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
102 af_glyph_hints_dump_edges) [FT_DEBUG_AUTOFIT]: Add parameter to
103 handle output to stdout.
105 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
106 af_glyph_hints_dump_edges) [!FT_DEBUG_AUTOFIT]: Removed.
108 2013-11-25 Werner Lemberg <wl@gnu.org>
110 * Version 2.5.1 released.
111 =========================
114 Tag sources with `VER-2-5-1'.
116 * docs/VERSION.DLL: Update documentation and bump version number to
119 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
120 builds/windows/vc2005/index.html,
121 builds/windows/vc2008/freetype.vcproj,
122 builds/windows/vc2008/index.html,
123 builds/windows/vc2010/freetype.vcxproj,
124 builds/windows/vc2010/index.html,
125 builds/windows/visualc/freetype.dsp,
126 builds/windows/visualc/freetype.vcproj,
127 builds/windows/visualc/index.html,
128 builds/windows/visualce/freetype.dsp,
129 builds/windows/visualce/freetype.vcproj,
130 builds/windows/visualce/index.html,
131 builds/wince/vc2005-ce/freetype.vcproj,
132 builds/wince/vc2005-ce/index.html,
133 builds/wince/vc2008-ce/freetype.vcproj,
134 builds/wince/vc2008-ce/index.html: s/2.5.0/2.5.1/, s/250/251/.
136 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
138 * builds/unix/configure.raw (version_info): Set to 17:0:11.
139 * CMakeLists.txt (VERSION_PATCH): Set to 2.
140 * docs/CHANGES, docs/release: Updated.
142 2013-11-23 Werner Lemberg <wl@gnu.org>
144 [truetype]: Add tricky font names `hkscsiic.ttf' and `iicore.ttf'.
146 * src/truetype/ttobjs.c (TRICK_NAMES_MAX_CHARACTERS,
147 TRICK_NAMES_COUNT): Updated.
148 (trick_names): Add family name for the two fonts.
150 2013-11-23 Werner Lemberg <wl@gnu.org>
152 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Typo.
154 2013-11-21 Werner Lemberg <wl@gnu.org>
158 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
160 * src/sfnt/sfobjs.c (sfnt_load_face): Return correct `bsize->width'
161 value if the font lacks an `OS/2' table.
163 2013-11-21 Werner Lemberg <wl@gnu.org>
165 [sfnt] Improve handling of buggy embedded bitmap strikes.
167 We are now able to successfully load `AppleMyoungJo.ttf'.
168 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
170 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Don't trust glyph
173 2013-11-20 Werner Lemberg <wl@gnu.org>
175 [truetype] Don't trust `maxp's `maxSizeOfInstructions'.
177 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>; see
179 http://lists.nongnu.org/archive/html/freetype-devel/2013-08/msg00005.html
183 * src/base/ftobjs.c (FT_Load_Glyph): Check size of `fpgm' and `prep'
184 tables also for setting `autohint'.
186 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Use code from
187 `TT_Process_Composite_Glyph' for handling unreliable values of
188 `maxSizeOfInstructions'.
190 2013-11-16 Werner Lemberg <wl@gnu.org>
192 [sfnt] Fix `OS/2' table version 5 support.
194 We now follow the `official' announcement from Microsoft (on the
195 OpenType mailing list, which unfortunately hasn't a public archive).
197 * include/freetype/tttables.h (TT_OS2):
198 s/usLowerPointSize/usLowerOpticalPointSize/,
199 s/usUpperPointSize/usUpperOpticalPointSize/.
201 * src/sfnt/ttload.c (tt_face_load_os2): Update, and set correct
204 2013-11-13 Werner Lemberg <wl@gnu.org>
206 * builds/unix/ft2unix.h: Remove. No longer necessary.
208 * builds/unix/install.mk (install): Updated.
210 2013-11-13 Werner Lemberg <wl@gnu.org>
212 Simplify header file hierarchy.
214 This large patch changes the header file directory layout from
215 `include/freetype/...' to `include/...', effectively removing one
216 level. Since the file `ft2build.h' is also located in `include'
217 (and it stays there even after installation), all FreeType header
218 files are now in a single directory.
220 Applications that use (a) `freetype-config' or FreeType's
221 `pkg-config' file to get the include directory for the compiler, and
222 (b) the documented way for header inclusion like
224 #include <ft2build.h>
225 #include FT_FREETYPE_H
228 don't need any change to the source code.
230 * include/freetype/*: Move up to...
231 * include/*: ... this directory.
233 * builds/amiga/include/freetype/*: Move up to...
234 * builds/amiga/include/*: ... this directory.
236 */*: Essentially do `s@/freetype/@/@' where appropriate.
238 * CMakeList.txt: Simplify.
239 * builds/unix/freetype-config.in, builds/unix/freetype2.in: For
240 `--cflags', return a single directory.
241 * builds/unix/install.mk (install): No longer try to remove `cache'
242 and `internal' subdirectories; instead, remove the `freetype'
245 2013-11-12 Werner Lemberg <wl@gnu.org>
247 [truetype] Fix last `truetype' commit.
249 * src/truetype/ttgload.c (tt_get_metrics): Preserve stream position.
251 (load_truetype_glyph): Updated.
253 2013-11-10 Werner Lemberg <wl@gnu.org>
255 * docs/CMAKE: New dummy file.
257 2013-11-08 Dave Arnold <darnold@adobe.com>
259 [cff] Fix for hints that touch.
261 * src/cff/cf2hints.c (cf2_hintmap_insertHint): Fix condition for
262 finding index value of insertion point.
264 2013-11-06 Werner Lemberg <wl@gnu.org>
266 [truetype] Fix handling of phantom points in composite glyphs.
267 Problem reported by Nigel Tao <nigeltao@golang.org>.
269 This is a follow-up commit to the previous one.
271 * src/truetype/ttgload.c (load_truetype_glyph): Call
272 `tt_get_metrics' after loading the glyph header.
274 2013-11-06 Werner Lemberg <wl@gnu.org>
276 [truetype] Improve emulation of vertical metrics.
278 This commit also improves the start values of vertical phantom
279 points. Kudos to Greg Hitchcock for help.
281 * src/truetype/ttgload.c (TT_Get_VMetrics): Add parameter to pass
282 `yMax' value. Replace code with fixed Microsoft definition.
283 (tt_get_metrics): Updated.
284 (TT_LOADER_SET_PP): Add explanation how to initialize phantom
285 points, taken from both the OpenType specification and private
286 communication with Greg (which will eventually be added to the
288 Fix horizontal position of `pp3' and `pp4'.
290 * src/truetype/ttgload.h: Updated.
292 * src/truetype/ttdriver.c (tt_get_advances): Updated.
294 * docs/CHANGES: Updated.
296 2013-11-05 Werner Lemberg <wl@gnu.org>
298 * builds/windows/vc2010/freetype.vcxproj: s/v110/v100/.
299 PlatformToolSet version 110 is for VC2012.
301 Problem reported (with solution) by Dave Arnold <darnold@adobe.com>.
303 2013-11-05 Werner Lemberg <wl@gnu.org>
305 [truetype] Correctly reset point tags for glyph components.
306 Problem reported by Nigel Tao <nigeltao@golang.org>.
308 * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Fix loop.
310 2013-11-02 Werner Lemberg <wl@gnu.org>
312 [truetype] Fix GETINFO opcode handling of subpixel hinting bits.
314 * src/truetype/ttinterp.c (Ins_GETINFO): Don't request bit 6 set to
315 get info on subpixel hinting.
317 * docs/CHANGES: Updated.
319 2013-11-02 Werner Lemberg <wl@gnu.org>
321 Fix Savannah bug #40451.
323 Simply apply the patch from the bug report.
325 * builds/unix/ftconfig.in, builds/vms/ftconfig.h,
326 include/freetype/config/ftconfig.h: The used #pragma directives only
327 work with gcc versions 4.6 and higher.
329 2013-11-01 Werner Lemberg <wl@gnu.org>
331 * docs/CHANGES: Updated.
333 2013-11-01 Werner Lemberg <wl@gnu.org>
335 [truetype] Minor code refactoring.
337 Two benefits: The allocated FDEF (and IDEF) array gets slightly
338 smaller, and the `ttdebug' demo program has access to function
339 numbers without additional costs.
341 Fortunately, no changes to FontForge are necessary – this is the
342 only external TrueType debugger I know of, but others may exist and
343 should check the code accordingly.
345 * src/truetype/ttinterp.h (TT_CallRec): Replace `Cur_Restart' and
346 `Cur_End' with a pointer to the corresponding `TT_DefRecord'
349 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF, Ins_ENDF,
350 Ins_CALL, Ins_LOOPCALL, Ins_UNKNOWN, TT_RunIns <Invalid_Opcode>):
353 2013-10-27 Werner Lemberg <wl@gnu.org>
355 [sfnt] Implement support for `OS/2' table version 5.
359 http://typedrawers.com/discussion/470/new-microsoft-size-specific-design-selection-mechanism
361 for the announcement.
363 * include/freetype/tttables.h (TT_OS2): Add fields
364 `usLowerPointSize' and `usUpperPointSize'. Since FreeType returns
365 this structure only as a pointer through `FT_Get_Sfnt_Table', there
366 shouldn't be any ABI problems.
368 * src/sfnt/ttload.c (tt_face_load_os2): Implement it.
370 * docs/CHANGES: Updated.
372 2013-10-24 Werner Lemberg <wl@gnu.org>
374 * README.git, docs/CHANGES, docs/INSTALL: Updated.
376 2013-10-24 John Cary <cary@txcorp.com>
378 Provide cmake support.
380 * CMakeLists.txt: New file.
382 2013-10-23 Kenneth Miller <kennethadammiller@yahoo.com>
383 Werner Lemberg <wl@gnu.org>
385 Provide support for x64 builds in Visual C++ project files.
387 * src/builds/win32: Renamed to...
388 * src/builds/windows: This.
390 * src/builds/windows/vc2010/*: Updated to handle x64 target.
392 * src/builds/windows/*.mk, docs/INSTALL.GNU: s/win32/windows/ where
395 2013-10-22 Werner Lemberg <wl@gnu.org>
397 * src/base/md5.c, src/base/md5.h: Updated to recent version.
399 * src/base/ftobjs.c: Updated; `md5.c' no longer uses `free'.
401 The canonical URL to get updates for this file is
403 http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/popa3d/popa3d/md5/
405 as the author told me in private communication.
407 2013-10-19 Werner Lemberg <wl@gnu.org>
409 [autofit] s/SMALL_TOP/X_HEIGHT/.
411 * src/autofit/afblue.dat: Updated.
413 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
415 * src/autofit/aflatin.c, src/autofit/aflatin.h,
416 src/autofit/atlatin2.c: Updated.
418 2013-10-19 Werner Lemberg <wl@gnu.org>
420 * src/autofit/afblue.dat: s/MINOR/DESCENDER/.
422 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
424 2013-10-16 Werner Lemberg <wl@gnu.org>
426 [autofit] Add description strings to script entries.
428 Currently, this is unused.
430 * src/autofit/afscript.h: Do it.
431 * src/autofit/afglobal.c, src/autofit/afpic.c,
432 src/autofit/aftypes.h: Updated.
434 2013-10-16 Werner Lemberg <wl@gnu.org>
436 [autofit] Improve tracing message for extra light flag.
438 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Do it.
440 2013-10-15 Chongyu Zhu <lembacon@gmail.com>
442 [arm] Fix thumb2 inline assembly under LLVM.
444 When using `ADD' with an immediate operand, the instruction is
445 actually `ADD Rd, Rn, #<imm12>', that is, the maximum of the
446 immediate operand cannot exceed 4095. It will fail to compile with
449 However, in GCC, due to some legacy compatibility considerations,
450 `ADD.W' will be automatically emitted when the immediate operand is
453 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
454 (FT_MulFix_arm) [__GNUC__]: Support clang compiler.
456 * src/truetype/ttinterp.c (TT_MulFix14_arm) [__GNUC__]: Ditto.
458 2013-10-12 Werner Lemberg <wl@gnu.org>
460 [autofit] Improve tracing of `latin' hinter.
462 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Report blue
464 (af_latin_metrics_scale_dim): Report scaling changes due to x height
466 Report scaled stroke width and blue zone values.
468 2013-10-03 Dave Arnold <darnold@adobe.com>
470 * src/cff/cf2font.c (cf2_computeDarkening): Avoid division by zero.
472 Note that the old code avoided using a region of the piecewise
473 linear function where the slope was zero. The recovery was to use a
474 different section of the function, which produced a different,
475 incorrect amount of darkening.
477 2013-10-02 Darrell Bellert <darrell.bellert@hl.konicaminolta.us>
479 * src/sfnt/ttload.c (tt_face_load_pclt): Fix `pclt_fields'.
481 2013-10-02 Dave Arnold <darnold@adobe.com>
483 * src/cff/cf2font.c (cf2_computeDarkening): Initialize darkenAmount.
485 This line was lost in commit 89ca1fd6 (from 2013-06-25). The effect
486 is to use a previous darkening amount when producing an unhinted,
487 unscaled outline. This can cause autohint samples in ftgrid and
488 ftview to be based on darkened CFF outlines instead of unhinted,
491 2013-09-29 Dave Arnold <darnold@adobe.com>
493 Fix Savannah bug #39295.
495 The bug was caused by switching to the initial hintmap (the one in
496 effect when `moveto' executes) just before drawing the final element
497 in the charstring. This ensured that the path was closed (in both
498 Character Space and Device Space). But if the final element was a
499 curve and if the final hintmap was different enough from the initial
500 one, then the curve was visibly distorted.
502 The first part of the fix is to draw the final curve using the final
503 hintmap as specified by the charstring. This corrects the
504 distortion but does not ensure closing in Device Space. It may
505 require the rasterizer to automatically generate an extra closing
506 line. Depending on the hintmap differences, this line could be from
507 zero to a couple pixels in length.
509 The second part of the fix covers the case where the charstring
510 subpath is closed with an explicit line. We now modify that line's
511 end point to avoid the distortion.
513 Some glyphs in the bug report font (TexGyreHeros-Regular) that show
520 Curves at the *end* of a subpath are no longer distorted. However,
521 some of these glyphs have bad hint substitutions in the middle of a
522 subpath, and these are not affected.
524 The patch has been tested with a set of 106 fonts that shipped with
525 Adobe Creative Suite 4, together with 756 Open Source CFF fonts from
526 Google Fonts. There are 1.5 million glyphs, of which some 20k are
527 changed with the fix. A sampling of a few hundred of these changes
528 have been examined more closely, and the changes look good (or at
531 * src/cff/cf2hints.h (CF2_GlyphPathRec): New element `pathIsClosing'
532 to indicate that we synthesize a closepath line.
534 * src/cff/cf2hints.c (cf2_glyphpath_init): Updated.
535 (cf2_glyphpath_pushPrevElem): If closing, use first hint map (for
536 `lineto' operator) and adjust hint zone.
537 For synthesized closing lines, use end point in first hint zone.
538 (cf2_glyphpath_lineTo): Take care of synthesized closing lines. In
539 particular, shift the detection of zero-length lines from character
540 space to device space.
541 (cf2_glyphpath_closeOpenPath): Remove assertion.
544 2013-09-25 Werner Lemberg <wl@gnu.org>
546 * src/autofit/aflatin.c (af_{grek,cyrl}_uniranges): Fix arrays.
548 2013-09-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
550 [bdf, pcf] Refuse non-zero face_index.
552 Suggested by Akira Tagoh, see
554 http://lists.gnu.org/archive/html/freetype/2013-09/msg00030.html
556 * src/bdf/bdfdrivr.c (BDF_Face_Init): Return `Invalid_Argument'
557 error if the font could be opened but non-zero `face_index' is
559 * src/pcf/pcfdrivr.c (PCF_Face_Init): Ditto.
561 * src/type42/t42objs.c (T42_Face_Init): Remove unrequired FT_UNUSED
562 macro for `face_index' because it is validated later.
564 2013-09-23 Werner Lemberg <wl@gnu.org>
566 Fix Savannah bug #40090.
568 * src/autofit/afcjk.c (af_cjk_metrics_scale): Revert commit
569 306f8c5d (from 2013-08-25) affecting this function.
571 2013-09-22 Werner Lemberg <wl@gnu.org>
573 [autofit] Disunify Cyrillic and Greek handling from Latin.
575 * src/autofit/afscript.h: Add Cyrillic and Greek.
577 * src/autofit/afblue.dat (AF_BLUE_STRINGSET_GREK,
578 AF_BLUE_STRINGSET_CYRL): Add blue zones for Greek and Cyrillic.
579 (AF_BLUE_STRINGSET_LATN): Fix typo.
580 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
582 * src/autofit/aflatin.c (af_grek_uniranges, af_cyrl_uniranges): New
584 (af_grek_script_class, af_cyrl_script_class): New scripts.
585 * src/autofit/aflatin.h: Updated.
587 2013-09-20 Werner Lemberg <wl@gnu.org>
589 * docs/CHANGES: Updated.
591 2013-09-20 Behdad Esfahbod <behdad@behdad.org>
593 Fix vertical size of emboldened glyphs.
595 Cf. https://bugzilla.gnome.org/show_bug.cgi?id=686709
597 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Adjust `horiBearingY'
600 2013-09-11 Alexei Podtelezhnikov <apodtele@gmail.com>
602 * include/freetype/ftoutln.h: Correct FT_Outline_Get_Orientation
603 algorithm description.
605 2013-09-11 Werner Lemberg <wl@gnu.org>
607 [autofit] Improve Hebrew rendering.
609 This change introduces a new blue zone property
610 `AF_BLUE_PROPERTY_LATIN_LONG' to make the auto-hinter ignore short
613 * src/autofit/afblue.dat: Fix Hebrew blue strings.
614 Use AF_BLUE_PROPERTY_LATIN_LONG for AF_BLUE_STRING_HEBREW_TOP.
616 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_LONG): New macro.
618 * src/autofit/afblue.c, src/autofit/afblue.h: Updated.
620 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Handle
621 `AF_LATIN_IS_LONG_BLUE'.
623 * src/autofit/aflatin.h (AF_LATIN_IS_LONG_BLUE): New macro.
625 2013-08-28 Behdad Esfahbod <behdad@google.com>
627 [sfnt] Fix frame access while reading WOFF table directory.
629 * src/sfnt/sfobjs.c (woff_open_font): Using single memory frame
630 while reading the directory entries for the whole loop.
632 2013-08-29 Werner Lemberg <wl@gnu.org>
633 Behdad Esfahbod <behdad@google.com>
635 Implement support for WOFF containers.
637 We simply synthesize a SFNT from the WOFF, create a memory stream
638 for the new data, and load the SFNT as usual.
640 Does NOT add any API to access WOFF metadata or private blocks.
642 * include/freetype/internal/tttypes.h (WOFF_HeaderRec,
643 WOFF_TableRec): New structures.
645 * include/freetype/tttags.h (TTAG_wOFF): New macro.
647 * src/base/ftobjs.c (FT_Open_Face): Set `stream' after calling
650 * src/sfnt/sfobjs.c [FT_CONFIG_OPTION_SYSTEM_ZLIB]: Include
652 (WRITE_BYTE, WRITE_USHORT, WRITE_ULONG): New temporary macros for
654 (sfnt_stream_close, compare_offsets, woff_open_font): New functions.
655 (sfnt_open_font): Handle `TTAG_wOFF'.
656 (sfnt_init_face): Set `stream' after calling `sfnt_open_font'.
658 * src/truetype/ttobjs.c (tt_face_init): Set `stream' after calling
661 * src/base/ftobjs.c (open_face): Use a pointer to FT_Stream as an
662 argument so that a changed stream survives.
665 2013-08-28 Werner Lemberg <wl@gnu.org>
667 [gzip] New function `FT_Gzip_Uncompress'.
669 This is modeled after zlib's `uncompress' function. We need this
672 * include/freetype/ftgzip.h, src/gzip/ftgzip.c (FT_Gzip_Uncompress):
675 * src/gzip/rules.mk: Rewrite to better reflect dependencies.
677 2013-08-28 Werner Lemberg <wl@gnu.org>
679 [autofit] Fix `make multi' compilation.
681 * src/autofit/afblue.cin, src/autofit/afblue.c: Don't include
682 `afblue.h' but `aftypes.h'.
683 * src/autofit/afcjk.c: Don't include `aftypes.h' but `afglobal.h'.
685 2013-08-28 Werner Lemberg <wl@gnu.org>
687 [autofit] Fix C++ compilation.
689 * src/autofit/afglobal.c (af_face_globals_get_metrics),
690 src/autofit/afdummy.c (af_dflt_script_class), src/autofit/afindic.c
691 (af_deva_script_class): Use proper casts.
693 2013-08-27 Behdad Esfahbod <behdad@google.com>
695 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix sign typos.
697 2013-08-27 Behdad Esfahbod <behdad@google.com>
699 FT_Open_Face: Improve external stream handling.
701 If the font's `clazz->init_face' function wants to swap to new
702 stream, handling of whether original stream was external could
703 result to either memory leak or double free. Mark externality into
704 face flags before calling `init_face' such that the clazz can handle
705 external streams properly.
707 * src/base/ftobjs.c (FT_Open_Face): Move code to set
708 FT_FACE_FLAG_EXTERNAL_STREAM to...
709 (open_face): This function.
711 2013-08-27 Werner Lemberg <wl@gnu.org>
713 Remove `FT_SqrtFixed' function.
717 * include/freetype/internal/ftcalc.h, src/base/ftcalc.c: Do it.
719 2013-08-27 Werner Lemberg <wl@gnu.org>
721 [autofit] While tracing, report script names instead of ID values.
723 * src/autofit/afglobal.c (af_script_names) [FT_DEBUG_LEVEL_TRACE]:
725 * src/autofit/afglobal.h: Updated.
727 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
728 af_cjk_hint_edges): Use `af_script_names'.
729 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
730 af_latin_hint_edges): Ditto.
732 2013-08-26 Werner Lemberg <wl@gnu.org>
734 [autofit] Report used script while hinting a glyph.
736 * src/autofit/afcjk.c (af_cjk_hint_edges), src/autofit/aflatin.c
737 (af_latin_hint_edges): Implement it.
739 2013-08-26 Werner Lemberg <wl@gnu.org>
741 [autofit] Add support for Hebrew script.
743 * src/autofit/afblue.dat: Add blue strings for Hebrew.
744 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
746 * src/autofit/aflatin.c (af_hebr_uniranges): New array.
747 (af_hebr_script_class): New script.
748 * src/autofit/aflatin.h, src/autofit/afscript.h: Updated.
750 2013-08-26 Werner Lemberg <wl@gnu.org>
752 [autofit] Improve tracing messages.
754 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Mention script
755 ID in tracing message.
756 (af_cjk_metrics_init_blues): Initialize `axis' outside of the inner
758 Improve tracing messages.
759 (af_cjk_hint_edges) [FT_DEBUG_LEVEL_TRACE]: New variable
760 `num_actions' to count hinting actions.
761 Improve tracing messages.
763 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Mention
764 script ID in tracing message.
765 (af_latin_metrics_init_blues, af_latin_hint_edges): Improve tracing
768 2013-08-26 Werner Lemberg <wl@gnu.org>
770 Better tracing of loaded glyphs.
772 Previously, the loading of a glyph was traced at level 4, if at all.
773 With this change, all font loading routines emit a tracing message
774 at level 1, making it easier to select tracing output (for example
775 using F2_DEBUG="any:1 afhints:7 aflatin:7").
777 * src/bdf/bdfdrivr.c (BDF_Glyph_Load): Add tracing message.
778 * src/cff/cffdrivr.c (cff_glyph_load): Ditto.
779 * src/cff/cffgload.c (cff_decoder_prepare): Improve tracing
781 * src/cid/cidgload.c (cid_load_glyph): Use level 1 for tracing
783 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Ditto.
784 * src/pfr/pfrobjs.c (pfr_slot_load): Add tracing message.
785 * src/truetype/ttgload.c (TT_Load_Glyph): Ditto.
786 * src/type1/t1gload.c (T1_Load_Glyph): Ditto.
787 * src/type42/t42objs.c (T42_GlyphSlot_Load): Ditto.
788 * src/winfonts/winfnt.c (FNT_Load_Glyph): Ditto.
790 2013-08-26 Werner Lemberg <wl@gnu.org>
792 [autofit] Fix script selection.
794 * src/autofit/afglobal.c (af_face_globals_get_metrics): Use
795 `AF_SCRIPT_DFLT', not value 0.
798 * src/autofit/afscript.h: Sort by script name.
800 2013-08-26 Werner Lemberg <wl@gnu.org>
802 [autofit] Make `dummy' hinter work as expected.
804 * src/autofit/afdummy.c (af_dummy_hints_init): Properly set scaling
806 (af_dummy_hints_apply): Scale the glyphs.
808 2013-08-25 Werner Lemberg <wl@gnu.org>
810 [autofit] Make `cjk' module use blue stringsets.
812 * src/autofit/afcjk.c (AF_CJK_MAX_TEST_CHARACTERS): Removed.
813 (af_cjk_hani_blue_chars): Removed.
814 (AF_CJK_BLUE_TYPE_*): Removed.
815 (af_cjk_metrics_init_blues): Replace AF_CJK_MAX_TEST_CHARACTERS with
816 AF_BLUE_STRING_MAX_LEN.
817 Change loops to use offsets (in file `afblue.h') into the new arrays
818 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
819 Instead of three dimensions (as used in the old blue string array)
820 we now use properties to do the same, saving one loop nesting level.
822 * src/autofit/afcjk.h: Remove old enumeration values superseded by
823 the new data in `afblue.h'.
824 (AF_CJK_IS_TOP_BLUE, AF_CJK_IS_HORIZ_BLUE, AF_CJK_IS_FILLED_BLUE,
825 AF_CJK_IS_RIGHT_BLUE): New macros, to be used in
826 `af_cjk_metrics_init_blues'.
827 (AF_CJK_BLUE_IS_RIGHT): Remove this now redundant enum value.
828 (AF_CJK_BLUE_IS_TOP): Renamed to...
829 (AF_CJK_BLUE_TOP): This.
830 (AF_CJK_MAX_BLUES): Remove.
831 (AF_CJKAxisRec): Updated.
833 2013-08-25 Werner Lemberg <wl@gnu.org>
837 * src/autofit/afblue.hin, src/autofit/afblue.c (GET_UTF8_CHAR): Use
840 2013-08-25 Werner Lemberg <wl@gnu.org>
842 [autofit] Synchronize `cjk' with `latin' module (and vice versa).
844 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Add tracing
846 (af_cjk_metrics_init_blues): Don't pass blue string array as
847 argument but use the global array directly.
848 Use `outline' directly.
849 Update and add tracing messages.
850 (af_cjk_metrics_init): Simplify code.
851 (af_cjk_metrics_scale_dim): Improve tracing message.
852 (af_cjk_metrics_scale): Synchronize.
854 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
855 af_latin_metrics_init_blues): Improve and add tracing messages.
857 2013-08-25 Werner Lemberg <wl@gnu.org>
859 [autofit] Make `latin' module use blue stringsets.
861 * src/autofit/aflatin.c (AF_LATIN_MAX_TEST_CHARACTERS): Removed.
862 (af_latin_blue_chars): Removed.
863 (af_latin_metrics_init_blues): Replace AF_LATIN_MAX_TEST_CHARACTERS
864 with AF_BLUE_STRING_MAX_LEN.
865 Change loops to use offsets (in file `afblue.h') into the new arrays
866 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
867 Use `AF_LATIN_IS_SMALL_TOP_BLUE' macro.
869 * src/autofit/aflatin.h: Remove old enumeration values superseded by
870 the new data in `afblue.h'.
871 (AF_LATIN_IS_TOP_BLUE): Updated definition.
872 (AF_LATIN_IS_SMALL_TOP_BLUE): New macro.
873 (AF_LATIN_MAX_BLUES): Remove.
874 (AF_LatinAxisRec): Updated.
876 2013-08-25 Werner Lemberg <wl@gnu.org>
878 [autofit] Add blue stringsets.
880 * src/autofit/aftypes.h: Include `afblue.h'.
881 (AF_ScriptClassRec): Add `blue_stringset' field.
882 (AF_DEFINE_SCRIPT_CLASS): Updated.
884 * src/autofit/autofit.c: Include `afblue.c'.
886 * src/autofit/afcjk.c (af_hani_script_class), src/autofit/afdummy.c
887 (af_dflt_script_class), src/autofit/afindic.c
888 (af_deva_script_class), src/autofit/aflatin.c
889 (af_latn_script_class), src/autofit/aflatin2.c
890 (af_ltn2_script_class): Updated.
892 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afblue.c'.
894 2013-08-25 Werner Lemberg <wl@gnu.org>
896 [autofit] Introduce data file for blue strings.
898 The idea is to have a central file which gets processed by a Perl
899 script to create proper `.c' and `.h' files using templates. There
900 are two other reasons to do that:
902 . The data file should be easily readable. We use UTF-8 encoding
903 which then gets converted to single bytes.
905 . Since the number of supported scripts will increase soon, the
906 current usage of blue string arrays is a waste of space. Using
907 the Perl script it is possible to imitate jagged arrays,
908 defining enumeration constants as offsets into the arrays.
910 This commit only adds files without changing any functionality.
912 * src/autofit/afblue.dat: New data file.
913 * src/tools/afblue.pl: New Perl script for processing `afblue.dat'.
915 * src/autofit/afblue.cin, src/autofit/afblue.hin: New template files
917 * src/autofit/afblue.c, src/autofit/afblue.c: New source files.
918 To avoid a dependency on Perl, we add them too.
920 2013-08-19 Alexei Podtelezhnikov <apodtele@gmail.com>
922 [base] Enable new algorithm for `BBox_Cubic_Check'.
924 * src/base/ftbbox.c: Enable new BBox_Cubic_Check algorithm, remove
928 2013-08-18 Werner Lemberg <wl@gnu.org>
930 * builds/unix/unix-def.in (freetype2.pc): Don't set executable bit.
932 2013-08-18 Werner Lemberg <wl@gnu.org>
934 Fix Savannah bug #39804.
936 * builds/unix/configure.raw (LIBPNG): Define and export.
937 * builds/unix/freetype-config.in, builds/unix/freetype2.in: Handle
940 2013-08-17 Alexei Podtelezhnikov <apodtele@gmail.com>
942 [base] Clean up BBox_Conic_Check.
944 * src/base/ftbbox.c (BBox_Conic_Check): Remove redundant checks for
945 extremum at the segment ends, which are already within the bbox.
946 Slightly modify calculations.
948 2013-08-15 Alexei Podtelezhnikov <apodtele@gmail.com>
950 [base] Finish experimental (disabled) BBox_Cubic_Check implementation.
952 * src/base/ftbbox.c (BBox_Cubic_Check): Scale arguments to improve
953 accuracy and avoid overflows.
955 2013-08-13 Alexei Podtelezhnikov <apodtele@gmail.com>
957 [base] Refactor experimental (disabled) BBox_Cubic_Check.
959 * src/base/ftbbox.c (BBox_Cubic_Check): Implement the minimum search
960 as the mirror image of the maximum search implemented here...
961 (update_max): New function.
963 2013-08-06 John Tytgat <John.Tytgat@esko.com>
965 Fix Savannah bug #39702.
967 * src/cff/cffload.c (cff_index_get_pointers): Check for `cur_offset
968 != 0'; this stronger test is mandated by the CFF specification.
969 Fix test for INDEX structures which have one or more empty entries
972 2013-08-05 Werner Lemberg <wl@gnu.org>
974 Fix gcc pragmas, part 2.
976 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
977 TT_DotFix14_long_long): `#pragma gcc diagnostic {push,pop}' has been
978 introduced with gcc version 4.6.
980 2013-08-05 Werner Lemberg <wl@gnu.org>
984 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
985 TT_DotFix14_long_long): Older gcc versions don't accept diagnostic
986 pragmas within a function body.
988 2013-08-05 Werner Lemberg <wl@gnu.org>
990 Fix Savannah bug #39700.
992 * builds/unix/ftconfig.h: Synchronize with
993 `include/freetype/config/ftconfig.h'.
995 * builds/vms/ftconfig.h: Ditto.
996 Make the differences to the master `ftconfig.h' file as small as
997 possible for easier maintainance.
999 2013-08-05 Werner Lemberg <wl@gnu.org>
1001 [autofit] Improve handling of `near' points.
1003 Points which are very near to each other are now marked as such.
1004 The `weak' flag is then computed by using the `in' vector of the
1005 first and the `out' vector of the last point of a group of near
1008 For example, this fixes the rendering of glyph `Oslash' in
1011 * src/autofit/afhints.h (AF_Flags): New value `AF_FLAGS_NEAR'.
1013 * src/autofit/afhints.c (af_glyph_hints_reload): Introduce
1014 the heuristic value `near_limit' to decide whether the current point
1015 is near to the previous one, then set `AF_FLAG_NEAR' accordingly.
1016 Store good `in' vector (of last non-near point) in
1017 `last_good_in_{x,y}' and use it as an argument to
1018 `ft_corner_is_flat' if necessary.
1020 2013-08-02 Werner Lemberg <wl@gnu.org>
1022 * include/freetype/ftcffdrv.h: Improve documentation.
1023 This is based on blog entries from David Lemon and Dave Arnold (both
1024 from Adobe) with kind permission. Dave also helped in
1027 2013-08-02 Werner Lemberg <wl@gnu.org>
1029 [autofit] Move declaration of scripts into separate file.
1031 This has the benefit that we don't need to duplicate the data at
1034 * src/autofit/afscript.h: New file.
1036 * src/autofit/aftypes.h (AF_Script): Include `afscript.h' to define
1037 the enumeration values.
1039 * src/autofit/afglobal.c: Include `afscript.h' to get the script
1040 specific header files.
1041 (af_script_classes): Include `afscript.h' to fill this array.
1043 * src/autofit/afpic.c: Include `afscript.h' to get the script
1044 specific header files.
1045 (autofit_module_class_pic_init): Include `afscript.h' for
1047 * src/autofit/afpic.h (AF_SCRIPT_CLASSES_COUNT,
1048 AF_SCRIPT_CLASSES_REC_COUNT): Removed. Use `AF_SCRIPT_MAX' instead.
1050 * src/autofit/rules.mk (AUTOF_DRV_H): Updated.
1052 2013-08-02 Werner Lemberg <wl@gnu.org>
1054 [autofit] Move declaration of writing systems into separate file.
1056 This has the benefit that we don't need to duplicate the data at
1059 * src/autofit/afwrtsys.h: New file.
1061 * src/autofit/aftypes.h (AF_WritingSystem): Include `afwrtsys.h' to
1062 define the enumeration values.
1064 * src/autofit/afglobal.c: Include `afwrtsys.h' to get the writing
1065 system specific header files.
1067 (af_writing_system_classes): Include `afwrtsys.h' to fill this
1070 * src/autofit/afpic.c: Include `afwrtsys.h' to get the writing
1071 system specific header files.
1072 (autofit_module_class_pic_init): Include `afwrtsys.h' for
1074 * src/autofit/afpic.h (AF_WRITING_SYSTEM_CLASSES_COUNT,
1075 AF_WRITING_SYSTEM_CLASSES_REC_COUNT): Removed. Use
1076 `AF_WRITING_SYSTEM_MAX' instead.
1078 2013-08-02 Werner Lemberg <wl@gnu.org>
1080 [sfnt] Fix compilation with g++.
1082 * src/sfnt/pngshim.c (error_callback, read_data_from_FT_stream): Use
1084 (Load_SBit_Png): Pacify compiler.
1086 2013-08-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1087 Werner Lemberg <wl@gnu.org>
1089 [autofit] Fix `make multi'.
1091 * include/freetype/config/ftconfig.h (FT_LOCAL_ARRAY,
1092 FT_LOCAL_ARRAY_DEF): New macros.
1094 * src/autofit/afglobal.c (af_writing_system_classes,
1095 af_script_classes): Use FT_LOCAL_ARRAY_DEF.
1096 * src/autofit/afglobal.h: Declare `af_writing_system_classes' and
1097 `af_script_classes'.
1098 * src/autofit/afloader.c: Include `afpic.h'.
1100 2013-08-01 Werner Lemberg <wl@gnu.org>
1102 Another round of cppcheck nitpicks.
1104 The call was (from the top-level of the FreeType tree):
1109 -I /usr/local/include \
1110 -I /usr/lib/gcc/i586-suse-linux/4.7/include \
1112 -I include/freetype \
1113 -I include/freetype/config \
1114 -I include/freetype/internal \
1115 -DFT2_BUILD_LIBRARY \
1118 using cppcheck git commit f7e93f99.
1120 Note that cppcheck still can't handle `#include FOO' (with `FOO' a
1123 */* Improve variable scopes.
1124 */* Remove redundant initializations which get overwritten.
1126 * src/gxvalid/*: Comment out redundant code or guard it with
1127 FT_DEBUG_LEVEL_TRACE.
1129 2013-07-30 Werner Lemberg <wl@gnu.org>
1131 [autofit] Introduce `writing systems'.
1133 This patch adds a new top level to the auto-hinter's script class
1134 hierarchy. It defines `writing systems' which can contain multiple
1137 For example, the `latin' writing system (in file `aflatin.c') is
1138 able to support scripts like Latin, Cyrillic, Armenian, etc., which
1139 can be handled similarly.
1141 Scripts are now named using four-letter OpenType tags.
1143 * src/autofit/aftypes.h (AF_ScriptClassRec): Move relevant members
1145 (AF_WritingSystemClassRec): This new structure. It holds pointers
1146 to functions which can be shared among related scripts.
1147 (AF_WritingSystem): New enumeration.
1148 (AF_Script): Revised values using four-letter tags.
1149 (AF_DEFINE_WRITING_SYSTEM_CLASS): New macro.
1150 (AF_DEFINE_SCRIPT_CLASS): Updated.
1152 * src/autofit/afglobal.c (af_writing_system_classes): New global,
1154 (af_script_classes): Updated.
1155 (af_face_globals_free): Updated.
1157 (af_face_globals_get_metrics): Updated.
1159 * src/autofit/afglobal.h (AF_SCRIPT_FALLBACK)
1160 [!AF_CONFIG_OPTION_CJK]: Handle this case.
1162 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
1165 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated;
1166 initialize structures for both writing systems and scripts.
1167 * src/autofit/afpic.h: Updated.
1168 (AF_WRITING_SYSTEM_CLASSES_GET): New macro.
1170 * src/autofit/afcjk.c (af_cjk_writing_system_class): New writing
1172 (af_cjk_uniranges): Renamed to...
1173 (af_hani_uniranges): This.
1174 (af_cjk_script_class): Reduced and renamed to...
1175 (af_hani_script_class): This.
1176 * src/autofit/afcjk.h: Updated.
1178 * src/autofit/afdummy.c (af_dummy_writing_system_class): New writing
1180 (af_dummy_script_class): Reduced and renamed to...
1181 (af_dflt_script_class): This.
1182 * src/autofit/afdummy.h: Updated.
1184 * src/autofit/afindic.c (af_indic_writing_system_class): New writing
1186 (af_indic_uniranges): Renamed to...
1187 (af_deva_uniranges): This.
1188 (af_indic_script_class): Reduced and renamed to...
1189 (af_deva_script_class): This.
1190 * src/autofit/afcjk.h: Updated.
1192 * src/autofit/aflatin.c (af_latin_writing_system_class): New writing
1194 (af_latin_uniranges): Renamed to...
1195 (af_latn_uniranges): This.
1196 (af_latin_script_class): Reduced and renamed to...
1197 (af_latn_script_class): This.
1198 * src/autofit/aflatin.h: Updated.
1200 * src/autofit/aflatin2.c (af_latin2_writing_system_class): New
1202 (af_latin2_uniranges): Renamed to...
1203 (af_ltn2_uniranges): This.
1204 Synchronize ranges with `latin'.
1205 (af_latin2_script_class): Reduced and renamed to...
1206 (af_ltn2_script_class): This.
1207 * src/autofit/aflatin2.h: Updated.
1209 2013-07-30 Werner Lemberg <wl@gnu.org>
1211 [autofit] Variable renaming.
1213 * src/autofit/aftypes.h (AF_ScriptMetricsRec):
1214 s/clazz/script_class/.
1217 2013-07-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1219 Ignore libpng-config under cross-building configuration,
1220 because it will return the flags for the hosting environment.
1222 * builds/unix/configure.raw: Ignore libpng-config when
1223 `cross_compiling' == yes.
1225 2013-07-30 Behdad Esfahbod <behdad@google.com>
1227 Prevent division by zero by a transparent color.
1229 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra):
1230 Return 0 immediately, when alpha channel is zero.
1232 2013-07-25 Behdad Esfahbod <behdad@google.com>
1234 Add FT_FACE_FLAG_COLOR and FT_HAS_COLOR.
1236 Also disambiguate Google's color bitmap tables.
1238 * include/freetype/freetype.h (FT_FACE_FLAG_COLOR, FT_HAS_COLOR):
1241 * include/freetype/internal/tttypes.h (TT_SbitTableType): Add
1242 TT_SBIT_TABLE_TYPE_CBLC.
1244 * src/sfnt/sfobjs.c (sfnt_load_face): Handle FT_FACE_FLAG_COLOR.
1246 * src/sfnt/ttsbit.c (tt_face_load_sbit,
1247 tt_face_load_strike_metrics, tt_face_load_sbit_image): Handle
1248 TT_SBIT_TABLE_TYPE_CBLC.
1250 2013-07-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1252 [sfnt] Fix for `make multi' target.
1254 * src/sfnt/pngshim.c (Load_SBit_Png): Use FT_LOCAL_DEF().
1256 2013-07-20 Werner Lemberg <wl@gnu.org>
1258 * docs/INSTALL.GNU: Updated.
1260 2013-07-20 Behdad Esfahbod <behdad@google.com>
1262 [sfnt] Fix `sbix' table version handling.
1264 * src/sfnt/ttsbit.c (tt_face_load_sbit) [TT_SBIT_TABLE_TYPE_SBIX]:
1265 USHORT version numbers are to be considered as `minor'.
1267 2013-07-19 Werner Lemberg <wl@gnu.org>
1269 [autofit] Fix segment classification for blue zones.
1271 The old code (essentially unchanged since the very beginning)
1272 incorrectly handled this configuration
1288 as round. (`o' and `x' are on and off points, respectively).
1290 This is a major change which should improve the rendering results
1291 enormously for many TrueType fonts, especially in the range approx.
1292 20-40ppem, fixing the appearance of many overshoots.
1294 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Look at the
1295 first and last points of the segment, not the points right before
1298 2013-07-19 Behdad Esfahbod <behdad@google.com>
1300 [sfnt] `sbix' fix-ups.
1302 * src/sfnt/sfobjs.c (sfnt_load_face): Apple's `sbix' color bitmaps
1303 are rendered scaled and then the `glyf' outline rendered on top. We
1304 don't support that yet, so just ignore the `glyf' outline and
1305 advertise it as a bitmap-only font.
1307 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
1308 [TT_SBIT_TABLE_TYPE_SBIX]: Return metrics in 26.6 units.
1309 (tt_face_load_sbix_image): Typo.
1311 2013-07-18 Behdad Esfahbod <behdad@google.com>
1313 [sfnt] Add support for Apple's `sbix' color bitmap table.
1315 * include/freetype/internal/tttypes.h (TT_SBit_MetricsRec): Widen
1316 fields to FT_Short and FT_UShort, respectively.
1317 (TT_SBitTableType): New enumeration.
1318 (TT_FaceRec): Add `sbit_table_type' field.
1320 * include/freetype/tttags.h (TTAG_sbix): New macro.
1322 * src/sfnt/pngshim.c (Load_SBit_Png): Pass a more generic
1323 FT_GlyphSlot argument instead FT_Bitmap.
1324 Add flag to control map and metrics handling.
1327 * src/sfnt/ttsbit.c: Include `ttmtx.h'.
1328 (tt_face_load_eblc): Renamed to...
1329 (tt_face_load_sbit): This.
1330 Handlic `sbix' bitmaps.
1331 (tt_face_free_eblc): Renamed to...
1332 (tt_face_load_sbit): This.
1334 (tt_face_load_strike_metrics): Handle `sbix' bitmaps.
1335 (tt_face_load_sbix_image): New function.
1336 (tt_sbit_decoder_alloc_bitmap, tt_sbit_decoder_load_image,
1337 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
1338 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
1339 tt_sbit_decoder_load_image, tt_sbit_decoder_load_bitmap): Don't pass
1340 and handle load flags.
1341 (tt_sbit_decoder_load_bitmap) [!FT_CONFIG_OPTION_USE_PNG]: Better
1342 handle formats 17-19.
1343 Move color to grayscale conversion to...
1344 (tt_face_load_sbit_image): Here.
1345 Handle `sbix' bitmaps.
1347 * src/sfnt/pngshim.h: Updated.
1348 * src/sfnt/ttsbit.h: Updated.
1349 * src/sfnt/sfdriver.c: Updated.
1351 2013-07-18 Werner Lemberg <wl@gnu.org>
1353 [sfnt] Ignore invalid magic number in `head' or `bhed'.
1355 Other font engines seem to ignore it also. Problem reported by
1356 Hin-Tak Leung <htl10@users.sourceforge.net>.
1358 * src/sfnt/ttload.c (check_table_dir): Don't abort but warn only if
1359 we have an invalid magic number.
1361 2013-07-16 Werner Lemberg <wl@gnu.org>
1363 [smooth] Fix segfault caused by previous commit.
1365 * src/smooth/ftgrays.c (gray_set_cell): Always compute
1368 2013-07-16 David Turner <digit@google.com>
1370 [smooth] Improve performance.
1372 Provide a work-around for an ARM-specific performance bug in GCC.
1373 This speeds up the rasterizer by more than 5%.
1375 Also slightly optimize `set_gray_cell' and `gray_record_cell' (which
1376 also improves performance on other platforms by a tiny bit (<1%).
1378 * src/smooth/ftgrays.c (FT_DIV_MOD): New macro.
1379 Use it where appropriate.
1381 (gray_record_cell, gray_set_cell, gray_move_to,
1382 gray_convert_glyph_inner): Streamline condition handling.
1384 2013-07-16 David Turner <digit@google.com>
1386 [truetype] Add assembler code for TT_MulFix14 and TT_DotFix14.
1388 This patch provides slightly optimized versions for ARM, x86, and
1389 x86_64 CPUs if built with GCC.
1391 Also remove some dead code.
1393 * src/truetype/ttinterp.c (TT_MulFix14_arm, TT_MulFix14_long_long,
1394 TT_DotFix14_long_long): New functions.
1396 2013-07-16 David Turner <digit@google.com>
1398 Optimize FT_MulFix for x86_64 GCC builds.
1400 This patch provides an optimized `FT_MulFix' implementation for
1401 x86_64 machines when FreeType is built with GCC, or compatible
1402 compilers like Clang.
1405 bin/ftbench -p -t 5 -s 14 -f 0008 Arial.ttf
1410 Load_Advances (Normal) 4.816 us/op
1411 Load_Advances (Fast) 0.028 us/op
1413 Get_Glyph 0.463 us/op
1414 Get_CBox 0.077 us/op
1415 Get_Char_Index 0.023 us/op
1416 Iterate CMap 13.898 us/op
1417 New_Face 12.368 us/op
1418 Embolden 0.028 us/op
1419 Get_BBox 0.302 us/op
1424 Load_Advances (Normal) 4.645 us/op
1425 Load_Advances (Fast) 0.027 us/op
1427 Get_Glyph 0.460 us/op
1428 Get_CBox 0.077 us/op
1429 Get_Char_Index 0.024 us/op
1430 Iterate CMap 13.403 us/op
1431 New_Face 12.278 us/op
1432 Embolden 0.028 us/op
1433 Get_BBox 0.301 us/op
1435 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
1436 (FT_MulFix_x86_64): New function.
1438 2013-07-16 David Turner <digit@google.com>
1440 Speed up ARMv7 support.
1442 When building for ARMv7 with thumb2 instructions, the optimized
1443 `FT_MulFix_arm' assembly routine was not being used.
1445 The reason for this is in the `ftconfig.h' header, namely:
1447 - The assembly routine uses the `smull' instruction which is not
1448 available when generating Thumb-1 machine code. It is available
1449 in Thumb-2 mode, though.
1451 - The header was written a long time ago before Thumb-2 became
1452 widely popular (e.g. with Android). So it simply doesn't use the
1453 assembly routine if the `__thumb__' built-in macro is defined.
1455 - When compiling in Thumb-2 mode, the compiler will define both
1456 `__thumb__' and `__thumb2__'.
1458 By checking for `(__thumb2__ || !__thumb__)', we ensure that the
1459 assembly routine is only avoided when generating Thumb-1 code.
1461 Given that this is performance-sensitive function, this improves
1462 `ftbench' as follows on a Galaxy Nexus:
1464 Before (us/op) After (us/op)
1466 - loading Arial.ttf glyphs at 14 ppem [1]
1470 - same operation with the light auto-hinter [2]
1474 - same operation without hinting [3]
1478 - loading Arial.ttf advances at 14 ppem [4]
1480 Load_Advances (normal) 34.216 33.016
1481 Load_Advances (fast) 0.176 0.176
1483 [1] ftbench -t 5 -p -s 14 -b a -f 0008 Arial.ttf
1484 [2] ftbench -t 5 -p -s 14 -b a -r 1 -f 0028 Arial.ttf
1485 [3] ftbench -t 5 -p -s 14 -b a -f 000a Arial.ttf
1486 [4] ftbench -t 5 -p -s 14 -b b -f 0008 Arial.ttf
1488 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
1489 (FT_MULFIX_ASSEMBLER): Fix handling for ARMv7.
1491 2013-06-28 Werner Lemberg <wl@gnu.org>
1493 * docs/CHANGES: Updated.
1495 2013-06-27 Werner Lemberg <wl@gnu.org>
1497 * src/winfonts/winfnt.c (FNT_Load_Glyph): Fix bitmap width guard.
1499 2013-06-25 Werner Lemberg <wl@gnu.org>
1501 [cff] Add darkening limit to `darkening-parameters'.
1503 * src/cff/cffdrivr.c (cff_property_set): Add check.
1505 2013-06-25 Werner Lemberg <wl@gnu.org>
1507 [cff] Add `darkening-parameters' property.
1509 * include/freetype/ftcffdrv.h: Document it.
1511 * src/cff/cffdrivr.c (cff_property_set, cff_property_get): Handle
1512 `darkening-parameters' property.
1514 * src/cff/cf2font.h (CF2_FontRec): Add `darkenParams' array.
1516 * src/cff/cf2font.c (cf2_computeDarkening): Add `darkenParams'
1517 argument and use it.
1520 * src/cff/cf2ft.c (cf2_decoder_parse_charstrings): Copy
1521 `darken_params' values.
1523 * src/cff/cffobjs.h (CFF_DriverRec): Add `darken_params' array.
1525 * src/cff/cffobjs.c (cff_driver_init): Set default values for
1528 2013-06-25 Werner Lemberg <wl@gnu.org>
1530 [docmaker] Code shuffling.
1532 * src/tools/docmaker/tohtml.py (re_url): Move regexp...
1533 * src/tools/docmaker/sources.py: ... to this file.
1535 2013-06-25 Werner Lemberg <wl@gnu.org>
1537 [docmaker] Remove unused functions.
1539 * src/tools/docmaker/content.py (DocMarkup.get_start,
1540 DocBlock.get_markup_name): Removed.
1541 * src/tools/docmaker/tohtml.py (html_quote0, dump_html_code,
1542 HtmlFormatter.make_html_words): Removed.
1544 2013-06-25 Werner Lemberg <wl@gnu.org>
1546 * builds/freetype.mk (dll): Remove target.
1548 Problem reported by Jörg Günnewig <joerg.guennewig@googlemail.com>.
1550 2013-06-25 Werner Lemberg <wl@gnu.org>
1552 [docmaker] Recognise URLs.
1554 * src/tools/docmaker/tohtml.py (re_url): New regular expression.
1555 (make_html_para): Use it.
1557 2013-06-19 Werner Lemberg <wl@gnu.org>
1559 * Version 2.5.0.1 released.
1560 ===========================
1563 Tag sources with `VER-2-5-0-1'.
1565 * include/freetype/config/ftoption.h: Undefine
1566 CFF_CONFIG_OPTION_OLD_ENGINE.
1567 * devel/ftoption.h: Define CFF_CONFIG_OPTION_OLD_ENGINE.
1569 2013-06-19 Werner Lemberg <wl@gnu.org>
1571 * builds/unix/install.mk (install): Don't create `cache' directory.
1573 Found by Peter Breitenlohner <peb@mppmu.mpg.de>.
1575 2013-06-19 Werner Lemberg <wl@gnu.org>
1577 * Version 2.5.0 released.
1578 =========================
1581 Tag sources with `VER-2-5-0'.
1583 * docs/VERSION.DLL: Update documentation and bump version number to
1586 * README, Jamfile (RefDoc),
1587 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
1588 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
1589 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
1590 builds/win32/visualc/freetype.dsp,
1591 builds/win32/visualc/freetype.vcproj,
1592 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
1593 builds/win32/visualce/freetype.vcproj,
1594 builds/win32/visualce/index.html,
1595 builds/wince/vc2005-ce/freetype.vcproj,
1596 builds/wince/vc2005-ce/index.html,
1597 builds/wince/vc2008-ce/freetype.vcproj,
1598 builds/wince/vc2008-ce/index.html: s/2.4.12/2.5.0/, s/2412/250/.
1600 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 5.
1601 (FREETYPE_PATCH): Set to 0.
1603 * builds/unix/configure.raw (version_info): Set to 16:2:10.
1605 * src/base/ftobjs.c (FT_Open_Face): Pacify compiler.
1606 * src/truetype/ttinterp.c (Ins_MSIRP, Ins_MIRP): Ditto.
1608 2013-06-18 Werner Lemberg <wl@gnu.org>
1610 Fix Savannah bug #39269.
1612 * src/base/ftgloadr.c (FT_GlyphLoader_CheckPoints): Free memory in
1613 case of reacollocation failures.
1615 2013-06-18 Andrew Church <achurch+savannah@achurch.org>
1617 Fix Savannah bug #39266.
1619 If memory allocations fail at certain points while opening a font,
1620 FreeType can either crash due to a NULL dereference or leak memory.
1622 * include/freetype/internal/ftobjs.c (FT_Face_InternalRec,
1623 FT_LibraryRec): Make `refcount' a signed integer. If, for example,
1624 FT_Open_Face() fails in a memory allocation before the face's
1625 reference count is set to 1, a subsequent `FT_Done_Library' call
1626 would otherwise loop over `FT_Done_Face' 2^32 times before freeing
1629 * src/base/ftobjs.c (open_face): Initialize `stream' and friends
1631 (FT_Open_Face) <Fail>: Behave correctly if `node' is NULL.
1632 (FT_Destroy_Module) <Fail>: Check that `renderer_clazz' is valid.
1634 2013-06-14 Werner Lemberg <wl@gnu.org>
1636 * src/smooth/ftgrays.c One final pragma to silence 64-bit MSVC.
1638 2013-06-06 Dave Arnold <darnold@adobe.com>
1639 Werner Lemberg <wl@gnu.org>
1641 [cff] Add code to Adobe's engine to handle ppem > 2000.
1643 * src/cff/cffgload.c (cff_slot_load): If we get
1644 FT_Err_Glyph_Too_Big, retry unhinted and scale up later on.
1646 2013-06-12 Werner Lemberg <wl@gnu.org>
1648 Another try on pragmas.
1650 * include/freetype/internal/ftdebug.h: Move pragmas to...
1651 * include/freetype/internal/internal.h: ... this file since it gets
1652 included by all source files.
1653 * include/freetype/internal/ftserv.h: Remove pragma which has no
1656 2013-06-12 Werner Lemberg <wl@gnu.org>
1658 * include/freetype/internal/ftdebug.h: Disable MSVC warning C4127.
1660 This partially undoes commit 3f6e0e0c.
1662 2013-06-12 Werner Lemberg <wl@gnu.org>
1664 More compiler warning fixes.
1666 */*: Use cast to `FT_Bool' (or `Bool') where appropriate.
1668 2013-06-10 Werner Lemberg <wl@gnu.org>
1670 [truetype] Improve handling of broken sbit advance widths.
1672 * src/truetype/ttgload.c (TT_Load_Glyph): Use the glyph's (scaled)
1673 `linearHoriAdvance' if the sbit's `horiAdvance' value is zero.
1675 Cf. font `Fixedsys Excelsior' v3.01 (FSEX300.ttf), glyph A, 16ppem.
1677 2013-06-10 Werner Lemberg <wl@gnu.org>
1679 [sfnt] Improve embedded bitmap tracing.
1681 * src/base/ftobjs.c (FT_Request_Size): Move trace message regarding
1682 bitmap strike match to...
1683 (FT_Match_Size): This function.
1685 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics,
1686 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
1687 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
1688 tt_sbit_decoder_load_image): Decorate with tracing messages.
1690 2013-06-10 Werner Lemberg <wl@gnu.org>
1692 Fix Savannah bug #39160.
1694 * src/truetype/ttinterp.c (Ins_SDPVTL): Set projection vector too
1695 for the degenerate case.
1697 2013-06-09 David Turner <digit@google.com>
1699 * src/cache/ftcmanag.c (FTC_Manager_Reset): Add missing cache flush.
1701 This code, present since eight(!) years in the unused `CACHE'
1702 branch, has been forgotten to apply to the master branch. It's
1703 really amazing that noone has ever complained since
1704 `FTC_Manager_Reset' is pretty useless without flushing the cache.
1706 2013-06-07 Werner Lemberg <wl@gnu.org>
1708 Add and improve pragmas for MSVC compiler.
1710 * include/freetype/internal/ftdebug.h: Remove pragmas.
1711 * include/freetype/internal/ftserv.h: Use push and pop for pragmas.
1712 * include/freetype/internal/ftvalid.h: Handle warning C4324.
1713 * src/base/ftobjs.c: Use push and pop for pragmas.
1714 * src/gzip/ftgzip.c: Handle warning C4244.
1716 2013-06-07 Werner Lemberg <wl@gnu.org>
1718 [cff] s/cf2_getGlyphWidth/cf2_getGlyphOutline/.
1720 * src/cff/cf2font.c, src/cff/cf2font.h, src/cff/cf2ft.c: Do it.
1722 2013-06-06 Dave Arnold <darnold@adobe.com>
1724 [cff] Add early exit feature for width-only calls.
1726 This is for `FT_Get_Advance'.
1728 There are 7 places where the spec says the width can be defined:
1738 * src/cff/cf2intrp.c (cf2_doStems): Exit early for width-only calls,
1741 (cf2_interpT2CharString) <cf2_cmdHSTEM>, <cf2_cmdVSTEM>,
1742 <cf2_cmdVMOVETO>, <cf2_cmdENDCHAR>, <cf2_cmdHINTMASK>,
1743 <cf2_cmdRMOVETO>, <cf2_cmdHMOVETO>: Exit early for width-only calls.
1745 2013-06-06 Werner Lemberg <wl@gnu.org>
1747 Next round of compiler fixes.
1749 * builds/win32/ftdebug.c, builds/wince/ftdebug.c (ft_debug_init):
1752 * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Fix
1754 * include/freetype/internal/ftstream.h: Decorate stream and frame
1755 macros with `FT_Long' and `FT_ULong' as appropriate.
1757 * src/base/ftrfork.c (raccess_guess_darwin_hfsplus,
1758 raccess_guess_darwin_newvfs): Use cast.
1760 * src/bdf/bdflib.c (_bdf_set_default_spacing): Use cast.
1762 * src/cache/ftcmanag.c (FTC_Manager_Check): Fix cast.
1763 * src/cache/ftcmanag.h (FTC_ManagerRec): Ditto.
1765 * src/cff/cf2arrst.c (cf2_arrstack_setNum_Elements): Use cast.
1766 * src/cff/cf2ft.c (cf2_freeSeacComponent): Ditto.
1767 * src/cff/cffobjs.c (remove_subset_prefix, remove_style): Ditto.
1769 * src/cid/cidparse.c (cid_parser_new): Use cast.
1771 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Use cast.
1773 * src/psaux/psobjs.c (reallocate_t1_table): Fix argument type.
1775 * src/raster/ftraster.c (ft_black_reset): Use cast.
1777 * src/truetype/ttgxvar.c (FT_Stream_FTell): Use cast.
1778 (ALL_POINTS): Fix cast.
1780 * src/type1/t1driver.c (t1_ps_get_font_value): Add casts.
1781 * src/type1/t1parse.c (T1_Get_Private_Dict): Add cast.
1783 2013-06-05 Dave Arnold <darnold@adobe.com>
1785 Fix more MSVC Win32 compiler warnings.
1787 * src/base/ftobjs.c: Fix typo in MS pragma.
1789 * src/base/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
1790 `lineno' is only used in debug mode.
1792 * src/cff/cf2ft.c (cf2_builder_moveTo): `params' is only used in
1795 2013-06-05 Werner Lemberg <wl@gnu.org>
1797 Fix compiler warnings.
1799 * include/freetype/internal/ftmemory.h: Decorate memory allocation
1800 macros with `FT_Long' where appropriate.
1801 Remove duplicate of FT_MEM_QRENEW_ARRAY definition.
1803 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
1806 * src/base/ftobjs.c: Add warning disabling pragma for MSVC while
1809 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdESC>: Add
1812 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_compound): Fix casts.
1813 (tt_sbit_decoder_load_bitmap): Beautification.
1815 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Initialize
1816 variables (earlier).
1818 * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Pacify compiler.
1820 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Use unsigned constants
1823 * src/type1/t1load.c (T1_Get_MM_Var): Ditto.
1825 2013-06-04 Werner Lemberg <wl@gnu.org>
1827 * src/cff/cf2font.c (cf2_getGlyphWidth): Initialize `advWidth'.
1829 Problem reported by Ingmar Sittl <ingmar.sittl@elektrobit.com>.
1831 2013-06-04 Werner Lemberg <wl@gnu.org>
1833 Apply fixes for cppcheck nitpicks.
1835 http://cppcheck.sourceforge.net/
1837 The call was (from the top-level of the FreeType tree):
1842 -I include/freetype/ \
1843 -I include/freetype/config/ \
1844 -I include/freetype/internal/ \
1847 Note that the current version heavily chokes on FreeType, delivering
1848 many wrong results. I will report those issues to the cppcheck team
1849 so that a newer version gives improved results hopefully.
1851 */* Improve variable scopes.
1852 */* Remove redundant initializations which get overwritten.
1854 * src/base/ftmac.c, builds/mac/ftmac.c (count_faces_scalable):
1855 Remove unused variable.
1857 * src/base/ftdbgmem.c (ft_mem_table_destroy): `table' can't be zero.
1859 * src/gxvalid/gxvkern.c (gxv_kern_subtable_fmt1_entry_validate):
1860 Remove functionless code.
1862 * src/tools/ftrandom.c (main): Fix memory leak.
1864 2013-06-03 Werner Lemberg <wl@gnu.org>
1866 Add CFF_CONFIG_OPTION_OLD_ENGINE configuration option.
1868 This controls whether the old FreeType CFF engine gets compiled into
1869 FreeType. It is now disabled by default.
1871 * devel/ftoption.h, include/freetype/config/ftoption.h
1872 (CFF_CONFIG_OPTION_OLD_ENGINE): New macro.
1874 * src/cff/cffdrivr.c (cff_property_set), src/cff/cffgload.c
1875 (CFF_Operator, cff_argument_counts, cff_builder_add_point,
1876 cff_operator_seac, cff_decoder_parse_charstrings, cff_slot_load),
1877 src/cff/cffgload.h, src/cff/cffobjs.c (cff_driver_init): Use
1878 CFF_CONFIG_OPTION_OLD_ENGINE to guard the affected code.
1880 * docs/CHANGES: Updated.
1882 2013-06-02 Werner Lemberg <wl@gnu.org>
1884 Fix PNG library handling.
1886 * builds/unix/configure.raw: Don't use LIBPNG_LIBS but
1889 2013-05-23 Behdad Esfahbod <behdad@google.com>
1891 Add support for color embedded bitmaps (eg. color emoji).
1893 A new load flag, FT_LOAD_COLOR, makes FreeType load color
1894 embedded-bitmaps, following this draft specification
1896 https://color-emoji.googlecode.com/git/specification/v1.html
1898 which defines two new SFNT tables, `CBDT' and `CBLC' (named and
1899 modeled after `EBDT' and `EBLC', respectively). The color bitmaps
1900 are stored in the new FT_PIXEL_MODE_BGRA format to represent BGRA
1901 pre-multiplied sRGB images. If PNG support is available, PNG color
1902 images as defined in the same proposed specification are supported
1905 Note that color bitmaps are converted to grayscale if client didn't
1908 * builds/unix/configure.raw: Search for libpng.
1909 Add `--without-png' option.
1911 * devel/ftoption.h, include/freetype/config/ftoption.h
1912 (FT_CONFIG_OPTION_USE_PNG): New macro.
1914 * include/freetype/freetype.h (FT_LOAD_COLOR): New load flag.
1916 * include/freetype/ftimage.h (FT_Pixel_Mode): Add
1917 `FT_PIXEL_MODE_BGRA'.
1919 * include/freetype/tttags.h (TTAG_CBDT, TTAG_CBLC): New tags.
1921 * src/base/ftbitmap.c (FT_Bitmap_Embolden): Updated.
1922 (ft_gray_for_premultiplied_srgb_bgra): New function.
1923 (FT_Bitmap_Convert): Handle FT_PIXEL_MODE_BGRA.
1925 * src/sfnt/pngshim.c, src/sfnt/pngshim.h: New files.
1927 * src/sfnt/sfnt.c: Include `pngshim.c'.
1929 * src/sfnt/ttsbit.c: Include FT_BITMAP_H and `pngshim.h'
1930 (tt_face_load_eblc): Load `CBLC'.
1931 (tt_sbit_decoder_init): Load `CBDT'.
1932 (tt_sbit_decoder_alloc_bitmap): Pass load flags to select between
1933 color and grayscale bitmaps.
1934 Set `num_grays'. This is used by `ftview' to choose the blending
1936 (tt_sbit_decoder_load_byte_aligned,
1937 tt_sbit_decoder_load_bit_aligned, tt_sbit_decoder_load_compound,
1938 tt_sbit_decoder_load_image): Pass load flag.
1940 Don't call `tt_sbit_decoder_alloc_bitmap'.
1942 (tt_sbit_decoder_load_png) [FT_CONFIG_OPTION_USE_PNG]: New function.
1943 (tt_sbit_decoder_load_bitmap): Pass load flag.
1944 Handle new glyph formats 17, 18, and 19.
1945 Call `tt_sbit_decoder_alloc_bitmap'.
1946 Flatten color bitmaps if necessary.
1947 (tt_face_load_sbit_image): Updated.
1949 * src/sfnt/rules.mk (SFNT_DRV_SRC): Add `pngshim.c'.
1951 * docs/CHANGES: Updated.
1953 2013-05-24 Guenter <info@gknw.net>
1955 Apply Savannah patch #8055.
1957 Make `apinames' create an import file for NetWare.
1959 * src/tools/apinames.c (PROGRAM_VERSION): Set to 0.2.
1960 (OutputFormat): Add `OUTPUT_NETWARE_IMP'.
1961 (names_dump): Handle it.
1963 (main): Handle new command line flag `-wN'.
1965 2013-05-23 Behdad Esfahbod <behdad@behdad.org>
1969 * src/truetype/ttinterp.c (TT_RunIns)
1970 [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Make it work.
1972 2013-05-22 Infinality <infinality@infinality.net>
1974 [truetype] Formatting and an additional subpixel tweak.
1976 * src/truetype/ttinterp.c (Ins_SHPIX): Formatting fix.
1977 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules):
1978 Revert previous modification for Verdana clones.
1980 2013-05-22 Infinality <infinality@infinality.net>
1982 [truetype] Adjust subpixel zp2 moves and tweak rules.
1984 These modifications fix thin diagonal stems in some legacy fonts.
1986 * src/truetype/ttinterp.c (Direct_Move_X): Remove unused macro.
1987 (Move_Zp2_Point): Don't always disable x moves for subpixel rendering.
1988 (Ins_SHP): Disable x moves here for subpixel rendering.
1989 (Ins_SHPIX): Only disable x moves in compatibility mode.
1990 Split out zp2 move reversals and reorder conditional respectively.
1992 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules): Fix oversight.
1993 Only adjust Verdana clones for 17 ppem.
1994 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Courier New.
1995 (ALWAYS_SKIP_DELTAP_Rules): Found additional cases for Arial `s'.
1997 2013-05-20 Infinality <infinality@infinality.net>
1999 [truetype] Simplify and improve subpixel function detection.
2001 Some small enhancements have allowed the removal of many macros and
2002 the simplification of existing rules in `ttsubpix.c'.
2004 * src/truetype/ttsubpix.h (SPH_TWEAK_ALLOW_X_DMOVEX,
2005 SPH_TWEAK_ALLOW_X_MOVE_ZP2,
2006 SPH_TWEAK_DELTAP_SKIP_EXAGGERATED_VALUES,
2007 SPH_TWEAK_SKIP_INLINE_DELTAS, SPH_TWEAK_MIRP_CVT_ZERO): Removed.
2008 (SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES_DELTAP): New rule macro.
2010 * src/truetype/ttsubpix.c: Updated affected rules.
2012 * src/truetype/ttinterp.c (Direct_Move_X): Updated.
2013 (INS_FDEF): Add additional function detection.
2014 (INS_ENDF): Set runtime flag.
2015 (Ins_CALL): Skip the call under certain conditions.
2017 (Ins_LOOPCALL): Skip the call under certain conditions.
2019 (Move_Zp2_Point): Updated.
2020 (Ins_SHPIX): Updated.
2021 Skip the move under some situations.
2022 (Ins_MIAP): Improve conditions.
2023 (Ins_MIRP): Updated.
2024 (Ins_DELTAP): Skip move under certain conditions.
2025 Simplify conditions.
2026 (TT_RunIns): Updated.
2027 Add code to handle new function detection.
2030 2013-05-17 Werner Lemberg <wl@gnu.org>
2032 Update more FT_Err_XXX macros using FT_ERR and FT_THROW;
2034 * builds/amiga/src/base/ftsystem.c, builds/mac/ftmac.c,
2035 builds/unix/ftsystem.c, builds/vms/ftsystem.c: Do it.
2037 2013-05-15 Werner Lemberg <wl@gnu.org>
2039 [truetype] Add `interpreter-version' property.
2041 This makes the option TT_CONFIG_OPTION_SUBPIXEL_HINTING controllable
2044 * include/freetype/ftttdrv.h: New file.
2046 * include/freetype/config/ftheader.h (FT_TRUETYPE_DRIVER_H): New
2049 * src/truetype/ttdriver.c: Include FT_TRUETYPE_DRIVER_H.
2050 (tt_property_set, tt_property_get): Fill templates.
2052 * src/truetype/ttobjs.h (TT_DriverRec): Add `interpreter_version'
2054 Remove unused `extension_component' member.
2056 * src/truetype/ttgload.c: Include FT_TRUETYPE_DRIVER_H.
2057 (tt_get_metrics, TT_Hint_Glyph, TT_Process_Simple_Glyph,
2058 compute_glyph_metrics, tt_loader_init): Use `interpreter_version'.
2060 * src/truetype/ttinterp.c: Include FT_TRUETYPE_DRIVER_H.
2061 (SUBPIXEL_HINTING): New macro to check `interpreter_version' flag.
2062 Update all affected functions to use it.
2063 Use TT_INTERPRETER_VERSION_XXX where appropriate.
2065 * src/truetype/ttobjs.c: Include FT_TRUETYPE_DRIVER_H.
2066 (tt_driver_init): Initialize `interpreter_version'.
2068 * src/truetype/ttsubpix.c: Include FT_TRUETYPE_DRIVER_H.
2069 Use TT_INTERPRETER_VERSION_XXX where appropriate.
2071 2013-05-13 Werner Lemberg <wl@gnu.org>
2073 [truetype] Avoid empty source file.
2075 * src/truetype/ttsubpix.c [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]:
2076 Provide dummy typedef.
2078 2013-05-13 Werner Lemberg <wl@gnu.org>
2080 * src/cff/cf2font.c (cf2_getGlyphWidth): Fix uninitialized variable.
2082 Fix suggested by Vaibhav Nagarnaik <vnagarnaik@gmail.com>.
2084 2013-05-13 Brian Nixon <bnixon@yahoo.com>
2086 Fix Savannah bug #38970.
2088 * src/base/ftdebug.c, builds/win32/ftdebug.c,
2089 builds/wince/ftdebug.c, builds/amiga/src/base/ftdebug.c
2090 (ft_debug_init): Don't read past the environment variable FT2_DEBUG.
2092 2013-05-12 Werner Lemberg <wl@gnu.org>
2094 [truetype] Add framework for TrueType properties.
2096 * src/truetype/ttdrivr.c: Include FT_SERVICE_PROPERTIES_H.
2097 (tt_property_set, tt_property_get): New functions, still empty.
2098 Define `tt_service_properties' service.
2099 Update `tt_services'.
2101 * src/truetype/ttpic.h: Include FT_SERVICE_PROPERTIES_H.
2102 (TT_SERVICE_PROPERTIES_GET): New macro.
2103 (TTModulePIC): Add `tt_service_properties'.
2105 2013-05-12 Werner Lemberg <wl@gnu.org>
2107 Fix Savannah bug #38967.
2109 * src/base/ftcalc.c (FT_DivFix) [FT_LONG64]: Fix cast.
2111 2013-05-12 Werner Lemberg <wl@gnu.org>
2113 Introduce unsigned 64bit type (if available).
2115 * include/freetype/config/ftconfig.h: Define FT_UINT64 if available.
2116 [FT_LONG64]: Provide FT_UInt64.
2118 * builds/unix/ftconfig.in: Synchronized.
2120 2013-05-12 Werner Lemberg <wl@gnu.org>
2122 Fix Savannah bug #38968.
2124 * include/freetype/ftmodapi.h: Add `FT_EXPORT' to
2125 FT_Property_{Set,Get}.
2126 * src/base/ftobjs.c: Add `FT_EXPORT_DEF' to
2127 FT_Property_{Set,Get}.
2129 2013-05-10 Werner Lemberg <wl@gnu.org>
2131 [sfnt] Clean up bitmap code.
2133 * src/sfnt/ttsbit.c: Deleted.
2134 * src/sfnt/ttsbit0.c: Renamed to `ttsbit.c'.
2135 * rules.mk (SFNT_DRV_H): Updated.
2137 2013-05-10 Werner Lemberg <wl@gnu.org>
2139 */* [FT_CONFIG_OPTION_OLD_INTERNALS]: Remove macro and guarded code.
2141 2013-05-08 Werner Lemberg <wl@gnu.org>
2143 * Version 2.4.12 released.
2144 ==========================
2147 Tag sources with `VER-2-4-12'.
2149 * docs/VERSION.DLL: Update documentation and bump version number to
2152 * README, Jamfile (RefDoc),
2153 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
2154 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
2155 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
2156 builds/win32/visualc/freetype.dsp,
2157 builds/win32/visualc/freetype.vcproj,
2158 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
2159 builds/win32/visualce/freetype.vcproj,
2160 builds/win32/visualce/index.html,
2161 builds/wince/vc2005-ce/freetype.vcproj,
2162 builds/wince/vc2005-ce/index.html,
2163 builds/wince/vc2008-ce/freetype.vcproj,
2164 builds/wince/vc2008-ce/index.html: s/2.4.11/2.4.12/, s/2411/2412/.
2166 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 12.
2168 * builds/unix/configure.raw (version_info): Set to 16:1:10.
2170 2013-05-08 Werner Lemberg <wl@gnu.org>
2172 * docs/CHANGES: Updated.
2174 2013-05-08 Werner Lemberg <wl@gnu.org>
2176 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Typo.
2178 2013-05-05 Werner Lemberg <wl@gnu.org>
2180 Synchronize `ftconfig.h'.
2182 * builds/unix/ftconfig.in: Updated.
2184 2013-05-05 Werner Lemberg <wl@gnu.org>
2186 Fix compilation with C++.
2188 * src/base/md5.c (body): Use proper cast.
2190 2013-05-05 Werner Lemberg <wl@gnu.org>
2192 Fix 64bit compilation issues.
2194 * include/freetype/config/ftconfig.h [FT_LONG64]: Typedef
2197 * src/base/ftcalc.c: Remove typedef of `FT_Int64'.
2198 (FT_DivFix): Fix cast.
2199 * src/base/fttrigon.c: Remove typedef of `FT_Int64'.
2201 2013-05-05 Werner Lemberg <wl@gnu.org>
2203 [raster] Fix clang issues.
2205 Fix suggested by <octoploid@yandex.com>.
2207 * src/raster/ftraster.c (ULong): New typedef.
2208 (SCALED): Add proper cast.
2210 2013-05-04 Werner Lemberg <wl@gnu.org>
2214 * src/base/fttrigon.c (ft_trig_prenorm, FT_Vector_Rotate): Use
2217 * src/cff/cf2intrp.c (cf2_interpT2CharString) <default>: Force
2218 unsigned for computations.
2219 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Ditto.
2220 * src/cff/cffparse.c (cff_parse_integer): Ditto.
2222 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Ditto.
2224 2013-05-04 Werner Lemberg <wl@gnu.org>
2226 [cff] Make Adobe CFF engine work correctly on 64bit hosts.
2228 Reported by numerous people on the `freetype-devel' list. Without
2229 this fix, glyphs aren't properly aligned on a common baseline.
2231 On 64bit systems, `FT_Pos' expands to `long int', having a width of
2232 64bit. `CF2_Fixed' expands to `int' which is normally 32bit wide on
2233 64bit hosts also. Wrong casts filled up the blues arrays with
2234 incorrect values. Note that all blues values are accessed with the
2235 `cf2_blueToFixed' macro which handles the 64bit to 32bit conversion.
2237 * src/cff/cf2ft.h (cf2_getBlueValues, cf2_getOtherBlues,
2238 cf2_getFamilyBlues, cf2_getFamilyOtherBlues): Use `FT_Pos' for
2239 `data', not `CF2_Fixed'.
2240 * src/cff/cf2ft.c (cf2_getBlueValues, cf2_getOtherBlues,
2241 cf2_getFamilyBlues, cf2_getFamilyOtherBlues): Updated.
2242 * src/cff/cf2blues.c (cf2_blues_init): Updated.
2244 2013-05-04 Werner Lemberg <wl@gnu.org>
2246 More fixes for clang's `sanitize' feature.
2248 * src/base/ftcalc.c (FT_DivFix): Use unsigned values for
2249 computations which use the left shift operator and convert to signed
2251 * src/base/fttrigon.c (ft_trig_prenorm, FT_Vector_Rotate,
2252 FT_Vector_Length, FT_Vector_Polarize): Ditto.
2254 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Simplify.
2255 * src/cff/cffload.c (cff_subfont_load): Fix constant.
2256 * src/cff/cffparse.c (cff_parse_integer, cff_parse_real, do_fixed,
2257 cff_parse_fixed_dynamic): Use unsigned values for computations which
2258 use the left shift operator and convert to signed as the last step.
2260 * src/cid/cidload.c (cid_get_offset): Ditto.
2262 * src/psaux/psconv.c (PS_Conv_ToFixed): Ditto.
2263 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Ditto.
2265 * src/truetype/ttinterp.c (TT_MulFix14, TT_DotFix14): Ditto.
2267 2013-05-04 Werner Lemberg <wl@gnu.org>
2269 Fix errors reported by clang's `sanitize' feature.
2271 * include/freetype/internal/ftstream.h: Simplify and fix integer
2273 (FT_INT8_, FT_BYTE_I16, FT_BYTE_I32, FT_INT8_I16, FT_INT8_I32,
2274 FT_INT8_I32, FT_INT8_U32): Removed.
2275 (FT_PEEK_SHORT, FT_PEEK_LONG, FT_PEEK_OFF3, FT_PEEK_SHORT_LE,
2276 FT_PEEK_LONG_LE, FT_PEEK_OFF3_LE): Use unsigned values for
2277 computations and convert to signed as the last step.
2279 * src/cff/cf2fixed.h (cf2_intToFixed, cf2_fixedToInt,
2280 cf2_fracToFixed): Avoid shifts of negative values.
2281 (cf2_intToFrac, cf2_fixedToFrac, cf2_fixedTo26Dot6): Removed,
2284 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdEXTENDEDNMBR,
2285 default>: Use unsigned values for computations and convert to signed
2287 Use proper types in tracing messages.
2289 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Use unsigned
2290 values for computation of operands and convert to signed as the last
2292 Use proper type in tracing message.
2294 2013-05-03 Werner Lemberg <wl@gnu.org>
2296 * src/cff/cf2blues.c: Remove dead code.
2298 2013-05-02 Chris Liddell <chris.liddell@artifex.com>
2300 * src/cff/cffgload.c: Include FT_CFF_DRIVER_H.
2302 2013-04-27 Werner Lemberg <wl@gnu.org>
2304 * docs/CHANGES: Updated.
2307 2013-04-13 Werner Lemberg <wl@gnu.org>
2309 [cff] Add a new Type 2 interpreter and hinter.
2311 This work, written by Dave Arnold <darnold@adobe.com> and fully
2312 integrated into FreeType by me, is a donation by Adobe in
2313 collaboration with Google. It is vastly superior to the old CFF
2314 engine, and it will replace it soon. Right now, it is still off by
2315 default, and you have to explicitly select it using the new
2316 `hinting-engine' property of the cff driver.
2318 For convenience, (most of) the new files are committed separately.
2320 * include/freetype/config/ftheader.h (FT_CFF_DRIVER_H): New macro.
2321 * include/freetype/ftcffdrv.h: New file to access CFF driver
2323 * include/freetype/fterrdef.h (FT_Err_Glyph_Too_Big): New error
2325 * include/freetype/internal/fttrace.h: Add `cf2blues', `cf2hints',
2328 * src/cff/cffgload.h (CFF_SubFont): New member `current_subfont'.
2329 * src/cff/cffobjs.h (CFF_DriverRec): New members `hinting_engine'
2330 and `no_stem_darkening'.
2331 * src/cff/cfftypes.h (CFF_FontRec): New member `cf2_instance'.
2333 * src/cff/cff.c: Include new files.
2334 * src/cff/cffdrivr.c (cff_property_set, cff_property_get): Handle
2335 `hinting-engine' and `no-stem-darkening' properties (only the Adobe
2336 engine listens to them).
2337 * src/cff/cffgload.c: Include `cf2ft.h'.
2338 (cff_decoder_prepare): Initialize `current_subfont'.
2339 (cff_build_add_point): Handle Adobe engine which uses 16.16
2341 (cff_slot_load): Handle FT_LOAD_NO_SCALE and FT_LOAD_NO_HINTING
2343 Choose rendering engine based on `hinting_engine' property.
2344 * src/cff/cffload.c (cff_font_done): Call finalizer of the Adobe
2346 * src/cff/cffobjs.c: Include FT_CFF_DRIVER_H.
2347 (cff_driver_init): Set default property values.
2349 * src/cff/rules.mk (CFF_DRV_SRC, CFF_DRV_H): Add new files.
2351 * src/cff/cf2*.*: New files, containing the Adobe engine.
2353 2013-04-12 Werner Lemberg <wl@gnu.org>
2355 [cff] Minor code administration issues.
2357 * src/cff/cffgload.c (check_points): Rename to...
2358 (cff_check_points): ...this and make it FT_LOCAL.
2359 (cff_builder_add_point, cff_builder_add_point1,
2360 cff_builder_start_point, cff_builder_close_contour,
2361 cff_lookup_glyph_by_stdcharcode, cff_get_glyph_data,
2362 cff_free_glyph_data): Make them FT_LOCAL.
2364 * src/cff/cffgload.h: Updated.
2366 2013-04-12 Werner Lemberg <wl@gnu.org>
2368 Add output bitmap checksums.
2370 Use `FT2_DEBUG=bitmap:3' for tracing.
2372 * src/base/md5.c, src/base/md5.h: New files, taken from
2374 http://openwall.info/wiki/people/solar/software/public-domain-source-code/md5
2376 * include/freetype/internal/fttrace.h: Add `bitmap'.
2378 * src/base/ftobjs.c [FT_DEBUG_LEVEL_TRACE]: Include `md5.c'
2380 (FT_Render_Glyph_Internal) [FT_DEBUG_LEVEL_TRACE]: For tracing,
2381 convert resulting bitmap to a uniform format and compute a checksum.
2382 Use `bitmap' category for the tracing message.
2384 * src/base/rules.mk (BASE_H): Updated.
2386 * docs/LICENSE.TXT: Updated.
2388 2013-04-12 Werner Lemberg <wl@gnu.org>
2390 [cff] Add framework for CFF properties.
2392 * include/freetype/internal/ftserv.h (FT_DEFINE_SERVICEDESCREC7):
2395 * src/cff/cffdrivr.c: Include FT_SERVICE_PROPERTIES_H.
2396 (cff_property_set, cff_property_get): New functions, still empty.
2397 Define `cff_service_properties' service.
2398 Update `cff_services'.
2400 * src/cff/cffpic.h: Include FT_SERVICE_PROPERTIES_H.
2401 (CFF_SERVICE_PROPERTIES_GET): New macro.
2402 (CffModulePIC): Add `cff_service_properties'.
2404 2013-04-03 Werner Lemberg <wl@gnu.org>
2406 [bdf] Fix Savannah bug #38589.
2408 * src/bdf/bdflib.c (_bdf_readstream): Thinko.
2410 2013-03-31 Werner Lemberg <wl@gnu.org>
2412 * configure: Use egrep, not grep.
2414 Problem reported Mojca Miklavec <mojca.miklavec.lists@gmail.com>.
2416 2013-03-29 Werner Lemberg <wl@gnu.org>
2418 * include/freetype/ftlcdfil.h: Add description of color filtering.
2420 Based on a contribution from Antti S. Lankila <alankila@bel.fi>
2421 (Savannah bug #38607).
2423 2013-03-23 Werner Lemberg <wl@gnu.org>
2427 * src/autofit/afmodule.c (af_property_set): Typo.
2428 (af_autofitter_init, af_autofitter_done): Use cast.
2430 2013-03-21 Werner Lemberg <wl@gnu.org>
2432 * configure: Automatically test for `gmake' also.
2434 Suggested by Mojca Miklavec <mojca.miklavec.lists@gmail.com>.
2436 2013-03-21 Peter Breitenlohner <peb@mppmu.mpg.de>
2438 Respect CONFIG_SHELL from the environment.
2440 Some large packages using FreeType have to use a broken (deficient)
2441 /bin/sh. The configure scripts (as generated by Autoconf) are
2442 clever enough to find a better shell and put that one into the
2443 environment variable CONFIG_SHELL. If that environment variable is
2444 already set the script skips the test and assumes to be already
2445 running under a good shell.
2447 * builds/unix/detect.mk: Honour CONFIG_SHELL.
2448 * builds/unix/unix-def.in (SHELL): Define.
2450 2013-03-21 Werner Lemberg <wl@gnu.org>
2452 Fix Savannah patch #7971.
2454 * configure: Handle MAKE environment variable also.
2456 2013-03-17 Werner Lemberg <wl@gnu.org>
2458 Fix Savannah bug #38538.
2460 * builds/amiga/src/base/ftdebug.c, builds/win32/ftdebug.c,
2461 builds/wince/ftdebug.c (FT_Throw): Add function.
2463 2013-03-17 Werner Lemberg <wl@gnu.org>
2465 [raster] Remove dead code.
2467 * src/raster/rastpic.c (ft_raster1_renderer_class_pic_init)
2468 src/smooth/ftspic.c (ft_smooth_renderer_class_pic_init): Do it.
2470 2013-03-17 Werner Lemberg <wl@gnu.org>
2472 * src/pshinter/pshpic.h (GET_PIC): Use correct container.
2474 2013-03-15 Werner Lemberg <wl@gnu.org>
2476 * include/freetype/ftmoderr.h: Fix commit from 2013-03-11.
2478 The previous version was not backwards compatible. Reported by
2481 2013-03-14 Werner Lemberg <wl@gnu.org>
2483 */*: Use FT_ERR_EQ, FT_ERR_NEQ, and FT_ERR where appropriate.
2485 FT_Err_XXX and friends are no longer directly used in the source
2488 2013-03-14 Werner Lemberg <wl@gnu.org>
2490 New error management macros.
2492 * include/freetype/fterrors.h (FT_ERR_XCAT, FT_ERR_CAT): Move to...
2493 * include/freetype/fttypes.h: ... this file.
2494 (FT_ERR, FT_ERR_EQ, FT_ERR_NEQ, FT_MODERR_EQ, FT_MODERR_NEQ): New
2497 * include/freetype/freetype.h: Updated.
2499 2013-03-14 Werner Lemberg <wl@gnu.org>
2501 */*: Use FT_Err_Ok only.
2503 This is a purely mechanical conversion.
2505 2013-03-14 Werner Lemberg <wl@gnu.org>
2507 */*: Use `FT_THROW'.
2509 This is essentially a mechanical conversion, adding inclusion of
2510 `FT_INTERNAL_DEBUG_H' where necessary, and providing the macros for
2511 stand-alone compiling modes of the rasterizer modules.
2513 To convert the remaining occurrences of FT_Err_XXX and friends it is
2514 necessary to rewrite the code. Note, however, that it doesn't harm
2515 if some cases are not handled since FT_THROW is a no-op.
2517 2013-03-13 Werner Lemberg <wl@gnu.org>
2519 Introduce `FT_THROW' macro.
2521 The idea is to replace code like
2523 return FT_Err_Foo_Bar;
2527 return CFF_Err_Foo_Bar;
2531 return FT_THROW( Foo_Bar );
2533 The FT_THROW macro has two functions:
2535 . It hides the module specific prefix.
2537 . In debug mode, it calls the empty function `FT_Throw' which can
2538 be thus used to set a breakpoint.
2540 * include/freetype/internal/ftdebug.h (FT_THROW): New macro.
2541 (FT_Throw): New prototype.
2542 * src/base/ftdebug.c (FT_Throw): New function.
2544 2013-03-12 Werner Lemberg <wl@gnu.org>
2546 Remove `FT_KEEP_ERR_PREFIX'.
2548 The idea is to always have FT_ERR_PREFIX available internally.
2550 * include/freetype/fterrors.h: Use FT2_BUILD_LIBRARY to guard
2551 undefinition of FT_ERR_PREFIX
2553 * src/gxvalid/gxverror.h, src/otvalid/otverror.h,
2554 src/sfnt/sferrors.h: Updated.
2556 2013-03-11 Werner Lemberg <wl@gnu.org>
2558 [gxvalid] Fix module error.
2560 * src/gxvalid/gxverror.h (FT_ERR_BASE): Define as
2562 * include/freetype/ftmoderr.h: Add module error for `GXvalid'.
2564 2013-03-11 Werner Lemberg <wl@gnu.org>
2566 Always use module related error codes.
2568 * src/cff/cffobjs.c (cff_face_init), src/type1/t1objs.c
2569 (T1_Face_Init), src/type42/t42objs.c (T42_Face_Init): Use
2572 * src/type1/t1load.c (parse_encoding): Use
2573 T1_Err_Unknown_File_Format.
2575 2013-03-08 Werner Lemberg <wl@gnu.org>
2577 [cff] Set `linear{Hori,Vert}Advance' for embedded bitmaps also.
2579 Problem reported by Khaled Hosny <khaledhosny@eglug.org>.
2581 * src/cff/cffgload.c (cff_slot_load): Implement it.
2583 2013-02-23 Alexei Podtelezhnikov <apodtele@gmail.com>
2585 [base] Fix commit ab02d9e8.
2587 * src/base/ftbbox.c (BBox_Cubic_Check): Change scaling to msb of 22.
2589 2013-02-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2591 [base] New bisecting BBox_Cubic_Check (disabled).
2593 * src/base/ftbbox.c (BBox_Cubic_Check): New bisecting algorithm
2594 for extremum search built around simple condition that defines
2595 which half contains the extremum.
2597 2013-02-18 Alexei Podtelezhnikov <apodtele@gmail.com>
2599 [tools] Update BBox testing tool.
2601 * src/tools/test_bbox.c: Add another cubic outline with exact BBox.
2602 (REPEAT): Increase the number of benchmarking cycles.
2603 (profile_outline): Tweak output formatting.
2605 2013-02-02 Werner Lemberg <wl@gnu.org>
2607 Fix Savannah bug #38235.
2609 * builds/unix/configure.raw: Don't generate `freetype-config' and
2612 * builds/unix/unix-def.in (FT2_EXTRA_LIBS, LIBBZ2, LIBZ,
2613 build_libtool_libs, ft_version): New variables to be substituted.
2614 (freetype-config, freetype.pc): New rules to generate those files.
2616 * builds/unix/freetype-config.in: Remove code for handling `rpath'.
2617 The use of $rpath has been accidentally removed in a patch from
2618 2009-12-22, and apparently noone has missed it since.
2619 Use `%' instead of `@' as a variable substitution marker.
2622 * builds/unix/freetype.in: Use `%' instead of `@' as a variable
2623 substitution marker.
2626 2013-02-07 Werner Lemberg <wl@gnu.org>
2628 * src/truetype/ttobjs.c (tt_size_run_prep): Reset more GS variables.
2630 BTW, Greg agrees that the OpenType specification is missing the list
2631 of GS variables which will always be reset to the default values
2632 after the `prep' table has been executed.
2634 2013-02-06 Werner Lemberg <wl@gnu.org>
2636 * src/truetype/ttobjs.c (tt_size_run_prep): Reset reference points.
2638 Up to now, we simply took a snapshot of the Graphics State after the
2639 `prep' table has been executed, and right before a glyph's bytecode
2640 was run it got reloaded. However, as Greg Hitchcock has told us in
2641 private communication, reference points get reset to zero in the MS
2642 rasterizer and we follow in due course. While reasonable, this is
2643 undocumented behaviour.
2645 Most notably, this fixes the rendering of Arial's `x' glyph in
2646 subpixel hinting mode.
2648 2013-02-05 Werner Lemberg <wl@gnu.org>
2650 [truetype] A better fix for Savannah bug #38211.
2652 * src/truetype/ttinterp.c (Ins_IP): Implement identical behaviour to
2653 MS rasterizer if rp1 == rp2 (confirmed by Greg Hitchcock).
2655 2013-02-01 Alexei Podtelezhnikov <apodtele@gmail.com>
2657 [pcf] Streamline parsing of PCF encoding table.
2659 * src/pcf/pcfread.c (pcf_get_encodings): Use simpler double for-loop.
2660 Reallocate array instead of using temporary storage.
2662 2013-02-01 Werner Lemberg <wl@gnu.org>
2664 Fix Savannah bug #38227.
2666 * builds/unix/freetype-config.in: Set LC_ALL.
2668 2013-02-01 Werner Lemberg <wl@gnu.org>
2670 Fix Savannah bug #38221.
2672 This complements commit 83c0ebab.
2674 * src/base/ftcalc.c (FT_MulDiv_No_Round): Don't enclose with
2675 `TT_USE_BYTECODE_INTERPRETER'.
2677 2013-02-01 Werner Lemberg <wl@gnu.org>
2679 [truetype] Fix Savannah bug #38211.
2681 * src/truetype/ttinterp.c (Ins_IP): Make FreeType behave identical
2682 to other interpreters if rp1 == rp2 (which is invalid).
2684 2013-01-28 Alexei Podtelezhnikov <apodtele@gmail.com>
2686 [base] Small optimization of BBox calculation.
2688 * src/base/ftbbox.c (BBox_Cubic_Check): Use FT_MSB function in
2691 2013-01-26 Infinality <infinality@infinality.net>
2693 [truetype] Minor formatting fix.
2695 * src/truetype/ttinterp.c: Updated.
2696 (DO_RS): Fix indentation.
2698 2013-01-26 Infinality <infinality@infinality.net>
2700 [truetype] Fix rasterizer_version logic in sph.
2702 * src/truetype/ttsubpix.c: Updated.
2703 (ALWAYS_SKIP_DELTAP_Rules): Remove rule for Trebuchet MS.
2704 (sph_set_tweaks): Fix `rasterizer_version' logic.
2706 2013-01-26 Infinality <infinality@infinality.net>
2708 [truetype] Align more to ClearType whitepaper for sph.
2710 * include/freetype/internal/tttypes.h (TT_FaceRec): Add flags
2711 for detected opcode patterns and compatibility mode.
2713 * src/truetype/ttgload.c (tt_loader_init): Complete conditional.
2715 * src/truetype/ttinterp.c: Updated.
2716 Remove SPH_DEBUG and replace with FT_TRACE7.
2717 (DO_RS): More conditions.
2718 (Ins_FDEF): Add more opcode detection patterns.
2719 More specific conditions when flagging an fdef.
2720 Make compatibility mode only turn on when delta fdefs are found.
2721 (Ins_CALL, Ins_LOOPCALL): Set flags for currently executed fdef.
2722 (Ins_SHPIX): Remove logic to handle ttfautohinted fonts.
2723 Simplify conditionals where possible.
2724 Use `&' instead of `%' operator for dumb compilers.
2725 (Ins_MIAP): Adjust twilight zone conditional.
2726 Ensure `ignore_x_mode' is on when testing sph conditionals.
2727 (Ins_MIRP): Ensure `ignore_x_mode' is on when testing sph
2729 Do cvt cutin always when `ignore_x_mode' is active.
2730 Remove test for ttfautohinted fonts.
2731 (Ins_DELTAP): Ensure `ignore_x_mode' is on when testing sph
2733 Do cvt cutin always when `ignore_x_mode' is active.
2734 Remove test for ttfautohinted fonts.
2735 Use `&' instead of `%' operator for dumb compilers.
2736 (Ins_GETINFO): Remove SPH_DEBUG and replace with FT_TRACE7.
2738 * src/truetype/ttinterp.h: Updated.
2739 (TT_ExecContextRec): Remove compatibility_mode variable.
2740 Add variable to indicate when executing in special fdefs for sph.
2742 * src/truetype/ttobjs.h: Updated.
2743 (TT_DefRecord): Add flags to identify special fdefs for sph.
2744 (TT_SizeRec): Remove unnecessary ttfautohinted variable.
2746 * src/truetype/ttsubpix.c: Updated.
2747 (COMPATIBILITY_MODE_Rules): Remove all. Auto-detected now.
2748 (PIXEL_HINTING_Rules): Remove all. Unnecessary after fixes.
2749 (SKIP_NONPIXEL_Y_MOVES_Rules): Remove Ubuntu.
2750 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Arial Bold `N'.
2751 (SKIP_OFFPIXEL_Y_MOVES_Rules): Remove all. Happens automatically
2753 (ROUND_NONPIXEL_Y_MOVES_Rules): Remove Ubuntu.
2754 (ROUND_NONPIXEL_Y_MOVES_Rules_Exceptions): Remove all.
2755 (NORMAL_ROUND_Rules): Remove Verdana.
2756 (NO_DELTAP_AFTER_IUP_Rules): Remove all.
2757 (sph_set_tweaks): Performance fix. Don't run prep always.
2758 Adjust conditional for sph_compatibility_mode.
2760 * src/truetype/ttsubpix.h: Add new fdef flags for sph.
2762 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
2764 [base] Fix broken emboldening at small sizes.
2766 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Do not attempt to
2767 normalize zero-length vectors.
2769 2013-01-25 Werner Lemberg <wl@gnu.org>
2771 Fix Savannah bug #38167.
2773 This fixes commit 83c0ebab from 2012-06-27.
2775 * src/truetype/ttinterp.h:
2776 s/TT_CONFIG_OPTION_BYTECODE_INTERPRETER/TT_USE_BYTECODE_INTERPRETER/.
2778 2013-01-25 Xi Wang <xi.wang@gmail.com>
2780 [sfnt] Fix broken pointer overflow checks.
2782 Many compilers such as gcc and clang optimize away pointer overflow
2783 checks `p + n < p', because pointer overflow is undefined behavior.
2784 Use a safe form `n > p_limit - p' instead.
2786 Also avoid possible integer overflow issues, for example, using
2787 `num_glyphs > ( p_limit - p ) / 2' rather than `num_glyphs * 2'
2788 given a large `num_glyphs'.
2790 * src/sfnt/ttsbit0.c (tt_sbit_decoder_load_image): Implement it.
2792 2013-01-25 Werner Lemberg <wl@gnu.org>
2794 [base] Fix `make multi'.
2796 * src/base/ftoutln.c, src/base/fttrigon.c: Include
2799 2013-01-25 David 'Digit' Turner <digit@google.com>
2801 [truetype] Fix C++ compilation.
2803 * src/truetype/ttsubpix.h: Updated.
2804 (SPH_X_SCALING_RULES_SIZE): Moved and renamed to...
2805 * src/truetype/ttsubpix.c (X_SCALING_RULES_SIZE): This.
2806 (sph_X_SCALING_Rules): Removed.
2807 (scale_test_tweak): Make function static.
2808 (sph_test_tweak_x_scaling): New function.
2810 * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Updated.
2812 2013-01-23 Werner Lemberg <wl@gnu.org>
2814 [base] Make `FT_Hypot' really internal.
2816 * include/freetype/fttrigon.h (FT_Hypot): Move to...
2817 * include/freetype/internal/ftcalc.h: This file.
2819 * src/base/fttrigon.c (FT_Hypot): Move to...
2820 * src/base/ftcalc.c: This file.
2821 Include FT_TRIGONOMETRY_H.
2823 * src/truetype/ttgload.c: Don't include FT_TRIGONOMETRY_H.
2825 2013-01-23 Werner Lemberg <wl@gnu.org>
2827 [truetype] Revert change from 2013-01-22.
2829 FreeType's `height' value is the baseline-to-baseline distance...
2831 * src/truetype/ttobjs.c (tt_size_reset): Undo.
2833 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
2835 [base, truetype] New internal `FT_Hypot' function.
2837 * include/freetype/fttrigon.h (FT_Hypot): Declare it.
2838 * src/base/fttrigon.c (FT_Hypot): Define it.
2839 * src/truetype/ttgload.c (TT_Process_Composite_Component): Use it
2840 instead of explicit expressions.
2841 * src/truetype/ttinterp.c (Current_Ratio, Normalize): Use it instead
2843 (TT_VecLen): Removed.
2845 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
2847 [base] Fix integer overflow.
2849 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Normalize incoming and
2850 outgoing vectors and use fixed point arithmetic.
2852 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
2854 [base] Fix integer overflow.
2856 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Scale the
2857 coordinates down to avoid overflow.
2859 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
2861 [base] Split out MSB function.
2863 * src/base/fttrigon.c (ft_trig_prenorm): Borrow from here.
2864 * include/freetype/internal/ftcalc.h (FT_MSB): Declare here.
2865 * src/base/ftcalc.c (FT_MSB): Define here.
2867 2013-01-22 Werner Lemberg <wl@gnu.org>
2869 [truetype] Fix font height.
2871 * src/truetype/ttobjs.c (tt_size_reset): The Windows rendering
2872 engine uses rounded values of the ascender and descender to compute
2873 the TrueType font height.
2875 2013-01-16 Behdad Esfahbod <behdad@behdad.org>
2877 [sfnt] Fix optimized sbit loader.
2879 It was not taking bit_depth into consideration when blitting!
2881 * src/sfnt/ttsbit0.c (tt_sbit_decoder_load_byte_aligned,
2882 * tt_sbit_decoder_load_bit_aligned): Handle bit
2885 2013-01-16 David 'Digit' Turner <digit@google.com>
2887 [truetype] Improve sub-pixel code.
2889 This patches fixes many issues with the ttsubpix implementation.
2891 1. Data tables are defined, instead of declared, in the header, and
2892 thus copied into each source file that includes it.
2894 2. These tables were defined as global, mutable, visible variables,
2895 and thus costing private RAM to every process that loads the
2896 library (> 50 KB / process, this is huge!).
2898 Additionally, this also made the library export the symbols
2899 completely needlessly.
2901 3. Missing `sph_' and `SPH_' prefixes to some of the definitions.
2903 Note that this doesn't try to fix the incredibly inefficient storage
2904 format for the data tables used by the code. This one will require
2905 another pass in the future.
2907 * src/truetype/ttinterp.h (MAX_NAME_SIZE, MAX_CLASS_MEMBERS):
2909 (SPH_MAX_NAME_SIZE, SPH_MAX_CLASS_MEMBERS): This.
2912 (SPH_TweakRule, SPH_ScaleRule): Decorate with `const' where
2915 (Font_Class): Rename to...
2916 (SPH_Font_Class): This. Decorate with `const' where appropriate.
2918 * src/truetype/ttsubpix.h (scale_test_tweak, sph_test_tweak):
2919 Decorate arguments with `const' where appropriate.
2921 Move font tweaking tables to...
2923 * src/truetype/ttsubpic.c: This file and decorate them with `static'
2924 and `const' where appropriate.
2926 (X_SCALING_Rules, X_SCALING_RULES_SIZE): Renamed to...
2927 (spu_X_SCALING_Rules, SPH_X_SCALING_RULES_SIZE): This.
2930 2013-01-12 Alexei Podtelezhnikov <apodtele@gmail.com>
2932 [truetype] Improve accuracy of normalization of short vectors.
2934 Unit vector components are stored as 2.14 fixed-point numbers. In
2935 order to calculate all 14 bits accurately, a short vector to be
2936 normalized has to be upscaled to at least 14 bits before its length
2937 is calculated. This has been safe since accurate CORDIC algorithms
2940 * src/truetype/ttinterp.c (Normalize): Scale short vectors by 0x4000.
2942 2013-01-12 Alexei Podtelezhnikov <apodtele@gmail.com>
2944 [truetype] Kill very old vector normalization hacks.
2946 Back in the days, vector length calculations were not very accurate
2947 and the vector normalization function, Normalize, had to meticulously
2948 correct the errors for long vectors [commit b7ef2b096867]. It was no
2949 longer necessary after accurate CORDIC algorithms were adopted, but
2950 the code remained. It is time to kill it.
2952 * src/truetype/ttinterp.c (Normalize): Remove error compensation.
2953 (TT_VecLen): Remove any mention of old less accurate implementation.
2955 2013-01-11 Werner Lemberg <wl@gnu.org>
2957 Disable FT_CONFIG_OPTION_OLD_INTERNALS.
2959 After the next release we are going to remove the code completely.
2961 * devel/ftoption.h, include/freetype/config/ftoption.h
2962 (FT_CONFIG_OPTION_OLD_INTERNALS): Comment out.
2963 * docs/CHANGES: Document it.
2965 2013-01-10 Alexei Podtelezhnikov <apodtele@gmail.com>
2967 [base] Update the overflow protection bit.
2969 The recent optimizations of CORDIC iterations drastically reduce the
2970 expansion factor. Vector components with MSB of 29 are now safe
2973 * src/base/fttrigon.c (FT_TRIG_SAFE_MSB): New macro.
2974 (ft_trig_prenorm): Use it and remove dead code.
2976 2013-01-09 Alexei Podtelezhnikov <apodtele@gmail.com>
2978 [base, pshinter] Use FT_ABS, FT_MIN, and FT_MAX for readability.
2980 * src/base/ftbbox.c: Updated.
2981 * src/base/ftobjs.c: Updated.
2982 * src/base/fttrigon.c: Updated.
2983 * src/pshinter/pshalgo.c: Updated.
2984 * src/pshinter/pshrec.c: Updated.
2986 2013-01-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2988 [base] Clean up trigonometric core.
2990 * src/base/fttrigon.c: Document the algorithm in a large comment.
2991 (FT_TRIG_COSCALE): Remove macro.
2992 (FT_Tan: Use `FT_TRIG_SCALE' instead.
2993 (FT_Cos, FT_Vector_Unit): Ditto and round the return values.
2995 2013-01-02 Alexei Podtelezhnikov <apodtele@gmail.com>
2997 [base] Use rounding in CORDIC iterations.
2999 * src/base/fttrigon.c (ft_trig_pseudo_rotate,
3000 ft_trig_pseudo_polarize): Improve accuracy by rounding.
3002 2013-01-02 Alexei Podtelezhnikov <apodtele@gmail.com>
3004 [base] Reduce trigonometric algorithms.
3006 After we get within 45 degrees by means of true 90-degree rotations,
3007 we can remove initial 45-degree CORDIC iteration and start from
3008 atan(1/2) pseudorotation, reducing expansion factor thereby.
3010 * src/base/fttrigon.c (FT_TRIG_SCALE, FT_TRIG_COSCALE): Update macros.
3011 (ft_trig_pseudo_rotate, ft_trig_pseudo_polarize): Update.
3013 * src/tools/cordic.py: Bring up to date with trigonometric core.
3015 * docs/CHANGES: Old typo.
3017 2013-01-02 Alexei Podtelezhnikov <apodtele@gmail.com>
3019 * src/pshinter/pshalgo.h: Remove unused code.
3021 2012-12-27 Werner Lemberg <wl@gnu.org>
3023 * src/truetype/ttgload.c (tt_loader_init): Add more tracing.
3025 2012-12-23 Werner Lemberg <wl@gnu.org>
3027 [type1] Fix handling of /FontBBox in MM fonts.
3028 Problem reported by Del Merritt <del@alum.mit.edu>
3032 /FontBBox { { 11 12 13 14 15 16 17 18 }
3033 { 21 22 23 24 25 26 27 28 }
3034 { 31 32 33 34 35 36 37 38 }
3035 { 41 42 43 44 45 46 47 48 } }
3037 in the /Blend dictionary, then the first BBox is { 11 21 31 41 },
3038 the second { 12 22 32 42 }, etc.
3040 * include/freetype/internal/psaux.h (T1_FieldType): Add
3041 `T1_FIELD_TYPE_MM_BBOX' (for temporary use).
3043 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
3046 2012-12-21 Alexei Podtelezhnikov <apodtele@gmail.com>
3048 * src/tools/cordic.py: Bring up to date with trigonometric core.
3050 2012-12-21 Werner Lemberg <wl@gnu.org>
3052 Check parameters of `FT_Outline_New'.
3053 Problem reported by Robin Watts <robin.watts@artifex.com>.
3055 * src/base/ftoutln.c (FT_Outline_New_Internal): Ensure that
3056 `numContours' and `numPoints' fit into FT_Outline's `n_points' and
3057 `n_contours', respectively.
3059 2012-12-20 Werner Lemberg <wl@gnu.org>
3061 * Version 2.4.11 released.
3062 ==========================
3065 Tag sources with `VER-2-4-11'.
3067 * docs/CHANGES, docs/release: Updated.
3069 * docs/VERSION.DLL: Update documentation and bump version number to
3072 * README, Jamfile (RefDoc),
3073 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
3074 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
3075 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
3076 builds/win32/visualc/freetype.dsp,
3077 builds/win32/visualc/freetype.vcproj,
3078 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
3079 builds/win32/visualce/freetype.vcproj,
3080 builds/win32/visualce/index.html,
3081 builds/wince/vc2005-ce/freetype.vcproj,
3082 builds/wince/vc2005-ce/index.html,
3083 builds/wince/vc2008-ce/freetype.vcproj,
3084 builds/wince/vc2008-ce/index.html: s/2.4.10/2.4.11/, s/2410/2411/.
3086 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 11.
3088 * builds/unix/configure.raw (version_info): Set to 16:0:10.
3090 * builds/toplevel.mk (dist): Don't include `.mailmap'.
3092 2012-12-20 Alexei Podtelezhnikov <apodtele@gmail.com>
3094 [base] Improve trigonometric core.
3096 FreeType used to rely on a 24-step iteration CORDIC algorithm to
3097 calculate trigonometric functions and rotate vectors. It turns out
3098 that once the vector is in the right half-plane, the initial rotation
3099 by 63 degrees is not necessary. The algorithm is perfectly capable
3100 to converge to any angle starting from the second 45 degree rotation.
3101 This patch removes the first rotation and makes it a 23-step CORDIC
3104 * src/base/fttrigon.c (FT_TRIG_SCALE, FT_TRIG_COSCALE): Update macro
3106 (ft_trig_pseudo_rotate, ft_trig_pseudo_polarize): Remove initial
3109 2012-12-19 Werner Lemberg <wl@gnu.org>
3111 * src/base/ftobjs.c (ft_property_do): Fix compiler warning.
3113 2012-12-19 Alexei Podtelezhnikov <apodtele@gmail.com>
3115 * src/base/ftrfork.c (FT_Raccess_Guess): Switch to FT_Int counters.
3117 2012-12-19 Alexei Podtelezhnikov <apodtele@gmail.com>
3119 [base] Clean up trigonometric core.
3121 * src/base/fttrrigon.c (ft_trig_pseudo_polarize): Align algorithm
3122 with `ft_trig_pseudo_rotate'.
3124 2012-12-18 Infinality <infinality@infinality.net>
3126 [truetype] Minor performance enhancement.
3128 * src/truetype/ttgload.c: (TT_Process_Simple_Glyph): Use FT_MulFix
3129 instead of FT_MulDiv.
3131 2012-12-17 Infinality <infinality@infinality.net>
3133 [truetype] Remove unusued code and variables.
3135 * src/truetype/ttinterp.c: Updated.
3136 (Ins_FDEF): Remove opcode patterns that are not being used.
3138 2012-12-16 Werner Lemberg <wl@gnu.org>
3140 Various compiler warning fixes.
3142 * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Use
3143 `logical not' operator instead of negation. The idea is that `~'
3144 returns exactly the data type enforced by the cast to a pointer (be
3145 it 32bit or 64bit or whatever), while a negative integer has not
3147 * src/cache/ftccmap.c (FTC_CMAP_UNKNOWN): Ditto.
3148 * src/truetype/ttgxvar.c (ALL_POINTS, TT_Get_MM_Var): Ditto.
3149 * src/type/t1load.c (T1_Get_MM_Var): Ditto.
3150 (parse_blend_axis_types): Use cast.
3151 * src/bdf/bdflib.c (_bdf_readstream): Use cast.
3153 2012-12-16 Infinality <infinality@infinality.net>
3155 [truetype] Remove unusued code and variables. Add minor fixes.
3157 * src/truetype/ttsubpix.h: Updated.
3158 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Trebuchet MS.
3159 (ALLOW_X_DMOVEX_Rules): Remove Arial characters.
3160 (ALLOW_X_DMOVE_Rules): Remove Arial characters.
3161 (RASTERIZER_35_Rules): Verdana no longer needs to be here.
3162 (SKIP_IUP_Rules): Formatting fix.
3163 (DELTAP_SKIP_EXAGGERATED_VALUES_Rules): Remove Segoe UI.
3164 (COMPATIBLE_WIDTHS_Rules): Add Monaco and Trebuchet MS.
3165 (X_SCALING_Rules): Add misc. corrective fixes.
3167 * src/truetype/ttgload.c: (TT_Process_Simple_Glyph): Adjust correction
3168 factor for emboldening during scaling.
3170 * src/truetype/ttinterp.h: Updated.
3171 (TT_ExecContextRec): Remove unused variables.
3173 * src/truetype/ttobjs.h: Updated.
3174 (TT_SizeRec): Add ttfautohinted variable.
3176 * src/truetype/ttinterp.c: Updated.
3177 (Ins_FDEF): Rework code to fix bugs and add more detection.
3178 (Ins_CALL): Remove unused code.
3179 (Ins_LOOPCALL): Remove unused code.
3180 (TT_RunIns): Remove unusued code.
3181 (Ins_SHPIX): Add logic to handle ttfautohinted fonts.
3182 (Ins_MIRP): Don't round x in cut-in calculation. Add logic to handle
3183 ttfautohinted fonts.
3185 2012-12-16 Werner Lemberg <wl@gnu.org>
3187 [sfnt] Fix Savannah bug #37936.
3189 * src/sfnt/ttload.c (tt_face_load_gasp): Avoid memory leak.
3191 2012-12-15 Alexei Podtelezhnikov <apodtele@gmail.com>
3193 [base] Fix 11-year old bug.
3195 Since the initial commit (ebe85f59) the value of FT_TRIG_SCALE has
3196 always been slightly less than the correct value, which has been
3197 given in the comment as a hexadecimal. As a result, vector lengths
3198 were underestimated and rotated vectors were shortened.
3200 * src/base/fttrigon.c (FT_TRIG_SCALE): Fix macro value.
3202 2012-12-15 Werner Lemberg <wl@gnu.org>
3204 [bdf] Fix Savannah bug #37907.
3206 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Normalize
3207 negative second parameter of `ENCODING' field also.
3209 2012-12-15 Werner Lemberg <wl@gnu.org>
3211 [bdf] Fix Savannah bug #37906.
3213 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Use correct array
3214 size for checking `glyph_enc'.
3216 2012-12-15 Werner Lemberg <wl@gnu.org>
3218 [bdf] Fix Savannah bug #37905.
3220 * src/bdf/bdflib.c (_bdf_parse_start) <STARTPROPERTIES>: Reset
3221 `props_size' to zero in case of allocation error; this value gets
3222 used in a loop in `bdf_free_font'.
3224 2012-12-10 Alexei Podtelezhnikov <apodtele@gmail.com>
3226 [truetype] Scale F_dot_P down.
3228 The dot product between freeVector and projVector or cosine of
3229 the angle between these FT_F2Dot14 unit vectors used to be scaled up
3230 by 4 and routinely occupied 32 bits in an FT_Long field F_dot_P.
3231 This patch scales the value down by 2^14 instead, which simplifies
3232 its use throughout the bytecode interpreter.
3234 This does not lead to the loss of precision because the lower bits
3235 are unreliable anyway. Consider two unit vectors (1,0) and (.6,.8)
3236 for which the true value of F_dot_P is .6 * 0x40000000 = 0x26666666.
3237 These vectors are stored as (0x4000,0) and (0x2666,0x3333) after
3238 rounding and F_dot_P is assigned 0x26660000. The lower bits were
3239 already lost while rounding the unit vector components.
3241 Besides code simplification, this change can lead to better
3242 performance when FT_MulDiv with the scaled-down F_dot_P is less
3243 likely to use the costly 64-bit path. We are not changing the type
3244 of F_dot_P to FT_F2Dot14 at this point.
3246 * src/truetype/ttinterp.c (Compute_Funcs): Scale F_dot_P down by 14
3247 bits and modify its use accordingly.
3248 (Direct_Move, Direct_Move_Orig, Compute_Point_Displacement): Modify
3249 the use of F_dot_P field.
3250 * src/truetype/ttobjs.c (tt_size_run_fpgm): Change arbitrary
3251 assignment of F_dot_P to its theoretical maximum in case we decide
3252 to scale back its type later.
3254 2012-12-09 Johnson Y. Yan <yinsen_yan@foxitsoftware.com>
3256 [type1] Another fix for 2012-09-17 commit.
3258 * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Correctly set
3261 2012-12-06 Alexei Podtelezhnikov <apodtele@gmail.com>
3263 [truetype] Tweak the previous commit.
3265 * src/truetype/ttinterp.c (Current_Ratio): Put unit vector
3266 components as the second TT_MulFix14 arguments. This is required
3269 2012-12-06 Alexei Podtelezhnikov <apodtele@gmail.com>
3271 [truetype] Microoptimizations in bytecode interpreter.
3273 * src/truetype/ttinterp.c (TT_DivFix14): New macro.
3274 (Normalize): Use it here.
3275 (Current_Ratio): Use TT_MulFix14 instead of FT_MulDiv.
3276 (Ins_SHPIX): Cancel out two TT_MulFix14 calls.
3278 2012-12-05 Alexei Podtelezhnikov <apodtele@gmail.com>
3280 [truetype] Cosmetic improvement in bytecode interpreter.
3282 * src/truetype/ttinterp.c: Use explicit calls to FT_MulDiv,
3283 FT_MulFix, and FT_DivFix instead of macros.
3285 2012-12-03 John Tytgat <John.Tytgat@esko.com>
3287 [pshinter] Clamp BlueScale value.
3289 This is Savannah bug #37856.
3291 * src/pshinter/pshglob.c (psh_calc_max_height): New function.
3292 (psh_globals_new): Use it to limit BlueScale value to
3293 `1 / max_of_blue_zone_heights'.
3295 2012-12-01 Alexei Podtelezhnikov <apodtele@gmail.com>
3297 [truetype, type1] Revise the use of FT_MulDiv.
3299 * src/truetype/ttgxvar.c: Updated.
3300 * src/truetype/ttobjs.c: Updated.
3301 * src/type1/t1load.c: Updated.
3303 2012-11-30 Werner Lemberg <wl@gnu.org>
3305 [configure] Preserve customized `ftoption.h'.
3307 Problem reported by Del Merritt <del@alum.mit.edu>.
3309 * builds/unix/configure.raw <cpp computation of bit length>: Don't
3310 remove existing FreeType configuration files.
3312 2012-11-29 John Tytgat <John.Tytgat@esko.com>
3314 [type1] Fix Savannah bug #37831.
3316 The bug report also contains a patch.
3318 * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Really fix
3319 change from 2012-09-17.
3321 2012-11-28 Alexei Podtelezhnikov <apodtele@gmail.com>
3323 [truetype] Fix formatting and typo.
3325 2012-11-27 Alexei Podtelezhnikov <apodtele@gmail.com>
3327 [cid, type1, type42] Clean up units_per_EM calculations.
3329 * src/cid/cidload.c (cid_parse_font_matrix): Updated.
3330 * src/type1/t1load.c (t1_parse_font_matrix): Updated.
3331 * src/type42/t42parse.c (t42_parse_font_matrix): Updated.
3333 2012-11-27 Alexei Podtelezhnikov <apodtele@gmail.com>
3335 [ftstroke] Minor improvement.
3337 * src/base/ftstroke.c: Replace nested FT_DivFix and FT_MulFix with
3340 2012-11-17 Werner Lemberg <wl@gnu.org>
3342 * src/base/fttrigon.c (ft_trig_downscale): Make 64bit version work.
3344 2012-11-15 Alexei Podtelezhnikov <apodtele@gmail.com>
3346 [base] Fix integer overflows in dd5718c7d67a.
3348 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Use FT_MulDiv.
3350 2012-11-15 Werner Lemberg <wl@gnu.org>
3352 [autofit] Trace stem widths.
3354 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Add some
3357 2012-11-13 Werner Lemberg <wl@gnu.org>
3359 [cff] Add support for OpenType Collections (OTC).
3361 * src/cff/cffload.c (cff_font_load): Separate subfont and face
3362 index handling to load both pure CFFs with multiple subfonts and
3363 OTCs (with multiple faces where each face holds exactly one
3365 * src/cff/cffobjs.c (cff_face_init): Updated.
3367 2012-11-12 Werner Lemberg <wl@gnu.org>
3369 [autofit] Minor improvement.
3371 * src/autofit/aflatin.c (af_latin_hints_compute_blue_edges): Fix
3374 2012-11-10 Werner Lemberg <wl@gnu.org>
3376 [autofit] Improve tracing.
3378 * src/autofit/aflatin.c (af_latin_hint_edges)
3379 [FT_DEBUG_LEVEL_TRACE]: Count number of actions and emit something
3380 if there weren't any.
3382 2012-11-04 Alexei Podtelezhnikov <apodtele@gmail.com>
3384 [base] Fortify emboldening code against egregious distortions.
3386 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Threshold emboldening
3387 strength when it leads to segment collapse.
3389 2012-11-03 Alexei Podtelezhnikov <apodtele@gmail.com>
3391 [base] Clean up emboldening code and improve comments there.
3393 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Replace sequential
3394 calls to FT_MulFix and FT_DivFix with FT_MulDiv.
3395 Mention that bisectors are used to figure out the shift direction.
3397 2012-10-24 Werner Lemberg <wl@gnu.org>
3399 [autofit] Add standard character to `AF_ScriptClassRec' structure.
3401 * src/autofit/aftypes.h (AF_ScriptClassRec): Add `standard_char'
3403 (AF_DEFINE_SCRIPT_CLASS): Updated.
3405 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Use it.
3406 (af_latin_metrics_init, af_latin_script_class): Updated.
3408 * src/autofit/aflatin.c (af_latin2_metrics_init_widths): Use it.
3409 (af_latin2_metrics_init, af_latin2_script_class): Updated.
3411 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Use it.
3412 (af_cjk_metrics_init, af_cjk_script_class): Updated.
3414 * src/autofit/afindic.c (af_indic_metrics_init,
3415 af_indic_script_class): Updated.
3417 * src/autofit/afcjk.h, src/autofit/aflatin.h: Updated.
3419 * src/autofit/afdummy.c: Updated.
3421 2012-10-24 Werner Lemberg <wl@gnu.org>
3423 [autofit] Only use Unicode CMap.
3425 * src/autofit/aflatin.c (af_latin_metrics_init): Implement it, to be
3426 in sync with `af_face_globals_compute_script_coverage'.
3428 2012-10-21 Werner Lemberg <wl@gnu.org>
3430 [psaux] Improve parsing of invalid numbers.
3432 * src/psaux/psconv.c (PS_Conv_Strtol): Always parse complete number,
3433 even in case of overflow.
3434 (PS_Conv_ToInt): Only increase cursor if parsing was successful.
3435 (PS_Conv_ToFixed): Ditto.
3436 Trace underflow and data error.
3438 2012-10-21 Werner Lemberg <wl@gnu.org>
3440 [smooth] Improve tracing.
3442 * src/smooth/ftgrays.c (gray_sweep): Trace last sweep line of
3445 2012-10-20 Alexei Podtelezhnikov <apodtele@gmail.com>
3447 [truetype] Cheaper way to threshold angles between vectors.
3449 * src/truetype/ttinterp.c (Ins_ISECT): Thresholding tangent is a lot
3450 cheaper than thresholding sine.
3452 2012-10-20 Werner Lemberg <wl@gnu.org>
3454 [cff] Improve parsing of invalid real numbers.
3456 * src/cff/cffparse.c (cff_parse_real): Always parse complete number,
3457 even in case of overflow or underflow.
3458 Also trace one more underflow.
3460 2012-10-20 Andreas Pehnack <andreas.pehnack@me.com>
3462 [sfnt] Load pure CFF fonts wrapped in SFNT container.
3464 Such fonts only have a `cmap' and a `CFF' table.
3466 * src/sfnt/ttload.c (tt_face_load_font_dir): Don't call
3467 `check_table_dir' if font signature is `OTTO'.
3469 2012-10-20 Werner Lemberg <wl@gnu.org>
3471 [psaux] Fix some value overflows and improve tracing.
3473 * src/psaux/psconv.c: Include FT_INTERNAL_DEBUG_H.
3474 (FT_COMPONENT): Define.
3475 (PS_Conv_Strtol): Return FT_Long.
3476 Handle bad data and overflow.
3477 Emit some tracing messages in case of error.
3478 (PS_Conv_ToInt): Return FT_Long.
3479 (PS_Conv_ToFixed): Updated.
3480 * src/psaux/psconv.h: Updated.
3482 * include/freetype/internal/fttrace.h: Add `psconv'.
3484 2012-10-20 Werner Lemberg <wl@gnu.org>
3486 [autofit] Fix `make multi CC=c++'.
3488 * src/autofit/aflatin.c, src/autofit/aflatin2.c: Include
3490 * src/autofit/afloader.c: Fix order of header files.
3491 * src/autofit/afmodule.c: Include `afglobal.h' and `aferrors.h'.
3493 2012-10-19 Werner Lemberg <wl@gnu.org>
3495 [cff] Fix more value errors and improve tracing.
3497 * src/cff/cffparse.c (cff_parse_integer): Emit tracing message in
3499 (cff_parse_real): Handle and trace overflow, underflow, and bad data
3501 (do_fixed): New helper function, handling and tracing overflow.
3502 (cff_parse_fixed, cff_parse_fixed_scaled): Use `do_fixed'.
3504 2012-10-17 Werner Lemberg <wl@gnu.org>
3506 [psaux] Fix some value overflows.
3508 * src/psaux/psconv.c (PS_Conv_ToFixed): Implement it.
3510 2012-10-17 Bram Tassyns <BramT@enfocus.com>
3512 [cff] Fix value overflow.
3514 * src/cff/cffparse.c (cff_parse_fixed_scaled): Implement it.
3516 2012-10-17 Werner Lemberg <wl@gnu.org>
3518 [truetype] Fix Savannah bug #37572.
3520 * src/truetype/ttinterp.c (Ins_ISECT): Use angle between vectors to
3521 avoid grazing intersections. The previous threshold was too coarse,
3522 incorrectly rejecting short but valid vectors.
3524 2012-09-30 Gilles Espinasse <g.esp@free.fr>
3526 Remove useless `rm' detection.
3528 `rm -f' is directly used in the `configure' script created by
3529 autoconf, thus no availability test is necessary.
3531 * builds/unix/configure.raw (RMF): Remove test.
3532 * builds/unix/unix-def.in (DELETE): Updated.
3534 2012-09-29 Werner Lemberg <wl@gnu.org>
3536 [autofit] Minor optimization.
3538 * src/autofit/afglobals.c (af_face_globals_compute_script_coverage):
3541 2012-09-29 Werner Lemberg <wl@gnu.org>
3543 [autofit] Fix thinko.
3545 * src/autofit/aftypes.h (AF_SCRIPT):
3546 s/AF_SCRIPT_NONE/AF_SCRIPT_DUMMY/. We already use `AF_SCRIPT_NONE'
3549 * src/autofit/afdummy.c: Updated.
3551 2012-09-18 Werner Lemberg <wl@gnu.org>
3553 [autofit] Implement `increase-x-height' property.
3555 * include/freetype/ftautoh.h (FT_Prop_IncreaseXHeight): New
3558 * include/autofit/afmodule.c (af_property_get_face_globals): New
3559 function, re-using code from `af_property_get'.
3560 (af_property_set, af_property_get): Handle `increase-x-height'.
3563 2012-09-18 Werner Lemberg <wl@gnu.org>
3565 [autofit] Implement Infinality's `increase glyph heights'.
3567 This is an improved version of a similar fix contained in the
3568 so-called `Infinality patch', taken from
3570 http://www.infinality.net/fedora/linux/zips/freetype-infinality-2.4.10-20120616_01-x86_64.tar.bz2
3572 which addresses various enhancements of the auto-hinter. Without
3573 properties to control a module's metadata it wasn't possible to
3574 adapt the patches because everything was originally controlled by
3575 environment variables which I consider not suitable in general.
3577 A patch to control `increase_x_height' follows.
3579 * src/autofit/afglobal.h (AF_PROP_INCREASE_X_HEIGHT_MIN,
3580 AF_PROP_INCREASE_X_HEIGHT_MAX): New macros.
3581 (AF_FaceGlobalsRec): Add `increase_x_height' member.
3582 * src/autofit/afglobal.c (af_face_globals_new): Initialize it.
3584 * src/autofit/aflatin.c (af_latin_metrics_scale_dim),
3585 * src/autofit/aflatin2.c (af_latin2_metrics_scale_dim): Implement
3586 handling of `increase_x_height'.
3588 2012-09-18 Werner Lemberg <wl@gnu.org>
3590 [autofit] Add hierarchical property access to some structures.
3592 * src/autofit/afglobal.h: Include `afmodule.h'.
3593 (AF_FaceGlobalsRec): Add `module' member.
3594 (AF_FaceGlobals): Typedef moved to...
3595 * src/autofit/aftypes.h: Here.
3596 (AF_ScriptMetricsRec): Add `globals' member.
3598 * src/autofit/afglobal.c (af_face_globals_new,
3599 af_face_globals_compute_script_coverage,
3600 af_face_globals_get_metrics): Updated.
3602 * src/autofit/afloader.c (af_loader_reset), src/autofit/afmodule.c
3603 (af_property_get): Updated.
3605 2012-09-17 Werner Lemberg <wl@gnu.org>
3607 [type1] Fix Savannah bug #37350.
3609 * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Check for ASCII
3610 storage only if we actually have at least four bytes.
3612 2012-09-15 Werner Lemberg <wl@gnu.org>
3614 [autofit] Implement `fallback-script' property.
3616 * src/autofit/afglobal.c: s/default_script/fallback_script/.
3617 * src/autofit/afglobal.h: s/AF_SCRIPT_DEFAULT/AF_SCRIPT_FALLBACK/.
3619 * src/autofit/afmodule.c: s/default_script/fallback_script/.
3620 (af_property_set, af_property_get): Implement `fallback-script'.
3621 * src/autofit/afmodule.h: s/default_script/fallback_script/.
3623 * include/freetype/ftautoh.h: Document it.
3625 2012-09-15 Werner Lemberg <wl@gnu.org>
3627 [autofit] Correct previous Unicode 6.1.0 change.
3629 The auto-hinter's latin module only handles latin ligatures in the
3630 `Alphabetical Presentation Forms' block.
3632 * src/autofit/aflatin.c (af_latin_uniranges): Fix it.
3634 2012-09-15 Werner Lemberg <wl@gnu.org>
3636 * src/autofit/afmodule.c: s/FT_Err_/AF_Err_/.
3638 2012-09-15 Werner Lemberg <wl@gnu.org>
3640 [autofit] Make default script a global property.
3642 * src/autofit/afmodule.h (AF_ModuleRec): Add `default_script' field.
3644 * src/autofit/afglobal.c (af_face_globals_compute_script_coverage,
3645 af_face_globals_new), src/autofit/afloader.c (af_loader_reset),
3646 src/autofit/afmodule.c (af_property_get) <glyph-to-script-map>,
3648 Handle default script.
3650 * src/autofit/afglobal.h: Updated.
3652 2012-09-15 Werner Lemberg <wl@gnu.org>
3654 Use `FT_Module' instead of `FT_Library' argument in property funcs.
3656 This internal change simplifies access to global module data.
3658 * include/freetype/internal/services/svprop.h
3659 (FT_Properties_SetFunc, FT_Properties_GetFunc): Change accordingly.
3661 * src/base/ftobjs.c (ft_property_do), src/autofit/afmodule.c
3662 (af_property_set, af_property_get): Updated.
3664 2012-09-14 Werner Lemberg <wl@gnu.org>
3666 [autofit] Update to Unicode 6.1.0.
3668 * src/autofit/afcjk.c (af_cjk_uniranges), src/autofit/aflatin.c
3669 (af_latin_uniranges): Add and fix ranges.
3671 2012-09-14 Werner Lemberg <wl@gnu.org>
3673 [autofit] Pass `AF_Module' instead of `AF_Loader'.
3675 We want to access the (not yet existing) module's global data later
3678 * src/autofit/afloader.c: Include `afmodule.h'.
3679 (af_loader_init, af_loader_reset, af_loader_done,
3680 af_loader_load_glyph): Change accordingly.
3681 * src/autofit/afmodule.c (AF_ModuleRec): Move to `afmodule.h'.
3684 * src/autofit/afmodule.h: Include `afloader.h'.
3685 (AF_ModuleRec): Define here.
3686 * src/autofit/afloader.h (AF_Module): Define here.
3689 2012-09-14 Werner Lemberg <wl@gnu.org>
3691 [autofit] Fix `make multi'.
3693 * include/freetype/internal/fttrace.h: Add `afmodule'.
3694 * src/autofit/afmodule.c: Include FT_INTERNAL_DEBUG_H.
3695 (FT_COMPONENT): Define.
3697 2012-09-14 Werner Lemberg <wl@gnu.org>
3699 * src/autofit/afmodule.c: s/FT_Autofitter/AF_Module/.
3701 2012-09-12 Werner Lemberg <wl@gnu.org>
3703 [autofit] Minor reorganization.
3705 * src/autofit/afglobal.c (AF_SCRIPT_LIST_DEFAULT,
3706 AF_SCRIPT_LIST_NONE, AF_DIGIT): Move to...
3707 * src/autofit/afglobal.h (AF_SCRIPT_DEFAULT, AF_SCRIPT_LIST_NONE,
3708 AF_DIGIT): This and update code.
3710 2012-09-01 Werner Lemberg <wl@gnu.org>
3712 [autofit] Implement `glyph-to-script-map' property.
3714 * include/freetype/ftautoh.h: New public header file.
3715 * include/freetype/config/ftheader.h (FT_AUTOHINTER_H): New macro.
3717 * src/autofit/afglobal.c (AF_FaceGlobalsRec): Move structure to...
3718 * src/autofit/afglobal.h: This header file.
3719 * src/autofit/afmodule.c: Include FT_AUTOHINTER_H.
3720 (af_property_get): Handle `glyph-to-script-map'.
3722 2012-08-31 Werner Lemberg <wl@gnu.org>
3724 [autofit] Implement properties service framework.
3726 No properties are added yet.
3728 * src/autofit/afmodule.c: Include FT_SERVICE_PROPERTIES_H.
3729 (af_property_set, af_property_get): New dummy functions.
3730 (af_service_properties, af_services, af_get_interface): Provide
3732 (autofit_moduleclass): Add service interface.
3734 * src/autofit/afpic.c: Add necessary forward declarations.
3735 (autofit_module_class_pic_init): Add code for service addition.
3736 (autofit_module_pic_free): Add code for service removal.
3737 * src/autofit/afpic.h (AF_SERVICES_GET, AF_SERVICE_PROPERTIES_GET):
3738 New macros which provide necessary syntactical sugar for PIC
3741 2012-08-30 Werner Lemberg <wl@gnu.org>
3743 Implement properties to control FreeType modules.
3745 * include/freetype/fterrdef.h (FT_Err_Missing_Property): New error
3747 * include/freetype/ftmodapi.h (FT_Property_Set, FT_Property_Get):
3750 * include/freetype/internal/services/svprop.h: New file.
3751 * include/freetype/internal/ftserv.h (FT_SERVICE_PROPERTIES_H): New
3754 * src/base/ftobjs.c: Include FT_SERVICE_PROPERTIES_H.
3755 (ft_property_do, FT_Property_Set, FT_Property_Get): New functions.
3757 2012-08-29 Werner Lemberg <wl@gnu.org>
3759 [docmaker] Allow `-' in tags and identifiers.
3761 * src/tools/docmaker/content.py (re_identifier),
3762 src/tools/docmaker/sources.py (re_markup_tag1, re_markup_tag2,
3763 re_crossref): Add `-' in patterns.
3765 2012-08-27 Werner Lemberg <wl@gnu.org>
3767 [FT_CONFIG_OPTION_PIC] Fix g++ 4.6.2 compiler warnings.
3769 * include/freetype/internal/ftdriver.h (FT_DEFINE_DRIVER),
3770 include/freetype/internal/ftobjs.h (FT_DEFINE_RENDERER,
3771 FT_DEFINE_MODULE), include/freetype/internal/ftserv.h
3772 (FT_DEFINE_SERVICEDESCREC1, FT_DEFINE_SERVICEDESCREC2,
3773 FT_DEFINE_SERVICEDESCREC3, FT_DEFINE_SERVICEDESCREC4,
3774 FT_DEFINE_SERVICEDESCREC5, FT_DEFINE_SERVICEDESCREC6),
3775 src/autofit/afpic.c (autofit_module_class_pic_init),
3776 src/base/basepic.c (ft_base_pic_init), src/base/ftinit.c
3777 (ft_create_default_module_classes), src/cff/cffparse.c
3778 (FT_Create_Class_cff_field_handlers), src/cff/cffpic.c
3779 (cff_driver_class_pic_init), src/pshinter/pshpic.c
3780 (pshinter_module_class_pic_init), src/psnames/pspic.c
3781 (psnames_module_class_pic_init), src/raster/rastpic.c
3782 (ft_raster1_renderer_class_pic_init), src/sfnt/sfntpic.c
3783 (sfnt_module_class_pic_init), src/sfnt/ttcmap.c
3784 (FT_Create_Class_tt_cmap_classes), src/smooth/ftspic.c
3785 (ft_smooth_renderer_class_pic_init), src/truetype/ttpic.c
3786 (tt_driver_class_pic_init): Initialize allocation variable.
3788 2012-08-27 Werner Lemberg <wl@gnu.org>
3790 [truetype] Fix compilation warning.
3792 * src/truetype/ttgload.c (IS_HINTED): Move macro to...
3793 * src/truetype/ttobjs.h: This header file.
3795 2012-08-27 Werner Lemberg <wl@gnu.org>
3797 [autofit, cff, pshinter, psnames] More renamings for orthogonality.
3799 * src/autofit/afmodule.c, src/autofit/afpic.h:
3800 s/AF_AUTOFITTER_/AF_/.
3802 * src/cff/cffdrivr.c, src/cff/cffobjs.c, src/cff/cffparse.c,
3803 src/cff/cffpic.h: s/FT_CFF_/CFF_/.
3805 * src/pshinter/pshmod.c, src/pshinter/pshpic.h:
3806 s/FT_PSHINTER_/PSHINTER_/.
3808 * src/psnames/psmodule.c, src/psnames/pspic.h:
3809 s/FT_PSCMAPS/PSCMAPS_/.
3811 2012-08-27 Werner Lemberg <wl@gnu.org>
3813 [sfnt, truetype] More renamings for orthogonality.
3815 * src/sfnt/sfdriver.c, src/sfnt/sfntpic.h, src/sfnt/ttcmap.c,
3816 src/truetype/ttdriver.c, src/truetype/ttpic.h: s/FT_SFNT_/SFNT_/,
3817 s/FT_TT_/TT_/, s/GET_CMAP_INFO_GET/CMAP_INFO_GET/.
3819 2012-08-27 Werner Lemberg <wl@gnu.org>
3821 [autofit] Some macro and variable renamings for orthogonality.
3823 * include/freetype/internal/autohint.h, src/base/ftobjs.c,
3824 src/autofit/afmodule.c, src/autofit/afpic.c, src/autofit/afpic.h:
3825 s/SERVICE/INTERFACE/, s/service/interface/, s/Service/Interface/.
3827 2012-08-26 Werner Lemberg <wl@gnu.org>
3829 Fix Savannah bug #37178.
3831 * src/base/ftobjs.c (FT_Open_Face): Initialize `error' with
3832 `FT_Err_Missing_Module' before loop to indicate `no valid drivers'.
3834 2012-08-17 Werner Lemberg <wl@gnu.org>
3836 * src/base/ftsynth.c (FT_GlyphSlot_Oblique): Fix shear angle.
3838 The old value was far too large (more than 20°). The new one
3839 corresponds to 12°, quite common in typography.
3841 2012-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
3843 [smooth] Fix Savannah bug #37017.
3845 * src/smooth/ftgrays.c (gray_render_cubic): Use a different set of
3846 checks when detecting super curvy splines to be split.
3848 2012-08-05 Werner Lemberg <wl@gnu.org>
3850 [autofit] Improve recognition of flat segments.
3852 Problem reported by Brad Dunzer <BDunzer@extensis.com>.
3854 * src/autofit/aflatin.c (af_latin_metrics_init_blues): We have
3855 a flat segment if the horizontal distance of best on-points is
3856 larger than a given threshold.
3858 2012-08-05 Werner Lemberg <wl@gnu.org>
3860 [autofit] Variable renamings.
3862 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Replace
3863 `glyph' with `outline'.
3864 s/best_first/best_contour_first/.
3865 s/best_last/best_contour_last/.
3867 2012-07-31 Werner Lemberg <wl@gnu.org>
3869 [type1] Fix Savannah bug #37000.
3871 * src/type1/t1load.c (parse_encoding): Fix order of checks.
3873 2012-07-17 Werner Lemberg <wl@gnu.org>
3875 [psaux] Fix Savannah bug #36833.
3877 * src/psaux/t1decode.c (t1operator_seac): `seac' is not a valid
3878 operator if we want metrics only.
3880 2012-07-16 Werner Lemberg <wl@gnu.org>
3882 [type1] Fix Savannah bug #36832.
3884 * src/type1/t1load.c (parse_charstrings): Reject negative number of
3887 2012-07-13 Werner Lemberg <wl@gnu.org>
3889 [type1] Fix Savannah bug #36829.
3891 * src/type1/t1load.c (parse_encoding): Check cursor position after
3892 call to T1_Skip_PS_Token.
3894 2012-07-12 Alexei Podtelezhnikov <apodtele@gmail.com>
3896 Revert the last commit 45337b07.
3898 * src/base/ftstroke.c (FT_Stroker_New): Revert the previous change.
3900 2012-07-11 Alexei Podtelezhnikov <apodtele@gmail.com>
3902 [ftstroke] Fix uninitialized return value.
3904 * src/base/ftstroke.c (FT_Stroker_New): Return FT_Err_Ok instead.
3906 2012-07-11 Werner Lemberg <wl@gnu.org>
3908 [smooth] Avoid memory leak in case of failure.
3910 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use flags to
3911 indicate what to clean up after finishing the function, with and
3914 2012-07-09 Werner Lemberg <wl@gnu.org>
3916 Fix compilation with MSVC 5.0.
3918 Problem reported by Peter Breitenlohner and Akira Kakuto.
3920 * include/freetype/config/ftstdlib.h (ft_setjmp): Updated.
3921 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Remove cast.
3923 2012-07-09 Werner Lemberg <wl@gnu.org>
3925 [autofit] Improve debugging messages; do some code cleanup.
3927 * src/autofit/aflatin.c (af_latin_align_linked_edge,
3928 af_latin_hint_edges): Synchronize with formatting used in the
3929 ttfautohint project.
3931 2012-07-07 Gilles Espinasse <g.esp@free.fr>
3933 Fix strict-aliasing warning.
3935 * src/base/ftglyph.c (FT_Glyph_To_Bitmap): Avoid double cast.
3937 2012-07-07 Dave Thomas <dave.thomas@metaforic.com>
3939 [ARM] Fix FT_MulFix_arm.
3941 * include/freetype/config/ftconfig.h (FT_MulFix_arm) [__arm__]:
3942 Avoid ADDS instruction to clobber condition codes.
3944 2012-07-06 Werner Lemberg <wl@gnu.org>
3946 [autofit] Do some code cleanup.
3948 * src/autofit/afglobal.c (af_face_globals_new): Simplify.
3950 * src/autofit/afhints.c: Use `FT_TRACE7' instead of `printf'
3952 (FT_COMPONENT): New macro.
3953 (af_glyph_hints_done): Simplify.
3955 * include/freetype/internal/fttrace.h: Updated.
3957 2012-07-05 Werner Lemberg <wl@gnu.org>
3959 [autofit] Improve output of debugging information.
3961 * src/autofit/afhints.c (af_glyph_hints_dump_segments): Print more
3962 data; report no data.
3963 (af_glyph_hints_dump_edges): Report no data.
3965 2012-07-04 Werner Lemberg <wl@gnu.org>
3967 [autofit] Fix Savannah bug #36091.
3969 * src/autofit/aflatin.c (af_latin_metrics_init_blues),
3970 src/autofit/aflatin2.c (af_latin2_metrics_init_blues): Change the
3971 constraint for testing round vs. flat segment: Accept either a
3972 small distance or a small angle.
3974 2012-07-04 Werner Lemberg <wl@gnu.org>
3976 [autofit] Beautify blue zone tracing.
3978 * src/autofit/aflatin.c (af_latin_metrics_init_blues),
3979 src/autofit/aflatin2.c (af_latin2_metrics_init_blues): Implement it.
3981 2012-07-03 Werner Lemberg <wl@gnu.org>
3983 [autofit] Quantize stem widths.
3985 * src/autofit/afangles.c (af_sort_widths): Rename to...
3986 (af_sort_and_quantize_widths): This.
3987 Add code to avoid stem widths which are almost identical.
3988 * src/autofit/aftypes.h, src/autofit/aflatin.c, src/autofit/afcjk.c:
3991 2012-07-03 Werner Lemberg <wl@gnu.org>
3993 [autofit] Minor speed-up.
3995 * src/autofit/afangles (af_sort_pos, af_sort_widths): Don't swap
3996 elements if they are equal.
3998 2012-06-30 Gilles Espinasse <g.esp@free.fr>
4000 Fix `checking if gcc static flag -static works' test.
4002 On my linux build tree, I receive yes answer in in every package I
4003 build except freetype for this test checking if gcc static flag
4006 On freetype, no is received, unless bzip2 and zlib are disabled using
4008 ./configure --without-bzip2 --without-zlib
4010 The reason is that bzip2 and zlib tests add `-lz' and `-lbz2' to
4011 LDFLAGS and this broke static flag test.
4013 * builds/unix/configure.raw: Update CFLAGS and LDFLAGS only after
4016 2012-06-28 Infinality <infinality@infinality.net>
4018 [truetype] Fix various artifacts.
4020 Verdana was broken in the original Infinality commit. Also
4021 includes other minor fixes.
4023 * src/truetype/ttsubpix.h: Updated. Removed unused macros.
4024 (RASTERIZER_35_Rules): Add Verdana.
4025 (SKIP_NONPIXEL_Y_MOVES_Rules): Add Tahoma `s'.
4026 (MIRP_CVT_ZERO_Rules): Remove Verdana.
4027 (ALWAYS_SKIP_DELTAP_Rules): Add Russian char 0x438.
4028 (COMPATIBLE_WIDTHS_Rules): Rearrange some rules.
4029 (X_SCALING_Rules): Adjust Verdana `a' at 12 and 13 ppem.
4031 * src/truetype/ttsubpix.c: Updated.
4032 (sph_set_tweaks): Re-execute fpgm always.
4034 2012-06-28 Gilles Espinasse <g.esp@free.fr>
4036 Fix CFLAGS and LDFLAGS share configure test.
4038 * builds/unix/configure.raw: Fix typo.
4040 2012-06-28 Werner Lemberg <wl@gnu.org>
4042 [truetype] Set the `subpixel_positioned' flag unconditionally.
4044 This is how the code currently behaves.
4046 * src/truetype/ttgload.c (tt_loader_init): Do it.
4048 2012-06-27 Werner Lemberg <wl@gnu.org>
4050 Fix conditional compilation.
4052 * src/base/basepic.c: Use FT_CONFIG_OPTION_MAC_FONTS.
4054 2012-06-27 Werner Lemberg <wl@gnu.org>
4056 Fix conditional compilation.
4058 * include/freetype/internal/ftcalc.h (FT_MulDiv_No_Round): Don't
4059 enclose with `TT_USE_BYTECODE_INTERPRETER'; we now need the function
4062 * src/autofit/afcjk.h: Use AF_CONFIG_OPTION_CJK.
4064 * src/truetype/ttgload.c (tt_loader_init): Fix compiler warning.
4066 * src/truetype/ttinterp.c (Ins_MSIRP): Fix compiler warning.
4068 * src/truetype/ttinterp.h: Use
4069 TT_CONFIG_OPTION_BYTECODE_INTERPRETER.
4071 2012-06-26 Infinality <infinality@infinality.net>
4073 [truetype] Remove unused rounding functionality.
4075 The subpixel hinting patch contained the concept of an adjustable
4076 number of gridlines per pixel. This is no longer used due to x
4077 being completely ignored instead. This will return some of the
4078 code to its existing state prior to the original Infinality
4081 * include/freetype/internal/ftobjs.h (FT_PIX_FLOOR_GRID,
4082 FT_PIX_ROUND_GRID, FT_PIX_CEIL_GRID): Removed.
4084 * src/truetype/ttinterp.c: Updated.
4085 (Round_None, Round_To_Grid, Round_To_Half_Grid, Round_Down_To_Grid,
4086 Round_Up_To_Grid, Round_To_Double_Grid, Round_Super, Round_Super_45,
4087 SetSuperRound): Remove parameter to handle the number of grid lines per
4089 (SET_SuperRound, ROUND_None, CUR_Func_round): Updated.
4090 (DO_SROUND, DOS45ROUND, DO_ODD, DO_EVEN): Updated.
4091 (DO_ROUND, DO_NROUND): Updated.
4092 (Move_Zp2_Point, Ins_SHPIX, Ins_MSIRP, Ins_MDAP, Ins_MIAP,
4093 Ins_MDRP, Ins_MIRP): Perform Round_None instead of calling a modified
4094 rounding function. Remove gridlines_per_pixel. Create a local
4095 variable to store control value cutin. Simplify the conditional for
4096 ignore_x_mode. Adjust rounding calls to pass only two values.
4098 2012-06-25 Werner Lemberg <wl@gnu.org>
4100 [cff] Fix Savannah bug #36705.
4102 Handle numbers like 2.001 correctly.
4104 * src/cff/cffparse.c (cff_parse_real): Avoid negative values for
4107 2012-06-18 Infinality <infinality@infinality.net>
4109 [truetype] Support subpixel hinting.
4111 This is the large, famous `Infinality' patch to support ClearType
4112 bytecode which has been available from
4113 http://www.infinality.net/blog/ for some time, and which has been
4114 refined over the last years. While still experimental, it is now
4115 mature enough to be included directly into FreeType.
4117 Most of the code is based on the ClearType whitepaper written by
4120 http://www.microsoft.com/typography/cleartype/truetypecleartype.aspx
4122 which gives a detailed overview of the necessary changes to the
4123 Microsoft rasterizer so that older fonts are supported. However, a
4124 lot of details are still missing, and this patches provides a
4125 framework to easily handle rendering issues down to the glyph level
4128 Note that ClearType support is not completely implemented! In
4129 particular, full support for the options `compatible_widths',
4130 `symmetrical_smoothing, and `bgr' (via the GETINFO bytecode
4131 instruction) is missing.
4133 * src/truetype/ttsubpix.c: New file, providing code to handle
4134 `tweaks', this is, rules for certain glyphs in certain fonts
4135 (including wildcards) which need a special treatment.
4137 * src/truetype/ttsubpix.h: New file, holding the tweaking rules.
4139 * include/freetype/config/ftoption.h, src/devel/ftoption.h
4140 (TT_CONFIG_OPTION_SUBPIXEL_HINTING): New macro.
4142 * include/freetype/internal/ftobjs.h (FT_PIX_FLOOR_GRID,
4143 FT_PIX_ROUND_GRID, FT_PIX_CEIL_GRID): New macros.
4145 * src/truetype/truetype.c [TT_USE_BYTECODE_INTERPRETER]: Include
4148 * src/truetype/ttgload.c: Include `ttsubpix.h'.
4149 [All changes below are guarded by TT_CONFIG_OPTION_SUBPIXEL_HINTING.]
4151 (tt_get_metrics): Set tweak flags.
4152 (TT_Hint_Glyph): Call `FT_Outline_EmboldenXY' if necessary.
4153 (TT_Process_Simple_Glyph): Compensate emboldening if necessary.
4154 (compute_glyph_metrics): Handle `compatible widths' option.
4155 (tt_loader_init): Handle ClearType GETINFO information bits.
4157 * src/truetype/rules.mk (TT_DRC_SRC): Updated.
4159 * src/truetype/ttinterp.c: Include `ttsubpix.h'.
4160 [Where necessary, changes below are guarded by
4161 TT_CONFIG_OPTION_SUBPIXEL_HINTING.]
4163 (Direct_Move, Direct_Move_X): Extended.
4164 (Round_None, Round_To_Grid, Round_To_Half_Grid, Round_Down_To_Grid,
4165 Round_Up_To_Grid, Round_To_Double_Grid, Round_Super, Round_Super_45,
4166 SetSuperRound): Add parameter to handle the number of grid lines per
4168 (SET_SuperRound, ROUND_None, CUR_Func_round): Updated.
4169 (DO_SROUND, DOS45ROUND, DO_ODD, DO_EVEN): Updated.
4170 (DO_ROUND, DO_NROUND): Updated.
4171 (DO_RS): Take care of `Typeman' bytecode patterns.
4172 (Ins_FDEF): Add some debugging code. Commented out.
4173 (Ins_ENDF): Restore state.
4174 (Ins_CALL, Ins_LOOPCALL): Handle inline delta functions.
4175 (Ins_MD): Handle `Vacuform' rounds.
4176 (Move_Zp2_Point, Ins_SHPIX, Ins_MSIRP, Ins_MDAP, Ins_MIAP,
4177 Ins_MDRP, Ins_MIRP): Handle tweaks.
4178 (Ins_ALIGNRP): Add tweak guard.
4179 (Ins_IUP, Ins_DELTAP): Handle tweaks.
4180 (Ins_GETINFO): Handle new ClearType bits.
4181 (TT_RunIns): Handle tweaks.
4183 * src/truetype/ttinterp.h: Updated.
4184 (SPH_TweakRule, SPH_ScaleRule): New structures for tweaks.
4185 (TT_ExecContextRec): Add members for subpixel hinting support.
4187 * src/truetype/ttobjs.h (TT_DefRecord): Add `inline_delta' member.
4189 2012-06-15 Werner Lemberg <wl@gnu.org>
4191 * Version 2.4.10 released.
4192 =========================
4195 Tag sources with `VER-2-4-10'.
4197 * docs/VERSION.DLL: Update documentation and bump version number to
4200 * README, Jamfile (RefDoc),
4201 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
4202 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
4203 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
4204 builds/win32/visualc/freetype.dsp,
4205 builds/win32/visualc/freetype.vcproj,
4206 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
4207 builds/win32/visualce/freetype.vcproj,
4208 builds/win32/visualce/index.html,
4209 builds/wince/vc2005-ce/freetype.vcproj,
4210 builds/wince/vc2005-ce/index.html,
4211 builds/wince/vc2008-ce/freetype.vcproj,
4212 builds/wince/vc2008-ce/index.html: s/2.4.9/2.4.10/, s/249/2410/.
4214 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 10.
4216 * builds/unix/configure.raw (version_info): Set to 15:0:9.
4218 2012-06-15 Alexei Podtelezhnikov <apodtele@gmail.com>
4220 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Improve spacing.
4222 * docs/CHANGES: Updated.
4224 2012-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4226 * builds/exports.mk: Add CCexe_CFLAGS and CCexe_LDFLAGS.
4228 to pass special compiler/linker flags under cross development.
4229 Suggested by Savannah bug #36367.
4231 ChangeLog on 2010-07-15 saying as they were removed was wrong
4232 for the official trunk of FreeType2. This commit is the first
4233 introduction of them.
4235 2012-06-14 Werner Lemberg <wl@gnu.org>
4237 * docs/CHANGES: Updated.
4239 2012-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4241 [truetype] Add new versions of NEC FA family to tricky font list.
4243 NEC FA family dated in 1996 have different checksum.
4244 Reported by Johnson Y. Yan <yinsen_yan@foxitsoftware.com>; see
4246 http://lists.gnu.org/archive/html/freetype-devel/2012-06/msg00023.html
4248 * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids): 4 sets
4249 of fpgm & prep table checksums for FA-Gothic, FA-Minchou,
4250 FA-RoundedGothicM, FA-RoundedGothicB are added. The family
4251 names in sample PDF are truncated, thus the list of the
4252 family names in tt_check_trickyness_family() is not updated yet.
4254 2012-06-06 Werner Lemberg <wl@gnu.org>
4256 [ftraster] Fix rounding issue causing visual artifacts.
4258 Problem reported by jola <hans-jochen.lau@lhsystems.com>; see
4260 http://lists.gnu.org/archive/html/freetype-devel/2012-05/msg00036.html
4262 * src/raster/ftraster.c (SMulDiv_No_Round): New macro.
4264 * src/raster/ftmisc.h (FT_MulDiv_No_Round): Copied from `ftcalc.c'.
4266 2012-05-28 Alexei Podtelezhnikov <apodtele@gmail.com>
4268 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Simplify.
4270 We now use the cross product of the direction vectors to compute the
4271 outline's orientation.
4273 2012-05-28 Werner Lemberg <wl@gnu.org>
4275 * docs/CHANGES: Updated.
4277 2012-05-28 Alexei Podtelezhnikov <apodtele@gmail.com>
4279 New function FT_Outline_EmboldenXY.
4281 * include/freetype/ftoutln.h (FT_Outline_EmboldenXY): Define it.
4283 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Implement it, using a
4284 simplified embolding algorithm.
4285 (FT_Outline_Embolden): Make it a special case of
4286 `FT_Outline_EmboldenXY'
4288 2012-05-07 Werner Lemberg <wl@gnu.org>
4290 [type1] Fix Savannah bug #36386.
4292 * src/type1/t1load.c (t1_load_keyword): Ignore keyword if context is
4295 2012-04-07 Werner Lemberg <wl@gnu.org>
4297 Remove compiler warning.
4299 * src/truetype/ttgload.c (TT_Load_Glyph)
4300 [!TT_CONFIG_OPTION_EMBEDDED_BITMAPS]: Access `glyph->face' directly.
4302 2012-03-28 Werner Lemberg <wl@gnu.org>
4304 [autofit] Properly copy scaler flags to script metrics object.
4306 Without this patch, only the dummy and cjk autohinter modules get
4307 them (since they copy the whole scaler object).
4309 * src/autofit/aflatin.c (af_latin_metrics_scale),
4310 src/autofit/aflatin2.c (af_latin2_metrics_scale): Implement it.
4312 2012-03-22 Alexei Podtelezhnikov <apodtele@gmail.com>
4314 [bdflib] Remove redundant macro.
4316 * src/bdf/bdflib.c (isdigok): Remove and replace with sbitset, which
4317 is exactly the same.
4319 2012-03-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4321 [configure] Fix Savannah bug #35644.
4323 * builds/unix/configure.raw: Check `-ansi' flag works even if gcc
4324 is used. Bionic libc headers for Android lose the consistency
4325 when they are parsed with __STDC_VERSION__ older than 199901L or
4328 2012-03-20 Werner Lemberg <wl@gnu.org>
4330 [bdf] Improvement to Savannah bug #35656.
4332 * src/bdf/bdflib.c (isdigok): Add cast, as suggested in report.
4334 2012-03-17 Chris Liddell <chris.liddell@artifex.com>
4336 [type1] Fix Savannah bug #35847.
4338 * src/type1/t1load.c (parse_subrs): Fix the loop exit condition;
4339 we want to exit when we have run out of data.
4341 2012-03-16 Werner Lemberg <wl@gnu.org>
4343 [bdf] Really fix Savannah bug #35658.
4345 * src/bdf/bdflib.c (_bdf_list_split): Add one more `field' initializer.
4347 2012-03-14 Yann Droneaud <yann@droneaud.fr>
4349 [sfnt] Make arrays static like all others.
4351 * src/sfnt/ttload.c (tt_face_load_maxp, tt_face_load_os2),
4352 src/sfnt/ttmtx.c (tt_face_load_hhea): Add `static' keyword to frame
4355 2012-03-14 Huw Davies <huw@codeweavers.com>
4357 [sfnt] A refinement of the previous commit.
4359 * src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16,
4360 tt_name_entry_ascii_from_other): Stop at null byte.
4362 2012-03-14 Huw Davies <huw@codeweavers.com>
4364 [sfnt] Add `name' table compatibility to MS Windows.
4366 * src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16,
4367 tt_name_entry_ascii_from_other): Don't replace `\0' with question
4368 marks when converting strings.
4370 2012-03-14 Werner Lemberg <wl@gnu.org>
4372 [type1] Fix Savannah bug #35833.
4374 Based on the patch given in the bug report.
4376 * src/type1/t1load.c (IS_INCREMENTAL): New macro.
4377 (read_binary_data): Add parameter `incremental'.
4378 Update all callers using `IS_INCREMENTAL'.
4380 2012-03-11 Werner Lemberg <wl@gnu.org>
4382 [autofit] Return correct linear advance width values.
4384 This was quite a subtle bug which accidentally showed up with glyph
4385 `afii10023' of arial.ttf (version 2.76). This glyph is a composite;
4386 the first component, `E', has an advance width of 1366 font units,
4387 while the advance width of the composite itself (which looks like
4388 uppercase `E' with dieresis) is 1367 font units. I think this is
4389 actually a bug in the font itself, because there is no reason that
4390 this glyph has not the same width as uppercase `E' without the
4391 dieresis. Anyway, it helped identify this problem.
4393 Using the TrueType hinter, the correct value (1367) of `afii10023'
4394 was returned, but the autohinter mysteriously returned 1366.
4396 Digging in the code showed that the autohinter recursively calls
4397 FT_Load_Glyph to load the glyph, adding the FT_LOAD_NO_SCALE load
4398 flag. However, the `linearHoriAdvance' field is still returned as a
4399 scaled value. To avoid scaling twice, the old code in autofit reset
4400 `linearHoriAdvance', using the `horiAdvance' field. This seemed to
4401 work since FT_LOAD_NO_SCALE was in use, but it failed actually,
4402 because `horiAdvance' is defined as the distance of the first
4403 subglyph's phantom points, which in turn are initialized using the
4404 advance width of the first subglyph. And as the given example
4405 shows, these widths can differ.
4407 * src/autofit/afloader.c (af_loader_load_g): Temporarily set
4408 FT_LOAD_LINEAR_DESIGN while calling FT_Load_Glyph to get unscaled
4409 values for the linear advance widths.
4411 2012-03-10 Werner Lemberg <wl@gnu.org>
4413 [truetype] Fix SSW instruction.
4415 * src/truetype/ttinterp.c (DO_SSW): SSW *does* use font units. For
4416 verification, it took some time to find a font which actually uses
4419 2012-03-09 Vinnie Falco <vinnie.falco@gmail.com>
4421 Prepare source code for amalgamation.
4423 * include/freetype/freetype.h: Swap order of preprocessor blocks.
4425 2012-03-08 Werner Lemberg <wl@gnu.org>
4427 * Version 2.4.9 released.
4428 =========================
4431 Tag sources with `VER-2-4-9'.
4433 * docs/CHANGES: Updated.
4435 * docs/VERSION.DLL: Update documentation and bump version number to
4438 * README, Jamfile (RefDoc),
4439 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
4440 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
4441 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
4442 builds/win32/visualc/freetype.dsp,
4443 builds/win32/visualc/freetype.vcproj,
4444 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
4445 builds/win32/visualce/freetype.vcproj,
4446 builds/win32/visualce/index.html,
4447 builds/wince/vc2005-ce/freetype.vcproj,
4448 builds/wince/vc2005-ce/index.html,
4449 builds/wince/vc2008-ce/freetype.vcproj,
4450 builds/wince/vc2008-ce/index.html: s/2.4.8/2.4.9/, s/248/249/.
4452 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 9.
4454 * builds/unix/configure.raw (version_info): Set to 14:1:8.
4456 2012-03-08 Werner Lemberg <wl@gnu.org>
4458 [bdf] Add missing overflow check.
4460 * src/bdf/bdflib.c (_bdf_parse_glyphs) <BITMAP>: Add threshold for
4463 2012-03-07 Vinnie Falco <vinnie.falco@gmail.com>
4465 Prepare source code for amalgamation.
4467 * src/autofit/aferrors.h, src/bdf/bdferror.h, src/bzip2/ftbzip2.c,
4468 src/cache/ftcerror.h, src/cff/cfferrs.h, src/cid/ciderrs.h,
4469 src/gxvalid/gxverror.h, src/gzip/ftgzip.c, src/lzw/ftlzw.c,
4470 src/otvalid/otverror.h, src/pcf/pcferror.h, src/pfr/pfrerror.h,
4471 src/psaux/psauxerr.h, src/pshinter/pshnterr.h,
4472 src/psnames/psnamerr.h, src/raster/rasterrs.h, src/sfnt/sferrors.h,
4473 src/smooth/ftsmerrs.h, src/truetype/tterrors.h,
4474 src/type1/t1errors.h, src/type42/t42error.h, src/winfonts/fnterrs.h:
4475 Add #undef FT_ERR_PREFIX before #define FT_ERR_PREFIX.
4477 2012-03-03 Werner Lemberg <wl@gnu.org>
4479 Fix Savannah bug #35660.
4481 For some divisions, we use casts to 32bit entities. Always guard
4482 against division by zero with these casts also.
4484 * src/base/ftcalc.c (ft_div64by32): Remove redundant cast.
4485 (FT_MulDiv, FT_MulDiv_No_Round): Add 32bit cast.
4486 (FT_DivFix): Add 32bit cast (this omission triggered the bug).
4488 2012-03-03 Werner Lemberg <wl@gnu.org>
4490 [psaux] Fix handling of track kerning.
4492 * src/psaux/afmparse.c (afm_parse_track_kern): Don't inverse sign
4493 for `min_kern'. It is indeed quite common that track kerning
4494 *increases* spacing for very small sizes.
4496 2012-03-02 Werner Lemberg <wl@gnu.org>
4498 [truetype] Fix Savannah bug #35689.
4500 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Check first outline
4503 2012-03-01 Werner Lemberg <wl@gnu.org>
4505 [bdf] Fix Savannah bug #35656.
4507 * src/bdf/bdflib.c (_bdf_parse_glyphs) <_BDF_BITMAP>: Check validity
4508 of nibble characters instead of accessing `a2i' array.
4510 2012-03-01 Werner Lemberg <wl@gnu.org>
4512 [winfonts] Fix Savannah bug #35659.
4514 * src/winfonts/winfnt.c (FNT_Face_Init): Check number of glyphs.
4516 2012-03-01 Werner Lemberg <wl@gnu.org>
4518 [bdf] Fix Savannah bug #35658.
4520 * src/bdf/bdflib.c (_bdf_list_split): Initialize `field' elements
4523 2012-03-01 Werner Lemberg <wl@gnu.org>
4525 [psaux] Fix Savannah bug #35657.
4527 If in function `skip_spaces' the routine `skip_comment' comes to the
4528 end of buffer, `cur' is still increased by one, so we need to check
4529 for `p >= limit' and not `p == limit'.
4531 * src/psaux/psconv.c (PS_Conv_Strtol, PS_Conv_ToFixed,
4532 PS_Conv_ASCIIHexDecode, PS_Conv_EexecDecode): Fix boundary checking.
4534 2012-03-01 Werner Lemberg <wl@gnu.org>
4536 [truetype] Fix Savannah bug #35646.
4538 * src/truetype/ttinterp.c (Ins_MIRP): Typo, present since ages. The
4539 code is now in sync with the other operators (e.g. MSIRP) which
4540 modify twilight points.
4542 2012-03-01 Werner Lemberg <wl@gnu.org>
4544 [bdf] Fix Savannah bug #35643.
4546 * src/bdf/bdflib.c (_bdf_list_ensure): Bring code in sync with
4547 comment before `_bdf_list_split', this is, really allocate at least
4548 five `field' elements.
4550 2012-03-01 Werner Lemberg <wl@gnu.org>
4552 [bdf] Fix Savannah bug #35641.
4554 * src/bdf/bdflib.c (_bdf_parse_glyphs) <DWIDTH, BBX>: Abort if
4555 _BDF_ENCODING isn't set. We need this because access to the `glyph'
4556 variable might be undefined otherwise.
4558 2012-03-01 Werner Lemberg <wl@gnu.org>
4560 [truetype] Fix Savannah bug #35640.
4562 * src/truetype/ttinterp.c (SkipCode, TT_RunIns): Fix boundary check
4563 for NPUSHB and NPUSHW instructions.
4565 2012-02-29 Werner Lemberg <wl@gnu.org>
4567 [truetype] Fix Savannah bug #35601.
4569 * src/truetype/ttinterp.c (Ins_SHZ): Use number of points instead of
4570 last point for loop.
4571 Also remove redundant boundary check.
4573 2012-02-29 Werner Lemberg <wl@gnu.org>
4575 [truetype] Remove redundant check.
4577 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Remove redundant
4578 second check for ordered contour start points.
4580 2012-02-29 Werner Lemberg <wl@gnu.org>
4582 [truetype] Make SHC instruction behave similar to MS rasterizer.
4584 * src/truetype/ttinterp.c (Ins_SHC): Handle virtual contour in
4587 2012-02-29 Alexei Podtelezhnikov <apodtele@gmail.com>
4589 Avoid modulo operators against a power-of-two denominator.
4591 * src/afcjk.c (af_hint_normal_stem), src/base/ftoutln.c
4592 (ft_contour_has), src/cff/cffgload.c (cff_decoder_parse_charstrings)
4593 <cff_op_vvcurveto, cff_op_hhcurveto, cff_op_hvcurveto>,
4594 src/gxvalid/gxvcommn.c (GXV_32BIT_ALIGNMENT_VALIDATE),
4595 src/gxvalid/gxvfeat.c (gxv_feat_setting_validate): Replace `%' with
4598 2012-02-29 Werner Lemberg <wl@gnu.org>
4600 [autofit] Don't synchronize digit widths for light rendering mode.
4602 We don't hint horizontally in this mode.
4604 * src/autofit/afloader.c (af_loader_load_g) <Hint_Metrics>:
4607 2012-02-26 Alexei Podtelezhnikov <apodtele@gmail.com>
4609 [type42] Minor code optimization (again).
4611 * src/type42/t42parse.c (t42_parse_sfnts): Simplify previous change.
4613 2012-02-26 Mateusz Jurczyk <mjurczyk@google.com>
4614 Werner Lemberg <wl@gnu.org>
4616 [smooth] Fix Savannah bug #35604.
4618 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use `FT_Pos'
4619 instead of `FT_UInt' for some variables and update comparisons
4620 accordingly. A detailed analysis can be found in the bug report.
4622 2012-02-26 Alexei Podtelezhnikov <apodtele@gmail.com>
4624 [type42] Minor code optimization.
4626 * src/type42/t42parse.c (t42_parse_sfnts): Use bitmask instead of
4629 2012-02-26 Werner Lemberg <wl@gnu.org>
4631 * docs/CHANGES: Updated.
4633 2012-02-26 Werner Lemberg <wl@gnu.org>
4635 [type1] Fix Savannah bug #35608.
4637 * src/type1/t1parse.c (T1_Get_Private_Dict): Reject too short
4640 2012-02-26 Werner Lemberg <wl@gnu.org>
4642 [bdf] Support `ENCODING -1 <n>' format.
4644 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Implement it.
4646 2012-02-26 Werner Lemberg <wl@gnu.org>
4648 [bdf] Fix Savannah bug #35607.
4650 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Normalize
4651 negative encoding values.
4653 2012-02-26 Werner Lemberg <wl@gnu.org>
4655 [type1] Fix Savannah bug #35606.
4657 * src/type1/t1load.c (parse_subrs): Add proper guards for `strncmp'.
4659 * src/psaux/psobjs.c (ps_parser_skip_PS_token): Emit error message
4660 only if cur < limit.
4662 2012-02-25 Werner Lemberg <wl@gnu.org>
4664 [pcf] Fix Savannah bug #35603.
4666 * src/pcf/pcfread.c (pcf_get_properties): Assure final zero byte in
4669 2012-02-25 Werner Lemberg <wl@gnu.org>
4671 [type42] Fix Savannah bug #35602.
4673 * src/type42/t42parse.c (t42_parse_sfnts): Check `string_size' more
4676 2012-02-25 Werner Lemberg <wl@gnu.org>
4678 [bdf] Fix Savannah bugs #35599 and #35600.
4680 * src/bdf/bdflib.c (ACMSG16): New warning message.
4681 (_bdf_parse_glyphs) <_BDF_BITMAP>: Check line length.
4683 2012-02-24 Werner Lemberg <wl@gnu.org>
4685 [bdf] Fix Savannah bugs #35597 and #35598.
4687 * src/bdf/bdflib.c (_bdf_is_atom): Fix handling of property value.
4689 2012-02-24 Vinnie Falco <vinnie.falco@gmail.com>
4691 Prepare source code for amalgamation (6/6).
4693 * src/cff/cffdrivr.c: s/Load_Glyph/cff_glyph_load/.
4695 * src/cid/cidload.c: s/parse_font_matrix/cid_parse_font_matrix/.
4696 s/t1_init_loader/cid_init_loader/.
4697 s/t1_done_loader/cid_done_loader/.
4699 * src/pxaux/t1cmap.c: s/t1_get_glyph_name/psaux_get_glyph_name/.
4701 * src/truetype/ttdriver.c: s/Load_Glyph/tt_glyph_load/.
4703 * src/type1/t1load.c: s/parse_font_matrix/t1_parse_font_matrix/.
4705 2012-02-24 Vinnie Falco <vinnie.falco@gmail.com>
4707 Prepare source code for amalgamation (5/6).
4709 * include/freetype/fterrors.h: Undefine FT_KEEP_ERR_PREFIX after
4712 2012-02-22 Vinnie Falco <vinnie.falco@gmail.com>
4714 Prepare source code for amalgamation (4/6).
4716 * src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine RAS_ARG,
4717 RAS_ARGS, RAS_VAR, and RAS_VARS before defining it.
4719 * src/smooth/ftgrays.c: s/TRaster/black_TRaster/,
4720 s/PRaster/black_PRaster/.
4721 * src/raster/ftraster.c: s/TRaster/gray_TRaster/,
4722 s/PRaster/gray_PRaster/.
4724 2012-02-20 Vinnie Falco <vinnie.falco@gmail.com>
4726 Prepare source code for amalgamation (3/6).
4728 * src/smooth/ftgrays.c: s/TWorker/black_TWorker/,
4729 s/PWorker/black_PWorker/.
4730 * src/raster/ftraster.c: s/TWorker/gray_TWorker/,
4731 s/PWorker/gray_PWorker/.
4733 2012-02-20 Vinnie Falco <vinnie.falco@gmail.com>
4735 Prepare source code for amalgamation (2/6).
4737 * src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine FLOOR,
4738 CEILING, TRUNC, and SCALED before defining it.
4740 2012-02-20 Vinnie Falco <vinnie.falco@gmail.com>
4742 Prepare source code for amalgamation (1/6).
4744 See discussion starting at
4746 http://lists.gnu.org/archive/html/freetype-devel/2012-01/msg00037.html
4748 * src/smooth/ftgrays.c: s/TBand/gray_TBand/.
4749 * src/raster/ftraster.c: s/TBand/black_TBand/.
4751 2012-02-17 Alexei Podtelezhnikov <apodtele@gmail.com>
4753 [autofit] Fix outline flags.
4755 * src/autofit/afloader.c (af_loader_load_g): Don't reassign
4756 `outline.flags' so that this information is preserved. See
4757 discussion starting at
4759 http://lists.gnu.org/archive/html/freetype-devel/2012-02/msg00046.html
4761 2012-02-11 Werner Lemberg <wl@gnu.org>
4763 [truetype] Fix Savannah bug #35466.
4765 Jump instructions are now bound to the current function. The MS
4766 Windows rasterizer behaves the same, as confirmed by Greg Hitchcock.
4768 * src/truetype/ttinterp.h (TT_CallRec): Add `Cur_End' element.
4769 * src/truetype/ttobjs.h (TT_DefRecord): Add `end' element.
4771 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF): Check upper
4772 bound of jump address.
4773 (Ins_FDEF, Ins_CALL, Ins_LOOPCALL, Ins_UNKNOWN, TT_RunIns): Updated.
4775 2012-02-11 Werner Lemberg <wl@gnu.org>
4777 We don't use `extensions'.
4779 * include/freetype/internal/ftobjs.h (FT_DriverRec): Remove
4782 2012-02-11 Werner Lemberg <wl@gnu.org>
4784 Clean up `generic' fields.
4786 * include/freetype/internal/ftobjs.h (FT_ModuleRec, FT_LibraryRec):
4787 Remove `generic' field since users can't access it.
4789 * src/base/ftobjs.c (FT_Done_GlyphSlot): Call `generic.finalizer' as
4790 advertised in the documentation of FT_Generic.
4791 (Destroy_Module, FT_Done_Library): Updated to changes in `ftobjs.h'.
4793 2012-02-07 Werner Lemberg <wl@gnu.org>
4795 [autofit] Harmonize function arguments.
4797 * src/autofit/afloader.c, src/autofit/afloader.h: Use `FT_Int32' for
4800 2012-02-07 Werner Lemberg <wl@gnu.org>
4802 * src/cff/cffobjs.c (cff_face_init): Remove unnecessary casts.
4804 2012-01-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4806 [gxvalid] Fix Savannah bug #35286.
4808 Patch submitted by anonymous reporter.
4810 * src/gxvalid/gxvcommn.c (gxv_XStateTable_subtable_setup):
4811 gxv_set_length_by_ulong_offset() must be called with 3, not 4,
4812 the number of the subtables in the state tables; classTable,
4813 stateArray, entryTable.
4815 2012-01-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4817 [raccess] Modify for PIC build.
4819 Based on the patch provided by Erik Dahlstrom <ed@opera.com>,
4820 http://lists.gnu.org/archive/html/freetype-devel/2012-01/msg00010.html
4822 Also `raccess_guess_table[]' and `raccess_rule_by_darwin_vfs()'
4823 are renamed with `ft_' suffixes.
4825 * src/base/ftbase.h: `raccess_rule_by_darwin_vfs()' is renamed
4826 to `ft_raccess_rule_by_darwin_vfs()'.
4827 * src/base/ftobjs.c: Ditto.
4829 * src/base/ftrfork.c: Declarations of FT_RFork_Rule,
4830 raccess_guess_rec, are moved to...
4831 * include/freetype/internal/ftrfork.h: Here.
4833 * include/freetype/internal/ftrfork.h:
4834 FT_RFORK_RULE_ARRAY_{BEGIN,ENTRY,END} macros are defined
4835 to replace raccess_guess_table[] in both of PIC and non-PIC
4837 * src/base/ftrfork.c: raccess_guess_table[] array is rewritten
4838 by FT_RFORK_RULE_ARRAY_{BEGIN,ENTRY,END}.
4840 * src/base/basepic.h (BasePIC): Add `ft_raccess_guess_table'
4841 storage. (FT_RACCESS_GUESS_TABLE_GET): New macro to retrieve
4842 the function pointer from `ft_raccess_guess_table' storage in
4843 `BasePIC' structure.
4844 * src/base/ftrfork.c (FT_Raccess_Guess): Rewritten with
4845 FT_RACCESS_GUESS_TABLE_GET.
4846 (raccess_get_rule_type_from_rule_index): Add `library' as the
4847 first argument to the function, to retrieve the storage of
4848 `ft_raccess_guess_table' from it. Also `raccess_guess_table'
4849 is replaced by FT_RACCESS_GUESS_TABLE_GET.
4850 (ft_raccess_rule_by_darwin_vfs): Ditto.
4852 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4854 Remove trailing spaces.
4856 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4858 Formatting PIC related sources.
4860 * src/autofit/afpic.c: Harmonize to FT2 coding conventions.
4861 * src/base/basepic.c: Ditto.
4862 * src/base/ftpic.c: Ditto.
4863 * src/cff/cffpic.c: Ditto.
4864 * src/pshinter/pshpic.c: Ditto.
4865 * src/psnames/pspic.c: Ditto.
4866 * src/raster/rastpic.c: Ditto.
4867 * src/sfnt/sfntpic.c: Ditto.
4868 * src/smooth/ftspic.c: Ditto.
4869 * src/truetype/ttpic.c: Ditto.
4871 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4873 [autofit] Fix the inclusion of `aflatin2.h' in PIC file.
4875 * src/autofit/afpic.c: Include `aflatin2.h' when
4876 FT_OPTION_AUTOFIT2 is defined, as afglobal.c does so.
4877 Unconditionally inclusion causes declared but unimplemented
4880 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4882 [cff] Remove redundant declarations of cff_cmap_XXX_class_rec.
4884 * src/cff/cffpic.c: The declarations of
4885 FT_Init_Class_cff_cmap_encoding_class_rec() and
4886 FT_Init_Class_cff_cmap_unicode_class_rec() are removed.
4887 They can be obtained by the inclusion of cffcmap.h.
4888 cffcmap.h invokes FT_DECLARE_CMAP_CLASS() and it declares
4889 FT_Init_Class_cff_cmap_encoding_class_rec() etc in PIC mode.
4891 2012-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4893 Fix redundant declaration warning in PIC mode.
4895 Originally FT_DEFINE_{DRIVER,MODULE,RENDERER}() macros were
4896 designed to declare xxx_pic_{free,init} by themselves.
4897 Because these macros are used at the end of the module
4898 interface (e.g. ttdriver.c) and the wrapper source to build
4899 a module as a single object (e.g. truetype.c) includes
4900 the PIC file (e.g. ttpic.c) before the module interface,
4901 these macros are expanded AFTER xxx_pic_{free,init} body
4902 when the modules are built as single object.
4903 The declaration after the implementation causes the redundant
4904 declaration warnings, so the declarations are moved to module
4905 PIC headers (e.g. ttpic.h). Separating to other header files
4906 are needed for multi build.
4908 * include/freetype/internal/ftdriver.h (FT_DEFINE_DRIVER):
4909 Remove class_##_pic_free and class_##_pic_init declarations.
4910 * include/freetype/internal/ftobjs.h (FT_DEFINE_RENDERER,
4911 FT_DEFINE_MODULE): Ditto.
4913 * src/base/basepic.h: Insert a comment and fix coding style.
4914 * src/autofit/afpic.h: Declare autofit_module_class_pic_{free,
4916 * src/cff/cffpic.h: Declare cff_driver_class_pic_{free,init}.
4917 * src/pshinter/pshpic.h: Declare pshinter_module_class_pic_{free,
4919 * src/psnames/pspic.h: Declare psnames_module_class_pic_{free,
4921 * src/raster/rastpic.h: Declare
4922 ft_raster{1,5}_renderer_class_pic_{free,init}
4923 * src/sfnt/sfntpic.h: Declare sfnt_module_class_pic_{free,init}.
4924 * src/smooth/ftspic.h: Declare
4925 ft_smooth_{,lcd_,lcdv_}renderer_class_pic_{free,init}.
4926 * src/truetype/ttpic.h: Declare tt_driver_class_pic_{free,init}.
4928 2012-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4930 Make pspic.c to include module error header to fix multi build.
4932 * src/psnames/pspic.c: Include `psnamerr.h'.
4934 2012-01-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4936 [base] Fix a dereference of uninitialized variable in PIC mode.
4938 * src/base/ftglyph.c (FT_Glyph_To_Bitmap): `glyph' must be
4939 set before derefering to obtain `library'. The initialization
4940 of `clazz', `glyph', `library' and NULL pointer check are
4941 reordered to minimize PIC conditonals.
4943 2012-01-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4945 [base] Insert explicit cast for GCC 4.6 in PIC mode.
4947 * src/base/ftinit.c (FT_Add_Default_Modules): Under PIC
4948 configuration, FT_DEFAULT_MODULES_GET returns
4949 FT_Module_Class** pointer, GCC 4.6 warns that
4950 const FT_Module_Class* const* variable is warned as
4951 inappropriate to store it. To calm it, explicit cast is
4952 inserted. Also `library' is checked to prevent the NULL
4953 pointer dereference in FT_DEFAULT_MODULES_GET.
4955 2012-01-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4957 Fix PIC build broken by d9145241fe378104ba4c12a42534549faacc92e6.
4959 Under PIC configuration, FT_{CFF,PSCMAPS,SFNT,TT}_SERVICES_GET
4960 take no arguments but derefer the variable named `library'
4963 * src/cff/cffdrivr.c (cff_get_interface): Declare `library' and
4964 set it if non-NULL driver is passed.
4965 * src/truetype/ttdriver.c (tt_get_interface): Ditto.
4967 * src/sfnt/sfdriver.c (sfnt_get_interface): Declare `library'
4968 under PIC configuration, and set it if non-NULL module is given.
4969 * src/psnames/psmodule.c (psnames_get_interface): Ditto.
4971 2012-01-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4973 Make PIC files include module error headers, to use the error codes
4974 with per-module prefix.
4976 * src/autofit/afpic.c: Include `aferrors.h'.
4977 * src/cff/cffpic.c: Include `cfferrs.h'.
4978 * src/pshinter/pshpic.c: Include `pshnterr.h'.
4979 * src/raster/rastpic.c: Include `rasterrs.h'.
4980 * src/sfnt/sfntpic.c: Include `sferrors.h'.
4981 * src/smooth/ftspic.c: Include `ftsmerrs.h'.
4982 * src/truetype/ttpic.c: Include `tterrors.h'.
4984 2012-01-04 Tobias Ringström <tobias@ringis.se>
4986 [truetype] Fix IP instruction if x_ppem != y_ppem.
4988 * src/truetype/ttinterp.c (Ins_IP): Scale `orus' coordinates
4991 2012-01-02 Werner Lemberg <wl@gnu.org>
4993 Fix tracing message for `loca' table.
4995 * src/truetype/ttpload.c (tt_face_get_location): Don't emit a
4996 warning message if the last `loca' entry references an empty glyph.
4998 2011-12-10 Werner Lemberg <wl@gnu.org>
5000 Add some variable initializations.
5001 Reported by Richard COOK <rscook@unicode.org>.
5003 * src/type1/t1driver.c (t1_ps_get_font_value): Initialize `val'.
5004 * src/smooth/ftgrays.c (gray_render_conic): Initialize `levels'
5007 2011-12-08 Werner Lemberg <wl@gnu.org>
5009 Fix serious scaling bug in `FT_Get_Advances'.
5011 * src/base/ftadvanc.c (FT_Get_Advances): Advance values returned by
5012 `FT_Load_Glyph' must be simply multiplied by 1024.
5014 2011-12-08 Werner Lemberg <wl@gnu.org>
5016 * src/bdf/bdflib.c (_bdf_parse_start): Drop redundant error tracing.
5018 2011-12-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5020 [mac] Unify DARWIN_NO_CARBON with FT_MACINTOSH.
5022 Originally FT_MACINTOSH was a pure auto macro and DARWIN_NO_CARBON
5023 was a configurable macro to disable Carbon-dependent code. Because
5024 now configure script sets DARWIN_NO_CARBON by default and disables
5025 Darwin & Carbon-dependent codes, these macros can be unified.
5026 FT_MACINTOSH (undefined by default) is kept and DARWIN_NO_CARBON
5027 (defined by default) is removed, because DARWIN_NO_CARBON violates
5028 FT_XXX naming convention of public macros, and a macro configured by
5029 default is not portable for the building without configure (e.g.
5032 * builds/unix/configure.raw: Define FT_MACINTOSH if Carbon-based
5033 old Mac font support is requested and Carbon is available.
5034 * builds/unix/ftconfig.in: Undefine FT_MACINTOSH when the support
5035 for Mac OS X without Carbon (e.g. Mac OS X 10.4 for ppc64) is
5037 * include/freetype/config/ftconfig.in: Ditto.
5038 * builds/vms/ftconfig.h: Ditto.
5040 * src/base/ftbase.h: Remove DARWIN_NO_CARBON.
5041 * src/base/ftbase.c: Ditto.
5042 * src/base/ftobjs.c: Ditto.
5043 * src/base/ftrfork.c: Ditto.
5045 * src/base/ftmac.c: Compile the body if FT_MACINTOSH is defined
5046 (same with TT_USE_BYTECODE_INTERPRETER in ttinterp.c).
5047 * builds/mac/ftmac.c: Ditto.
5049 * builds/mac/FreeType.m68k_cfm.make.txt: Define FT_MACINTOSH.
5050 * builds/mac/FreeType.m68k_far.make.txt: Ditto.
5051 * builds/mac/FreeType.ppc_classic.make.txt: Ditto.
5052 * builds/mac/FreeType.ppc_carbon.make.txt: Ditto.
5054 2011-11-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5056 Fix Savannah bug #34728 (`make devel' on Mac OS X).
5058 * builds/toplevel.mk: Check `/dev/null' to identify the Unix-
5059 like systems without `init' nor `hurd' (e.g. Mac OS X >= 10.4).
5060 * builds/unix/detect.mk: Ditto.
5062 2011-11-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5064 [apinames] Fix the overflow of signed integer hash.
5066 * src/tools/apinames.c (names_add): Change the type of `h' from
5067 int to unsigned int, to prevent undefined behaviour in the
5068 overflow of signed integers (overflow of unsigned int is defined
5069 to be wrap around). Found by clang test suggested by Sean
5072 2011-11-30 Werner Lemberg <wl@gnu.org>
5074 [winfonts] Remove casts.
5076 * src/winfonts/winfnt.c (winfnt_driver_class): Remove all casts and
5077 update affected functions.
5078 (FNT_Size_Select): Fix number of arguments.
5080 2011-11-30 Werner Lemberg <wl@gnu.org>
5082 [type42] Remove casts.
5084 * src/type42/t42driver.c (t42_driver_class): Remove all casts and
5085 update affected functions.
5087 * src/type42/t42objs.c, src/type42/t42objs.h: Updated for t42driver
5090 2011-11-30 Werner Lemberg <wl@gnu.org>
5092 [type1] Remove casts.
5094 * src/type1/t1driver.c (t1_driver_class): Remove all casts and
5095 update affected functions.
5097 * src/type1/t1gload.c, src/type1/t1gload.h, src/type1/t1objs.c:
5098 Updated for t1driver changes.
5099 src/type1/t1objs.h (T1_Driver): Remove unused typedef.
5100 Updated for t1driver changes.
5102 2011-11-27 Werner Lemberg <wl@gnu.org>
5104 [bdf] Fix Savannah bug #34896.
5106 ENCODING now covers the whole Unicode range.
5108 Note, however, that this change is quite expensive since it
5109 increases the size of three arrays by almost 400kByte in total. The
5110 right fix is to replace the logic with something smarter.
5111 Additionally, there exist very old BDFs for three-byte CCCII
5112 encoding which exceeds the range of Unicode (another reason to have
5115 * src/bdf/bdf.h (bdf_font_t): Increase size of `nmod' and `umod'
5117 * src/bdf/bdflib.c (bdf_parse_t): Increase size of `have' array.
5119 2011-11-27 Werner Lemberg <wl@gnu.org>
5121 [bdf] Improve tracing.
5123 * src/bdf/bdflib.c (DBGMSG1, DBGMSG2): New macros.
5124 (_bdf_parse_glyphs): Use them.
5126 2011-11-26 Werner Lemberg <wl@gnu.org>
5130 * src/bdf/bdfdrivr.c (BDF_Face_Done), src/pcf/pcfdrivr.c
5131 (PCF_Face_Done): Remove tracing message.
5133 * src/bdf/bdfdrivr.c (BDF_Face_Init), src/cff/cffobjs.c
5134 (cff_face_init), src/cid/cidobjs.c (cid_face_init),
5135 src/pfr/pfrobjs.c (pfr_face_init), src/sfnt/sfobjs.c
5136 (sfnt_init_face), src/truetype/ttobjs.c (tt_face_init),
5137 src/type1/t1objs.c (T1_Face_Init), src/type42/t42objs.c
5138 (T42_Face_Init), src/winfonts/winfnt.c (FNT_Face_Init): Add
5141 * src/sfnt/sfobjs.c (sfnt_open_font), src/type42/t42objs.c
5142 (T42_Open_Face): Improve tracing.
5144 2011-11-26 Werner Lemberg <wl@gnu.org>
5146 [cid] Fix error code.
5148 * src/cid/cidparse.c (cid_parser_new): Do it.
5150 2011-11-26 Werner Lemberg <wl@gnu.org>
5152 [cff] Fix error code.
5154 * src/cff/cffload.c (cff_font_load): Do it.
5156 2011-11-26 Werner Lemberg <wl@gnu.org>
5158 Add new error code FT_Err_Missing_Module.
5160 Previously, FreeType misleadingly returned
5161 FT_Err_Unknown_File_Format if a module was missing (or a test was
5162 missing completely).
5164 * include/freetype/fterrdef.h (FT_Err_Missing_Module): Define.
5166 * src/cff/cffobjs.c (cff_face_init), src/cff/cffdrivr.c
5167 (cff_get_glyph_name), src/cid/cidobjs.c (cid_face_init),
5168 src/sfnt/sfobjs.c (sfnt_init_face), src/truetype/ttobjs.c
5169 (tt_face_init), src/type1/t1objs.c (T1_Face_Init),
5170 src/type42/t42objs.c (T42_Face_Init, T42_Driver_Init): Updated.
5172 * src/type1/t1afm.c (T1_Read_Metrics), src/type/t1objs.c
5173 (T1_Face_Init), src/type42/t42objs.c (T42_Face_Init): Remove now
5174 redundant test for `psaux'.
5176 2011-11-25 Werner Lemberg <wl@gnu.org>
5178 [bdf] Add more error messages.
5180 * src/bdf/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
5181 Add line number argument.
5183 (ERRMSG5, ERRMSG6, ERRMSG7, ERRMSG8, ERRMSG9): New macros.
5184 (_bdf_readstream, _bdf_set_default_spacing, _bdf_add_property,
5185 _bdf_parse_glyphs, _bdf_parse_start): Add error messages.
5187 2011-11-24 Werner Lemberg <wl@gnu.org>
5189 * include/freetype/fterrors.h: Remove dead code.
5191 2011-11-15 Werner Lemberg <wl@gnu.org>
5193 * docs/releases: Updated.
5195 2011-11-15 Werner Lemberg <wl@gnu.org>
5197 * Version 2.4.8 released.
5198 =========================
5201 Tag sources with `VER-2-4-8'.
5203 * docs/CHANGES: Updated.
5205 * docs/VERSION.DLL: Update documentation and bump version number to
5208 * README, Jamfile (RefDoc),
5209 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5210 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5211 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
5212 builds/win32/visualc/freetype.dsp,
5213 builds/win32/visualc/freetype.vcproj,
5214 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5215 builds/win32/visualce/freetype.vcproj,
5216 builds/win32/visualce/index.html,
5217 builds/wince/vc2005-ce/freetype.vcproj,
5218 builds/wince/vc2005-ce/index.html,
5219 builds/wince/vc2008-ce/freetype.vcproj,
5220 builds/wince/vc2008-ce/index.html: s/2.4.7/2.4.8/, s/247/248/.
5222 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 8.
5224 * builds/unix/configure.raw (version_info): Set to 14:0:8.
5226 2011-11-13 Chris Liddell <chris.liddell@artifex.com>
5228 Add FT_Get_PS_Font_Value() API.
5230 This allows a Type 1 font face to be interrogated to retrieve most
5231 of the dictionary keys (keys not relevant to FreeType's Type 1
5232 interpreter are not available).
5234 * include/freetype/internal/services/svpsinfo.h
5235 (PS_GetFontValueFunc): New typedef.
5236 (PSInfo): Add `ps_get_font_value'.
5237 (FT_DEFINE_SERVICE_PSINFOREC): Updated.
5239 * include/freetype/internal/t1types.h (T1_EncodingType): Moved to...
5240 * include/freetype/t1tables.h: Here.
5241 (PS_Dict_Keys): New enumeration.
5242 (FT_Get_PS_Font_Value): New declaration.
5244 * src/base/fttype1.c (FT_Get_PS_Font_Value): New function.
5246 * src/type1/t1driver.c (t1_ps_get_font_value): This new function
5248 (t1_service_ps_info): Add it.
5250 * src/cff/cffdrivr.c (cff_service_ps_info), src/cid/cidriver.c
5251 (cid_service_ps_info), src/type42/t42drivr.c (t42_service_ps_info):
5254 2011-11-08 Braden Thomas <bthomas@apple.com>
5256 [cid] Various loading fixes.
5258 * src/cid/cidload.c (cid_load_keyword) <default>,
5259 (parse_font_matrix, parse_expansion_factor): Correctly check number
5261 (cid_read_subrs): Protect against invalid values of `num_subrs'.
5262 Assure that the elements of the `offsets' array are ascending.
5264 2011-11-05 Werner Lemberg <wl@gnu.org>
5266 * README: We use copyright ranges also.
5270 http://www.gnu.org/prep/maintain/html_node/Copyright-Notices.html
5272 this should be mentioned explicitly.
5274 2011-10-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5276 [raccess] Supplement for previous fix.
5278 * src/base/ftbase.h (raccess_rule_by_darwin_vfs): Do not declare
5279 it on native Mac OS X.
5280 * src/base/ftrfork.c (raccess_get_rule_type_from_rule_index):
5281 Hide raccess_get_rule_type_from_rule_index() on native Mac OS X
5284 2011-10-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5286 [raccess] Hide raccess_rule_by_darwin_vfs() on native Mac OS X.
5288 * src/base/ftrfork.c (raccess_rule_by_darwin_vfs): Do not
5289 compile on native Mac OS X because it is not used.
5291 2011-10-25 Werner Lemberg <wl@gnu.org>
5293 [truetype] Fix MD instruction for twilight zone.
5295 * src/truetype/ttinterp.c (Ins_MD): Without this fix, the MD
5296 instruction applied to original coordinates of twilight points
5297 always returns zero.
5299 2011-10-18 Werner Lemberg <wl@gnu.org>
5301 * Version 2.4.7 released.
5302 =========================
5305 Tag sources with `VER-2-4-7'.
5307 * docs/CHANGES: Updated.
5309 * docs/VERSION.DLL: Update documentation and bump version number to
5312 * README, Jamfile (RefDoc),
5313 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5314 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5315 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
5316 builds/win32/visualc/freetype.dsp,
5317 builds/win32/visualc/freetype.vcproj,
5318 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5319 builds/win32/visualce/freetype.vcproj,
5320 builds/win32/visualce/index.html,
5321 builds/wince/vc2005-ce/freetype.vcproj,
5322 builds/wince/vc2005-ce/index.html,
5323 builds/wince/vc2008-ce/freetype.vcproj,
5324 builds/wince/vc2008-ce/index.html: s/2.4.6/2.4.7/, s/246/247/.
5326 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 7.
5328 * builds/unix/configure.raw (version_info): Set to 13:2:7.
5330 2011-10-15 Kal Conley <kcconley@gmail.com>
5332 Fix handling of transformations if no renderer is present.
5334 * src/base/ftobjs.c (FT_Load_Glyph): Thinko.
5336 2011-10-15 Kal Conley <kcconley@gmail.com>
5338 Fix conditions for autohinting.
5340 * src/base/ftobjs.c (FT_Load_Glyph): Handle
5341 FT_LOAD_IGNORE_TRANSFORM.
5343 2011-10-07 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5345 [gxvalid] Fix a bug to detect too large offset in morx table.
5347 * src/gxvalid/gxvmorx2.c
5348 (gxv_morx_subtable_type2_ligActionIndex_validate): Fix a bug
5349 that too large positive offset cannot be detected.
5351 2011-10-01 Braden Thomas <bthomas@apple.com>
5353 Handle some border cases.
5355 * include/freetype/config/ftstdlib.h (FT_USHORT_MAX): New macro.
5357 * src/base/ftbitmap.c (FT_Bitmap_Convert): Protect against invalid
5358 value of `target->rows'.
5360 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Add check for
5363 * src/raster/ftrend1.c (ft_raster1_render): Check `width' and
5366 * src/truetype/ttgxvar.c (TT_Vary_Get_Glyph_Deltas): Protect against
5367 invalid values in `localpoints' array.
5369 2011-10-01 Werner Lemberg <wl@gnu.org>
5371 [psnames] Handle zapfdingbats.
5372 Problem reported by Nicolas Rougier <Nicolas.Rougier@inria.fr>.
5374 * src/tools/glnames.py (adobe_glyph_list): Add data from AGL's
5375 `zapfdingbats.txt' file.
5377 * src/psnames/pstables.h: Regenerated.
5379 2011-09-27 Simon Bünzli <zeniko@gmail.com>
5381 [type1] Fix Savannah bug #34189.
5383 * src/type1/t1load.c (T1_Open_Face): Initialize
5384 `face->len_buildchar'.
5386 2011-09-26 Werner Lemberg <wl@gnu.org>
5388 [cff] Dump SIDs while tracing.
5390 * src/cff/cffobjs.c (cff_face_init): Do it.
5392 * src/cff/cffparse.c (cff_parser_run) [FT_DEBUG_LEVEL_TRACE]
5393 <cff_kind_string>: Identify as SID.
5395 2011-09-17 Werner Lemberg <wl@gnu.org>
5397 Remove unused FT_ALIGNMENT macro.
5399 * builds/unix/ftconfig.in, builds/vms/ftconfig.h,
5400 include/freetype/config/ftconfig.h: Do it.
5402 2011-09-17 Alexei Podtelezhnikov <apodtele@gmail.com>
5404 [smooth] Slightly optimize conic and cubic flatterners.
5406 * src/smooth/ftgrays.c (gray_render_conic, gray_render_cubic): Move
5407 out some code from the main loop to speed it up.
5409 2011-09-11 Tomas Hoger <thoger@redhat.com>
5411 Slightly improve LZW_CLEAR handling.
5413 * src/lzw/ftzopen.c (ft_lzwstate_io) <FT_LZW_PHASE_CODE>:
5414 Ensure that subsequent (modulo garbage byte(s)) LZW_CLEAR codes are
5415 handled as clear codes. This also re-sets old_code and old_char to
5416 predictable values, which is a little better than using `random'
5417 ones if the code following LZW_CLEAR is invalid.
5419 2011-09-11 Tomas Hoger <thoger@redhat.com>
5421 Add explicit LZW decompression stack size limit.
5423 Stack larger than 1<<LZW_MAX_BITS is never needed if prefix table is
5424 constructed correctly. It's even less than that, see e.g.
5425 libarchive code comment for a better size upper bound:
5427 http://code.google.com/p/libarchive/source/browse/trunk/libarchive/archive_read_support_filter_compress.c?r=3635#121
5429 This patch adds explicit stack size limit, enforced when stack is
5432 An alternative is to ensure that code < state->prefix[code - 256]
5433 when traversing prefix table. Such check is less efficient and
5434 should not be required if prefix table is constructed correctly in
5437 * src/lzw/ftzopen.c (ft_lzwstate_stack_grow): Implement it.
5439 2011-09-11 Tomas Hoger <thoger@redhat.com>
5441 Protect against loops in the prefix table.
5443 LZW decompressor did not sufficiently check codes read from the
5444 input LZW stream. A specially-crafted or corrupted input could
5445 create a loop in the prefix table, which leads to memory usage
5446 spikes, as there's no decompression stack size limit.
5448 * src/lzw/ftzopen.c (ft_lzwstate_io) <FT_LZW_PHASE_START>: First
5449 code in valid LZW stream must be 0..255.
5450 <FT_LZW_PHASE_CODE>: In the special KwKwK case, code == free_ent,
5451 code > free_ent is invalid.
5453 2011-09-09 Werner Lemberg <wl@gnu.org>
5455 Better tracing of metrics.
5457 * src/base/ftobjs.c (FT_Request_Size, FT_Select_Size): Decorate with
5460 2011-09-07 Werner Lemberg <wl@gnu.org>
5462 [cff] Fix Savannah bug #33816.
5464 * src/cff/cfftypes.h (CFF_FontRecDictRec): New member
5466 * src/cff/cffparse.c (cff_parse_font_matrix): Set it.
5467 Update tracing output.
5468 * src/cff/cffobjs.c (cff_face_init): Use it so that the heuristics
5471 2011-08-30 Werner Lemberg <wl@gnu.org>
5473 Better tracing of metrics.
5475 * src/base/ftobjs.c (FT_Select_Metrics, FT_Request_Metrics):
5476 Decorate with FT_TRACE.
5478 2011-08-25 Werner Lemberg <wl@gnu.org>
5480 [cff] Better tracing of the parsing process.
5482 * src/cff/cffload.c (cff_subfont_load, cff_font_load): Decorate with
5485 * src/cff/cffparse.c (cff_parse_font_matrix, cff_parse_font_bbox,
5486 cff_parse_private_dict, cff_parse_cid_ros): Updated.
5487 (CFF_FIELD_NUM, CFF_FIELD_FIXED, CFF_FIELD_FIXED_1000,
5488 CFF_FIELD_STRING, CFF_FIELD_BOOL, CFF_FIELD_CALLBACK, CFF_FIELD,
5489 CFF_FIELD_DELTA): Add argument for ID.
5490 (cff_parser_run): Decorate with FT_TRACE.
5492 * src/cff/cffparse.h (CFF_Field_Handler) [FT_DEBUG_LEVEL_TRACE]: Add
5495 * src/cff/cfftoken.h: Add IDs to all fields.
5497 2011-08-16 Werner Lemberg <wl@gnu.org>
5499 Fix Savannah bug #34022.
5501 * README, docs/INSTALL: Remove references to UPGRADE.UNIX.
5503 2011-08-15 Werner Lemberg <wl@gnu.org>
5505 Fix Savannah bug #34018.
5507 * docs/UPGRADE.UNIX: Removed. Obsolete.
5509 2011-08-15 David Bevan <david.bevan@pb.com>
5511 Fix Savannah bug #33992.
5513 * src/base/ftstroke.c (FT_Stroker_ParseOutline): Fix border case.
5515 2011-08-12 Werner Lemberg <wl@gnu.org
5517 [truetype] Fix degenerate case in S{P,F,DP}VTL opcodes.
5519 * src/truetype/ttinterp.c (Ins_SxVTL): Handle p1 == p2 specially.
5520 (Ins_SDPVTL): Handle v1 == v2 specially.
5522 2011-08-09 Werner Lemberg <wl@gnu.org>
5524 [cff] Fix Savannah bug #33975.
5526 * src/cff/cffparse.c (cff_parse_font_matrix): Fix typo.
5528 2011-07-29 Werner Lemberg <wl@gnu.org>
5530 * Version 2.4.6 released.
5531 =========================
5534 Tag sources with `VER-2-4-6'.
5536 * docs/CHANGES: Updated.
5538 * docs/VERSION.DLL: Update documentation and bump version number to
5541 * README, Jamfile (RefDoc),
5542 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5543 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5544 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
5545 builds/win32/visualc/freetype.dsp,
5546 builds/win32/visualc/freetype.vcproj,
5547 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5548 builds/win32/visualce/freetype.vcproj,
5549 builds/win32/visualce/index.html,
5550 builds/wince/vc2005-ce/freetype.vcproj,
5551 builds/wince/vc2005-ce/index.html,
5552 builds/wince/vc2008-ce/freetype.vcproj,
5553 builds/wince/vc2008-ce/index.html: s/2.4.5/2.4.6/, s/245/246/.
5555 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 6.
5557 * builds/unix/configure.raw (version_info): Set to 13:1:7.
5559 2011-07-29 Werner Lemberg <wl@gnu.org>
5561 [cff] Add some more tracing infos.
5563 * src/cff/cffparse.c (cff_parse_font_matrix, cff_parse_font_bbox,
5564 cff_parse_cid_ros): Add tracing.
5566 2011-07-22 Dirk Müller <dmueller@suse.de>
5568 [psaux, type1] Fix null pointer dereferences.
5570 Found with font fuzzying.
5572 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Check
5573 `decoder->buildchar'.
5575 * src/type1/t1load.c (t1_load_keyword): Check `blend->num_designs'.
5577 2011-07-20 Chris Morgan <cmorgan@cybexintl.com>
5579 Add FT_CONFIG_OPTION_DISABLE_STREAM_SUPPORT.
5581 Useful for embedded systems which don't need file stream support.
5583 * src/base/ftsystem.c, src/base/ftobjs.c (FT_Stream_New): Implement
5586 2011-07-20 Elton Chung <elton328@gmail.com>
5588 * src/base/ftpatent.c (FT_Face_SetUnpatentedHinting): Fix typo.
5590 2011-07-16 Steven Chu <steven.f.chu@gmail.com>
5592 [truetype] Fix metrics on size request for scalable fonts.
5594 * src/truetype/ttdriver.c (tt_size_request): Fix copying metrics
5595 from TT_Size to FT_Size if scalable font.
5599 http://lists.gnu.org/archive/html/freetype-devel/2011-07/msg00049.html
5601 for some comparison images.
5603 2011-07-14 Matthias Drochner <M.Drochner@fz-juelich.de>.
5605 [psaux] Fix potential sign extension problems.
5607 When shifting right a signed value, it is not defined by the
5608 C standard whether one gets a sign extension or not. Use a macro to
5609 do an explicit cast from a signed short (assuming that this is
5612 * src/psaux/t1decode.c (Fix2Int): New macro.
5613 Use it where appropriate.
5615 2011-07-14 Werner Lemberg <wl@gnu.org>
5617 * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
5618 <op_callothersubr>: Better handling of subroutine index 0.
5619 From Matthias Drochner <M.Drochner@fz-juelich.de>.
5621 2011-07-10 Алексей Подтележников <apodtele@gmail.com>
5623 [psaux] Optimize previous commit.
5625 * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
5626 <op_callothersubr>: Move error check down to avoid testing twice for
5629 2011-07-08 Werner Lemberg <wl@gnu.org>
5631 [psaux] Add better argument check for `callothersubr'.
5633 * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
5634 <op_callothersubr>: Reject negative arguments.
5636 2011-07-07 Werner Lemberg <wl@gnu.org>
5638 [sfnt] Try harder to find non-zero values for ascender and descender.
5640 * src/sfnt/sfobjs.c (sfnt_load_face): Consult `OS/2' table in case
5641 the `hhea' table's values are zero.
5643 2011-07-03 Werner Lemberg <wl@gnu.org>
5645 Fix previous commit.
5647 We want to unset FT_FACE_FLAG_SCALABLE only if there are bitmap
5648 strikes in the font.
5650 * src/truetype/ttobjs.c (tt_face_init): Implement it.
5652 * docs/CHANGES: Updated.
5654 2011-07-02 Just Fill Bugs <mozbugbox@yahoo.com.au>
5656 [truetype] Fix Savannah bug #33246.
5658 * src/truetype/ttobjs.c (tt_check_single_notdef): New function.
5659 (tt_face_init): Use it to test FT_FACE_FLAG_SCALABLE.
5661 2011-07-02 Werner Lemberg <wl@gnu.org>
5663 * docs/CHANGES: Updated.
5665 2011-07-02 David Bevan <david.bevan@pb.com>
5667 [ftstroke] Major revision.
5672 o If FT_STROKER_LINEJOIN_BEVEL was specified, unlimited miter
5673 joins (not bevel joins) were generated. Indeed, the meanings of
5674 `miter' and `bevel' were incorrectly reversed (consistently) in
5675 both the code and comments.
5677 o The way bevel joins were constructed (whether specified
5678 explicitly, or created as a result of exceeding the miter limit)
5679 did not match what is required for stroked text in PostScript or
5685 o The behaviour of FT_STROKER_LINEJOIN_BEVEL has been corrected.
5687 o A new line join style, FT_STROKER_LINEJOIN_MITER_FIXED, has been
5688 introduced to support PostScript and PDF miter joins.
5690 o FT_STROKER_LINEJOIN_MITER_VARIABLE has been introduced as an
5691 alias for FT_STROKER_LINEJOIN_MITER.
5693 Additionally, a variety of stroking errors have been fixed. These
5694 would cause various artifacts (including points `at infinity'),
5695 especially when stroking poor quality fonts.
5699 http://lists.gnu.org/archive/html/freetype-devel/2011-07/msg00001.html
5701 for example documents. The FreeType stroker now produces results
5702 very similar to that produced by GhostScript and Distiller for these
5708 The following problems have been resolved:
5710 o Inside corners could be generated incorrectly. Intersecting the
5711 inside corner could cause a missing triangular area and other
5714 The intersection point can only be used if the join is between
5715 two lines and both lines are long enough. The `optimization'
5716 condition in `ft_stroker_inside' has been corrected; this
5717 requires the line length to be passed into various functions and
5718 stored in `FT_StrokerRec'.
5720 o Incorrect cubic curves could be generated. The angle
5721 calculations in `FT_Stroker_CubicTo' have been corrected to
5722 handle the case of the curve crossing the +/-PI direction.
5724 o If the border radius was greater than the radius of curvature of
5725 a curve, then the negative sector would end up outside (not
5726 inside) the border. This situation is now recognized and the
5727 negative sector is circumnavigated in the opposite direction.
5728 (If round line joins are being used, this code is disabled
5729 because the line join will always cover the negative sector.)
5731 o When a curve is split, the arcs may not join smoothly (especially
5732 if the curve turns sharply back on itself). Changes in
5733 direction between adjacent arcs were not handled. A round
5734 corner is now added if the deviation from one arc to the next is
5735 greater than a suitable threshold.
5737 o The current direction wasn't retained if a the outline contained
5738 a zero length lineto or a curve that was determined to be
5739 `basically a point'. This could cause a spurious join to be
5742 o Cubics with close control points could be mishandled. All eight
5743 cases are now distinguished correctly.
5748 o Borders for cubic curves could be too `flat'.
5749 FT_SMALL_CUBIC_THRESHOLD has been reduced a little to prevent
5752 o The handling and use of movable points has been simplified a
5755 o Various values are now computed only if the results are actually
5758 o The directions of the outer and inner borders have been swapped,
5759 as recommended by Graham Asher.
5761 * src/base/ftstroke.c: Revised.
5762 * include/freetype/ftstroke.h: Updated.
5764 2011-06-30 İsmail Dönmez <ismail@namtrac.org>
5766 * builds/toplevel.mk: We use git, not CVS, thus skip `.gitignore'.
5768 2011-06-29 Werner Lemberg <wl@gnu.org>
5770 [bdf] Fix Savannah bug #33663.
5772 * src/bdf/bdflib.c (_bdf_parse_glyphs): Handle negative values for
5775 * docs/CHANGES: Document it.
5777 2011-06-24 Werner Lemberg <wl@gnu.org>
5779 * Version 2.4.5 released.
5780 =========================
5783 Tag sources with `VER-2-4-5'.
5785 * docs/CHANGES: Updated.
5787 * docs/VERSION.DLL: Update documentation and bump version number to
5790 * README, Jamfile (RefDoc),
5791 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5792 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5793 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
5794 builds/win32/visualc/freetype.dsp,
5795 builds/win32/visualc/freetype.vcproj,
5796 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5797 builds/win32/visualce/freetype.vcproj,
5798 builds/win32/visualce/index.html,
5799 builds/wince/vc2005-ce/freetype.vcproj,
5800 builds/wince/vc2005-ce/index.html,
5801 builds/wince/vc2008-ce/freetype.vcproj,
5802 builds/wince/vc2008-ce/index.html: s/2.4.4/2.4.5/, s/244/245/.
5804 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 5.
5806 * builds/unix/configure.raw (version_info): Set to 13:0:7.
5808 2011-06-20 Werner Lemberg <wl@gnu.org>
5810 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Fix change
5813 2011-06-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5815 [gxvalid] make the `prop' validation tracing verbose.
5817 * src/gxvalid/gxvprop.c: Add tracing messages for errors.
5819 2011-06-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5821 [autogen.sh] Reflect environment variable LIBTOOLIZE.
5823 2011-06-18 Werner Lemberg <wl@gnu.org>
5825 Update license documentation.
5827 * docs/GPL.TXT: Renamed to...
5828 * docs/GPLv2.TXT: This.
5830 * docs/LICENSE.TXT: Updated.
5832 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5834 Fix g++4.6 compiler warnings in module drivers.
5836 The background is same with previous commit.
5838 * src/truetype/ttgxvar.c (ft_var_readpackedpoints):
5839 Init `points'. (TT_Vary_Get_Glyph_Deltas): Init
5840 `delta_xy'. (TT_Get_MM_Var): Init `mmvar'.
5841 * src/type1/t1load.c (T1_Get_MM_Var): Ditto.
5842 * src/cff/cffdrivr.c (cff_ps_get_font_info): Init
5844 * src/cff/cffload.c (cff_index_get_pointers): Init `t'.
5845 (cff_font_load): Init `sub'.
5846 * src/cff/cffobjs.c (cff_size_init): Init `internal'.
5847 (cff_face_init): Init `cff'.
5848 * src/pfr/pfrload.c (pfr_extra_item_load_stem_snaps):
5850 * src/pcf/pcfread.c (pcf_get_properties): Init `properties'.
5851 (pcf_get_bitmaps): Init `offsets'. (pcf_get_encodings):
5853 * src/sfnt/ttload.c (tt_face_load_gasp): Init `gaspranges'.
5854 * src/sfnt/ttsbit.c (Load_SBit_Image): Init `components'.
5855 * src/cache/ftcmru.c (FTC_MruList_New): Init `node'.
5856 * src/gzip/ftgzip.c (FT_Stream_OpenGzip): Init `zip' and
5858 * src/lzw/ftlzw.c (FT_Stream_OpenLZW): Init `zip'.
5859 * src/bzip2/ftbzip2.c (FT_Stream_OpenBzip2): Init `zip'.
5861 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5863 [base] Fix g++4.6 compiler warnings in src/base/*.c.
5865 Passing uninitialized pointer to FT_NEW() families is
5866 not problematic theoretically (as far as the returned
5867 pointer is checked before writing), but g++4.6 dislikes
5868 it and warns by -Wuninitialized. Initialize them by NULL.
5870 * src/base/ftobjs.c (FT_Stream_New): Init `stream'.
5871 (new_memory_stream): Ditto.
5872 (FT_New_GlyphSlot): Init `slot'.
5873 (FT_CMap_New): Init `cmap'.
5874 (open_face_PS_from_sfnt_stream): Init `sfnt_ps'.
5875 (Mac_Read_POST_Resource): Init `pfb_data'.
5876 (Mac_Read_sfnt_Resource): Init `sfnt_data'.
5877 * src/base/ftrfork.c (FT_Raccess_Get_DataOffsets):
5878 Init `offsets_internal' and `ref'.
5879 (raccess_guess_darwin_hfsplus): Init `newpath'.
5880 (raccess_guess_darwin_newvfs): Ditto.
5881 * src/base/ftbitmap.c (ft_bitmap_assure_buffer):
5883 * src/base/ftstroke.c (FT_Stroker_New): Init `stroker'.
5885 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5889 Some invalid, overrunning, unrecommended non-zero values
5890 are cared in paranoid validation mode only. There are
5891 many lines looking like:
5893 if ( valid->root->level >= FT_VALIDATE_PARANOID )
5896 To simplify them, GXV_SET_ERR_IF_PARANOID( err ) is
5897 introduced for more paranoid validation in future.
5899 * src/gxvalid/gxvcommn.h (IS_PARANOID_VALIDATION):
5900 New macro to assure valid->root->level is more or
5901 equal to FT_VALIDATE_PARANOID. (GXV_SET_ERR_IF_PARANOID):
5902 New macro to raise an error if in paranoid validation.
5903 * src/gxvalid/gxvcommn.c: Use GXV_SET_ERR_IF_PARANOID().
5904 * src/gxvalid/gxvfeat.c: Ditto.
5905 * src/gxvalid/gxvjust.c: Ditto.
5906 * src/gxvalid/gxvkern.c: Ditto.
5907 * src/gxvalid/gxvmort.c: Ditto.
5908 * src/gxvalid/gxvmort0.c: Ditto.
5909 * src/gxvalid/gxvmort1.c: Ditto.
5910 * src/gxvalid/gxvmort2.c: Ditto.
5911 * src/gxvalid/gxvmorx1.c: Ditto.
5912 * src/gxvalid/gxvmorx2.c: Ditto.
5914 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5916 [gxvalid] Fix gcc4.6 compiler warnings in gxvtrak.c.
5918 * src/gxvalid/gxvtrak.c (gxv_trak_trackTable_validate):
5919 Check different entries pointing same traking value.
5920 (gxv_trak_validate): Remove unused variable `table_size'.
5922 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5924 [gxvalid] Fix gcc4.6 compiler warnings in gxvmorx*.c.
5926 * src/gxvalid/gxvmorx.c (gxv_morx_subtables_validate):
5927 Conditionalize unvalidated variable `subFeatureFlags'.
5928 (gxv_morx_chain_validate): Conditionalize unvalidated
5929 variable `defaultFlags'.
5931 * src/gxvalid/gxmorx0.c
5932 (gxv_morx_subtable_type0_entry_validate):
5933 Conditionalize unvalidated variables; `markFirst',
5934 `dontAdvance', `markLast', `verb'.
5936 * src/gxvalid/gxmorx1.c
5937 (gxv_morx_subtable_type1_entry_validate): Conditionalize
5938 unvalidated variables; `setMark', `dontAdvance'.
5940 * src/gxvalid/gxvmorx2.c
5941 (gxv_morx_subtable_type2_ligActionOffset_validate):
5942 Conditionalize unvalidated variables; `last', `store'.
5943 Checking for overrunning offset is added.
5944 (gxv_morx_subtable_type2_entry_validate):
5945 Conditionalize unvalidated variables; `setComponent',
5946 `dontAdvance', `performAction'.
5947 (gxv_morx_subtable_type2_ligatureTable_validate):
5948 Check if the GID for ligature does not exceed the
5949 max GID in `maxp' table.
5951 * src/gxvalid/gxvmort5.c
5952 (gxv_morx_subtable_type5_InsertList_validate):
5953 Conditionalize unvalidated loading of `insert_glyphID'
5954 array. (gxv_morx_subtable_type5_entry_validate):
5955 Conditionalize unvalidated variables; `setMark',
5956 `dontAdvance', `currentIsKashidaLike',
5957 `markedIsKashidaLike', `currentInsertBefore',
5958 `markedInsertBefore'.
5960 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5962 [gxvalid] Fix gcc4.6 compiler warnings in gxvmort*.c.
5964 * src/gxvalid/gxvmort.c (gxv_mort_subtables_validate):
5965 Conditionalize unvalidated variable `subFeatureFlags'.
5966 (gxv_mort_chain_validate): Conditionalize unvalidated
5967 variable `defaultFlags'.
5969 * src/gxvalid/gxmort0.c
5970 (gxv_mort_subtable_type0_entry_validate): Check the
5971 conflict of the marks for the glyphs.
5973 * src/gxvalid/gxmort1.c
5974 (gxv_mort_subtable_type1_offset_to_subst_validate):
5975 Local variables `min_gid', `max_gid' are replaced by
5976 variables in the validator.
5977 (gxv_mort_subtable_type1_entry_validate): Conditionalize
5978 unvalidated variables; `setMark', `dontAdvance'.
5979 (gxv_mort_subtable_type1_substTable_validate):
5980 Validate the GID by the min/max GIDs in the validator.
5982 * src/gxvalid/gxvmort2.c
5983 (gxv_mort_subtable_type2_ligActionOffset_validate):
5984 Conditionalize unvalidated variables; `last', `store'.
5985 Checking for overrunning offset is added.
5986 (gxv_mort_subtable_type2_entry_validate):
5987 Conditionalize unvalidated variables; `setComponent',
5989 (gxv_mort_subtable_type2_ligatureTable_validate):
5990 Check if the GID for ligature does not exceed the
5991 max GID in `maxp' table.
5993 * src/gxvalid/gxvmort5.c
5994 (gxv_mort_subtable_type5_InsertList_validate):
5995 Conditionalize unvalidated loading of `insert_glyphID'
5996 array. (gxv_mort_subtable_type5_entry_validate):
5997 Conditionalize unvalidated variables; `setMark',
5998 `dontAdvance', `currentIsKashidaLike',
5999 `markedIsKashidaLike', `currentInsertBefore',
6000 `markedInsertBefore'.
6002 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6004 [gxvalid] Fix gcc4.6 compiler warnings in gxvkern.c.
6006 * src/gxvalid/gxvkern.c
6007 (gxv_kern_subtable_fmt0_pairs_validate): Conditionalize
6008 unvalidated variable `kernValue'.
6009 (gxv_kern_subtable_fmt1_entry_validate): Conditionalize
6010 unvalidated variables; `push', `dontAdvance', `kernAction',
6012 (gxv_kern_coverage_new_apple_validate): Conditionalize
6013 trace-only variables; `kernVertical', `kernCrossStream',
6015 (gxv_kern_coverage_classic_apple_validate): Conditionalize
6016 trace-only variables; `horizontal', `cross_stream'.
6017 (gxv_kern_coverage_classic_microsoft_validate):
6018 Conditionalize trace-only variables; `horizontal',
6019 `minimum', `cross_stream', `override'.
6020 (gxv_kern_subtable_validate): Conditionalize trace-only
6021 variables; `version', `tupleIndex'.
6023 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6025 [gxvalid] Fix gcc4.6 compiler warnings in gxvjust.c.
6027 * src/gxvalid/gxvjust.c (gxv_just_check_max_gid):
6028 New function to unify the checks of too large GID.
6029 (gxv_just_wdp_entry_validate): Conditionalize unvalidated
6030 variables; `beforeGrowLimit', `beforeShrinkGrowLimit',
6031 `afterGrowLimit', `afterShrinkGrowLimit', `growFlags',
6032 `shrinkFlags'. Additional check for non-zero values in
6033 unused storage `justClass' is added.
6034 (gxv_just_actSubrecord_type0_validate): Conditionalize
6035 unvalidated variable `order'. GID is checked by
6036 gxv_just_check_max_gid(). Additional check for upside-down
6037 relationship between `lowerLimit' and `upperLimit' is added.
6038 (gxv_just_actSubrecord_type1_validate): GID is checked by
6039 gxv_just_check_max_gid().
6040 (gxv_just_actSubrecord_type2_validate): Conditionalize
6041 unvalidated variable `substThreshhold'. GID is checked by
6042 gxv_just_check_max_gid().
6043 (gxv_just_actSubrecord_type5_validate): GID is checked by
6044 gxv_just_check_max_gid().
6045 (gxv_just_classTable_entry_validate): Conditionalize
6046 unvalidated variables; `setMark', `dontAdvance',
6047 `markClass', `currentClass'.
6049 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6051 [gxvalid] Preparation to fix gcc4.6 compiler warnings.
6053 * src/gxvalid/gxvcommn.h (GXV_LOAD_TRACE_VARS): New macro to
6054 conditionalize the variable which is only used for trace messages.
6055 Automatically set by FT_DEBUG_LEVEL_TRACE.
6056 (GXV_LOAD_UNUSED_VARS): New macro to conditionalize the loading of
6057 unvalidated variables. Undefined by default to calm gcc4.6 warning.
6058 (GXV_ValidatorRec.{min_gid,max_gid}): New variables to hold defined
6059 GID ranges, for the comparison of GID ranges in different subtables.
6061 2011-06-08 Werner Lemberg <wl@gnu.org>
6063 [autofit] Remove unused structure member.
6065 * src/autofit/afhints.h (AF_SegmentRec): Remove `contour'.
6066 * src/autofit/aflatin.c (af_latin_hints_compute_segments),
6067 src/autofit/aflatin2.c (af_latin2_hints_compute_segments): Updated.
6069 2011-05-30 Werner Lemberg <wl@gnu.org>
6071 Fix g++ 4.6 compilation.
6073 * src/autofit/afhints.c (af_glyph_hints_dump_segments,
6074 af_glyph_hints_dump_edges): Use cast.
6076 2011-05-30 Werner Lemberg <wl@gnu.org>
6078 Fix gcc 4.6 compiler warnings.
6080 * src/autofit/afcjk.c (af_cjk_metrics_init_blues): Use casts and
6081 remove unused variables.
6082 * src/autofit/aflatin.c (af_latin_hints_compute_edges): Comment out
6084 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use `height_org'
6085 and `width_org' conditionalized.
6087 2011-05-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6089 [mac] Conditionalize the inclusion of `AvailabilityMacros.h'.
6091 The native SDK on earliest Mac OS X (10.0-10.1) did not have
6092 `AvailabilityMacros.h'. To prevent the inclusion of missing
6093 header file, ECANCELED (introduced in 10.2) in POSIX header
6094 file <errno.h> is checked to detect the system version.
6096 * include/freetype/config/ftconfig.h: Conditionalize the
6097 inclusion of `AvailabilityMacros.h'.
6098 * builds/unix/ftconfig.in: Ditto.
6099 * builds/vms/ftconfig.h: Ditto.
6101 2011-05-27 Werner Lemberg <wl@gnu.org>
6103 [autofit] Improve tracing of hinting process.
6105 * src/autofit/aflatin.c (af_latin_hint_edges): Add tracing message
6108 2011-05-26 Werner Lemberg <wl@gnu.org>
6110 [autofit] Fix trace message.
6112 * src/autofit/aflatin.c (af_latin_hint_edges): Show correct value in
6115 2011-05-24 Daniel Zimmermann <netzimme@googlemail.com>
6117 Reduce warnings for MS Visual Studio 2010.
6119 * src/autofit/afhints.c (af_glyph_hints_get_num_segments,
6120 af_glyph_hints_get_segment_offset) [!FT_DEBUG_AUTOFIT]: Provide
6122 * src/cff/cffgload.c (cff_slot_load): Add cast.
6123 * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids): Use proper
6126 2011-05-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6128 Automake component `builds/unix/install-sh' is removed.
6130 * builds/unix/install-sh: Removed. It is not needed to
6131 include repository, because autogen.sh installs it.
6132 * builds/unix/.gitignore: Register install-sh.
6134 2011-05-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6136 [autofit] Make trace message for CJK bluezone more verbose.
6138 2011-05-08 Just Fill Bugs <mozbugbox@yahoo.com.au>
6139 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6141 [autofit] Add bluezones for CJK Ideographs.
6143 To remove extremas of vertical strokes of CJK Ideographs at
6144 low resolution and make the top and bottom horizontal stems
6145 aligned, bluezones for CJK Ideographs are calculated from
6146 sample glyphs. At present, vertical bluezones (bluezones
6147 to align vertical stems) are disabled by default. For detail, see
6148 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00070.html
6149 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00092.html
6150 http://lists.gnu.org/archive/html/freetype-devel/2011-05/msg00001.html
6152 * include/freetype/internal/fttrace.h: New trace component `afcjk'.
6153 * src/autofit/afcjk.h (AF_CJK{Blue,Axis,Metric}Rec): Add CJK version
6154 for AF_Latin{Blue,Axis,Metric}Rec.
6155 (af_cjk_metrics_check_digits): Ditto, shared with Indic module.
6156 (af_cjk_metrics_init_widths): Ditto.
6157 (af_cjk_metrics_init): Take AF_CJKMetric instead of AF_LatinMetric.
6158 (af_cjk_metrics_scale): Ditto (declaration).
6159 (af_cjk_hints_init): Ditto (declaration).
6160 (af_cjk_hints_apply): Ditto (declaration).
6161 * src/autofit/afcjk.c (af_cjk_metrics_scale): Ditto (body).
6162 (af_cjk_hints_init): Ditto (body).
6163 (af_cjk_hints_apply): Ditto (body).
6164 (af_cjk_metrics_init_widths): Duplicate af_latin_metrics_init_widths.
6165 (af_cjk_metrics_check_digits): Duplicate af_latin_metrics_check_digits.
6166 (af_cjk_metrics_init): Call CJK bluezone initializer.
6167 (af_cjk_metrics_scale_dim): Add code to scale bluezones.
6168 (af_cjk_hints_compute_blue_edges): New function, CJK version of
6169 af_latin_hints_compute_blue_edges.
6170 (af_cjk_metrics_init_blues): New function, CJK version of
6171 af_latin_metrics_init_blues.
6172 (af_cjk_hints_edges): Add code to align the edge stems to blue zones.
6174 * src/autofit/afindic.c (af_indic_metrics_init): Take AF_CJKMetric
6175 instead of AF_LatinMetric, and initialize as af_cjk_metrics_init.
6176 However bluezones are not initialized.
6177 (af_indic_metrics_scale): Take AF_CJKMetric instead of AF_LatinMetric.
6178 (af_indic_hints_init): Ditto.
6179 (af_indic_hints_apply): Ditto.
6181 * docs/CHANGES: Note about CJK bluezone support.
6183 2011-05-06 Werner Lemberg <wl@gnu.org>
6185 [autofit] Remove unused struct member.
6187 * src/autofit/aflatin.h (AF_LatinAxis): Remove `control_overshoot'.
6189 2011-05-04 Werner Lemberg <wl@gnu.org>
6191 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Simplify.
6193 2011-05-01 Just Fill Bugs <mozbugbox@yahoo.com.au>
6194 Werner Lemberg <wl@gnu.org>
6196 [autofit] Add more debugging functions.
6198 * src/autofit/afhints.c (af_glyph_hints_get_num_segments,
6199 af_glyph_hints_get_segment_offset): New functions.
6201 2011-05-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6203 Add new option `--disable-mmap' to configure script.
6205 * builds/unix/configure.raw: New option `--disable-mmap'
6206 is added. It is for the developers to simulate the systems
6207 without mmap() (like 4.3BSD, minix etc) on POSIX systems.
6209 2011-04-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6211 [truetype] Always recalculate the sfnt table checksum.
6213 * src/truetype/ttobjs.c (tt_get_sfnt_checksum): Recalculate
6214 the sfnt table checksum even if non-zero value is written in
6215 the TrueType font header. Some bad PDF generators write
6216 wrong values. For details see examples and benchmark tests
6217 of the latency by recalculation:
6218 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00091.html
6219 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00096.html
6221 2011-04-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6223 [truetype] Register a set of tricky fonts, NEC FA family.
6225 * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids):
6226 Add 8 checksum sets for NEC FA family. For the tricky fonts
6227 without some tables (e.g. NEC FA fonts lack cvt table),
6228 extra check is added to assure that a zero-length table in the
6229 registry is not included in the font.
6231 2011-04-29 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6233 [truetype] Fix a bug in the sfnt table checksum getter.
6235 * src/truetype/ttobjs.c (tt_get_sfnt_checksum): Check the
6236 return value of face->goto_table() correctly.
6238 2011-04-28 Werner Lemberg <wl@gnu.org>
6240 [autofit] Improve tracing messages.
6242 * src/autofit/aflatin.c (af_latin_metrics_init_blues,
6243 af_latin_align_linked_edge, af_latin_hint_edges): Do it.
6245 2011-04-25 Kan-Ru Chen <kanru@kanru.info>
6247 [truetype] Always check the checksum to identify tricky fonts.
6249 Because some PDF generators mangle the family name badly,
6250 the trickyness check by the checksum should be invoked always.
6252 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00073.html
6254 * src/truetype/ttobjs.c (tt_check_trickyness): Even when
6255 tt_check_trickyness_family() finds no trickyness,
6256 tt_check_trickyness_sfnt_ids() is invoked.
6258 2011-04-22 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6260 [autofit] Add more Indic scripts with hanging baseline.
6262 * src/autofit/afindic.c (af_indic_uniranges): Tibetan, Limbu,
6263 Sundanese, Meetei Mayak, Syloti Nagri and Sharada scripts are
6266 2011-04-21 Behdad Esfahbod <behdad@behdad.org>
6268 Always ignore global advance.
6270 This makes FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH redundant,
6271 deprecated, and ignored. The new behavior is what every major user
6272 of FreeType has been requesting. Global advance is broken in many
6273 CJK fonts. Just ignoring it by default makes most sense.
6275 * src/truetype/ttdriver.c (tt_get_advances),
6276 src/truetype/ttgload.c (TT_Get_HMetrics, TT_Get_VMetrics,
6277 tt_get_metrics, compute_glyph_metrics, TT_Load_Glyph),
6278 src/truetype/ttgload.h: Implement it.
6280 * docs/CHANGES: Updated.
6282 2011-04-21 rainy6144 <rainy6144@gmail.com>
6284 [autofit] Blur CJK stems if too many to preserve their gaps.
6286 When there are too many stems to preserve their gaps in the
6287 rasterization of CJK Ideographs at a low resolution, blur the
6288 stems instead of showing clumped stems. See
6289 http://lists.gnu.org/archive/html/freetype-devel/2011-02/msg00011.html
6290 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00046.html
6293 * src/autofit/afcjk.c (af_cjk_hint_edges): Store the position of
6294 the previous stem by `has_last_stem' and `last_stem_pos', and skip
6295 a stem if the current and previous stem are too near to preserve
6298 2011-04-18 Werner Lemberg <wl@gnu.org>
6300 Integrate autofitter debugging stuff.
6302 * devel/ftoption.h, include/freetype/config/ftoption.h
6303 (FT_DEBUG_AUTOFIT): New macro.
6305 * include/freetype/internal/fttrace.h: Add trace components for
6308 * src/autofit/aftypes.h (AF_LOG): Removed.
6309 (_af_debug): Removed.
6311 * src/autofit/*: s/AF_DEBUG/FT_DEBUG_AUTOFIT/.
6312 s/AF_LOG/FT_TRACE5/.
6313 Define FT_COMPONENT where necessary.
6315 2011-04-18 Werner Lemberg <wl@gnu.org>
6317 Synchronize config files.
6319 * builds/unix/ftconfig.in: Copy missing assembler routines from
6320 include/freetype/config/ftconfig.h.
6322 2011-04-13 Werner Lemberg <wl@gnu.org>
6324 [psaux] Fix Savannah bug #33047.
6326 Patch submitted by anonymous reporter.
6328 * src/psaux/psobjs.c (ps_table_add): Use FT_PtrDist for pointer
6331 2011-04-11 Kan-Ru Chen <kanru@kanru.info>
6333 Fix reading of signed integers from files on 64bit platforms.
6335 Previously, signed integers were converted to unsigned integers, but
6336 this can fail because of sign extension. For example, 0xa344a1eb
6337 becomes 0xffffffffa344a1eb.
6339 We now do the reverse which is always correct because the integer
6340 size is the same during the cast from unsigned to signed.
6342 * include/freetype/internal/ftstream.h, src/base/ftstream.c
6343 (FT_Stream_Get*): Replace with...
6344 (FT_Stream_GetU*): Functions which read unsigned integers.
6345 Update all macros accordingly.
6347 * src/gzip/ftgzip.c (ft_gzip_get_uncompressed_size): Updated.
6349 2011-04-07 Werner Lemberg <wl@gnu.org>
6351 Update Unicode ranges for CJK autofitter; in particular, add Hangul.
6353 * src/autofit/afcjk.c (af_cjk_uniranges): Update to Unicode 6.0.
6355 2011-04-04 Werner Lemberg <wl@gnu.org>
6357 Fix formatting of autofit debug dumps.
6359 * src/autofit/afhints.c (af_glyph_hints_dump_points,
6360 af_glyph_hints_dump_segments, af_glyph_hints_dump_edges): Adjust
6363 2011-03-30 Werner Lemberg <wl@gnu.org>
6365 * src/autofit/aftypes.h (AF_OutlineRec): Removed, unused.
6367 2011-03-24 Werner Lemberg <wl@gnu.org>
6369 * src/cff/cfftypes.h (CFF_MAX_CID_FONTS): Increase to 256.
6370 This limit is given on p. 37 of Adobe Technical Note #5014.
6372 2011-03-23 Werner Lemberg <wl@gnu.org>
6374 * src/truetype/ttpload.c (tt_face_load_loca): Fix mismatch warning.
6376 2011-03-20 Werner Lemberg <wl@gnu.org>
6378 * src/sfnt/sfobjs.c (sfnt_open_font): Check number of TTC subfonts.
6380 2011-03-19 Werner Lemberg <wl@gnu.org>
6382 More C++ compilation fixes.
6384 * src/autofit/afhints.c (af_glyph_hints_dump_points,
6385 af_glyph_hints_dump_segments, af_glyph_hints_dump_edges)
6386 [__cplusplus]: Protect with `extern "C"'.
6388 2011-03-18 Werner Lemberg <wl@gnu.org>
6390 C++ compilation fixes.
6392 * src/autofit/aflatin.c (af_latin_hints_apply), src/autofit/afcjk.c
6393 (af_cjk_hints_apply): Use cast for `dim'.
6395 2011-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
6397 A better fix for Savannah bug #32671.
6399 * src/smooth/ftgrays.c (gray_render_conic): Clean up code and
6400 replace WHILE loop with a more natural DO-WHILE construct.
6402 2011-03-16 Werner Lemberg <wl@gnu.org>.
6404 * src/base/ftstroke.c (FT_StrokerRec): Remove unused `valid' field.
6405 Suggested by Graham Asher.
6407 2011-03-09 Werner Lemberg <wl@gnu.org>
6409 Make FT_Sfnt_Table_Info return the number of SFNT tables.
6411 * src/sfnt/sfdriver.c (sfnt_table_info): Implement it.
6412 * include/freetype/tttables.h: Update documentation.
6413 * docs/CHANGES: Updated.
6415 2011-03-07 Bram Tassyns <bramt@enfocus.be>
6417 [cff] Fix Savannah bug #27988.
6419 * src/cff/cffobjs.c (remove_style): New function.
6420 (cff_face_init): Use it to strip off the style part of the family
6423 2011-03-07 Werner Lemberg <wl@gnu.org>
6425 * docs/CHANGES: Updated.
6427 2011-03-07 Alexei Podtelezhnikov <apodtele@gmail.com>
6429 Quick fix for Savannah bug #32671.
6431 This isn't the optimal solution yet, but it restores the previous
6432 rendering quality (more or less).
6434 * src/smooth/ftgrays.c (gray_render_conic): Do more splitting.
6436 2011-03-06 Werner Lemberg <wl@gnu.org>
6438 Fix autohinting fallback.
6440 * src/base/ftobjs.c (FT_Load_Glyph): Assure that we only check TTFs,
6441 ignoring CFF-based OTFs.
6443 2011-02-27 Werner Lemberg <wl@gnu.org>
6445 Add AF_CONFIG_OPTION_USE_WARPER to control the autofit warper.
6447 * devel/ftoption.h, include/freetype/config/ftoption.h
6448 (AF_CONFIG_OPTION_USE_WARPER): New macro.
6449 * src/autofit/aftypes.h (AF_USE_WARPER): Remove.
6451 * src/autofit/*: s/AF_USE_WARPER/AF_CONFIG_OPTION_USE_WARPER/.
6453 * src/autofit/afwarp.c [!AF_CONFIG_OPTION_USE_WARPER]: Replace dummy
6454 variable assignment with a typedef.
6456 2011-02-26 Werner Lemberg <wl@gnu.org>
6458 [autofit] Slight simplifications.
6460 * src/autofit/aflatin.c (af_latin_hints_link_segments): Remove
6461 test which always returns false.
6462 (af_latin_hints_compute_blue_edges): Remove redundant assignment.
6464 2011-02-24 Werner Lemberg <wl@gnu.org>
6466 * docs/PROBLEMS: Mention rendering differences on different
6468 Suggested and worded by Jason Owen <jason.a.owen@gmail.com>.
6470 2011-02-24 Werner Lemberg <wl@gnu.org>
6472 [autofit] Comment out unused code.
6474 * src/autofit/aflatin.c, src/autofit/aflatin2.c
6475 (af_latin_hints_compute_edges): Do it.
6477 2011-02-24 Werner Lemberg <wl@gnu.org>
6479 * src/autofit/afhints.h (AF_GlyphHints): Remove unused field.
6481 2011-02-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6483 [cache] Fix an off-by-one bug in `FTC_Manager_RemoveFaceID'.
6484 Found by <ychen1392001@yahoo.com.cn>, see detail in
6486 http://lists.gnu.org/archive/html/freetype/2011-01/msg00023.html
6488 * src/cache/ftccache.c (FTC_Cache_RemoveFaceID): Check the node
6489 buckets[cache->p + cache->mask] too.
6491 2011-02-19 Kevin Kofler <kevin.kofler@chello.at>
6493 Fall back to autohinting if a TTF/OTF doesn't contain any bytecode.
6494 This is Savannah patch #7471.
6496 * src/base/ftobjs.c (FT_Load_Glyph): Implement it.
6498 2011-02-19 John Tytgat <John.Tytgat@esko.com>
6500 [cff] Fix subset prefix removal.
6501 This is Savannah patch #7465.
6503 * src/cff/cffobjs.c (remove_subset_prefix): Update length after
6504 subset prefix removal.
6506 2011-02-13 Bradley Grainger <bgrainger@logos.com>
6508 Add inline assembly version of FT_MulFix for MSVC.
6510 * include/freetype/config/ftconfig.h: Ported the FT_MulFix_i386
6511 function from GNU inline assembly syntax (see #ifdef __GNUC__ block
6512 above) to MASM syntax for Microsoft Visual C++.
6514 2011-02-13 Bradley Grainger <bgrainger@logos.com>
6516 Add project and solution files in Visual Studio 2010 format.
6518 * builds/win32/.gitignore: Ignore user-specific cache files.
6519 * builds/win32/vc2010/: Add VS2010 project & solution files, created
6520 by upgrading builds/win32/vc2008/freetype.vcproj.
6521 * objs/.gitignore: Ignore Visual Studio output files.
6523 2011-02-01 Werner Lemberg <wl@gnu.org>
6525 * src/autofit/afdummy.c: Include `aferrors.h'.
6526 Problem reported by Chris Liddell <chris.liddell@artifex.com>.
6528 2011-02-01 Werner Lemberg <wl@gnu.org>
6530 [cff] Ignore unknown operators in charstrings.
6531 Patch suggested by Miles.Lau <sunliang_liu@foxitsoftware.com>.
6533 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Emit tracing
6534 message for unknown operators and continue instead of exiting with a
6537 2011-02-01 Werner Lemberg <wl@gnu.org>
6539 [truetype] FT_LOAD_PEDANTIC now affects `prep' and `fpgm' also.
6541 * src/truetype/ttgload.c (tt_loader_init): Handle
6543 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep,
6544 tt_size_init_bytecode, tt_size_ready_bytecode): New argument to
6545 handle pedantic mode.
6546 * src/truetype/ttobjs.h: Updated.
6548 2011-01-31 Werner Lemberg <wl@gnu.org>
6550 [truetype] Protect jump instructions against endless loops.
6552 * src/truetype/interp.c (DO_JROT, DO_JMPR, DO_JROF): Exit with error
6555 2011-01-31 Werner Lemberg <wl@gnu.org>
6557 [truetype] Improve handling of invalid references.
6559 * src/truetype/interp.c: Set even more TT_Err_Invalid_Reference
6560 error codes only if pedantic hinting is active. At the same time,
6561 try to provide sane values which hopefully allow useful
6562 continuation. Exception to this is CALL and LOOPCALL – due to
6563 possible stack corruption it is necessary to bail out.
6565 2011-01-31 Werner Lemberg <wl@gnu.org>
6567 [truetype] Improve handling of stack underflow.
6569 * src/truetype/ttinterp.c (TT_RunIns, Ins_FLIPPT, Ins_DELTAP,
6570 Ins_DELTAC): Exit with error only if `pedantic_hinting' is set.
6571 Otherwise, try to do something sane.
6573 2011-01-30 Werner Lemberg <wl@gnu.org>
6575 * src/sfnt/ttmtx.c (tt_face_load_hmtx): Fix tracing message.
6577 2011-01-30 LIU Sun-Liang <sunliang_liu@foxitsoftware.com>
6579 [truetype]: Fix behaviour of MIAP for invalid arguments.
6581 * src/truetype/ttinterp.c (Ins_MIAP): Set reference points even in
6584 2011-01-18 Werner Lemberg <wl@gnu.org>
6586 [truetype] Fix handling of MIRP instruction.
6588 Thanks to Greg Hitchcock who explained the issue.
6590 * src/truetype/ttinterp.c (Ins_MIRP): Replace a `>=' operator with
6591 `>' since the description in the specification is incorrect.
6592 This fixes, for example, glyph `two' in font `Helvetica Neue LT Com
6593 65 medium' at 15ppem.
6595 2011-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6597 Fix ARM assembly code in include/freetype/config/ftconfig.h.
6599 * include/freetype/config/ftconfig.h (FT_MulFix_arm):
6600 Copy the maintained code from builds/unix/ftconfig.in.
6601 Old GNU binutils could not accept the reduced syntax
6602 `orr %0, %2, lsl #16'. Un-omitted syntax like RVCT,
6603 `orr %0, %0, %2, lsl #16' is better. Reported by
6604 Johnson Y. Yan. The bug report by Qt developers is
6607 http://bugreports.qt.nokia.com/browse/QTBUG-6521
6609 2011-01-15 Werner Lemberg <wl@gnu.org>
6611 [raster] Make bbox handling the same as with Microsoft's rasterizer.
6613 Right before B/W rasterizing, the bbox gets simply rounded to
6614 integers. This fixes, for example, glyph `three' in font `Helvetica
6615 Neue LT Com 65 Medium' at 11ppem.
6617 Thanks to Greg Hitchcock who explained this behaviour.
6619 * src/raster/ftrend1.c (ft_raster1_render): Implement it.
6621 2011-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6623 Copy -mcpu=* & -march=* options from CFLAGS to LDFLAGS.
6625 * builds/unix/configure.raw: Consider recent gcc-standard
6626 flags to specify architecture in CFLAGS & LDFLAGS
6627 harmonization. Requested by Savannah bug #32114, to
6628 support multilib feature of BuildRoot SDK correctly.
6630 2011-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6632 Fix off-by-one bug in CFLAGS & LDFLAGS harmonizer.
6634 * builds/unix/configure.raw: Some important options that
6635 included in CFLAGS but not in LDFLAGS are copied to
6636 LDFLAGS, but the last option in CFLAGS was not checked.
6638 2011-01-13 Werner Lemberg <wl@gnu.org>
6640 [raster] Add undocumented drop-out rule to the other bbox side also.
6642 * src/raster/ftraster.c (Vertical_Sweep_Drop,
6643 Horizontal_Sweep_Drop): Implement it.
6645 2011-01-13 Werner Lemberg <wl@gnu.org>
6647 [raster] Reduce jitter value.
6649 This catches a rendering problem with glyph `x' from Tahoma at
6650 10ppem. It seems that the increase of the precision in the change
6651 from 2009-06-11 makes a larger jitter value unnecessary.
6653 * src/raster/ftraster.c (Set_High_Precision): Implement it.
6655 2011-01-13 Werner Lemberg <wl@gnu.org>
6657 [raster] Handle drop-outs at glyph borders according to Microsoft.
6659 If a drop-out rule would switch on a pixel outside of the glyph's
6660 bounding box, use the right (or top) pixel instead. This is an
6661 undocumented feature, but some fonts like `Helvetica Neue LT Com 65
6662 Medium' heavily rely on it.
6664 Thanks to Greg Hitchcock who explained this behaviour.
6666 * src/raster/ftraster.c (Vertical_Sweep_Drop,
6667 Horizontal_Sweep_Drop): Implement it.
6669 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6671 [cache] Fix Savannah bug #31923, patch drafted by Harsha.
6673 When a node comparator changes the cached nodes during the
6674 search of a node matching with queried properties, the
6675 pointers obtained before the function should be updated to
6676 prevent the dereference to freed or reallocated nodes.
6677 To minimize the rescan of the linked list, the update is
6678 executed when the comparator notifies the change of cached
6679 nodes. This change depends previous change:
6680 38b272ffbbdaae276d636aec4ef84af407d16181
6682 * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): Rescan the
6683 top node if the cached nodes are changed.
6684 * src/cache/ftccache.c (FTC_Cache_Lookup): Ditto.
6686 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6688 [cache] Notice if a cache query induced the node list change.
6690 Some node comparators (comparing the cache node contents and the
6691 properties specified by the query) can flush the cache node to
6692 prevent the cache inflation. The change may invalidate the pointers
6693 to the node obtained before the node comparison, so it should be
6694 noticed to the caller. The problem caused by the cache node
6695 changing is reported by Harsha, see Savannah bug #31923.
6697 * src/cache/ftccache.h (FTC_Node_CompareFunc): Add new argument
6698 `FT_Bool* list_changed' to indicate the change of the cached nodes
6700 (FTC_CACHE_LOOKUP_CMP): Watch the change of the cached nodes by
6702 (FTC_CACHE_TRYLOOP_END): Take new macro argument `_list_changed'
6703 and update it when `FTC_Manager_FlushN' flushes any nodes.
6705 * src/cache/ftccback.h (ftc_snode_compare): Updated to fit with new
6706 FTC_Node_CompareFunc type.
6707 (ftc_gnode_compare): Ditto.
6709 * src/cache/ftcbasic.c: Include FT_INTERNAL_OBJECTS_H to use
6711 (ftc_basic_gnode_compare_faceid): New argument `FT_Bool*
6712 list_changed' to indicate the change of the cache nodes (anyway, it
6715 * src/cache/ftccmap.c: Include FT_INTERNAL_OBJECTS_H to use
6717 (ftc_cmap_node_compare): New argument `FT_Bool* list_changed' to
6718 indicate the change of the cache nodes (anyway, it is always FALSE).
6719 (ftc_cmap_node_remove_faceid): Ditto.
6721 * src/cache/ftccache.c (FTC_Cache_NewNode): Pass a NULL pointer to
6722 `FTC_CACHE_TRYLOOP_END', because the result is not needed.
6723 (FTC_Cache_Lookup): Watch the change of the cache nodes by
6725 (FTC_Cache_RemoveFaceID): Ditto.
6727 * src/cache/ftcglyph.c: Include FT_INTERNAL_OBJECTS_H to use
6729 (ftc_gnode_compare): New argument `FT_Bool* list_changed' to
6730 indicate the change of the cache nodes (anyway, it is always FALSE).
6731 (FTC_GNode_Compare): New argument `FT_Bool* list_changed' to be
6732 passed to `ftc_gnode_compare'.
6733 * src/cache/ftcglyph.h (FTC_GNode_Compare): Ditto.
6735 * src/cache/ftcsbits.c (ftc_snode_compare): New argument `FT_Bool*
6736 list_changed' to indicate the change of the cache nodes, anyway. It
6737 is updated by `FTC_CACHE_TRYLOOP'.
6738 (FTC_SNode_Compare): New argument `FT_Bool* list_changed' to be
6739 passed to `ftc_snode_compare'.
6740 * src/cache/ftcsbits.h (FTC_SNode_Compare): Ditto.
6742 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6744 [cache] Fit `FTC_GNode_Compare' to `FTC_Node_CompareFunc'.
6746 * src/cache/ftcglyph.h (FTC_GNode_Compare): Add the 3rd
6747 argument `FTC_Cache cache' to fit FTC_Node_CompareFunc
6749 * src/cache/ftcglyph.c (FTC_GNode_Compare): Ditto. Anyway,
6750 `cache' is not used by its child `ftc_gnode_compare'.
6752 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6754 [cache] Deduplicate the code to get the top node by a hash.
6756 There are several duplicated code fragments getting the top node
6757 from a cache by a given hash, like:
6759 idx = hash & cache->mask;
6760 if ( idx < cache->p )
6761 idx = hash & ( cache->mask * 2 + 1 );
6762 pnode = cache->buckets + idx;
6764 To remove duplication, a cpp-macro to do same work
6765 `FTC_NODE__TOP_FOR_HASH' is introduced. For non-inlined
6766 configuration, non-`ftc_get_top_node_for_hash' is also introduced.
6768 * src/cache/ftccache.h (FTC_NODE__TOP_FOR_HASH): Declare
6769 and implement inlined version.
6770 (FTC_CACHE_LOOKUP_CMP): Use `FTC_NODE__TOP_FOR_HASH'.
6771 * src/cache/ftccache.c (ftc_get_top_node_for_hash): Non-inlined
6773 (ftc_node_hash_unlink): Use `FTC_NODE__TOP_FOR_HASH'.
6774 (ftc_node_hash_link): Ditto.
6775 (FTC_Cache_Lookup): Ditto.
6777 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6779 [cache] inline-specific functions are conditionalized.
6781 * src/cache/ftcglyph.c (FTC_GNode_Compare): Conditionalized for
6782 inlined configuration. This function is a thin wrapper of
6783 `ftc_gnode_compare' for inlined `FTC_CACHE_LOOKUP_CMP' (see
6784 `nodecmp' argument). Under non-inlined configuration,
6785 `ftc_gnode_compare' is invoked by `FTC_Cache_Lookup', via
6786 `FTC_Cache->clazz.node_compare'.
6788 * src/cache/ftcglyph.h (FTC_GNode_Compare): Ditto.
6789 * src/cache/ftcsbits.c (FTC_SNode_Compare): Ditto, for
6790 `ftc_snode_compare'.
6791 * src/cache/ftcsbits.h (FTC_SNode_Compare): Ditto.
6793 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6795 [cache] Correct a type mismatch under non-inlined config.
6797 * src/cache/ftcglyph.h (FTC_GCACHE_LOOKUP_CMP): `FTC_GCache_Lookup'
6798 takes the node via a pointer `FTC_Node*', differently from cpp-macro
6799 `FTC_CACHE_LOOKUP_CMP'.
6801 2011-01-06 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6803 Update Jamfile to include Bzip2 support.
6805 * Jamfile: Include src/bzip2 to project.
6806 Comments for lzw, gzip, bzip2 are changed to clarify that
6807 they are for compressed PCF fonts, not others.
6808 (e.g. compressed BDF fonts are not supported yet)
6810 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6812 Update Symbian project files to include Bzip2 support.
6814 Currently, it provides `FT_Stream_OpenBzip2' that returns
6815 unimplemented error always, to prevent unresolved symbol
6816 error for the applications designed for Unix systems.
6818 * builds/symbian/bld.inf: Include ftbzip2.h.
6819 * builds/symbian/freetype.mmp: Include ftbzip2.c.
6821 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6823 Update classic MacOS makefiles to include Bzip2 support.
6825 Currently, it provides `FT_Stream_OpenBzip2' that returns
6826 unimplemented error always, to prevent unresolved symbol
6827 error for the applications designed for Unix systems.
6829 * builds/mac/FreeType.m68k_cfm.make.txt: Include ftbzip2.c.o.
6830 * builds/mac/FreeType.m68k_far.make.txt: Ditto.
6831 * builds/mac/FreeType.ppc_carbon.make.txt: Include ftbzip2.c.x.
6832 * builds/mac/FreeType.ppc_classic.make.txt: Ditto.
6834 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6836 Update Amiga makefiles to include Bzip2 support.
6838 Currently, it provides `FT_Stream_OpenBzip2' that returns
6839 unimplemented error always, to prevent unresolved symbol
6840 error for the applications designed for Unix systems.
6842 * builds/amiga/makefile: Include bzip2.ppc.o built from ftbzip2.c.
6843 * builds/amiga/makefile.os4: Include bzip2.o built from ftbzip2.c.
6844 * builds/amiga/smakefile: Ditto.
6846 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6848 Update pkg-config tools to reflect Bzip2 support.
6850 * builds/unix/freetype-config.in: Include `-lbz2' to
6851 --libs output, if built with Bzip2 support.
6852 * builds/unix/freetype2.in: Ditto.
6854 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6856 * builds/unix/configure.raw: Remove `SYSTEM_BZ2LIB' macro.
6858 SYSTEM_ZLIB is used to switch the builtin zlib source
6859 or system zlib source out of FreeType2. But ftbzip2
6860 module has no builtin bzip2 library and always requires
6861 system bzip2 library. Thus SYSTEM_BZ2LIB is always yes,
6864 2011-01-03 Werner Lemberg <wl@gnu.org>
6866 */rules.mk: Handle `*pic.c' files.
6868 2010-12-31 Werner Lemberg <wl@gnu.org>
6870 * src/cff/cfftypes.h (CFF_MAX_CID_FONTS): Increase to 64.
6871 Problem reported by Tom Bishop <wenlin@wenlin.com>.
6873 2010-12-31 Werner Lemberg <wl@gnu.org>
6875 Improve bzip2 support.
6877 * include/freetype/ftmoderr.h: Add bzip2.
6879 * docs/INSTALL.ANY, docs/CHANGES: Updated.
6881 * src/pcf/README: Updated.
6882 * include/freetype/internal/pcftypes.h: Obsolete, removed.
6884 2010-12-31 Joel Klinghed <the_jk@yahoo.com>
6886 Add bzip2 compression support to handle *.pcf.bz2 files.
6888 * builds/unix/configure.raw: Test for libbz2 library.
6890 * devel/ftoption.h, include/freetype/config/ftoption.h
6891 (FT_CONFIG_OPTION_USE_BZIP2): Define.
6892 * include/freetype/config/ftheader.h (FT_BZIP2_H): Define.
6894 * include/freetype/ftbzip2.h: New file.
6896 * src/bzip2/*: New files.
6898 * src/pcf/pcf.h: s/gzip_/comp_/.
6899 * src/pcf/pcfdrvr.c: Include FT_BZIP2_H.
6901 (PCF_Face_Init): Handle bzip2 compressed files.
6903 * docs/formats.txt, modules.cfg: Updated.
6905 2010-12-25 Harsha <mm.harsha@gmail.com>
6907 Apply Savannah patch #7422.
6909 If we encounter a space in a string then the sbit buffer is NULL,
6910 height and width are 0s. So the check in ftc_snode_compare will
6911 always pass for spaces (comparision with 255). Here the comments
6912 above the condition are proper but the implementation is not. When
6913 we create an snode I think it is the proper way to initialize the
6914 width to 255 and then put a check for being equal to 255 in snode
6917 * src/cache/ftcsbits.c (FTC_SNode_New): Initialize sbit widths with
6919 (ftc_snode_compare): Fix condition.
6921 2010-12-13 Werner Lemberg <wl@gnu.org>
6923 Fix parameter handling of `FT_Set_Renderer'.
6924 Reported by Kirill Tishin <siege@bk.ru>.
6926 * src/base/ftobjs.c (FT_Set_Renderer): Increment `parameters'.
6928 2010-12-09 Werner Lemberg <wl@gnu.org>
6930 [cff] Allow `hlineto' and `vlineto' without arguments.
6932 We simply ignore such instructions. This is invalid, but it doesn't
6933 harm; and indeed, there exist such subsetted fonts in PDFs.
6935 Reported by Albert Astals Cid <aacid@kde.org>.
6937 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
6938 [cff_op_hlineto]: Ignore instruction if there aren't any arguments
6941 2010-11-28 Werner Lemberg <wl@gnu.org>
6943 * Version 2.4.4 released.
6944 =========================
6947 Tag sources with `VER-2-4-4'.
6949 * docs/CHANGES: Updated.
6951 * docs/VERSION.DLL: Update documentation and bump version number to
6954 * README, Jamfile (RefDoc),
6955 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
6956 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
6957 builds/win32/visualc/freetype.dsp,
6958 builds/win32/visualc/freetype.vcproj,
6959 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
6960 builds/win32/visualce/freetype.vcproj,
6961 builds/win32/visualce/index.html,
6962 builds/wince/vc2005-ce/freetype.vcproj,
6963 builds/wince/vc2005-ce/index.html,
6964 builds/wince/vc2008-ce/freetype.vcproj,
6965 builds/wince/vc2008-ce/index.html: s/2.4.3/2.4.4/, s/243/244/.
6967 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 4.
6969 * builds/unix/configure.raw (version_info): Set to 12:2:6.
6971 2010-11-28 Alexei Podtelezhnikov <apodtele@gmail.com>
6973 [ftsmooth]: Minor code simplification.
6975 * src/smooth/ftgrays (gray_render_cubic): Do only one comparison
6978 2010-11-26 Johnson Y. Yan <yinsen_yan@foxitsoftware.com>
6980 [truetype] Better multi-threading support.
6982 * src/truetype/ttinterp.c (TT_Load_Context): Reset glyph zone
6985 2010-11-23 John Tytgat <John.Tytgat@esko.com>
6987 * src/psaux/t1decode.c (t1_decoder_parse_charstring): Expand
6988 start_point, check_points, add_point, add_point1, close_contour
6990 Remove add_contour macro.
6991 Return error code from t1_builder_start_point and
6992 t1_builder_check_points when there was one (instead of returning 0).
6994 2010-11-22 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6996 [truetype] Identify the tricky fonts by cvt/fpgm/prep checksums.
6997 Some Latin TrueType fonts are still expected to be unhinted.
6998 Fix Savannah bug #31645.
7000 * src/truetype/ttobjs.c (tt_check_trickyness): Divided to...
7001 (tt_check_trickyness_family): this checking family name, and
7002 (tt_check_trickyness_sfnt_ids): this checking cvt/fpgm/prep.
7003 (tt_get_sfnt_checksum): Function to retrieve the sfnt checksum
7004 for specified subtable even if cleared by lazy PDF generators.
7005 (tt_synth_sfnt_checksum): Function to calculate the checksum.
7007 2010-11-18 Werner Lemberg <wl@gnu.org>
7009 [truetype] Fix `loca' handling for inconsistent number of glyphs.
7010 Reported by Johnson Y. Yan <yinsen_yan@foxitsoftware.com>.
7012 * src/truetype/ttpload.c (tt_face_load_loca): While sanitizing,
7013 handle case where `loca' is the last table in the font.
7015 2010-11-18 Werner Lemberg <wl@gnu.org>
7017 [sfnt] Ignore all errors while loading `OS/2' table.
7018 Suggested by Johnson Y. Yan <yinsen_yan@foxitsoftware.com>.
7020 * src/sfnt/sfobjs.c (sfnt_load_face): Do it.
7022 2010-11-18 Johnson Y. Yan <yinsen_yan@foxitsoftware.com>
7024 [type1] Fix matrix normalization.
7026 * src/type1/t1load.c (parse_font_matrix): Handle sign of scaling
7029 2010-11-18 Werner Lemberg <wl@gnu.org>
7031 [type1] Improve guard against malformed data.
7032 Based on a patch submitted by Johnson Y. Yan
7033 <yinsen_yan@foxitsoftware.com>
7035 * src/type1/t1load.c (read_binary_data): Check `size'.
7037 2010-11-17 Werner Lemberg <wl@gnu.org>
7039 [sfnt] While tracing, output table checksums also.
7041 * src/sfnt/ttload.c (tt_face_load_font_dir): Do it.
7043 2010-11-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7045 [UVS] Fix `find_variant_selector_charmap', Savannah bug #31545.
7047 Since 2010-07-04, `find_variant_selector_charmap' returns
7048 the first cmap subtable always under rogue-compatible
7049 configuration, it causes NULL pointer dereference and
7050 make UVS-related functions crashed.
7052 * src/base/ftobjs.c (Fix find_variant_selector_charmap):
7053 Returns UVS cmap correctly.
7055 2010-11-01 Alexei Podtelezhnikov <apodtele@gmail.com>
7057 [ftsmooth] Improve rendering.
7059 * src/smooth/ftsmooth.c (gray_render_conic): Since version 2.4.3,
7060 cubic deviations have been estimated _after_ UPSCALE, whereas
7061 conic ones have been evaluated _before_ UPSCALE, which produces
7062 inferior rendering results. Fix this.
7063 Partially undo change from 2010-10-15 by using ONE_PIXEL/4; this has
7064 been tested with demo images sent to the mailing list. See
7066 http://lists.gnu.org/archive/html/freetype-devel/2010-10/msg00055.html
7068 and later mails in this thread.
7070 2010-10-28 Werner Lemberg <wl@gnu.org>
7072 [ftraster] Minor fixes.
7074 Reported by Tom Bishop <wenlin@wenlin.com>.
7076 * src/raster/ftraster.c (ULong): Remove unused typedef.
7077 (TWorker): Remove unused variable `precision_mask'.
7079 2010-10-28 Werner Lemberg <wl@gnu.org>
7081 [ftraster] Fix rendering.
7083 Problem reported by Tom Bishop <wenlin@wenlin.com>; see
7084 thread starting with
7086 http://lists.gnu.org/archive/html/freetype/2010-10/msg00049.html
7088 * src/raster/ftraster.c (Line_Up): Replace FMulDiv with SMulDiv
7089 since the involved multiplication exceeds 32 bits.
7091 2010-10-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7093 Revert a change of `_idx' type in `FTC_CACHE_LOOKUP_CMP'.
7095 * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): Revert
7096 the type of `_idx' from FT_PtrDist (by previous change)
7097 to original FT_UFast, to match with FT_CacheRec.
7099 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7101 [cache] Change the hash types to FT_PtrDist.
7103 On LLP64 platforms (e.g. Win64), FT_ULong (32-bit)
7104 variables are inappropriate to calculate hash values
7105 from the memory address (64-bit). The hash variables
7106 are extended from FT_ULong to FT_PtrDist and new
7107 hashing macro functions are introduced. The hash
7108 values on 16-bit memory platforms are changed, but
7109 ILP32 and LP64 are not changed. The hash value in
7110 the cache subsystem is not reverted to the memory
7111 address, so using signed type FT_PtrDist is safe.
7113 * src/cache/ftccache.h (_FTC_FACE_ID_HASH): New hash
7114 function to replace `FTC_FACE_ID_HASH' for portability.
7115 * src/cache/ftcmanag.h (FTC_SCALER_HASH): Replace
7116 `FTC_FACE_ID_HASH' by `_FTC_FACE_ID_HASH'.
7117 * src/cache/ftccmap.c (FTC_CMAP_HASH): Ditto.
7119 * src/cache/ftccache.h (FTC_NodeRec): The type of the
7120 member `hash' is changed from FT_UInt32 to FT_PtrDist.
7122 * src/cache/ftccache.h (FTC_Cache_Lookup): The type of the
7123 argument `hash' is changed from FT_UInt32 to FT_PtrDist.
7124 (FTC_Cache_NewNode): Ditto.
7125 * src/cache/ftccache.c (ftc_cache_add): Ditto.
7126 (FTC_Cache_Lookup): Ditto. (FTC_Cache_NewNode): Ditto.
7127 * src/cache/ftcglyph.h (FTC_GCache_Lookup): Ditto.
7128 * src/cache/ftcglyph.c (FTC_GCache_Lookup): Ditto.
7130 * src/cache/ftcbasic.c (FTC_ImageCache_Lookup): The type
7131 of the internal variable `hash' is changed to FT_PtrDist
7132 from FT_UInt32. (FTC_ImageCache_LookupScaler): Ditto.
7133 (FTC_SBitCache_Lookup): Ditto.
7134 (FTC_SBitCache_LookupScaler): Ditto.
7135 * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Ditto.
7136 * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): Ditto.
7137 Also the type of the internal variable `_idx' is changed to
7138 FT_PtrDist from FT_UFast for better pointer calculation.
7140 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7142 [cache] Hide internal macros incompatible with LLP64.
7144 `FT_POINTER_TO_ULONG', `FTC_FACE_ID_HASH', and
7145 `FTC_IMAGE_TYPE_HASH' are enclosed by
7146 FT_CONFIG_OPTION_OLD_INTERNALS and hidden from
7149 For the history of these macros, see the investigation:
7150 http://lists.gnu.org/archive/html/freetype/2010-10/msg00022.html
7152 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7154 Change the type of `FT_MEM_VAL' from FT_ULong to FT_PtrDist.
7156 On LLP64 platforms (e.g. Win64), unsigned long (32-bit)
7157 cannot cover the memory address (64-bit). `FT_MEM_VAL' is
7158 used for hashing only and not dereferred, so using signed
7159 type FT_PtrDist is safe.
7161 * src/base/ftdbgmem.c (FT_MEM_VAL): Change the type of the
7162 return value from FT_ULong to FT_PtrDist.
7163 (ft_mem_table_resize): The type of hash is changed to
7164 FT_PtrDist. (ft_mem_table_get_nodep): Ditto.
7166 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7168 Replace "%lx" for memory address by "%p", LLP64 platforms.
7170 On LLP64 platforms (e.g. Win64), long (32-bit) cannot cover
7171 the memory address (64-bit). Also the casts from the pointer
7172 type to long int should be removed to preserve the address
7175 * src/raster/ftraster.c (New_Profile): Replace "%lx" by "%p".
7176 (End_Profile) Ditto.
7177 * src/truetype/ttinterp.c (Init_Context): Ditto.
7179 2010-10-15 Alexei Podtelezhnikov <apodtele@gmail.com>
7181 Fix thinko in spline flattening.
7183 FT_MAX_CURVE_DEVIATION is dependent on the value of ONE_PIXEL.
7185 * src/smooth/ftgrays.c (FT_MAX_CURVE_DEVIATION): Remove it and
7186 replace it everywhere with ONE_PIXEL/8.
7188 2010-10-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7190 [raccess] Skip unrequired resource access rules by Darwin VFS.
7192 When a resource fork access rule by Darwin VFS could open the
7193 resource fork but no font is found in it, the rest of rules
7194 by Darwin VFS are skipped. It reduces the warnings of the
7195 deprecated resource fork access method by recent Darwin kernel.
7196 Fix MacPorts ticket #18859:
7197 http://trac.macports.org/ticket/18859
7199 * src/base/ftobjs.c (load_face_in_embedded_rfork):
7200 When `FT_Stream_New' returns FT_Err_Cannot_Open_Stream, it
7201 means that the file is possible to be `fopen'-ed but zero-sized.
7202 Also there is a case that the resource fork is not zero-sized,
7203 but no supported font exists in it. If a rule by Darwin VFS
7204 falls into such cases, there is no need to try other Darwin VFS
7205 rules anymore. Such cases are marked by vfs_rfork_has_no_font.
7206 If it is TRUE, the Darwin VFS rules are skipped.
7208 2010-10-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7210 [raccess] Grouping resource access rules based on Darwin VFS.
7212 MacOS X/Darwin kernel supports a few tricky methods to access
7213 a resource fork via ANSI C or POSIX interface. Current resource
7214 fork accessor tries all possible methods to support all kernels.
7215 But if a method could open a resource fork but no font is found,
7216 there is no need to try other methods older than tested method.
7217 To determine whether the rule index is for Darwin VFS, a local
7218 function `ftrfork.c::raccess_rule_by_darwin_vfs' is introduced.
7219 To use this function in ftobjs.c etc but it should be inlined,
7220 it is exposed by ftbase.h.
7222 * src/base/ftrfork.c (FT_RFork_Rule): New enum type to identify
7223 the rules to access the resource fork.
7224 (raccess_guess_rec): New structure to bind the rule function and
7226 (FT_Raccess_Guess): The list of the rule functions is replaced by
7227 (raccess_guess_table): This. This is exposed to be used by other
7228 intra module functions.
7229 (raccess_rule_by_darwin_vfs): A function to return a boolean
7230 if the rule specified by the rule index is based on Darwin VFS.
7232 2010-10-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7234 Prevent to open a FT_Stream for zero-sized file on non-Unix.
7236 builds/unix/ftsystem.c prevents to open an useless stream from
7237 zero-sized file and returns FT_Err_Cannot_Open_Stream, but the
7238 stream drivers for ANSI C, Amiga and VMS return useless streams.
7239 For cross-platform consistency, all stream drivers should act
7242 * src/base/ftsystem.c (FT_Stream_Open): If the size of the opened
7243 file is zero, FT_Err_Cannot_Open_Stream is returned.
7244 * builds/amiga/src/base/ftsystem.c (FT_Stream_Open): Ditto.
7245 * src/vms/ftsystem.c (FT_Stream_Open): Ditto.
7247 2010-10-12 Werner Lemberg <wl@gnu.org>
7249 [truetype] Fix Savannah bug #31310.
7251 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Protect against
7252 invalid `runcnt' values.
7254 2010-10-08 Chris Liddell <chris.liddell@artifex.com>
7256 [sfnt] Fix Savannah bug #31275.
7258 * src/sfnt/ttpost.c: Include FT_INTERNAL_DEBUG_H.
7260 2010-10-06 Werner Lemberg <wl@gnu.org>
7262 [truetype] Improve error handling of `SHZ' bytecode instruction.
7263 Problem reported by Chris Evans <scarybeasts@gmail.com>.
7265 * src/truetype/ttinterp.c (Ins_SHZ): Check `last_point'.
7267 2010-10-05 Werner Lemberg <wl@gnu.org>
7269 Fix Savannah bug #31253.
7270 Patch submitted by an anonymous reporter.
7272 * configure: Use `awk' instead of `sed' to manipulate output of `ls
7275 2010-10-03 Werner Lemberg <wl@gnu.org>
7277 * Version 2.4.3 released.
7278 =========================
7281 Tag sources with `VER-2-4-3'.
7283 * docs/CHANGES: Updated.
7285 * docs/VERSION.DLL: Update documentation and bump version number to
7288 * README, Jamfile (RefDoc),
7289 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
7290 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
7291 builds/win32/visualc/freetype.dsp,
7292 builds/win32/visualc/freetype.vcproj,
7293 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
7294 builds/win32/visualce/freetype.vcproj,
7295 builds/win32/visualce/index.html,
7296 builds/wince/vc2005-ce/freetype.vcproj,
7297 builds/wince/vc2005-ce/index.html,
7298 builds/wince/vc2008-ce/freetype.vcproj,
7299 builds/wince/vc2008-ce/index.html: s/2.4.2/2.4.3/, s/242/243/.
7301 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 3.
7303 * builds/unix/configure.raw (version_info): Set to 12:1:6.
7305 2010-10-03 Werner Lemberg <wl@gnu.org>
7307 Avoid `configure' issues with symbolic links.
7308 Based on a patch from Alexander Stohr <Alexander.Stohr@gmx.de>.
7310 * configure: Compare directories using `ls -id'.
7311 Check existence of `reference' subdirectory before creating it.
7313 2010-10-02 Werner Lemberg <wl@gnu.org>
7315 [sfnt] Fix Savannah bug #31088 (sort of).
7317 * src/sfnt/ttload.c (tt_face_load_maxp): Always allocate at least 64
7320 2010-10-02 Werner Lemberg <wl@gnu.org>
7322 [smooth] Fix splitting of cubics for negative values.
7324 Reported by Róbert Márki <gsmiko@gmail.com>; see
7325 http://lists.gnu.org/archive/html/freetype/2010-09/msg00019.html.
7327 * src/smooth/ftgrays.c (gray_render_cubic): Fix thinko.
7329 2010-10-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7331 [truetype] Fix Savannah bug #31040.
7333 * src/truetype/ttinterp.c (free_buffer_in_size): Remove.
7334 (TT_RunIns): Updated.
7336 2010-09-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7338 [sfnt] Make error message filling NULL names less verbose.
7340 * src/sfnt/ttpost.c (load_format_20): Showing 1 summary message
7341 when we fill `post' names by NULL, instead of per-entry message.
7343 2010-09-20 Graham Asher <graham.asher@btinternet.com>
7344 David Bevan <david.bevan@pb.com>
7346 [smooth] Fix and improve spline flattening.
7348 This fixes the flattening of cubic, S-shaped curves and speeds up
7349 the handling of both the conic and cubic arcs.
7351 See the discussions on the freetype-devel mailing list in late
7352 August and September 2010 for details.
7354 * src/smooth/ftgrays.c (FT_MAX_CURVE_DEVIATION): New macro.
7355 (TWorker): Remove `conic_level' and `cubic_level' elements.
7356 (gray_render_conic): Simplify algorithm.
7357 (gray_render_cubic): New algorithm; details are given in the code
7359 (gray_convert_glyph): Remove heuristics.
7361 2010-09-19 Werner Lemberg <wl@gnu.org>
7365 * src/cff/cffload.c (cff_charset_compute_cids): `charset->sids[i]'
7367 (cff_index_access_element): Don't use additions in comparison.
7368 * src/sfnt/ttpost.c (load_format_20): Make `post_limit' of type
7370 Don't use additions in comparison.
7371 Improve tracing messages.
7372 (load_format_25, load_post_names): Make `post_limit' of type
7375 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7377 [cff] Truncate the element length at the end of the stream.
7378 See Savannah bug #30975.
7380 * src/cff/cffload.c (cff_index_access_element): `off2', the offset
7381 to the next element is truncated at the end of the stream to prevent
7382 invalid I/O. As `off1', the offset to the requested element has
7383 been checked by `FT_STREAM_SEEK', `off2' should be checked
7386 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7388 [cff] Ignore CID > 0xFFFFU.
7389 See Savannah bug #30975.
7391 * src/cff/cffload.c (cff_charset_compute_cids): Ignore CID if
7392 greater than 0xFFFFU. CFF font spec does not mention maximum CID in
7393 the font, but PostScript and PDF spec define that maximum CID is
7396 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7398 [cff] Make trace message in` cff_charset_load' verbose.
7399 See Savannah bug #30975.
7401 * src/cff/cffload.c (cff_charset_load): Report the original `nleft'
7402 and truncated `nleft'.
7404 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7406 [cff] Correct `max_cid' from CID array length to max CID.
7407 See Savannah bug #30975.
7409 * src/cff/cffload.c (cff_charset_compute_cids): Don't increment
7410 max_cid after detecting max CID. The array CFF_Charset->cids is
7411 allocated by max_cid + 1.
7412 (cff_charset_cid_to_gindex): Permit CID is less than or equal to
7413 CFF_Charset->max_cid.
7414 * src/cff/cffobjs.c (cff_face_init): FT_Face->num_glyphs is
7415 calculated as CFF_Charset->max_cid + 1.
7417 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7419 [truetype] Sanitize the broken offsets in `loca'.
7420 See Savannah bug #31040.
7422 * src/truetype/ttpload.c (tt_face_get_location): If `pos1', the
7423 offset to the requested entry in `glyf' exceeds the end of the
7424 table, return offset=0, length=0. If `pos2', the offset to the next
7425 entry in `glyf' exceeds the end of the table, truncate the entry
7426 length at the end of `glyf' table.
7428 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7430 [sfnt] Prevent overrunning in `post' table parser.
7431 See Savannah bug #31040.
7433 * src/sfnt/ttpost.c (load_post_names): Get the length of `post'
7434 table and pass the limit of `post' table to `load_format_20' and
7436 (load_format_20): Stop the parsing when we reached at the limit of
7437 `post' table. If more glyph names are required, they are filled by
7440 2010-09-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7442 [truetype] Don't duplicate size->twilight structure to be freed.
7443 See Savannah bug #31040 for detail.
7445 * src/truetype/ttinterp.c (free_buffer_in_size): Don't duplicate
7446 FT_GlyphZoneRec size->twilight to be freed. If duplicated,
7447 `FT_FREE' erases the duplicated pointers only and leave original
7448 pointers. They can cause the double-free crash when the burst
7449 errors occur in TrueType interpreter and `free_buffer_in_size' is
7452 2010-09-15 Werner Lemberg <wl@gnu.org>
7454 Make bytecode debugging with FontForge work again.
7456 * src/truetype/ttinterp.c (TT_RunIns): Don't call
7457 `free_buffer_in_size' in case of error if a debugger is active.
7459 2010-09-14 Werner Lemberg <wl@gnu.org>
7461 Improve tracing messages.
7463 * src/truetype/ttinterp.c (TT_RunIns): Improve wording of tracing
7465 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Add
7467 * src/truetype/ttgload.c (tt_loader_init): Add tracing message.
7468 * src/cache/ftcsbits.c (ftc_snode_load): Emit tracing message if
7469 glyph doesn't fit into a small bitmap container.
7471 2010-09-13 Werner Lemberg <wl@gnu.org>
7473 Fix minor issues reported by <muktha.narayan@wipro.com>.
7475 * src/autofit/aflatin.c (af_latin_compute_stem_width): Remove
7476 redundant conditional check.
7477 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Ditto.
7478 * src/cff/cffload.c (cff_encoding_load): Remove conditional check
7479 which always evaluates to `true'.
7480 * src/pshinter/pshalgo.c (ps_glyph_interpolate_strong_points):
7482 * src/truetype/ttinterp.c (Ins_IUP): Ditto.
7483 * src/cid/cidgload.c (cid_slot_load_glyph): Don't check for NULL if
7484 value is already dereferenced.
7485 * src/winfonts/winfnt.c (FNT_Load_Glyph): Fix check of `face'.
7487 2010-08-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7489 Ignore the environmental setting of LIBTOOL.
7490 Patch is suggested by Adrian Bunk, to prevent unexpected
7491 reflection of environmental LIBTOOL. See:
7492 http://savannah.nongnu.org/patch/?7290
7494 * builds/unix/unix-cc.in: LIBTOOL is unconditionally set to
7495 $(FT_LIBTOOL_DIR)/libtool. FT_LIBTOOL_DIR is set to $(BUILD_DIR)
7497 * configure: When configured for the building out of source tee,
7498 FT_LIBTOOL_DIR is set to $(OBJ_DIR).
7500 2010-08-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7502 [truetype] Decrease the trace level catching the interpreter error.
7504 * src/truetype/ttinterp.c (TT_RunIns): Decrease the trace level
7505 showing the error when the interpreter returns with an error,
7506 from` FT_TRACE7' to `FT_TRACE1'.
7508 2010-08-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7510 [truetype] Prevent bytecode reuse after the interpretation error.
7512 * src/truetype/ttinterp.c (free_buffer_in_size): New function to
7513 free the buffer allocated during the interpretation of this glyph.
7514 (TT_RunIns): Unset FT_Face->size->{cvt_ready,bytecode_ready} if
7515 an error occurs in the bytecode interpretation. The interpretation
7516 of invalid bytecode may break the function definitions and referring
7517 them in later interpretation is danger. By unsetting these flags,
7518 `fpgm' and `prep' tables are executed again in next interpretation.
7520 This fixes Savannah bug #30798, reported by Robert Święcki.
7522 2010-08-29 Werner Lemberg <wl@gnu.org>
7524 [ftraster] Pacify compiler.
7526 * src/raster/ftraster.c (ft_black_new) [_STANDALONE_]: `memory' is
7529 2010-08-29 Werner Lemberg <wl@gnu.org>
7531 [cff] Allow SIDs >= 65000.
7533 * src/cff/cffload.c (cff_charset_load): Fix change from 2009-03-20:
7534 The threshold for SIDs is not applicable here. I misinterpreted the
7535 `SID values 65000 and above are available for implementation use'
7536 sentence in the CFF specification.
7538 Problem reported by Ivan Ninčić <inincic@pdftron.com>.
7540 2010-08-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7542 Force hinting when the font lacks its familyname.
7544 In Type42 or Type11 font embedded in PostScript & PDF, TrueType sfnt
7545 stream may lack `name' table because they are not required. Hinting
7546 for nameless fonts is safer for PDFs including embedded Chinese
7547 fonts. Written by David Bevan, see:
7549 http://lists.gnu.org/archive/html/freetype-devel/2010-08/msg00021.html
7550 http://lists.freedesktop.org/archives/poppler/2010-August/006310.html
7552 * src/truetype/ttobjs.c (tt_check_trickyness): If a NULL pointer by
7553 nameless font is given, TRUE is returned to enable hinting.
7555 2010-08-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7557 Register yet another tricky TrueType font.
7559 * src/truetype/ttobjs.c (tt_check_trickyness): Add `HuaTianKaiTi?',
7560 a Kaishu typeface paired with `HuaTianSongTi?' by Huatian
7561 Information Industry.
7563 2010-08-17 Teijo Kinnunen <Teijo.Kinnunen@nuance.com>
7565 [cache] Fix Savannah bug #30788.
7567 * src/cache/ftccache.c (FTC_Cache_Clear): Check `cache->buckets' for
7570 2010-08-10 Werner Lemberg <wl@gnu.org>
7572 Try to fix Savannah bug #30717 (and probably #30719 too).
7574 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Add another
7575 overflow test for `width' and `height'.
7577 2010-08-06 Werner Lemberg <wl@gnu.org>
7579 * Version 2.4.2 released.
7580 =========================
7583 Tag sources with `VER-2-4-2'.
7585 * docs/CHANGES: Updated.
7587 * docs/VERSION.DLL: Update documentation and bump version number to
7590 * README, Jamfile (RefDoc),
7591 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
7592 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
7593 builds/win32/visualc/freetype.dsp,
7594 builds/win32/visualc/freetype.vcproj,
7595 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
7596 builds/win32/visualce/freetype.vcproj,
7597 builds/win32/visualce/index.html,
7598 builds/wince/vc2005-ce/freetype.vcproj,
7599 builds/wince/vc2005-ce/index.html,
7600 builds/wince/vc2008-ce/freetype.vcproj,
7601 builds/wince/vc2008-ce/index.html: s/2.4.1/2.4.2/, s/241/242/.
7603 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
7605 * builds/unix/configure.raw (version_info): Set to 12:0:6.
7607 2010-08-06 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7609 Fix Savannah bug #30648.
7611 * src/base/ftobjs.c (FT_Done_Library): Specify the order of font
7612 drivers during the face closing process. Type42 faces should be
7613 closed before TrueType faces, because a Type42 face refers to
7614 another internal TrueType face which is created from sfnt[] array on
7617 2010-08-06 Yuriy Kaminskiy <yumkam@mail.ru>
7619 [raster] Fix valgrind warning.
7621 * src/raster/ftraster.c (Decompose_Curve) <default>: Access point[0]
7622 only if we don't hit `limit'.
7624 2010-08-06 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7626 Fix Savannah bug #30658.
7628 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check that the total
7629 length of collected POST segments does not overrun the allocated
7632 2010-08-06 Yuriy Kaminskiy <yumkam@mail.ru>
7634 Fix conditional usage of FT_MulFix_i386.
7635 With -ansi flag, gcc does not define `i386', only `__i386__'.
7637 * include/freetype/config/ftconfig.h, builds/unix/ftconfig.in:
7640 2010-08-05 Werner Lemberg <wl@gnu.org>
7642 [truetype] Fix Savannah bug #30657.
7644 * src/truetype/ttinterp.c (BOUNDSL): New macro.
7645 Change `BOUNDS' to `BOUNDSL' where appropriate.
7647 * src/truetype/ttinterp.h (TT_ExecContextRec): Fix type of
7650 2010-08-05 Werner Lemberg <wl@gnu.org>
7652 [type42] Fix Savannah bug #30656.
7654 * src/type42/t42parse.c (t42_parse_sfnts): Protect against negative
7658 2010-08-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7660 [cff] Don't use any values in decoder after parsing error.
7662 * src/cff/cffgload.c (cff_slot_load): Skip the evaluations
7663 of the values in decoder, if `cff_decoder_parse_charstrings'
7666 2010-08-04 Werner Lemberg <wl@gnu.org>
7668 Fix Savannah bug #30644.
7670 * src/base/ftstream.c (FT_Stream_EnterFrame): Fix comparison.
7672 2010-08-04 Werner Lemberg <wl@gnu.org>
7674 `make devel' fails if FT_CONFIG_OPTION_OLD_INTERNALS is set.
7676 * devel/ftoption.h: Synchronize with
7677 include/freetype/config/ftoption.h.
7679 2010-08-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7681 [cff] Improve stack overflow test.
7683 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Check stack
7684 after execution of operations too.
7686 2010-07-18 Werner Lemberg <wl@gnu.org>
7688 Add reference counters and to FT_Library and FT_Face objects.
7690 * include/freetype/freetype.h (FT_Reference_Face): New function.
7691 * include/freetype/ftmodapi.h (FT_Rererence_Library): New function.
7693 * include/freetype/internal/ftobjs.h (FT_Face_InternalRec,
7694 FT_LibraryRec): New field `refcount'.
7696 * src/base/ftobjs.c (FT_Open_Face, FT_New_Library): Handle
7698 (FT_Reference_Face, FT_Reference_Library): Implement new functions.
7699 (FT_Done_Face, FT_Done_Library): Handle `refcount'.
7701 * docs/CHANGES: Updated.
7703 2010-07-18 Werner Lemberg <wl@gnu.org>
7705 * Version 2.4.1 released.
7706 =========================
7709 Tag sources with `VER-2-4-1'.
7711 * docs/CHANGES: Updated.
7713 * docs/VERSION.DLL: Update documentation and bump version number to
7716 * README, Jamfile (RefDoc),
7717 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
7718 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
7719 builds/win32/visualc/freetype.dsp,
7720 builds/win32/visualc/freetype.vcproj,
7721 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
7722 builds/win32/visualce/freetype.vcproj,
7723 builds/win32/visualce/index.html,
7724 builds/wince/vc2005-ce/freetype.vcproj,
7725 builds/wince/vc2005-ce/index.html,
7726 builds/wince/vc2008-ce/freetype.vcproj,
7727 builds/wince/vc2008-ce/index.html: s/2.4.0/2.4.1/, s/240/241/.
7729 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
7731 * builds/unix/configure.raw (version_info): Set to 11:1:5.
7733 2010-07-17 Werner Lemberg <wl@gnu.org>
7735 [cff] Final try to fix `hintmask' and `cntrmask' limit check.
7737 Problem reported by Tobias Wolf <towolf@gmail.com>.
7739 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
7740 <cff_op_hintmask>: Sigh. I'm apparently too silly to fix this
7741 correctly in less than three tries.
7743 2010-07-12 Werner Lemberg <wl@gnu.org>
7745 * Version 2.4.0 released.
7746 =========================
7749 Tag sources with `VER-2-4-0'.
7751 * docs/CHANGES: Updated.
7753 * docs/VERSION.DLL: Update documentation and bump version number to
7756 * README, Jamfile (RefDoc),
7757 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
7758 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
7759 builds/win32/visualc/freetype.dsp,
7760 builds/win32/visualc/freetype.vcproj,
7761 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
7762 builds/win32/visualce/freetype.vcproj,
7763 builds/win32/visualce/index.html,
7764 builds/wince/vc2005-ce/freetype.vcproj,
7765 builds/wince/vc2005-ce/index.html,
7766 builds/wince/vc2008-ce/freetype.vcproj,
7767 builds/wince/vc2008-ce/index.html: s/2.3.12/2.4.0/, s/2312/240/.
7769 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 4.
7770 (FREETYPE_PATCH): Set to 0.
7772 * builds/unix/configure.raw (version_info): Set to 11:0:5.
7774 2010-07-12 Werner Lemberg <wl@gnu.org>
7776 Remove C++ warnings.
7778 */*: Initialize pointers where necessary to make g++ happy.
7780 2010-07-12 malc <av1474@comtv.ru>
7781 Richard Henderson <rth@redhat.com>
7783 Fix type-punning issues with C++.
7785 * include/freetype/internal/ftmemory.h (FT_ASSIGNP) [__cplusplus]:
7786 Emulate a `typeof' operator with an inline template which uses
7789 2010-07-11 Werner Lemberg <wl@gnu.org>
7791 Fix C++ compilation issue.
7793 * src/tools/apinames.c (names_dump) <OUTPUT_WATCOM_LBC>: Fix
7794 type of `dot' variable.
7796 2010-07-10 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7798 Fix another case reported in Savannah bug #30373.
7799 Permit a face for Type1, Type42 and CFF without charmap,
7800 patch by Tor Andersson.
7802 * src/type1/t1objs.c (T1_Face_Init): Reset the error if it
7803 is FT_Err_No_Unicode_Glyph_Name.
7804 * src/type42/t42objs.c (T42_Face_Init): Ditto.
7805 * src/cff/cffobjs.c (cff_face_init): Ditto.
7807 2010-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7809 Use defined macros to set {platform,encoding}_id.
7811 * src/bdf/bdfdrivr.c: Include ttnameid.h and use macros to
7812 set charmap.{platfom,encoding}_id.
7813 * src/pcf/pcfdrivr.c: Ditto.
7814 * src/winfonts/winfnt.c: Ditto.
7815 * src/type1/t1objs.c: Ditto.
7816 * src/type42/t42objs.c: Ditto.
7817 * src/cff/cffobjs.c: Ditto.
7818 * src/pfr/pfrobjs.c: Ditto.
7820 2010-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7822 Fix Savannah bug #30373.
7823 Too serious check of errors by `FT_CMap_New' since 2010-07-04
7824 is fixed. Reported by Tor Andersson.
7826 * include/freetype/fterrdef.h
7827 (PSnames_Err_No_Unicode_Glyph_Name): New error code to
7828 indicate the Unicode charmap synthesis failed because
7829 no Unicode glyph name is found.
7831 * src/psnames/psmodule.c (ps_unicodes_init): Return
7832 PSnames_Err_No_Unicode_Glyph_Name when no Unicode glyph name
7833 is found in the font.
7834 * src/cff/cffcmap.c (cff_cmap_unicode_init): Return
7835 CFF_Err_No_Unicode_Glyph_Name when no SID is available.
7837 * src/type1/t1objs.c (T1_Face_Init): Proceed if `FT_CMap_New'
7838 is failed by the lack of Unicode glyph name.
7839 * src/type42/t42objs.c (T42_Face_Init): Ditto.
7840 * src/cff/cffobjs.c (cff_face_init): Ditto.
7842 2010-07-09 Ken Sharp <ken.sharp@artifex.com>
7844 Make ftraster.c compile in stand-alone mode with MSVC compiler.
7846 * src/raster/ftmisc.h (FT_Int64) [_WIN32, _WIN64]: Fix typedef
7847 since there is no `inttypes.h' for MSVC.
7849 2010-07-08 Werner Lemberg <wl@gnu.org>
7851 [truetype] Fix Savannah bug #30361.
7853 * src/truetype/ttinterp.c (Ins_IUP): Fix bounds check.
7855 2010-07-06 Werner Lemberg <wl@gnu.org>
7859 * src/cff/cffload.c (cff_index_get_pointers): Initialize
7862 2010-07-05 Eugene A. Shatokhin <spectre@ispras.ru>
7864 Fix Savannah bug #27648.
7866 * src/base/ftobjs.c (ft_remove_renderer, FT_Add_Module): Call
7867 `raster_done' only if we have an outline glyph format.
7869 2010-07-05 Werner Lemberg <wl@gnu.org>
7871 Fix Savannah bug #30030.
7873 * builds/win32/*/freetype.vcproj: Add ftxf86.c.
7875 2010-07-05 Werner Lemberg <wl@gnu.org>
7877 [cff] Next try to fix `hintmask' and `cntrmask' limit check.
7879 Problem reported by malc <av1474@comtv.ru>.
7881 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
7882 <cff_op_hintmask>: It is possible that there is just a single byte
7883 after the `hintmask' or `cntrmask', e.g., a `return' instruction.
7885 2010-07-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7887 Restrict the number of the charmaps in a rogue-compatible mode.
7888 Fix for Savannah bug #30059.
7890 * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Replace `16' the
7891 minimum character code passed by a legacy rogue client by...
7892 * include/freetype/config/ftoption.h (FT_MAX_CHARMAP_CACHEABLE):
7893 This. It is undefined when FT_CONFIG_OPTION_OLD_INTERNALS is
7894 undefined (thus the rogue client compatibility is not required).
7896 * src/cff/cffobjs.c (cff_face_init): Abort the automatic
7897 selection or synthesis of Unicode cmap subtable when the charmap
7898 index exceeds FT_MAX_CHARMAP_CACHEABLE.
7899 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Issue error message
7900 when the charmap index exceeds FT_MAX_CHARMAP_CACHEABLE.
7902 * src/base/ftobjs.c (find_unicode_charmap): When Unicode charmap
7903 is found after FT_MAX_CHARMAP_CACHEABLE, ignore it and search
7905 (find_variant_selector_charmap): When UVS charmap is found after
7906 FT_MAX_CHARMAP_CACHEABLE, ignore it and search earlier one.
7907 (FT_Select_Charmap): When a charmap matching with requested
7908 encoding but after FT_MAX_CHARMAP_CACHEABLE, ignore and search
7910 (FT_Set_Charmap): When a charmap matching with requested
7911 charmap but after FT_MAX_CHARMAP_CACHEABLE, ignore and search
7913 (FT_Get_Charmap_Index): When a requested charmap is found
7914 after FT_MAX_CHARMAP_CACHEABLE, return the inverted charmap
7917 2010-07-04 Werner Lemberg <wl@gnu.org>
7919 TrueType hinting is no longer patented.
7921 * include/freetype/config/ftoption.h, devel/ftoption.h
7922 (TT_CONFIG_OPTION_BYTECODE_INTERPRETER): Define.
7923 (TT_CONFIG_OPTION_UNPATENTED_HINTING): Undefine.
7925 * docs/CHANGES, docs/INSTALL, include/freetype/freetype.h: Updated.
7926 * docs/TRUETYPE, docs/PATENTS: Removed.
7928 2010-07-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7930 Check error value by `FT_CMap_New'.
7932 * src/cff/cffobjs.c (cff_face_init): Check error value by
7934 * src/pfr/pfrobjs.c (pfr_face_init): Ditto.
7935 * src/type1/t1jobjs.c (T1_Face_Init): Ditto.
7936 * src/type42/t42jobjs.c (T42_Face_Init): Ditto.
7938 2010-07-03 Werner Lemberg <wl@gnu.org>
7940 Make ftgrays.c compile stand-alone again.
7942 * src/smooth/ftgrays.c [_STANDALONE_]: Include `stddef.h'.
7943 (FT_INT_MAX, FT_PtrDist)[_STANDALONE_]: Define.
7945 2010-07-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7947 Additional fix for Savannah bug #30306.
7949 * src/base/ftobjs.c (Mac_Read_POST_Resource): If the type of the
7950 POST fragment is 0, the segment is completely ignored. The declared
7951 length of the segment is not cared at all. According to Adobe
7952 Technical Note 5040, type 0 segment is a comment only and should not
7953 be loaded for the interpreter. Reported by Robert Święcki.
7955 2010-07-01 Werner Lemberg <wl@gnu.org>
7957 [truetype] Protect against code range underflow.
7959 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF): Don't allow
7962 2010-07-01 Werner Lemberg <wl@gnu.org>
7964 [truetype] Add rudimentary tracing for bytecode instructions.
7966 * src/truetype/ttinterp.c (opcode_name) [FT_DEBUG_LEVEL_TRACE]: New
7968 (TT_RunIns): Trace opcodes.
7970 2010-06-30 Werner Lemberg <wl@gnu.org>
7972 [smooth] Fix Savannah bug #30263.
7974 * src/smooth/ftgrays.c (gray_render_span): Use cast to `unsigned
7975 int' to avoid integer overflow.
7977 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use smaller
7978 threshold values for `width' and `height'. This is not directly
7979 related to the bug fix but makes sense anyway.
7981 2010-07-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7983 Initial fix for Savannah bug #30306.
7985 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check `rlen', the
7986 length of fragment declared in the POST fragment header, and prevent
7987 an underflow in length calculation. Some fonts set the length to
7988 zero in spite of the existence of a following 16bit `type'.
7989 Reported by Robert Święcki.
7991 2010-07-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
7993 Additional fix for Savannah bug #30248 and #30249.
7995 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check the buffer size
7996 during gathering PFB fragments embedded in LaserWriter PS font for
7997 Macintosh. Reported by Robert Święcki.
7999 2010-06-30 Alexei Podtelezhnikov <apodtele@gmail.com>
8001 Minor optimizations by avoiding divisions.
8003 * src/sfnt/ttkern.c (tt_face_load_kern, tt_face_get_kerning):
8004 Replace divisions with multiplication in comparisons.
8006 2010-06-29 Werner Lemberg <wl@gnu.org>
8008 Fix minor tracing issues.
8010 * src/cff/cffgload.c, src/truetype/ttgload.c: Adjust tracing levels.
8012 2010-06-27 Werner Lemberg <wl@gnu.org>
8014 [cff] Really fix `hintmask' and `cntrmask' limit check.
8016 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
8017 <cff_op_hintmask>: Fix thinko and handle tracing also.
8019 2010-06-27 Werner Lemberg <wl@gnu.org>
8021 Fix valgrind warning.
8023 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Initialize
8026 2010-06-27 Werner Lemberg <wl@gnu.org>
8028 [cff] Fix memory leak.
8030 * src/cff/cffgload.c (cff_operator_seac): Free charstrings even in
8033 2010-06-27 Werner Lemberg <wl@gnu.org>
8035 [cff] Protect against invalid `hintmask' and `cntrmask' operators.
8037 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
8038 <cff_op_hintmask>: Ensure that we don't exceed `limit' while parsing
8039 the bit masks of the `hintmask' and `cntrmask' operators.
8041 2010-06-26 Werner Lemberg <wl@gnu.org>
8043 Fix PFR change 2010-06-24.
8045 * src/pfr/pfrgload.c (pfr_glyph_load_simple): Really protect against
8048 2010-06-26 Werner Lemberg <wl@gnu.org>
8050 Improve PFR tracing messages.
8052 * src/pfr/pfrgload.c (pfr_glyph_load_rec): Emit tracing messages for
8053 simple and compound glyph offsets.
8055 2010-06-26 Werner Lemberg <wl@gnu.org>
8057 Fix last PFR change.
8059 * src/pfr/pfrobjs.c (pfr_face_init): Fix rejection logic.
8061 2010-06-26 Werner Lemberg <wl@gnu.org>
8063 [sfnt] Fix Savannah bug #30262.
8065 * src/sfnt/ttload.c (tt_face_load_maxp): Limit `maxComponentDepth'
8066 arbitrarily to 100 to avoid stack exhaustion.
8068 2010-06-26 Werner Lemberg <wl@gnu.org>
8070 Add some memory checks (mainly for debugging).
8072 * src/base/ftstream.c (FT_Stream_EnterFrame): Exit with error
8073 if the frame size is larger than the stream size.
8075 * src/base/ftsystem.c (ft_ansi_stream_io): Exit with error if
8076 seeking a position larger than the stream size.
8078 2010-06-25 Werner Lemberg <wl@gnu.org>
8080 [pfr] Fix Savannah bug #30261.
8082 * src/pfr/pfrobjs.c (pfr_face_init): Reject fonts which contain
8083 neither outline nor bitmap glyphs.
8085 2010-06-25 Werner Lemberg <wl@gnu.org>
8087 [cff] Fix Savannah bug #30254.
8089 * src/cff/cffload.c (cff_index_get_pointers): Do sanity check for
8092 2010-06-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
8094 Initial fix for Savannah bug #30248 and #30249.
8096 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check the error during
8097 reading a PFB fragment embedded in LaserWriter PS font for Macintosh.
8098 Reported by Robert Święcki.
8100 2010-06-24 Werner Lemberg <wl@gnu.org>
8102 [pcf] Fix Savannah bug #30247.
8104 * src/pcf/pcfread.c (pcf_get_metrics): Disallow (invalid) fonts with
8107 2010-06-24 Graham Asher <graham.asher@btinternet.com>
8109 * src/smooth/ftgrays.c (gray_render_cubic): Fix algorithm.
8110 The previous version was too aggressive, as demonstrated in
8111 http://lists.gnu.org/archive/html/freetype-devel/2010-06/msg00020.html.
8113 2010-06-24 Werner Lemberg <wl@gnu.org>
8115 */*: Use module specific error names where appropriate.
8117 2010-06-24 Werner Lemberg <wl@gnu.org>
8119 [sfnt] Fix Savannah bug #30236.
8121 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Improve check for pointer
8124 2010-06-24 Werner Lemberg <wl@gnu.org>
8126 [pfr] Fix Savannah bug #30235.
8128 * src/pfr/pfrgload.c (pfr_glyph_load_simple): Protect against
8129 invalid indices if there aren't any coordinates for indexing.
8131 2010-06-24 Werner Lemberg <wl@gnu.org>
8133 [bdf]: Font properties are optional.
8135 * src/bdf/bdflib.c (_bdf_readstream): Use special error code to
8136 indicate a redo operation.
8137 (_bdf_parse_start): Handle `CHARS' keyword here too and pass current
8138 input line to `_bdf_parse_glyph'.
8140 2010-06-23 Werner Lemberg <wl@gnu.org>
8142 [bdf] Fix Savannah bug #30220.
8144 * include/freetype/fterrdef.h
8145 (BDF_Err_Missing_Fontboundingbox_Field): New error code.
8147 * src/bdf/bdflib.c (_bdf_parse_start): Check for missing
8148 `FONTBOUNDINGBOX' field.
8149 Avoid memory leak if there are multiple `FONT' lines (which is
8150 invalid but doesn't hurt).
8152 2010-06-21 Werner Lemberg <wl@gnu.org>
8154 [pfr] Fix Savannah bug #30168.
8156 * src/pfr/pfrgload.c (pfr_glyph_load_compound): Limit the number of
8157 subglyphs to avoid endless recursion.
8159 2010-06-20 Werner Lemberg <wl@gnu.org>
8161 [psaux] Fix Savannah bug #30145.
8163 * src/psaux/psobjs.c (t1_builder_add_contour): Protect against
8164 `outline == NULL' which might happen in invalid fonts.
8166 2010-06-19 Werner Lemberg <wl@gnu.org>
8168 [bdf] Fix Savannah bug #30135.
8170 * src/bdf/bdflib.c (_bdf_list_join): Don't modify value in static
8172 (_bdf_parse_glyph): Avoid memory leak in case of error.
8174 2010-06-15 Werner Lemberg <wl@gnu.org>
8176 [autofit] Fix Savannah bug #30108.
8178 * src/autofit/afglobal.c (af_face_globals_compute_script_coverage):
8179 Properly mask AF_DIGIT bit in comparison.
8181 2010-06-11 Werner Lemberg <wl@gnu.org>
8183 [pshinter] Fix Savannah bug #30106.
8185 Point numbers for FreeType's implementation of hinting masks are
8186 collected before the final number of points of a glyph has been
8187 determined; in particular, the code for handling the `endchar'
8188 opcode can reduce the number of points.
8190 * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Assure that
8191 `end_point' is not larger than `glyph->num_points'.
8193 2010-06-11 Werner Lemberg <wl@gnu.org>
8195 [cff]: Improve debugging output.
8197 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
8198 <cff_op_hintmask>: Implement it.
8200 2010-06-10 Graham Asher <graham.asher@btinternet.com>
8202 ftgrays: Speed up rendering of small cubic splines.
8204 * src/smooth/ftgrays.c (gray_render_cubic): Implement new,
8205 simplified algorithm to find out whether the spline can be replaced
8206 with two straight lines. See this thread for more:
8208 http://lists.gnu.org/archive/html/freetype-devel/2010-06/msg00000.html
8210 2010-06-09 Werner Lemberg <wl@gnu.org>
8212 [cff] Fix Savannah bug #30082.
8214 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
8215 <cff_op_callothersubr>: Protect against stack underflow.
8217 2010-06-08 Werner Lemberg <wl@gnu.org>
8219 [cff] Fix Savannah bug #30053.
8221 * src/cff/cffparse.c (cff_parse_real): Handle border case where
8222 `fraction_length' has value 10.
8224 2010-06-07 Werner Lemberg <wl@gnu.org>
8226 Fix Savannah bug #30052.
8227 This bug has been introduced with commit 2415cbf3.
8229 * src/base/ftobjs.c (FT_Get_First_Char, FT_Get_Next_Char): Protect
8230 against endless loop in case of corrupted font header data.
8232 2010-05-26 Werner Lemberg <wl@gnu.org>
8234 Remove unused variable.
8237 * src/autofit/afhints.c (af_glyph_hints_reload): Remove unused
8238 variable `first' in first block.
8240 2010-05-22 Werner Lemberg <wl@gnu.org>
8242 Fix various memory problems found by linuxtesting.org.
8244 * src/base/ftgxval.c (FT_TrueTypeGX_Free, FT_ClassicKern_Free),
8245 src/base/ftotval.c (FT_OpenType_Free), src/base/ftpfr.c
8246 (ft_pfr_check): Check `face'.
8248 * src/base/ftobjs.c (FT_Get_Charmap_Index): Check `charmap' and
8250 (FT_Render_Glyph): Check `slot->face'.
8251 (FT_Get_SubGlyph_Info): Check `glyph->subglyphs'.
8253 2010-05-22 Werner Lemberg <wl@gnu.org>
8255 autofit: Remove dead code.
8256 Suggested by Graham.
8258 * src/autofit/afhints.c (af_glyph_hints_compute_inflections):
8260 (af_glyph_hints_reload): Remove third argument.
8263 2010-05-21 Bram Tassyns <bramt@enfocus.be>
8265 [cff] Fix Savannah bug #27987.
8267 * src/cff/cffobjs.c (remove_subset_prefix): New function.
8268 (cff_face_init): Use it to adjust `cffface->family_name'.
8270 2010-05-20 Werner Lemberg <wl@gnu.org>
8272 TrueType: Make FreeType ignore maxSizeOfInstructions in `maxp'.
8274 Acroread does the same.
8276 * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Call
8277 `Update_Max' to adjust size of instructions array if necessary and
8278 add a rough safety check.
8280 (load_truetype_glyph): Save `loader->byte_len' before recursive
8283 * src/truetype/ttinterp.h, src/truetype/ttinterp.c (Update_Max):
8284 Declare it as FT_LOCAL.
8286 2010-05-18 Hongbo Ni <hongbo@njstar.com>
8288 Apply Savannah patch #7196.
8290 * src/cff/cffgload.c (cff_slot_load): Prevent crash if CFF subfont
8291 index is out of range.
8293 2010-05-11 Werner Lemberg <wl@gnu.org>
8295 * docs/formats.txt: Give pointer to PCF documentation.
8296 Information provided by Alan Coopersmith
8297 <alan.coopersmith@oracle.com>.
8299 2010-05-10 Ken Sharp <ken.sharp@artifex.com>
8301 [psaux] Fix Savannah bug #29846.
8303 Previously we discovered fonts which used `setcurrentpoint' to set
8304 the initial point of a contour to 0,0. This caused FreeType to
8305 raise an error, because the `setcurrentpoint' operator is only
8306 supposed to be used with the results from an OtherSubr subroutine.
8308 This was fixed by simply ignoring the error and carrying on.
8310 Now we have found a font which uses setcurrentpoint to actually
8311 establish a non-zero point for a contour during the course of a
8312 glyph program. FWIW, these files may be produced by an application
8313 called `Intaglio' on the Mac, when converting TrueType fonts to
8316 The fix allows the new invalid behaviour, the old invalid behaviour
8317 and real proper usage of the operator to work the same way as Adobe
8318 interpreters apparently do.
8320 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Make
8321 `setcurrentpoint' use the top two elements of the stack to establish
8322 unconditionally the current x and y coordinates.
8324 Make the `flex' subroutine handling (OtherSubr 0) put the current
8325 x,y coordinates onto the stack, instead of two dummy uninitialised
8328 2010-04-14 Ken Sharp <ken.sharp@artifex.com>
8330 [psaux] Fix Savannah bug #29444.
8332 * src/psaux/psobjs.c (t1_builder_start_point): Accept (invalid)
8333 `lineto' immediately after `hsbw', in accordance with Acrobat, GS,
8336 2010-04-14 Michał Cichoń <thedmd@artifexmundi.com>
8338 [psaux] Fix Savannah bug #27999.
8340 * src/cache/ftcmanag.c (FTC_Manager_RemoveFaceID): Only remove
8341 selected entry, not all.
8343 2010-04-06 Jonathan Kew <jfkthame@gmail.com>
8345 [truetype] Add overflow check to `fvar' table.
8347 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Check axis and instance
8350 2010-04-05 Ken Sharp <ken.sharp@artifex.com>
8352 [raster] Fix Savannah bug #29335.
8354 * src/raster/ftraster.c (Line_Up): Use slow multiplication to
8355 prevent overflow. This shouldn't have any serious impact on speed,
8358 2010-04-05 Werner Lemberg <wl@gnu.org>
8360 Add new function `FT_Library_SetLcdFilterWeights'.
8362 This is based on code written by Lifter
8363 <http://unixforum.org/index.php?showuser=11691>. It fixes
8364 FreeDesktop bug #27386.
8366 * src/base/ftlcdfil.c (FT_Library_SetLcdFilterWeights): New
8369 * include/freetype/ftlcdfil.h: Updated.
8371 * docs/CHANGES: Updated.
8373 2010-04-01 John Tytgat <John.Tytgat@esko.com>
8375 [truetype] Fix Savannah bug #29404.
8377 * src/truetype/ttgload.c: Revert change 2752bd1a (check on bit 1
8378 of `head' table of TrueType fonts).
8380 2010-03-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
8382 Fix `multi build' for Tytgat's CFF driver improvement.
8384 * src/base/cffload.h (cff_index_get_name): Added.
8386 2010-03-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
8388 Remove duplicated inclusion of `FT_OUTLINE_H' in ftobjs.c.
8390 * src/base/ftobjs.c: Remove 2nd inclusion of `FT_OUTLINE_H'.
8392 2010-03-11 Chris Liddell <chris.liddell@artifex.com>
8394 [raster] Fix Savannah bug #27442.
8396 * src/raster/ftraster.c (ft_black_reset): Fix `buffer_size'.
8398 2010-03-09 Werner Lemberg <wl@gnu.org>
8400 [cff] Remove unused variable.
8403 * src/cff/cffparse.c (cff_parse_real): Remove `rest'.
8405 2010-03-02 John Tytgat <John.Tytgat@esko.com>
8407 [cff] Improve CFF string (especially glyphname) lookup performance.
8409 We do this by avoiding memory allocation and file I/O. This is
8410 Savannah patch #7104.
8412 * src/cff/cfftypes.h: Include PS cmaps service and
8413 FT_INTERNAL_POSTSCRIPT_HINTS_H.
8414 (CFF_SubFontRec): Remove `num_local_subrs'.
8415 (CFF_FontRec): Add `num_strings', `strings', and `string_pool'
8417 Remove `string_index' and `num_global_subrs' fields.
8418 Use real types instead of `void' for `pshinter' and `psnames' fields.
8420 * src/cff/cffload.c: Don't include PS cmaps service.
8421 (cff_index_get_pointers): Add `pool' parameter which allows to
8422 insert an extra NUL character for each String INDEX entry.
8423 (cff_index_get_name): Make it a local function.
8424 (cff_index_get_string): New function.
8425 (cff_subfont_load): Updated.
8426 (cff_font_load): Initialize `num_strings', `strings', and
8427 `string_pool' fields in the `CFF_FontRec' structure.
8428 (cff_index_get_sid_string): Use `cff_index_get_string' instead of
8429 `cff_index_get_name'.
8430 (cff_font_done): Updated.
8432 * src/cff/cffload.h: Don't include PS cmaps service.
8433 (cff_index_get_string): Added.
8434 (cff_index_get_sid_string): Updated.
8436 * src/cff/cffobjs.c: Don't include PS cmaps service and
8437 FT_INTERNAL_POSTSCRIPT_HINTS_H.
8438 (cff_size_get_globals_funcs, cff_slot_init): Updated.
8439 (cff_face_init): Follow `cff_index_get_name',
8440 `cff_index_get_string', and `cff_index_get_sid_string' changes.
8442 * src/cff/cffcmap.c (cff_sid_free_glyph_name): Removed.
8443 (cff_sid_to_glyph_name): Use `cff_index_get_cid_string'.
8444 (cff_cmap_unicode_init): Updated.
8446 * src/cff/cffdrivr.c: Don't include PS cmap service.
8447 (cff_get_glyph_name): Avoid unnecessary lookup for POSTSCRIPT_CMAPS
8449 (cff_get_glyph_name, cff_ps_get_font_info, cff_get_ros): Follow API
8450 `cff_index_get_sid_string' change.
8451 (cff_get_name_index): Use `cff_index_get_string' instead of
8452 `cff_index_get_name'.
8454 * src/cff/cffgload.c: Don't include FT_INTERNAL_POSTSCRIPT_HINTS_H.
8455 (cff_decoder_init, cff_decoder_prepare): Updated.
8457 2010-02-27 Werner Lemberg <wl@gnu.org>
8460 Suggested by Behdad.
8462 * src/base/ftobjs.c (FT_Get_First_Char): Don't use a loop since we
8463 call FT_Get_Next_Char anyway if necessary.
8465 2010-02-26 Behdad Esfahbod <behdad@behdad.org>
8467 Improve handling of invalid glyph indices in char->index functions.
8469 * src/base/ftobjs.c (FT_Get_First_Char, FT_Get_Next_Char): Use a
8472 2010-02-18 Chris Liddell <chris.liddell@artifex.com>
8474 [truetype] Fix Savannah bug #28905.
8476 Initialize phantom points before calling the incremental interface
8477 to update glyph metrics.
8479 * src/truetype/ttgload.c (tt_get_metrics_incr_overrides)
8480 [FT_CONFIG_OPTION_INCREMENTAL]: New function, split off from...
8481 (tt_get_metrics): This.
8483 (load_truetype_glyph): Use tt_get_metrics_incr_overrides.
8485 ----------------------------------------------------------------------------
8487 Copyright 2010-2013 by
8488 David Turner, Robert Wilhelm, and Werner Lemberg.
8490 This file is part of the FreeType project, and may only be used, modified,
8491 and distributed under the terms of the FreeType project license,
8492 LICENSE.TXT. By continuing to use, modify, or distribute this file you
8493 indicate that you have read the license and understand and accept it
8498 version-control: never