1 2013-06-19 Werner Lemberg <wl@gnu.org>
3 * Version 2.5.0 released.
4 =========================
7 Tag sources with `VER-2-5-0'.
9 * docs/VERSION.DLL: Update documentation and bump version number to
12 * README, Jamfile (RefDoc),
13 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
14 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
15 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
16 builds/win32/visualc/freetype.dsp,
17 builds/win32/visualc/freetype.vcproj,
18 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
19 builds/win32/visualce/freetype.vcproj,
20 builds/win32/visualce/index.html,
21 builds/wince/vc2005-ce/freetype.vcproj,
22 builds/wince/vc2005-ce/index.html,
23 builds/wince/vc2008-ce/freetype.vcproj,
24 builds/wince/vc2008-ce/index.html: s/2.4.12/2.5.0/, s/2412/250/.
26 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 5.
27 (FREETYPE_PATCH): Set to 0.
29 * builds/unix/configure.raw (version_info): Set to 16:2:10.
31 * src/base/ftobjs.c (FT_Open_Face): Pacify compiler.
32 * src/truetype/ttinterp.c (Ins_MSIRP, Ins_MIRP): Ditto.
34 2013-06-18 Werner Lemberg <wl@gnu.org>
36 Fix Savannah bug #39269.
38 * src/base/ftgloadr.c (FT_GlyphLoader_CheckPoints): Free memory in
39 case of reacollocation failures.
41 2013-06-18 Andrew Church <achurch+savannah@achurch.org>
43 Fix Savannah bug #39266.
45 If memory allocations fail at certain points while opening a font,
46 FreeType can either crash due to a NULL dereference or leak memory.
48 * include/freetype/internal/ftobjs.c (FT_Face_InternalRec,
49 FT_LibraryRec): Make `refcount' a signed integer. If, for example,
50 FT_Open_Face() fails in a memory allocation before the face's
51 reference count is set to 1, a subsequent `FT_Done_Library' call
52 would otherwise loop over `FT_Done_Face' 2^32 times before freeing
55 * src/base/ftobjs.c (open_face): Initialize `stream' and friends
57 (FT_Open_Face) <Fail>: Behave correctly if `node' is NULL.
58 (FT_Destroy_Module) <Fail>: Check that `renderer_clazz' is valid.
60 2013-06-14 Werner Lemberg <wl@gnu.org>
62 * src/smooth/ftgrays.c One final pragma to silence 64-bit MSVC.
64 2013-06-06 Dave Arnold <darnold@adobe.com>
65 Werner Lemberg <wl@gnu.org>
67 [cff] Add code to Adobe's engine to handle ppem > 2000.
69 * src/cff/cffgload.c (cff_slot_load): If we get
70 FT_Err_Glyph_Too_Big, retry unhinted and scale up later on.
72 2013-06-12 Werner Lemberg <wl@gnu.org>
74 Another try on pragmas.
76 * include/freetype/internal/ftdebug.h: Move pragmas to...
77 * include/freetype/internal/internal.h: ... this file since it gets
78 included by all source files.
79 * include/freetype/internal/ftserv.h: Remove pragma which has no
82 2013-06-12 Werner Lemberg <wl@gnu.org>
84 * include/freetype/internal/ftdebug.h: Disable MSVC warning C4127.
86 This partially undoes commit 3f6e0e0c.
88 2013-06-12 Werner Lemberg <wl@gnu.org>
90 More compiler warning fixes.
92 */*: Use cast to `FT_Bool' (or `Bool') where appropriate.
94 2013-06-10 Werner Lemberg <wl@gnu.org>
96 [truetype] Improve handling of broken sbit advance widths.
98 * src/truetype/ttgload.c (TT_Load_Glyph): Use the glyph's (scaled)
99 `linearHoriAdvance' if the sbit's `horiAdvance' value is zero.
101 Cf. font `Fixedsys Excelsior' v3.01 (FSEX300.ttf), glyph A, 16ppem.
103 2013-06-10 Werner Lemberg <wl@gnu.org>
105 [sfnt] Improve embedded bitmap tracing.
107 * src/base/ftobjs.c (FT_Request_Size): Move trace message regarding
108 bitmap strike match to...
109 (FT_Match_Size): This function.
111 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics,
112 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
113 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
114 tt_sbit_decoder_load_image): Decorate with tracing messages.
116 2013-06-10 Werner Lemberg <wl@gnu.org>
118 Fix Savannah bug #39160.
120 * src/truetype/ttinterp.c (Ins_SDPVTL): Set projection vector too
121 for the degenerate case.
123 2013-06-09 David Turner <digit@google.com>
125 * src/cache/ftcmanag.c (FTC_Manager_Reset): Add missing cache flush.
127 This code, present since eight(!) years in the unused `CACHE'
128 branch, has been forgotten to apply to the master branch. It's
129 really amazing that noone has ever complained since
130 `FTC_Manager_Reset' is pretty useless without flushing the cache.
132 2013-06-07 Werner Lemberg <wl@gnu.org>
134 Add and improve pragmas for MSVC compiler.
136 * include/freetype/internal/ftdebug.h: Remove pragmas.
137 * include/freetype/internal/ftserv.h: Use push and pop for pragmas.
138 * include/freetype/internal/ftvalid.h: Handle warning C4324.
139 * src/base/ftobjs.c: Use push and pop for pragmas.
140 * src/gzip/ftgzip.c: Handle warning C4244.
142 2013-06-07 Werner Lemberg <wl@gnu.org>
144 [cff] s/cf2_getGlyphWidth/cf2_getGlyphOutline/.
146 * src/cff/cf2font.c, src/cff/cf2font.h, src/cff/cf2ft.c: Do it.
148 2013-06-06 Dave Arnold <darnold@adobe.com>
150 [cff] Add early exit feature for width-only calls.
152 This is for `FT_Get_Advance'.
154 There are 7 places where the spec says the width can be defined:
164 * src/cff/cf2intrp.c (cf2_doStems): Exit early for width-only calls,
167 (cf2_interpT2CharString) <cf2_cmdHSTEM>, <cf2_cmdVSTEM>,
168 <cf2_cmdVMOVETO>, <cf2_cmdENDCHAR>, <cf2_cmdHINTMASK>,
169 <cf2_cmdRMOVETO>, <cf2_cmdHMOVETO>: Exit early for width-only calls.
171 2013-06-06 Werner Lemberg <wl@gnu.org>
173 Next round of compiler fixes.
175 * builds/win32/ftdebug.c, builds/wince/ftdebug.c (ft_debug_init):
178 * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Fix
180 * include/freetype/internal/ftstream.h: Decorate stream and frame
181 macros with `FT_Long' and `FT_ULong' as appropriate.
183 * src/base/ftrfork.c (raccess_guess_darwin_hfsplus,
184 raccess_guess_darwin_newvfs): Use cast.
186 * src/bdf/bdflib.c (_bdf_set_default_spacing): Use cast.
188 * src/cache/ftcmanag.c (FTC_Manager_Check): Fix cast.
189 * src/cache/ftcmanag.h (FTC_ManagerRec): Ditto.
191 * src/cff/cf2arrst.c (cf2_arrstack_setNum_Elements): Use cast.
192 * src/cff/cf2ft.c (cf2_freeSeacComponent): Ditto.
193 * src/cff/cffobjs.c (remove_subset_prefix, remove_style): Ditto.
195 * src/cid/cidparse.c (cid_parser_new): Use cast.
197 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Use cast.
199 * src/psaux/psobjs.c (reallocate_t1_table): Fix argument type.
201 * src/raster/ftraster.c (ft_black_reset): Use cast.
203 * src/truetype/ttgxvar.c (FT_Stream_FTell): Use cast.
204 (ALL_POINTS): Fix cast.
206 * src/type1/t1driver.c (t1_ps_get_font_value): Add casts.
207 * src/type1/t1parse.c (T1_Get_Private_Dict): Add cast.
209 2013-06-05 Dave Arnold <darnold@adobe.com>
211 Fix more MSVC Win32 compiler warnings.
213 * src/base/ftobjs.c: Fix typo in MS pragma.
215 * src/base/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
216 `lineno' is only used in debug mode.
218 * src/cff/cf2ft.c (cf2_builder_moveTo): `params' is only used in
221 2013-06-05 Werner Lemberg <wl@gnu.org>
223 Fix compiler warnings.
225 * include/freetype/internal/ftmemory.h: Decorate memory allocation
226 macros with `FT_Long' where appropriate.
227 Remove duplicate of FT_MEM_QRENEW_ARRAY definition.
229 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
232 * src/base/ftobjs.c: Add warning disabling pragma for MSVC while
235 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdESC>: Add
238 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_compound): Fix casts.
239 (tt_sbit_decoder_load_bitmap): Beautification.
241 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Initialize
244 * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Pacify compiler.
246 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Use unsigned constants
249 * src/type1/t1load.c (T1_Get_MM_Var): Ditto.
251 2013-06-04 Werner Lemberg <wl@gnu.org>
253 * src/cff/cf2font.c (cf2_getGlyphWidth): Initialize `advWidth'.
255 Problem reported by Ingmar Sittl <ingmar.sittl@elektrobit.com>.
257 2013-06-04 Werner Lemberg <wl@gnu.org>
259 Apply fixes for cppcheck nitpicks.
261 http://cppcheck.sourceforge.net/
263 The call was (from the top-level of the FreeType tree):
268 -I include/freetype/ \
269 -I include/freetype/config/ \
270 -I include/freetype/internal/ \
273 Note that the current version heavily chokes on FreeType, delivering
274 many wrong results. I will report those issues to the cppcheck team
275 so that a newer version gives improved results hopefully.
277 */* Improve variable scopes.
278 */* Remove redundant initializations which get overwritten.
280 * src/base/ftmac.c ,builds/mac/ftmac.c (count_faces_scalable):
281 Remove unused variable.
283 * src/base/ftdbgmem.c (ft_mem_table_destroy): `table' can't be zero.
285 * src/gxvalid/gxvkern.c (gxv_kern_subtable_fmt1_entry_validate):
286 Remove functionless code.
288 * src/tools/ftrandom.c (main): Fix memory leak.
290 2013-06-03 Werner Lemberg <wl@gnu.org>
292 Add CFF_CONFIG_OPTION_OLD_ENGINE configuration option.
294 This controls whether the old FreeType CFF engine gets compiled into
295 FreeType. It is now disabled by default.
297 * devel/ftoption.h, include/freetype/config/ftoption.h
298 (CFF_CONFIG_OPTION_OLD_ENGINE): New macro.
300 * src/cff/cffdrivr.c (cff_property_set), src/cff/cffgload.c
301 (CFF_Operator, cff_argument_counts, cff_builder_add_point,
302 cff_operator_seac, cff_decoder_parse_charstrings, cff_slot_load),
303 src/cff/cffgload.h, src/cff/cffobjs.c (cff_driver_init): Use
304 CFF_CONFIG_OPTION_OLD_ENGINE to guard the affected code.
306 * docs/CHANGES: Updated.
308 2013-06-02 Werner Lemberg <wl@gnu.org>
310 Fix PNG library handling.
312 * builds/unix/configure.raw: Don't use LIBPNG_LIBS but
315 2013-05-23 Behdad Esfahbod <behdad@google.com>
317 Add support for color embedded bitmaps (eg. color emoji).
319 A new load flag, FT_LOAD_COLOR, makes FreeType load color
320 embedded-bitmaps, following this draft specification
322 https://color-emoji.googlecode.com/git/specification/v1.html
324 which defines two new SFNT tables, `CBDT' and `CBLC' (named and
325 modeled after `EBDT' and `EBLC', respectively). The color bitmaps
326 are stored in the new FT_PIXEL_MODE_BGRA format to represent BGRA
327 pre-multiplied sRGB images. If PNG support is available, PNG color
328 images as defined in the same proposed specification are supported
331 Note that color bitmaps are converted to grayscale if client didn't
334 * builds/unix/configure.raw: Search for libpng.
335 Add `--without-png' option.
337 * devel/ftoption.h, include/freetype/config/ftoption.h
338 (FT_CONFIG_OPTION_USE_PNG): New macro.
340 * include/freetype/freetype.h (FT_LOAD_COLOR): New load flag.
342 * include/freetype/ftimage.h (FT_Pixel_Mode): Add
343 `FT_PIXEL_MODE_BGRA'.
345 * include/freetype/tttags.h (TTAG_CBDT, TTAG_CBLC): New tags.
347 * src/base/ftbitmap.c (FT_Bitmap_Embolden): Updated.
348 (ft_gray_for_premultiplied_srgb_bgra): New function.
349 (FT_Bitmap_Convert): Handle FT_PIXEL_MODE_BGRA.
351 * src/sfnt/pngshim.c, src/sfnt/pngshim.h: New files.
353 * src/sfnt/sfnt.c: Include `pngshim.c'.
355 * src/sfnt/ttsbit.c: Include FT_BITMAP_H and `pngshim.h'
356 (tt_face_load_eblc): Load `CBLC'.
357 (tt_sbit_decoder_init): Load `CBDT'.
358 (tt_sbit_decoder_alloc_bitmap): Pass load flags to select between
359 color and grayscale bitmaps.
360 Set `num_grays'. This is used by `ftview' to choose the blending
362 (tt_sbit_decoder_load_byte_aligned,
363 tt_sbit_decoder_load_bit_aligned, tt_sbit_decoder_load_compound,
364 tt_sbit_decoder_load_image): Pass load flag.
366 Don't call `tt_sbit_decoder_alloc_bitmap'.
368 (tt_sbit_decoder_load_png) [FT_CONFIG_OPTION_USE_PNG]: New function.
369 (tt_sbit_decoder_load_bitmap): Pass load flag.
370 Handle new glyph formats 17, 18, and 19.
371 Call `tt_sbit_decoder_alloc_bitmap'.
372 Flatten color bitmaps if necessary.
373 (tt_face_load_sbit_image): Updated.
375 * src/sfnt/rules.mk (SFNT_DRV_SRC): Add `pngshim.c'.
377 * docs/CHANGES: Updated.
379 2013-05-24 Guenter <info@gknw.net>
381 Apply Savannah patch #8055.
383 Make `apinames' create an import file for NetWare.
385 * src/tools/apinames.c (PROGRAM_VERSION): Set to 0.2.
386 (OutputFormat): Add `OUTPUT_NETWARE_IMP'.
387 (names_dump): Handle it.
389 (main): Handle new command line flag `-wN'.
391 2013-05-23 Behdad Esfahbod <behdad@behdad.org>
395 * src/truetype/ttinterp.c (TT_RunIns)
396 [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Make it work.
398 2013-05-22 Infinality <infinality@infinality.net>
400 [truetype] Formatting and an additional subpixel tweak.
402 * src/truetype/ttinterp.c (Ins_SHPIX): Formatting fix.
403 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules):
404 Revert previous modification for Verdana clones.
406 2013-05-22 Infinality <infinality@infinality.net>
408 [truetype] Adjust subpixel zp2 moves and tweak rules.
410 These modifications fix thin diagonal stems in some legacy fonts.
412 * src/truetype/ttinterp.c (Direct_Move_X): Remove unused macro.
413 (Move_Zp2_Point): Don't always disable x moves for subpixel rendering.
414 (Ins_SHP): Disable x moves here for subpixel rendering.
415 (Ins_SHPIX): Only disable x moves in compatibility mode.
416 Split out zp2 move reversals and reorder conditional respectively.
418 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules): Fix oversight.
419 Only adjust Verdana clones for 17 ppem.
420 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Courier New.
421 (ALWAYS_SKIP_DELTAP_Rules): Found additional cases for Arial `s'.
423 2013-05-20 Infinality <infinality@infinality.net>
425 [truetype] Simplify and improve subpixel function detection.
427 Some small enhancements have allowed the removal of many macros and
428 the simplification of existing rules in `ttsubpix.c'.
430 * src/truetype/ttsubpix.h (SPH_TWEAK_ALLOW_X_DMOVEX,
431 SPH_TWEAK_ALLOW_X_MOVE_ZP2,
432 SPH_TWEAK_DELTAP_SKIP_EXAGGERATED_VALUES,
433 SPH_TWEAK_SKIP_INLINE_DELTAS, SPH_TWEAK_MIRP_CVT_ZERO): Removed.
434 (SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES_DELTAP): New rule macro.
436 * src/truetype/ttsubpix.c: Updated affected rules.
438 * src/truetype/ttinterp.c (Direct_Move_X): Updated.
439 (INS_FDEF): Add additional function detection.
440 (INS_ENDF): Set runtime flag.
441 (Ins_CALL): Skip the call under certain conditions.
443 (Ins_LOOPCALL): Skip the call under certain conditions.
445 (Move_Zp2_Point): Updated.
446 (Ins_SHPIX): Updated.
447 Skip the move under some situations.
448 (Ins_MIAP): Improve conditions.
450 (Ins_DELTAP): Skip move under certain conditions.
452 (TT_RunIns): Updated.
453 Add code to handle new function detection.
456 2013-05-17 Werner Lemberg <wl@gnu.org>
458 Update more FT_Err_XXX macros using FT_ERR and FT_THROW;
460 * builds/amiga/src/base/ftsystem.c, builds/mac/ftmac.c,
461 builds/unix/ftsystem.c, builds/vms/ftsystem.c: Do it.
463 2013-05-15 Werner Lemberg <wl@gnu.org>
465 [truetype] Add `interpreter-version' property.
467 This makes the option TT_CONFIG_OPTION_SUBPIXEL_HINTING controllable
470 * include/freetype/ftttdrv.h: New file.
472 * include/freetype/config/ftheader.h (FT_TRUETYPE_DRIVER_H): New
475 * src/truetype/ttdriver.c: Include FT_TRUETYPE_DRIVER_H.
476 (tt_property_set, tt_property_get): Fill templates.
478 * src/truetype/ttobjs.h (TT_DriverRec): Add `interpreter_version'
480 Remove unused `extension_component' member.
482 * src/truetype/ttgload.c: Include FT_TRUETYPE_DRIVER_H.
483 (tt_get_metrics, TT_Hint_Glyph, TT_Process_Simple_Glyph,
484 compute_glyph_metrics, tt_loader_init): Use `interpreter_version'.
486 * src/truetype/ttinterp.c: Include FT_TRUETYPE_DRIVER_H.
487 (SUBPIXEL_HINTING): New macro to check `interpreter_version' flag.
488 Update all affected functions to use it.
489 Use TT_INTERPRETER_VERSION_XXX where appropriate.
491 * src/truetype/ttobjs.c: Include FT_TRUETYPE_DRIVER_H.
492 (tt_driver_init): Initialize `interpreter_version'.
494 * src/truetype/ttsubpix.c: Include FT_TRUETYPE_DRIVER_H.
495 Use TT_INTERPRETER_VERSION_XXX where appropriate.
497 2013-05-13 Werner Lemberg <wl@gnu.org>
499 [truetype] Avoid empty source file.
501 * src/truetype/ttsubpix.c [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]:
502 Provide dummy typedef.
504 2013-05-13 Werner Lemberg <wl@gnu.org>
506 * src/cff/cf2font.c (cf2_getGlyphWidth): Fix uninitialized variable.
508 Fix suggested by Vaibhav Nagarnaik <vnagarnaik@gmail.com>.
510 2013-05-13 Brian Nixon <bnixon@yahoo.com>
512 Fix Savannah bug #38970.
514 * src/base/ftdebug.c, builds/win32/ftdebug.c,
515 builds/wince/ftdebug.c, builds/amiga/src/base/ftdebug.c
516 (ft_debug_init): Don't read past the environment variable FT2_DEBUG.
518 2013-05-12 Werner Lemberg <wl@gnu.org>
520 [truetype] Add framework for TrueType properties.
522 * src/truetype/ttdrivr.c: Include FT_SERVICE_PROPERTIES_H.
523 (tt_property_set, tt_property_get): New functions, still empty.
524 Define `tt_service_properties' service.
525 Update `tt_services'.
527 * src/truetype/ttpic.h: Include FT_SERVICE_PROPERTIES_H.
528 (TT_SERVICE_PROPERTIES_GET): New macro.
529 (TTModulePIC): Add `tt_service_properties'.
531 2013-05-12 Werner Lemberg <wl@gnu.org>
533 Fix Savannah bug #38967.
535 * src/base/ftcalc.c (FT_DivFix) [FT_LONG64]: Fix cast.
537 2013-05-12 Werner Lemberg <wl@gnu.org>
539 Introduce unsigned 64bit type (if available).
541 * include/freetype/config/ftconfig.h: Define FT_UINT64 if available.
542 [FT_LONG64]: Provide FT_UInt64.
544 * builds/unix/ftconfig.in: Synchronized.
546 2013-05-12 Werner Lemberg <wl@gnu.org>
548 Fix Savannah bug #38968.
550 * include/freetype/ftmodapi.h: Add `FT_EXPORT' to
551 FT_Property_{Set,Get}.
552 * src/base/ftobjs.c: Add `FT_EXPORT_DEF' to
553 FT_Property_{Set,Get}.
555 2013-05-10 Werner Lemberg <wl@gnu.org>
557 [sfnt] Clean up bitmap code.
559 * src/sfnt/ttsbit.c: Deleted.
560 * src/sfnt/ttsbit0.c: Renamed to `ttsbit.c'.
561 * rules.mk (SFNT_DRV_H): Updated.
563 2013-05-10 Werner Lemberg <wl@gnu.org>
565 */* [FT_CONFIG_OPTION_OLD_INTERNALS]: Remove macro and guarded code.
567 2013-05-08 Werner Lemberg <wl@gnu.org>
569 * Version 2.4.12 released.
570 ==========================
573 Tag sources with `VER-2-4-12'.
575 * docs/VERSION.DLL: Update documentation and bump version number to
578 * README, Jamfile (RefDoc),
579 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
580 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
581 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
582 builds/win32/visualc/freetype.dsp,
583 builds/win32/visualc/freetype.vcproj,
584 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
585 builds/win32/visualce/freetype.vcproj,
586 builds/win32/visualce/index.html,
587 builds/wince/vc2005-ce/freetype.vcproj,
588 builds/wince/vc2005-ce/index.html,
589 builds/wince/vc2008-ce/freetype.vcproj,
590 builds/wince/vc2008-ce/index.html: s/2.4.11/2.4.12/, s/2411/2412/.
592 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 12.
594 * builds/unix/configure.raw (version_info): Set to 16:1:10.
596 2013-05-08 Werner Lemberg <wl@gnu.org>
598 * docs/CHANGES: Updated.
600 2013-05-08 Werner Lemberg <wl@gnu.org>
602 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Typo.
604 2013-05-05 Werner Lemberg <wl@gnu.org>
606 Synchronize `ftconfig.h'.
608 * builds/unix/ftconfig.in: Updated.
610 2013-05-05 Werner Lemberg <wl@gnu.org>
612 Fix compilation with C++.
614 * src/base/md5.c (body): Use proper cast.
616 2013-05-05 Werner Lemberg <wl@gnu.org>
618 Fix 64bit compilation issues.
620 * include/freetype/config/ftconfig.h [FT_LONG64]: Typedef
623 * src/base/ftcalc.c: Remove typedef of `FT_Int64'.
624 (FT_DivFix): Fix cast.
625 * src/base/fttrigon.c: Remove typedef of `FT_Int64'.
627 2013-05-05 Werner Lemberg <wl@gnu.org>
629 [raster] Fix clang issues.
631 Fix suggested by <octoploid@yandex.com>.
633 * src/raster/ftraster.c (ULong): New typedef.
634 (SCALED): Add proper cast.
636 2013-05-04 Werner Lemberg <wl@gnu.org>
640 * src/base/fttrigon.c (ft_trig_prenorm, FT_Vector_Rotate): Use
643 * src/cff/cf2intrp.c (cf2_interpT2CharString) <default>: Force
644 unsigned for computations.
645 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Ditto.
646 * src/cff/cffparse.c (cff_parse_integer): Ditto.
648 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Ditto.
650 2013-05-04 Werner Lemberg <wl@gnu.org>
652 [cff] Make Adobe CFF engine work correctly on 64bit hosts.
654 Reported by numerous people on the `freetype-devel' list. Without
655 this fix, glyphs aren't properly aligned on a common baseline.
657 On 64bit systems, `FT_Pos' expands to `long int', having a width of
658 64bit. `CF2_Fixed' expands to `int' which is normally 32bit wide on
659 64bit hosts also. Wrong casts filled up the blues arrays with
660 incorrect values. Note that all blues values are accessed with the
661 `cf2_blueToFixed' macro which handles the 64bit to 32bit conversion.
663 * src/cff/cf2ft.h (cf2_getBlueValues, cf2_getOtherBlues,
664 cf2_getFamilyBlues, cf2_getFamilyOtherBlues): Use `FT_Pos' for
665 `data', not `CF2_Fixed'.
666 * src/cff/cf2ft.c (cf2_getBlueValues, cf2_getOtherBlues,
667 cf2_getFamilyBlues, cf2_getFamilyOtherBlues): Updated.
668 * src/cff/cf2blues.c (cf2_blues_init): Updated.
670 2013-05-04 Werner Lemberg <wl@gnu.org>
672 More fixes for clang's `sanitize' feature.
674 * src/base/ftcalc.c (FT_DivFix): Use unsigned values for
675 computations which use the left shift operator and convert to signed
677 * src/base/fttrigon.c (ft_trig_prenorm, FT_Vector_Rotate,
678 FT_Vector_Length, FT_Vector_Polarize): Ditto.
680 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Simplify.
681 * src/cff/cffload.c (cff_subfont_load): Fix constant.
682 * src/cff/cffparse.c (cff_parse_integer, cff_parse_real, do_fixed,
683 cff_parse_fixed_dynamic): Use unsigned values for computations which
684 use the left shift operator and convert to signed as the last step.
686 * src/cid/cidload.c (cid_get_offset): Ditto.
688 * src/psaux/psconv.c (PS_Conv_ToFixed): Ditto.
689 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Ditto.
691 * src/truetype/ttinterp.c (TT_MulFix14, TT_DotFix14): Ditto.
693 2013-05-04 Werner Lemberg <wl@gnu.org>
695 Fix errors reported by clang's `sanitize' feature.
697 * include/freetype/internal/ftstream.h: Simplify and fix integer
699 (FT_INT8_, FT_BYTE_I16, FT_BYTE_I32, FT_INT8_I16, FT_INT8_I32,
700 FT_INT8_I32, FT_INT8_U32): Removed.
701 (FT_PEEK_SHORT, FT_PEEK_LONG, FT_PEEK_OFF3, FT_PEEK_SHORT_LE,
702 FT_PEEK_LONG_LE, FT_PEEK_OFF3_LE): Use unsigned values for
703 computations and convert to signed as the last step.
705 * src/cff/cf2fixed.h (cf2_intToFixed, cf2_fixedToInt,
706 cf2_fracToFixed): Avoid shifts of negative values.
707 (cf2_intToFrac, cf2_fixedToFrac, cf2_fixedTo26Dot6): Removed,
710 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdEXTENDEDNMBR,
711 default>: Use unsigned values for computations and convert to signed
713 Use proper types in tracing messages.
715 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Use unsigned
716 values for computation of operands and convert to signed as the last
718 Use proper type in tracing message.
720 2013-05-03 Werner Lemberg <wl@gnu.org>
722 * src/cff/cf2blues.c: Remove dead code.
724 2013-05-02 Chris Liddell <chris.liddell@artifex.com>
726 * src/cff/cffgload.c: Include FT_CFF_DRIVER_H.
728 2013-04-27 Werner Lemberg <wl@gnu.org>
730 * docs/CHANGES: Updated.
733 2013-04-13 Werner Lemberg <wl@gnu.org>
735 [cff] Add a new Type 2 interpreter and hinter.
737 This work, written by Dave Arnold <darnold@adobe.com> and fully
738 integrated into FreeType by me, is a donation by Adobe in
739 collaboration with Google. It is vastly superior to the old CFF
740 engine, and it will replace it soon. Right now, it is still off by
741 default, and you have to explicitly select it using the new
742 `hinting-engine' property of the cff driver.
744 For convenience, (most of) the new files are committed separately.
746 * include/freetype/config/ftheader.h (FT_CFF_DRIVER_H): New macro.
747 * include/freetype/ftcffdrv.h: New file to access CFF driver
749 * include/freetype/fterrdef.h (FT_Err_Glyph_Too_Big): New error
751 * include/freetype/internal/fttrace.h: Add `cf2blues', `cf2hints',
754 * src/cff/cffgload.h (CFF_SubFont): New member `current_subfont'.
755 * src/cff/cffobjs.h (CFF_DriverRec): New members `hinting_engine'
756 and `no_stem_darkening'.
757 * src/cff/cfftypes.h (CFF_FontRec): New member `cf2_instance'.
759 * src/cff/cff.c: Include new files.
760 * src/cff/cffdrivr.c (cff_property_set, cff_property_get): Handle
761 `hinting-engine' and `no-stem-darkening' properties (only the Adobe
762 engine listens to them).
763 * src/cff/cffgload.c: Include `cf2ft.h'.
764 (cff_decoder_prepare): Initialize `current_subfont'.
765 (cff_build_add_point): Handle Adobe engine which uses 16.16
767 (cff_slot_load): Handle FT_LOAD_NO_SCALE and FT_LOAD_NO_HINTING
769 Choose rendering engine based on `hinting_engine' property.
770 * src/cff/cffload.c (cff_font_done): Call finalizer of the Adobe
772 * src/cff/cffobjs.c: Include FT_CFF_DRIVER_H.
773 (cff_driver_init): Set default property values.
775 * src/cff/rules.mk (CFF_DRV_SRC, CFF_DRV_H): Add new files.
777 * src/cff/cf2*.*: New files, containing the Adobe engine.
779 2013-04-12 Werner Lemberg <wl@gnu.org>
781 [cff] Minor code administration issues.
783 * src/cff/cffgload.c (check_points): Rename to...
784 (cff_check_points): ...this and make it FT_LOCAL.
785 (cff_builder_add_point, cff_builder_add_point1,
786 cff_builder_start_point, cff_builder_close_contour,
787 cff_lookup_glyph_by_stdcharcode, cff_get_glyph_data,
788 cff_free_glyph_data): Make them FT_LOCAL.
790 * src/cff/cffgload.h: Updated.
792 2013-04-12 Werner Lemberg <wl@gnu.org>
794 Add output bitmap checksums.
796 Use `FT2_DEBUG=bitmap:3' for tracing.
798 * src/base/md5.c, src/base/md5.h: New files, taken from
800 http://openwall.info/wiki/people/solar/software/public-domain-source-code/md5
802 * include/freetype/internal/fttrace.h: Add `bitmap'.
804 * src/base/ftobjs.c [FT_DEBUG_LEVEL_TRACE]: Include `md5.c'
806 (FT_Render_Glyph_Internal) [FT_DEBUG_LEVEL_TRACE]: For tracing,
807 convert resulting bitmap to a uniform format and compute a checksum.
808 Use `bitmap' category for the tracing message.
810 * src/base/rules.mk (BASE_H): Updated.
812 * docs/LICENSE.TXT: Updated.
814 2013-04-12 Werner Lemberg <wl@gnu.org>
816 [cff] Add framework for CFF properties.
818 * include/freetype/internal/ftserv.h (FT_DEFINE_SERVICEDESCREC7):
821 * src/cff/cffdrivr.c: Include FT_SERVICE_PROPERTIES_H.
822 (cff_property_set, cff_property_get): New functions, still empty.
823 Define `cff_service_properties' service.
824 Update `cff_services'.
826 * src/cff/cffpic.h: Include FT_SERVICE_PROPERTIES_H.
827 (CFF_SERVICE_PROPERTIES_GET): New macro.
828 (CffModulePIC): Add `cff_service_properties'.
830 2013-04-03 Werner Lemberg <wl@gnu.org>
832 [bdf] Fix Savannah bug #38589.
834 * src/bdf/bdflib.c (_bdf_readstream): Thinko.
836 2013-03-31 Werner Lemberg <wl@gnu.org>
838 * configure: Use egrep, not grep.
840 Problem reported Mojca Miklavec <mojca.miklavec.lists@gmail.com>.
842 2013-03-29 Werner Lemberg <wl@gnu.org>
844 * include/freetype/ftlcdfil.h: Add description of color filtering.
846 Based on a contribution from Antti S. Lankila <alankila@bel.fi>
847 (Savannah bug #38607).
849 2013-03-23 Werner Lemberg <wl@gnu.org>
853 * src/autofit/afmodule.c (af_property_set): Typo.
854 (af_autofitter_init, af_autofitter_done): Use cast.
856 2013-03-21 Werner Lemberg <wl@gnu.org>
858 * configure: Automatically test for `gmake' also.
860 Suggested by Mojca Miklavec <mojca.miklavec.lists@gmail.com>.
862 2013-03-21 Peter Breitenlohner <peb@mppmu.mpg.de>
864 Respect CONFIG_SHELL from the environment.
866 Some large packages using FreeType have to use a broken (deficient)
867 /bin/sh. The configure scripts (as generated by Autoconf) are
868 clever enough to find a better shell and put that one into the
869 environment variable CONFIG_SHELL. If that environment variable is
870 already set the script skips the test and assumes to be already
871 running under a good shell.
873 * builds/unix/detect.mk: Honour CONFIG_SHELL.
874 * builds/unix/unix-def.in (SHELL): Define.
876 2013-03-21 Werner Lemberg <wl@gnu.org>
878 Fix Savannah patch #7971.
880 * configure: Handle MAKE environment variable also.
882 2013-03-17 Werner Lemberg <wl@gnu.org>
884 Fix Savannah bug #38538.
886 * builds/amiga/src/base/ftdebug.c, builds/win32/ftdebug.c,
887 builds/wince/ftdebug.c (FT_Throw): Add function.
889 2013-03-17 Werner Lemberg <wl@gnu.org>
891 [raster] Remove dead code.
893 * src/raster/rastpic.c (ft_raster1_renderer_class_pic_init)
894 src/smooth/ftspic.c (ft_smooth_renderer_class_pic_init): Do it.
896 2013-03-17 Werner Lemberg <wl@gnu.org>
898 * src/pshinter/pshpic.h (GET_PIC): Use correct container.
900 2013-03-15 Werner Lemberg <wl@gnu.org>
902 * include/freetype/ftmoderr.h: Fix commit from 2013-03-11.
904 The previous version was not backwards compatible. Reported by
907 2013-03-14 Werner Lemberg <wl@gnu.org>
909 */*: Use FT_ERR_EQ, FT_ERR_NEQ, and FT_ERR where appropriate.
911 FT_Err_XXX and friends are no longer directly used in the source
914 2013-03-14 Werner Lemberg <wl@gnu.org>
916 New error management macros.
918 * include/freetype/fterrors.h (FT_ERR_XCAT, FT_ERR_CAT): Move to...
919 * include/freetype/fttypes.h: ... this file.
920 (FT_ERR, FT_ERR_EQ, FT_ERR_NEQ, FT_MODERR_EQ, FT_MODERR_NEQ): New
923 * include/freetype/freetype.h: Updated.
925 2013-03-14 Werner Lemberg <wl@gnu.org>
927 */*: Use FT_Err_Ok only.
929 This is a purely mechanical conversion.
931 2013-03-14 Werner Lemberg <wl@gnu.org>
935 This is essentially a mechanical conversion, adding inclusion of
936 `FT_INTERNAL_DEBUG_H' where necessary, and providing the macros for
937 stand-alone compiling modes of the rasterizer modules.
939 To convert the remaining occurrences of FT_Err_XXX and friends it is
940 necessary to rewrite the code. Note, however, that it doesn't harm
941 if some cases are not handled since FT_THROW is a no-op.
943 2013-03-13 Werner Lemberg <wl@gnu.org>
945 Introduce `FT_THROW' macro.
947 The idea is to replace code like
949 return FT_Err_Foo_Bar;
953 return CFF_Err_Foo_Bar;
957 return FT_THROW( Foo_Bar );
959 The FT_THROW macro has two functions:
961 . It hides the module specific prefix.
963 . In debug mode, it calls the empty function `FT_Throw' which can
964 be thus used to set a breakpoint.
966 * include/freetype/internal/ftdebug.h (FT_THROW): New macro.
967 (FT_Throw): New prototype.
968 * src/base/ftdebug.c (FT_Throw): New function.
970 2013-03-12 Werner Lemberg <wl@gnu.org>
972 Remove `FT_KEEP_ERR_PREFIX'.
974 The idea is to always have FT_ERR_PREFIX available internally.
976 * include/freetype/fterrors.h: Use FT2_BUILD_LIBRARY to guard
977 undefinition of FT_ERR_PREFIX
979 * src/gxvalid/gxverror.h, src/otvalid/otverror.h,
980 src/sfnt/sferrors.h: Updated.
982 2013-03-11 Werner Lemberg <wl@gnu.org>
984 [gxvalid] Fix module error.
986 * src/gxvalid/gxverror.h (FT_ERR_BASE): Define as
988 * include/freetype/ftmoderr.h: Add module error for `GXvalid'.
990 2013-03-11 Werner Lemberg <wl@gnu.org>
992 Always use module related error codes.
994 * src/cff/cffobjs.c (cff_face_init), src/type1/t1objs.c
995 (T1_Face_Init), src/type42/t42objs.c (T42_Face_Init): Use
998 * src/type1/t1load.c (parse_encoding): Use
999 T1_Err_Unknown_File_Format.
1001 2013-03-08 Werner Lemberg <wl@gnu.org>
1003 [cff] Set `linear{Hori,Vert}Advance' for embedded bitmaps also.
1005 Problem reported by Khaled Hosny <khaledhosny@eglug.org>.
1007 * src/cff/cffgload.c (cff_slot_load): Implement it.
1009 2013-02-23 Alexei Podtelezhnikov <apodtele@gmail.com>
1011 [base] Fix commit ab02d9e8.
1013 * src/base/ftbbox.c (BBox_Cubic_Check): Change scaling to msb of 22.
1015 2013-02-19 Alexei Podtelezhnikov <apodtele@gmail.com>
1017 [base] New bisecting BBox_Cubic_Check (disabled).
1019 * src/base/ftbbox.c (BBox_Cubic_Check): New bisecting algorithm
1020 for extremum search built around simple condition that defines
1021 which half contains the extremum.
1023 2013-02-18 Alexei Podtelezhnikov <apodtele@gmail.com>
1025 [tools] Update BBox testing tool.
1027 * src/tools/test_bbox.c: Add another cubic outline with exact BBox.
1028 (REPEAT): Increase the number of benchmarking cycles.
1029 (profile_outline): Tweak output formatting.
1031 2013-02-02 Werner Lemberg <wl@gnu.org>
1033 Fix Savannah bug #38235.
1035 * builds/unix/configure.raw: Don't generate `freetype-config' and
1038 * builds/unix/unix-def.in (FT2_EXTRA_LIBS, LIBBZ2, LIBZ,
1039 build_libtool_libs, ft_version): New variables to be substituted.
1040 (freetype-config, freetype.pc): New rules to generate those files.
1042 * builds/unix/freetype-config.in: Remove code for handling `rpath'.
1043 The use of $rpath has been accidentally removed in a patch from
1044 2009-12-22, and apparently noone has missed it since.
1045 Use `%' instead of `@' as a variable substitution marker.
1048 * builds/unix/freetype.in: Use `%' instead of `@' as a variable
1049 substitution marker.
1052 2013-02-07 Werner Lemberg <wl@gnu.org>
1054 * src/truetype/ttobjs.c (tt_size_run_prep): Reset more GS variables.
1056 BTW, Greg agrees that the OpenType specification is missing the list
1057 of GS variables which will always be reset to the default values
1058 after the `prep' table has been executed.
1060 2013-02-06 Werner Lemberg <wl@gnu.org>
1062 * src/truetype/ttobjs.c (tt_size_run_prep): Reset reference points.
1064 Up to now, we simply took a snapshot of the Graphics State after the
1065 `prep' table has been executed, and right before a glyph's bytecode
1066 was run it got reloaded. However, as Greg Hitchcock has told us in
1067 private communication, reference points get reset to zero in the MS
1068 rasterizer and we follow in due course. While reasonable, this is
1069 undocumented behaviour.
1071 Most notably, this fixes the rendering of Arial's `x' glyph in
1072 subpixel hinting mode.
1074 2013-02-05 Werner Lemberg <wl@gnu.org>
1076 [truetype] A better fix for Savannah bug #38211.
1078 * src/truetype/ttinterp.c (Ins_IP): Implement identical behaviour to
1079 MS rasterizer if rp1 == rp2 (confirmed by Greg Hitchcock).
1081 2013-02-01 Alexei Podtelezhnikov <apodtele@gmail.com>
1083 [pcf] Streamline parsing of PCF encoding table.
1085 * src/pcf/pcfread.c (pcf_get_encodings): Use simpler double for-loop.
1086 Reallocate array instead of using temporary storage.
1088 2013-02-01 Werner Lemberg <wl@gnu.org>
1090 Fix Savannah bug #38227.
1092 * builds/unix/freetype-config.in: Set LC_ALL.
1094 2013-02-01 Werner Lemberg <wl@gnu.org>
1096 Fix Savannah bug #38221.
1098 This complements commit 83c0ebab.
1100 * src/base/ftcalc.c (FT_MulDiv_No_Round): Don't enclose with
1101 `TT_USE_BYTECODE_INTERPRETER'.
1103 2013-02-01 Werner Lemberg <wl@gnu.org>
1105 [truetype] Fix Savannah bug #38211.
1107 * src/truetype/ttinterp.c (Ins_IP): Make FreeType behave identical
1108 to other interpreters if rp1 == rp2 (which is invalid).
1110 2013-01-28 Alexei Podtelezhnikov <apodtele@gmail.com>
1112 [base] Small optimization of BBox calculation.
1114 * src/base/ftbbox.c (BBox_Cubic_Check): Use FT_MSB function in
1117 2013-01-26 Infinality <infinality@infinality.net>
1119 [truetype] Minor formatting fix.
1121 * src/truetype/ttinterp.c: Updated.
1122 (DO_RS): Fix indentation.
1124 2013-01-26 Infinality <infinality@infinality.net>
1126 [truetype] Fix rasterizer_version logic in sph.
1128 * src/truetype/ttsubpix.c: Updated.
1129 (ALWAYS_SKIP_DELTAP_Rules): Remove rule for Trebuchet MS.
1130 (sph_set_tweaks): Fix `rasterizer_version' logic.
1132 2013-01-26 Infinality <infinality@infinality.net>
1134 [truetype] Align more to ClearType whitepaper for sph.
1136 * include/freetype/internal/tttypes.h (TT_FaceRec): Add flags
1137 for detected opcode patterns and compatibility mode.
1139 * src/truetype/ttgload.c (tt_loader_init): Complete conditional.
1141 * src/truetype/ttinterp.c: Updated.
1142 Remove SPH_DEBUG and replace with FT_TRACE7.
1143 (DO_RS): More conditions.
1144 (Ins_FDEF): Add more opcode detection patterns.
1145 More specific conditions when flagging an fdef.
1146 Make compatibility mode only turn on when delta fdefs are found.
1147 (Ins_CALL, Ins_LOOPCALL): Set flags for currently executed fdef.
1148 (Ins_SHPIX): Remove logic to handle ttfautohinted fonts.
1149 Simplify conditionals where possible.
1150 Use `&' instead of `%' operator for dumb compilers.
1151 (Ins_MIAP): Adjust twilight zone conditional.
1152 Ensure `ignore_x_mode' is on when testing sph conditionals.
1153 (Ins_MIRP): Ensure `ignore_x_mode' is on when testing sph
1155 Do cvt cutin always when `ignore_x_mode' is active.
1156 Remove test for ttfautohinted fonts.
1157 (Ins_DELTAP): Ensure `ignore_x_mode' is on when testing sph
1159 Do cvt cutin always when `ignore_x_mode' is active.
1160 Remove test for ttfautohinted fonts.
1161 Use `&' instead of `%' operator for dumb compilers.
1162 (Ins_GETINFO): Remove SPH_DEBUG and replace with FT_TRACE7.
1164 * src/truetype/ttinterp.h: Updated.
1165 (TT_ExecContextRec): Remove compatibility_mode variable.
1166 Add variable to indicate when executing in special fdefs for sph.
1168 * src/truetype/ttobjs.h: Updated.
1169 (TT_DefRecord): Add flags to identify special fdefs for sph.
1170 (TT_SizeRec): Remove unnecessary ttfautohinted variable.
1172 * src/truetype/ttsubpix.c: Updated.
1173 (COMPATIBILITY_MODE_Rules): Remove all. Auto-detected now.
1174 (PIXEL_HINTING_Rules): Remove all. Unnecessary after fixes.
1175 (SKIP_NONPIXEL_Y_MOVES_Rules): Remove Ubuntu.
1176 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Arial Bold `N'.
1177 (SKIP_OFFPIXEL_Y_MOVES_Rules): Remove all. Happens automatically
1179 (ROUND_NONPIXEL_Y_MOVES_Rules): Remove Ubuntu.
1180 (ROUND_NONPIXEL_Y_MOVES_Rules_Exceptions): Remove all.
1181 (NORMAL_ROUND_Rules): Remove Verdana.
1182 (NO_DELTAP_AFTER_IUP_Rules): Remove all.
1183 (sph_set_tweaks): Performance fix. Don't run prep always.
1184 Adjust conditional for sph_compatibility_mode.
1186 * src/truetype/ttsubpix.h: Add new fdef flags for sph.
1188 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
1190 [base] Fix broken emboldening at small sizes.
1192 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Do not attempt to
1193 normalize zero-length vectors.
1195 2013-01-25 Werner Lemberg <wl@gnu.org>
1197 Fix Savannah bug #38167.
1199 This fixes commit 83c0ebab from 2012-06-27.
1201 * src/truetype/ttinterp.h:
1202 s/TT_CONFIG_OPTION_BYTECODE_INTERPRETER/TT_USE_BYTECODE_INTERPRETER/.
1204 2013-01-25 Xi Wang <xi.wang@gmail.com>
1206 [sfnt] Fix broken pointer overflow checks.
1208 Many compilers such as gcc and clang optimize away pointer overflow
1209 checks `p + n < p', because pointer overflow is undefined behavior.
1210 Use a safe form `n > p_limit - p' instead.
1212 Also avoid possible integer overflow issues, for example, using
1213 `num_glyphs > ( p_limit - p ) / 2' rather than `num_glyphs * 2'
1214 given a large `num_glyphs'.
1216 * src/sfnt/ttsbit0.c (tt_sbit_decoder_load_image): Implement it.
1218 2013-01-25 Werner Lemberg <wl@gnu.org>
1220 [base] Fix `make multi'.
1222 * src/base/ftoutln.c, src/base/fttrigon.c: Include
1225 2013-01-25 David 'Digit' Turner <digit@google.com>
1227 [truetype] Fix C++ compilation.
1229 * src/truetype/ttsubpix.h: Updated.
1230 (SPH_X_SCALING_RULES_SIZE): Moved and renamed to...
1231 * src/truetype/ttsubpix.c (X_SCALING_RULES_SIZE): This.
1232 (sph_X_SCALING_Rules): Removed.
1233 (scale_test_tweak): Make function static.
1234 (sph_test_tweak_x_scaling): New function.
1236 * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Updated.
1238 2013-01-23 Werner Lemberg <wl@gnu.org>
1240 [base] Make `FT_Hypot' really internal.
1242 * include/freetype/fttrigon.h (FT_Hypot): Move to...
1243 * include/freetype/internal/ftcalc.h: This file.
1245 * src/base/fttrigon.c (FT_Hypot): Move to...
1246 * src/base/ftcalc.c: This file.
1247 Include FT_TRIGONOMETRY_H.
1249 * src/truetype/ttgload.c: Don't include FT_TRIGONOMETRY_H.
1251 2013-01-23 Werner Lemberg <wl@gnu.org>
1253 [truetype] Revert change from 2013-01-22.
1255 FreeType's `height' value is the baseline-to-baseline distance...
1257 * src/truetype/ttobjs.c (tt_size_reset): Undo.
1259 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
1261 [base, truetype] New internal `FT_Hypot' function.
1263 * include/freetype/fttrigon.h (FT_Hypot): Declare it.
1264 * src/base/fttrigon.c (FT_Hypot): Define it.
1265 * src/truetype/ttgload.c (TT_Process_Composite_Component): Use it
1266 instead of explicit expressions.
1267 * src/truetype/ttinterp.c (Current_Ratio, Normalize): Use it instead
1269 (TT_VecLen): Removed.
1271 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
1273 [base] Fix integer overflow.
1275 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Normalize incoming and
1276 outgoing vectors and use fixed point arithmetic.
1278 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
1280 [base] Fix integer overflow.
1282 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Scale the
1283 coordinates down to avoid overflow.
1285 2013-01-23 Alexei Podtelezhnikov <apodtele@gmail.com>
1287 [base] Split out MSB function.
1289 * src/base/fttrigon.c (ft_trig_prenorm): Borrow from here.
1290 * include/freetype/internal/ftcalc.h (FT_MSB): Declare here.
1291 * src/base/ftcalc.c (FT_MSB): Define here.
1293 2013-01-22 Werner Lemberg <wl@gnu.org>
1295 [truetype] Fix font height.
1297 * src/truetype/ttobjs.c (tt_size_reset): The Windows rendering
1298 engine uses rounded values of the ascender and descender to compute
1299 the TrueType font height.
1301 2013-01-16 Behdad Esfahbod <behdad@behdad.org>
1303 [sfnt] Fix optimized sbit loader.
1305 It was not taking bit_depth into consideration when blitting!
1307 * src/sfnt/ttsbit0.c (tt_sbit_decoder_load_byte_aligned,
1308 * tt_sbit_decoder_load_bit_aligned): Handle bit
1311 2013-01-16 David 'Digit' Turner <digit@google.com>
1313 [truetype] Improve sub-pixel code.
1315 This patches fixes many issues with the ttsubpix implementation.
1317 1. Data tables are defined, instead of declared, in the header, and
1318 thus copied into each source file that includes it.
1320 2. These tables were defined as global, mutable, visible variables,
1321 and thus costing private RAM to every process that loads the
1322 library (> 50 KB / process, this is huge!).
1324 Additionally, this also made the library export the symbols
1325 completely needlessly.
1327 3. Missing `sph_' and `SPH_' prefixes to some of the definitions.
1329 Note that this doesn't try to fix the incredibly inefficient storage
1330 format for the data tables used by the code. This one will require
1331 another pass in the future.
1333 * src/truetype/ttinterp.h (MAX_NAME_SIZE, MAX_CLASS_MEMBERS):
1335 (SPH_MAX_NAME_SIZE, SPH_MAX_CLASS_MEMBERS): This.
1338 (SPH_TweakRule, SPH_ScaleRule): Decorate with `const' where
1341 (Font_Class): Rename to...
1342 (SPH_Font_Class): This. Decorate with `const' where appropriate.
1344 * src/truetype/ttsubpix.h (scale_test_tweak, sph_test_tweak):
1345 Decorate arguments with `const' where appropriate.
1347 Move font tweaking tables to...
1349 * src/truetype/ttsubpic.c: This file and decorate them with `static'
1350 and `const' where appropriate.
1352 (X_SCALING_Rules, X_SCALING_RULES_SIZE): Renamed to...
1353 (spu_X_SCALING_Rules, SPH_X_SCALING_RULES_SIZE): This.
1356 2013-01-12 Alexei Podtelezhnikov <apodtele@gmail.com>
1358 [truetype] Improve accuracy of normalization of short vectors.
1360 Unit vector components are stored as 2.14 fixed-point numbers. In
1361 order to calculate all 14 bits accurately, a short vector to be
1362 normalized has to be upscaled to at least 14 bits before its length
1363 is calculated. This has been safe since accurate CORDIC algorithms
1366 * src/truetype/ttinterp.c (Normalize): Scale short vectors by 0x4000.
1368 2013-01-12 Alexei Podtelezhnikov <apodtele@gmail.com>
1370 [truetype] Kill very old vector normalization hacks.
1372 Back in the days, vector length calculations were not very accurate
1373 and the vector normalization function, Normalize, had to meticulously
1374 correct the errors for long vectors [commit b7ef2b096867]. It was no
1375 longer necessary after accurate CORDIC algorithms were adopted, but
1376 the code remained. It is time to kill it.
1378 * src/truetype/ttinterp.c (Normalize): Remove error compensation.
1379 (TT_VecLen): Remove any mention of old less accurate implementation.
1381 2013-01-11 Werner Lemberg <wl@gnu.org>
1383 Disable FT_CONFIG_OPTION_OLD_INTERNALS.
1385 After the next release we are going to remove the code completely.
1387 * devel/ftoption.h, include/freetype/config/ftoption.h
1388 (FT_CONFIG_OPTION_OLD_INTERNALS): Comment out.
1389 * docs/CHANGES: Document it.
1391 2013-01-10 Alexei Podtelezhnikov <apodtele@gmail.com>
1393 [base] Update the overflow protection bit.
1395 The recent optimizations of CORDIC iterations drastically reduce the
1396 expansion factor. Vector components with MSB of 29 are now safe
1399 * src/base/fttrigon.c (FT_TRIG_SAFE_MSB): New macro.
1400 (ft_trig_prenorm): Use it and remove dead code.
1402 2013-01-09 Alexei Podtelezhnikov <apodtele@gmail.com>
1404 [base, pshinter] Use FT_ABS, FT_MIN, and FT_MAX for readability.
1406 * src/base/ftbbox.c: Updated.
1407 * src/base/ftobjs.c: Updated.
1408 * src/base/fttrigon.c: Updated.
1409 * src/pshinter/pshalgo.c: Updated.
1410 * src/pshinter/pshrec.c: Updated.
1412 2013-01-08 Alexei Podtelezhnikov <apodtele@gmail.com>
1414 [base] Clean up trigonometric core.
1416 * src/base/fttrigon.c: Document the algorithm in a large comment.
1417 (FT_TRIG_COSCALE): Remove macro.
1418 (FT_Tan: Use `FT_TRIG_SCALE' instead.
1419 (FT_Cos, FT_Vector_Unit): Ditto and round the return values.
1421 2013-01-02 Alexei Podtelezhnikov <apodtele@gmail.com>
1423 [base] Use rounding in CORDIC iterations.
1425 * src/base/fttrigon.c (ft_trig_pseudo_rotate,
1426 ft_trig_pseudo_polarize): Improve accuracy by rounding.
1428 2013-01-02 Alexei Podtelezhnikov <apodtele@gmail.com>
1430 [base] Reduce trigonometric algorithms.
1432 After we get within 45 degrees by means of true 90-degree rotations,
1433 we can remove initial 45-degree CORDIC iteration and start from
1434 atan(1/2) pseudorotation, reducing expansion factor thereby.
1436 * src/base/fttrigon.c (FT_TRIG_SCALE, FT_TRIG_COSCALE): Update macros.
1437 (ft_trig_pseudo_rotate, ft_trig_pseudo_polarize): Update.
1439 * src/tools/cordic.py: Bring up to date with trigonometric core.
1441 * docs/CHANGES: Old typo.
1443 2013-01-02 Alexei Podtelezhnikov <apodtele@gmail.com>
1445 * src/pshinter/pshalgo.h: Remove unused code.
1447 2012-12-27 Werner Lemberg <wl@gnu.org>
1449 * src/truetype/ttgload.c (tt_loader_init): Add more tracing.
1451 2012-12-23 Werner Lemberg <wl@gnu.org>
1453 [type1] Fix handling of /FontBBox in MM fonts.
1454 Problem reported by Del Merritt <del@alum.mit.edu>
1458 /FontBBox { { 11 12 13 14 15 16 17 18 }
1459 { 21 22 23 24 25 26 27 28 }
1460 { 31 32 33 34 35 36 37 38 }
1461 { 41 42 43 44 45 46 47 48 } }
1463 in the /Blend dictionary, then the first BBox is { 11 21 31 41 },
1464 the second { 12 22 32 42 }, etc.
1466 * include/freetype/internal/psaux.h (T1_FieldType): Add
1467 `T1_FIELD_TYPE_MM_BBOX' (for temporary use).
1469 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
1472 2012-12-21 Alexei Podtelezhnikov <apodtele@gmail.com>
1474 * src/tools/cordic.py: Bring up to date with trigonometric core.
1476 2012-12-21 Werner Lemberg <wl@gnu.org>
1478 Check parameters of `FT_Outline_New'.
1479 Problem reported by Robin Watts <robin.watts@artifex.com>.
1481 * src/base/ftoutln.c (FT_Outline_New_Internal): Ensure that
1482 `numContours' and `numPoints' fit into FT_Outline's `n_points' and
1483 `n_contours', respectively.
1485 2012-12-20 Werner Lemberg <wl@gnu.org>
1487 * Version 2.4.11 released.
1488 ==========================
1491 Tag sources with `VER-2-4-11'.
1493 * docs/CHANGES, docs/release: Updated.
1495 * docs/VERSION.DLL: Update documentation and bump version number to
1498 * README, Jamfile (RefDoc),
1499 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
1500 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
1501 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
1502 builds/win32/visualc/freetype.dsp,
1503 builds/win32/visualc/freetype.vcproj,
1504 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
1505 builds/win32/visualce/freetype.vcproj,
1506 builds/win32/visualce/index.html,
1507 builds/wince/vc2005-ce/freetype.vcproj,
1508 builds/wince/vc2005-ce/index.html,
1509 builds/wince/vc2008-ce/freetype.vcproj,
1510 builds/wince/vc2008-ce/index.html: s/2.4.10/2.4.11/, s/2410/2411/.
1512 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 11.
1514 * builds/unix/configure.raw (version_info): Set to 16:0:10.
1516 * builds/toplevel.mk (dist): Don't include `.mailmap'.
1518 2012-12-20 Alexei Podtelezhnikov <apodtele@gmail.com>
1520 [base] Improve trigonometric core.
1522 FreeType used to rely on a 24-step iteration CORDIC algorithm to
1523 calculate trigonometric functions and rotate vectors. It turns out
1524 that once the vector is in the right half-plane, the initial rotation
1525 by 63 degrees is not necessary. The algorithm is perfectly capable
1526 to converge to any angle starting from the second 45 degree rotation.
1527 This patch removes the first rotation and makes it a 23-step CORDIC
1530 * src/base/fttrigon.c (FT_TRIG_SCALE, FT_TRIG_COSCALE): Update macro
1532 (ft_trig_pseudo_rotate, ft_trig_pseudo_polarize): Remove initial
1535 2012-12-19 Werner Lemberg <wl@gnu.org>
1537 * src/base/ftobjs.c (ft_property_do): Fix compiler warning.
1539 2012-12-19 Alexei Podtelezhnikov <apodtele@gmail.com>
1541 * src/base/ftrfork.c (FT_Raccess_Guess): Switch to FT_Int counters.
1543 2012-12-19 Alexei Podtelezhnikov <apodtele@gmail.com>
1545 [base] Clean up trigonometric core.
1547 * src/base/fttrrigon.c (ft_trig_pseudo_polarize): Align algorithm
1548 with `ft_trig_pseudo_rotate'.
1550 2012-12-18 Infinality <infinality@infinality.net>
1552 [truetype] Minor performance enhancement.
1554 * src/truetype/ttgload.c: (TT_Process_Simple_Glyph): Use FT_MulFix
1555 instead of FT_MulDiv.
1557 2012-12-17 Infinality <infinality@infinality.net>
1559 [truetype] Remove unusued code and variables.
1561 * src/truetype/ttinterp.c: Updated.
1562 (Ins_FDEF): Remove opcode patterns that are not being used.
1564 2012-12-16 Werner Lemberg <wl@gnu.org>
1566 Various compiler warning fixes.
1568 * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Use
1569 `logical not' operator instead of negation. The idea is that `~'
1570 returns exactly the data type enforced by the cast to a pointer (be
1571 it 32bit or 64bit or whatever), while a negative integer has not
1573 * src/cache/ftccmap.c (FTC_CMAP_UNKNOWN): Ditto.
1574 * src/truetype/ttgxvar.c (ALL_POINTS, TT_Get_MM_Var): Ditto.
1575 * src/type/t1load.c (T1_Get_MM_Var): Ditto.
1576 (parse_blend_axis_types): Use cast.
1577 * src/bdf/bdflib.c (_bdf_readstream): Use cast.
1579 2012-12-16 Infinality <infinality@infinality.net>
1581 [truetype] Remove unusued code and variables. Add minor fixes.
1583 * src/truetype/ttsubpix.h: Updated.
1584 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Trebuchet MS.
1585 (ALLOW_X_DMOVEX_Rules): Remove Arial characters.
1586 (ALLOW_X_DMOVE_Rules): Remove Arial characters.
1587 (RASTERIZER_35_Rules): Verdana no longer needs to be here.
1588 (SKIP_IUP_Rules): Formatting fix.
1589 (DELTAP_SKIP_EXAGGERATED_VALUES_Rules): Remove Segoe UI.
1590 (COMPATIBLE_WIDTHS_Rules): Add Monaco and Trebuchet MS.
1591 (X_SCALING_Rules): Add misc. corrective fixes.
1593 * src/truetype/ttgload.c: (TT_Process_Simple_Glyph): Adjust correction
1594 factor for emboldening during scaling.
1596 * src/truetype/ttinterp.h: Updated.
1597 (TT_ExecContextRec): Remove unused variables.
1599 * src/truetype/ttobjs.h: Updated.
1600 (TT_SizeRec): Add ttfautohinted variable.
1602 * src/truetype/ttinterp.c: Updated.
1603 (Ins_FDEF): Rework code to fix bugs and add more detection.
1604 (Ins_CALL): Remove unused code.
1605 (Ins_LOOPCALL): Remove unused code.
1606 (TT_RunIns): Remove unusued code.
1607 (Ins_SHPIX): Add logic to handle ttfautohinted fonts.
1608 (Ins_MIRP): Don't round x in cut-in calculation. Add logic to handle
1609 ttfautohinted fonts.
1611 2012-12-16 Werner Lemberg <wl@gnu.org>
1613 [sfnt] Fix Savannah bug #37936.
1615 * src/sfnt/ttload.c (tt_face_load_gasp): Avoid memory leak.
1617 2012-12-15 Alexei Podtelezhnikov <apodtele@gmail.com>
1619 [base] Fix 11-year old bug.
1621 Since the initial commit (ebe85f59) the value of FT_TRIG_SCALE has
1622 always been slightly less than the correct value, which has been
1623 given in the comment as a hexadecimal. As a result, vector lengths
1624 were underestimated and rotated vectors were shortened.
1626 * src/base/fttrigon.c (FT_TRIG_SCALE): Fix macro value.
1628 2012-12-15 Werner Lemberg <wl@gnu.org>
1630 [bdf] Fix Savannah bug #37907.
1632 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Normalize
1633 negative second parameter of `ENCODING' field also.
1635 2012-12-15 Werner Lemberg <wl@gnu.org>
1637 [bdf] Fix Savannah bug #37906.
1639 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Use correct array
1640 size for checking `glyph_enc'.
1642 2012-12-15 Werner Lemberg <wl@gnu.org>
1644 [bdf] Fix Savannah bug #37905.
1646 * src/bdf/bdflib.c (_bdf_parse_start) <STARTPROPERTIES>: Reset
1647 `props_size' to zero in case of allocation error; this value gets
1648 used in a loop in `bdf_free_font'.
1650 2012-12-10 Alexei Podtelezhnikov <apodtele@gmail.com>
1652 [truetype] Scale F_dot_P down.
1654 The dot product between freeVector and projVector or cosine of
1655 the angle between these FT_F2Dot14 unit vectors used to be scaled up
1656 by 4 and routinely occupied 32 bits in an FT_Long field F_dot_P.
1657 This patch scales the value down by 2^14 instead, which simplifies
1658 its use throughout the bytecode interpreter.
1660 This does not lead to the loss of precision because the lower bits
1661 are unreliable anyway. Consider two unit vectors (1,0) and (.6,.8)
1662 for which the true value of F_dot_P is .6 * 0x40000000 = 0x26666666.
1663 These vectors are stored as (0x4000,0) and (0x2666,0x3333) after
1664 rounding and F_dot_P is assigned 0x26660000. The lower bits were
1665 already lost while rounding the unit vector components.
1667 Besides code simplification, this change can lead to better
1668 performance when FT_MulDiv with the scaled-down F_dot_P is less
1669 likely to use the costly 64-bit path. We are not changing the type
1670 of F_dot_P to FT_F2Dot14 at this point.
1672 * src/truetype/ttinterp.c (Compute_Funcs): Scale F_dot_P down by 14
1673 bits and modify its use accordingly.
1674 (Direct_Move, Direct_Move_Orig, Compute_Point_Displacement): Modify
1675 the use of F_dot_P field.
1676 * src/truetype/ttobjs.c (tt_size_run_fpgm): Change arbitrary
1677 assignment of F_dot_P to its theoretical maximum in case we decide
1678 to scale back its type later.
1680 2012-12-09 Johnson Y. Yan <yinsen_yan@foxitsoftware.com>
1682 [type1] Another fix for 2012-09-17 commit.
1684 * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Correctly set
1687 2012-12-06 Alexei Podtelezhnikov <apodtele@gmail.com>
1689 [truetype] Tweak the previous commit.
1691 * src/truetype/ttinterp.c (Current_Ratio): Put unit vector
1692 components as the second TT_MulFix14 arguments. This is required
1695 2012-12-06 Alexei Podtelezhnikov <apodtele@gmail.com>
1697 [truetype] Microoptimizations in bytecode interpreter.
1699 * src/truetype/ttinterp.c (TT_DivFix14): New macro.
1700 (Normalize): Use it here.
1701 (Current_Ratio): Use TT_MulFix14 instead of FT_MulDiv.
1702 (Ins_SHPIX): Cancel out two TT_MulFix14 calls.
1704 2012-12-05 Alexei Podtelezhnikov <apodtele@gmail.com>
1706 [truetype] Cosmetic improvement in bytecode interpreter.
1708 * src/truetype/ttinterp.c: Use explicit calls to FT_MulDiv,
1709 FT_MulFix, and FT_DivFix instead of macros.
1711 2012-12-03 John Tytgat <John.Tytgat@esko.com>
1713 [pshinter] Clamp BlueScale value.
1715 This is Savannah bug #37856.
1717 * src/pshinter/pshglob.c (psh_calc_max_height): New function.
1718 (psh_globals_new): Use it to limit BlueScale value to
1719 `1 / max_of_blue_zone_heights'.
1721 2012-12-01 Alexei Podtelezhnikov <apodtele@gmail.com>
1723 [truetype, type1] Revise the use of FT_MulDiv.
1725 * src/truetype/ttgxvar.c: Updated.
1726 * src/truetype/ttobjs.c: Updated.
1727 * src/type1/t1load.c: Updated.
1729 2012-11-30 Werner Lemberg <wl@gnu.org>
1731 [configure] Preserve customized `ftoption.h'.
1733 Problem reported by Del Merritt <del@alum.mit.edu>.
1735 * builds/unix/configure.raw <cpp computation of bit length>: Don't
1736 remove existing FreeType configuration files.
1738 2012-11-29 John Tytgat <John.Tytgat@esko.com>
1740 [type1] Fix Savannah bug #37831.
1742 The bug report also contains a patch.
1744 * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Really fix
1745 change from 2012-09-17.
1747 2012-11-28 Alexei Podtelezhnikov <apodtele@gmail.com>
1749 [truetype] Fix formatting and typo.
1751 2012-11-27 Alexei Podtelezhnikov <apodtele@gmail.com>
1753 [cid, type1, type42] Clean up units_per_EM calculations.
1755 * src/cid/cidload.c (cid_parse_font_matrix): Updated.
1756 * src/type1/t1load.c (t1_parse_font_matrix): Updated.
1757 * src/type42/t42parse.c (t42_parse_font_matrix): Updated.
1759 2012-11-27 Alexei Podtelezhnikov <apodtele@gmail.com>
1761 [ftstroke] Minor improvement.
1763 * src/base/ftstroke.c: Replace nested FT_DivFix and FT_MulFix with
1766 2012-11-17 Werner Lemberg <wl@gnu.org>
1768 * src/base/fttrigon.c (ft_trig_downscale): Make 64bit version work.
1770 2012-11-15 Alexei Podtelezhnikov <apodtele@gmail.com>
1772 [base] Fix integer overflows in dd5718c7d67a.
1774 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Use FT_MulDiv.
1776 2012-11-15 Werner Lemberg <wl@gnu.org>
1778 [autofit] Trace stem widths.
1780 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Add some
1783 2012-11-13 Werner Lemberg <wl@gnu.org>
1785 [cff] Add support for OpenType Collections (OTC).
1787 * src/cff/cffload.c (cff_font_load): Separate subfont and face
1788 index handling to load both pure CFFs with multiple subfonts and
1789 OTCs (with multiple faces where each face holds exactly one
1791 * src/cff/cffobjs.c (cff_face_init): Updated.
1793 2012-11-12 Werner Lemberg <wl@gnu.org>
1795 [autofit] Minor improvement.
1797 * src/autofit/aflatin.c (af_latin_hints_compute_blue_edges): Fix
1800 2012-11-10 Werner Lemberg <wl@gnu.org>
1802 [autofit] Improve tracing.
1804 * src/autofit/aflatin.c (af_latin_hint_edges)
1805 [FT_DEBUG_LEVEL_TRACE]: Count number of actions and emit something
1806 if there weren't any.
1808 2012-11-04 Alexei Podtelezhnikov <apodtele@gmail.com>
1810 [base] Fortify emboldening code against egregious distortions.
1812 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Threshold emboldening
1813 strength when it leads to segment collapse.
1815 2012-11-03 Alexei Podtelezhnikov <apodtele@gmail.com>
1817 [base] Clean up emboldening code and improve comments there.
1819 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Replace sequential
1820 calls to FT_MulFix and FT_DivFix with FT_MulDiv.
1821 Mention that bisectors are used to figure out the shift direction.
1823 2012-10-24 Werner Lemberg <wl@gnu.org>
1825 [autofit] Add standard character to `AF_ScriptClassRec' structure.
1827 * src/autofit/aftypes.h (AF_ScriptClassRec): Add `standard_char'
1829 (AF_DEFINE_SCRIPT_CLASS): Updated.
1831 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Use it.
1832 (af_latin_metrics_init, af_latin_script_class): Updated.
1834 * src/autofit/aflatin.c (af_latin2_metrics_init_widths): Use it.
1835 (af_latin2_metrics_init, af_latin2_script_class): Updated.
1837 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Use it.
1838 (af_cjk_metrics_init, af_cjk_script_class): Updated.
1840 * src/autofit/afindic.c (af_indic_metrics_init,
1841 af_indic_script_class): Updated.
1843 * src/autofit/afcjk.h, src/autofit/aflatin.h: Updated.
1845 * src/autofit/afdummy.c: Updated.
1847 2012-10-24 Werner Lemberg <wl@gnu.org>
1849 [autofit] Only use Unicode CMap.
1851 * src/autofit/aflatin.c (af_latin_metrics_init): Implement it, to be
1852 in sync with `af_face_globals_compute_script_coverage'.
1854 2012-10-21 Werner Lemberg <wl@gnu.org>
1856 [psaux] Improve parsing of invalid numbers.
1858 * src/psaux/psconv.c (PS_Conv_Strtol): Always parse complete number,
1859 even in case of overflow.
1860 (PS_Conv_ToInt): Only increase cursor if parsing was successful.
1861 (PS_Conv_ToFixed): Ditto.
1862 Trace underflow and data error.
1864 2012-10-21 Werner Lemberg <wl@gnu.org>
1866 [smooth] Improve tracing.
1868 * src/smooth/ftgrays.c (gray_sweep): Trace last sweep line of
1871 2012-10-20 Alexei Podtelezhnikov <apodtele@gmail.com>
1873 [truetype] Cheaper way to threshold angles between vectors.
1875 * src/truetype/ttinterp.c (Ins_ISECT): Thresholding tangent is a lot
1876 cheaper than thresholding sine.
1878 2012-10-20 Werner Lemberg <wl@gnu.org>
1880 [cff] Improve parsing of invalid real numbers.
1882 * src/cff/cffparse.c (cff_parse_real): Always parse complete number,
1883 even in case of overflow or underflow.
1884 Also trace one more underflow.
1886 2012-10-20 Andreas Pehnack <andreas.pehnack@me.com>
1888 [sfnt] Load pure CFF fonts wrapped in SFNT container.
1890 Such fonts only have a `cmap' and a `CFF' table.
1892 * src/sfnt/ttload.c (tt_face_load_font_dir): Don't call
1893 `check_table_dir' if font signature is `OTTO'.
1895 2012-10-20 Werner Lemberg <wl@gnu.org>
1897 [psaux] Fix some value overflows and improve tracing.
1899 * src/psaux/psconv.c: Include FT_INTERNAL_DEBUG_H.
1900 (FT_COMPONENT): Define.
1901 (PS_Conv_Strtol): Return FT_Long.
1902 Handle bad data and overflow.
1903 Emit some tracing messages in case of error.
1904 (PS_Conv_ToInt): Return FT_Long.
1905 (PS_Conv_ToFixed): Updated.
1906 * src/psaux/psconv.h: Updated.
1908 * include/freetype/internal/fttrace.h: Add `psconv'.
1910 2012-10-20 Werner Lemberg <wl@gnu.org>
1912 [autofit] Fix `make multi CC=c++'.
1914 * src/autofit/aflatin.c, src/autofit/aflatin2.c: Include
1916 * src/autofit/afloader.c: Fix order of header files.
1917 * src/autofit/afmodule.c: Include `afglobal.h' and `aferrors.h'.
1919 2012-10-19 Werner Lemberg <wl@gnu.org>
1921 [cff] Fix more value errors and improve tracing.
1923 * src/cff/cffparse.c (cff_parse_integer): Emit tracing message in
1925 (cff_parse_real): Handle and trace overflow, underflow, and bad data
1927 (do_fixed): New helper function, handling and tracing overflow.
1928 (cff_parse_fixed, cff_parse_fixed_scaled): Use `do_fixed'.
1930 2012-10-17 Werner Lemberg <wl@gnu.org>
1932 [psaux] Fix some value overflows.
1934 * src/psaux/psconv.c (PS_Conv_ToFixed): Implement it.
1936 2012-10-17 Bram Tassyns <BramT@enfocus.com>
1938 [cff] Fix value overflow.
1940 * src/cff/cffparse.c (cff_parse_fixed_scaled): Implement it.
1942 2012-10-17 Werner Lemberg <wl@gnu.org>
1944 [truetype] Fix Savannah bug #37572.
1946 * src/truetype/ttinterp.c (Ins_ISECT): Use angle between vectors to
1947 avoid grazing intersections. The previous threshold was too coarse,
1948 incorrectly rejecting short but valid vectors.
1950 2012-09-30 Gilles Espinasse <g.esp@free.fr>
1952 Remove useless `rm' detection.
1954 `rm -f' is directly used in the `configure' script created by
1955 autoconf, thus no availability test is necessary.
1957 * builds/unix/configure.raw (RMF): Remove test.
1958 * builds/unix/unix-def.in (DELETE): Updated.
1960 2012-09-29 Werner Lemberg <wl@gnu.org>
1962 [autofit] Minor optimization.
1964 * src/autofit/afglobals.c (af_face_globals_compute_script_coverage):
1967 2012-09-29 Werner Lemberg <wl@gnu.org>
1969 [autofit] Fix thinko.
1971 * src/autofit/aftypes.h (AF_SCRIPT):
1972 s/AF_SCRIPT_NONE/AF_SCRIPT_DUMMY/. We already use `AF_SCRIPT_NONE'
1975 * src/autofit/afdummy.c: Updated.
1977 2012-09-18 Werner Lemberg <wl@gnu.org>
1979 [autofit] Implement `increase-x-height' property.
1981 * include/freetype/ftautoh.h (FT_Prop_IncreaseXHeight): New
1984 * include/autofit/afmodule.c (af_property_get_face_globals): New
1985 function, re-using code from `af_property_get'.
1986 (af_property_set, af_property_get): Handle `increase-x-height'.
1989 2012-09-18 Werner Lemberg <wl@gnu.org>
1991 [autofit] Implement Infinality's `increase glyph heights'.
1993 This is an improved version of a similar fix contained in the
1994 so-called `Infinality patch', taken from
1996 http://www.infinality.net/fedora/linux/zips/freetype-infinality-2.4.10-20120616_01-x86_64.tar.bz2
1998 which addresses various enhancements of the auto-hinter. Without
1999 properties to control a module's metadata it wasn't possible to
2000 adapt the patches because everything was originally controlled by
2001 environment variables which I consider not suitable in general.
2003 A patch to control `increase_x_height' follows.
2005 * src/autofit/afglobal.h (AF_PROP_INCREASE_X_HEIGHT_MIN,
2006 AF_PROP_INCREASE_X_HEIGHT_MAX): New macros.
2007 (AF_FaceGlobalsRec): Add `increase_x_height' member.
2008 * src/autofit/afglobal.c (af_face_globals_new): Initialize it.
2010 * src/autofit/aflatin.c (af_latin_metrics_scale_dim),
2011 * src/autofit/aflatin2.c (af_latin2_metrics_scale_dim): Implement
2012 handling of `increase_x_height'.
2014 2012-09-18 Werner Lemberg <wl@gnu.org>
2016 [autofit] Add hierarchical property access to some structures.
2018 * src/autofit/afglobal.h: Include `afmodule.h'.
2019 (AF_FaceGlobalsRec): Add `module' member.
2020 (AF_FaceGlobals): Typedef moved to...
2021 * src/autofit/aftypes.h: Here.
2022 (AF_ScriptMetricsRec): Add `globals' member.
2024 * src/autofit/afglobal.c (af_face_globals_new,
2025 af_face_globals_compute_script_coverage,
2026 af_face_globals_get_metrics): Updated.
2028 * src/autofit/afloader.c (af_loader_reset), src/autofit/afmodule.c
2029 (af_property_get): Updated.
2031 2012-09-17 Werner Lemberg <wl@gnu.org>
2033 [type1] Fix Savannah bug #37350.
2035 * src/type1/t1parse.c (T1_Get_Private_Dict) <found>: Check for ASCII
2036 storage only if we actually have at least four bytes.
2038 2012-09-15 Werner Lemberg <wl@gnu.org>
2040 [autofit] Implement `fallback-script' property.
2042 * src/autofit/afglobal.c: s/default_script/fallback_script/.
2043 * src/autofit/afglobal.h: s/AF_SCRIPT_DEFAULT/AF_SCRIPT_FALLBACK/.
2045 * src/autofit/afmodule.c: s/default_script/fallback_script/.
2046 (af_property_set, af_property_get): Implement `fallback-script'.
2047 * src/autofit/afmodule.h: s/default_script/fallback_script/.
2049 * include/freetype/ftautoh.h: Document it.
2051 2012-09-15 Werner Lemberg <wl@gnu.org>
2053 [autofit] Correct previous Unicode 6.1.0 change.
2055 The auto-hinter's latin module only handles latin ligatures in the
2056 `Alphabetical Presentation Forms' block.
2058 * src/autofit/aflatin.c (af_latin_uniranges): Fix it.
2060 2012-09-15 Werner Lemberg <wl@gnu.org>
2062 * src/autofit/afmodule.c: s/FT_Err_/AF_Err_/.
2064 2012-09-15 Werner Lemberg <wl@gnu.org>
2066 [autofit] Make default script a global property.
2068 * src/autofit/afmodule.h (AF_ModuleRec): Add `default_script' field.
2070 * src/autofit/afglobal.c (af_face_globals_compute_script_coverage,
2071 af_face_globals_new), src/autofit/afloader.c (af_loader_reset),
2072 src/autofit/afmodule.c (af_property_get) <glyph-to-script-map>,
2074 Handle default script.
2076 * src/autofit/afglobal.h: Updated.
2078 2012-09-15 Werner Lemberg <wl@gnu.org>
2080 Use `FT_Module' instead of `FT_Library' argument in property funcs.
2082 This internal change simplifies access to global module data.
2084 * include/freetype/internal/services/svprop.h
2085 (FT_Properties_SetFunc, FT_Properties_GetFunc): Change accordingly.
2087 * src/base/ftobjs.c (ft_property_do), src/autofit/afmodule.c
2088 (af_property_set, af_property_get): Updated.
2090 2012-09-14 Werner Lemberg <wl@gnu.org>
2092 [autofit] Update to Unicode 6.1.0.
2094 * src/autofit/afcjk.c (af_cjk_uniranges), src/autofit/aflatin.c
2095 (af_latin_uniranges): Add and fix ranges.
2097 2012-09-14 Werner Lemberg <wl@gnu.org>
2099 [autofit] Pass `AF_Module' instead of `AF_Loader'.
2101 We want to access the (not yet existing) module's global data later
2104 * src/autofit/afloader.c: Include `afmodule.h'.
2105 (af_loader_init, af_loader_reset, af_loader_done,
2106 af_loader_load_glyph): Change accordingly.
2107 * src/autofit/afmodule.c (AF_ModuleRec): Move to `afmodule.h'.
2110 * src/autofit/afmodule.h: Include `afloader.h'.
2111 (AF_ModuleRec): Define here.
2112 * src/autofit/afloader.h (AF_Module): Define here.
2115 2012-09-14 Werner Lemberg <wl@gnu.org>
2117 [autofit] Fix `make multi'.
2119 * include/freetype/internal/fttrace.h: Add `afmodule'.
2120 * src/autofit/afmodule.c: Include FT_INTERNAL_DEBUG_H.
2121 (FT_COMPONENT): Define.
2123 2012-09-14 Werner Lemberg <wl@gnu.org>
2125 * src/autofit/afmodule.c: s/FT_Autofitter/AF_Module/.
2127 2012-09-12 Werner Lemberg <wl@gnu.org>
2129 [autofit] Minor reorganization.
2131 * src/autofit/afglobal.c (AF_SCRIPT_LIST_DEFAULT,
2132 AF_SCRIPT_LIST_NONE, AF_DIGIT): Move to...
2133 * src/autofit/afglobal.h (AF_SCRIPT_DEFAULT, AF_SCRIPT_LIST_NONE,
2134 AF_DIGIT): This and update code.
2136 2012-09-01 Werner Lemberg <wl@gnu.org>
2138 [autofit] Implement `glyph-to-script-map' property.
2140 * include/freetype/ftautoh.h: New public header file.
2141 * include/freetype/config/ftheader.h (FT_AUTOHINTER_H): New macro.
2143 * src/autofit/afglobal.c (AF_FaceGlobalsRec): Move structure to...
2144 * src/autofit/afglobal.h: This header file.
2145 * src/autofit/afmodule.c: Include FT_AUTOHINTER_H.
2146 (af_property_get): Handle `glyph-to-script-map'.
2148 2012-08-31 Werner Lemberg <wl@gnu.org>
2150 [autofit] Implement properties service framework.
2152 No properties are added yet.
2154 * src/autofit/afmodule.c: Include FT_SERVICE_PROPERTIES_H.
2155 (af_property_set, af_property_get): New dummy functions.
2156 (af_service_properties, af_services, af_get_interface): Provide
2158 (autofit_moduleclass): Add service interface.
2160 * src/autofit/afpic.c: Add necessary forward declarations.
2161 (autofit_module_class_pic_init): Add code for service addition.
2162 (autofit_module_pic_free): Add code for service removal.
2163 * src/autofit/afpic.h (AF_SERVICES_GET, AF_SERVICE_PROPERTIES_GET):
2164 New macros which provide necessary syntactical sugar for PIC
2167 2012-08-30 Werner Lemberg <wl@gnu.org>
2169 Implement properties to control FreeType modules.
2171 * include/freetype/fterrdef.h (FT_Err_Missing_Property): New error
2173 * include/freetype/ftmodapi.h (FT_Property_Set, FT_Property_Get):
2176 * include/freetype/internal/services/svprop.h: New file.
2177 * include/freetype/internal/ftserv.h (FT_SERVICE_PROPERTIES_H): New
2180 * src/base/ftobjs.c: Include FT_SERVICE_PROPERTIES_H.
2181 (ft_property_do, FT_Property_Set, FT_Property_Get): New functions.
2183 2012-08-29 Werner Lemberg <wl@gnu.org>
2185 [docmaker] Allow `-' in tags and identifiers.
2187 * src/tools/docmaker/content.py (re_identifier),
2188 src/tools/docmaker/sources.py (re_markup_tag1, re_markup_tag2,
2189 re_crossref): Add `-' in patterns.
2191 2012-08-27 Werner Lemberg <wl@gnu.org>
2193 [FT_CONFIG_OPTION_PIC] Fix g++ 4.6.2 compiler warnings.
2195 * include/freetype/internal/ftdriver.h (FT_DEFINE_DRIVER),
2196 include/freetype/internal/ftobjs.h (FT_DEFINE_RENDERER,
2197 FT_DEFINE_MODULE), include/freetype/internal/ftserv.h
2198 (FT_DEFINE_SERVICEDESCREC1, FT_DEFINE_SERVICEDESCREC2,
2199 FT_DEFINE_SERVICEDESCREC3, FT_DEFINE_SERVICEDESCREC4,
2200 FT_DEFINE_SERVICEDESCREC5, FT_DEFINE_SERVICEDESCREC6),
2201 src/autofit/afpic.c (autofit_module_class_pic_init),
2202 src/base/basepic.c (ft_base_pic_init), src/base/ftinit.c
2203 (ft_create_default_module_classes), src/cff/cffparse.c
2204 (FT_Create_Class_cff_field_handlers), src/cff/cffpic.c
2205 (cff_driver_class_pic_init), src/pshinter/pshpic.c
2206 (pshinter_module_class_pic_init), src/psnames/pspic.c
2207 (psnames_module_class_pic_init), src/raster/rastpic.c
2208 (ft_raster1_renderer_class_pic_init), src/sfnt/sfntpic.c
2209 (sfnt_module_class_pic_init), src/sfnt/ttcmap.c
2210 (FT_Create_Class_tt_cmap_classes), src/smooth/ftspic.c
2211 (ft_smooth_renderer_class_pic_init), src/truetype/ttpic.c
2212 (tt_driver_class_pic_init): Initialize allocation variable.
2214 2012-08-27 Werner Lemberg <wl@gnu.org>
2216 [truetype] Fix compilation warning.
2218 * src/truetype/ttgload.c (IS_HINTED): Move macro to...
2219 * src/truetype/ttobjs.h: This header file.
2221 2012-08-27 Werner Lemberg <wl@gnu.org>
2223 [autofit, cff, pshinter, psnames] More renamings for orthogonality.
2225 * src/autofit/afmodule.c, src/autofit/afpic.h:
2226 s/AF_AUTOFITTER_/AF_/.
2228 * src/cff/cffdrivr.c, src/cff/cffobjs.c, src/cff/cffparse.c,
2229 src/cff/cffpic.h: s/FT_CFF_/CFF_/.
2231 * src/pshinter/pshmod.c, src/pshinter/pshpic.h:
2232 s/FT_PSHINTER_/PSHINTER_/.
2234 * src/psnames/psmodule.c, src/psnames/pspic.h:
2235 s/FT_PSCMAPS/PSCMAPS_/.
2237 2012-08-27 Werner Lemberg <wl@gnu.org>
2239 [sfnt, truetype] More renamings for orthogonality.
2241 * src/sfnt/sfdriver.c, src/sfnt/sfntpic.h, src/sfnt/ttcmap.c,
2242 src/truetype/ttdriver.c, src/truetype/ttpic.h: s/FT_SFNT_/SFNT_/,
2243 s/FT_TT_/TT_/, s/GET_CMAP_INFO_GET/CMAP_INFO_GET/.
2245 2012-08-27 Werner Lemberg <wl@gnu.org>
2247 [autofit] Some macro and variable renamings for orthogonality.
2249 * include/freetype/internal/autohint.h, src/base/ftobjs.c,
2250 src/autofit/afmodule.c, src/autofit/afpic.c, src/autofit/afpic.h:
2251 s/SERVICE/INTERFACE/, s/service/interface/, s/Service/Interface/.
2253 2012-08-26 Werner Lemberg <wl@gnu.org>
2255 Fix Savannah bug #37178.
2257 * src/base/ftobjs.c (FT_Open_Face): Initialize `error' with
2258 `FT_Err_Missing_Module' before loop to indicate `no valid drivers'.
2260 2012-08-17 Werner Lemberg <wl@gnu.org>
2262 * src/base/ftsynth.c (FT_GlyphSlot_Oblique): Fix shear angle.
2264 The old value was far too large (more than 20°). The new one
2265 corresponds to 12°, quite common in typography.
2267 2012-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
2269 [smooth] Fix Savannah bug #37017.
2271 * src/smooth/ftgrays.c (gray_render_cubic): Use a different set of
2272 checks when detecting super curvy splines to be split.
2274 2012-08-05 Werner Lemberg <wl@gnu.org>
2276 [autofit] Improve recognition of flat segments.
2278 Problem reported by Brad Dunzer <BDunzer@extensis.com>.
2280 * src/autofit/aflatin.c (af_latin_metrics_init_blues): We have
2281 a flat segment if the horizontal distance of best on-points is
2282 larger than a given threshold.
2284 2012-08-05 Werner Lemberg <wl@gnu.org>
2286 [autofit] Variable renamings.
2288 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Replace
2289 `glyph' with `outline'.
2290 s/best_first/best_contour_first/.
2291 s/best_last/best_contour_last/.
2293 2012-07-31 Werner Lemberg <wl@gnu.org>
2295 [type1] Fix Savannah bug #37000.
2297 * src/type1/t1load.c (parse_encoding): Fix order of checks.
2299 2012-07-17 Werner Lemberg <wl@gnu.org>
2301 [psaux] Fix Savannah bug #36833.
2303 * src/psaux/t1decode.c (t1operator_seac): `seac' is not a valid
2304 operator if we want metrics only.
2306 2012-07-16 Werner Lemberg <wl@gnu.org>
2308 [type1] Fix Savannah bug #36832.
2310 * src/type1/t1load.c (parse_charstrings): Reject negative number of
2313 2012-07-13 Werner Lemberg <wl@gnu.org>
2315 [type1] Fix Savannah bug #36829.
2317 * src/type1/t1load.c (parse_encoding): Check cursor position after
2318 call to T1_Skip_PS_Token.
2320 2012-07-12 Alexei Podtelezhnikov <apodtele@gmail.com>
2322 Revert the last commit 45337b07.
2324 * src/base/ftstroke.c (FT_Stroker_New): Revert the previous change.
2326 2012-07-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2328 [ftstroke] Fix uninitialized return value.
2330 * src/base/ftstroke.c (FT_Stroker_New): Return FT_Err_Ok instead.
2332 2012-07-11 Werner Lemberg <wl@gnu.org>
2334 [smooth] Avoid memory leak in case of failure.
2336 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use flags to
2337 indicate what to clean up after finishing the function, with and
2340 2012-07-09 Werner Lemberg <wl@gnu.org>
2342 Fix compilation with MSVC 5.0.
2344 Problem reported by Peter Breitenlohner and Akira Kakuto.
2346 * include/freetype/config/ftstdlib.h (ft_setjmp): Updated.
2347 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Remove cast.
2349 2012-07-09 Werner Lemberg <wl@gnu.org>
2351 [autofit] Improve debugging messages; do some code cleanup.
2353 * src/autofit/aflatin.c (af_latin_align_linked_edge,
2354 af_latin_hint_edges): Synchronize with formatting used in the
2355 ttfautohint project.
2357 2012-07-07 Gilles Espinasse <g.esp@free.fr>
2359 Fix strict-aliasing warning.
2361 * src/base/ftglyph.c (FT_Glyph_To_Bitmap): Avoid double cast.
2363 2012-07-07 Dave Thomas <dave.thomas@metaforic.com>
2365 [ARM] Fix FT_MulFix_arm.
2367 * include/freetype/config/ftconfig.h (FT_MulFix_arm) [__arm__]:
2368 Avoid ADDS instruction to clobber condition codes.
2370 2012-07-06 Werner Lemberg <wl@gnu.org>
2372 [autofit] Do some code cleanup.
2374 * src/autofit/afglobal.c (af_face_globals_new): Simplify.
2376 * src/autofit/afhints.c: Use `FT_TRACE7' instead of `printf'
2378 (FT_COMPONENT): New macro.
2379 (af_glyph_hints_done): Simplify.
2381 * include/freetype/internal/fttrace.h: Updated.
2383 2012-07-05 Werner Lemberg <wl@gnu.org>
2385 [autofit] Improve output of debugging information.
2387 * src/autofit/afhints.c (af_glyph_hints_dump_segments): Print more
2388 data; report no data.
2389 (af_glyph_hints_dump_edges): Report no data.
2391 2012-07-04 Werner Lemberg <wl@gnu.org>
2393 [autofit] Fix Savannah bug #36091.
2395 * src/autofit/aflatin.c (af_latin_metrics_init_blues),
2396 src/autofit/aflatin2.c (af_latin2_metrics_init_blues): Change the
2397 constraint for testing round vs. flat segment: Accept either a
2398 small distance or a small angle.
2400 2012-07-04 Werner Lemberg <wl@gnu.org>
2402 [autofit] Beautify blue zone tracing.
2404 * src/autofit/aflatin.c (af_latin_metrics_init_blues),
2405 src/autofit/aflatin2.c (af_latin2_metrics_init_blues): Implement it.
2407 2012-07-03 Werner Lemberg <wl@gnu.org>
2409 [autofit] Quantize stem widths.
2411 * src/autofit/afangles.c (af_sort_widths): Rename to...
2412 (af_sort_and_quantize_widths): This.
2413 Add code to avoid stem widths which are almost identical.
2414 * src/autofit/aftypes.h, src/autofit/aflatin.c, src/autofit/afcjk.c:
2417 2012-07-03 Werner Lemberg <wl@gnu.org>
2419 [autofit] Minor speed-up.
2421 * src/autofit/afangles (af_sort_pos, af_sort_widths): Don't swap
2422 elements if they are equal.
2424 2012-06-30 Gilles Espinasse <g.esp@free.fr>
2426 Fix `checking if gcc static flag -static works' test.
2428 On my linux build tree, I receive yes answer in in every package I
2429 build except freetype for this test checking if gcc static flag
2432 On freetype, no is received, unless bzip2 and zlib are disabled using
2434 ./configure --without-bzip2 --without-zlib
2436 The reason is that bzip2 and zlib tests add `-lz' and `-lbz2' to
2437 LDFLAGS and this broke static flag test.
2439 * builds/unix/configure.raw: Update CFLAGS and LDFLAGS only after
2442 2012-06-28 Infinality <infinality@infinality.net>
2444 [truetype] Fix various artifacts.
2446 Verdana was broken in the original Infinality commit. Also
2447 includes other minor fixes.
2449 * src/truetype/ttsubpix.h: Updated. Removed unused macros.
2450 (RASTERIZER_35_Rules): Add Verdana.
2451 (SKIP_NONPIXEL_Y_MOVES_Rules): Add Tahoma `s'.
2452 (MIRP_CVT_ZERO_Rules): Remove Verdana.
2453 (ALWAYS_SKIP_DELTAP_Rules): Add Russian char 0x438.
2454 (COMPATIBLE_WIDTHS_Rules): Rearrange some rules.
2455 (X_SCALING_Rules): Adjust Verdana `a' at 12 and 13 ppem.
2457 * src/truetype/ttsubpix.c: Updated.
2458 (sph_set_tweaks): Re-execute fpgm always.
2460 2012-06-28 Gilles Espinasse <g.esp@free.fr>
2462 Fix CFLAGS and LDFLAGS share configure test.
2464 * builds/unix/configure.raw: Fix typo.
2466 2012-06-28 Werner Lemberg <wl@gnu.org>
2468 [truetype] Set the `subpixel_positioned' flag unconditionally.
2470 This is how the code currently behaves.
2472 * src/truetype/ttgload.c (tt_loader_init): Do it.
2474 2012-06-27 Werner Lemberg <wl@gnu.org>
2476 Fix conditional compilation.
2478 * src/base/basepic.c: Use FT_CONFIG_OPTION_MAC_FONTS.
2480 2012-06-27 Werner Lemberg <wl@gnu.org>
2482 Fix conditional compilation.
2484 * include/freetype/internal/ftcalc.h (FT_MulDiv_No_Round): Don't
2485 enclose with `TT_USE_BYTECODE_INTERPRETER'; we now need the function
2488 * src/autofit/afcjk.h: Use AF_CONFIG_OPTION_CJK.
2490 * src/truetype/ttgload.c (tt_loader_init): Fix compiler warning.
2492 * src/truetype/ttinterp.c (Ins_MSIRP): Fix compiler warning.
2494 * src/truetype/ttinterp.h: Use
2495 TT_CONFIG_OPTION_BYTECODE_INTERPRETER.
2497 2012-06-26 Infinality <infinality@infinality.net>
2499 [truetype] Remove unused rounding functionality.
2501 The subpixel hinting patch contained the concept of an adjustable
2502 number of gridlines per pixel. This is no longer used due to x
2503 being completely ignored instead. This will return some of the
2504 code to its existing state prior to the original Infinality
2507 * include/freetype/internal/ftobjs.h (FT_PIX_FLOOR_GRID,
2508 FT_PIX_ROUND_GRID, FT_PIX_CEIL_GRID): Removed.
2510 * src/truetype/ttinterp.c: Updated.
2511 (Round_None, Round_To_Grid, Round_To_Half_Grid, Round_Down_To_Grid,
2512 Round_Up_To_Grid, Round_To_Double_Grid, Round_Super, Round_Super_45,
2513 SetSuperRound): Remove parameter to handle the number of grid lines per
2515 (SET_SuperRound, ROUND_None, CUR_Func_round): Updated.
2516 (DO_SROUND, DOS45ROUND, DO_ODD, DO_EVEN): Updated.
2517 (DO_ROUND, DO_NROUND): Updated.
2518 (Move_Zp2_Point, Ins_SHPIX, Ins_MSIRP, Ins_MDAP, Ins_MIAP,
2519 Ins_MDRP, Ins_MIRP): Perform Round_None instead of calling a modified
2520 rounding function. Remove gridlines_per_pixel. Create a local
2521 variable to store control value cutin. Simplify the conditional for
2522 ignore_x_mode. Adjust rounding calls to pass only two values.
2524 2012-06-25 Werner Lemberg <wl@gnu.org>
2526 [cff] Fix Savannah bug #36705.
2528 Handle numbers like 2.001 correctly.
2530 * src/cff/cffparse.c (cff_parse_real): Avoid negative values for
2533 2012-06-18 Infinality <infinality@infinality.net>
2535 [truetype] Support subpixel hinting.
2537 This is the large, famous `Infinality' patch to support ClearType
2538 bytecode which has been available from
2539 http://www.infinality.net/blog/ for some time, and which has been
2540 refined over the last years. While still experimental, it is now
2541 mature enough to be included directly into FreeType.
2543 Most of the code is based on the ClearType whitepaper written by
2546 http://www.microsoft.com/typography/cleartype/truetypecleartype.aspx
2548 which gives a detailed overview of the necessary changes to the
2549 Microsoft rasterizer so that older fonts are supported. However, a
2550 lot of details are still missing, and this patches provides a
2551 framework to easily handle rendering issues down to the glyph level
2554 Note that ClearType support is not completely implemented! In
2555 particular, full support for the options `compatible_widths',
2556 `symmetrical_smoothing, and `bgr' (via the GETINFO bytecode
2557 instruction) is missing.
2559 * src/truetype/ttsubpix.c: New file, providing code to handle
2560 `tweaks', this is, rules for certain glyphs in certain fonts
2561 (including wildcards) which need a special treatment.
2563 * src/truetype/ttsubpix.h: New file, holding the tweaking rules.
2565 * include/freetype/config/ftoption.h, src/devel/ftoption.h
2566 (TT_CONFIG_OPTION_SUBPIXEL_HINTING): New macro.
2568 * include/freetype/internal/ftobjs.h (FT_PIX_FLOOR_GRID,
2569 FT_PIX_ROUND_GRID, FT_PIX_CEIL_GRID): New macros.
2571 * src/truetype/truetype.c [TT_USE_BYTECODE_INTERPRETER]: Include
2574 * src/truetype/ttgload.c: Include `ttsubpix.h'.
2575 [All changes below are guarded by TT_CONFIG_OPTION_SUBPIXEL_HINTING.]
2577 (tt_get_metrics): Set tweak flags.
2578 (TT_Hint_Glyph): Call `FT_Outline_EmboldenXY' if necessary.
2579 (TT_Process_Simple_Glyph): Compensate emboldening if necessary.
2580 (compute_glyph_metrics): Handle `compatible widths' option.
2581 (tt_loader_init): Handle ClearType GETINFO information bits.
2583 * src/truetype/rules.mk (TT_DRC_SRC): Updated.
2585 * src/truetype/ttinterp.c: Include `ttsubpix.h'.
2586 [Where necessary, changes below are guarded by
2587 TT_CONFIG_OPTION_SUBPIXEL_HINTING.]
2589 (Direct_Move, Direct_Move_X): Extended.
2590 (Round_None, Round_To_Grid, Round_To_Half_Grid, Round_Down_To_Grid,
2591 Round_Up_To_Grid, Round_To_Double_Grid, Round_Super, Round_Super_45,
2592 SetSuperRound): Add parameter to handle the number of grid lines per
2594 (SET_SuperRound, ROUND_None, CUR_Func_round): Updated.
2595 (DO_SROUND, DOS45ROUND, DO_ODD, DO_EVEN): Updated.
2596 (DO_ROUND, DO_NROUND): Updated.
2597 (DO_RS): Take care of `Typeman' bytecode patterns.
2598 (Ins_FDEF): Add some debugging code. Commented out.
2599 (Ins_ENDF): Restore state.
2600 (Ins_CALL, Ins_LOOPCALL): Handle inline delta functions.
2601 (Ins_MD): Handle `Vacuform' rounds.
2602 (Move_Zp2_Point, Ins_SHPIX, Ins_MSIRP, Ins_MDAP, Ins_MIAP,
2603 Ins_MDRP, Ins_MIRP): Handle tweaks.
2604 (Ins_ALIGNRP): Add tweak guard.
2605 (Ins_IUP, Ins_DELTAP): Handle tweaks.
2606 (Ins_GETINFO): Handle new ClearType bits.
2607 (TT_RunIns): Handle tweaks.
2609 * src/truetype/ttinterp.h: Updated.
2610 (SPH_TweakRule, SPH_ScaleRule): New structures for tweaks.
2611 (TT_ExecContextRec): Add members for subpixel hinting support.
2613 * src/truetype/ttobjs.h (TT_DefRecord): Add `inline_delta' member.
2615 2012-06-15 Werner Lemberg <wl@gnu.org>
2617 * Version 2.4.10 released.
2618 =========================
2621 Tag sources with `VER-2-4-10'.
2623 * docs/VERSION.DLL: Update documentation and bump version number to
2626 * README, Jamfile (RefDoc),
2627 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
2628 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
2629 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
2630 builds/win32/visualc/freetype.dsp,
2631 builds/win32/visualc/freetype.vcproj,
2632 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
2633 builds/win32/visualce/freetype.vcproj,
2634 builds/win32/visualce/index.html,
2635 builds/wince/vc2005-ce/freetype.vcproj,
2636 builds/wince/vc2005-ce/index.html,
2637 builds/wince/vc2008-ce/freetype.vcproj,
2638 builds/wince/vc2008-ce/index.html: s/2.4.9/2.4.10/, s/249/2410/.
2640 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 10.
2642 * builds/unix/configure.raw (version_info): Set to 15:0:9.
2644 2012-06-15 Alexei Podtelezhnikov <apodtele@gmail.com>
2646 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Improve spacing.
2648 * docs/CHANGES: Updated.
2650 2012-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
2652 * builds/exports.mk: Add CCexe_CFLAGS and CCexe_LDFLAGS.
2654 to pass special compiler/linker flags under cross development.
2655 Suggested by Savannah bug #36367.
2657 ChangeLog on 2010-07-15 saying as they were removed was wrong
2658 for the official trunk of FreeType2. This commit is the first
2659 introduction of them.
2661 2012-06-14 Werner Lemberg <wl@gnu.org>
2663 * docs/CHANGES: Updated.
2665 2012-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
2667 [truetype] Add new versions of NEC FA family to tricky font list.
2669 NEC FA family dated in 1996 have different checksum.
2670 Reported by Johnson Y. Yan <yinsen_yan@foxitsoftware.com>; see
2672 http://lists.gnu.org/archive/html/freetype-devel/2012-06/msg00023.html
2674 * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids): 4 sets
2675 of fpgm & prep table checksums for FA-Gothic, FA-Minchou,
2676 FA-RoundedGothicM, FA-RoundedGothicB are added. The family
2677 names in sample PDF are truncated, thus the list of the
2678 family names in tt_check_trickyness_family() is not updated yet.
2680 2012-06-06 Werner Lemberg <wl@gnu.org>
2682 [ftraster] Fix rounding issue causing visual artifacts.
2684 Problem reported by jola <hans-jochen.lau@lhsystems.com>; see
2686 http://lists.gnu.org/archive/html/freetype-devel/2012-05/msg00036.html
2688 * src/raster/ftraster.c (SMulDiv_No_Round): New macro.
2690 * src/raster/ftmisc.h (FT_MulDiv_No_Round): Copied from `ftcalc.c'.
2692 2012-05-28 Alexei Podtelezhnikov <apodtele@gmail.com>
2694 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Simplify.
2696 We now use the cross product of the direction vectors to compute the
2697 outline's orientation.
2699 2012-05-28 Werner Lemberg <wl@gnu.org>
2701 * docs/CHANGES: Updated.
2703 2012-05-28 Alexei Podtelezhnikov <apodtele@gmail.com>
2705 New function FT_Outline_EmboldenXY.
2707 * include/freetype/ftoutln.h (FT_Outline_EmboldenXY): Define it.
2709 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Implement it, using a
2710 simplified embolding algorithm.
2711 (FT_Outline_Embolden): Make it a special case of
2712 `FT_Outline_EmboldenXY'
2714 2012-05-07 Werner Lemberg <wl@gnu.org>
2716 [type1] Fix Savannah bug #36386.
2718 * src/type1/t1load.c (t1_load_keyword): Ignore keyword if context is
2721 2012-04-07 Werner Lemberg <wl@gnu.org>
2723 Remove compiler warning.
2725 * src/truetype/ttgload.c (TT_Load_Glyph)
2726 [!TT_CONFIG_OPTION_EMBEDDED_BITMAPS]: Access `glyph->face' directly.
2728 2012-03-28 Werner Lemberg <wl@gnu.org>
2730 [autofit] Properly copy scaler flags to script metrics object.
2732 Without this patch, only the dummy and cjk autohinter modules get
2733 them (since they copy the whole scaler object).
2735 * src/autofit/aflatin.c (af_latin_metrics_scale),
2736 src/autofit/aflatin2.c (af_latin2_metrics_scale): Implement it.
2738 2012-03-22 Alexei Podtelezhnikov <apodtele@gmail.com>
2740 [bdflib] Remove redundant macro.
2742 * src/bdf/bdflib.c (isdigok): Remove and replace with sbitset, which
2743 is exactly the same.
2745 2012-03-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
2747 [configure] Fix Savannah bug #35644.
2749 * builds/unix/configure.raw: Check `-ansi' flag works even if gcc
2750 is used. Bionic libc headers for Android lose the consistency
2751 when they are parsed with __STDC_VERSION__ older than 199901L or
2754 2012-03-20 Werner Lemberg <wl@gnu.org>
2756 [bdf] Improvement to Savannah bug #35656.
2758 * src/bdf/bdflib.c (isdigok): Add cast, as suggested in report.
2760 2012-03-17 Chris Liddell <chris.liddell@artifex.com>
2762 [type1] Fix Savannah bug #35847.
2764 * src/type1/t1load.c (parse_subrs): Fix the loop exit condition;
2765 we want to exit when we have run out of data.
2767 2012-03-16 Werner Lemberg <wl@gnu.org>
2769 [bdf] Really fix Savannah bug #35658.
2771 * src/bdf/bdflib.c (_bdf_list_split): Add one more `field' initializer.
2773 2012-03-14 Yann Droneaud <yann@droneaud.fr>
2775 [sfnt] Make arrays static like all others.
2777 * src/sfnt/ttload.c (tt_face_load_maxp, tt_face_load_os2),
2778 src/sfnt/ttmtx.c (tt_face_load_hhea): Add `static' keyword to frame
2781 2012-03-14 Huw Davies <huw@codeweavers.com>
2783 [sfnt] A refinement of the previous commit.
2785 * src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16,
2786 tt_name_entry_ascii_from_other): Stop at null byte.
2788 2012-03-14 Huw Davies <huw@codeweavers.com>
2790 [sfnt] Add `name' table compatibility to MS Windows.
2792 * src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16,
2793 tt_name_entry_ascii_from_other): Don't replace `\0' with question
2794 marks when converting strings.
2796 2012-03-14 Werner Lemberg <wl@gnu.org>
2798 [type1] Fix Savannah bug #35833.
2800 Based on the patch given in the bug report.
2802 * src/type1/t1load.c (IS_INCREMENTAL): New macro.
2803 (read_binary_data): Add parameter `incremental'.
2804 Update all callers using `IS_INCREMENTAL'.
2806 2012-03-11 Werner Lemberg <wl@gnu.org>
2808 [autofit] Return correct linear advance width values.
2810 This was quite a subtle bug which accidentally showed up with glyph
2811 `afii10023' of arial.ttf (version 2.76). This glyph is a composite;
2812 the first component, `E', has an advance width of 1366 font units,
2813 while the advance width of the composite itself (which looks like
2814 uppercase `E' with dieresis) is 1367 font units. I think this is
2815 actually a bug in the font itself, because there is no reason that
2816 this glyph has not the same width as uppercase `E' without the
2817 dieresis. Anyway, it helped identify this problem.
2819 Using the TrueType hinter, the correct value (1367) of `afii10023'
2820 was returned, but the autohinter mysteriously returned 1366.
2822 Digging in the code showed that the autohinter recursively calls
2823 FT_Load_Glyph to load the glyph, adding the FT_LOAD_NO_SCALE load
2824 flag. However, the `linearHoriAdvance' field is still returned as a
2825 scaled value. To avoid scaling twice, the old code in autofit reset
2826 `linearHoriAdvance', using the `horiAdvance' field. This seemed to
2827 work since FT_LOAD_NO_SCALE was in use, but it failed actually,
2828 because `horiAdvance' is defined as the distance of the first
2829 subglyph's phantom points, which in turn are initialized using the
2830 advance width of the first subglyph. And as the given example
2831 shows, these widths can differ.
2833 * src/autofit/afloader.c (af_loader_load_g): Temporarily set
2834 FT_LOAD_LINEAR_DESIGN while calling FT_Load_Glyph to get unscaled
2835 values for the linear advance widths.
2837 2012-03-10 Werner Lemberg <wl@gnu.org>
2839 [truetype] Fix SSW instruction.
2841 * src/truetype/ttinterp.c (DO_SSW): SSW *does* use font units. For
2842 verification, it took some time to find a font which actually uses
2845 2012-03-09 Vinnie Falco <vinnie.falco@gmail.com>
2847 Prepare source code for amalgamation.
2849 * include/freetype/freetype.h: Swap order of preprocessor blocks.
2851 2012-03-08 Werner Lemberg <wl@gnu.org>
2853 * Version 2.4.9 released.
2854 =========================
2857 Tag sources with `VER-2-4-9'.
2859 * docs/CHANGES: Updated.
2861 * docs/VERSION.DLL: Update documentation and bump version number to
2864 * README, Jamfile (RefDoc),
2865 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
2866 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
2867 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
2868 builds/win32/visualc/freetype.dsp,
2869 builds/win32/visualc/freetype.vcproj,
2870 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
2871 builds/win32/visualce/freetype.vcproj,
2872 builds/win32/visualce/index.html,
2873 builds/wince/vc2005-ce/freetype.vcproj,
2874 builds/wince/vc2005-ce/index.html,
2875 builds/wince/vc2008-ce/freetype.vcproj,
2876 builds/wince/vc2008-ce/index.html: s/2.4.8/2.4.9/, s/248/249/.
2878 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 9.
2880 * builds/unix/configure.raw (version_info): Set to 14:1:8.
2882 2012-03-08 Werner Lemberg <wl@gnu.org>
2884 [bdf] Add missing overflow check.
2886 * src/bdf/bdflib.c (_bdf_parse_glyphs) <BITMAP>: Add threshold for
2889 2012-03-07 Vinnie Falco <vinnie.falco@gmail.com>
2891 Prepare source code for amalgamation.
2893 * src/autofit/aferrors.h, src/bdf/bdferror.h, src/bzip2/ftbzip2.c,
2894 src/cache/ftcerror.h, src/cff/cfferrs.h, src/cid/ciderrs.h,
2895 src/gxvalid/gxverror.h, src/gzip/ftgzip.c, src/lzw/ftlzw.c,
2896 src/otvalid/otverror.h, src/pcf/pcferror.h, src/pfr/pfrerror.h,
2897 src/psaux/psauxerr.h, src/pshinter/pshnterr.h,
2898 src/psnames/psnamerr.h, src/raster/rasterrs.h, src/sfnt/sferrors.h,
2899 src/smooth/ftsmerrs.h, src/truetype/tterrors.h,
2900 src/type1/t1errors.h, src/type42/t42error.h, src/winfonts/fnterrs.h:
2901 Add #undef FT_ERR_PREFIX before #define FT_ERR_PREFIX.
2903 2012-03-03 Werner Lemberg <wl@gnu.org>
2905 Fix Savannah bug #35660.
2907 For some divisions, we use casts to 32bit entities. Always guard
2908 against division by zero with these casts also.
2910 * src/base/ftcalc.c (ft_div64by32): Remove redundant cast.
2911 (FT_MulDiv, FT_MulDiv_No_Round): Add 32bit cast.
2912 (FT_DivFix): Add 32bit cast (this omission triggered the bug).
2914 2012-03-03 Werner Lemberg <wl@gnu.org>
2916 [psaux] Fix handling of track kerning.
2918 * src/psaux/afmparse.c (afm_parse_track_kern): Don't inverse sign
2919 for `min_kern'. It is indeed quite common that track kerning
2920 *increases* spacing for very small sizes.
2922 2012-03-02 Werner Lemberg <wl@gnu.org>
2924 [truetype] Fix Savannah bug #35689.
2926 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Check first outline
2929 2012-03-01 Werner Lemberg <wl@gnu.org>
2931 [bdf] Fix Savannah bug #35656.
2933 * src/bdf/bdflib.c (_bdf_parse_glyphs) <_BDF_BITMAP>: Check validity
2934 of nibble characters instead of accessing `a2i' array.
2936 2012-03-01 Werner Lemberg <wl@gnu.org>
2938 [winfonts] Fix Savannah bug #35659.
2940 * src/winfonts/winfnt.c (FNT_Face_Init): Check number of glyphs.
2942 2012-03-01 Werner Lemberg <wl@gnu.org>
2944 [bdf] Fix Savannah bug #35658.
2946 * src/bdf/bdflib.c (_bdf_list_split): Initialize `field' elements
2949 2012-03-01 Werner Lemberg <wl@gnu.org>
2951 [psaux] Fix Savannah bug #35657.
2953 If in function `skip_spaces' the routine `skip_comment' comes to the
2954 end of buffer, `cur' is still increased by one, so we need to check
2955 for `p >= limit' and not `p == limit'.
2957 * src/psaux/psconv.c (PS_Conv_Strtol, PS_Conv_ToFixed,
2958 PS_Conv_ASCIIHexDecode, PS_Conv_EexecDecode): Fix boundary checking.
2960 2012-03-01 Werner Lemberg <wl@gnu.org>
2962 [truetype] Fix Savannah bug #35646.
2964 * src/truetype/ttinterp.c (Ins_MIRP): Typo, present since ages. The
2965 code is now in sync with the other operators (e.g. MSIRP) which
2966 modify twilight points.
2968 2012-03-01 Werner Lemberg <wl@gnu.org>
2970 [bdf] Fix Savannah bug #35643.
2972 * src/bdf/bdflib.c (_bdf_list_ensure): Bring code in sync with
2973 comment before `_bdf_list_split', this is, really allocate at least
2974 five `field' elements.
2976 2012-03-01 Werner Lemberg <wl@gnu.org>
2978 [bdf] Fix Savannah bug #35641.
2980 * src/bdf/bdflib.c (_bdf_parse_glyphs) <DWIDTH, BBX>: Abort if
2981 _BDF_ENCODING isn't set. We need this because access to the `glyph'
2982 variable might be undefined otherwise.
2984 2012-03-01 Werner Lemberg <wl@gnu.org>
2986 [truetype] Fix Savannah bug #35640.
2988 * src/truetype/ttinterp.c (SkipCode, TT_RunIns): Fix boundary check
2989 for NPUSHB and NPUSHW instructions.
2991 2012-02-29 Werner Lemberg <wl@gnu.org>
2993 [truetype] Fix Savannah bug #35601.
2995 * src/truetype/ttinterp.c (Ins_SHZ): Use number of points instead of
2996 last point for loop.
2997 Also remove redundant boundary check.
2999 2012-02-29 Werner Lemberg <wl@gnu.org>
3001 [truetype] Remove redundant check.
3003 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Remove redundant
3004 second check for ordered contour start points.
3006 2012-02-29 Werner Lemberg <wl@gnu.org>
3008 [truetype] Make SHC instruction behave similar to MS rasterizer.
3010 * src/truetype/ttinterp.c (Ins_SHC): Handle virtual contour in
3013 2012-02-29 Alexei Podtelezhnikov <apodtele@gmail.com>
3015 Avoid modulo operators against a power-of-two denominator.
3017 * src/afcjk.c (af_hint_normal_stem), src/base/ftoutln.c
3018 (ft_contour_has), src/cff/cffgload.c (cff_decoder_parse_charstrings)
3019 <cff_op_vvcurveto, cff_op_hhcurveto, cff_op_hvcurveto>,
3020 src/gxvalid/gxvcommn.c (GXV_32BIT_ALIGNMENT_VALIDATE),
3021 src/gxvalid/gxvfeat.c (gxv_feat_setting_validate): Replace `%' with
3024 2012-02-29 Werner Lemberg <wl@gnu.org>
3026 [autofit] Don't synchronize digit widths for light rendering mode.
3028 We don't hint horizontally in this mode.
3030 * src/autofit/afloader.c (af_loader_load_g) <Hint_Metrics>:
3033 2012-02-26 Alexei Podtelezhnikov <apodtele@gmail.com>
3035 [type42] Minor code optimization (again).
3037 * src/type42/t42parse.c (t42_parse_sfnts): Simplify previous change.
3039 2012-02-26 Mateusz Jurczyk <mjurczyk@google.com>
3040 Werner Lemberg <wl@gnu.org>
3042 [smooth] Fix Savannah bug #35604.
3044 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use `FT_Pos'
3045 instead of `FT_UInt' for some variables and update comparisons
3046 accordingly. A detailed analysis can be found in the bug report.
3048 2012-02-26 Alexei Podtelezhnikov <apodtele@gmail.com>
3050 [type42] Minor code optimization.
3052 * src/type42/t42parse.c (t42_parse_sfnts): Use bitmask instead of
3055 2012-02-26 Werner Lemberg <wl@gnu.org>
3057 * docs/CHANGES: Updated.
3059 2012-02-26 Werner Lemberg <wl@gnu.org>
3061 [type1] Fix Savannah bug #35608.
3063 * src/type1/t1parse.c (T1_Get_Private_Dict): Reject too short
3066 2012-02-26 Werner Lemberg <wl@gnu.org>
3068 [bdf] Support `ENCODING -1 <n>' format.
3070 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Implement it.
3072 2012-02-26 Werner Lemberg <wl@gnu.org>
3074 [bdf] Fix Savannah bug #35607.
3076 * src/bdf/bdflib.c (_bdf_parse_glyphs) <ENCODING>: Normalize
3077 negative encoding values.
3079 2012-02-26 Werner Lemberg <wl@gnu.org>
3081 [type1] Fix Savannah bug #35606.
3083 * src/type1/t1load.c (parse_subrs): Add proper guards for `strncmp'.
3085 * src/psaux/psobjs.c (ps_parser_skip_PS_token): Emit error message
3086 only if cur < limit.
3088 2012-02-25 Werner Lemberg <wl@gnu.org>
3090 [pcf] Fix Savannah bug #35603.
3092 * src/pcf/pcfread.c (pcf_get_properties): Assure final zero byte in
3095 2012-02-25 Werner Lemberg <wl@gnu.org>
3097 [type42] Fix Savannah bug #35602.
3099 * src/type42/t42parse.c (t42_parse_sfnts): Check `string_size' more
3102 2012-02-25 Werner Lemberg <wl@gnu.org>
3104 [bdf] Fix Savannah bugs #35599 and #35600.
3106 * src/bdf/bdflib.c (ACMSG16): New warning message.
3107 (_bdf_parse_glyphs) <_BDF_BITMAP>: Check line length.
3109 2012-02-24 Werner Lemberg <wl@gnu.org>
3111 [bdf] Fix Savannah bugs #35597 and #35598.
3113 * src/bdf/bdflib.c (_bdf_is_atom): Fix handling of property value.
3115 2012-02-24 Vinnie Falco <vinnie.falco@gmail.com>
3117 Prepare source code for amalgamation (6/6).
3119 * src/cff/cffdrivr.c: s/Load_Glyph/cff_glyph_load/.
3121 * src/cid/cidload.c: s/parse_font_matrix/cid_parse_font_matrix/.
3122 s/t1_init_loader/cid_init_loader/.
3123 s/t1_done_loader/cid_done_loader/.
3125 * src/pxaux/t1cmap.c: s/t1_get_glyph_name/psaux_get_glyph_name/.
3127 * src/truetype/ttdriver.c: s/Load_Glyph/tt_glyph_load/.
3129 * src/type1/t1load.c: s/parse_font_matrix/t1_parse_font_matrix/.
3131 2012-02-24 Vinnie Falco <vinnie.falco@gmail.com>
3133 Prepare source code for amalgamation (5/6).
3135 * include/freetype/fterrors.h: Undefine FT_KEEP_ERR_PREFIX after
3138 2012-02-22 Vinnie Falco <vinnie.falco@gmail.com>
3140 Prepare source code for amalgamation (4/6).
3142 * src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine RAS_ARG,
3143 RAS_ARGS, RAS_VAR, and RAS_VARS before defining it.
3145 * src/smooth/ftgrays.c: s/TRaster/black_TRaster/,
3146 s/PRaster/black_PRaster/.
3147 * src/raster/ftraster.c: s/TRaster/gray_TRaster/,
3148 s/PRaster/gray_PRaster/.
3150 2012-02-20 Vinnie Falco <vinnie.falco@gmail.com>
3152 Prepare source code for amalgamation (3/6).
3154 * src/smooth/ftgrays.c: s/TWorker/black_TWorker/,
3155 s/PWorker/black_PWorker/.
3156 * src/raster/ftraster.c: s/TWorker/gray_TWorker/,
3157 s/PWorker/gray_PWorker/.
3159 2012-02-20 Vinnie Falco <vinnie.falco@gmail.com>
3161 Prepare source code for amalgamation (2/6).
3163 * src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine FLOOR,
3164 CEILING, TRUNC, and SCALED before defining it.
3166 2012-02-20 Vinnie Falco <vinnie.falco@gmail.com>
3168 Prepare source code for amalgamation (1/6).
3170 See discussion starting at
3172 http://lists.gnu.org/archive/html/freetype-devel/2012-01/msg00037.html
3174 * src/smooth/ftgrays.c: s/TBand/gray_TBand/.
3175 * src/raster/ftraster.c: s/TBand/black_TBand/.
3177 2012-02-17 Alexei Podtelezhnikov <apodtele@gmail.com>
3179 [autofit] Fix outline flags.
3181 * src/autofit/afloader.c (af_loader_load_g): Don't reassign
3182 `outline.flags' so that this information is preserved. See
3183 discussion starting at
3185 http://lists.gnu.org/archive/html/freetype-devel/2012-02/msg00046.html
3187 2012-02-11 Werner Lemberg <wl@gnu.org>
3189 [truetype] Fix Savannah bug #35466.
3191 Jump instructions are now bound to the current function. The MS
3192 Windows rasterizer behaves the same, as confirmed by Greg Hitchcock.
3194 * src/truetype/ttinterp.h (TT_CallRec): Add `Cur_End' element.
3195 * src/truetype/ttobjs.h (TT_DefRecord): Add `end' element.
3197 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF): Check upper
3198 bound of jump address.
3199 (Ins_FDEF, Ins_CALL, Ins_LOOPCALL, Ins_UNKNOWN, TT_RunIns): Updated.
3201 2012-02-11 Werner Lemberg <wl@gnu.org>
3203 We don't use `extensions'.
3205 * include/freetype/internal/ftobjs.h (FT_DriverRec): Remove
3208 2012-02-11 Werner Lemberg <wl@gnu.org>
3210 Clean up `generic' fields.
3212 * include/freetype/internal/ftobjs.h (FT_ModuleRec, FT_LibraryRec):
3213 Remove `generic' field since users can't access it.
3215 * src/base/ftobjs.c (FT_Done_GlyphSlot): Call `generic.finalizer' as
3216 advertised in the documentation of FT_Generic.
3217 (Destroy_Module, FT_Done_Library): Updated to changes in `ftobjs.h'.
3219 2012-02-07 Werner Lemberg <wl@gnu.org>
3221 [autofit] Harmonize function arguments.
3223 * src/autofit/afloader.c, src/autofit/afloader.h: Use `FT_Int32' for
3226 2012-02-07 Werner Lemberg <wl@gnu.org>
3228 * src/cff/cffobjs.c (cff_face_init): Remove unnecessary casts.
3230 2012-01-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3232 [gxvalid] Fix Savannah bug #35286.
3234 Patch submitted by anonymous reporter.
3236 * src/gxvalid/gxvcommn.c (gxv_XStateTable_subtable_setup):
3237 gxv_set_length_by_ulong_offset() must be called with 3, not 4,
3238 the number of the subtables in the state tables; classTable,
3239 stateArray, entryTable.
3241 2012-01-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3243 [raccess] Modify for PIC build.
3245 Based on the patch provided by Erik Dahlstrom <ed@opera.com>,
3246 http://lists.gnu.org/archive/html/freetype-devel/2012-01/msg00010.html
3248 Also `raccess_guess_table[]' and `raccess_rule_by_darwin_vfs()'
3249 are renamed with `ft_' suffixes.
3251 * src/base/ftbase.h: `raccess_rule_by_darwin_vfs()' is renamed
3252 to `ft_raccess_rule_by_darwin_vfs()'.
3253 * src/base/ftobjs.c: Ditto.
3255 * src/base/ftrfork.c: Declarations of FT_RFork_Rule,
3256 raccess_guess_rec, are moved to...
3257 * include/freetype/internal/ftrfork.h: Here.
3259 * include/freetype/internal/ftrfork.h:
3260 FT_RFORK_RULE_ARRAY_{BEGIN,ENTRY,END} macros are defined
3261 to replace raccess_guess_table[] in both of PIC and non-PIC
3263 * src/base/ftrfork.c: raccess_guess_table[] array is rewritten
3264 by FT_RFORK_RULE_ARRAY_{BEGIN,ENTRY,END}.
3266 * src/base/basepic.h (BasePIC): Add `ft_raccess_guess_table'
3267 storage. (FT_RACCESS_GUESS_TABLE_GET): New macro to retrieve
3268 the function pointer from `ft_raccess_guess_table' storage in
3269 `BasePIC' structure.
3270 * src/base/ftrfork.c (FT_Raccess_Guess): Rewritten with
3271 FT_RACCESS_GUESS_TABLE_GET.
3272 (raccess_get_rule_type_from_rule_index): Add `library' as the
3273 first argument to the function, to retrieve the storage of
3274 `ft_raccess_guess_table' from it. Also `raccess_guess_table'
3275 is replaced by FT_RACCESS_GUESS_TABLE_GET.
3276 (ft_raccess_rule_by_darwin_vfs): Ditto.
3278 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3280 Remove trailing spaces.
3282 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3284 Formatting PIC related sources.
3286 * src/autofit/afpic.c: Harmonize to FT2 coding conventions.
3287 * src/base/basepic.c: Ditto.
3288 * src/base/ftpic.c: Ditto.
3289 * src/cff/cffpic.c: Ditto.
3290 * src/pshinter/pshpic.c: Ditto.
3291 * src/psnames/pspic.c: Ditto.
3292 * src/raster/rastpic.c: Ditto.
3293 * src/sfnt/sfntpic.c: Ditto.
3294 * src/smooth/ftspic.c: Ditto.
3295 * src/truetype/ttpic.c: Ditto.
3297 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3299 [autofit] Fix the inclusion of `aflatin2.h' in PIC file.
3301 * src/autofit/afpic.c: Include `aflatin2.h' when
3302 FT_OPTION_AUTOFIT2 is defined, as afglobal.c does so.
3303 Unconditionally inclusion causes declared but unimplemented
3306 2012-01-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3308 [cff] Remove redundant declarations of cff_cmap_XXX_class_rec.
3310 * src/cff/cffpic.c: The declarations of
3311 FT_Init_Class_cff_cmap_encoding_class_rec() and
3312 FT_Init_Class_cff_cmap_unicode_class_rec() are removed.
3313 They can be obtained by the inclusion of cffcmap.h.
3314 cffcmap.h invokes FT_DECLARE_CMAP_CLASS() and it declares
3315 FT_Init_Class_cff_cmap_encoding_class_rec() etc in PIC mode.
3317 2012-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3319 Fix redundant declaration warning in PIC mode.
3321 Originally FT_DEFINE_{DRIVER,MODULE,RENDERER}() macros were
3322 designed to declare xxx_pic_{free,init} by themselves.
3323 Because these macros are used at the end of the module
3324 interface (e.g. ttdriver.c) and the wrapper source to build
3325 a module as a single object (e.g. truetype.c) includes
3326 the PIC file (e.g. ttpic.c) before the module interface,
3327 these macros are expanded AFTER xxx_pic_{free,init} body
3328 when the modules are built as single object.
3329 The declaration after the implementation causes the redundant
3330 declaration warnings, so the declarations are moved to module
3331 PIC headers (e.g. ttpic.h). Separating to other header files
3332 are needed for multi build.
3334 * include/freetype/internal/ftdriver.h (FT_DEFINE_DRIVER):
3335 Remove class_##_pic_free and class_##_pic_init declarations.
3336 * include/freetype/internal/ftobjs.h (FT_DEFINE_RENDERER,
3337 FT_DEFINE_MODULE): Ditto.
3339 * src/base/basepic.h: Insert a comment and fix coding style.
3340 * src/autofit/afpic.h: Declare autofit_module_class_pic_{free,
3342 * src/cff/cffpic.h: Declare cff_driver_class_pic_{free,init}.
3343 * src/pshinter/pshpic.h: Declare pshinter_module_class_pic_{free,
3345 * src/psnames/pspic.h: Declare psnames_module_class_pic_{free,
3347 * src/raster/rastpic.h: Declare
3348 ft_raster{1,5}_renderer_class_pic_{free,init}
3349 * src/sfnt/sfntpic.h: Declare sfnt_module_class_pic_{free,init}.
3350 * src/smooth/ftspic.h: Declare
3351 ft_smooth_{,lcd_,lcdv_}renderer_class_pic_{free,init}.
3352 * src/truetype/ttpic.h: Declare tt_driver_class_pic_{free,init}.
3354 2012-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3356 Make pspic.c to include module error header to fix multi build.
3358 * src/psnames/pspic.c: Include `psnamerr.h'.
3360 2012-01-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3362 [base] Fix a dereference of uninitialized variable in PIC mode.
3364 * src/base/ftglyph.c (FT_Glyph_To_Bitmap): `glyph' must be
3365 set before derefering to obtain `library'. The initialization
3366 of `clazz', `glyph', `library' and NULL pointer check are
3367 reordered to minimize PIC conditonals.
3369 2012-01-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3371 [base] Insert explicit cast for GCC 4.6 in PIC mode.
3373 * src/base/ftinit.c (FT_Add_Default_Modules): Under PIC
3374 configuration, FT_DEFAULT_MODULES_GET returns
3375 FT_Module_Class** pointer, GCC 4.6 warns that
3376 const FT_Module_Class* const* variable is warned as
3377 inappropriate to store it. To calm it, explicit cast is
3378 inserted. Also `library' is checked to prevent the NULL
3379 pointer dereference in FT_DEFAULT_MODULES_GET.
3381 2012-01-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3383 Fix PIC build broken by d9145241fe378104ba4c12a42534549faacc92e6.
3385 Under PIC configuration, FT_{CFF,PSCMAPS,SFNT,TT}_SERVICES_GET
3386 take no arguments but derefer the variable named `library'
3389 * src/cff/cffdrivr.c (cff_get_interface): Declare `library' and
3390 set it if non-NULL driver is passed.
3391 * src/truetype/ttdriver.c (tt_get_interface): Ditto.
3393 * src/sfnt/sfdriver.c (sfnt_get_interface): Declare `library'
3394 under PIC configuration, and set it if non-NULL module is given.
3395 * src/psnames/psmodule.c (psnames_get_interface): Ditto.
3397 2012-01-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3399 Make PIC files include module error headers, to use the error codes
3400 with per-module prefix.
3402 * src/autofit/afpic.c: Include `aferrors.h'.
3403 * src/cff/cffpic.c: Include `cfferrs.h'.
3404 * src/pshinter/pshpic.c: Include `pshnterr.h'.
3405 * src/raster/rastpic.c: Include `rasterrs.h'.
3406 * src/sfnt/sfntpic.c: Include `sferrors.h'.
3407 * src/smooth/ftspic.c: Include `ftsmerrs.h'.
3408 * src/truetype/ttpic.c: Include `tterrors.h'.
3410 2012-01-04 Tobias Ringström <tobias@ringis.se>
3412 [truetype] Fix IP instruction if x_ppem != y_ppem.
3414 * src/truetype/ttinterp.c (Ins_IP): Scale `orus' coordinates
3417 2012-01-02 Werner Lemberg <wl@gnu.org>
3419 Fix tracing message for `loca' table.
3421 * src/truetype/ttpload.c (tt_face_get_location): Don't emit a
3422 warning message if the last `loca' entry references an empty glyph.
3424 2011-12-10 Werner Lemberg <wl@gnu.org>
3426 Add some variable initializations.
3427 Reported by Richard COOK <rscook@unicode.org>.
3429 * src/type1/t1driver.c (t1_ps_get_font_value): Initialize `val'.
3430 * src/smooth/ftgrays.c (gray_render_conic): Initialize `levels'
3433 2011-12-08 Werner Lemberg <wl@gnu.org>
3435 Fix serious scaling bug in `FT_Get_Advances'.
3437 * src/base/ftadvanc.c (FT_Get_Advances): Advance values returned by
3438 `FT_Load_Glyph' must be simply multiplied by 1024.
3440 2011-12-08 Werner Lemberg <wl@gnu.org>
3442 * src/bdf/bdflib.c (_bdf_parse_start): Drop redundant error tracing.
3444 2011-12-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3446 [mac] Unify DARWIN_NO_CARBON with FT_MACINTOSH.
3448 Originally FT_MACINTOSH was a pure auto macro and DARWIN_NO_CARBON
3449 was a configurable macro to disable Carbon-dependent code. Because
3450 now configure script sets DARWIN_NO_CARBON by default and disables
3451 Darwin & Carbon-dependent codes, these macros can be unified.
3452 FT_MACINTOSH (undefined by default) is kept and DARWIN_NO_CARBON
3453 (defined by default) is removed, because DARWIN_NO_CARBON violates
3454 FT_XXX naming convention of public macros, and a macro configured by
3455 default is not portable for the building without configure (e.g.
3458 * builds/unix/configure.raw: Define FT_MACINTOSH if Carbon-based
3459 old Mac font support is requested and Carbon is available.
3460 * builds/unix/ftconfig.in: Undefine FT_MACINTOSH when the support
3461 for Mac OS X without Carbon (e.g. Mac OS X 10.4 for ppc64) is
3463 * include/freetype/config/ftconfig.in: Ditto.
3464 * builds/vms/ftconfig.h: Ditto.
3466 * src/base/ftbase.h: Remove DARWIN_NO_CARBON.
3467 * src/base/ftbase.c: Ditto.
3468 * src/base/ftobjs.c: Ditto.
3469 * src/base/ftrfork.c: Ditto.
3471 * src/base/ftmac.c: Compile the body if FT_MACINTOSH is defined
3472 (same with TT_USE_BYTECODE_INTERPRETER in ttinterp.c).
3473 * builds/mac/ftmac.c: Ditto.
3475 * builds/mac/FreeType.m68k_cfm.make.txt: Define FT_MACINTOSH.
3476 * builds/mac/FreeType.m68k_far.make.txt: Ditto.
3477 * builds/mac/FreeType.ppc_classic.make.txt: Ditto.
3478 * builds/mac/FreeType.ppc_carbon.make.txt: Ditto.
3480 2011-11-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3482 Fix Savannah bug #34728 (`make devel' on Mac OS X).
3484 * builds/toplevel.mk: Check `/dev/null' to identify the Unix-
3485 like systems without `init' nor `hurd' (e.g. Mac OS X >= 10.4).
3486 * builds/unix/detect.mk: Ditto.
3488 2011-11-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3490 [apinames] Fix the overflow of signed integer hash.
3492 * src/tools/apinames.c (names_add): Change the type of `h' from
3493 int to unsigned int, to prevent undefined behaviour in the
3494 overflow of signed integers (overflow of unsigned int is defined
3495 to be wrap around). Found by clang test suggested by Sean
3498 2011-11-30 Werner Lemberg <wl@gnu.org>
3500 [winfonts] Remove casts.
3502 * src/winfonts/winfnt.c (winfnt_driver_class): Remove all casts and
3503 update affected functions.
3504 (FNT_Size_Select): Fix number of arguments.
3506 2011-11-30 Werner Lemberg <wl@gnu.org>
3508 [type42] Remove casts.
3510 * src/type42/t42driver.c (t42_driver_class): Remove all casts and
3511 update affected functions.
3513 * src/type42/t42objs.c, src/type42/t42objs.h: Updated for t42driver
3516 2011-11-30 Werner Lemberg <wl@gnu.org>
3518 [type1] Remove casts.
3520 * src/type1/t1driver.c (t1_driver_class): Remove all casts and
3521 update affected functions.
3523 * src/type1/t1gload.c, src/type1/t1gload.h, src/type1/t1objs.c:
3524 Updated for t1driver changes.
3525 src/type1/t1objs.h (T1_Driver): Remove unused typedef.
3526 Updated for t1driver changes.
3528 2011-11-27 Werner Lemberg <wl@gnu.org>
3530 [bdf] Fix Savannah bug #34896.
3532 ENCODING now covers the whole Unicode range.
3534 Note, however, that this change is quite expensive since it
3535 increases the size of three arrays by almost 400kByte in total. The
3536 right fix is to replace the logic with something smarter.
3537 Additionally, there exist very old BDFs for three-byte CCCII
3538 encoding which exceeds the range of Unicode (another reason to have
3541 * src/bdf/bdf.h (bdf_font_t): Increase size of `nmod' and `umod'
3543 * src/bdf/bdflib.c (bdf_parse_t): Increase size of `have' array.
3545 2011-11-27 Werner Lemberg <wl@gnu.org>
3547 [bdf] Improve tracing.
3549 * src/bdf/bdflib.c (DBGMSG1, DBGMSG2): New macros.
3550 (_bdf_parse_glyphs): Use them.
3552 2011-11-26 Werner Lemberg <wl@gnu.org>
3556 * src/bdf/bdfdrivr.c (BDF_Face_Done), src/pcf/pcfdrivr.c
3557 (PCF_Face_Done): Remove tracing message.
3559 * src/bdf/bdfdrivr.c (BDF_Face_Init), src/cff/cffobjs.c
3560 (cff_face_init), src/cid/cidobjs.c (cid_face_init),
3561 src/pfr/pfrobjs.c (pfr_face_init), src/sfnt/sfobjs.c
3562 (sfnt_init_face), src/truetype/ttobjs.c (tt_face_init),
3563 src/type1/t1objs.c (T1_Face_Init), src/type42/t42objs.c
3564 (T42_Face_Init), src/winfonts/winfnt.c (FNT_Face_Init): Add
3567 * src/sfnt/sfobjs.c (sfnt_open_font), src/type42/t42objs.c
3568 (T42_Open_Face): Improve tracing.
3570 2011-11-26 Werner Lemberg <wl@gnu.org>
3572 [cid] Fix error code.
3574 * src/cid/cidparse.c (cid_parser_new): Do it.
3576 2011-11-26 Werner Lemberg <wl@gnu.org>
3578 [cff] Fix error code.
3580 * src/cff/cffload.c (cff_font_load): Do it.
3582 2011-11-26 Werner Lemberg <wl@gnu.org>
3584 Add new error code FT_Err_Missing_Module.
3586 Previously, FreeType misleadingly returned
3587 FT_Err_Unknown_File_Format if a module was missing (or a test was
3588 missing completely).
3590 * include/freetype/fterrdef.h (FT_Err_Missing_Module): Define.
3592 * src/cff/cffobjs.c (cff_face_init), src/cff/cffdrivr.c
3593 (cff_get_glyph_name), src/cid/cidobjs.c (cid_face_init),
3594 src/sfnt/sfobjs.c (sfnt_init_face), src/truetype/ttobjs.c
3595 (tt_face_init), src/type1/t1objs.c (T1_Face_Init),
3596 src/type42/t42objs.c (T42_Face_Init, T42_Driver_Init): Updated.
3598 * src/type1/t1afm.c (T1_Read_Metrics), src/type/t1objs.c
3599 (T1_Face_Init), src/type42/t42objs.c (T42_Face_Init): Remove now
3600 redundant test for `psaux'.
3602 2011-11-25 Werner Lemberg <wl@gnu.org>
3604 [bdf] Add more error messages.
3606 * src/bdf/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
3607 Add line number argument.
3609 (ERRMSG5, ERRMSG6, ERRMSG7, ERRMSG8, ERRMSG9): New macros.
3610 (_bdf_readstream, _bdf_set_default_spacing, _bdf_add_property,
3611 _bdf_parse_glyphs, _bdf_parse_start): Add error messages.
3613 2011-11-24 Werner Lemberg <wl@gnu.org>
3615 * include/freetype/fterrors.h: Remove dead code.
3617 2011-11-15 Werner Lemberg <wl@gnu.org>
3619 * docs/releases: Updated.
3621 2011-11-15 Werner Lemberg <wl@gnu.org>
3623 * Version 2.4.8 released.
3624 =========================
3627 Tag sources with `VER-2-4-8'.
3629 * docs/CHANGES: Updated.
3631 * docs/VERSION.DLL: Update documentation and bump version number to
3634 * README, Jamfile (RefDoc),
3635 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
3636 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
3637 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
3638 builds/win32/visualc/freetype.dsp,
3639 builds/win32/visualc/freetype.vcproj,
3640 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
3641 builds/win32/visualce/freetype.vcproj,
3642 builds/win32/visualce/index.html,
3643 builds/wince/vc2005-ce/freetype.vcproj,
3644 builds/wince/vc2005-ce/index.html,
3645 builds/wince/vc2008-ce/freetype.vcproj,
3646 builds/wince/vc2008-ce/index.html: s/2.4.7/2.4.8/, s/247/248/.
3648 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 8.
3650 * builds/unix/configure.raw (version_info): Set to 14:0:8.
3652 2011-11-13 Chris Liddell <chris.liddell@artifex.com>
3654 Add FT_Get_PS_Font_Value() API.
3656 This allows a Type 1 font face to be interrogated to retrieve most
3657 of the dictionary keys (keys not relevant to FreeType's Type 1
3658 interpreter are not available).
3660 * include/freetype/internal/services/svpsinfo.h
3661 (PS_GetFontValueFunc): New typedef.
3662 (PSInfo): Add `ps_get_font_value'.
3663 (FT_DEFINE_SERVICE_PSINFOREC): Updated.
3665 * include/freetype/internal/t1types.h (T1_EncodingType): Moved to...
3666 * include/freetype/t1tables.h: Here.
3667 (PS_Dict_Keys): New enumeration.
3668 (FT_Get_PS_Font_Value): New declaration.
3670 * src/base/fttype1.c (FT_Get_PS_Font_Value): New function.
3672 * src/type1/t1driver.c (t1_ps_get_font_value): This new function
3674 (t1_service_ps_info): Add it.
3676 * src/cff/cffdrivr.c (cff_service_ps_info), src/cid/cidriver.c
3677 (cid_service_ps_info), src/type42/t42drivr.c (t42_service_ps_info):
3680 2011-11-08 Braden Thomas <bthomas@apple.com>
3682 [cid] Various loading fixes.
3684 * src/cid/cidload.c (cid_load_keyword) <default>,
3685 (parse_font_matrix, parse_expansion_factor): Correctly check number
3687 (cid_read_subrs): Protect against invalid values of `num_subrs'.
3688 Assure that the elements of the `offsets' array are ascending.
3690 2011-11-05 Werner Lemberg <wl@gnu.org>
3692 * README: We use copyright ranges also.
3696 http://www.gnu.org/prep/maintain/html_node/Copyright-Notices.html
3698 this should be mentioned explicitly.
3700 2011-10-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3702 [raccess] Supplement for previous fix.
3704 * src/base/ftbase.h (raccess_rule_by_darwin_vfs): Do not declare
3705 it on native Mac OS X.
3706 * src/base/ftrfork.c (raccess_get_rule_type_from_rule_index):
3707 Hide raccess_get_rule_type_from_rule_index() on native Mac OS X
3710 2011-10-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3712 [raccess] Hide raccess_rule_by_darwin_vfs() on native Mac OS X.
3714 * src/base/ftrfork.c (raccess_rule_by_darwin_vfs): Do not
3715 compile on native Mac OS X because it is not used.
3717 2011-10-25 Werner Lemberg <wl@gnu.org>
3719 [truetype] Fix MD instruction for twilight zone.
3721 * src/truetype/ttinterp.c (Ins_MD): Without this fix, the MD
3722 instruction applied to original coordinates of twilight points
3723 always returns zero.
3725 2011-10-18 Werner Lemberg <wl@gnu.org>
3727 * Version 2.4.7 released.
3728 =========================
3731 Tag sources with `VER-2-4-7'.
3733 * docs/CHANGES: Updated.
3735 * docs/VERSION.DLL: Update documentation and bump version number to
3738 * README, Jamfile (RefDoc),
3739 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
3740 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
3741 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
3742 builds/win32/visualc/freetype.dsp,
3743 builds/win32/visualc/freetype.vcproj,
3744 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
3745 builds/win32/visualce/freetype.vcproj,
3746 builds/win32/visualce/index.html,
3747 builds/wince/vc2005-ce/freetype.vcproj,
3748 builds/wince/vc2005-ce/index.html,
3749 builds/wince/vc2008-ce/freetype.vcproj,
3750 builds/wince/vc2008-ce/index.html: s/2.4.6/2.4.7/, s/246/247/.
3752 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 7.
3754 * builds/unix/configure.raw (version_info): Set to 13:2:7.
3756 2011-10-15 Kal Conley <kcconley@gmail.com>
3758 Fix handling of transformations if no renderer is present.
3760 * src/base/ftobjs.c (FT_Load_Glyph): Thinko.
3762 2011-10-15 Kal Conley <kcconley@gmail.com>
3764 Fix conditions for autohinting.
3766 * src/base/ftobjs.c (FT_Load_Glyph): Handle
3767 FT_LOAD_IGNORE_TRANSFORM.
3769 2011-10-07 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3771 [gxvalid] Fix a bug to detect too large offset in morx table.
3773 * src/gxvalid/gxvmorx2.c
3774 (gxv_morx_subtable_type2_ligActionIndex_validate): Fix a bug
3775 that too large positive offset cannot be detected.
3777 2011-10-01 Braden Thomas <bthomas@apple.com>
3779 Handle some border cases.
3781 * include/freetype/config/ftstdlib.h (FT_USHORT_MAX): New macro.
3783 * src/base/ftbitmap.c (FT_Bitmap_Convert): Protect against invalid
3784 value of `target->rows'.
3786 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Add check for
3789 * src/raster/ftrend1.c (ft_raster1_render): Check `width' and
3792 * src/truetype/ttgxvar.c (TT_Vary_Get_Glyph_Deltas): Protect against
3793 invalid values in `localpoints' array.
3795 2011-10-01 Werner Lemberg <wl@gnu.org>
3797 [psnames] Handle zapfdingbats.
3798 Problem reported by Nicolas Rougier <Nicolas.Rougier@inria.fr>.
3800 * src/tools/glnames.py (adobe_glyph_list): Add data from AGL's
3801 `zapfdingbats.txt' file.
3803 * src/psnames/pstables.h: Regenerated.
3805 2011-09-27 Simon Bünzli <zeniko@gmail.com>
3807 [type1] Fix Savannah bug #34189.
3809 * src/type1/t1load.c (T1_Open_Face): Initialize
3810 `face->len_buildchar'.
3812 2011-09-26 Werner Lemberg <wl@gnu.org>
3814 [cff] Dump SIDs while tracing.
3816 * src/cff/cffobjs.c (cff_face_init): Do it.
3818 * src/cff/cffparse.c (cff_parser_run) [FT_DEBUG_LEVEL_TRACE]
3819 <cff_kind_string>: Identify as SID.
3821 2011-09-17 Werner Lemberg <wl@gnu.org>
3823 Remove unused FT_ALIGNMENT macro.
3825 * builds/unix/ftconfig.in, builds/vms/ftconfig.h,
3826 include/freetype/config/ftconfig.h: Do it.
3828 2011-09-17 Alexei Podtelezhnikov <apodtele@gmail.com>
3830 [smooth] Slightly optimize conic and cubic flatterners.
3832 * src/smooth/ftgrays.c (gray_render_conic, gray_render_cubic): Move
3833 out some code from the main loop to speed it up.
3835 2011-09-11 Tomas Hoger <thoger@redhat.com>
3837 Slightly improve LZW_CLEAR handling.
3839 * src/lzw/ftzopen.c (ft_lzwstate_io) <FT_LZW_PHASE_CODE>:
3840 Ensure that subsequent (modulo garbage byte(s)) LZW_CLEAR codes are
3841 handled as clear codes. This also re-sets old_code and old_char to
3842 predictable values, which is a little better than using `random'
3843 ones if the code following LZW_CLEAR is invalid.
3845 2011-09-11 Tomas Hoger <thoger@redhat.com>
3847 Add explicit LZW decompression stack size limit.
3849 Stack larger than 1<<LZW_MAX_BITS is never needed if prefix table is
3850 constructed correctly. It's even less than that, see e.g.
3851 libarchive code comment for a better size upper bound:
3853 http://code.google.com/p/libarchive/source/browse/trunk/libarchive/archive_read_support_filter_compress.c?r=3635#121
3855 This patch adds explicit stack size limit, enforced when stack is
3858 An alternative is to ensure that code < state->prefix[code - 256]
3859 when traversing prefix table. Such check is less efficient and
3860 should not be required if prefix table is constructed correctly in
3863 * src/lzw/ftzopen.c (ft_lzwstate_stack_grow): Implement it.
3865 2011-09-11 Tomas Hoger <thoger@redhat.com>
3867 Protect against loops in the prefix table.
3869 LZW decompressor did not sufficiently check codes read from the
3870 input LZW stream. A specially-crafted or corrupted input could
3871 create a loop in the prefix table, which leads to memory usage
3872 spikes, as there's no decompression stack size limit.
3874 * src/lzw/ftzopen.c (ft_lzwstate_io) <FT_LZW_PHASE_START>: First
3875 code in valid LZW stream must be 0..255.
3876 <FT_LZW_PHASE_CODE>: In the special KwKwK case, code == free_ent,
3877 code > free_ent is invalid.
3879 2011-09-09 Werner Lemberg <wl@gnu.org>
3881 Better tracing of metrics.
3883 * src/base/ftobjs.c (FT_Request_Size, FT_Select_Size): Decorate with
3886 2011-09-07 Werner Lemberg <wl@gnu.org>
3888 [cff] Fix Savannah bug #33816.
3890 * src/cff/cfftypes.h (CFF_FontRecDictRec): New member
3892 * src/cff/cffparse.c (cff_parse_font_matrix): Set it.
3893 Update tracing output.
3894 * src/cff/cffobjs.c (cff_face_init): Use it so that the heuristics
3897 2011-08-30 Werner Lemberg <wl@gnu.org>
3899 Better tracing of metrics.
3901 * src/base/ftobjs.c (FT_Select_Metrics, FT_Request_Metrics):
3902 Decorate with FT_TRACE.
3904 2011-08-25 Werner Lemberg <wl@gnu.org>
3906 [cff] Better tracing of the parsing process.
3908 * src/cff/cffload.c (cff_subfont_load, cff_font_load): Decorate with
3911 * src/cff/cffparse.c (cff_parse_font_matrix, cff_parse_font_bbox,
3912 cff_parse_private_dict, cff_parse_cid_ros): Updated.
3913 (CFF_FIELD_NUM, CFF_FIELD_FIXED, CFF_FIELD_FIXED_1000,
3914 CFF_FIELD_STRING, CFF_FIELD_BOOL, CFF_FIELD_CALLBACK, CFF_FIELD,
3915 CFF_FIELD_DELTA): Add argument for ID.
3916 (cff_parser_run): Decorate with FT_TRACE.
3918 * src/cff/cffparse.h (CFF_Field_Handler) [FT_DEBUG_LEVEL_TRACE]: Add
3921 * src/cff/cfftoken.h: Add IDs to all fields.
3923 2011-08-16 Werner Lemberg <wl@gnu.org>
3925 Fix Savannah bug #34022.
3927 * README, docs/INSTALL: Remove references to UPGRADE.UNIX.
3929 2011-08-15 Werner Lemberg <wl@gnu.org>
3931 Fix Savannah bug #34018.
3933 * docs/UPGRADE.UNIX: Removed. Obsolete.
3935 2011-08-15 David Bevan <david.bevan@pb.com>
3937 Fix Savannah bug #33992.
3939 * src/base/ftstroke.c (FT_Stroker_ParseOutline): Fix border case.
3941 2011-08-12 Werner Lemberg <wl@gnu.org
3943 [truetype] Fix degenerate case in S{P,F,DP}VTL opcodes.
3945 * src/truetype/ttinterp.c (Ins_SxVTL): Handle p1 == p2 specially.
3946 (Ins_SDPVTL): Handle v1 == v2 specially.
3948 2011-08-09 Werner Lemberg <wl@gnu.org>
3950 [cff] Fix Savannah bug #33975.
3952 * src/cff/cffparse.c (cff_parse_font_matrix): Fix typo.
3954 2011-07-29 Werner Lemberg <wl@gnu.org>
3956 * Version 2.4.6 released.
3957 =========================
3960 Tag sources with `VER-2-4-6'.
3962 * docs/CHANGES: Updated.
3964 * docs/VERSION.DLL: Update documentation and bump version number to
3967 * README, Jamfile (RefDoc),
3968 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
3969 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
3970 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
3971 builds/win32/visualc/freetype.dsp,
3972 builds/win32/visualc/freetype.vcproj,
3973 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
3974 builds/win32/visualce/freetype.vcproj,
3975 builds/win32/visualce/index.html,
3976 builds/wince/vc2005-ce/freetype.vcproj,
3977 builds/wince/vc2005-ce/index.html,
3978 builds/wince/vc2008-ce/freetype.vcproj,
3979 builds/wince/vc2008-ce/index.html: s/2.4.5/2.4.6/, s/245/246/.
3981 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 6.
3983 * builds/unix/configure.raw (version_info): Set to 13:1:7.
3985 2011-07-29 Werner Lemberg <wl@gnu.org>
3987 [cff] Add some more tracing infos.
3989 * src/cff/cffparse.c (cff_parse_font_matrix, cff_parse_font_bbox,
3990 cff_parse_cid_ros): Add tracing.
3992 2011-07-22 Dirk Müller <dmueller@suse.de>
3994 [psaux, type1] Fix null pointer dereferences.
3996 Found with font fuzzying.
3998 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Check
3999 `decoder->buildchar'.
4001 * src/type1/t1load.c (t1_load_keyword): Check `blend->num_designs'.
4003 2011-07-20 Chris Morgan <cmorgan@cybexintl.com>
4005 Add FT_CONFIG_OPTION_DISABLE_STREAM_SUPPORT.
4007 Useful for embedded systems which don't need file stream support.
4009 * src/base/ftsystem.c, src/base/ftobjs.c (FT_Stream_New): Implement
4012 2011-07-20 Elton Chung <elton328@gmail.com>
4014 * src/base/ftpatent.c (FT_Face_SetUnpatentedHinting): Fix typo.
4016 2011-07-16 Steven Chu <steven.f.chu@gmail.com>
4018 [truetype] Fix metrics on size request for scalable fonts.
4020 * src/truetype/ttdriver.c (tt_size_request): Fix copying metrics
4021 from TT_Size to FT_Size if scalable font.
4025 http://lists.gnu.org/archive/html/freetype-devel/2011-07/msg00049.html
4027 for some comparison images.
4029 2011-07-14 Matthias Drochner <M.Drochner@fz-juelich.de>.
4031 [psaux] Fix potential sign extension problems.
4033 When shifting right a signed value, it is not defined by the
4034 C standard whether one gets a sign extension or not. Use a macro to
4035 do an explicit cast from a signed short (assuming that this is
4038 * src/psaux/t1decode.c (Fix2Int): New macro.
4039 Use it where appropriate.
4041 2011-07-14 Werner Lemberg <wl@gnu.org>
4043 * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
4044 <op_callothersubr>: Better handling of subroutine index 0.
4045 From Matthias Drochner <M.Drochner@fz-juelich.de>.
4047 2011-07-10 Алексей Подтележников <apodtele@gmail.com>
4049 [psaux] Optimize previous commit.
4051 * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
4052 <op_callothersubr>: Move error check down to avoid testing twice for
4055 2011-07-08 Werner Lemberg <wl@gnu.org>
4057 [psaux] Add better argument check for `callothersubr'.
4059 * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
4060 <op_callothersubr>: Reject negative arguments.
4062 2011-07-07 Werner Lemberg <wl@gnu.org>
4064 [sfnt] Try harder to find non-zero values for ascender and descender.
4066 * src/sfnt/sfobjs.c (sfnt_load_face): Consult `OS/2' table in case
4067 the `hhea' table's values are zero.
4069 2011-07-03 Werner Lemberg <wl@gnu.org>
4071 Fix previous commit.
4073 We want to unset FT_FACE_FLAG_SCALABLE only if there are bitmap
4074 strikes in the font.
4076 * src/truetype/ttobjs.c (tt_face_init): Implement it.
4078 * docs/CHANGES: Updated.
4080 2011-07-02 Just Fill Bugs <mozbugbox@yahoo.com.au>
4082 [truetype] Fix Savannah bug #33246.
4084 * src/truetype/ttobjs.c (tt_check_single_notdef): New function.
4085 (tt_face_init): Use it to test FT_FACE_FLAG_SCALABLE.
4087 2011-07-02 Werner Lemberg <wl@gnu.org>
4089 * docs/CHANGES: Updated.
4091 2011-07-02 David Bevan <david.bevan@pb.com>
4093 [ftstroke] Major revision.
4098 o If FT_STROKER_LINEJOIN_BEVEL was specified, unlimited miter
4099 joins (not bevel joins) were generated. Indeed, the meanings of
4100 `miter' and `bevel' were incorrectly reversed (consistently) in
4101 both the code and comments.
4103 o The way bevel joins were constructed (whether specified
4104 explicitly, or created as a result of exceeding the miter limit)
4105 did not match what is required for stroked text in PostScript or
4111 o The behaviour of FT_STROKER_LINEJOIN_BEVEL has been corrected.
4113 o A new line join style, FT_STROKER_LINEJOIN_MITER_FIXED, has been
4114 introduced to support PostScript and PDF miter joins.
4116 o FT_STROKER_LINEJOIN_MITER_VARIABLE has been introduced as an
4117 alias for FT_STROKER_LINEJOIN_MITER.
4119 Additionally, a variety of stroking errors have been fixed. These
4120 would cause various artifacts (including points `at infinity'),
4121 especially when stroking poor quality fonts.
4125 http://lists.gnu.org/archive/html/freetype-devel/2011-07/msg00001.html
4127 for example documents. The FreeType stroker now produces results
4128 very similar to that produced by GhostScript and Distiller for these
4134 The following problems have been resolved:
4136 o Inside corners could be generated incorrectly. Intersecting the
4137 inside corner could cause a missing triangular area and other
4140 The intersection point can only be used if the join is between
4141 two lines and both lines are long enough. The `optimization'
4142 condition in `ft_stroker_inside' has been corrected; this
4143 requires the line length to be passed into various functions and
4144 stored in `FT_StrokerRec'.
4146 o Incorrect cubic curves could be generated. The angle
4147 calculations in `FT_Stroker_CubicTo' have been corrected to
4148 handle the case of the curve crossing the +/-PI direction.
4150 o If the border radius was greater than the radius of curvature of
4151 a curve, then the negative sector would end up outside (not
4152 inside) the border. This situation is now recognized and the
4153 negative sector is circumnavigated in the opposite direction.
4154 (If round line joins are being used, this code is disabled
4155 because the line join will always cover the negative sector.)
4157 o When a curve is split, the arcs may not join smoothly (especially
4158 if the curve turns sharply back on itself). Changes in
4159 direction between adjacent arcs were not handled. A round
4160 corner is now added if the deviation from one arc to the next is
4161 greater than a suitable threshold.
4163 o The current direction wasn't retained if a the outline contained
4164 a zero length lineto or a curve that was determined to be
4165 `basically a point'. This could cause a spurious join to be
4168 o Cubics with close control points could be mishandled. All eight
4169 cases are now distinguished correctly.
4174 o Borders for cubic curves could be too `flat'.
4175 FT_SMALL_CUBIC_THRESHOLD has been reduced a little to prevent
4178 o The handling and use of movable points has been simplified a
4181 o Various values are now computed only if the results are actually
4184 o The directions of the outer and inner borders have been swapped,
4185 as recommended by Graham Asher.
4187 * src/base/ftstroke.c: Revised.
4188 * include/freetype/ftstroke.h: Updated.
4190 2011-06-30 İsmail Dönmez <ismail@namtrac.org>
4192 * builds/toplevel.mk: We use git, not CVS, thus skip `.gitignore'.
4194 2011-06-29 Werner Lemberg <wl@gnu.org>
4196 [bdf] Fix Savannah bug #33663.
4198 * src/bdf/bdflib.c (_bdf_parse_glyphs): Handle negative values for
4201 * docs/CHANGES: Document it.
4203 2011-06-24 Werner Lemberg <wl@gnu.org>
4205 * Version 2.4.5 released.
4206 =========================
4209 Tag sources with `VER-2-4-5'.
4211 * docs/CHANGES: Updated.
4213 * docs/VERSION.DLL: Update documentation and bump version number to
4216 * README, Jamfile (RefDoc),
4217 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
4218 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
4219 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
4220 builds/win32/visualc/freetype.dsp,
4221 builds/win32/visualc/freetype.vcproj,
4222 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
4223 builds/win32/visualce/freetype.vcproj,
4224 builds/win32/visualce/index.html,
4225 builds/wince/vc2005-ce/freetype.vcproj,
4226 builds/wince/vc2005-ce/index.html,
4227 builds/wince/vc2008-ce/freetype.vcproj,
4228 builds/wince/vc2008-ce/index.html: s/2.4.4/2.4.5/, s/244/245/.
4230 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 5.
4232 * builds/unix/configure.raw (version_info): Set to 13:0:7.
4234 2011-06-20 Werner Lemberg <wl@gnu.org>
4236 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Fix change
4239 2011-06-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4241 [gxvalid] make the `prop' validation tracing verbose.
4243 * src/gxvalid/gxvprop.c: Add tracing messages for errors.
4245 2011-06-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4247 [autogen.sh] Reflect environment variable LIBTOOLIZE.
4249 2011-06-18 Werner Lemberg <wl@gnu.org>
4251 Update license documentation.
4253 * docs/GPL.TXT: Renamed to...
4254 * docs/GPLv2.TXT: This.
4256 * docs/LICENSE.TXT: Updated.
4258 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4260 Fix g++4.6 compiler warnings in module drivers.
4262 The background is same with previous commit.
4264 * src/truetype/ttgxvar.c (ft_var_readpackedpoints):
4265 Init `points'. (TT_Vary_Get_Glyph_Deltas): Init
4266 `delta_xy'. (TT_Get_MM_Var): Init `mmvar'.
4267 * src/type1/t1load.c (T1_Get_MM_Var): Ditto.
4268 * src/cff/cffdrivr.c (cff_ps_get_font_info): Init
4270 * src/cff/cffload.c (cff_index_get_pointers): Init `t'.
4271 (cff_font_load): Init `sub'.
4272 * src/cff/cffobjs.c (cff_size_init): Init `internal'.
4273 (cff_face_init): Init `cff'.
4274 * src/pfr/pfrload.c (pfr_extra_item_load_stem_snaps):
4276 * src/pcf/pcfread.c (pcf_get_properties): Init `properties'.
4277 (pcf_get_bitmaps): Init `offsets'. (pcf_get_encodings):
4279 * src/sfnt/ttload.c (tt_face_load_gasp): Init `gaspranges'.
4280 * src/sfnt/ttsbit.c (Load_SBit_Image): Init `components'.
4281 * src/cache/ftcmru.c (FTC_MruList_New): Init `node'.
4282 * src/gzip/ftgzip.c (FT_Stream_OpenGzip): Init `zip' and
4284 * src/lzw/ftlzw.c (FT_Stream_OpenLZW): Init `zip'.
4285 * src/bzip2/ftbzip2.c (FT_Stream_OpenBzip2): Init `zip'.
4287 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4289 [base] Fix g++4.6 compiler warnings in src/base/*.c.
4291 Passing uninitialized pointer to FT_NEW() families is
4292 not problematic theoretically (as far as the returned
4293 pointer is checked before writing), but g++4.6 dislikes
4294 it and warns by -Wuninitialized. Initialize them by NULL.
4296 * src/base/ftobjs.c (FT_Stream_New): Init `stream'.
4297 (new_memory_stream): Ditto.
4298 (FT_New_GlyphSlot): Init `slot'.
4299 (FT_CMap_New): Init `cmap'.
4300 (open_face_PS_from_sfnt_stream): Init `sfnt_ps'.
4301 (Mac_Read_POST_Resource): Init `pfb_data'.
4302 (Mac_Read_sfnt_Resource): Init `sfnt_data'.
4303 * src/base/ftrfork.c (FT_Raccess_Get_DataOffsets):
4304 Init `offsets_internal' and `ref'.
4305 (raccess_guess_darwin_hfsplus): Init `newpath'.
4306 (raccess_guess_darwin_newvfs): Ditto.
4307 * src/base/ftbitmap.c (ft_bitmap_assure_buffer):
4309 * src/base/ftstroke.c (FT_Stroker_New): Init `stroker'.
4311 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4315 Some invalid, overrunning, unrecommended non-zero values
4316 are cared in paranoid validation mode only. There are
4317 many lines looking like:
4319 if ( valid->root->level >= FT_VALIDATE_PARANOID )
4322 To simplify them, GXV_SET_ERR_IF_PARANOID( err ) is
4323 introduced for more paranoid validation in future.
4325 * src/gxvalid/gxvcommn.h (IS_PARANOID_VALIDATION):
4326 New macro to assure valid->root->level is more or
4327 equal to FT_VALIDATE_PARANOID. (GXV_SET_ERR_IF_PARANOID):
4328 New macro to raise an error if in paranoid validation.
4329 * src/gxvalid/gxvcommn.c: Use GXV_SET_ERR_IF_PARANOID().
4330 * src/gxvalid/gxvfeat.c: Ditto.
4331 * src/gxvalid/gxvjust.c: Ditto.
4332 * src/gxvalid/gxvkern.c: Ditto.
4333 * src/gxvalid/gxvmort.c: Ditto.
4334 * src/gxvalid/gxvmort0.c: Ditto.
4335 * src/gxvalid/gxvmort1.c: Ditto.
4336 * src/gxvalid/gxvmort2.c: Ditto.
4337 * src/gxvalid/gxvmorx1.c: Ditto.
4338 * src/gxvalid/gxvmorx2.c: Ditto.
4340 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4342 [gxvalid] Fix gcc4.6 compiler warnings in gxvtrak.c.
4344 * src/gxvalid/gxvtrak.c (gxv_trak_trackTable_validate):
4345 Check different entries pointing same traking value.
4346 (gxv_trak_validate): Remove unused variable `table_size'.
4348 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4350 [gxvalid] Fix gcc4.6 compiler warnings in gxvmorx*.c.
4352 * src/gxvalid/gxvmorx.c (gxv_morx_subtables_validate):
4353 Conditionalize unvalidated variable `subFeatureFlags'.
4354 (gxv_morx_chain_validate): Conditionalize unvalidated
4355 variable `defaultFlags'.
4357 * src/gxvalid/gxmorx0.c
4358 (gxv_morx_subtable_type0_entry_validate):
4359 Conditionalize unvalidated variables; `markFirst',
4360 `dontAdvance', `markLast', `verb'.
4362 * src/gxvalid/gxmorx1.c
4363 (gxv_morx_subtable_type1_entry_validate): Conditionalize
4364 unvalidated variables; `setMark', `dontAdvance'.
4366 * src/gxvalid/gxvmorx2.c
4367 (gxv_morx_subtable_type2_ligActionOffset_validate):
4368 Conditionalize unvalidated variables; `last', `store'.
4369 Checking for overrunning offset is added.
4370 (gxv_morx_subtable_type2_entry_validate):
4371 Conditionalize unvalidated variables; `setComponent',
4372 `dontAdvance', `performAction'.
4373 (gxv_morx_subtable_type2_ligatureTable_validate):
4374 Check if the GID for ligature does not exceed the
4375 max GID in `maxp' table.
4377 * src/gxvalid/gxvmort5.c
4378 (gxv_morx_subtable_type5_InsertList_validate):
4379 Conditionalize unvalidated loading of `insert_glyphID'
4380 array. (gxv_morx_subtable_type5_entry_validate):
4381 Conditionalize unvalidated variables; `setMark',
4382 `dontAdvance', `currentIsKashidaLike',
4383 `markedIsKashidaLike', `currentInsertBefore',
4384 `markedInsertBefore'.
4386 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4388 [gxvalid] Fix gcc4.6 compiler warnings in gxvmort*.c.
4390 * src/gxvalid/gxvmort.c (gxv_mort_subtables_validate):
4391 Conditionalize unvalidated variable `subFeatureFlags'.
4392 (gxv_mort_chain_validate): Conditionalize unvalidated
4393 variable `defaultFlags'.
4395 * src/gxvalid/gxmort0.c
4396 (gxv_mort_subtable_type0_entry_validate): Check the
4397 conflict of the marks for the glyphs.
4399 * src/gxvalid/gxmort1.c
4400 (gxv_mort_subtable_type1_offset_to_subst_validate):
4401 Local variables `min_gid', `max_gid' are replaced by
4402 variables in the validator.
4403 (gxv_mort_subtable_type1_entry_validate): Conditionalize
4404 unvalidated variables; `setMark', `dontAdvance'.
4405 (gxv_mort_subtable_type1_substTable_validate):
4406 Validate the GID by the min/max GIDs in the validator.
4408 * src/gxvalid/gxvmort2.c
4409 (gxv_mort_subtable_type2_ligActionOffset_validate):
4410 Conditionalize unvalidated variables; `last', `store'.
4411 Checking for overrunning offset is added.
4412 (gxv_mort_subtable_type2_entry_validate):
4413 Conditionalize unvalidated variables; `setComponent',
4415 (gxv_mort_subtable_type2_ligatureTable_validate):
4416 Check if the GID for ligature does not exceed the
4417 max GID in `maxp' table.
4419 * src/gxvalid/gxvmort5.c
4420 (gxv_mort_subtable_type5_InsertList_validate):
4421 Conditionalize unvalidated loading of `insert_glyphID'
4422 array. (gxv_mort_subtable_type5_entry_validate):
4423 Conditionalize unvalidated variables; `setMark',
4424 `dontAdvance', `currentIsKashidaLike',
4425 `markedIsKashidaLike', `currentInsertBefore',
4426 `markedInsertBefore'.
4428 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4430 [gxvalid] Fix gcc4.6 compiler warnings in gxvkern.c.
4432 * src/gxvalid/gxvkern.c
4433 (gxv_kern_subtable_fmt0_pairs_validate): Conditionalize
4434 unvalidated variable `kernValue'.
4435 (gxv_kern_subtable_fmt1_entry_validate): Conditionalize
4436 unvalidated variables; `push', `dontAdvance', `kernAction',
4438 (gxv_kern_coverage_new_apple_validate): Conditionalize
4439 trace-only variables; `kernVertical', `kernCrossStream',
4441 (gxv_kern_coverage_classic_apple_validate): Conditionalize
4442 trace-only variables; `horizontal', `cross_stream'.
4443 (gxv_kern_coverage_classic_microsoft_validate):
4444 Conditionalize trace-only variables; `horizontal',
4445 `minimum', `cross_stream', `override'.
4446 (gxv_kern_subtable_validate): Conditionalize trace-only
4447 variables; `version', `tupleIndex'.
4449 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4451 [gxvalid] Fix gcc4.6 compiler warnings in gxvjust.c.
4453 * src/gxvalid/gxvjust.c (gxv_just_check_max_gid):
4454 New function to unify the checks of too large GID.
4455 (gxv_just_wdp_entry_validate): Conditionalize unvalidated
4456 variables; `beforeGrowLimit', `beforeShrinkGrowLimit',
4457 `afterGrowLimit', `afterShrinkGrowLimit', `growFlags',
4458 `shrinkFlags'. Additional check for non-zero values in
4459 unused storage `justClass' is added.
4460 (gxv_just_actSubrecord_type0_validate): Conditionalize
4461 unvalidated variable `order'. GID is checked by
4462 gxv_just_check_max_gid(). Additional check for upside-down
4463 relationship between `lowerLimit' and `upperLimit' is added.
4464 (gxv_just_actSubrecord_type1_validate): GID is checked by
4465 gxv_just_check_max_gid().
4466 (gxv_just_actSubrecord_type2_validate): Conditionalize
4467 unvalidated variable `substThreshhold'. GID is checked by
4468 gxv_just_check_max_gid().
4469 (gxv_just_actSubrecord_type5_validate): GID is checked by
4470 gxv_just_check_max_gid().
4471 (gxv_just_classTable_entry_validate): Conditionalize
4472 unvalidated variables; `setMark', `dontAdvance',
4473 `markClass', `currentClass'.
4475 2011-06-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4477 [gxvalid] Preparation to fix gcc4.6 compiler warnings.
4479 * src/gxvalid/gxvcommn.h (GXV_LOAD_TRACE_VARS): New macro to
4480 conditionalize the variable which is only used for trace messages.
4481 Automatically set by FT_DEBUG_LEVEL_TRACE.
4482 (GXV_LOAD_UNUSED_VARS): New macro to conditionalize the loading of
4483 unvalidated variables. Undefined by default to calm gcc4.6 warning.
4484 (GXV_ValidatorRec.{min_gid,max_gid}): New variables to hold defined
4485 GID ranges, for the comparison of GID ranges in different subtables.
4487 2011-06-08 Werner Lemberg <wl@gnu.org>
4489 [autofit] Remove unused structure member.
4491 * src/autofit/afhints.h (AF_SegmentRec): Remove `contour'.
4492 * src/autofit/aflatin.c (af_latin_hints_compute_segments),
4493 src/autofit/aflatin2.c (af_latin2_hints_compute_segments): Updated.
4495 2011-05-30 Werner Lemberg <wl@gnu.org>
4497 Fix g++ 4.6 compilation.
4499 * src/autofit/afhints.c (af_glyph_hints_dump_segments,
4500 af_glyph_hints_dump_edges): Use cast.
4502 2011-05-30 Werner Lemberg <wl@gnu.org>
4504 Fix gcc 4.6 compiler warnings.
4506 * src/autofit/afcjk.c (af_cjk_metrics_init_blues): Use casts and
4507 remove unused variables.
4508 * src/autofit/aflatin.c (af_latin_hints_compute_edges): Comment out
4510 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use `height_org'
4511 and `width_org' conditionalized.
4513 2011-05-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4515 [mac] Conditionalize the inclusion of `AvailabilityMacros.h'.
4517 The native SDK on earliest Mac OS X (10.0-10.1) did not have
4518 `AvailabilityMacros.h'. To prevent the inclusion of missing
4519 header file, ECANCELED (introduced in 10.2) in POSIX header
4520 file <errno.h> is checked to detect the system version.
4522 * include/freetype/config/ftconfig.h: Conditionalize the
4523 inclusion of `AvailabilityMacros.h'.
4524 * builds/unix/ftconfig.in: Ditto.
4525 * builds/vms/ftconfig.h: Ditto.
4527 2011-05-27 Werner Lemberg <wl@gnu.org>
4529 [autofit] Improve tracing of hinting process.
4531 * src/autofit/aflatin.c (af_latin_hint_edges): Add tracing message
4534 2011-05-26 Werner Lemberg <wl@gnu.org>
4536 [autofit] Fix trace message.
4538 * src/autofit/aflatin.c (af_latin_hint_edges): Show correct value in
4541 2011-05-24 Daniel Zimmermann <netzimme@googlemail.com>
4543 Reduce warnings for MS Visual Studio 2010.
4545 * src/autofit/afhints.c (af_glyph_hints_get_num_segments,
4546 af_glyph_hints_get_segment_offset) [!FT_DEBUG_AUTOFIT]: Provide
4548 * src/cff/cffgload.c (cff_slot_load): Add cast.
4549 * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids): Use proper
4552 2011-05-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4554 Automake component `builds/unix/install-sh' is removed.
4556 * builds/unix/install-sh: Removed. It is not needed to
4557 include repository, because autogen.sh installs it.
4558 * builds/unix/.gitignore: Register install-sh.
4560 2011-05-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4562 [autofit] Make trace message for CJK bluezone more verbose.
4564 2011-05-08 Just Fill Bugs <mozbugbox@yahoo.com.au>
4565 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4567 [autofit] Add bluezones for CJK Ideographs.
4569 To remove extremas of vertical strokes of CJK Ideographs at
4570 low resolution and make the top and bottom horizontal stems
4571 aligned, bluezones for CJK Ideographs are calculated from
4572 sample glyphs. At present, vertical bluezones (bluezones
4573 to align vertical stems) are disabled by default. For detail, see
4574 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00070.html
4575 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00092.html
4576 http://lists.gnu.org/archive/html/freetype-devel/2011-05/msg00001.html
4578 * include/freetype/internal/fttrace.h: New trace component `afcjk'.
4579 * src/autofit/afcjk.h (AF_CJK{Blue,Axis,Metric}Rec): Add CJK version
4580 for AF_Latin{Blue,Axis,Metric}Rec.
4581 (af_cjk_metrics_check_digits): Ditto, shared with Indic module.
4582 (af_cjk_metrics_init_widths): Ditto.
4583 (af_cjk_metrics_init): Take AF_CJKMetric instead of AF_LatinMetric.
4584 (af_cjk_metrics_scale): Ditto (declaration).
4585 (af_cjk_hints_init): Ditto (declaration).
4586 (af_cjk_hints_apply): Ditto (declaration).
4587 * src/autofit/afcjk.c (af_cjk_metrics_scale): Ditto (body).
4588 (af_cjk_hints_init): Ditto (body).
4589 (af_cjk_hints_apply): Ditto (body).
4590 (af_cjk_metrics_init_widths): Duplicate af_latin_metrics_init_widths.
4591 (af_cjk_metrics_check_digits): Duplicate af_latin_metrics_check_digits.
4592 (af_cjk_metrics_init): Call CJK bluezone initializer.
4593 (af_cjk_metrics_scale_dim): Add code to scale bluezones.
4594 (af_cjk_hints_compute_blue_edges): New function, CJK version of
4595 af_latin_hints_compute_blue_edges.
4596 (af_cjk_metrics_init_blues): New function, CJK version of
4597 af_latin_metrics_init_blues.
4598 (af_cjk_hints_edges): Add code to align the edge stems to blue zones.
4600 * src/autofit/afindic.c (af_indic_metrics_init): Take AF_CJKMetric
4601 instead of AF_LatinMetric, and initialize as af_cjk_metrics_init.
4602 However bluezones are not initialized.
4603 (af_indic_metrics_scale): Take AF_CJKMetric instead of AF_LatinMetric.
4604 (af_indic_hints_init): Ditto.
4605 (af_indic_hints_apply): Ditto.
4607 * docs/CHANGES: Note about CJK bluezone support.
4609 2011-05-06 Werner Lemberg <wl@gnu.org>
4611 [autofit] Remove unused struct member.
4613 * src/autofit/aflatin.h (AF_LatinAxis): Remove `control_overshoot'.
4615 2011-05-04 Werner Lemberg <wl@gnu.org>
4617 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Simplify.
4619 2011-05-01 Just Fill Bugs <mozbugbox@yahoo.com.au>
4620 Werner Lemberg <wl@gnu.org>
4622 [autofit] Add more debugging functions.
4624 * src/autofit/afhints.c (af_glyph_hints_get_num_segments,
4625 af_glyph_hints_get_segment_offset): New functions.
4627 2011-05-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4629 Add new option `--disable-mmap' to configure script.
4631 * builds/unix/configure.raw: New option `--disable-mmap'
4632 is added. It is for the developers to simulate the systems
4633 without mmap() (like 4.3BSD, minix etc) on POSIX systems.
4635 2011-04-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4637 [truetype] Always recalculate the sfnt table checksum.
4639 * src/truetype/ttobjs.c (tt_get_sfnt_checksum): Recalculate
4640 the sfnt table checksum even if non-zero value is written in
4641 the TrueType font header. Some bad PDF generators write
4642 wrong values. For details see examples and benchmark tests
4643 of the latency by recalculation:
4644 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00091.html
4645 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00096.html
4647 2011-04-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4649 [truetype] Register a set of tricky fonts, NEC FA family.
4651 * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids):
4652 Add 8 checksum sets for NEC FA family. For the tricky fonts
4653 without some tables (e.g. NEC FA fonts lack cvt table),
4654 extra check is added to assure that a zero-length table in the
4655 registry is not included in the font.
4657 2011-04-29 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4659 [truetype] Fix a bug in the sfnt table checksum getter.
4661 * src/truetype/ttobjs.c (tt_get_sfnt_checksum): Check the
4662 return value of face->goto_table() correctly.
4664 2011-04-28 Werner Lemberg <wl@gnu.org>
4666 [autofit] Improve tracing messages.
4668 * src/autofit/aflatin.c (af_latin_metrics_init_blues,
4669 af_latin_align_linked_edge, af_latin_hint_edges): Do it.
4671 2011-04-25 Kan-Ru Chen <kanru@kanru.info>
4673 [truetype] Always check the checksum to identify tricky fonts.
4675 Because some PDF generators mangle the family name badly,
4676 the trickyness check by the checksum should be invoked always.
4678 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00073.html
4680 * src/truetype/ttobjs.c (tt_check_trickyness): Even when
4681 tt_check_trickyness_family() finds no trickyness,
4682 tt_check_trickyness_sfnt_ids() is invoked.
4684 2011-04-22 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4686 [autofit] Add more Indic scripts with hanging baseline.
4688 * src/autofit/afindic.c (af_indic_uniranges): Tibetan, Limbu,
4689 Sundanese, Meetei Mayak, Syloti Nagri and Sharada scripts are
4692 2011-04-21 Behdad Esfahbod <behdad@behdad.org>
4694 Always ignore global advance.
4696 This makes FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH redundant,
4697 deprecated, and ignored. The new behavior is what every major user
4698 of FreeType has been requesting. Global advance is broken in many
4699 CJK fonts. Just ignoring it by default makes most sense.
4701 * src/truetype/ttdriver.c (tt_get_advances),
4702 src/truetype/ttgload.c (TT_Get_HMetrics, TT_Get_VMetrics,
4703 tt_get_metrics, compute_glyph_metrics, TT_Load_Glyph),
4704 src/truetype/ttgload.h: Implement it.
4706 * docs/CHANGES: Updated.
4708 2011-04-21 rainy6144 <rainy6144@gmail.com>
4710 [autofit] Blur CJK stems if too many to preserve their gaps.
4712 When there are too many stems to preserve their gaps in the
4713 rasterization of CJK Ideographs at a low resolution, blur the
4714 stems instead of showing clumped stems. See
4715 http://lists.gnu.org/archive/html/freetype-devel/2011-02/msg00011.html
4716 http://lists.gnu.org/archive/html/freetype-devel/2011-04/msg00046.html
4719 * src/autofit/afcjk.c (af_cjk_hint_edges): Store the position of
4720 the previous stem by `has_last_stem' and `last_stem_pos', and skip
4721 a stem if the current and previous stem are too near to preserve
4724 2011-04-18 Werner Lemberg <wl@gnu.org>
4726 Integrate autofitter debugging stuff.
4728 * devel/ftoption.h, include/freetype/config/ftoption.h
4729 (FT_DEBUG_AUTOFIT): New macro.
4731 * include/freetype/internal/fttrace.h: Add trace components for
4734 * src/autofit/aftypes.h (AF_LOG): Removed.
4735 (_af_debug): Removed.
4737 * src/autofit/*: s/AF_DEBUG/FT_DEBUG_AUTOFIT/.
4738 s/AF_LOG/FT_TRACE5/.
4739 Define FT_COMPONENT where necessary.
4741 2011-04-18 Werner Lemberg <wl@gnu.org>
4743 Synchronize config files.
4745 * builds/unix/ftconfig.in: Copy missing assembler routines from
4746 include/freetype/config/ftconfig.h.
4748 2011-04-13 Werner Lemberg <wl@gnu.org>
4750 [psaux] Fix Savannah bug #33047.
4752 Patch submitted by anonymous reporter.
4754 * src/psaux/psobjs.c (ps_table_add): Use FT_PtrDist for pointer
4757 2011-04-11 Kan-Ru Chen <kanru@kanru.info>
4759 Fix reading of signed integers from files on 64bit platforms.
4761 Previously, signed integers were converted to unsigned integers, but
4762 this can fail because of sign extension. For example, 0xa344a1eb
4763 becomes 0xffffffffa344a1eb.
4765 We now do the reverse which is always correct because the integer
4766 size is the same during the cast from unsigned to signed.
4768 * include/freetype/internal/ftstream.h, src/base/ftstream.c
4769 (FT_Stream_Get*): Replace with...
4770 (FT_Stream_GetU*): Functions which read unsigned integers.
4771 Update all macros accordingly.
4773 * src/gzip/ftgzip.c (ft_gzip_get_uncompressed_size): Updated.
4775 2011-04-07 Werner Lemberg <wl@gnu.org>
4777 Update Unicode ranges for CJK autofitter; in particular, add Hangul.
4779 * src/autofit/afcjk.c (af_cjk_uniranges): Update to Unicode 6.0.
4781 2011-04-04 Werner Lemberg <wl@gnu.org>
4783 Fix formatting of autofit debug dumps.
4785 * src/autofit/afhints.c (af_glyph_hints_dump_points,
4786 af_glyph_hints_dump_segments, af_glyph_hints_dump_edges): Adjust
4789 2011-03-30 Werner Lemberg <wl@gnu.org>
4791 * src/autofit/aftypes.h (AF_OutlineRec): Removed, unused.
4793 2011-03-24 Werner Lemberg <wl@gnu.org>
4795 * src/cff/cfftypes.h (CFF_MAX_CID_FONTS): Increase to 256.
4796 This limit is given on p. 37 of Adobe Technical Note #5014.
4798 2011-03-23 Werner Lemberg <wl@gnu.org>
4800 * src/truetype/ttpload.c (tt_face_load_loca): Fix mismatch warning.
4802 2011-03-20 Werner Lemberg <wl@gnu.org>
4804 * src/sfnt/sfobjs.c (sfnt_open_font): Check number of TTC subfonts.
4806 2011-03-19 Werner Lemberg <wl@gnu.org>
4808 More C++ compilation fixes.
4810 * src/autofit/afhints.c (af_glyph_hints_dump_points,
4811 af_glyph_hints_dump_segments, af_glyph_hints_dump_edges)
4812 [__cplusplus]: Protect with `extern "C"'.
4814 2011-03-18 Werner Lemberg <wl@gnu.org>
4816 C++ compilation fixes.
4818 * src/autofit/aflatin.c (af_latin_hints_apply), src/autofit/afcjk.c
4819 (af_cjk_hints_apply): Use cast for `dim'.
4821 2011-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
4823 A better fix for Savannah bug #32671.
4825 * src/smooth/ftgrays.c (gray_render_conic): Clean up code and
4826 replace WHILE loop with a more natural DO-WHILE construct.
4828 2011-03-16 Werner Lemberg <wl@gnu.org>.
4830 * src/base/ftstroke.c (FT_StrokerRec): Remove unused `valid' field.
4831 Suggested by Graham Asher.
4833 2011-03-09 Werner Lemberg <wl@gnu.org>
4835 Make FT_Sfnt_Table_Info return the number of SFNT tables.
4837 * src/sfnt/sfdriver.c (sfnt_table_info): Implement it.
4838 * include/freetype/tttables.h: Update documentation.
4839 * docs/CHANGES: Updated.
4841 2011-03-07 Bram Tassyns <bramt@enfocus.be>
4843 [cff] Fix Savannah bug #27988.
4845 * src/cff/cffobjs.c (remove_style): New function.
4846 (cff_face_init): Use it to strip off the style part of the family
4849 2011-03-07 Werner Lemberg <wl@gnu.org>
4851 * docs/CHANGES: Updated.
4853 2011-03-07 Alexei Podtelezhnikov <apodtele@gmail.com>
4855 Quick fix for Savannah bug #32671.
4857 This isn't the optimal solution yet, but it restores the previous
4858 rendering quality (more or less).
4860 * src/smooth/ftgrays.c (gray_render_conic): Do more splitting.
4862 2011-03-06 Werner Lemberg <wl@gnu.org>
4864 Fix autohinting fallback.
4866 * src/base/ftobjs.c (FT_Load_Glyph): Assure that we only check TTFs,
4867 ignoring CFF-based OTFs.
4869 2011-02-27 Werner Lemberg <wl@gnu.org>
4871 Add AF_CONFIG_OPTION_USE_WARPER to control the autofit warper.
4873 * devel/ftoption.h, include/freetype/config/ftoption.h
4874 (AF_CONFIG_OPTION_USE_WARPER): New macro.
4875 * src/autofit/aftypes.h (AF_USE_WARPER): Remove.
4877 * src/autofit/*: s/AF_USE_WARPER/AF_CONFIG_OPTION_USE_WARPER/.
4879 * src/autofit/afwarp.c [!AF_CONFIG_OPTION_USE_WARPER]: Replace dummy
4880 variable assignment with a typedef.
4882 2011-02-26 Werner Lemberg <wl@gnu.org>
4884 [autofit] Slight simplifications.
4886 * src/autofit/aflatin.c (af_latin_hints_link_segments): Remove
4887 test which always returns false.
4888 (af_latin_hints_compute_blue_edges): Remove redundant assignment.
4890 2011-02-24 Werner Lemberg <wl@gnu.org>
4892 * docs/PROBLEMS: Mention rendering differences on different
4894 Suggested and worded by Jason Owen <jason.a.owen@gmail.com>.
4896 2011-02-24 Werner Lemberg <wl@gnu.org>
4898 [autofit] Comment out unused code.
4900 * src/autofit/aflatin.c, src/autofit/aflatin2.c
4901 (af_latin_hints_compute_edges): Do it.
4903 2011-02-24 Werner Lemberg <wl@gnu.org>
4905 * src/autofit/afhints.h (AF_GlyphHints): Remove unused field.
4907 2011-02-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4909 [cache] Fix an off-by-one bug in `FTC_Manager_RemoveFaceID'.
4910 Found by <ychen1392001@yahoo.com.cn>, see detail in
4912 http://lists.gnu.org/archive/html/freetype/2011-01/msg00023.html
4914 * src/cache/ftccache.c (FTC_Cache_RemoveFaceID): Check the node
4915 buckets[cache->p + cache->mask] too.
4917 2011-02-19 Kevin Kofler <kevin.kofler@chello.at>
4919 Fall back to autohinting if a TTF/OTF doesn't contain any bytecode.
4920 This is Savannah patch #7471.
4922 * src/base/ftobjs.c (FT_Load_Glyph): Implement it.
4924 2011-02-19 John Tytgat <John.Tytgat@esko.com>
4926 [cff] Fix subset prefix removal.
4927 This is Savannah patch #7465.
4929 * src/cff/cffobjs.c (remove_subset_prefix): Update length after
4930 subset prefix removal.
4932 2011-02-13 Bradley Grainger <bgrainger@logos.com>
4934 Add inline assembly version of FT_MulFix for MSVC.
4936 * include/freetype/config/ftconfig.h: Ported the FT_MulFix_i386
4937 function from GNU inline assembly syntax (see #ifdef __GNUC__ block
4938 above) to MASM syntax for Microsoft Visual C++.
4940 2011-02-13 Bradley Grainger <bgrainger@logos.com>
4942 Add project and solution files in Visual Studio 2010 format.
4944 * builds/win32/.gitignore: Ignore user-specific cache files.
4945 * builds/win32/vc2010/: Add VS2010 project & solution files, created
4946 by upgrading builds/win32/vc2008/freetype.vcproj.
4947 * objs/.gitignore: Ignore Visual Studio output files.
4949 2011-02-01 Werner Lemberg <wl@gnu.org>
4951 * src/autofit/afdummy.c: Include `aferrors.h'.
4952 Problem reported by Chris Liddell <chris.liddell@artifex.com>.
4954 2011-02-01 Werner Lemberg <wl@gnu.org>
4956 [cff] Ignore unknown operators in charstrings.
4957 Patch suggested by Miles.Lau <sunliang_liu@foxitsoftware.com>.
4959 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Emit tracing
4960 message for unknown operators and continue instead of exiting with a
4963 2011-02-01 Werner Lemberg <wl@gnu.org>
4965 [truetype] FT_LOAD_PEDANTIC now affects `prep' and `fpgm' also.
4967 * src/truetype/ttgload.c (tt_loader_init): Handle
4969 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep,
4970 tt_size_init_bytecode, tt_size_ready_bytecode): New argument to
4971 handle pedantic mode.
4972 * src/truetype/ttobjs.h: Updated.
4974 2011-01-31 Werner Lemberg <wl@gnu.org>
4976 [truetype] Protect jump instructions against endless loops.
4978 * src/truetype/interp.c (DO_JROT, DO_JMPR, DO_JROF): Exit with error
4981 2011-01-31 Werner Lemberg <wl@gnu.org>
4983 [truetype] Improve handling of invalid references.
4985 * src/truetype/interp.c: Set even more TT_Err_Invalid_Reference
4986 error codes only if pedantic hinting is active. At the same time,
4987 try to provide sane values which hopefully allow useful
4988 continuation. Exception to this is CALL and LOOPCALL – due to
4989 possible stack corruption it is necessary to bail out.
4991 2011-01-31 Werner Lemberg <wl@gnu.org>
4993 [truetype] Improve handling of stack underflow.
4995 * src/truetype/ttinterp.c (TT_RunIns, Ins_FLIPPT, Ins_DELTAP,
4996 Ins_DELTAC): Exit with error only if `pedantic_hinting' is set.
4997 Otherwise, try to do something sane.
4999 2011-01-30 Werner Lemberg <wl@gnu.org>
5001 * src/sfnt/ttmtx.c (tt_face_load_hmtx): Fix tracing message.
5003 2011-01-30 LIU Sun-Liang <sunliang_liu@foxitsoftware.com>
5005 [truetype]: Fix behaviour of MIAP for invalid arguments.
5007 * src/truetype/ttinterp.c (Ins_MIAP): Set reference points even in
5010 2011-01-18 Werner Lemberg <wl@gnu.org>
5012 [truetype] Fix handling of MIRP instruction.
5014 Thanks to Greg Hitchcock who explained the issue.
5016 * src/truetype/ttinterp.c (Ins_MIRP): Replace a `>=' operator with
5017 `>' since the description in the specification is incorrect.
5018 This fixes, for example, glyph `two' in font `Helvetica Neue LT Com
5019 65 medium' at 15ppem.
5021 2011-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5023 Fix ARM assembly code in include/freetype/config/ftconfig.h.
5025 * include/freetype/config/ftconfig.h (FT_MulFix_arm):
5026 Copy the maintained code from builds/unix/ftconfig.in.
5027 Old GNU binutils could not accept the reduced syntax
5028 `orr %0, %2, lsl #16'. Un-omitted syntax like RVCT,
5029 `orr %0, %0, %2, lsl #16' is better. Reported by
5030 Johnson Y. Yan. The bug report by Qt developers is
5033 http://bugreports.qt.nokia.com/browse/QTBUG-6521
5035 2011-01-15 Werner Lemberg <wl@gnu.org>
5037 [raster] Make bbox handling the same as with Microsoft's rasterizer.
5039 Right before B/W rasterizing, the bbox gets simply rounded to
5040 integers. This fixes, for example, glyph `three' in font `Helvetica
5041 Neue LT Com 65 Medium' at 11ppem.
5043 Thanks to Greg Hitchcock who explained this behaviour.
5045 * src/raster/ftrend1.c (ft_raster1_render): Implement it.
5047 2011-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5049 Copy -mcpu=* & -march=* options from CFLAGS to LDFLAGS.
5051 * builds/unix/configure.raw: Consider recent gcc-standard
5052 flags to specify architecture in CFLAGS & LDFLAGS
5053 harmonization. Requested by Savannah bug #32114, to
5054 support multilib feature of BuildRoot SDK correctly.
5056 2011-01-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5058 Fix off-by-one bug in CFLAGS & LDFLAGS harmonizer.
5060 * builds/unix/configure.raw: Some important options that
5061 included in CFLAGS but not in LDFLAGS are copied to
5062 LDFLAGS, but the last option in CFLAGS was not checked.
5064 2011-01-13 Werner Lemberg <wl@gnu.org>
5066 [raster] Add undocumented drop-out rule to the other bbox side also.
5068 * src/raster/ftraster.c (Vertical_Sweep_Drop,
5069 Horizontal_Sweep_Drop): Implement it.
5071 2011-01-13 Werner Lemberg <wl@gnu.org>
5073 [raster] Reduce jitter value.
5075 This catches a rendering problem with glyph `x' from Tahoma at
5076 10ppem. It seems that the increase of the precision in the change
5077 from 2009-06-11 makes a larger jitter value unnecessary.
5079 * src/raster/ftraster.c (Set_High_Precision): Implement it.
5081 2011-01-13 Werner Lemberg <wl@gnu.org>
5083 [raster] Handle drop-outs at glyph borders according to Microsoft.
5085 If a drop-out rule would switch on a pixel outside of the glyph's
5086 bounding box, use the right (or top) pixel instead. This is an
5087 undocumented feature, but some fonts like `Helvetica Neue LT Com 65
5088 Medium' heavily rely on it.
5090 Thanks to Greg Hitchcock who explained this behaviour.
5092 * src/raster/ftraster.c (Vertical_Sweep_Drop,
5093 Horizontal_Sweep_Drop): Implement it.
5095 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5097 [cache] Fix Savannah bug #31923, patch drafted by Harsha.
5099 When a node comparator changes the cached nodes during the
5100 search of a node matching with queried properties, the
5101 pointers obtained before the function should be updated to
5102 prevent the dereference to freed or reallocated nodes.
5103 To minimize the rescan of the linked list, the update is
5104 executed when the comparator notifies the change of cached
5105 nodes. This change depends previous change:
5106 38b272ffbbdaae276d636aec4ef84af407d16181
5108 * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): Rescan the
5109 top node if the cached nodes are changed.
5110 * src/cache/ftccache.c (FTC_Cache_Lookup): Ditto.
5112 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5114 [cache] Notice if a cache query induced the node list change.
5116 Some node comparators (comparing the cache node contents and the
5117 properties specified by the query) can flush the cache node to
5118 prevent the cache inflation. The change may invalidate the pointers
5119 to the node obtained before the node comparison, so it should be
5120 noticed to the caller. The problem caused by the cache node
5121 changing is reported by Harsha, see Savannah bug #31923.
5123 * src/cache/ftccache.h (FTC_Node_CompareFunc): Add new argument
5124 `FT_Bool* list_changed' to indicate the change of the cached nodes
5126 (FTC_CACHE_LOOKUP_CMP): Watch the change of the cached nodes by
5128 (FTC_CACHE_TRYLOOP_END): Take new macro argument `_list_changed'
5129 and update it when `FTC_Manager_FlushN' flushes any nodes.
5131 * src/cache/ftccback.h (ftc_snode_compare): Updated to fit with new
5132 FTC_Node_CompareFunc type.
5133 (ftc_gnode_compare): Ditto.
5135 * src/cache/ftcbasic.c: Include FT_INTERNAL_OBJECTS_H to use
5137 (ftc_basic_gnode_compare_faceid): New argument `FT_Bool*
5138 list_changed' to indicate the change of the cache nodes (anyway, it
5141 * src/cache/ftccmap.c: Include FT_INTERNAL_OBJECTS_H to use
5143 (ftc_cmap_node_compare): New argument `FT_Bool* list_changed' to
5144 indicate the change of the cache nodes (anyway, it is always FALSE).
5145 (ftc_cmap_node_remove_faceid): Ditto.
5147 * src/cache/ftccache.c (FTC_Cache_NewNode): Pass a NULL pointer to
5148 `FTC_CACHE_TRYLOOP_END', because the result is not needed.
5149 (FTC_Cache_Lookup): Watch the change of the cache nodes by
5151 (FTC_Cache_RemoveFaceID): Ditto.
5153 * src/cache/ftcglyph.c: Include FT_INTERNAL_OBJECTS_H to use
5155 (ftc_gnode_compare): New argument `FT_Bool* list_changed' to
5156 indicate the change of the cache nodes (anyway, it is always FALSE).
5157 (FTC_GNode_Compare): New argument `FT_Bool* list_changed' to be
5158 passed to `ftc_gnode_compare'.
5159 * src/cache/ftcglyph.h (FTC_GNode_Compare): Ditto.
5161 * src/cache/ftcsbits.c (ftc_snode_compare): New argument `FT_Bool*
5162 list_changed' to indicate the change of the cache nodes, anyway. It
5163 is updated by `FTC_CACHE_TRYLOOP'.
5164 (FTC_SNode_Compare): New argument `FT_Bool* list_changed' to be
5165 passed to `ftc_snode_compare'.
5166 * src/cache/ftcsbits.h (FTC_SNode_Compare): Ditto.
5168 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5170 [cache] Fit `FTC_GNode_Compare' to `FTC_Node_CompareFunc'.
5172 * src/cache/ftcglyph.h (FTC_GNode_Compare): Add the 3rd
5173 argument `FTC_Cache cache' to fit FTC_Node_CompareFunc
5175 * src/cache/ftcglyph.c (FTC_GNode_Compare): Ditto. Anyway,
5176 `cache' is not used by its child `ftc_gnode_compare'.
5178 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5180 [cache] Deduplicate the code to get the top node by a hash.
5182 There are several duplicated code fragments getting the top node
5183 from a cache by a given hash, like:
5185 idx = hash & cache->mask;
5186 if ( idx < cache->p )
5187 idx = hash & ( cache->mask * 2 + 1 );
5188 pnode = cache->buckets + idx;
5190 To remove duplication, a cpp-macro to do same work
5191 `FTC_NODE__TOP_FOR_HASH' is introduced. For non-inlined
5192 configuration, non-`ftc_get_top_node_for_hash' is also introduced.
5194 * src/cache/ftccache.h (FTC_NODE__TOP_FOR_HASH): Declare
5195 and implement inlined version.
5196 (FTC_CACHE_LOOKUP_CMP): Use `FTC_NODE__TOP_FOR_HASH'.
5197 * src/cache/ftccache.c (ftc_get_top_node_for_hash): Non-inlined
5199 (ftc_node_hash_unlink): Use `FTC_NODE__TOP_FOR_HASH'.
5200 (ftc_node_hash_link): Ditto.
5201 (FTC_Cache_Lookup): Ditto.
5203 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5205 [cache] inline-specific functions are conditionalized.
5207 * src/cache/ftcglyph.c (FTC_GNode_Compare): Conditionalized for
5208 inlined configuration. This function is a thin wrapper of
5209 `ftc_gnode_compare' for inlined `FTC_CACHE_LOOKUP_CMP' (see
5210 `nodecmp' argument). Under non-inlined configuration,
5211 `ftc_gnode_compare' is invoked by `FTC_Cache_Lookup', via
5212 `FTC_Cache->clazz.node_compare'.
5214 * src/cache/ftcglyph.h (FTC_GNode_Compare): Ditto.
5215 * src/cache/ftcsbits.c (FTC_SNode_Compare): Ditto, for
5216 `ftc_snode_compare'.
5217 * src/cache/ftcsbits.h (FTC_SNode_Compare): Ditto.
5219 2011-01-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5221 [cache] Correct a type mismatch under non-inlined config.
5223 * src/cache/ftcglyph.h (FTC_GCACHE_LOOKUP_CMP): `FTC_GCache_Lookup'
5224 takes the node via a pointer `FTC_Node*', differently from cpp-macro
5225 `FTC_CACHE_LOOKUP_CMP'.
5227 2011-01-06 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5229 Update Jamfile to include Bzip2 support.
5231 * Jamfile: Include src/bzip2 to project.
5232 Comments for lzw, gzip, bzip2 are changed to clarify that
5233 they are for compressed PCF fonts, not others.
5234 (e.g. compressed BDF fonts are not supported yet)
5236 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5238 Update Symbian project files to include Bzip2 support.
5240 Currently, it provides `FT_Stream_OpenBzip2' that returns
5241 unimplemented error always, to prevent unresolved symbol
5242 error for the applications designed for Unix systems.
5244 * builds/symbian/bld.inf: Include ftbzip2.h.
5245 * builds/symbian/freetype.mmp: Include ftbzip2.c.
5247 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5249 Update classic MacOS makefiles to include Bzip2 support.
5251 Currently, it provides `FT_Stream_OpenBzip2' that returns
5252 unimplemented error always, to prevent unresolved symbol
5253 error for the applications designed for Unix systems.
5255 * builds/mac/FreeType.m68k_cfm.make.txt: Include ftbzip2.c.o.
5256 * builds/mac/FreeType.m68k_far.make.txt: Ditto.
5257 * builds/mac/FreeType.ppc_carbon.make.txt: Include ftbzip2.c.x.
5258 * builds/mac/FreeType.ppc_classic.make.txt: Ditto.
5260 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5262 Update Amiga makefiles to include Bzip2 support.
5264 Currently, it provides `FT_Stream_OpenBzip2' that returns
5265 unimplemented error always, to prevent unresolved symbol
5266 error for the applications designed for Unix systems.
5268 * builds/amiga/makefile: Include bzip2.ppc.o built from ftbzip2.c.
5269 * builds/amiga/makefile.os4: Include bzip2.o built from ftbzip2.c.
5270 * builds/amiga/smakefile: Ditto.
5272 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5274 Update pkg-config tools to reflect Bzip2 support.
5276 * builds/unix/freetype-config.in: Include `-lbz2' to
5277 --libs output, if built with Bzip2 support.
5278 * builds/unix/freetype2.in: Ditto.
5280 2011-01-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5282 * builds/unix/configure.raw: Remove `SYSTEM_BZ2LIB' macro.
5284 SYSTEM_ZLIB is used to switch the builtin zlib source
5285 or system zlib source out of FreeType2. But ftbzip2
5286 module has no builtin bzip2 library and always requires
5287 system bzip2 library. Thus SYSTEM_BZ2LIB is always yes,
5290 2011-01-03 Werner Lemberg <wl@gnu.org>
5292 */rules.mk: Handle `*pic.c' files.
5294 2010-12-31 Werner Lemberg <wl@gnu.org>
5296 * src/cff/cfftypes.h (CFF_MAX_CID_FONTS): Increase to 64.
5297 Problem reported by Tom Bishop <wenlin@wenlin.com>.
5299 2010-12-31 Werner Lemberg <wl@gnu.org>
5301 Improve bzip2 support.
5303 * include/freetype/ftmoderr.h: Add bzip2.
5305 * docs/INSTALL.ANY, docs/CHANGES: Updated.
5307 * src/pcf/README: Updated.
5308 * include/freetype/internal/pcftypes.h: Obsolete, removed.
5310 2010-12-31 Joel Klinghed <the_jk@yahoo.com>
5312 Add bzip2 compression support to handle *.pcf.bz2 files.
5314 * builds/unix/configure.raw: Test for libbz2 library.
5316 * devel/ftoption.h, include/freetype/config/ftoption.h
5317 (FT_CONFIG_OPTION_USE_BZIP2): Define.
5318 * include/freetype/config/ftheader.h (FT_BZIP2_H): Define.
5320 * include/freetype/ftbzip2.h: New file.
5322 * src/bzip2/*: New files.
5324 * src/pcf/pcf.h: s/gzip_/comp_/.
5325 * src/pcf/pcfdrvr.c: Include FT_BZIP2_H.
5327 (PCF_Face_Init): Handle bzip2 compressed files.
5329 * docs/formats.txt, modules.cfg: Updated.
5331 2010-12-25 Harsha <mm.harsha@gmail.com>
5333 Apply Savannah patch #7422.
5335 If we encounter a space in a string then the sbit buffer is NULL,
5336 height and width are 0s. So the check in ftc_snode_compare will
5337 always pass for spaces (comparision with 255). Here the comments
5338 above the condition are proper but the implementation is not. When
5339 we create an snode I think it is the proper way to initialize the
5340 width to 255 and then put a check for being equal to 255 in snode
5343 * src/cache/ftcsbits.c (FTC_SNode_New): Initialize sbit widths with
5345 (ftc_snode_compare): Fix condition.
5347 2010-12-13 Werner Lemberg <wl@gnu.org>
5349 Fix parameter handling of `FT_Set_Renderer'.
5350 Reported by Kirill Tishin <siege@bk.ru>.
5352 * src/base/ftobjs.c (FT_Set_Renderer): Increment `parameters'.
5354 2010-12-09 Werner Lemberg <wl@gnu.org>
5356 [cff] Allow `hlineto' and `vlineto' without arguments.
5358 We simply ignore such instructions. This is invalid, but it doesn't
5359 harm; and indeed, there exist such subsetted fonts in PDFs.
5361 Reported by Albert Astals Cid <aacid@kde.org>.
5363 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
5364 [cff_op_hlineto]: Ignore instruction if there aren't any arguments
5367 2010-11-28 Werner Lemberg <wl@gnu.org>
5369 * Version 2.4.4 released.
5370 =========================
5373 Tag sources with `VER-2-4-4'.
5375 * docs/CHANGES: Updated.
5377 * docs/VERSION.DLL: Update documentation and bump version number to
5380 * README, Jamfile (RefDoc),
5381 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5382 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5383 builds/win32/visualc/freetype.dsp,
5384 builds/win32/visualc/freetype.vcproj,
5385 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5386 builds/win32/visualce/freetype.vcproj,
5387 builds/win32/visualce/index.html,
5388 builds/wince/vc2005-ce/freetype.vcproj,
5389 builds/wince/vc2005-ce/index.html,
5390 builds/wince/vc2008-ce/freetype.vcproj,
5391 builds/wince/vc2008-ce/index.html: s/2.4.3/2.4.4/, s/243/244/.
5393 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 4.
5395 * builds/unix/configure.raw (version_info): Set to 12:2:6.
5397 2010-11-28 Alexei Podtelezhnikov <apodtele@gmail.com>
5399 [ftsmooth]: Minor code simplification.
5401 * src/smooth/ftgrays (gray_render_cubic): Do only one comparison
5404 2010-11-26 Johnson Y. Yan <yinsen_yan@foxitsoftware.com>
5406 [truetype] Better multi-threading support.
5408 * src/truetype/ttinterp.c (TT_Load_Context): Reset glyph zone
5411 2010-11-23 John Tytgat <John.Tytgat@esko.com>
5413 * src/psaux/t1decode.c (t1_decoder_parse_charstring): Expand
5414 start_point, check_points, add_point, add_point1, close_contour
5416 Remove add_contour macro.
5417 Return error code from t1_builder_start_point and
5418 t1_builder_check_points when there was one (instead of returning 0).
5420 2010-11-22 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5422 [truetype] Identify the tricky fonts by cvt/fpgm/prep checksums.
5423 Some Latin TrueType fonts are still expected to be unhinted.
5424 Fix Savannah bug #31645.
5426 * src/truetype/ttobjs.c (tt_check_trickyness): Divided to...
5427 (tt_check_trickyness_family): this checking family name, and
5428 (tt_check_trickyness_sfnt_ids): this checking cvt/fpgm/prep.
5429 (tt_get_sfnt_checksum): Function to retrieve the sfnt checksum
5430 for specified subtable even if cleared by lazy PDF generators.
5431 (tt_synth_sfnt_checksum): Function to calculate the checksum.
5433 2010-11-18 Werner Lemberg <wl@gnu.org>
5435 [truetype] Fix `loca' handling for inconsistent number of glyphs.
5436 Reported by Johnson Y. Yan <yinsen_yan@foxitsoftware.com>.
5438 * src/truetype/ttpload.c (tt_face_load_loca): While sanitizing,
5439 handle case where `loca' is the last table in the font.
5441 2010-11-18 Werner Lemberg <wl@gnu.org>
5443 [sfnt] Ignore all errors while loading `OS/2' table.
5444 Suggested by Johnson Y. Yan <yinsen_yan@foxitsoftware.com>.
5446 * src/sfnt/sfobjs.c (sfnt_load_face): Do it.
5448 2010-11-18 Johnson Y. Yan <yinsen_yan@foxitsoftware.com>
5450 [type1] Fix matrix normalization.
5452 * src/type1/t1load.c (parse_font_matrix): Handle sign of scaling
5455 2010-11-18 Werner Lemberg <wl@gnu.org>
5457 [type1] Improve guard against malformed data.
5458 Based on a patch submitted by Johnson Y. Yan
5459 <yinsen_yan@foxitsoftware.com>
5461 * src/type1/t1load.c (read_binary_data): Check `size'.
5463 2010-11-17 Werner Lemberg <wl@gnu.org>
5465 [sfnt] While tracing, output table checksums also.
5467 * src/sfnt/ttload.c (tt_face_load_font_dir): Do it.
5469 2010-11-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5471 [UVS] Fix `find_variant_selector_charmap', Savannah bug #31545.
5473 Since 2010-07-04, `find_variant_selector_charmap' returns
5474 the first cmap subtable always under rogue-compatible
5475 configuration, it causes NULL pointer dereference and
5476 make UVS-related functions crashed.
5478 * src/base/ftobjs.c (Fix find_variant_selector_charmap):
5479 Returns UVS cmap correctly.
5481 2010-11-01 Alexei Podtelezhnikov <apodtele@gmail.com>
5483 [ftsmooth] Improve rendering.
5485 * src/smooth/ftsmooth.c (gray_render_conic): Since version 2.4.3,
5486 cubic deviations have been estimated _after_ UPSCALE, whereas
5487 conic ones have been evaluated _before_ UPSCALE, which produces
5488 inferior rendering results. Fix this.
5489 Partially undo change from 2010-10-15 by using ONE_PIXEL/4; this has
5490 been tested with demo images sent to the mailing list. See
5492 http://lists.gnu.org/archive/html/freetype-devel/2010-10/msg00055.html
5494 and later mails in this thread.
5496 2010-10-28 Werner Lemberg <wl@gnu.org>
5498 [ftraster] Minor fixes.
5500 Reported by Tom Bishop <wenlin@wenlin.com>.
5502 * src/raster/ftraster.c (ULong): Remove unused typedef.
5503 (TWorker): Remove unused variable `precision_mask'.
5505 2010-10-28 Werner Lemberg <wl@gnu.org>
5507 [ftraster] Fix rendering.
5509 Problem reported by Tom Bishop <wenlin@wenlin.com>; see
5510 thread starting with
5512 http://lists.gnu.org/archive/html/freetype/2010-10/msg00049.html
5514 * src/raster/ftraster.c (Line_Up): Replace FMulDiv with SMulDiv
5515 since the involved multiplication exceeds 32 bits.
5517 2010-10-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5519 Revert a change of `_idx' type in `FTC_CACHE_LOOKUP_CMP'.
5521 * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): Revert
5522 the type of `_idx' from FT_PtrDist (by previous change)
5523 to original FT_UFast, to match with FT_CacheRec.
5525 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5527 [cache] Change the hash types to FT_PtrDist.
5529 On LLP64 platforms (e.g. Win64), FT_ULong (32-bit)
5530 variables are inappropriate to calculate hash values
5531 from the memory address (64-bit). The hash variables
5532 are extended from FT_ULong to FT_PtrDist and new
5533 hashing macro functions are introduced. The hash
5534 values on 16-bit memory platforms are changed, but
5535 ILP32 and LP64 are not changed. The hash value in
5536 the cache subsystem is not reverted to the memory
5537 address, so using signed type FT_PtrDist is safe.
5539 * src/cache/ftccache.h (_FTC_FACE_ID_HASH): New hash
5540 function to replace `FTC_FACE_ID_HASH' for portability.
5541 * src/cache/ftcmanag.h (FTC_SCALER_HASH): Replace
5542 `FTC_FACE_ID_HASH' by `_FTC_FACE_ID_HASH'.
5543 * src/cache/ftccmap.c (FTC_CMAP_HASH): Ditto.
5545 * src/cache/ftccache.h (FTC_NodeRec): The type of the
5546 member `hash' is changed from FT_UInt32 to FT_PtrDist.
5548 * src/cache/ftccache.h (FTC_Cache_Lookup): The type of the
5549 argument `hash' is changed from FT_UInt32 to FT_PtrDist.
5550 (FTC_Cache_NewNode): Ditto.
5551 * src/cache/ftccache.c (ftc_cache_add): Ditto.
5552 (FTC_Cache_Lookup): Ditto. (FTC_Cache_NewNode): Ditto.
5553 * src/cache/ftcglyph.h (FTC_GCache_Lookup): Ditto.
5554 * src/cache/ftcglyph.c (FTC_GCache_Lookup): Ditto.
5556 * src/cache/ftcbasic.c (FTC_ImageCache_Lookup): The type
5557 of the internal variable `hash' is changed to FT_PtrDist
5558 from FT_UInt32. (FTC_ImageCache_LookupScaler): Ditto.
5559 (FTC_SBitCache_Lookup): Ditto.
5560 (FTC_SBitCache_LookupScaler): Ditto.
5561 * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Ditto.
5562 * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): Ditto.
5563 Also the type of the internal variable `_idx' is changed to
5564 FT_PtrDist from FT_UFast for better pointer calculation.
5566 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5568 [cache] Hide internal macros incompatible with LLP64.
5570 `FT_POINTER_TO_ULONG', `FTC_FACE_ID_HASH', and
5571 `FTC_IMAGE_TYPE_HASH' are enclosed by
5572 FT_CONFIG_OPTION_OLD_INTERNALS and hidden from
5575 For the history of these macros, see the investigation:
5576 http://lists.gnu.org/archive/html/freetype/2010-10/msg00022.html
5578 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5580 Change the type of `FT_MEM_VAL' from FT_ULong to FT_PtrDist.
5582 On LLP64 platforms (e.g. Win64), unsigned long (32-bit)
5583 cannot cover the memory address (64-bit). `FT_MEM_VAL' is
5584 used for hashing only and not dereferred, so using signed
5585 type FT_PtrDist is safe.
5587 * src/base/ftdbgmem.c (FT_MEM_VAL): Change the type of the
5588 return value from FT_ULong to FT_PtrDist.
5589 (ft_mem_table_resize): The type of hash is changed to
5590 FT_PtrDist. (ft_mem_table_get_nodep): Ditto.
5592 2010-10-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5594 Replace "%lx" for memory address by "%p", LLP64 platforms.
5596 On LLP64 platforms (e.g. Win64), long (32-bit) cannot cover
5597 the memory address (64-bit). Also the casts from the pointer
5598 type to long int should be removed to preserve the address
5601 * src/raster/ftraster.c (New_Profile): Replace "%lx" by "%p".
5602 (End_Profile) Ditto.
5603 * src/truetype/ttinterp.c (Init_Context): Ditto.
5605 2010-10-15 Alexei Podtelezhnikov <apodtele@gmail.com>
5607 Fix thinko in spline flattening.
5609 FT_MAX_CURVE_DEVIATION is dependent on the value of ONE_PIXEL.
5611 * src/smooth/ftgrays.c (FT_MAX_CURVE_DEVIATION): Remove it and
5612 replace it everywhere with ONE_PIXEL/8.
5614 2010-10-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5616 [raccess] Skip unrequired resource access rules by Darwin VFS.
5618 When a resource fork access rule by Darwin VFS could open the
5619 resource fork but no font is found in it, the rest of rules
5620 by Darwin VFS are skipped. It reduces the warnings of the
5621 deprecated resource fork access method by recent Darwin kernel.
5622 Fix MacPorts ticket #18859:
5623 http://trac.macports.org/ticket/18859
5625 * src/base/ftobjs.c (load_face_in_embedded_rfork):
5626 When `FT_Stream_New' returns FT_Err_Cannot_Open_Stream, it
5627 means that the file is possible to be `fopen'-ed but zero-sized.
5628 Also there is a case that the resource fork is not zero-sized,
5629 but no supported font exists in it. If a rule by Darwin VFS
5630 falls into such cases, there is no need to try other Darwin VFS
5631 rules anymore. Such cases are marked by vfs_rfork_has_no_font.
5632 If it is TRUE, the Darwin VFS rules are skipped.
5634 2010-10-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5636 [raccess] Grouping resource access rules based on Darwin VFS.
5638 MacOS X/Darwin kernel supports a few tricky methods to access
5639 a resource fork via ANSI C or POSIX interface. Current resource
5640 fork accessor tries all possible methods to support all kernels.
5641 But if a method could open a resource fork but no font is found,
5642 there is no need to try other methods older than tested method.
5643 To determine whether the rule index is for Darwin VFS, a local
5644 function `ftrfork.c::raccess_rule_by_darwin_vfs' is introduced.
5645 To use this function in ftobjs.c etc but it should be inlined,
5646 it is exposed by ftbase.h.
5648 * src/base/ftrfork.c (FT_RFork_Rule): New enum type to identify
5649 the rules to access the resource fork.
5650 (raccess_guess_rec): New structure to bind the rule function and
5652 (FT_Raccess_Guess): The list of the rule functions is replaced by
5653 (raccess_guess_table): This. This is exposed to be used by other
5654 intra module functions.
5655 (raccess_rule_by_darwin_vfs): A function to return a boolean
5656 if the rule specified by the rule index is based on Darwin VFS.
5658 2010-10-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5660 Prevent to open a FT_Stream for zero-sized file on non-Unix.
5662 builds/unix/ftsystem.c prevents to open an useless stream from
5663 zero-sized file and returns FT_Err_Cannot_Open_Stream, but the
5664 stream drivers for ANSI C, Amiga and VMS return useless streams.
5665 For cross-platform consistency, all stream drivers should act
5668 * src/base/ftsystem.c (FT_Stream_Open): If the size of the opened
5669 file is zero, FT_Err_Cannot_Open_Stream is returned.
5670 * builds/amiga/src/base/ftsystem.c (FT_Stream_Open): Ditto.
5671 * src/vms/ftsystem.c (FT_Stream_Open): Ditto.
5673 2010-10-12 Werner Lemberg <wl@gnu.org>
5675 [truetype] Fix Savannah bug #31310.
5677 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Protect against
5678 invalid `runcnt' values.
5680 2010-10-08 Chris Liddell <chris.liddell@artifex.com>
5682 [sfnt] Fix Savannah bug #31275.
5684 * src/sfnt/ttpost.c: Include FT_INTERNAL_DEBUG_H.
5686 2010-10-06 Werner Lemberg <wl@gnu.org>
5688 [truetype] Improve error handling of `SHZ' bytecode instruction.
5689 Problem reported by Chris Evans <scarybeasts@gmail.com>.
5691 * src/truetype/ttinterp.c (Ins_SHZ): Check `last_point'.
5693 2010-10-05 Werner Lemberg <wl@gnu.org>
5695 Fix Savannah bug #31253.
5696 Patch submitted by an anonymous reporter.
5698 * configure: Use `awk' instead of `sed' to manipulate output of `ls
5701 2010-10-03 Werner Lemberg <wl@gnu.org>
5703 * Version 2.4.3 released.
5704 =========================
5707 Tag sources with `VER-2-4-3'.
5709 * docs/CHANGES: Updated.
5711 * docs/VERSION.DLL: Update documentation and bump version number to
5714 * README, Jamfile (RefDoc),
5715 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5716 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5717 builds/win32/visualc/freetype.dsp,
5718 builds/win32/visualc/freetype.vcproj,
5719 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5720 builds/win32/visualce/freetype.vcproj,
5721 builds/win32/visualce/index.html,
5722 builds/wince/vc2005-ce/freetype.vcproj,
5723 builds/wince/vc2005-ce/index.html,
5724 builds/wince/vc2008-ce/freetype.vcproj,
5725 builds/wince/vc2008-ce/index.html: s/2.4.2/2.4.3/, s/242/243/.
5727 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 3.
5729 * builds/unix/configure.raw (version_info): Set to 12:1:6.
5731 2010-10-03 Werner Lemberg <wl@gnu.org>
5733 Avoid `configure' issues with symbolic links.
5734 Based on a patch from Alexander Stohr <Alexander.Stohr@gmx.de>.
5736 * configure: Compare directories using `ls -id'.
5737 Check existence of `reference' subdirectory before creating it.
5739 2010-10-02 Werner Lemberg <wl@gnu.org>
5741 [sfnt] Fix Savannah bug #31088 (sort of).
5743 * src/sfnt/ttload.c (tt_face_load_maxp): Always allocate at least 64
5746 2010-10-02 Werner Lemberg <wl@gnu.org>
5748 [smooth] Fix splitting of cubics for negative values.
5750 Reported by Róbert Márki <gsmiko@gmail.com>; see
5751 http://lists.gnu.org/archive/html/freetype/2010-09/msg00019.html.
5753 * src/smooth/ftgrays.c (gray_render_cubic): Fix thinko.
5755 2010-10-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5757 [truetype] Fix Savannah bug #31040.
5759 * src/truetype/ttinterp.c (free_buffer_in_size): Remove.
5760 (TT_RunIns): Updated.
5762 2010-09-20 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5764 [sfnt] Make error message filling NULL names less verbose.
5766 * src/sfnt/ttpost.c (load_format_20): Showing 1 summary message
5767 when we fill `post' names by NULL, instead of per-entry message.
5769 2010-09-20 Graham Asher <graham.asher@btinternet.com>
5770 David Bevan <david.bevan@pb.com>
5772 [smooth] Fix and improve spline flattening.
5774 This fixes the flattening of cubic, S-shaped curves and speeds up
5775 the handling of both the conic and cubic arcs.
5777 See the discussions on the freetype-devel mailing list in late
5778 August and September 2010 for details.
5780 * src/smooth/ftgrays.c (FT_MAX_CURVE_DEVIATION): New macro.
5781 (TWorker): Remove `conic_level' and `cubic_level' elements.
5782 (gray_render_conic): Simplify algorithm.
5783 (gray_render_cubic): New algorithm; details are given in the code
5785 (gray_convert_glyph): Remove heuristics.
5787 2010-09-19 Werner Lemberg <wl@gnu.org>
5791 * src/cff/cffload.c (cff_charset_compute_cids): `charset->sids[i]'
5793 (cff_index_access_element): Don't use additions in comparison.
5794 * src/sfnt/ttpost.c (load_format_20): Make `post_limit' of type
5796 Don't use additions in comparison.
5797 Improve tracing messages.
5798 (load_format_25, load_post_names): Make `post_limit' of type
5801 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5803 [cff] Truncate the element length at the end of the stream.
5804 See Savannah bug #30975.
5806 * src/cff/cffload.c (cff_index_access_element): `off2', the offset
5807 to the next element is truncated at the end of the stream to prevent
5808 invalid I/O. As `off1', the offset to the requested element has
5809 been checked by `FT_STREAM_SEEK', `off2' should be checked
5812 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5814 [cff] Ignore CID > 0xFFFFU.
5815 See Savannah bug #30975.
5817 * src/cff/cffload.c (cff_charset_compute_cids): Ignore CID if
5818 greater than 0xFFFFU. CFF font spec does not mention maximum CID in
5819 the font, but PostScript and PDF spec define that maximum CID is
5822 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5824 [cff] Make trace message in` cff_charset_load' verbose.
5825 See Savannah bug #30975.
5827 * src/cff/cffload.c (cff_charset_load): Report the original `nleft'
5828 and truncated `nleft'.
5830 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5832 [cff] Correct `max_cid' from CID array length to max CID.
5833 See Savannah bug #30975.
5835 * src/cff/cffload.c (cff_charset_compute_cids): Don't increment
5836 max_cid after detecting max CID. The array CFF_Charset->cids is
5837 allocated by max_cid + 1.
5838 (cff_charset_cid_to_gindex): Permit CID is less than or equal to
5839 CFF_Charset->max_cid.
5840 * src/cff/cffobjs.c (cff_face_init): FT_Face->num_glyphs is
5841 calculated as CFF_Charset->max_cid + 1.
5843 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5845 [truetype] Sanitize the broken offsets in `loca'.
5846 See Savannah bug #31040.
5848 * src/truetype/ttpload.c (tt_face_get_location): If `pos1', the
5849 offset to the requested entry in `glyf' exceeds the end of the
5850 table, return offset=0, length=0. If `pos2', the offset to the next
5851 entry in `glyf' exceeds the end of the table, truncate the entry
5852 length at the end of `glyf' table.
5854 2010-09-19 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5856 [sfnt] Prevent overrunning in `post' table parser.
5857 See Savannah bug #31040.
5859 * src/sfnt/ttpost.c (load_post_names): Get the length of `post'
5860 table and pass the limit of `post' table to `load_format_20' and
5862 (load_format_20): Stop the parsing when we reached at the limit of
5863 `post' table. If more glyph names are required, they are filled by
5866 2010-09-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5868 [truetype] Don't duplicate size->twilight structure to be freed.
5869 See Savannah bug #31040 for detail.
5871 * src/truetype/ttinterp.c (free_buffer_in_size): Don't duplicate
5872 FT_GlyphZoneRec size->twilight to be freed. If duplicated,
5873 `FT_FREE' erases the duplicated pointers only and leave original
5874 pointers. They can cause the double-free crash when the burst
5875 errors occur in TrueType interpreter and `free_buffer_in_size' is
5878 2010-09-15 Werner Lemberg <wl@gnu.org>
5880 Make bytecode debugging with FontForge work again.
5882 * src/truetype/ttinterp.c (TT_RunIns): Don't call
5883 `free_buffer_in_size' in case of error if a debugger is active.
5885 2010-09-14 Werner Lemberg <wl@gnu.org>
5887 Improve tracing messages.
5889 * src/truetype/ttinterp.c (TT_RunIns): Improve wording of tracing
5891 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Add
5893 * src/truetype/ttgload.c (tt_loader_init): Add tracing message.
5894 * src/cache/ftcsbits.c (ftc_snode_load): Emit tracing message if
5895 glyph doesn't fit into a small bitmap container.
5897 2010-09-13 Werner Lemberg <wl@gnu.org>
5899 Fix minor issues reported by <muktha.narayan@wipro.com>.
5901 * src/autofit/aflatin.c (af_latin_compute_stem_width): Remove
5902 redundant conditional check.
5903 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Ditto.
5904 * src/cff/cffload.c (cff_encoding_load): Remove conditional check
5905 which always evaluates to `true'.
5906 * src/pshinter/pshalgo.c (ps_glyph_interpolate_strong_points):
5908 * src/truetype/ttinterp.c (Ins_IUP): Ditto.
5909 * src/cid/cidgload.c (cid_slot_load_glyph): Don't check for NULL if
5910 value is already dereferenced.
5911 * src/winfonts/winfnt.c (FNT_Load_Glyph): Fix check of `face'.
5913 2010-08-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5915 Ignore the environmental setting of LIBTOOL.
5916 Patch is suggested by Adrian Bunk, to prevent unexpected
5917 reflection of environmental LIBTOOL. See:
5918 http://savannah.nongnu.org/patch/?7290
5920 * builds/unix/unix-cc.in: LIBTOOL is unconditionally set to
5921 $(FT_LIBTOOL_DIR)/libtool. FT_LIBTOOL_DIR is set to $(BUILD_DIR)
5923 * configure: When configured for the building out of source tee,
5924 FT_LIBTOOL_DIR is set to $(OBJ_DIR).
5926 2010-08-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5928 [truetype] Decrease the trace level catching the interpreter error.
5930 * src/truetype/ttinterp.c (TT_RunIns): Decrease the trace level
5931 showing the error when the interpreter returns with an error,
5932 from` FT_TRACE7' to `FT_TRACE1'.
5934 2010-08-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5936 [truetype] Prevent bytecode reuse after the interpretation error.
5938 * src/truetype/ttinterp.c (free_buffer_in_size): New function to
5939 free the buffer allocated during the interpretation of this glyph.
5940 (TT_RunIns): Unset FT_Face->size->{cvt_ready,bytecode_ready} if
5941 an error occurs in the bytecode interpretation. The interpretation
5942 of invalid bytecode may break the function definitions and referring
5943 them in later interpretation is danger. By unsetting these flags,
5944 `fpgm' and `prep' tables are executed again in next interpretation.
5946 This fixes Savannah bug #30798, reported by Robert Święcki.
5948 2010-08-29 Werner Lemberg <wl@gnu.org>
5950 [ftraster] Pacify compiler.
5952 * src/raster/ftraster.c (ft_black_new) [_STANDALONE_]: `memory' is
5955 2010-08-29 Werner Lemberg <wl@gnu.org>
5957 [cff] Allow SIDs >= 65000.
5959 * src/cff/cffload.c (cff_charset_load): Fix change from 2009-03-20:
5960 The threshold for SIDs is not applicable here. I misinterpreted the
5961 `SID values 65000 and above are available for implementation use'
5962 sentence in the CFF specification.
5964 Problem reported by Ivan Ninčić <inincic@pdftron.com>.
5966 2010-08-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5968 Force hinting when the font lacks its familyname.
5970 In Type42 or Type11 font embedded in PostScript & PDF, TrueType sfnt
5971 stream may lack `name' table because they are not required. Hinting
5972 for nameless fonts is safer for PDFs including embedded Chinese
5973 fonts. Written by David Bevan, see:
5975 http://lists.gnu.org/archive/html/freetype-devel/2010-08/msg00021.html
5976 http://lists.freedesktop.org/archives/poppler/2010-August/006310.html
5978 * src/truetype/ttobjs.c (tt_check_trickyness): If a NULL pointer by
5979 nameless font is given, TRUE is returned to enable hinting.
5981 2010-08-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5983 Register yet another tricky TrueType font.
5985 * src/truetype/ttobjs.c (tt_check_trickyness): Add `HuaTianKaiTi?',
5986 a Kaishu typeface paired with `HuaTianSongTi?' by Huatian
5987 Information Industry.
5989 2010-08-17 Teijo Kinnunen <Teijo.Kinnunen@nuance.com>
5991 [cache] Fix Savannah bug #30788.
5993 * src/cache/ftccache.c (FTC_Cache_Clear): Check `cache->buckets' for
5996 2010-08-10 Werner Lemberg <wl@gnu.org>
5998 Try to fix Savannah bug #30717 (and probably #30719 too).
6000 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Add another
6001 overflow test for `width' and `height'.
6003 2010-08-06 Werner Lemberg <wl@gnu.org>
6005 * Version 2.4.2 released.
6006 =========================
6009 Tag sources with `VER-2-4-2'.
6011 * docs/CHANGES: Updated.
6013 * docs/VERSION.DLL: Update documentation and bump version number to
6016 * README, Jamfile (RefDoc),
6017 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
6018 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
6019 builds/win32/visualc/freetype.dsp,
6020 builds/win32/visualc/freetype.vcproj,
6021 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
6022 builds/win32/visualce/freetype.vcproj,
6023 builds/win32/visualce/index.html,
6024 builds/wince/vc2005-ce/freetype.vcproj,
6025 builds/wince/vc2005-ce/index.html,
6026 builds/wince/vc2008-ce/freetype.vcproj,
6027 builds/wince/vc2008-ce/index.html: s/2.4.1/2.4.2/, s/241/242/.
6029 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
6031 * builds/unix/configure.raw (version_info): Set to 12:0:6.
6033 2010-08-06 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6035 Fix Savannah bug #30648.
6037 * src/base/ftobjs.c (FT_Done_Library): Specify the order of font
6038 drivers during the face closing process. Type42 faces should be
6039 closed before TrueType faces, because a Type42 face refers to
6040 another internal TrueType face which is created from sfnt[] array on
6043 2010-08-06 Yuriy Kaminskiy <yumkam@mail.ru>
6045 [raster] Fix valgrind warning.
6047 * src/raster/ftraster.c (Decompose_Curve) <default>: Access point[0]
6048 only if we don't hit `limit'.
6050 2010-08-06 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6052 Fix Savannah bug #30658.
6054 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check that the total
6055 length of collected POST segments does not overrun the allocated
6058 2010-08-06 Yuriy Kaminskiy <yumkam@mail.ru>
6060 Fix conditional usage of FT_MulFix_i386.
6061 With -ansi flag, gcc does not define `i386', only `__i386__'.
6063 * include/freetype/config/ftconfig.h, builds/unix/ftconfig.in:
6066 2010-08-05 Werner Lemberg <wl@gnu.org>
6068 [truetype] Fix Savannah bug #30657.
6070 * src/truetype/ttinterp.c (BOUNDSL): New macro.
6071 Change `BOUNDS' to `BOUNDSL' where appropriate.
6073 * src/truetype/ttinterp.h (TT_ExecContextRec): Fix type of
6076 2010-08-05 Werner Lemberg <wl@gnu.org>
6078 [type42] Fix Savannah bug #30656.
6080 * src/type42/t42parse.c (t42_parse_sfnts): Protect against negative
6084 2010-08-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6086 [cff] Don't use any values in decoder after parsing error.
6088 * src/cff/cffgload.c (cff_slot_load): Skip the evaluations
6089 of the values in decoder, if `cff_decoder_parse_charstrings'
6092 2010-08-04 Werner Lemberg <wl@gnu.org>
6094 Fix Savannah bug #30644.
6096 * src/base/ftstream.c (FT_Stream_EnterFrame): Fix comparison.
6098 2010-08-04 Werner Lemberg <wl@gnu.org>
6100 `make devel' fails if FT_CONFIG_OPTION_OLD_INTERNALS is set.
6102 * devel/ftoption.h: Synchronize with
6103 include/freetype/config/ftoption.h.
6105 2010-08-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6107 [cff] Improve stack overflow test.
6109 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Check stack
6110 after execution of operations too.
6112 2010-07-18 Werner Lemberg <wl@gnu.org>
6114 Add reference counters and to FT_Library and FT_Face objects.
6116 * include/freetype/freetype.h (FT_Reference_Face): New function.
6117 * include/freetype/ftmodapi.h (FT_Rererence_Library): New function.
6119 * include/freetype/internal/ftobjs.h (FT_Face_InternalRec,
6120 FT_LibraryRec): New field `refcount'.
6122 * src/base/ftobjs.c (FT_Open_Face, FT_New_Library): Handle
6124 (FT_Reference_Face, FT_Reference_Library): Implement new functions.
6125 (FT_Done_Face, FT_Done_Library): Handle `refcount'.
6127 * docs/CHANGES: Updated.
6129 2010-07-18 Werner Lemberg <wl@gnu.org>
6131 * Version 2.4.1 released.
6132 =========================
6135 Tag sources with `VER-2-4-1'.
6137 * docs/CHANGES: Updated.
6139 * docs/VERSION.DLL: Update documentation and bump version number to
6142 * README, Jamfile (RefDoc),
6143 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
6144 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
6145 builds/win32/visualc/freetype.dsp,
6146 builds/win32/visualc/freetype.vcproj,
6147 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
6148 builds/win32/visualce/freetype.vcproj,
6149 builds/win32/visualce/index.html,
6150 builds/wince/vc2005-ce/freetype.vcproj,
6151 builds/wince/vc2005-ce/index.html,
6152 builds/wince/vc2008-ce/freetype.vcproj,
6153 builds/wince/vc2008-ce/index.html: s/2.4.0/2.4.1/, s/240/241/.
6155 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
6157 * builds/unix/configure.raw (version_info): Set to 11:1:5.
6159 2010-07-17 Werner Lemberg <wl@gnu.org>
6161 [cff] Final try to fix `hintmask' and `cntrmask' limit check.
6163 Problem reported by Tobias Wolf <towolf@gmail.com>.
6165 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
6166 <cff_op_hintmask>: Sigh. I'm apparently too silly to fix this
6167 correctly in less than three tries.
6169 2010-07-12 Werner Lemberg <wl@gnu.org>
6171 * Version 2.4.0 released.
6172 =========================
6175 Tag sources with `VER-2-4-0'.
6177 * docs/CHANGES: Updated.
6179 * docs/VERSION.DLL: Update documentation and bump version number to
6182 * README, Jamfile (RefDoc),
6183 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
6184 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
6185 builds/win32/visualc/freetype.dsp,
6186 builds/win32/visualc/freetype.vcproj,
6187 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
6188 builds/win32/visualce/freetype.vcproj,
6189 builds/win32/visualce/index.html,
6190 builds/wince/vc2005-ce/freetype.vcproj,
6191 builds/wince/vc2005-ce/index.html,
6192 builds/wince/vc2008-ce/freetype.vcproj,
6193 builds/wince/vc2008-ce/index.html: s/2.3.12/2.4.0/, s/2312/240/.
6195 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 4.
6196 (FREETYPE_PATCH): Set to 0.
6198 * builds/unix/configure.raw (version_info): Set to 11:0:5.
6200 2010-07-12 Werner Lemberg <wl@gnu.org>
6202 Remove C++ warnings.
6204 */*: Initialize pointers where necessary to make g++ happy.
6206 2010-07-12 malc <av1474@comtv.ru>
6207 Richard Henderson <rth@redhat.com>
6209 Fix type-punning issues with C++.
6211 * include/freetype/internal/ftmemory.h (FT_ASSIGNP) [__cplusplus]:
6212 Emulate a `typeof' operator with an inline template which uses
6215 2010-07-11 Werner Lemberg <wl@gnu.org>
6217 Fix C++ compilation issue.
6219 * src/tools/apinames.c (names_dump) <OUTPUT_WATCOM_LBC>: Fix
6220 type of `dot' variable.
6222 2010-07-10 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6224 Fix another case reported in Savannah bug #30373.
6225 Permit a face for Type1, Type42 and CFF without charmap,
6226 patch by Tor Andersson.
6228 * src/type1/t1objs.c (T1_Face_Init): Reset the error if it
6229 is FT_Err_No_Unicode_Glyph_Name.
6230 * src/type42/t42objs.c (T42_Face_Init): Ditto.
6231 * src/cff/cffobjs.c (cff_face_init): Ditto.
6233 2010-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6235 Use defined macros to set {platform,encoding}_id.
6237 * src/bdf/bdfdrivr.c: Include ttnameid.h and use macros to
6238 set charmap.{platfom,encoding}_id.
6239 * src/pcf/pcfdrivr.c: Ditto.
6240 * src/winfonts/winfnt.c: Ditto.
6241 * src/type1/t1objs.c: Ditto.
6242 * src/type42/t42objs.c: Ditto.
6243 * src/cff/cffobjs.c: Ditto.
6244 * src/pfr/pfrobjs.c: Ditto.
6246 2010-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6248 Fix Savannah bug #30373.
6249 Too serious check of errors by `FT_CMap_New' since 2010-07-04
6250 is fixed. Reported by Tor Andersson.
6252 * include/freetype/fterrdef.h
6253 (PSnames_Err_No_Unicode_Glyph_Name): New error code to
6254 indicate the Unicode charmap synthesis failed because
6255 no Unicode glyph name is found.
6257 * src/psnames/psmodule.c (ps_unicodes_init): Return
6258 PSnames_Err_No_Unicode_Glyph_Name when no Unicode glyph name
6259 is found in the font.
6260 * src/cff/cffcmap.c (cff_cmap_unicode_init): Return
6261 CFF_Err_No_Unicode_Glyph_Name when no SID is available.
6263 * src/type1/t1objs.c (T1_Face_Init): Proceed if `FT_CMap_New'
6264 is failed by the lack of Unicode glyph name.
6265 * src/type42/t42objs.c (T42_Face_Init): Ditto.
6266 * src/cff/cffobjs.c (cff_face_init): Ditto.
6268 2010-07-09 Ken Sharp <ken.sharp@artifex.com>
6270 Make ftraster.c compile in stand-alone mode with MSVC compiler.
6272 * src/raster/ftmisc.h (FT_Int64) [_WIN32, _WIN64]: Fix typedef
6273 since there is no `inttypes.h' for MSVC.
6275 2010-07-08 Werner Lemberg <wl@gnu.org>
6277 [truetype] Fix Savannah bug #30361.
6279 * src/truetype/ttinterp.c (Ins_IUP): Fix bounds check.
6281 2010-07-06 Werner Lemberg <wl@gnu.org>
6285 * src/cff/cffload.c (cff_index_get_pointers): Initialize
6288 2010-07-05 Eugene A. Shatokhin <spectre@ispras.ru>
6290 Fix Savannah bug #27648.
6292 * src/base/ftobjs.c (ft_remove_renderer, FT_Add_Module): Call
6293 `raster_done' only if we have an outline glyph format.
6295 2010-07-05 Werner Lemberg <wl@gnu.org>
6297 Fix Savannah bug #30030.
6299 * builds/win32/*/freetype.vcproj: Add ftxf86.c.
6301 2010-07-05 Werner Lemberg <wl@gnu.org>
6303 [cff] Next try to fix `hintmask' and `cntrmask' limit check.
6305 Problem reported by malc <av1474@comtv.ru>.
6307 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
6308 <cff_op_hintmask>: It is possible that there is just a single byte
6309 after the `hintmask' or `cntrmask', e.g., a `return' instruction.
6311 2010-07-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6313 Restrict the number of the charmaps in a rogue-compatible mode.
6314 Fix for Savannah bug #30059.
6316 * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Replace `16' the
6317 minimum character code passed by a legacy rogue client by...
6318 * include/freetype/config/ftoption.h (FT_MAX_CHARMAP_CACHEABLE):
6319 This. It is undefined when FT_CONFIG_OPTION_OLD_INTERNALS is
6320 undefined (thus the rogue client compatibility is not required).
6322 * src/cff/cffobjs.c (cff_face_init): Abort the automatic
6323 selection or synthesis of Unicode cmap subtable when the charmap
6324 index exceeds FT_MAX_CHARMAP_CACHEABLE.
6325 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Issue error message
6326 when the charmap index exceeds FT_MAX_CHARMAP_CACHEABLE.
6328 * src/base/ftobjs.c (find_unicode_charmap): When Unicode charmap
6329 is found after FT_MAX_CHARMAP_CACHEABLE, ignore it and search
6331 (find_variant_selector_charmap): When UVS charmap is found after
6332 FT_MAX_CHARMAP_CACHEABLE, ignore it and search earlier one.
6333 (FT_Select_Charmap): When a charmap matching with requested
6334 encoding but after FT_MAX_CHARMAP_CACHEABLE, ignore and search
6336 (FT_Set_Charmap): When a charmap matching with requested
6337 charmap but after FT_MAX_CHARMAP_CACHEABLE, ignore and search
6339 (FT_Get_Charmap_Index): When a requested charmap is found
6340 after FT_MAX_CHARMAP_CACHEABLE, return the inverted charmap
6343 2010-07-04 Werner Lemberg <wl@gnu.org>
6345 TrueType hinting is no longer patented.
6347 * include/freetype/config/ftoption.h, devel/ftoption.h
6348 (TT_CONFIG_OPTION_BYTECODE_INTERPRETER): Define.
6349 (TT_CONFIG_OPTION_UNPATENTED_HINTING): Undefine.
6351 * docs/CHANGES, docs/INSTALL, include/freetype/freetype.h: Updated.
6352 * docs/TRUETYPE, docs/PATENTS: Removed.
6354 2010-07-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6356 Check error value by `FT_CMap_New'.
6358 * src/cff/cffobjs.c (cff_face_init): Check error value by
6360 * src/pfr/pfrobjs.c (pfr_face_init): Ditto.
6361 * src/type1/t1jobjs.c (T1_Face_Init): Ditto.
6362 * src/type42/t42jobjs.c (T42_Face_Init): Ditto.
6364 2010-07-03 Werner Lemberg <wl@gnu.org>
6366 Make ftgrays.c compile stand-alone again.
6368 * src/smooth/ftgrays.c [_STANDALONE_]: Include `stddef.h'.
6369 (FT_INT_MAX, FT_PtrDist)[_STANDALONE_]: Define.
6371 2010-07-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6373 Additional fix for Savannah bug #30306.
6375 * src/base/ftobjs.c (Mac_Read_POST_Resource): If the type of the
6376 POST fragment is 0, the segment is completely ignored. The declared
6377 length of the segment is not cared at all. According to Adobe
6378 Technical Note 5040, type 0 segment is a comment only and should not
6379 be loaded for the interpreter. Reported by Robert Święcki.
6381 2010-07-01 Werner Lemberg <wl@gnu.org>
6383 [truetype] Protect against code range underflow.
6385 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF): Don't allow
6388 2010-07-01 Werner Lemberg <wl@gnu.org>
6390 [truetype] Add rudimentary tracing for bytecode instructions.
6392 * src/truetype/ttinterp.c (opcode_name) [FT_DEBUG_LEVEL_TRACE]: New
6394 (TT_RunIns): Trace opcodes.
6396 2010-06-30 Werner Lemberg <wl@gnu.org>
6398 [smooth] Fix Savannah bug #30263.
6400 * src/smooth/ftgrays.c (gray_render_span): Use cast to `unsigned
6401 int' to avoid integer overflow.
6403 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Use smaller
6404 threshold values for `width' and `height'. This is not directly
6405 related to the bug fix but makes sense anyway.
6407 2010-07-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6409 Initial fix for Savannah bug #30306.
6411 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check `rlen', the
6412 length of fragment declared in the POST fragment header, and prevent
6413 an underflow in length calculation. Some fonts set the length to
6414 zero in spite of the existence of a following 16bit `type'.
6415 Reported by Robert Święcki.
6417 2010-07-01 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6419 Additional fix for Savannah bug #30248 and #30249.
6421 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check the buffer size
6422 during gathering PFB fragments embedded in LaserWriter PS font for
6423 Macintosh. Reported by Robert Święcki.
6425 2010-06-30 Alexei Podtelezhnikov <apodtele@gmail.com>
6427 Minor optimizations by avoiding divisions.
6429 * src/sfnt/ttkern.c (tt_face_load_kern, tt_face_get_kerning):
6430 Replace divisions with multiplication in comparisons.
6432 2010-06-29 Werner Lemberg <wl@gnu.org>
6434 Fix minor tracing issues.
6436 * src/cff/cffgload.c, src/truetype/ttgload.c: Adjust tracing levels.
6438 2010-06-27 Werner Lemberg <wl@gnu.org>
6440 [cff] Really fix `hintmask' and `cntrmask' limit check.
6442 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
6443 <cff_op_hintmask>: Fix thinko and handle tracing also.
6445 2010-06-27 Werner Lemberg <wl@gnu.org>
6447 Fix valgrind warning.
6449 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Initialize
6452 2010-06-27 Werner Lemberg <wl@gnu.org>
6454 [cff] Fix memory leak.
6456 * src/cff/cffgload.c (cff_operator_seac): Free charstrings even in
6459 2010-06-27 Werner Lemberg <wl@gnu.org>
6461 [cff] Protect against invalid `hintmask' and `cntrmask' operators.
6463 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
6464 <cff_op_hintmask>: Ensure that we don't exceed `limit' while parsing
6465 the bit masks of the `hintmask' and `cntrmask' operators.
6467 2010-06-26 Werner Lemberg <wl@gnu.org>
6469 Fix PFR change 2010-06-24.
6471 * src/pfr/pfrgload.c (pfr_glyph_load_simple): Really protect against
6474 2010-06-26 Werner Lemberg <wl@gnu.org>
6476 Improve PFR tracing messages.
6478 * src/pfr/pfrgload.c (pfr_glyph_load_rec): Emit tracing messages for
6479 simple and compound glyph offsets.
6481 2010-06-26 Werner Lemberg <wl@gnu.org>
6483 Fix last PFR change.
6485 * src/pfr/pfrobjs.c (pfr_face_init): Fix rejection logic.
6487 2010-06-26 Werner Lemberg <wl@gnu.org>
6489 [sfnt] Fix Savannah bug #30262.
6491 * src/sfnt/ttload.c (tt_face_load_maxp): Limit `maxComponentDepth'
6492 arbitrarily to 100 to avoid stack exhaustion.
6494 2010-06-26 Werner Lemberg <wl@gnu.org>
6496 Add some memory checks (mainly for debugging).
6498 * src/base/ftstream.c (FT_Stream_EnterFrame): Exit with error
6499 if the frame size is larger than the stream size.
6501 * src/base/ftsystem.c (ft_ansi_stream_io): Exit with error if
6502 seeking a position larger than the stream size.
6504 2010-06-25 Werner Lemberg <wl@gnu.org>
6506 [pfr] Fix Savannah bug #30261.
6508 * src/pfr/pfrobjs.c (pfr_face_init): Reject fonts which contain
6509 neither outline nor bitmap glyphs.
6511 2010-06-25 Werner Lemberg <wl@gnu.org>
6513 [cff] Fix Savannah bug #30254.
6515 * src/cff/cffload.c (cff_index_get_pointers): Do sanity check for
6518 2010-06-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6520 Initial fix for Savannah bug #30248 and #30249.
6522 * src/base/ftobjs.c (Mac_Read_POST_Resource): Check the error during
6523 reading a PFB fragment embedded in LaserWriter PS font for Macintosh.
6524 Reported by Robert Święcki.
6526 2010-06-24 Werner Lemberg <wl@gnu.org>
6528 [pcf] Fix Savannah bug #30247.
6530 * src/pcf/pcfread.c (pcf_get_metrics): Disallow (invalid) fonts with
6533 2010-06-24 Graham Asher <graham.asher@btinternet.com>
6535 * src/smooth/ftgrays.c (gray_render_cubic): Fix algorithm.
6536 The previous version was too aggressive, as demonstrated in
6537 http://lists.gnu.org/archive/html/freetype-devel/2010-06/msg00020.html.
6539 2010-06-24 Werner Lemberg <wl@gnu.org>
6541 */*: Use module specific error names where appropriate.
6543 2010-06-24 Werner Lemberg <wl@gnu.org>
6545 [sfnt] Fix Savannah bug #30236.
6547 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Improve check for pointer
6550 2010-06-24 Werner Lemberg <wl@gnu.org>
6552 [pfr] Fix Savannah bug #30235.
6554 * src/pfr/pfrgload.c (pfr_glyph_load_simple): Protect against
6555 invalid indices if there aren't any coordinates for indexing.
6557 2010-06-24 Werner Lemberg <wl@gnu.org>
6559 [bdf]: Font properties are optional.
6561 * src/bdf/bdflib.c (_bdf_readstream): Use special error code to
6562 indicate a redo operation.
6563 (_bdf_parse_start): Handle `CHARS' keyword here too and pass current
6564 input line to `_bdf_parse_glyph'.
6566 2010-06-23 Werner Lemberg <wl@gnu.org>
6568 [bdf] Fix Savannah bug #30220.
6570 * include/freetype/fterrdef.h
6571 (BDF_Err_Missing_Fontboundingbox_Field): New error code.
6573 * src/bdf/bdflib.c (_bdf_parse_start): Check for missing
6574 `FONTBOUNDINGBOX' field.
6575 Avoid memory leak if there are multiple `FONT' lines (which is
6576 invalid but doesn't hurt).
6578 2010-06-21 Werner Lemberg <wl@gnu.org>
6580 [pfr] Fix Savannah bug #30168.
6582 * src/pfr/pfrgload.c (pfr_glyph_load_compound): Limit the number of
6583 subglyphs to avoid endless recursion.
6585 2010-06-20 Werner Lemberg <wl@gnu.org>
6587 [psaux] Fix Savannah bug #30145.
6589 * src/psaux/psobjs.c (t1_builder_add_contour): Protect against
6590 `outline == NULL' which might happen in invalid fonts.
6592 2010-06-19 Werner Lemberg <wl@gnu.org>
6594 [bdf] Fix Savannah bug #30135.
6596 * src/bdf/bdflib.c (_bdf_list_join): Don't modify value in static
6598 (_bdf_parse_glyph): Avoid memory leak in case of error.
6600 2010-06-15 Werner Lemberg <wl@gnu.org>
6602 [autofit] Fix Savannah bug #30108.
6604 * src/autofit/afglobal.c (af_face_globals_compute_script_coverage):
6605 Properly mask AF_DIGIT bit in comparison.
6607 2010-06-11 Werner Lemberg <wl@gnu.org>
6609 [pshinter] Fix Savannah bug #30106.
6611 Point numbers for FreeType's implementation of hinting masks are
6612 collected before the final number of points of a glyph has been
6613 determined; in particular, the code for handling the `endchar'
6614 opcode can reduce the number of points.
6616 * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Assure that
6617 `end_point' is not larger than `glyph->num_points'.
6619 2010-06-11 Werner Lemberg <wl@gnu.org>
6621 [cff]: Improve debugging output.
6623 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
6624 <cff_op_hintmask>: Implement it.
6626 2010-06-10 Graham Asher <graham.asher@btinternet.com>
6628 ftgrays: Speed up rendering of small cubic splines.
6630 * src/smooth/ftgrays.c (gray_render_cubic): Implement new,
6631 simplified algorithm to find out whether the spline can be replaced
6632 with two straight lines. See this thread for more:
6634 http://lists.gnu.org/archive/html/freetype-devel/2010-06/msg00000.html
6636 2010-06-09 Werner Lemberg <wl@gnu.org>
6638 [cff] Fix Savannah bug #30082.
6640 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
6641 <cff_op_callothersubr>: Protect against stack underflow.
6643 2010-06-08 Werner Lemberg <wl@gnu.org>
6645 [cff] Fix Savannah bug #30053.
6647 * src/cff/cffparse.c (cff_parse_real): Handle border case where
6648 `fraction_length' has value 10.
6650 2010-06-07 Werner Lemberg <wl@gnu.org>
6652 Fix Savannah bug #30052.
6653 This bug has been introduced with commit 2415cbf3.
6655 * src/base/ftobjs.c (FT_Get_First_Char, FT_Get_Next_Char): Protect
6656 against endless loop in case of corrupted font header data.
6658 2010-05-26 Werner Lemberg <wl@gnu.org>
6660 Remove unused variable.
6663 * src/autofit/afhints.c (af_glyph_hints_reload): Remove unused
6664 variable `first' in first block.
6666 2010-05-22 Werner Lemberg <wl@gnu.org>
6668 Fix various memory problems found by linuxtesting.org.
6670 * src/base/ftgxval.c (FT_TrueTypeGX_Free, FT_ClassicKern_Free),
6671 src/base/ftotval.c (FT_OpenType_Free), src/base/ftpfr.c
6672 (ft_pfr_check): Check `face'.
6674 * src/base/ftobjs.c (FT_Get_Charmap_Index): Check `charmap' and
6676 (FT_Render_Glyph): Check `slot->face'.
6677 (FT_Get_SubGlyph_Info): Check `glyph->subglyphs'.
6679 2010-05-22 Werner Lemberg <wl@gnu.org>
6681 autofit: Remove dead code.
6682 Suggested by Graham.
6684 * src/autofit/afhints.c (af_glyph_hints_compute_inflections):
6686 (af_glyph_hints_reload): Remove third argument.
6689 2010-05-21 Bram Tassyns <bramt@enfocus.be>
6691 [cff] Fix Savannah bug #27987.
6693 * src/cff/cffobjs.c (remove_subset_prefix): New function.
6694 (cff_face_init): Use it to adjust `cffface->family_name'.
6696 2010-05-20 Werner Lemberg <wl@gnu.org>
6698 TrueType: Make FreeType ignore maxSizeOfInstructions in `maxp'.
6700 Acroread does the same.
6702 * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Call
6703 `Update_Max' to adjust size of instructions array if necessary and
6704 add a rough safety check.
6706 (load_truetype_glyph): Save `loader->byte_len' before recursive
6709 * src/truetype/ttinterp.h, src/truetype/ttinterp.c (Update_Max):
6710 Declare it as FT_LOCAL.
6712 2010-05-18 Hongbo Ni <hongbo@njstar.com>
6714 Apply Savannah patch #7196.
6716 * src/cff/cffgload.c (cff_slot_load): Prevent crash if CFF subfont
6717 index is out of range.
6719 2010-05-11 Werner Lemberg <wl@gnu.org>
6721 * docs/formats.txt: Give pointer to PCF documentation.
6722 Information provided by Alan Coopersmith
6723 <alan.coopersmith@oracle.com>.
6725 2010-05-10 Ken Sharp <ken.sharp@artifex.com>
6727 [psaux] Fix Savannah bug #29846.
6729 Previously we discovered fonts which used `setcurrentpoint' to set
6730 the initial point of a contour to 0,0. This caused FreeType to
6731 raise an error, because the `setcurrentpoint' operator is only
6732 supposed to be used with the results from an OtherSubr subroutine.
6734 This was fixed by simply ignoring the error and carrying on.
6736 Now we have found a font which uses setcurrentpoint to actually
6737 establish a non-zero point for a contour during the course of a
6738 glyph program. FWIW, these files may be produced by an application
6739 called `Intaglio' on the Mac, when converting TrueType fonts to
6742 The fix allows the new invalid behaviour, the old invalid behaviour
6743 and real proper usage of the operator to work the same way as Adobe
6744 interpreters apparently do.
6746 * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Make
6747 `setcurrentpoint' use the top two elements of the stack to establish
6748 unconditionally the current x and y coordinates.
6750 Make the `flex' subroutine handling (OtherSubr 0) put the current
6751 x,y coordinates onto the stack, instead of two dummy uninitialised
6754 2010-04-14 Ken Sharp <ken.sharp@artifex.com>
6756 [psaux] Fix Savannah bug #29444.
6758 * src/psaux/psobjs.c (t1_builder_start_point): Accept (invalid)
6759 `lineto' immediately after `hsbw', in accordance with Acrobat, GS,
6762 2010-04-14 Michał Cichoń <thedmd@artifexmundi.com>
6764 [psaux] Fix Savannah bug #27999.
6766 * src/cache/ftcmanag.c (FTC_Manager_RemoveFaceID): Only remove
6767 selected entry, not all.
6769 2010-04-06 Jonathan Kew <jfkthame@gmail.com>
6771 [truetype] Add overflow check to `fvar' table.
6773 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Check axis and instance
6776 2010-04-05 Ken Sharp <ken.sharp@artifex.com>
6778 [raster] Fix Savannah bug #29335.
6780 * src/raster/ftraster.c (Line_Up): Use slow multiplication to
6781 prevent overflow. This shouldn't have any serious impact on speed,
6784 2010-04-05 Werner Lemberg <wl@gnu.org>
6786 Add new function `FT_Library_SetLcdFilterWeights'.
6788 This is based on code written by Lifter
6789 <http://unixforum.org/index.php?showuser=11691>. It fixes
6790 FreeDesktop bug #27386.
6792 * src/base/ftlcdfil.c (FT_Library_SetLcdFilterWeights): New
6795 * include/freetype/ftlcdfil.h: Updated.
6797 * docs/CHANGES: Updated.
6799 2010-04-01 John Tytgat <John.Tytgat@esko.com>
6801 [truetype] Fix Savannah bug #29404.
6803 * src/truetype/ttgload.c: Revert change 2752bd1a (check on bit 1
6804 of `head' table of TrueType fonts).
6806 2010-03-14 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6808 Fix `multi build' for Tytgat's CFF driver improvement.
6810 * src/base/cffload.h (cff_index_get_name): Added.
6812 2010-03-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6814 Remove duplicated inclusion of `FT_OUTLINE_H' in ftobjs.c.
6816 * src/base/ftobjs.c: Remove 2nd inclusion of `FT_OUTLINE_H'.
6818 2010-03-11 Chris Liddell <chris.liddell@artifex.com>
6820 [raster] Fix Savannah bug #27442.
6822 * src/raster/ftraster.c (ft_black_reset): Fix `buffer_size'.
6824 2010-03-09 Werner Lemberg <wl@gnu.org>
6826 [cff] Remove unused variable.
6829 * src/cff/cffparse.c (cff_parse_real): Remove `rest'.
6831 2010-03-02 John Tytgat <John.Tytgat@esko.com>
6833 [cff] Improve CFF string (especially glyphname) lookup performance.
6835 We do this by avoiding memory allocation and file I/O. This is
6836 Savannah patch #7104.
6838 * src/cff/cfftypes.h: Include PS cmaps service and
6839 FT_INTERNAL_POSTSCRIPT_HINTS_H.
6840 (CFF_SubFontRec): Remove `num_local_subrs'.
6841 (CFF_FontRec): Add `num_strings', `strings', and `string_pool'
6843 Remove `string_index' and `num_global_subrs' fields.
6844 Use real types instead of `void' for `pshinter' and `psnames' fields.
6846 * src/cff/cffload.c: Don't include PS cmaps service.
6847 (cff_index_get_pointers): Add `pool' parameter which allows to
6848 insert an extra NUL character for each String INDEX entry.
6849 (cff_index_get_name): Make it a local function.
6850 (cff_index_get_string): New function.
6851 (cff_subfont_load): Updated.
6852 (cff_font_load): Initialize `num_strings', `strings', and
6853 `string_pool' fields in the `CFF_FontRec' structure.
6854 (cff_index_get_sid_string): Use `cff_index_get_string' instead of
6855 `cff_index_get_name'.
6856 (cff_font_done): Updated.
6858 * src/cff/cffload.h: Don't include PS cmaps service.
6859 (cff_index_get_string): Added.
6860 (cff_index_get_sid_string): Updated.
6862 * src/cff/cffobjs.c: Don't include PS cmaps service and
6863 FT_INTERNAL_POSTSCRIPT_HINTS_H.
6864 (cff_size_get_globals_funcs, cff_slot_init): Updated.
6865 (cff_face_init): Follow `cff_index_get_name',
6866 `cff_index_get_string', and `cff_index_get_sid_string' changes.
6868 * src/cff/cffcmap.c (cff_sid_free_glyph_name): Removed.
6869 (cff_sid_to_glyph_name): Use `cff_index_get_cid_string'.
6870 (cff_cmap_unicode_init): Updated.
6872 * src/cff/cffdrivr.c: Don't include PS cmap service.
6873 (cff_get_glyph_name): Avoid unnecessary lookup for POSTSCRIPT_CMAPS
6875 (cff_get_glyph_name, cff_ps_get_font_info, cff_get_ros): Follow API
6876 `cff_index_get_sid_string' change.
6877 (cff_get_name_index): Use `cff_index_get_string' instead of
6878 `cff_index_get_name'.
6880 * src/cff/cffgload.c: Don't include FT_INTERNAL_POSTSCRIPT_HINTS_H.
6881 (cff_decoder_init, cff_decoder_prepare): Updated.
6883 2010-02-27 Werner Lemberg <wl@gnu.org>
6886 Suggested by Behdad.
6888 * src/base/ftobjs.c (FT_Get_First_Char): Don't use a loop since we
6889 call FT_Get_Next_Char anyway if necessary.
6891 2010-02-26 Behdad Esfahbod <behdad@behdad.org>
6893 Improve handling of invalid glyph indices in char->index functions.
6895 * src/base/ftobjs.c (FT_Get_First_Char, FT_Get_Next_Char): Use a
6898 2010-02-18 Chris Liddell <chris.liddell@artifex.com>
6900 [truetype] Fix Savannah bug #28905.
6902 Initialize phantom points before calling the incremental interface
6903 to update glyph metrics.
6905 * src/truetype/ttgload.c (tt_get_metrics_incr_overrides)
6906 [FT_CONFIG_OPTION_INCREMENTAL]: New function, split off from...
6907 (tt_get_metrics): This.
6909 (load_truetype_glyph): Use tt_get_metrics_incr_overrides.
6911 ----------------------------------------------------------------------------
6913 Copyright 2010-2013 by
6914 David Turner, Robert Wilhelm, and Werner Lemberg.
6916 This file is part of the FreeType project, and may only be used, modified,
6917 and distributed under the terms of the FreeType project license,
6918 LICENSE.TXT. By continuing to use, modify, or distribute this file you
6919 indicate that you have read the license and understand and accept it
6924 version-control: never