blob: ff20967ade5c81030ce9f8cbe60c30fcad8e0b44 [file] [log] [blame]
Werner Lemberg16217e52015-04-01 13:13:56 +020012015-04-01 Werner Lemberg <wl@gnu.org>
2
Werner Lemberga2fa6572015-04-01 15:55:41 +02003 [autofit] Call dumper functions for tracing.
4
5 * src/autofit/afcjk.c (af_cjk_hints_apply): Remove dead code.
6 * src/autofit/afhints.c (af_glyph_hints_dump_points): Minor
7 improvement.
8 * src/autofit/afmodule.c (af_autofitter_load_glyph): Implement it.
9
102015-04-01 Werner Lemberg <wl@gnu.org>
11
Werner Lembergdb8df792015-04-01 13:30:55 +020012 [autofit] Make debugging stuff work again.
13
14 The interface to ftgrid was broken in the series of commits starting
15 with
16
17 [autofit] Allocate AF_Loader on the stack instead of AF_Module.
18
19 from 2015-01-14.
20
21 * src/autofit/afmodule.c (_af_debug_hints_rec) [FT_DEBUG_AUTOFIT]:
22 Use a global AF_GlyphHintsRec object for debugging.
23 (af_autofitter_done, af_autofitter_load_glyph): Updated.
24
25 * src/autofit/afloader.c (af_loader_init, af_loader_done): Updated.
26
272015-04-01 Werner Lemberg <wl@gnu.org>
28
Werner Lemberg16217e52015-04-01 13:13:56 +020029 * src/autofit/afhints.c (af_glyph_hints_done): Fix minor thinko.
30
Werner Lemberg10e2bb82015-03-29 13:32:47 +0200312015-03-29 Werner Lemberg <wl@gnu.org>
32
Werner Lembergf353a382015-03-29 14:47:49 +020033 [cff] Fix Savannah bug #44629.
34
35 * src/cff/cf2font.h (CF2_MAX_SUBR), src/cff/cffgload.h
36 (CFF_MAX_SUBRS_CALLS): Set to 16.
37
382015-03-29 Werner Lemberg <wl@gnu.org>
39
Werner Lemberg10e2bb82015-03-29 13:32:47 +020040 [type1, truetype] Make the MM API more flexible w.r.t. `num_coords'.
41
42 This commit allows `num_coords' to be larger or smaller than the
43 number of available axes while selecting a design instance, either
44 ignoring excess data or using defaults if data is missing.
45
46 * src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design):
47 Implement it.
48
49 * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design,
50 T1_Set_Var_Design): Ditto.
51
522015-03-29 Werner Lemberg <wl@gnu.org>
Werner Lemberg8ce30262015-03-27 08:33:47 +010053
Werner Lembergdd5d6d72015-03-29 10:04:22 +020054 [type1] Minor.
55
56 * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design): Use
57 FT_THROW.
58 (T1_Set_Var_Design): Use T1_MAX_MM_AXIS and FT_THROW.
59
602015-03-27 Werner Lemberg <wl@gnu.org>
61
Werner Lemberg8ce30262015-03-27 08:33:47 +010062 [cff] Trace charstring nesting levels.
63
64 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdCALLGSUBR,
65 cf2_cmdCALLSUBR, cf2_cmdRETURN>: Implement it.
66
67 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
68 <cff_op_callsubr, cff_op_callgsubr, cff_op_return>: Ditto.
69
Alexei Podtelezhnikovdac56442015-03-21 23:30:16 -0400702015-03-21 Alexei Podtelezhnikov <apodtele@gmail.com>
71
72 [base] Optimize `FT_Angle_Diff'.
73
74 Under normal circumstances we are usually close to the desired range
75 of angle values, so that the remainder is not really necessary.
76
77 * src/base/fttrigon.c (FT_Angle_Diff): Use loops instead of remainder.
78
79 * src/autofit/aftypes.h (AF_ANGLE_DIFF): Ditto in the unused macro.
80
Werner Lemberg6cc425d2015-03-21 06:51:07 +0100812015-03-21 Werner Lemberg <wl@gnu.org>
82
83 [truetype] Improve `gvar' handling.
84
85 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Correctly handle
86 single-element runs. Cf. glyph `Q' in Skia.ttf with weights larger
87 than the default.
88
Alexei Podtelezhnikov2d7284e2015-03-20 21:34:19 -0400892015-03-20 Alexei Podtelezhnikov <apodtele@gmail.com>
90
91 * src/base/fttrigon.c (FT_Vector_Rotate): Minor refactoring.
92
Alexei Podtelezhnikov6a171722015-03-17 22:43:08 -0400932015-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
94
95 Fix Savannah bug #44412 (part 2).
96
97 * src/base/fttrigon.c (FT_Sin, FT_Cos, FT_Tan): Call `FT_Vector_Unit'.
98
Werner Lemberg06339952015-03-11 06:30:23 +0100992015-03-11 Werner Lemberg <wl@gnu.org>
100
Werner Lembergd3284462015-03-11 16:45:58 +0100101 [autofit] Add support for Arabic script.
102
103 Thanks to Titus Nemeth <tn@tntypography.eu> for guidance!
104
105 * src/autofit/afblue.dat: Add blue zone data for Arabic.
106
107 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
108
109 * src/autofit/afscript.h: Add Arabic standard characters.
110
111 * src/autofit/afranges.c: Add Arabic data.
112
113 * src/autofit/afstyles.h: Add Arabic data.
114
115 * docs/CHANGES: Document it.
116
1172015-03-11 Werner Lemberg <wl@gnu.org>
118
Werner Lemberga4516382015-03-11 08:09:13 +0100119 Rename `svxf86nm.h' to `svfntfmt.h'; update related symbols.
120
121 * include/internal/ftserv.h (FT_SERVICE_XFREE86_NAME_H): Renamed
122 to...
123 (FT_SERVICE_FONT_FORMAT_H): This.
124
125 * include/internal/services/svfntfmt.h (FT_XF86_FORMAT_*): Renamed
126 to ...
127 (FT_FONT_FORMAT_*): This.
128
129 src/base/ftfntfmt.c, src/bdf/bdfdrivr.c, src/cff/cffdrivr.c,
130 src/cid/cidriver.c, src/pcf/pcfdrivr.c, src/pfr/pfrdrivr.c,
131 src/truetype/ttdriver.c, src/type1/t1driver.c,
132 src/type42/t42drivr.c, src/winfonts/winfnt.c: Updated.
133
1342015-03-11 Werner Lemberg <wl@gnu.org>
135
Werner Lembergdd7028c2015-03-11 07:45:05 +0100136 [base] Rename `FT_XFREE86_H' to `FT_FONT_FORMATS_H'.
137
138 * include/config/ftheader.h: Implement it.
139 * src/base/ftfntfmt.c, docs/CHANGES: Updated.
140
1412015-03-11 Werner Lemberg <wl@gnu.org>
142
Werner Lembergf4d1c112015-03-11 07:32:58 +0100143 [base] Rename `FT_Get_X11_Font_Format' to `FT_Get_Font_Format'.
144
145 * include/ftfntfmt.h, src/base/ftfntfmt.c: Implement it.
146
147 * docs/CHANGES: Updated.
148
1492015-03-11 Werner Lemberg <wl@gnu.org>
150
Werner Lembergcb0f7b62015-03-11 06:51:27 +0100151 Fix automatic copyright updating.
152
153 * src/tools/update-copyright: Make scanning of `no-copyright'
154 actually work.
155
156 * src/tools/no-copyright: Don't include README in general.
157
1582015-03-11 Werner Lemberg <wl@gnu.org>
159
Werner Lemberg06339952015-03-11 06:30:23 +0100160 Rename `ftxf86.[ch]' to `ftfntfmt.[ch]'.
161
162 CMakeLists.txt, builds/amiga/makefile, builds/amiga/makefile.os4,
163 builds/amiga/smakefile, builds/mac/FreeType.m68k_cfm.make.txt,
164 builds/mac/FreeType.m68k_far.make.txt,
165 builds/mac/FreeType.ppc_carbon.make.txt,
166 builds/mac/FreeType.ppc_classic.make.txt, builds/symbian/bld.inf,
167 builds/symbian/freetype.mmp, builds/wince/vc2005-ce/freetype.vcproj,
168 builds/wince/vc2008-ce/freetype.vcproj,
169 builds/windows/vc2005/freetype.vcproj,
170 builds/windows/vc2008/freetype.vcproj,
171 builds/windows/vc2010/freetype.vcxproj,
172 builds/windows/vc2010/freetype.vcxproj.filters,
173 builds/windows/visualc/freetype.dsp,
174 builds/windows/visualc/freetype.vcproj,
175 builds/windows/visualce/freetype.dsp,
176 builds/windows/visualce/freetype.vcproj, docs/INSTALL.ANY,
177 include/config/ftheader.h, include/ftfntfmt.h, modules.cfg,
178 src/base/ftfntfmt.c, vms_make.com: Updated.
179
Alexei Podtelezhnikov6b832c82015-03-10 23:25:49 -04001802015-03-10 Alexei Podtelezhnikov <apodtele@gmail.com>
181
182 Fix Savannah bug #44412 (part 1).
183
184 * src/base/ftstroke.c (ft_stroker_inside): Handle near U-turns.
185
Werner Lembergeee7d8b2015-03-10 11:15:15 +01001862015-03-10 Werner Lemberg <wl@gnu.org>
187
188 [base] Rename `FT_Bitmap_New' to `FT_Bitmap_Init'.
189
190 * include/ftbitmap.h, src/base/ftbitmap.c: Implement it.
191 Update all callers.
192
193 * docs/CHANGES: Updated.
194
Werner Lemberg493cc032015-03-06 05:38:31 +01001952015-03-06 Werner Lemberg <wl@gnu.org>
196
197 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix compiler warning.
198
199 Found by Alexei.
200
Alexei Podtelezhnikovdd7498d2015-03-05 22:51:36 -05002012015-03-05 Alexei Podtelezhnikov <apodtele@gmail.com>
202
203 * src/base/ftstroke.c: Simplify.
204
Werner Lemberg328b7922015-03-04 08:40:23 +01002052015-03-04 Werner Lemberg <wl@gnu.org>
206
207 [truetype] Some fixes and code refactoring in `ttgxvar.c'.
208
209 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Fix return value
210 of `point_cnt' if two bytes are read.
211 Use a more vertical coding style.
212 (ft_var_readpackeddeltas): Use FT_UInt for `delta_cnt' parameter.
213 Use a more vertical coding style.
214
Werner Lemberga374c9c2015-03-03 11:23:45 +01002152015-03-03 Werner Lemberg <wl@gnu.org>
216
217 [autofit] Fix Savannah bug #44241.
218
219 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Reject glyphs
220 with less than 3 points.
221
Werner Lemberga07029e2015-03-02 06:54:08 +01002222015-03-02 Werner Lemberg <wl@gnu.org>
223
224 Simplify `TYPEOF' macro.
225
226 No need for two arguments.
227
228 * include/config/ftconfig.h, builds/unix/ftconfig.in,
229 builds/vms/ftconfig.h (TYPEOF): Updated.
230
231 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
232 src/autofit/afwarp.h (AF_WARPER_FLOOR): Updated.
233
2342015-03-01 Werner Lemberg <wl@gnu.org>
Werner Lemberg4b9234b2015-02-25 06:31:43 +0100235
Werner Lemberg851e8152015-03-01 19:27:09 +0100236 Various compiler warning fixes for `make multi'.
237
238 * src/autofit/afcjk.c (af_cjk_hints_compute_blue_edges),
239 src/autofit/aflatin.c (af_latin_hint_compute_blue_edges,
240 af_latin_hint_edges), src/autofit/aflatin2.c
241 (af_latin2_hints_compute_blue_edges, af_latin2_hint_edges): Declare
242 as `static'.
243
244 * src/cache/ftccmap.c (FTC_CMAP_QUERY_HASH, FTC_CMAP_NODE_HASH):
245 Removed. Unused.
246 * src/cache/ftcimage.c: Include FT_INTERNAL_OBJECTS_H.
247 * src/cache/ftcmanag.c (FTC_LRU_GET_MANAGER): Removed. Unused.
248
249 * src/cff/cf2intrp.c: Include `cf2intrp.h'.
250 * src/cff/cffdrivr.c (PAIR_TAG): Removed. Unused.
251
252 * src/gzip/ftgzip.c (NO_DUMMY_DECL): Removed. Unused.
253
254 * src/psaux/afmparse.c (afm_parser_read_int): Declare as `static'.
255
256 * src/pshinter/pshalgo.c (STRONGER, PSH_ZONE_MIN, PSH_ZONE_MAX):
257 Removed. Unused.
258
259 * src/raster/ftraster.c (Render_Glyph): Declare as `static'.
260
261 * src/sfnt/ttpost.c (load_format_20): Fix signedness warning.
262
263 * src/truetype/ttdriver.c (PAIR_TAG): Removed. Unused.
264 * src/truetype/ttsubpix.c (is_member_of_family_class,
265 is_member_of_style_class): Declare as `static'.
266
267 * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Declare
268 as `static'.
269 * src/type1/t1load.c (mm_axis_unmap, mm_weights_unmap): Declare as
270 `static'.
271 (T1_FIELD_COUNT): Removed. Unused.
272 * src/type1/t1parse.h (T1_Done_Table): Removed. Unused.
273
274 * src/type42/t42parse.c (T1_Done_Table): Removed. Unused.
275
2762015-02-25 Werner Lemberg <wl@gnu.org>
277
Werner Lemberg04c22372015-02-25 11:20:20 +0100278 [psaux] Signedness fixes.
279
280 * include/internal/psaux.h, src/psaux/afmparse.c,
281 src/psaux/afmparse.h, src/psaux/psconv.c, src/psaux/psobjs.c,
282 src/psaux/t1cmap.c, src/psaux/t1decode.c: Apply.
283
2842015-02-25 Werner Lemberg <wl@gnu.org>
285
Werner Lembergd25ec162015-02-25 09:19:59 +0100286 [otvalid] Signedness fixes.
287
288 * src/otvalid/otvcommn.c, src/otvalid/otvgdef.c,
289 src/otvalid/otvgpos.c, src/otvalid/otvgsub.c, src/otvalid/otvmath.c:
290 Apply.
291
2922015-02-25 Werner Lemberg <wl@gnu.org>
293
Werner Lemberg5c9d9bf2015-02-25 08:13:40 +0100294 * src/bzip2/ftbzip2.c (ft_bzip2_alloc): Signedness fix.
295
2962015-02-25 Werner Lemberg <wl@gnu.org>
297
Werner Lemberg83d41812015-02-25 08:10:58 +0100298 [lzw] Signedness fixes.
299
300 * src/lzw/ftzopen.c, src/lzw/ftzopen.h: Apply.
301
3022015-02-25 Werner Lemberg <wl@gnu.org>
303
Werner Lemberg17b62912015-02-25 07:53:09 +0100304 [gxvalid] Signedness fixes.
305
306 * src/gxvalid/gxvbsln.c, src/gxvalid/gxvcommn.c,
307 src/gxvalid/gxvcommn.h, src/gxvalid/gxvjust.c,
308 src/gxvalid/gxvkern.c, src/gxvalid/gxvlcar.c, src/gxvalid/gxvmort.c,
309 src/gxvalid/gxvmort1.c, src/gxvalid/gxvmort2.c,
310 src/gxvalid/gxvmorx.c, src/gxvalid/gxvmorx1.c,
311 src/gxvalid/gxvmorx2.c, src/gxvalid/gxvopbd.c,
312 src/gxvalid/gxvprop.c, src/gxvalid/gxvtrak.c: Apply.
313
3142015-02-25 Werner Lemberg <wl@gnu.org>
315
Werner Lemberg24e4e962015-02-25 06:57:16 +0100316 [cache] Signedness fixes.
317
318 * src/cache/ftcbasic.c, src/cache/ftccmap.c, src/cache/ftcimage.c,
319 src/cache/ftcmanag.c, src/cache/ftcsbits.c: Apply.
320
3212015-02-25 Werner Lemberg <wl@gnu.org>
322
Werner Lemberg559727d2015-02-25 06:55:00 +0100323 Change dimension fields in `FTC_ImageTypeRec' to unsigned type.
324
325 This doesn't break ABI.
326
327 * include/ftcache.h (FTC_ImageTypeRec): Use unsigned types for
328 `width' and `height'.
329
330 * docs/CHANGES: Document it.
331
3322015-02-25 Werner Lemberg <wl@gnu.org>
333
Werner Lemberg4b9234b2015-02-25 06:31:43 +0100334 [cache] Don't use `labs'.
335
336 This is the only place in FreeType where this function was used.
337
338 * include/config/ftstdlib.h (ft_labs): Remove.
339
340 * src/cache/ftcimage.c (ftc_inode_weight): Replace `ft_labs' with
341 `FT_ABS'.
342
Werner Lemberg4d1f7af2015-02-23 07:04:36 +01003432015-02-23 Werner Lemberg <wl@gnu.org>
344
Werner Lemberg3aaebe32015-02-23 08:20:27 +0100345 [cache] Replace `FT_PtrDist' with `FT_Offset'.
346
347 * src/cache/ftccache.h (FTC_NodeRec): `FT_Offset' (a.k.a. `size_t')
348 is a better choice for `hash' to hold a pointer than `FT_PtrDist'
349 (a.k.a. `ptrdiff_t'), especially since the latter is signed,
350 causing zillions of signedness warnings. [Note that `hash' was of
Werner Lemberg17b62912015-02-25 07:53:09 +0100351 type `FT_UInt32' before the change to `FT_PtrDist'.]
Werner Lemberg3aaebe32015-02-23 08:20:27 +0100352 Update all users.
353
354 * src/cache/ftcbasic.c, src/cache/ftccache.c, src/cache/ftccmap.c,
355 src/cache/ftcglyph.c, src/cache/ftcglyph.h: Updated.
356
3572015-02-23 Werner Lemberg <wl@gnu.org>
358
Werner Lemberg4d1f7af2015-02-23 07:04:36 +0100359 [smooth, raster] Re-enable standalone compilation.
360
361 * src/raster/ftraster.c (FT_RENDER_POOL_SIZE, FT_MAX)
362 [_STANDALONE_]: Define macros.
363
364 * src/smooth/ftgrays.c (FT_RENDER_POOL_SIZE, FT_MAX, FT_ABS,
365 FT_HYPOT) [_STANDALONE_]: Define macros.
366
Werner Lemberg03ccfd02015-02-22 08:25:16 +01003672015-02-22 Werner Lemberg <wl@gnu.org>
368
Werner Lembergcb13e712015-02-23 06:41:52 +0100369 [smooth] Signedness fixes.
370
371 * src/smooth/ftgrays.c, src/smooth/ftsmooth.c: Apply.
372
3732015-02-22 Werner Lemberg <wl@gnu.org>
374
Werner Lemberga974e9a2015-02-22 21:02:13 +0100375 * src/raster/ftraster.c: Use the file's typedefs everywhere.
376
3772015-02-22 Werner Lemberg <wl@gnu.org>
378
Werner Lembergb0ebcdc2015-02-22 20:42:49 +0100379 * src/sfnt/ttpost.c (load_format_20): Fix error tracing message.
380
381 Bug introduced 6 commits earlier.
382
3832015-02-22 Werner Lemberg <wl@gnu.org>
384
Werner Lemberg22b1d5c2015-02-22 20:41:03 +0100385 [pshinter] Fix thinko.
386
387 * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Correctly
388 check `count'.
389 Bug introduced two commits earlier.
390
3912015-02-22 Werner Lemberg <wl@gnu.org>
392
Werner Lembergca96fe02015-02-22 20:05:04 +0100393 [raster] Signedness fixes.
394
395 * src/raster/ftraster.c, src/raster/ftrend1.c: Apply.
396
3972015-02-22 Werner Lemberg <wl@gnu.org>
398
Werner Lemberg452066c2015-02-22 15:59:02 +0100399 [pshinter] Signedness fixes.
400
401 * src/pshinter/pshalgo.c, src/pshinter/pshglob.c,
402 src/pshinter/pshrec.c: Apply.
403
4042015-02-22 Werner Lemberg <wl@gnu.org>
405
Werner Lemberg41c2ed82015-02-22 15:57:47 +0100406 [pshinter] Use macros for (unsigned) flags, not enumerations.
407
408 * src/pshinter/pshalgo.h (PSH_Hint_Flags): Replace with macros.
409 Updated.
410 * src/pshinter/pshrec.h (PS_Hint_Flags): Replace with macros.
411
4122015-02-22 Werner Lemberg <wl@gnu.org>
413
Werner Lemberg25c2f882015-02-22 15:54:31 +0100414 * src/pshinter/pshrec.c: Simplify.
415 (ps_hints_open, ps_hints_stem): Remove switch statement.
416
4172015-02-22 Werner Lemberg <wl@gnu.org>
418
Werner Lemberg01f08422015-02-22 12:03:28 +0100419 [sfnt] Signedness fixes.
420
421 * src/sfnt/pngshim.c, src/sfnt/sfobjs.c, src/sfnt/ttcmap.c,
422 src/sfnt/ttkern.c, src/sfnt/ttload.c, src/sfnt/ttpost.c,
423 src/sfnt/ttsbit.c: Apply.
424 * src/sfnt/sfdriver.c: Apply.
425 (sfnt_get_ps_name): Simplify.
426
4272015-02-22 Werner Lemberg <wl@gnu.org>
428
Werner Lemberg3c374c82015-02-22 09:16:53 +0100429 [bdf] Signedness fixes.
430
431 * src/bdf/bdf.h, src/bdf/bdfdrivr.c, src/bdf/bdfdrivr.h,
432 src/bdf/bdflib.c: Apply.
433
4342015-02-22 Werner Lemberg <wl@gnu.org>
435
Werner Lembergb13945a2015-02-22 09:15:47 +0100436 * src/bdf/bdflib.c (_bdf_atous): New function.
437 (_bdf_parse_glyphs, _bdf_parse_start): Use it.
438
4392015-02-22 Werner Lemberg <wl@gnu.org>
440
Werner Lemberg03ccfd02015-02-22 08:25:16 +0100441 [pcf] Signedness fixes.
442
443 * src/pcf/pcf.h, src/pcf/pcfdrivr.c: Apply.
444 * src/pcf/pcfread.c: Apply.
445 (pcf_get_encodings): Ignore invalid negative encoding offsets.
446
Werner Lemberg633a7292015-02-21 07:02:01 +01004472015-02-21 Werner Lemberg <wl@gnu.org>
448
Werner Lemberg3d7e53f2015-02-21 11:30:54 +0100449 * src/winfonts/winfnt.c: Signedness fixes.
450
4512015-02-21 Werner Lemberg <wl@gnu.org>
452
Werner Lemberg7b6b4172015-02-21 10:39:34 +0100453 [type42] Signedness fixes.
454
455 * src/type42/t42parse.c, src/type42/t42parse.h,
456 src/type42/t42types.h: Apply.
457
4582015-02-21 Werner Lemberg <wl@gnu.org>
459
Werner Lemberg8bfffb42015-02-21 09:52:29 +0100460 [pfr] Signedness fixes.
461
462 * src/pfr/pfrdrivr.c, src/pfr/pfrgload.c, src/pfr/pfrload.c,
463 src/pfr/pfrload.h, src/pfr/pfrobjs.c, src/pfr/pfrsbit.c,
464 src/pfr/pfrtypes.h: Apply.
465
4662015-02-21 Werner Lemberg <wl@gnu.org>
467
Werner Lemberg633a7292015-02-21 07:02:01 +0100468 [cff] Minor signedness fixes related to last commit.
469
470 * src/cff/cf2ft.c, src/cff/cf2intrp.c, src/cff/cffgload.c: Apply.
471
Werner Lemberg3a8d0532015-02-20 08:35:32 +01004722015-02-20 Werner Lemberg <wl@gnu.org>
473
Werner Lembergc00b05f2015-02-20 20:42:55 +0100474 [cff] Thinkos in bias handling.
475
476 Only the final result is always positive.
477
478 Bug introduced three commits earlier.
479
480 * src/cff/cffgload.c, src/cff/cffgload.h: Apply.
481
4822015-02-20 Werner Lemberg <wl@gnu.org>
483
Werner Lemberg2bf03eb2015-02-20 20:14:11 +0100484 [cid] Fix signedness issues and emit some better error codes.
485
486 * src/cid/cidgload.c, src/cid/cidload.h, src/cid/cidobjs.c,
487 src/cid/cidparse.h: Apply.
488 * src/cid/cidload.c: Apply.
489 (parse_fd_array): Reject negative values for number of dictionaries.
490 * src/cid/cidparse.c: Apply.
491 (cid_parser_new): Reject negative values for hex data length.
492
4932015-02-20 Werner Lemberg <wl@gnu.org>
494
Werner Lembergeb05bfb2015-02-20 08:37:35 +0100495 [cff] Signedness fixes for new engine.
496
497 * src/cff/cf2arrst.c, src/cff/cf2fixed.h, src/cff/cf2ft.c,
498 src/cff/cf2ft.h, src/cff/cf2hints.c, src/cff/cf2intrp.c: Apply.
499
5002015-02-20 Werner Lemberg <wl@gnu.org>
501
Werner Lemberg3a8d0532015-02-20 08:35:32 +0100502 [cff] Signedness fixes for basic infrastructure and old engine.
503
504 * include/internal/pshints.h, src/cff/cffdrivr.c,
505 src/cff/cffgload.c, src/cff/cffgload.h, src/cff/cffload.c,
506 src/cff/cffobjs.c, src/cff/cffparse.c, src/pshinter/pshrec.c: Apply.
507
Werner Lemberg81e5ff52015-02-19 09:46:48 +01005082015-02-19 Werner Lemberg <wl@gnu.org>
509
Werner Lemberg3a1df3e2015-02-19 15:42:48 +0100510 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Ignore `countSizePairs'.
511
512 This is hard-coded to value 2 in `fvar' version 1.0 (and no newer
513 version exists), but some fonts set it incorrectly.
514
515 Problem reported by Adam Twardoch <adam@fontlab.com>.
516
5172015-02-19 Werner Lemberg <wl@gnu.org>
518
Werner Lemberg93a884c2015-02-19 14:11:16 +0100519 [cff] Emit better error code for invalid private dict size.
520
521 * src/cff/cffparse.c (cff_parse_private_dict): Reject negative
522 values for size and offset.
523
5242015-02-19 Werner Lemberg <wl@gnu.org>
525
Werner Lembergb57bb112015-02-19 10:44:18 +0100526 [autofit] Fix signedness issues.
527
528 * src/autofit/afangles.c, src/autofit/afcjk.c,
529 src/autofit/afglobal.c, src/autofit/afhints.c,
530 src/autofit/aflatin.c, src/autofit/aflatin2.c, src/autofit/afwarp.c,
531 src/autofit/hbshim.c: Apply.
532
5332015-02-19 Werner Lemberg <wl@gnu.org>
534
Werner Lemberg81e5ff52015-02-19 09:46:48 +0100535 [autofit] Use macros for (unsigned) flags, not enumerations.
536
537 This harmonizes with other code in FreeType (and reduces the number
538 of necessary casts to avoid compiler warnings).
539
540 * src/autofit/afblue.hin: Make flag macros unsigned.
541 * src/autofit/afblue.h: Regenerated.
542
543 * src/autofit/afcjk.h: Replace flag enumeration with macros.
544 * src/autofit/afcjk.c: Updated.
545
546 * src/autofit/afhints.h (AF_Flags, AF_Edge_Flags): Replace with
547 macros.
548 * src/autofit/afhints.c: Updated.
549
550 * src/autofit/aflatin.h: Replace flag enumerations with macros.
551 * src/autofit/aflatin.c, src/autofit/aflatin2.c: Updated.
552
553 * src/autofit/aftypes.h (AF_ScalerFlags): Replace with macros.
554
Werner Lemberg6a0ded72015-02-18 08:51:22 +01005552015-02-18 Werner Lemberg <wl@gnu.org>
556
Werner Lemberg3b5f3322015-02-18 11:45:22 +0100557 [type1] Fix signedness issues.
558
559 * include/internal/psaux.h, include/internal/t1types.h,
560 src/psaux/psobjs.c, src/psaux/psobjs.h, src/psaux/t1decode.c,
561 src/type1/t1gload.c, src/type1/t1load.c, src/type1/t1parse.c: Apply.
562
5632015-02-18 Werner Lemberg <wl@gnu.org>
564
Werner Lemberg272e3cd2015-02-18 11:38:46 +0100565 [psaux, type1] Fix minor AFM issues.
566
567 * include/internal/t1types.h (AFM_KernPairRec): Make indices
568 unsigned.
569 Update users.
570 (AFM_FontInfoRec): Make element counters unsigned.
571 Update users.
572 * src/psaux/afmparse.h (AFM_ValueRec): Add union member for unsigned
573 int.
574
575 * src/psaux/afmparse.c (afm_parse_track_kern, afm_parse_kern_pairs):
576 Reject negative values for number of kerning elements.
577
578 * src/type1/t1afm.c, src/tools/test_afm.c: Updated.
579
5802015-02-18 Werner Lemberg <wl@gnu.org>
581
Werner Lemberg6bd7d282015-02-18 09:22:06 +0100582 Don't use `FT_PtrDist' for lengths.
583
584 Use FT_UInt instead.
585
586 * include/internal/psaux.h (PS_Table_FuncsRec, PS_TableRec,
587 T1_DecoderRec): Do it.
588
589 * include/internal/t1types.h (T1_FontRec): Ditto.
590
591 * src/cid/cidload.c (cid_parse_dict): Updated.
592 * src/pfr/pfrload.c (pfr_extra_item_load_font_id): Ditto.
593 * src/psaux/psobjs.c (ps_table_add), src/psaux/psobjs.h: Ditto.
594 * src/type1/t1load.c (parse_blend_axis_types, parse_encoding,
595 parse_chharstrings, parse_dict): Ditto.
596 * src/type42/t42parse.c (t42_parse_encoding, t42_parse_charstrings,
597 t42_parse_dict): Ditto.
598
5992015-02-18 Werner Lemberg <wl@gnu.org>
600
Werner Lemberg6a0ded72015-02-18 08:51:22 +0100601 * src/type1/t1driver.c (t1_ps_get_font_value): Clean up.
602 This handles negative values better, avoiding many casts.
603
Werner Lemberg0a33a392015-02-17 08:03:05 +01006042015-02-17 Werner Lemberg <wl@gnu.org>
605
Werner Lembergd3240c52015-02-17 20:30:36 +0100606 [base] Fix Savannah bug #44284.
607
608 * src/base/ftcalc.c (FT_MulFix): Typos.
609
6102015-02-17 Werner Lemberg <wl@gnu.org>
611
Werner Lemberg1f7a4e12015-02-17 10:17:56 +0100612 [truetype] Finish compiler warning fixes for signedness issues.
613
614 * src/truetype/ttgxvar.c, src/truetype/ttsubpix.c,
615 src/truetype/ttsubpix.h: Apply.
616
6172015-02-17 Werner Lemberg <wl@gnu.org>
618
Werner Lemberg9daea2c2015-02-17 09:27:56 +0100619 * src/truetype/ttsubpix.c: Adding missing `static' keywords.
620
6212015-02-17 Werner Lemberg <wl@gnu.org>
622
Werner Lembergd9c3f152015-02-17 09:21:26 +0100623 [truetype] More signedness fixes.
624
625 * include/internal/tttypes.h, src/truetype/ttinterp.h,
626 src/truetype/ttobjs.h, src/truetype/ttinterp.c,
627 src/truetype/ttobjs.c: Apply.
628
6292015-02-17 Werner Lemberg <wl@gnu.org>
630
Werner Lemberg0a33a392015-02-17 08:03:05 +0100631 [truetype] Various signedness fixes.
632
633 * include/internal/ftgloadr.h, src/truetype/ttpload.c: Apply.
634
635 * src/truetype/ttgload.c: Apply.
636 (TT_Get_VMetrics): Protect against invalid ascenders and descenders
637 while constructing advance height.
638
Werner Lemberg587351b2015-02-16 07:03:22 +01006392015-02-16 Werner Lemberg <wl@gnu.org>
640
Werner Lemberg76abc752015-02-16 22:00:27 +0100641 [base] Finish compiler warning fixes for signedness issues.
642
643 * src/base/ftglyph.c, src/base/ftlcdfil.c, src/base/ftstroke.c:
644 Apply.
645
6462015-02-16 Werner Lemberg <wl@gnu.org>
647
Werner Lemberg10aa8582015-02-16 20:12:54 +0100648 * include/tttables.h (TT_OS2): `fsType' must be FT_UShort.
649
6502015-02-16 Werner Lemberg <wl@gnu.org>
651
Werner Lemberg2e814fc2015-02-16 20:05:08 +0100652 More minor signedness warning fixes.
653
654 * src/base/ftbbox.c, src/base/ftbitmap.c, src/base/fttrigon.c,
655 src/base/ftutil.c: Apply.
656
6572015-02-16 Werner Lemberg <wl@gnu.org>
658
Werner Lemberg82235d02015-02-16 19:35:16 +0100659 Next round of minor compiler warning fixes.
660
661 * include/internal/ftrfork.h (FT_RFork_Ref): Change `offset' member
662 type to `FT_Long'.
663 (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Add `static' keyword.
664
Werner Lemberg3aaebe32015-02-23 08:20:27 +0100665 * include/internal/ftstream.h (FT_Stream_Pos): Return `FT_ULong'.
Werner Lemberg82235d02015-02-16 19:35:16 +0100666
667 * src/base/ftoutln.c, src/base/ftrfork.c, src/base/ftstream.c:
668 Signedess fixes.
669
6702015-02-16 Werner Lemberg <wl@gnu.org>
671
Werner Lemberg3cfa4d12015-02-16 17:59:06 +0100672 Various minor signedness fixes.
673
674 * include/ftadvanc.h, include/internal/ftobjs.h,
675 src/base/ftgloadr.c, src/base/ftobjs.c: Apply.
676
6772015-02-16 Werner Lemberg <wl@gnu.org>
678
Werner Lemberg6f325c22015-02-16 11:31:32 +0100679 New `TYPEOF' macro.
680
681 This helps suppress signedness warnings, avoiding issues with
682 implicit conversion changes.
683
684 * include/config/ftconfig.h, builds/unix/ftconfig.in,
685 builds/vms/ftconfig.h (TYPEOF): Define.
686
687 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
688 src/autofit/afwarp.h (AF_WARPER_FLOOR): Use it.
689
6902015-02-16 Werner Lemberg <wl@gnu.org>
691
Werner Lemberg1f377f02015-02-16 08:37:09 +0100692 * src/base/ftsystem.c: Use casts in standard C function wrappers.
693 (ft_alloc, ft_realloc, ft_ansi_stream_io, FT_Stream_Open): Do it.
694
6952015-02-16 Werner Lemberg <wl@gnu.org>
696
Werner Lemberg0814b802015-02-16 07:29:53 +0100697 Fix Savannah bug #44261.
698
699 * builds/unix/detect.mk (setup) [unix]: Set `CONFIG_SHELL' in the
700 environment also while calling the configure script.
701
7022015-02-16 Werner Lemberg <wl@gnu.org>
703
Werner Lemberg587351b2015-02-16 07:03:22 +0100704 * include/internal/ftmemory.h: Add some `FT_Offset' casts.
705 (FT_MEM_SET, FT_MEM_COPY, FT_MEM_MOVE, FT_ARRAY_ZERO, FT_ARRAY_COPY,
706 FT_MEM_MOVE): Do it.
707
Werner Lemberg6d7d6362015-02-15 12:30:42 +01007082015-02-15 Werner Lemberg <wl@gnu.org>
709
Werner Lemberg48186b82015-02-16 06:37:36 +0100710 [base] Clean up signedness issues in `ftdbgmem.c'.
711
712 Also fix other minor issues.
713
714 * src/base/ftdbgmem.c (FT_MemTableRec): Replace all FT_ULong types
715 with FT_Long for consistency.
716 (ft_mem_primes): Change type to `FT_Int'.
717 (ft_mem_closest_prime, ft_mem_table_set): Updated.
718
719 (ft_mem_debug_panic, ft_mem_debug_alloc, ft_mem_debug_free,
720 ft_mem_debug_realloc): Use `static' keyword and fix signedness
721 warnings where necessary.
722
723 (ft_mem_table_resize, ft_mem_table_new, ft_mem_table_destroy,
724 ft_mem_table_get_nodep, ft_mem_debug_init, FT_DumpMemory): Fix types
725 and add or remove casts to avoid signedness warnings.
726
7272015-02-15 Werner Lemberg <wl@gnu.org>
728
Werner Lemberg6d7d6362015-02-15 12:30:42 +0100729 [base] Clean up signedness in arithmetic functions.
730
731 This makes the code more readable and reduces compiler warnings.
732
733 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round, FT_MulFix,
734 FT_DivFix): Convert input parameters to unsigned, do the
735 computation, then convert the result back to signed.
736 (ft_corner_orientation): Fix casts.
737
Werner Lemberg92359bd2015-02-07 09:47:23 +01007382015-02-07 Werner Lemberg <wl@gnu.org>
739
740 [sfnt] Fix Savannah bug #44184.
741
742 * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir): No
743 longer reject `htmx' and `vmtx' tables with invalid length but
744 sanitize them.
745
Jon Anderson416d8792015-02-06 10:16:45 +01007462015-02-06 Jon Anderson <jon@websupergoo.com>
747
748 [truetype] Fix regression in the incremental glyph loader.
749
750 * src/truetype/ttgload.c (load_truetype_glyph): For incremental
751 fonts, the glyph index may be greater than the number of glyphs
752 indicated, so guard the check with a preprocessor conditional.
753
Werner Lembergb6cb4992015-02-06 08:46:06 +01007542015-02-06 Werner Lemberg <wl@gnu.org>
755
756 [autofit] Fix potential memory leak.
757
758 While this doesn't show up with FreeType, exactly the same code
759 leaks with ttfautohint's modified auto-hinter code (which gets used
760 in a slightly different way).
761
762 It certainly doesn't harm since it is similar to already existing
763 checks in the code for embedded arrays.
764
765 * src/autofit/afhints.c (af_glyph_hints_reload): Set `max_contours'
766 and `max_points' for all cases.
767
Werner Lemberg19146a52015-01-31 11:01:33 +01007682015-01-31 Werner Lemberg <wl@gnu.org>
769
770 [autofit] Add support for Thai script.
771
772 Thanks to Ben Mitchell <ben@rosettatype.com> for guidance with blue
773 zone characters!
774
775 * src/autofit/afblue.dat: Add blue zone data for Thai.
776
777 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
778
779 * src/autofit/afscript.h: Add Thai standard characters.
780
781 * src/autofit/afranges.c: Add Thai data.
782
783 * src/autofit/afstyles.h: Add Thai data.
784
Behdad Esfahbod264b5e42015-01-23 21:23:55 +01007852015-01-23 Behdad Esfahbod <behdad@behdad.org>
786
787 [raster] Handle `FT_RASTER_FLAG_AA' correctly.
788
789 This fixes a breakage caused by the commit `[raster] Remove
790 5-level gray AA mode from monochrome rasterizer.'.
791
Werner Lembergd2c531e2015-01-23 22:37:42 +0100792 Problem reported by Markus Trippelsdorf <markus@trippelsdorf.de>.
Behdad Esfahbod264b5e42015-01-23 21:23:55 +0100793
794 * src/raster/ftraster.c (ft_black_render): Handle
795 `FT_RASTER_FLAG_AA'.
796
797 * src/raster/ftrend1.c (ft_raster1_render): Remove gray AA mode
798 remnants.
799
Werner Lemberg79a5ac62015-01-18 07:30:04 +01008002015-01-18 Werner Lemberg <wl@gnu.org>
801
802 * src/base/ftobjs.c (FT_New_Library): Fix compiler warning.
803
Chris Liddell942aa5f2015-01-18 07:29:48 +01008042015-01-18 Chris Liddell <chris.liddell@artifex.com>
805
806 [raster] Fix Savannah bug #44022.
807
808 Add fallback for glyphs with degenerate bounding boxes.
809
810 If a glyph has only one very narrow feature, the bbox can end up
811 with either the width or height of the bbox being 0, in which case
812 no raster memory is allocated and no attempt is made to render the
813 glyph. This is less than ideal when the drop-out compensation in
814 the rendering code would actually result in the glyph being
815 rendered.
816
817 This problem can be observed with the `I' glyph (gid 47) in the
818 Autodesk RomanS TrueType font.
819
820 * src/raster/ftrend1.c (ft_raster1_render): Add a fallback if either
821 dimension is zero to explicitly round up/down (instead of simply
822 round).
823
Werner Lemberg50be00d2015-01-17 20:38:31 +01008242015-01-17 Werner Lemberg <wl@gnu.org>
825
826 Add some tools to handle yearly copyright notice updates.
827
828 We are now following the GNU guidelines: A new release automatically
829 means that the copyright year of all affected files gets updated; it
830 is no longer used to track years of modification changes.
831
832 * src/tools/update-copyright-year: New Perl script.
833 * src/tools/update-copyright: New shell script that calls
834 `update-copyright-year' on all files.
835 * src/tools/no-copyright: Exceptions that should not be handled by
836 `update-copyright'
837
Werner Lemberg4eff8542015-01-14 20:06:19 +01008382015-01-14 Werner Lemberg <wl@gnu.org>
839
840 * docs/CHANGES: Updated, using a description from Behdad.
841
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +01008422015-01-14 Behdad Esfahbod <behdad@behdad.org>
843
Behdad Esfahbod48c86622015-01-14 19:38:36 +0100844 * src/autofit/afmodule.c (af_autofitter_done): Fix compiler warning.
845
8462015-01-14 Behdad Esfahbod <behdad@behdad.org>
847
Behdad Esfahbod56ddafa2015-01-14 19:36:02 +0100848 [autofit] Add embedded array of segments and edges.
849
850 Avoids multiple mallocs per typical glyphs.
851
852 With this and recent changes to avoid mallocs, the thread-safe
853 stack-based loader is now as fast as the previous model that had one
854 cached singleton.
855
856 * src/autofit/afhints.h (AF_SEGMENTS_EMBEDDED, AF_EDGES_EMBEDDED):
857 New macros.
858 (AF_AxisHintsRec): Add two arrays for segments and edges.
859
860 * src/autofit/afhints.c (af_axis_hints_new_segment): Only allocate
861 data if number of segments exceeds given threshold value.
862 (af_axis_hints_new_edge): Only allocate data if number of edges
863 exceeds given threshold value.
864 (af_glyph_hints_done): Updated.
865
8662015-01-14 Behdad Esfahbod <behdad@behdad.org>
867
Behdad Esfahbod6f16b102015-01-14 19:26:49 +0100868 [autofit] Add embedded arrays for points and contours.
869
870 This avoids at least two malloc calls for typical glyphs.
871
872 * src/autofit/afhints.h (AF_POINTS_EMBEDDED, AF_CONTOURS_EMBEDDED):
873 New macros.
874 (AF_GlyphHintsRec): Add two arrays for contours and points.
875
876 * src/autofit/afhints.c (af_glyph_hints_init, af_glyph_hints_done):
877 Updated.
878 (af_glyph_hints_reload): Only allocate data if number of contours or
879 points exceeds given threshold values.
880
8812015-01-14 Behdad Esfahbod <behdad@behdad.org>
882
Behdad Esfahbodc2733652015-01-14 19:16:12 +0100883 [autofit] Allocate hints object on the stack.
884
885 This avoids one malloc per load.
886
887 * src/autofit/afloader.h (AF_LoaderRec): Change type of `hints' to
888 `AF_GlyphHints'.
889 Update prototype.
890
891 * src/autofit/afloader.c (af_loader_init): Use `AF_GlyphHints'
892 parameter instead of `FT_Memory'.
893 (af_loader_done): Directly reset `load_hints'.
894 (af_loader_load_g): Updated.
895
896 * src/autofit/afmodule.c (af_autofitter_load_glyph): Use local
897 `hints' object.
898
8992015-01-14 Behdad Esfahbod <behdad@behdad.org>
900
Behdad Esfahboda4117fb2015-01-14 19:07:54 +0100901 [autofit] Reuse slot glyph loader.
902
903 No need to create a new glyph loader; we can reuse the one from
904 `slot->internal->loader'. It's hard to tell why it was written that
905 way originally, but new code looks sound and correct to me, and
906 avoids lots of allocations.
907
908 * src/autofit/afloader.c (af_loader_init): Change return type to
909 `void'.
910 Don't call `FT_GlyphLoader_New'.
911 (af_loader_reset): Don't call `FT_GlyphLoader_Rewind'.
912 (af_loader_load_g): Update code to use `internal->loader', which
913 doesn't need copying of data.
914
915 * src/autofit/afloader.h (AF_LoaderRec): Remove `gloader' member.
916 Update prototype.
917
918 * src/autofit/afmodule.c (af_autofitter_load_glyph): Updated.
919
9202015-01-14 Behdad Esfahbod <behdad@behdad.org>
921
Behdad Esfahbodae6699f2015-01-14 18:55:39 +0100922 [autofit] Remove (unused) support for composite glyphs.
923
924 We never have to deal with composite glyphs in the autohinter, as
925 those will be loaded into FORMAT_OUTLINE by the recursed
926 `FT_Load_Glyph' function.
927
928 In the rare cases that FT_LOAD_NO_RECURSE is set, it will imply
929 FT_LOAD_NO_SCALE as per `FT_Load_Glyph', which then implies
930 FT_LOAD_NO_HINTING:
931
932 /* resolve load flags dependencies */
933
934 if ( load_flags & FT_LOAD_NO_RECURSE )
935 load_flags |= FT_LOAD_NO_SCALE |
936 FT_LOAD_IGNORE_TRANSFORM;
937
938 if ( load_flags & FT_LOAD_NO_SCALE )
939 {
940 load_flags |= FT_LOAD_NO_HINTING |
941 FT_LOAD_NO_BITMAP;
942
943 load_flags &= ~FT_LOAD_RENDER;
944 }
945
946 and as such the auto-hinter is never called. Thus, the recursion in
947 `af_loader_load_g' never actually happens. So remove the depth
948 counter as well.
949
950 * src/autofit/afloader.c (af_loader_load_g): Remove `depth'
951 parameter.
952 <FT_GLYPH_FORMAT_COMPOSITE>: Remove associated code.
953 (af_loader_load_glyph): Updated.
954
9552015-01-14 Behdad Esfahbod <behdad@behdad.org>
956
Behdad Esfahbodc242fe42015-01-14 18:48:14 +0100957 [raster] Fix uninitialized memory access.
958
959 Apparently `ras.cProfile' might be uninitialized. This will be the
960 case if `ras.top == ras.cProfile->offset', as can be seen in
961 `End_Profile'. The overshoot code introduced in a change `Fix B/W
962 rasterization of subglyphs with different drop-out modes.' (from
963 2009-06-18) violated this, accessing `ras.cProfile->flags'
964 unconditionally just before calling `End_Profile' (which then
965 detected that `cProfile' is uninitialized and didn't touch it).
966
967 This was harmless, and was not detected by valgrind before because
968 the objects were allocated on the `raster_pool', which was always
969 initialized. With recent change to allocate raster buffers on the
970 stack, valgrind now reported this invalid access.
971
972 * src/raster/ftraster.c (Convert_Glyph): Don't access an
973 uninitialized `cProfile'.
974
9752015-01-14 Behdad Esfahbod <behdad@behdad.org>
976
Behdad Esfahbodb2ba6862015-01-14 18:43:13 +0100977 [smooth] Fix uninitialized memory access.
978
979 Looks like `ras.span_y' could always be used without initialization.
980 This was never detected by valgrind before because the library-wide
981 `raster_pool' was used for the worker object and `raster_pool' was
982 originally zero'ed. But subsequent reuses of it were using `span_y'
983 uninitialized. With the recent change to not use `render_pool' and
984 allocate worker and buffer on the stack, valgrind now detects this
985 uninitialized access.
986
987 * src/smooth/ftgrays.c (gray_raster_render): Initialize
988 `ras.span_y'.
989
9902015-01-14 Behdad Esfahbod <behdad@behdad.org>
991
Behdad Esfahbod603292d2015-01-14 18:35:56 +0100992 [base] Don't initialize unused `driver->glyph_loader'.
993
994 * src/base/ftobjs.c (Destroy_Driver): Don't call
995 `FT_GlyphLoader_Done'.
996 (FT_Add_Module): Don't call `FT_GlyphLoader_New'.
997
9982015-01-14 Behdad Esfahbod <behdad@behdad.org>
999
Behdad Esfahbod51634252015-01-14 18:30:59 +01001000 [base] Don't allocate `library->raster_pool' anymore.
1001
1002 It's unused after the following commits:
1003
1004 [raster] Allocate render pool for mono rasterizer on the stack.
1005 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
1006
1007 The value of FT_RENDER_POOL_SIZE still serves the purpose it used to
1008 serve, which is, to adjust the pool size. But the pool is now
1009 allocated on the stack on demand.
1010
1011 * src/base/ftobjs.c (FT_New_Library, FT_Done_Library): Implement.
1012
10132015-01-14 Behdad Esfahbod <behdad@behdad.org>
1014
Behdad Esfahbod6dfdaf42015-01-14 18:21:13 +01001015 [base] Do not reorder library->renderers upon use.
1016
1017 Instead of keeping `library->renderers' in a MRU order, just leave
1018 it as-is. The MRU machinery wasn't thread-safe.
1019
1020 With this patch, rasterizing glyphs from different faces from
1021 different threads doesn't fail choosing rasterizer
1022 (FT_Err_Cannot_Render_Glyph).
1023
1024 Easiest to see that crash was to add a `printf' (or otherwise let
1025 thread yield in FT_Throw with debugging enabled).
1026
1027 * src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c
1028 (FT_Outline_Render): Don't call `FT_Set_Renderer'.
1029
10302015-01-14 Behdad Esfahbod <behdad@behdad.org>
1031
Behdad Esfahboda773c302015-01-14 18:16:20 +01001032 [raster] Allocate render pool for mono rasterizer on the stack.
1033
1034 Instead of using the `render_pool' member of `FT_Library' that is
1035 provided down to the rasterizer, completely ignore that and allocate
1036 needed objects on the stack instead.
1037
1038 With this patch, rasterizing glyphs from different faces from
1039 different threads doesn't crash in the monochrome rasterizer.
1040
1041 * src/raster/ftraster.c (black_TRaster): Remove `buffer',
1042 `buffer_size', and `worker' members.
1043
1044 (ft_black_render): Create `buffer' locally.
1045 (ft_black_reset): Updated.
1046
10472015-01-14 Behdad Esfahbod <behdad@behdad.org>
1048
Behdad Esfahbod8dc86352015-01-14 18:06:22 +01001049 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
1050
1051 It was off by default and couldn't be turned on at runtime. And the
1052 smooth rasterizer superceded it over ten years ago. No point in
1053 keeping. Comments suggested that it was there for compatibility
1054 with FreeType 1.
1055
1056 550 lines down.
1057
1058 * src/raster/ftraster.c (FT_RASTER_OPTION_ANTI_ALIASING,
1059 RASTER_GRAY_LINES): Remove macros and all associated code.
1060
1061 (black_TWorker): Remove `gray_min_x' and `gray_max_x'.
1062 (black_TRaster): Remove `grays' and `gray_width'.
1063
1064 (Vertical_Sweep_Init, Vertical_Sweep_Span, Vertical_Sweep_Drop,
1065 ft_black_render): Updated.
1066
1067 * src/raster/ftrend1.c (ft_raster1_render): Simplify code.
1068 (ft_raster5_renderer_class): Removed.
1069
10702015-01-14 Behdad Esfahbod <behdad@behdad.org>
1071
Behdad Esfahbod747ae2c2015-01-14 17:54:26 +01001072 [smooth] Allocate render pool for smooth rasterizer on the stack.
1073
1074 Instead of using the `render_pool' member of `FT_Library' that is
1075 provided down to the rasterizer, completely ignore that and allocate
1076 needed objects on the stack instead.
1077
1078 With this patch, rasterizing glyphs from different faces from
1079 different threads doesn't crash in the smooth rasterizer.
1080
1081 Bugs:
1082
1083 https://bugzilla.redhat.com/show_bug.cgi?id=678397
1084 https://bugzilla.redhat.com/show_bug.cgi?id=1004315
1085 https://bugzilla.redhat.com/show_bug.cgi?id=1165471
1086 https://bugs.freedesktop.org/show_bug.cgi?id=69034
1087
1088 * src/smooth/ftgrays.c (gray_TRaster): Remove `buffer',
1089 `buffer_size', `band_size', and `worker' members.
1090
1091 (gray_raster_render): Create `buffer', `buffer_size', and
1092 `band_size' locally.
1093 (gray_raster_reset): Updated.
1094
10952015-01-14 Behdad Esfahbod <behdad@behdad.org>
1096
Behdad Esfahbod531d4632015-01-14 17:46:55 +01001097 [truetype] Allocate TT_ExecContext in TT_Size instead of TT_Driver.
1098
1099 Previously the code had stipulation for using a per-TT_Size exec
1100 context if `size->debug' was true. But there was no way that
1101 `size->debug' could *ever* be true. As such, the code was always
1102 using the singleton `TT_ExecContext' that was stored in `TT_Driver'.
1103 This was, clearly, not threadsafe.
1104
1105 With this patch, loading glyphs from different faces from different
1106 threads doesn't crash in the bytecode loader code.
1107
1108 * src/truetype/ttobjs.h (TT_SizeRec): Remove `debug' member.
1109 (TT_DriverRec): Remove `context' member.
1110
1111 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Remove
1112 `TT_ExecContext' code related to a global `TT_Driver' object.
1113
1114 (tt_driver_done): Don't remove `TT_ExecContext' object here but ...
1115 (tt_size_done_bytecode): ... here.
1116
1117 (tt_driver_init): Don't create `TT_ExecContext' object here but ...
1118 (tt_size_init_bytecode): ... here, only on demand.
1119
1120 * src/truetype/ttinterp.c (TT_Run_Context): Remove defunct debug
1121 code.
1122 (TT_New_Context): Remove `TT_ExecContext' code related to a global
1123 `TT_Driver' object.
1124
1125 * src/truetype/ttinterp.h: Updated.
1126
1127 * src/truetype/ttgload.c (TT_Hint_Glyph, tt_loader_init): Updated.
1128
11292015-01-14 Behdad Esfahbod <behdad@behdad.org>
1130
Behdad Esfahbod89bc8d42015-01-14 16:01:19 +01001131 [autofit] Allocate AF_Loader on the stack instead of AF_Module.
1132
1133 Stop sharing a global `AF_Loader'. Allocate one on the stack during
1134 glyph load.
1135
1136 Right now this results in about 25% slowdown, to be fixed in a
1137 following commit.
1138
1139 With this patch loading glyphs from different faces from different
1140 threads doesn't immediately crash in the autohinting loader code.
1141
1142 Bugs:
1143
1144 https://bugzilla.redhat.com/show_bug.cgi?id=1164941
1145
1146 * src/autofit/afloader.c (af_loader_init): Pass
1147 `AF_Loader' and `FT_Memory' instead of `AF_Module' as arguments.
1148 (af_loader_reset, af_loader_load_glyph): Also pass `loader' as
1149 argument.
1150 (af_loader_done): Use `AF_Loader' instead of `AF_Module' as
1151 argument.
1152
1153 * src/autofit/afmodule.c (af_autofitter_init): Don't call
1154 `af_loader_init'.
1155 (af_autofitter_done): Don't call `af_loader_done'.
1156 (af_autofitter_load_glyph): Use a local `AF_Loader' object.
1157
1158 * src/autofit/afloader.h: Include `afmodule.h'.
1159 Update prototypes.
1160 Move typedef for `AF_Module' to...
1161
1162 * src/autofit/afmodule.h: ... this place.
1163 No longer include `afloader.h'.
1164
11652015-01-14 Behdad Esfahbod <behdad@behdad.org>
1166
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +01001167 * src/type42/t42objs.h (T42_DriverRec): Remove unused member.
1168
Werner Lemberg36d03c92015-01-12 11:26:30 +010011692015-01-12 Werner Lemberg <wl@gnu.org>
1170
1171 Fix Savannah bug #43976.
1172
1173 Assure that FreeType's internal include directories are found before
1174 `CPPFLAGS' (which might be set by the user in the environment), and
1175 `CPPFLAGS' before `CFLAGS'.
1176
1177 * builds/freetype.mk (FT_CFLAGS): Don't add `INCLUDE_FLAGS'.
1178 (FT_COMPILE): Make this a special variable for compiling only the
1179 files handled in `freetype.mk'.
1180 (.c.$O): Removed, unused.
1181
1182 * src/*/rules.mk (*_COMPILE): Fix order of include directories.
1183
Werner Lembergd03a67a2015-01-11 08:39:14 +010011842015-01-11 Werner Lemberg <wl@gnu.org>
1185
Werner Lemberg95b57052015-01-11 09:50:49 +01001186 [truetype] Prettyfing.
1187
1188 * src/truetype/ttinterp.c (project, dualproj, fast_project,
1189 fast_dualproj): Rename to...
1190 (PROJECT, DUALPROJ, FAST_PROJECT, FAST_DUALPROJ): ... this.
1191
11922015-01-11 Werner Lemberg <wl@gnu.org>
1193
Werner Lembergea173c02015-01-11 08:58:54 +01001194 * src/truetype/ttinterp.c (Ins_JROT, Ins_JROF): Simplify.
1195
1196 Based on a patch from Behdad.
1197
11982015-01-11 Werner Lemberg <wl@gnu.org>
1199
Werner Lemberg628578c2015-01-11 08:53:31 +01001200 * src/truetype/ttinterp.c (Ins_SxVTL): Simplify function call.
1201
12022015-01-11 Werner Lemberg <wl@gnu.org>
1203
Werner Lemberg08e79092015-01-11 08:45:50 +01001204 * src/truetype/ttinterp.c (Normalize): Remove unused argument.
1205
12062015-01-11 Werner Lemberg <wl@gnu.org>
1207
Werner Lembergd03a67a2015-01-11 08:39:14 +01001208 [truetype] More macro expansions.
1209
Werner Lemberg4aaadf42015-01-11 08:42:28 +01001210 * src/truetype/ttinterp.c (FT_UNUSED_EXEC): Remove macro by
1211 expansion.
1212
12132015-01-11 Werner Lemberg <wl@gnu.org>
1214
1215 [truetype] More macro expansions.
1216
Werner Lembergd03a67a2015-01-11 08:39:14 +01001217 * src/truetype/ttinterp.c (INS_ARG): Remove macro by expansion,
1218 adjusting funtion calls where necessary.
1219 (FT_UNUSED_ARG): Removed, no longer needed.
1220
Werner Lemberg1b4d68c2015-01-10 19:56:28 +010012212015-01-10 Werner Lemberg <wl@gnu.org>
1222
Werner Lembergeb341362015-01-11 00:23:27 +01001223 [truetype] More macro expansions.
1224
1225 Based on a patch from Behdad.
1226
1227 * src/truetype/ttinterp.c (DO_*): Expand macros into corresponding
1228 `Ins_*' functions.
1229 (TT_RunIns): Replace `DO_*' macros with `Ins_*' function calls.
1230 (ARRAY_BOUND_ERROR): Remove second definition, which is no longer
1231 needed.
1232 (Ins_SVTCA, Ins_SPVTCA, Ins_SFVTCA): Replaced with...
1233 (Ins_SxyTCA): New function.
1234
12352015-01-10 Werner Lemberg <wl@gnu.org>
1236
Werner Lemberg01be1302015-01-10 23:05:37 +01001237 [truetype] Remove TT_CONFIG_OPTION_INTERPRETER_SWITCH.
1238
1239 Behdad suggested this code simplification, and nobody objected...
1240
1241 * include/config/ftoption.h, devel/ftoption.h
1242 (TT_CONFIG_OPTION_INTERPRETER_SWITCH): Remove.
1243
1244 * src/truetype/ttinterp.c [TT_CONFIG_OPTION_INTERPRETER_SWITCH]:
1245 Remove related code.
1246 (ARRAY_BOUND_ERROR): Use do-while loop.
1247
12482015-01-10 Werner Lemberg <wl@gnu.org>
1249
Werner Lembergfae0c812015-01-10 20:23:10 +01001250 [truetype] More macro expansions.
1251
Werner Lemberg6cc1f122015-01-10 21:56:59 +01001252 * src/truetype/ttinterp.c, src/truetype/ttinterp.h (EXEC_ARG_,
1253 EXEC_ARG): Remove by replacing with expansion.
1254
12552015-01-10 Werner Lemberg <wl@gnu.org>
1256
1257 [truetype] More macro expansions.
1258
Werner Lemberg24681452015-01-10 21:53:48 +01001259 Based on a patch from Behdad.
1260
1261 * src/truetype/ttinterp.c (SKIP_Code, GET_ShortIns, NORMalize,
1262 SET_SuperRound, ROUND_None, INS_Goto_CodeRange, CUR_Func_move,
1263 CUR_Func_move_orig, CUR_Func_round, CUR_Func_cur_ppem,
1264 CUR_Func_read_cvt, CUR_Func_write_cvt, CUR_Func_move_cvt,
1265 CURRENT_Ratio, INS_SxVTL, COMPUTE_Funcs, COMPUTE_Round,
1266 COMPUTE_Point_Displacement, MOVE_Zp2_Point): Remove by replacing
1267 with expansion.
1268
1269 (Cur_Func_project, CUR_Func_dualproj, CUR_fast_project,
1270 CUR_fast_dualproj): Replace with macros `project', `dualproj',
1271 `fast_project', `fast_dualproj'.
1272
12732015-01-10 Werner Lemberg <wl@gnu.org>
1274
1275 [truetype] More macro expansions.
1276
Werner Lembergfae0c812015-01-10 20:23:10 +01001277 * src/truetype/ttinterp.c (EXEC_OP_, EXEC_OP): Remove by replacing
1278 with expansion.
1279
12802015-01-10 Werner Lemberg <wl@gnu.org>
1281
Werner Lemberg5a752f32015-01-10 20:08:35 +01001282 [truetype] Remove code for static TrueType interpreter.
1283
1284 This is a follow-up patch.
1285
1286 * src/truetype/ttinterp.c, src/truetype/ttinterp.h
1287 [TT_CONFIG_OPTION_STATIC_INTERPRETER,
1288 TT_CONFIG_OPTION_STATIC_RASTER]: Remove macros and related code.
1289
12902015-01-10 Werner Lemberg <wl@gnu.org>
1291
Werner Lemberg1b4d68c2015-01-10 19:56:28 +01001292 * src/truetype/ttinterp.c (CUR): Remove by replacing with expansion.
1293
1294 This starts a series of patches that simplifies the code of the
1295 bytecode interpreter.
1296
Werner Lemberg232bd942014-12-30 21:44:51 +010012972014-12-30 Werner Lemberg <wl@gnu.org>
1298
1299 * Version 2.5.5 released.
1300 =========================
1301
1302
1303 Tag sources with `VER-2-5-5'.
1304
1305 * docs/VERSION.DLL: Update documentation and bump version number to
1306 2.5.5.
1307
1308 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
1309 builds/windows/vc2005/index.html,
1310 builds/windows/vc2008/freetype.vcproj,
1311 builds/windows/vc2008/index.html,
1312 builds/windows/vc2010/freetype.vcxproj,
1313 builds/windows/vc2010/index.html,
1314 builds/windows/visualc/freetype.dsp,
1315 builds/windows/visualc/freetype.vcproj,
1316 builds/windows/visualc/index.html,
1317 builds/windows/visualce/freetype.dsp,
1318 builds/windows/visualce/freetype.vcproj,
1319 builds/windows/visualce/index.html,
1320 builds/wince/vc2005-ce/freetype.vcproj,
1321 builds/wince/vc2005-ce/index.html,
1322 builds/wince/vc2008-ce/freetype.vcproj,
1323 builds/wince/vc2008-ce/index.html: s/2.5.4/2.5.5/, s/254/255/.
1324
1325 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 5.
1326
1327 * builds/unix/configure.raw (version_info): Set to 17:4:11.
1328 * CMakeLists.txt (VERSION_PATCH): Set to 5.
1329 * docs/CHANGES: Updated.
1330
1331 * builds/toplevel.mk (dist): Fix typos.
1332
Alexei Podtelezhnikov70241552014-12-24 12:11:46 -050013332014-12-24 Alexei Podtelezhnikov <apodtele@gmail.com>
1334
1335 [base] Formatting and nanooptimizations.
1336
1337 * src/base/ftcalc.c,
1338 * src/base/fttrigon.c: Revise sign restoration.
1339
Werner Lemberg06842c72014-12-13 07:42:51 +010013402014-12-13 Werner Lemberg <wl@gnu.org>
1341
1342 * src/pcf/pcfread.c (pcf_read_TOC): Improve fix from 2014-12-08.
1343
Werner Lembergb9438112014-12-11 13:33:14 +010013442014-12-11 Werner Lemberg <wl@gnu.org>
1345
Werner Lemberg82119502014-12-11 22:27:06 +01001346 * builds/toplevel.mk (dist): Use older POSIX standard for `tar'.
1347
1348 Apparently, BSD tar isn't capable yet of handling POSIX-1.2001
1349 (contrary to GNU tar), so force the POSIX-1.1988 format.
1350
1351 Problem reported by Stephen Fisher <sfisher@SDF.ORG>.
1352
13532014-12-11 Werner Lemberg <wl@gnu.org>
1354
Werner Lemberg812ed342014-12-11 14:07:29 +01001355 * src/type42/t42parse.c (t42_parse_sfnts): Reject invalid TTF size.
1356
13572014-12-11 Werner Lemberg <wl@gnu.org>
1358
Werner Lembergc9ca6ff2014-12-11 13:39:39 +01001359 * src/base/ftobjs.c (FT_Get_Glyph_Name): Fix off-by-one check.
1360
1361 Problem reported by Dennis Felsing <dennis@felsin9.de>.
1362
13632014-12-11 Werner Lemberg <wl@gnu.org>
1364
Werner Lembergb9438112014-12-11 13:33:14 +01001365 * src/type42/t42parse.c (t42_parse_sfnts): Check `string_size'.
1366
1367 Problem reported by Dennis Felsing <dennis@felsin9.de>.
1368
suzuki toshiya2b592822014-12-10 00:27:41 +090013692014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1370
suzuki toshiya9bd1e552014-12-09 14:51:52 +09001371 [gxvalid] Fix a naming convention conflicting with ftvalid.
1372
1373 See previous changeset for otvalid.
1374
1375 * src/gxvalid/{gxvcommn.h, gxvmort.h, gxvmorx.h}: Replace
1376 `valid' by `gxvalid'.
1377 * src/gxvalid/{gxvbsln.c, gxvcommn.c, gxvfeat.c, gxvjust.c,
1378 gxvkern.c, gxvlcar.c, gxvmort.c, gxvmort0.c, gxvmort1.c,
1379 gxvmort2.c, gxvmort4.c, gxvmort5.c, gxvmorx.c, gxvmorx0.c,
1380 gxvmorx1.c, gxvmorx2.c, gxvmorx4.c, gxvmorx5.c, gxvopbd.c,
1381 gxvprop.c, gxvtrak.c}: Replace `valid' by `gxvalid' if
1382 it is typed as GXV_Validator.
1383
13842014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1385
suzuki toshiya51abdf62014-12-09 00:58:04 +09001386 [otvalid] Fix a naming convention conflicting with ftvalid.
1387
1388 Some prototypes in ftvalid.h use `valid' for the variables
1389 typed as FT_Validator. Their implementations in src/base/
1390 ftobjs.c and utilizations in src/sfnt/ttcmap.c do similar.
1391
1392 Some macros in otvcommn.h assume the exist of the variable
1393 `valid' typed as OTV_Validator in the caller.
1394
1395 Mixing these two conventions cause invalid pointer conversion
1396 and unexpected SEGV in longjmp. To prevent it, all variables
1397 typed as OTV_Validator are renamed to `otvalid'.
1398
1399 * src/otvalid/otvcommn.h: Replace `valid' by `otvalid'.
1400 * src/otvalid/{otvcommn.c, otvbase.c, otvgdef.c, otvgpos.c,
1401 otvgsub.c, otvjstf.c, otvmath.c}: Replace `valid' by `otvalid'
1402 if it is typed as OTV_Validator.
1403
14042014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1405
suzuki toshiya2b592822014-12-10 00:27:41 +09001406 [ftvalid] Introduce FT_THROW() in FT_INVALID_XXX macros.
1407
1408 Original patch is designed by Werner Lemberg. Extra part
1409 for otvalid and gxvalid are added by suzuki toshiya, see
1410 discussion:
1411 http://lists.nongnu.org/archive/html/freetype-devel/2014-12/msg00002.html
1412 http://lists.nongnu.org/archive/html/freetype-devel/2014-12/msg00007.html
1413
1414 * include/internal/ftvalid.h: Introduce FT_THROW() in FT_INVALID_().
1415 * src/gxvalid/gxvcommn.h: Ditto.
1416 * src/otvalid/otvcommn.h: Ditto.
1417
Werner Lemberg74af85c2014-12-08 16:01:50 +010014182014-12-08 Werner Lemberg <wl@gnu.org>
1419
1420 [pcf] Fix Savannah bug #43774.
1421
1422 Work around `features' of X11's `pcfWriteFont' and `pcfReadFont'
1423 functions. Since the PCF format doesn't have an official
1424 specification, we have to exactly follow these functions' behaviour.
1425
1426 The problem was unveiled with a patch from 2014-11-06, fixing issue
1427 #43547.
1428
1429 * src/pcf/pcfread.c (pcf_read_TOC): Don't check table size for last
1430 element. Instead, assign real size.
1431
Werner Lemberg66883b52014-12-07 09:17:06 +010014322014-12-07 Werner Lemberg <wl@gnu.org>
1433
Werner Lemberg553c9672014-12-07 19:29:52 +01001434 Work around a bug in Borland's C++ compiler.
1435
1436 See
1437
1438 http://qc.embarcadero.com/wc/qcmain.aspx?d=118998
1439
1440 for Borland's bug tracker entry.
1441
1442 Reported by Yuliana Zigangirova <zigangirova@inbox.ru>,
1443 http://lists.gnu.org/archive/html/freetype-devel/2014-04/msg00001.html.
1444
1445 * include/internal/ftvalid.h (FT_ValidatorRec), src/smooth/ftgrays.c
1446 (gray_TWorker_): Move `ft_jmp_buf' field to be the first element.
1447
14482014-12-07 Werner Lemberg <wl@gnu.org>
1449
Werner Lemberg9870d6d2014-12-07 09:40:47 +01001450 */*: Decorate hex constants with `U' and `L' where appropriate.
1451
14522014-12-07 Werner Lemberg <wl@gnu.org>
1453
Werner Lemberg66883b52014-12-07 09:17:06 +01001454 [truetype] Prevent memory leak for buggy fonts.
1455
1456 * src/truetype/ttobjs.c (tt_size_done): Unconditionally call
1457 `tt_size_done_bytecode'.
1458
Werner Lemberg94926682014-12-06 07:11:44 +010014592014-12-06 Werner Lemberg <wl@gnu.org>
1460
1461 * Version 2.5.4 released.
1462 =========================
1463
1464
1465 Tag sources with `VER-2-5-4'.
1466
1467 * docs/VERSION.DLL: Update documentation and bump version number to
1468 2.5.4.
1469
1470 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
1471 builds/windows/vc2005/index.html,
1472 builds/windows/vc2008/freetype.vcproj,
1473 builds/windows/vc2008/index.html,
1474 builds/windows/vc2010/freetype.vcxproj,
1475 builds/windows/vc2010/index.html,
1476 builds/windows/visualc/freetype.dsp,
1477 builds/windows/visualc/freetype.vcproj,
1478 builds/windows/visualc/index.html,
1479 builds/windows/visualce/freetype.dsp,
1480 builds/windows/visualce/freetype.vcproj,
1481 builds/windows/visualce/index.html,
1482 builds/wince/vc2005-ce/freetype.vcproj,
1483 builds/wince/vc2005-ce/index.html,
1484 builds/wince/vc2008-ce/freetype.vcproj,
1485 builds/wince/vc2008-ce/index.html: s/2.5.3/2.5.4/, s/253/254/.
1486
1487 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 4.
1488
1489 * builds/unix/configure.raw (version_info): Set to 17:3:11.
1490 * CMakeLists.txt (VERSION_PATCH): Set to 4.
1491 * docs/CHANGES: Updated.
1492
Werner Lemberg934ef382014-12-04 06:38:51 +010014932014-12-04 Werner Lemberg <wl@gnu.org>
1494
1495 docs/CHANGES: Updated, formatted.
1496
Dave Arnold2cdc4562014-12-04 06:10:16 +010014972014-12-04 Dave Arnold <darnold@adobe.com>
1498
Dave Arnoldf89396c2014-12-04 06:17:26 +01001499 [cff] Modify an FT_ASSERT.
1500
1501 * src/cff/cf2hints.c (cf2_hintmap_map): After the fix for Savannah
1502 bug #43661, the test font `...aspartam.otf' still triggers an
1503 FT_ASSERT. Since hintmap still works with count==0, ...
1504 (cf2_glyphpath_lineTo, cf2_glyphpath_curveTo): ... add that term to
1505 suppress the assert.
1506
15072014-12-04 Dave Arnold <darnold@adobe.com>
1508
Dave Arnold2cdc4562014-12-04 06:10:16 +01001509 [cff] Fix Savannah bug #43661.
1510
1511 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdHSTEM,
1512 cf2_cmdVSTEM, cf2_cmdHINTMASK>: Don't append to stem arrays after
1513 hintmask is constructed.
1514
1515 * src/cff/cf2hints.c (cf2_hintmap_build): Add defensive code to
1516 avoid reading past end of hintmask.
1517
Werner Lemberg16188eb2014-12-03 10:18:34 +010015182014-12-03 Werner Lemberg <wl@gnu.org>
1519
Werner Lemberg8fa69a82014-12-03 20:07:14 +01001520 docs/CHANGES: Updated.
1521
15222014-12-03 Werner Lemberg <wl@gnu.org>
1523
Werner Lemberga632b5f2014-12-03 19:30:44 +01001524 [autofit] Better fix for conversion specifiers in debug messages.
1525
1526 Using `%ld' for pointer differences causes warnings on 32bit
1527 platforms. The correct type would be (the relatively new) `%td',
1528 however, this is missing on some important platforms.
1529
1530 This patch improves the change from 2014-11-28.
1531
1532 * src/autofit/afhints.c (AF_INDEX_NUM): Use `int' typecast. Our
1533 pointer differences are always sufficiently small.
1534 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
1535 af_glyph_hints_dump_edge): Revert to `%d' and use `AF_INDEX_NUM'.
1536
15372014-12-03 Werner Lemberg <wl@gnu.org>
1538
Werner Lemberg16188eb2014-12-03 10:18:34 +01001539 FT_Sfnt_Tag: s/ft_sfnt_xxx/FT_SFNT_XXX/ for orthogonality.
1540
1541 All public FreeType enumeration and flag values are uppercase...
1542
1543 * include/tttables.h (FT_Sfnt_Tag): Implement it. For backwards
1544 compatilibity, retain the old values as macros.
1545
1546 * src/base/ftfstype.c (FT_Get_FSType_Flags), src/sfnt/sfdriver.c
1547 (get_sfnt_table): Updated.
1548
Werner Lemberg2af25ac2014-12-02 08:38:57 +010015492014-12-02 Werner Lemberg <wl@gnu.org>
1550
Werner Lembergde43ace2014-12-02 23:06:04 +01001551 * include/*: Improve structure of documentation.
1552
1553 . Add and update many `<Order>' tags.
1554 . Apply various documentation fixes.
1555 . Remove details to deprecated (or never implemented) data.
1556
15572014-12-02 Werner Lemberg <wl@gnu.org>
1558
Werner Lembergca1f5cc2014-12-02 22:49:25 +01001559 [docmaker] Always handle `<Order>' section elements.
1560
1561 Previously, those elements were handled only for sections present in
1562 a `<Sections>' chapter element.
1563
1564 * src/tools/docmaker/content.py (ContentProcessor::finish):
1565 Implement it.
1566
15672014-12-02 Werner Lemberg <wl@gnu.org>
1568
Werner Lembergef6a3522014-12-02 21:16:59 +01001569 [docmaker] Properly handle empty rows in Synopsis.
1570
1571 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Emit
1572 `&nbsp;' for empty fields.
1573
15742014-12-02 Werner Lemberg <wl@gnu.org>
1575
Werner Lemberg0e96f052014-12-02 11:08:31 +01001576 [docmaker] Thinko.
1577
1578 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
1579 Emit `/empty/' string for first element also.
1580
15812014-12-02 Werner Lemberg <wl@gnu.org>
1582
Werner Lemberg102d4a72014-12-02 10:27:40 +01001583 [docmaker] Honour empty lines in `<Order>' section element.
1584
1585 This greatly improves the readability of the `Synopsis' links.
1586
1587 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
1588 Insert string `/empty/' between items.
1589
1590 * src/tools/docmaker/formatter.py (Formatter::section_dump): Make it
1591 robust against nonexistent keys.
1592
1593 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Emit
1594 empty <td> elements for `/empty/'.
1595
15962014-12-02 Werner Lemberg <wl@gnu.org>
1597
Werner Lemberg2af25ac2014-12-02 08:38:57 +01001598 [docmaker] Ensure Python 3 compatibility.
1599
1600 * src/tools/docmaker/content.py (ContentProcessor::set_section,
1601 ContentProcessor::finish): Replace `has_key' function with `in'
1602 keyword.
1603
1604 * src/tools/docmaker/formatter.py (Formatter::__init__): Replace
1605 sorting function with a key generator.
1606 (Formatter::add_identifier): Replace `has_key' function with `in'
1607 keyword.
1608
1609 * src/tools/docmaker/tohtml.py (HtmlFormatter::html_source_quote):
1610 Replace `has_key' function with `in' keyword.
1611 (HtmlFormatter::index_exit, HtmlFormatter::section_enter): Use
1612 integer division.
1613 s/<>/>/.
1614
1615 * src/tools/docmaker/utils.py: Import `itertools'.
1616 (index_sort): Replaced by...
1617 (index_key): ... this new key generator (doing exactly the same).
1618
Werner Lemberg8f795112014-11-29 06:49:15 +010016192014-11-29 Werner Lemberg <wl@gnu.org>
1620
Werner Lemberg80bfeb12014-12-01 10:07:52 +01001621 [docmaker] Don't output a block multiple times.
1622
1623 This bug was hidden by not processing all lines of `<Order>' blocks.
1624
1625 * src/tools/docmaker/formatter.py (Formatter::section_dump): Filter
1626 out field names.
1627
16282014-11-29 Werner Lemberg <wl@gnu.org>
1629
Werner Lemberg0dbad762014-12-01 08:44:48 +01001630 [docmaker] Use field values as HTML link targets where possible.
1631
1632 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_block_url):
1633 Accept second, optional argument to specify a name.
1634 (HtmlFormatter::html_source_quote): Link to field ID if possible.
1635 (HtmlFormatter::print_html_field_list): Emit `id' attribute.
1636
16372014-11-29 Werner Lemberg <wl@gnu.org>
1638
Werner Lemberg785b1d02014-11-30 22:16:34 +01001639 [docmaker] Allow empty lines in `<Order>' blocks.
1640
1641 Before this patch, the suggested order of entries stopped at the
1642 first empty line.
1643
1644 Obviously, nobody noticed that this problem caused a much reduced
1645 set of links in the `Synopsis' sections; in particular, the
1646 `<Order>' blocks contain a lot of entries that wouldn't be listed
1647 otherwise...
1648
1649 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
1650 New function to iterate over all items.
1651 (DocSection::process): Use it.
1652
16532014-11-29 Werner Lemberg <wl@gnu.org>
1654
Werner Lemberg16b3e622014-11-30 20:58:27 +01001655 * src/tools/docmaker/sources.py (column) [Format 2]: Fix regexp.
1656
1657 After the single asterisk there must be no other immediately following
1658 asterisk.
1659
16602014-11-29 Werner Lemberg <wl@gnu.org>
1661
Werner Lemberg434bc692014-11-29 23:12:55 +01001662 * src/tools/docmaker/tohtml.py: Improve CSS for vertical spacing.
Werner Lemberg51987ea2014-11-29 22:19:29 +01001663
Werner Lemberg434bc692014-11-29 23:12:55 +010016642014-11-29 Werner Lemberg <wl@gnu.org>
1665
1666 [docmaker] Improve HTML code for table of contents.
1667
1668 * src/tools/docmaker/tohtml.py: Introduce a new table class `toc',
Werner Lemberg51987ea2014-11-29 22:19:29 +01001669 together with proper CSS.
1670
16712014-11-29 Werner Lemberg <wl@gnu.org>
1672
Werner Lembergaa834ce2014-11-29 20:08:29 +01001673 [docmaker] Provide higher-level markup and simplify HTML.
1674
1675 * src/tools/docmaker/tohtml.py: Instead of using extraneous `<div>'
1676 elements, use CSS descendants (of class `section') to format the
1677 data.
1678
1679 Also remove reduntant <p> and <br> elements, replacing them with
1680 proper CSS.
1681
1682 Globally reduce page width to 75%.
1683
1684 (block_header): Rename <div> class to `section'.
1685
16862014-11-29 Werner Lemberg <wl@gnu.org>
1687
Werner Lemberg3bb97022014-11-29 16:12:37 +01001688 [docmaker] Add `top' links after blocks.
1689
1690 * src/tools/docmaker/tohtml.py (block_footer_middle): Implement it.
1691
16922014-11-29 Werner Lemberg <wl@gnu.org>
1693
Werner Lemberga31f9712014-11-29 07:18:44 +01001694 * src/tools/docmaker/tohtml.py: Improve CSS for fields.
1695
Werner Lemberg3bb97022014-11-29 16:12:37 +01001696 Make fields align horizontally relative to full line width.
Werner Lemberga31f9712014-11-29 07:18:44 +01001697
16982014-11-29 Werner Lemberg <wl@gnu.org>
1699
Werner Lemberg8f795112014-11-29 06:49:15 +01001700 * src/tools/docmaker/tohtml.py: Fix index and TOC templates.
1701
1702 This thinko was introduced 2014-11-27.
1703
Werner Lembergba1ba0c2014-11-28 22:04:14 +010017042014-11-28 Werner Lemberg <wl@gnu.org>
1705
1706 [docmaker] Format field lists with CSS.
1707
1708 This also simplifies the inserted HTML code.
1709
1710 * src/tools/docmaker/tohtml.py
1711 (HtmlFormatter::print_html_field_list): Do it.
1712
suzuki toshiya348fffa2014-11-28 16:05:59 +090017132014-11-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1714
1715 Fix compiler warning to the comparison between signed and
1716 unsigned variable.
1717
1718 * src/pfr/pfrsbit.c (pfr_slot_load_bitmap): Fix the comparison
1719 between `ypos + ysize' and FT_INT_{MAX,MIN}.
1720
Werner Lembergba1ba0c2014-11-28 22:04:14 +010017212014-11-28 Werner Lemberg <wl@gnu.org>
Werner Lemberg984e0712014-11-28 05:33:58 +01001722
Werner Lembergba1ba0c2014-11-28 22:04:14 +01001723 [docmaker] Replace empty `<td>' with CSS.
Werner Lemberg46d4dc82014-11-28 05:49:56 +01001724
1725 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Do
1726 it.
1727
Werner Lembergba1ba0c2014-11-28 22:04:14 +010017282014-11-28 Werner Lemberg <wl@gnu.org>
Werner Lemberg46d4dc82014-11-28 05:49:56 +01001729
Werner Lemberg984e0712014-11-28 05:33:58 +01001730 [docmaker] Replace some `<table>' tags with `<h4>' and `<div>'.
1731
1732 * src/tools/docmaker/tohtml.py (marker_*): Use `<h4>'.
1733 (source_*): Use `<div>'.
1734 (HtmlFormatter::block_enter): s/<h4>/<h3>/.
1735
suzuki toshiya9ee6a0a2014-11-28 11:14:18 +090017362014-11-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1737
1738 Fix compiler warning to conversion specifiers in debug messages.
1739
1740 * src/autofit/afhints.c (af_glyph_hints_dump_points): Add length
Werner Lemberga632b5f2014-12-03 19:30:44 +01001741 modifier to dump long integers.
1742 (af_glyph_hints_dump_segments, af_glyph_hints_dump_edges): Ditto.
suzuki toshiya9ee6a0a2014-11-28 11:14:18 +09001743
Werner Lemberg26d699e2014-11-27 19:22:52 +010017442014-11-27 Werner Lemberg <wl@gnu.org>
1745
Werner Lemberg984e0712014-11-28 05:33:58 +01001746 * src/tools/docmaker/tohtml.py: Use more CSS for index.
Werner Lemberg7ea36342014-11-27 19:38:31 +01001747
17482014-11-27 Werner Lemberg <wl@gnu.org>
1749
Werner Lembergedcf8172014-11-27 19:28:48 +01001750 [docmaker] Replace `name' attribute of `<a>' with `id'.
1751
1752 * src/tools/docmaker/tohtml.py (HtmlFormatter::block_enter): Do it.
1753
17542014-11-27 Werner Lemberg <wl@gnu.org>
1755
Werner Lemberg26d699e2014-11-27 19:22:52 +01001756 * src/tools/docmaker/tohtml.py: Remove remaining `width' attributes.
1757
1758 For `Index' and `TOC' links, we now simply use the `text-align' CSS
1759 property of `<td>' to enforce flush-left and flush-right,
1760 eliminating the hack with an empty, full-width `<td>' element
1761 inbetween.
1762
1763 The change also enforces the same (smaller) size for all index and
1764 TOC links.
1765
suzuki toshiya2676e072014-11-28 00:58:25 +090017662014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1767
suzuki toshiya1b12f5d2014-11-28 01:22:26 +09001768 * src/cff/cf2font.c: Include `ftcalc.h' to use FT_MSB(),
1769 cf2font.c could not find it under `make multi' build.
1770
17712014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1772
suzuki toshiya2676e072014-11-28 00:58:25 +09001773 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Remove
1774 unrequired negative value check for `width' and `height'.
1775
Werner Lemberg8585cf52014-11-27 10:49:05 +010017762014-11-27 Werner Lemberg <wl@gnu.org>
1777
Werner Lembergdd3fee02014-11-27 13:20:52 +01001778 * src/tools/docmaker/tohtml.py: More HTML table refactoring.
1779
1780 Replace some `<table>' tags with `<div>' to simplify structure.
1781
1782 Move `bgcolor' attribute to CSS.
1783
1784 Replace most `width' attributes with CSS. The remaining instances
1785 (providing a similar effect as LaTeX's `\hfill' command) are removed
1786 in a later patch.
1787
17882014-11-27 Werner Lemberg <wl@gnu.org>
1789
Werner Lemberga5ad26a2014-11-27 10:52:24 +01001790 * src/tools/docmaker/tohtml.py: Replace <font> with CSS.
1791
17922014-11-27 Werner Lemberg <wl@gnu.org>
1793
Werner Lembergba67c612014-11-27 10:51:49 +01001794 * src/tools/docmaker/tohtml.py: Center <table> with CSS.
1795
17962014-11-27 Werner Lemberg <wl@gnu.org>
1797
Werner Lemberg5594fa52014-11-27 10:50:50 +01001798 * src/tools/docmaker/tohtml.py: Replace `<center>' with `<div>'.
1799
18002014-11-27 Werner Lemberg <wl@gnu.org>
1801
Werner Lemberg8585cf52014-11-27 10:49:05 +01001802 * src/tools/docmaker/tohtml.py: Remove redundant `<center>' tags.
1803
1804 This starts a series of commits into the direction of generating
1805 valid HTML 5 code, especially using much more CSS.
1806
suzuki toshiya1b057042014-11-27 17:53:20 +090018072014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1808
1809 Prevent too negative values (< FT_INT_MIN) in bitmap metrics,
1810 suggested by Alexei.
1811
1812 * src/pfr/pfrsbit.c (pfr_slot_load_bitmap): Prevent too
1813 negative values in `xpos' and `ypos + ysize'.
1814 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Prevent
1815 too negative values in `x_left' and `y_top'. Either negative
1816 values in `width' and `height' are checked.
1817
Werner Lemberg3d167cb2014-11-27 05:19:41 +010018182014-11-27 Werner Lemberg <wl@gnu.org>
1819
Werner Lembergc52882a2014-11-27 08:01:25 +01001820 [docmaker] Produce better HTML code.
1821
1822 * src/tools/docmaker/tohtml.py: Always use double quotes for
1823 attribute values.
1824 (source_footer): Close `td' and `tr' groups.
1825
18262014-11-27 Werner Lemberg <wl@gnu.org>
1827
Werner Lembergdbb93152014-11-27 07:20:48 +01001828 Use better way to disable creation of .pyc files for `make refdoc'.
1829
1830 Python 2.6 was released in 2008...
1831
1832 * builds/freetype.mk (refdoc): Use python's `-B' option.
1833
1834 * builds/detect.mk (std_setup, dos_setup): Mention required python
1835 version for `refdoc' target.
1836
18372014-11-27 Werner Lemberg <wl@gnu.org>
1838
Werner Lemberge8a5c332014-11-27 06:48:37 +01001839 * src/tools/docmaker/sources.py (re_bold, re_italic): Use
1840 non-grouping parentheses.
1841 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_html_word):
1842 Updated.
1843
18442014-11-27 Werner Lemberg <wl@gnu.org>
1845
Werner Lemberg3d167cb2014-11-27 05:19:41 +01001846 * src/base/ftobjs.c (FT_Get_Glyph_Name): Fix compiler warning.
1847
1848 Introdruced in previous change. Reported by Alexei.
1849
Werner Lemberga593a042014-11-26 18:42:48 +010018502014-11-26 Werner Lemberg <wl@gnu.org>
1851
Werner Lembergf34f1922014-11-26 21:59:21 +01001852 * src/*: Add checks for parameters of API functions where missing.
1853
1854 `API functions' are functions tagged with `FT_EXPORT_DEF'.
1855
1856 Besides trivial fixes, the following changes are included, too.
1857
1858 * src/base/ftbdf.c (FT_Get_BDF_Charset_ID, FT_Get_BDF_Property): Set
1859 error code if no service is available.
1860
1861 * src/base/ftinit.c (FT_Done_FreeType): Change return value for
1862 invalid `library' parameter to `Invalid_Library_Handle'.
1863
1864 * src/base/ftobjs.c (FT_New_Size): Change return value for invalid
1865 `asize' parameter to `Invalid_Argument'.
1866
1867 * src/base/ftoutln.c (FT_Outline_Copy): Change return value for
1868 invalid `source' and `target' parameters to `Invalid_Outline'.
1869 (FT_Outline_Done_Internal): Change return value for invalid
1870 `outline' parameter to `Invalid_Outline'.
1871
18722014-11-26 Werner Lemberg <wl@gnu.org>
1873
Werner Lemberga593a042014-11-26 18:42:48 +01001874 * src/cache/ftcbasic.c: Use single calls to `FT_TRACE'.
1875
suzuki toshiya5aff8532014-11-26 14:36:12 +090018762014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1877
suzuki toshiyacd4a5a22014-11-27 00:20:48 +09001878 * src/base/ftobj.c (Mac_Read_POST_Resource): Additional
1879 overflow check in the summation of POST fragment lengths,
1880 suggested by Mateusz Jurczyk <mjurczyk@google.com>.
1881
18822014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1883
suzuki toshiya1720e812014-11-26 16:39:00 +09001884 * src/base/ftobjs.c (Mac_Read_POST_Resource): Insert comments
1885 and fold too long tracing messages.
1886
18872014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1888
suzuki toshiya18a8f0d2014-11-26 16:11:38 +09001889 Fix Savannah bug #43540.
1890
1891 * src/base/ftmac.c (parse_fond): Prevent a buffer overrun
1892 caused by a font including too many (> 63) strings to store
1893 names[] table.
1894
18952014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1896
suzuki toshiya45331672014-11-26 16:02:17 +09001897 * src/base/ftobjs.c (Mac_Read_POST_Resource): Use unsigned long
1898 variables to read the lengths in POST fragments. Suggested by
1899 Mateusz Jurczyk <mjurczyk@google.com>.
1900
19012014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1902
suzuki toshiya35252ae2014-11-26 15:52:23 +09001903 Fix Savannah bug #43539.
1904
1905 * src/base/ftobjs.c (Mac_Read_POST_Resource): Fix integer overflow
1906 by a broken POST table in resource-fork.
1907
19082014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1909
suzuki toshiya240c94a2014-11-26 15:43:29 +09001910 Fix Savannah bug #43538.
1911
1912 * src/base/ftobjs.c (Mac_Read_POST_Resource): Fix integer overflow
1913 by a broken POST table in resource-fork.
1914
19152014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1916
suzuki toshiya5aff8532014-11-26 14:36:12 +09001917 * src/base/ftobjs.c (Mac_Read_POST_Resource): Avoid memory leak
1918 by a broken POST table in resource-fork. Return after freeing
1919 the buffered POST table when it is found to be broken.
1920
Werner Lemberg04edbbd2014-11-25 10:21:13 +010019212014-11-25 Werner Lemberg <wl@gnu.org>
1922
Werner Lemberg02b8e7e2014-11-25 11:31:51 +01001923 */*: s/Invalid_Argument/Invalid_Size_Handle/ where appropriate.
1924
19252014-11-25 Werner Lemberg <wl@gnu.org>
1926
Werner Lemberg0d4aa232014-11-25 11:26:14 +01001927 */*: s/Invalid_Argument/Invalid_Stream_Handle/ where appropriate.
1928
19292014-11-25 Werner Lemberg <wl@gnu.org>
1930
Werner Lembergf4f9e682014-11-25 11:11:55 +01001931 */*: s/Invalid_Argument/Invalid_Library_Handle/ where appropriate.
1932
19332014-11-25 Werner Lemberg <wl@gnu.org>
1934
Werner Lemberg04c2aa12014-11-25 10:22:12 +01001935 */*: s/Invalid_Argument/Invalid_Outline/ where appropriate.
1936
19372014-11-25 Werner Lemberg <wl@gnu.org>
1938
Werner Lemberg04edbbd2014-11-25 10:21:13 +01001939 */*: s/Invalid_Argument/Invalid_Face_Handle/ where appropriate.
1940
Werner Lembergeca0f062014-11-24 10:22:08 +010019412014-11-24 Werner Lemberg <wl@gnu.org>
1942
Werner Lemberg3e867112014-11-25 09:01:07 +01001943 [Savannah bug #43682] Adjust some renderer callbacks.
1944
1945 * src/raster/ftraster.c (ft_black_set_mode): Change return type to
1946 `int' to stay in sync with `FT_Renderer_SetModeFunc' prototype.
1947
1948 * src/smooth/ftgrays.c (gray_raster_set_mode): New dummy function
1949 for orthogonality.
1950 (ft_grays_raster): Use it.
1951
Werner Lemberg04edbbd2014-11-25 10:21:13 +010019522014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lemberg3e867112014-11-25 09:01:07 +01001953
Werner Lemberg6689a002014-11-25 08:53:09 +01001954 [Savannah bug #43682] Properly handle missing return errors.
1955
1956 The functions in this patch *do* return non-trivial errors that must
1957 be taken care of.
1958
1959 * src/autofit/afloader.c (af_loader_load_g), src/base/ftobjs.c
1960 (FT_Render_Glyph_Internal), src/base/ftoutln.c (FT_Outline_Render),
1961 src/cff/cffgload.c (cff_decoder_parse_charstrings) <cff_op_endchar>,
1962 src/psaux/psobjs.c (ps_parser_load_field_table), src/psaux/t1decode
1963 (t1_decoder_parse_charstrings) <op_endchar>, src/truetype/ttgload.c
1964 (load_truetype_glyph <subglyph loop>, tt_loader_init,
1965 TT_Load_Glyph), src/truetype/ttgxvar.c (TT_Set_MM_Blend),
1966 src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Do it.
1967
Werner Lemberg04edbbd2014-11-25 10:21:13 +010019682014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lemberg6689a002014-11-25 08:53:09 +01001969
Werner Lembergb24e8ba2014-11-25 08:30:49 +01001970 [Savannah bug #43682] Add/remove `void' casts to some functions.
1971
1972 We use a cast to indicate that we intentionally ignore a function's
1973 return value. However, this doesn't apply to API functions where
1974 errors can only happen for trivially invalid input.
1975
1976 * src/base/ftstroke.c (FT_Glyph_Stroke, FT_Glyph_StrokeBorder),
1977 src/base/ftsynth.c (FT_GlyphSlot_Embolden), src/cff/cffgload.c
1978 (cff_slot_load), src/pfr/pfrdrivr.c (pfr_get_kerning),
1979 src/type1/t1load.c (parse_encoding), src/type42/t42parse.c
1980 (t42_parse_encoding): Do it.
1981
Werner Lemberg04edbbd2014-11-25 10:21:13 +010019822014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lembergb24e8ba2014-11-25 08:30:49 +01001983
Werner Lembergef439fd2014-11-25 08:14:15 +01001984 [Savannah bug #43682] Change some signatures to `void' return type.
1985
1986 * include/internal/pshints.h (PSH_Globals_SetScaleFunc),
1987 include/internal/sfnt.h (TT_Get_Metrics_Func),
1988 src/pshinter/pshglob.c (psh_globals_set_scale),
1989 src/pshinter/pshrec.c (ps_hints_init), src/sfnt/ttmtx.c
1990 (tt_face_get_metrics), src/truetype/ttinterp.c (TT_Goto_CodeRange,
1991 TT_Set_CodeRange, TT_Clear_CodeRange, TT_Done_Context,
1992 TT_Save_Context): Do it.
1993
1994 * src/pshinter/pshglob.h, src/pshinter/pshrec.h, src/sfnt/ttmtx.h,
1995 src/truetype/ttgload.c (TT_Hint_Glyph), src/truetype/ttinterp.c
1996 (TT_Run_Context), src/truetype/ttinterp.h, src/truetype/ttobjs.c
1997 (tt_size_run_fpgm, tt_size_run_prep): Updated.
1998
19992014-11-24 Werner Lemberg <wl@gnu.org>
2000
Werner Lemberg6889f7b2014-11-24 17:16:08 +01002001 Remove all code related to FT_MAX_CHARMAP_CACHEABLE.
2002
2003 This is no longer used.
2004
2005 * src/base/ftobjs.c, src/cache/ftccmap.c, src/cff/cffobjs.c,
2006 src/sfnt/ttcmap.c: Do it.
2007
20082014-11-24 Werner Lemberg <wl@gnu.org>
2009
Werner Lembergf0292bb2014-11-24 10:51:21 +01002010 [sfnt] Fix Savannah bug #43680.
2011
2012 This adds an additional constraint to make the fix from 2013-01-25
2013 really work.
2014
2015 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_image) <index_format==4>:
2016 Check `p' before `num_glyphs'.
2017
20182014-11-24 Werner Lemberg <wl@gnu.org>
2019
Werner Lembergeca0f062014-11-24 10:22:08 +01002020 [truetype] Fix Savannah bug #43679.
2021
2022 * src/truetype/ttpload.c (tt_face_load_hdmx): Check minimum size of
2023 `record_size'.
2024
Jarkko Pöyry96341dc2014-11-24 09:53:07 +010020252014-11-24 Jarkko Pöyry <jarkko.poyry@gmail.com>
2026
2027 [cff, pfr, psaux, winfonts] Fix Savannah bug #43676.
2028
Werner Lemberged6a9df2014-12-06 23:28:58 +01002029 Don't cast cmap init function pointers to an incompatible type.
Jarkko Pöyry96341dc2014-11-24 09:53:07 +01002030
2031 Without this patch, the number of parameters between declaration and
2032 the real signature differs. Calling such a function results in
2033 undefined behavior.
2034
2035 ISO/IEC 9899:TC3 (Committee Draft September 7, 2007)
2036 6.5.2.2 Function calls
2037 9 If the function is defined with a type that is not
2038 compatible with the type (of the expression) pointed to by
2039 the expression that denotes the called function, the
2040 behavior is undefined.
2041
2042 On certain platforms (c -> js with emscripten) this causes
2043 termination of execution or invalid calls because in the emscripten
2044 implementation, function pointers of different types are stored in
2045 different pointer arrays. Incorrect pointer type here results in
2046 indexing of an incorrect array.
2047
2048 * src/cff/cffcmap.c (cff_cmap_encoding_init, cff_cmap_unicode_init),
2049 src/pfr/pfrcmap.c (pfr_cmap_init), src/psaux/t1cmap.c
2050 t1_cmap_standard_init, t1_cmap_expert_init, t1_cmap_custom_init,
2051 t1_cmap_unicode_init), src/winfonts/winfnt.c (fnt_cmap_init): Fix
2052 signature.
2053
Werner Lemberga7a42072014-11-24 06:44:45 +010020542014-11-24 Werner Lemberg <wl@gnu.org>
2055
Werner Lembergf70d9342014-11-24 09:31:32 +01002056 [sfnt] Fix Savannah bug #43672.
2057
2058 * src/sfnt/ttkern.c (tt_face_load_kern): Use correct value for
2059 minimum table length test.
2060
20612014-11-24 Werner Lemberg <wl@gnu.org>
2062
Werner Lemberg73be9f92014-11-24 07:30:05 +01002063 [type1, type42] Another fix for Savannah bug #43655.
2064
2065 * src/type1/t1load.c (parse_charstrings), src/type42/t42parse.c
2066 (t42_parse_charstrings): Add another boundary testing.
2067
20682014-11-24 Werner Lemberg <wl@gnu.org>
2069
Werner Lemberga7a42072014-11-24 06:44:45 +01002070 [docmaker] Formatting, copyright, improved documentation.
2071
2072 * src/tools/docmaker/*: No code changes besides trivial
2073 modifications.
2074
Werner Lemberg9bd20b72014-11-22 06:24:45 +010020752014-11-22 Werner Lemberg <wl@gnu.org>
2076
Werner Lembergaf834612014-11-22 13:29:10 +01002077 [bdf] Fix Savannah bug #43660.
2078
2079 * src/bdf/bdflib.c (_bdf_parse_glyphs) <"ENDFONT">: Check
2080 `_BDF_GLYPH_BITS'.
2081
20822014-11-22 Werner Lemberg <wl@gnu.org>
2083
Werner Lemberg42fcd662014-11-22 12:44:33 +01002084 [type42] Allow only embedded TrueType fonts.
2085
2086 This is a follow-up to Savannah bug #43659.
2087
2088 * src/type42/t42objs.c (T42_Face_Init): Exclusively use the
2089 `truetype' font driver for loading the font contained in the `sfnts'
2090 array.
2091
20922014-11-22 Werner Lemberg <wl@gnu.org>
2093
Werner Lemberg37881872014-11-22 10:46:47 +01002094 [type42] Fix Savannah bug #43659.
2095
2096 * src/type42/t42objs.c (T42_Open_Face): Initialize `face->ttf_size'.
2097
2098 * src/type42/t42parse.c (t42_parse_sfnts): Always set
2099 `face->ttf_size' directly. This ensures a correct stream size in
2100 the call to `FT_Open_Face', which follows after parsing, even for
2101 buggy input data.
2102 Fix error messages.
2103
21042014-11-22 Werner Lemberg <wl@gnu.org>
2105
Werner Lemberg5f201ab2014-11-22 09:16:39 +01002106 [cff] Fix Savannah bug #43658.
2107
2108 * src/cff/cf2ft.c (cf2_builder_lineTo, cf2_builder_cubeTo): Handle
2109 return values of point allocation routines.
2110
21112014-11-22 Werner Lemberg <wl@gnu.org>
2112
Werner Lemberg9bd20b72014-11-22 06:24:45 +01002113 [sfnt] Fix Savannah bug #43656.
2114
2115 * src/sfnt/ttcmap.c (tt_cmap4_validate): Fix order of validity
2116 tests.
2117
Werner Lemberg6de76172014-11-21 06:05:49 +010021182014-11-21 Werner Lemberg <wl@gnu.org>
2119
Werner Lembergdd897102014-11-21 22:19:28 +01002120 [type1, type42] Fix Savannah bug #43655.
2121
2122 * src/type1/t1load.c (parse_charstrings), src/type42/t42parse.c
2123 (t42_parse_charstrings): Fix boundary testing.
2124
21252014-11-21 Werner Lemberg <wl@gnu.org>
2126
Werner Lembergb1fc00d2014-11-21 12:06:40 +01002127 * src/pcf/pcfread.c (pcf_get_metrics): Sanitize invalid metrics.
2128
21292014-11-21 Werner Lemberg <wl@gnu.org>
2130
Werner Lemberg9154dab2014-11-21 08:03:51 +01002131 [ftlcdfil] Obey flow direction.
2132
2133 * src/base/ftlcdfil.c (_ft_lcd_filter_fir, _ft_lcd_filter_legacy):
2134 Handle `up' flow.
2135
21362014-11-21 Werner Lemberg <wl@gnu.org>
2137
Werner Lemberg644d6fa2014-11-21 07:28:50 +01002138 * src/base/ftbitmap.c (FT_Bitmap_Convert): Improve.
2139
2140 This commit completes argument checks and adds support for different
2141 flow directions.
2142
21432014-11-21 Werner Lemberg <wl@gnu.org>
2144
Werner Lemberg6de76172014-11-21 06:05:49 +01002145 * src/base/ftbitmap.c (FT_Bitmap_Copy): Improve.
2146
2147 This commit adds argument checks and support for different flow
2148 directions.
2149
Werner Lemberg1e6e1b82014-11-20 21:07:56 +010021502014-11-20 Werner Lemberg <wl@gnu.org>
2151
2152 * src/base/ftbitmap.c (FT_Bitmap_New): Check argument.
2153
Werner Lembergd6061212014-11-19 21:13:23 +010021542014-11-19 Werner Lemberg <wl@gnu.org>
2155
Werner Lembergb3500af2014-11-19 21:28:21 +01002156 Change some fields in `FT_Bitmap' to unsigned type.
2157
2158 This doesn't break ABI.
2159
2160 * include/ftimage.h (FT_Bitmap): Make `rows', `width', `num_grays',
2161 `pixel_mode', and `palette_mode' unsigned types.
2162
2163 * src/base/ftbitmap.c: Updated.
2164 (FT_Bitmap_Copy): Fix casts.
2165
2166 * src/cache/ftcsbits.c, src/raster/ftraster.c, src/sfnt/pngshim.c:
2167 Updated.
2168
21692014-11-19 Werner Lemberg <wl@gnu.org>
2170
Werner Lembergdf485772014-11-19 21:21:23 +01002171 Make `FT_Bitmap_Convert' correctly handle negative `pitch' values.
2172
2173 * src/base/ftbitmap.c (FT_Bitmap_Convert): Always use positive value
2174 for the pitch while copying data.
2175 Correctly set pitch sign in target bitmap.
2176
21772014-11-19 Werner Lemberg <wl@gnu.org>
2178
Werner Lembergd6061212014-11-19 21:13:23 +01002179 Minor code improvement in `FT_Bitmap_Embolden'.
2180
2181 * src/base/ftbitmap.c (FT_Bitmap_Embolden) <FT_PIXEL_MODE_GRAY[24]>:
2182 Fix thinko.
2183
Alexei Podtelezhnikovf841ad32014-11-19 21:19:06 -050021842014-11-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2185
2186 * src/base/fttrigon.c: Use dedicated `FT_Angle' for arctan table.
2187
Werner Lemberga67c43e2014-11-19 06:46:23 +010021882014-11-19 Behdad Esfahbod <behdad@behdad.org>
2189
2190 Avoid compiler warnings on x86-64 for `FT_MulFix'.
2191
2192 `FT_MulFix' takes `FT_Long' parameters as defined in `freetype.h',
2193 but several inline implementations of it in `ftcalc.h' take
2194 `FT_Int32' arguments. This is causing compiler warnings on x86-64:
2195 If parameters of type `FT_Fixed' (= `FT_Long') are passed to the
2196 inline implementation of this function, integer values are truncated
2197 from 64bit to 32bit.
2198
2199 * include/internal/ftcalc.h (FT_MulFix) [FT_MULFIX_ASSEMBLER]: Add
2200 casts.
2201
Werner Lemberg54abd222014-11-15 09:05:22 +010022022014-11-15 Werner Lemberg <wl@gnu.org>
2203
2204 [sfnt] Fix Savannah bug #43597.
2205
2206 * src/sfnt/pngshim.c (Load_SBit_Png): Protect against too large
2207 bitmaps.
2208
Werner Lemberg602040b2014-11-12 20:51:20 +010022092014-11-12 Werner Lemberg <wl@gnu.org>
2210
Werner Lemberg257c2702014-11-12 21:42:13 +01002211 [sfnt] Fix Savannah bug #43591.
2212
2213 * src/sfnt/ttsbit.c (tt_sbit_decoder_init): Protect against addition
2214 and multiplication overflow.
2215
22162014-11-12 Werner Lemberg <wl@gnu.org>
2217
Werner Lemberg677ddf42014-11-12 21:26:44 +01002218 [sfnt] Fix Savannah bug #43590.
2219
2220 * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir):
2221 Protect against addition overflow.
2222
22232014-11-12 Werner Lemberg <wl@gnu.org>
2224
Werner Lembergf46add12014-11-12 21:06:08 +01002225 [sfnt] Fix Savannah bug #43589.
2226
2227 * src/sfnt/sfobjs.c (woff_open_font): Protect against addition
2228 overflow.
2229
22302014-11-12 Werner Lemberg <wl@gnu.org>
2231
Werner Lemberg602040b2014-11-12 20:51:20 +01002232 [sfnt] Fix Savannah bug #43588.
2233
2234 * src/sfnt/ttcmap.c (tt_cmap8_validate, tt_cmap10_validate,
2235 tt_cmap12_validate, tt_cmap13_validate, tt_cmap14_validate): Protect
2236 against overflow in additions and multiplications.
2237
Alexei Podtelezhnikov2e73a1b2014-11-09 23:22:43 -050022382014-11-10 Alexei Podtelezhnikov <apodtele@gmail.com>
2239
2240 [base] CORDIC improvements.
2241
2242 The scaling between the hypotenuse and its CORDIC approximation is
2243 based on regression analysis. The smaller padding for `theta' is
2244 justifed by its maximum error of less than 6.
2245
2246 * src/base/fttrigon.c (ft_trig_downscale): Borrow code from
2247 ./ftcalc.c (ft_multo64), change linear intercept.
2248 (ft_trig_pseudo_polarize): Decrease `theta' padding.
2249
Werner Lemberg0e73d212014-11-09 01:27:38 +010022502014-11-09 Werner Lemberg <wl@gnu.org>
2251
2252 * src/base/ftstroke.c (ft_stroker_inside): Fix border intersections.
2253
2254 One more place to check whether `radius' is zero.
2255
2256 Problem reported by Marco Wertz <marco.wertz@gmx.de>.
2257
Werner Lemberg2c4832d2014-11-07 07:42:33 +010022582014-11-07 Werner Lemberg <wl@gnu.org>
2259
Werner Lemberg602040b2014-11-12 20:51:20 +01002260 [bdf] Fix Savannah bug #43535.
Werner Lemberg2c4832d2014-11-07 07:42:33 +01002261
2262 * src/bdf/bdflib.c (_bdf_strncmp): New macro that checks one
2263 character more than `strncmp'.
2264 s/ft_strncmp/_bdf_strncmp/ everywhere.
2265
Werner Lembergf49a1002014-11-06 13:30:28 +010022662014-11-06 Werner Lemberg <wl@gnu.org>
2267
Werner Lemberg602040b2014-11-12 20:51:20 +01002268 [pcf] Fix Savannah bug #43548.
Werner Lembergef1eba72014-11-06 23:25:05 +01002269
Werner Lemberg2c4832d2014-11-07 07:42:33 +01002270 * src/pcf/pcfread.c (pcf_get_encodings): Add sanity checks for row
2271 and column values.
Werner Lembergef1eba72014-11-06 23:25:05 +01002272
22732014-11-06 Werner Lemberg <wl@gnu.org>
2274
Werner Lemberg602040b2014-11-12 20:51:20 +01002275 [pcf] Fix Savannah bug #43547.
Werner Lemberg0e2f5d52014-11-06 22:32:46 +01002276
2277 * src/pcf/pcfread.c (pcf_read_TOC): Check `size' and `offset'
2278 values.
2279
22802014-11-06 Werner Lemberg <wl@gnu.org>
2281
Werner Lembergf49a1002014-11-06 13:30:28 +01002282 * src/pcf/pcfread.c (pcf_read_TOC): Avoid memory leak.
2283
Infinalityfacfc792014-11-03 07:24:59 +010022842014-11-03 Infinality <infinality@infinality.net>
2285
2286 * src/truetype/ttsubpix.c (COMPATIBILITY_MODE_Rules): Updated.
2287
2288 The previous commit deteriorates rendering of DejaVu and similar
2289 fonts; this gets compensated with this rule.
2290
Werner Lemberg706f7522014-11-03 07:20:57 +010022912014-11-03 Werner Lemberg <wl@gnu.org>
2292
2293 * src/truetype/ttinterp.c (Ins_DELTAP): Fix subpixel hinting.
2294
2295 Before this patch, it was impossible to ever call DELTAP[123] in
2296 subpixel hinting mode as described in the ClearType whitepaper; it
2297 only worked if in `compatibility mode'. However, compatibility mode
2298 essentially disables SHPIX, completely ruining hinting of
2299 ttfautohint output, for example.
2300
2301 We now follow the whitepaper more closely so that DELTAP[123]
2302 instructions for touched points in the non-subpixel direction are
2303 executed.
2304
Alexei Podtelezhnikove1efe0a2014-10-31 00:07:14 -040023052014-10-31 Alexei Podtelezhnikov <apodtele@gmail.com>
2306
Alexei Podtelezhnikov525d4872014-10-31 22:12:37 -04002307 [smooth] Improve code readability.
2308
2309 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Rearrange code.
2310
23112014-10-31 Alexei Podtelezhnikov <apodtele@gmail.com>
2312
Alexei Podtelezhnikove1efe0a2014-10-31 00:07:14 -04002313 [smooth] Reduce outline translations during rendering.
2314
2315 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Translate origin
2316 virtually by modifying cbox, actually translate outline if cumulative
2317 shift is not zero.
2318
Alexei Podtelezhnikovc7fd9352014-10-30 22:43:01 -040023192014-10-30 Alexei Podtelezhnikov <apodtele@gmail.com>
2320
2321 [smooth] Fix Savannah bug #35604 (cont'd).
2322
2323 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Remove checks and
2324 casts that became unnecessary after the variable type upgrades.
2325
Alexei Podtelezhnikov74916992014-10-29 22:24:24 -040023262014-10-29 Alexei Podtelezhnikov <apodtele@gmail.com>
2327
Alexei Podtelezhnikov465ab992014-10-29 23:45:23 -04002328 [smooth] Improve code readability.
2329
2330 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Rearrange code.
2331
23322014-10-29 Alexei Podtelezhnikov <apodtele@gmail.com>
2333
Alexei Podtelezhnikov74916992014-10-29 22:24:24 -04002334 Unify hypotenuse approximations.
2335
2336 * include/internal/ftcalc.h (FT_HYPOT): Move macro from here...
2337 * include/internal/ftobjs.h: ... to here, next to required `FT_ABS'.
2338 * src/smooth/ftgrays.c (gray_render_cubic): Use it here.
2339
Werner Lembergfe151522014-10-25 05:56:59 +020023402014-10-25 Werner Lemberg <wl@gnu.org>
2341
2342 [cff] Test valid darkening parameter macros in `ftoption.h'.
2343
2344 We no longer need an otherwise unused typedef that can cause a gcc
2345 warning.
2346 Problem reported by Alexei.
2347
2348 * src/cff/cffobjs.c (cff_driver_init): Use
2349 `CFF_CONFIG_OPTION_DARKENING_PARAMETER_XXX' macros directly.
2350 (SET_DARKENING_PARAMETERS): Removed.
2351 Compile time tests are now ...
2352
2353 * devel/ftoption.h, include/config/ftoption.h: ... here.
2354
Alexei Podtelezhnikovaba0f492014-10-24 23:50:57 -040023552014-10-25 Alexei Podtelezhnikov <apodtele@gmail.com>
2356
2357 Improve flat corner definition.
2358
2359 * include/internal/ftcalc.h (FT_HYPOT): Macro to approximate Euclidean
2360 distance with the alpha max plus beta min algorithm.
2361 * src/base/ftcalc.c (ft_corner_is_flat): Use it instead of Taxicab
2362 metric.
2363
David Weißdd8de1a2014-10-23 20:01:48 +020023642014-10-23 David Weiß <David.Weiss@ptvgroup.com>
2365
2366 [build] Improve property file for vc2010.
2367
2368 User-defined properties should be empty by default to prevent linker
2369 failures.
2370
2371 * builds/windows/vc2010/freetype.user.props,
2372 builds/windows/vc2010/freetype.vcxproj:
2373 s/OptionsDirectory/UserOptionDirectory/.
2374 Comment out all user options.
2375
Werner Lembergdd570e92014-10-23 19:57:37 +020023762014-10-23 Werner Lemberg <wl@gnu.org>
2377
2378 [cff] Work around bug in preprocessor of MSVC 2010.
2379
2380 We have been hit by
2381
2382 https://connect.microsoft.com/VisualStudio/feedback/details/718976/msvc-pr
2383
2384 * devel/ftoption.h, include/config/ftoption.h: Replace
2385 `CFF_CONFIG_OPTION_DARKENING_PARAMETERS' with eight macros
2386 `CFF_CONFIG_OPTION_DARKENING_PARAMETER_{X,Y}{1,2,3,4}'.
2387
2388 * src/cff/cffobjs.c (SET_DARKENING_PARAMETERS): Removed. We no
2389 longer need double expansion.
2390 (SET_DARKENING_PARAMETERS_0): Renamed to ...
2391 (SET_DARKENING_PARAMETERS): ... this.
2392 Update call.
2393
Werner Lembergcc7bb802014-10-20 08:35:50 +020023942014-10-20 Werner Lemberg <wl@gnu.org>
2395
2396 [sbit] Minor fixes.
2397
2398 * src/sfnt/ttsbit.c (tt_face_load_sbit) [TT_SBIT_TABLE_TYPE_SBIX]:
2399 Accept overlay format also, but emit warning message in that case.
2400 (tt_sbit_decoder_load_metrics): Add missing newline to error
2401 message.
2402 (tt_sbit_load_sbix_image): Add `rgbl' graphic type (as used on iOS
2403 7.1) to the list of unsupported formats.
2404
Alexei Podtelezhnikov118e6512014-10-19 23:31:08 -040024052014-10-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2406
2407 [truetype] Clean up bytecode rounding.
2408
2409 Zero distance does not have to be treated specially if you follow
2410 specifications and check the sign as the very last step of rounding.
2411
2412 * src/truetype/ttinterp.c (Round_None, Round_To_Grid,
2413 Round_Down_To_Grid, Round_Up_To_Grid, Round_To_Double_Grid): Use
2414 macros when available, do not check for non-zero distance.
2415 (Round_To_Half_Grid, Round_Super, Round_Super_45): Ditto, return phase
2416 if sign changed.
2417
Alexei Podtelezhnikovd4aabda2014-10-18 10:10:04 -040024182014-10-18 Alexei Podtelezhnikov <apodtele@gmail.com>
2419
2420 [truetype] Unwrap engine compensation settings.
2421
2422 * src/truetype/ttobjs.c (tt_size_init_bytecode): Updated.
2423
David Weißfede19e2014-10-18 14:59:20 +020024242014-10-18 David Weiß <David.Weiss@ptvgroup.com>
2425
2426 [build] Add property file to vc2010 project.
2427
2428 This simplifies custom build configurations, especially for
2429 automated build environments.
2430
2431 * builds/windows/vc2010/freetype.user.props: New configuration file.
2432
2433 * builds/windows/vc2010/freetype.vcxproj: Include
2434 `freetype.user.props' and use its data fields.
2435
2436 * builds/windows/vc2010/index.html: Updated.
2437
Werner Lembergc9c33f22014-10-18 11:01:14 +020024382014-10-18 Werner Lemberg <wl@gnu.org>
2439
2440 [autofit] Add blue-zone support for Telugu.
2441
2442 This essentially moves the Telugu script from the `Indic' hinter to
2443 the `Latin' hinter.
2444
2445 Note that this is a first shot and quite certainly needs
2446 refinements.
2447
2448 * src/autofit/afblue.dat: Add blue zone data for Telugu.
2449
2450 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2451
2452 * src/autofit/afscript.h: Add Telugu standard characters and move
2453 data out of AF_CONFIG_OPTION_INDIC block.
2454
2455 * src/autofit/afranges.c: Move Telugu data out of
2456 AF_CONFIG_OPTION_INDIC block.
2457
2458 * src/autofit/afstyles.h: Update Telugu data; in particular, use
2459 AF_WRITING_SYSTEM_LATIN.
2460
Werner Lemberg54306f52014-10-18 10:42:28 +020024612014-10-18 David Wimsey <david@wimsey.us>
2462
2463 [cmake] Add iOS build support.
Werner Lemberg1050aa92014-10-18 10:45:09 +02002464 From Savannah patch #8497.
Werner Lemberg54306f52014-10-18 10:42:28 +02002465
2466 * builds/cmake/iOS.cmake: New file. Universal binaries are built
2467 with both 32 and 64 bit arm architectures.
2468
2469 * CMakeLists.txt (IOS_PLATFORM): New variable for running the iOS
2470 toolchain. Possible values are `OS' to build on iOS, or
2471 `SIMULATOR' to build on APPLE.
2472
Werner Lemberg1a1750f2014-10-16 22:54:01 +020024732014-10-16 Behdad Esfahbod <behdad@behdad.org>
2474 Werner Lemberg <wl@gnu.org>
2475
2476 [cff] Add `CFF_CONFIG_OPTION_DARKENING_PARAMETERS' config macro.
2477
2478 * devel/ftoption.h, include/config/ftoption.h
2479 (CFF_CONFIG_OPTION_DARKENING_PARAMETERS): New macro.
2480
2481 * src/cff/cffobjs.c (SET_DARKENING_PARAMETERS,
2482 SET_DARKENING_PARAMETERS_0): New macros.
2483 (cff_driver_init): Use new macros.
2484
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -040024852014-10-14 Alexei Podtelezhnikov <apodtele@gmail.com>
2486
2487 [truetype] Limit delta shift range.
2488
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002489 The valid range for delta shift is zero through six. Negative values
2490 are invalid according to
2491
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -04002492 https://developer.apple.com/fonts/TrueType-Reference-Manual/RM04/Chap4.html#delta%20shift
2493
2494 * src/truetype/ttobjs.h (delta_shift, delta_base): Make unsigned.
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002495 * src/truetype/ttinterp.h (DO_SDS): Throw an error if `delta_shift'
2496 is out of range.
2497 (Ins_DELTAP, Ins_DELTAC): Optimize for valid `delta_shift'.
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -04002498
Werner Lemberg03987bf2014-10-16 07:19:46 +020024992014-10-16 Werner Lemberg <wl@gnu.org>
2500
2501 A better fix for Savannah bug #43392.
2502 Suggested by Doug Felt <dougfelt@gmail.com>.
2503
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002504 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics): Set
Werner Lemberg03987bf2014-10-16 07:19:46 +02002505 `vertAdvance' to zero...
2506
2507 * src/truetype/ttgload.c (TT_Load_Glyph): ... and set here a default
2508 value for `vertAdvance' based on `linearVertAdvance' in case
2509 `vertAdvance' is zero. Note that the previous computed ad-hoc value
2510 for `linearVertAdvance' was apparently not tested in a real-life
2511 situation.
2512
David Weiß3889cb22014-10-14 11:35:16 +020025132014-10-14 David Weiß <David.Weiss@ptvgroup.com>
2514
2515 [build] Better optimization settings for vc2010 solution file.
2516
2517 * builds/windows/vc2010/freetype.sln,
2518 builds/windows/vc2010/freetype.vcxproj: Updated.
2519
Werner Lemberg8f178092014-10-14 08:28:09 +020025202014-10-14 Werner Lemberg <wl@gnu.org>
2521
2522 [autofit] Adjust Devenagari character range.
2523
2524 * src/autofit/afranges.c (af_deva_uniranges): Omit characters that
2525 are common to all other Indic scripts.
2526
Werner Lemberg1ca5fa12014-10-12 08:31:32 +020025272014-10-12 Werner Lemberg <wl@gnu.org>
2528
2529 [sfnt] Fix Savannah bug #43392.
2530
2531 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics): Don't let
2532 vertical metrics uninitialized.
2533
Alexei Podtelezhnikov673a28e2014-10-11 14:40:51 -040025342014-10-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2535
2536 [base] Small bbox correction.
2537
2538 * src/base/ftbbox.c (FT_Outline_Get_BBox): Start from nonsense bbox
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002539 instead of initial point that could be `off' in conic outlines.
Alexei Podtelezhnikov673a28e2014-10-11 14:40:51 -04002540
Alexei Podtelezhnikov2ffcf172014-10-08 22:01:08 -040025412014-10-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2542
Alexei Podtelezhnikov40dac112014-10-09 00:58:14 -04002543 [base] Fix Savannah bug #43356.
2544
2545 * src/base/ftbbox.c (BBox_Move_To, BBox_Conic_To): Update bbox in case
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002546 of implicit `to'.
Alexei Podtelezhnikov40dac112014-10-09 00:58:14 -04002547 (BBox_Line_To): New emitter that does not update bbox.
2548
25492014-10-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2550
Alexei Podtelezhnikov2ffcf172014-10-08 22:01:08 -04002551 [base] Introduce and use new macro `FT_UPDATE_BBOX'
2552
2553 * src/base/ftbbox.c (FT_UPDATE_BBOX): New macro.
2554 (FT_Outline_Get_BBox): Use it here.
2555
Alexei Podtelezhnikov7abdb8c2014-10-02 23:13:33 -040025562014-10-02 Alexei Podtelezhnikov <apodtele@gmail.com>
2557
2558 [base] Significant optimization of `ft_div64by32'
2559
2560 We shift as many bits as we can into the high register, perform
2561 32-bit division with modulo there, then work through the remaining
2562 bits with long division. This optimization is especially noticeable
2563 for smaller dividends that barely use the high register.
2564
2565 * src/base/ftcalc.c (ft_div64by32): Updated.
2566
Dave Arnold537c55d2014-10-02 06:32:32 +020025672014-10-02 Dave Arnold <darnold@adobe.com>
2568
2569 [cff] Fix Savannah bug #43271.
2570
2571 * src/cff/cf2font.c (cf2_computeDarkening): Change overflow
2572 detection to use logarithms and clamp `scaledStem'.
2573
Alexei Podtelezhnikov418e18f2014-10-01 22:36:40 -040025742014-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
2575
Alexei Podtelezhnikov74d0aad2014-10-01 23:27:15 -04002576 * src/base/ftcalc.c: Remove miscellaneous type casts.
2577
25782014-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
2579
Alexei Podtelezhnikov418e18f2014-10-01 22:36:40 -04002580 [base] Use more common `FT_MSB' implementation with masks.
2581
2582 * src/base/ftcalc.c (FT_MSB): Updated.
2583
Alexei Podtelezhnikov955aff12014-09-30 23:09:39 -040025842014-09-30 Alexei Podtelezhnikov <apodtele@gmail.com>
2585
2586 [base] Clean up.
2587
2588 * src/base/ftcalc.c (FT_MOVE_SIGN): New macro for frequently used
2589 code.
2590
Alexei Podtelezhnikov7f491112014-09-25 22:54:38 -040025912014-09-25 Alexei Podtelezhnikov <apodtele@gmail.com>
2592
2593 [base] Avoid unnecessary long division.
2594
2595 This applies to `FT_MulDiv' but not to `FT_DivFix', where overflows or
2596 lack thereof are predicted accurately.
2597
2598 * src/base/ftcalc.c (ft_div64by32): Improve readability.
2599 (FT_MulDiv, FT_MulDiv_No_Round) [!FT_LONG64]: Use straight division
2600 when multiplication stayed within 32 bits.
2601
Werner Lemberg5b68e4f2014-09-24 19:06:13 +020026022014-09-24 Werner Lemberg <wl@gnu.org>
2603
2604 [autofit] Minor clean-ups.
2605
2606 * src/autofit/afhints.c (AF_FLAGS): Remove obsolete values.
2607
2608 * src/autofit/afhints.c (af_glyph_hints_dump_points,
2609 af_glyph_hints_align_strong_points): Updated.
2610
2611 * src/autofit/aflatin.c (af_latin_hints_link_segments,
2612 af_latin_hints_compute_segments), src/autofit/afcjk.c
2613 (af_cjk_hints_link_segments), src/autofit/aflatin2.c
2614 (af_latin2_hints_link_segments, af_latin2_hints_compute_segments):
2615 There are no longer fake segments since more than 10 years...
2616
Werner Lemberg387a9fe2014-09-22 06:42:24 +020026172014-09-22 Werner Lemberg <wl@gnu.org>
2618
2619 [autofit] Minor code streamlining.
2620
2621 * src/autofit/afhints.c (af_axis_hints_new_edge): Remove redundant
2622 initialization.
2623
Alexei Podtelezhnikov5c894842014-09-19 22:03:15 -040026242014-09-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2625
2626 * src/base/ftcalc.c: Harmonize code.
2627
26282014-09-15 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04002629
Alexei Podtelezhnikovef070d42014-09-15 22:06:19 -04002630 [base] Tighten the overflow check in `FT_MulDiv'.
2631
2632 * src/base/ftcalc.c (FT_MulDiv) [!FT_LONG64]: Updated.
2633
26342014-09-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2635
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04002636 Fix Savannah bug #43153.
2637
2638 * src/psaux/psconv.c (PS_Conv_ToFixed): Add protection against
Alexei Podtelezhnikov7abdb8c2014-10-02 23:13:33 -04002639 overflow in `divider'.
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04002640
Alexei Podtelezhnikov32128522014-09-03 21:57:42 -040026412014-09-03 Alexei Podtelezhnikov <apodtele@gmail.com>
2642
Alexei Podtelezhnikov336735d2014-09-03 22:55:26 -04002643 [base] Tighten the overflow check in `FT_DivFix'.
2644
2645 This fixes a 13-year old bug. The original overflow check should have
2646 been updated when rounding was introduced into this function
2647 (c2cd00443b).
2648
2649 * src/base/ftcalc.c (FT_DivFix) [!FT_LONG64]: Updated.
2650 * include/freetype.h (FT_DivFix): Updated documentation.
2651
26522014-09-03 Alexei Podtelezhnikov <apodtele@gmail.com>
2653
Alexei Podtelezhnikov32128522014-09-03 21:57:42 -04002654 [base] Tighten the overflow check in `FT_MulFix'.
2655
2656 * src/base/ftcalc.c (FT_MulFix) [!FT_LONG64]: Updated.
2657
Alexei Podtelezhnikov125c3ca2014-09-02 22:38:59 -040026582014-09-02 Alexei Podtelezhnikov <apodtele@gmail.com>
2659
2660 [truetype] Shortcut ppem calculations for square pixels.
2661
2662 * src/truetype/ttinterp.h (TT_ExecContextRec): New field
2663 `cur_ppem_func' with a function pointer.
2664 * src/truetype/ttinterp.c (TT_RunIns): Initialize `cur_ppem_func'
2665 depending on the pixel geometry to either...
2666 (Current_Ppem_Stretched): ... this for stretched pixels.
2667 (Current_Ppem): ... or this for square pixels.
2668 (DO_MPPEM, DO_MPS, Ins_DELTAP, Ins_DELTAC): Use `cur_ppem_func'.
2669
Behdad Esfahbod1ec98b22014-08-31 08:47:11 +020026702014-08-31 Behdad Esfahbod <behdad@behdad.org>
2671
2672 Don't use `register' keyword. Fixes compiler warnings.
2673
2674 * src/base/ftcalc.c (FT_Add64) [!FT_LONG64]: Do it.
2675 * src/gzip/inftrees.c (huft_build): Ditto.
2676 * src/truetype/ttinterp.c (TT_MulFix14_arm): Ditto.
2677
Alexei Podtelezhnikova8bc49e2014-08-24 22:14:01 -040026782014-08-24 Alexei Podtelezhnikov <apodtele@gmail.com>
2679
Alexei Podtelezhnikov125c3ca2014-09-02 22:38:59 -04002680 [truetype] Optimize DELTAP and DELTAC.
Alexei Podtelezhnikova8bc49e2014-08-24 22:14:01 -04002681
2682 * src/truetype/ttinterp.c (Ins_DELTAP, Ins_DELTAC): Move ppem
2683 calculations outside of the loop.
2684
Alexei Podtelezhnikov98688592014-08-21 23:28:52 -040026852014-08-21 Alexei Podtelezhnikov <apodtele@gmail.com>
2686
2687 Fix Savannah bug #43033.
2688
2689 * include/config/ftconfig.h, builds/unix/ftconfig.in,
2690 builds/vms/ftconfig.h [FT_LONG64]: Do not disable the macro when
2691 64-bit type is `long'.
2692
Alexei Podtelezhnikov8fd87d42014-08-20 00:57:22 -040026932014-08-20 Alexei Podtelezhnikov <apodtele@gmail.com>
2694
2695 [base] Small optimization of `FT_MulFix'.
2696
2697 * src/base/ftcalc.c (FT_MulFix): Loosen up the condition for direct
2698 32-bit calculations.
2699
Alexei Podtelezhnikovf09326a2014-08-20 00:08:38 -040027002014-08-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2701
2702 [base] Use unsigned calculation in `FT_MulDiv'.
2703
2704 * src/base/ftcalc.c (FT_MulDiv): Updated to expand 32-bit range.
2705
Alexei Podtelezhnikov382f3152014-08-18 23:16:15 -040027062014-08-18 Alexei Podtelezhnikov <apodtele@gmail.com>
2707
2708 [base] Remove truncation in `FT_DivFix'.
2709
2710 * src/base/ftcalc.c (FT_DivFix): Updated.
2711
Alexei Podtelezhnikov5ef20232014-08-14 23:21:46 -040027122014-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
2713
2714 Minor refactoring.
2715
2716 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round): Updated.
2717
27182014-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovc7022462014-08-14 23:01:01 -04002719
2720 Turn FT_MSB into a macro when using gcc builtins.
2721
2722 * src/base/ftcalc.c, include/internal/ftcalc.h: Updated.
2723
Alexei Podtelezhnikovf8efbcf2014-08-12 23:22:17 -040027242014-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
2725
2726 [base] Avoid undefined FT_MSB in `BBox_Cubic_Check'.
2727
2728 * src/base/ftbbox.c (BBox_Cubic_Check): Update.
2729 (update_cubic_max): Repalce with...
2730 (cubic_peak): ... this, which now handles upscaling.
2731
Alexei Podtelezhnikov47289932014-08-11 23:39:34 -040027322014-08-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2733
Alexei Podtelezhnikov28018d42014-08-12 00:26:16 -04002734 [base] Handle collapsed outlines to avoid undefined FT_MSB.
2735
2736 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Update.
2737
27382014-08-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2739
Alexei Podtelezhnikov47289932014-08-11 23:39:34 -04002740 [base] Restore FT_MulFix inlining.
2741
2742 * include/freetype.h (FT_MulFix): Unconditionally defined.
2743
2744 * src/base/ftcalc.c [FT_MULFIX_ASSEMBLER]: Move code from here...
2745
2746 * include/internal/ftcalc.h [FT_MULFIX_ASSEMBLER]: ... to here,
2747 which conditionally replaces the function with an inline version
2748 through the macro.
2749
Alexei Podtelezhnikov90be4b62014-08-08 22:27:10 -040027502014-08-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2751
2752 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Refactor.
2753
Werner Lembergd17cabf2014-07-26 09:53:50 +090027542014-07-26 Werner Lemberg <wl@gnu.org>
2755
2756 [cff] Fix typo.
2757
2758 * src/cff/cf2hints.c (cf2_glyphpath_computeOffset): Use correct
2759 offsets in third quadrant.
2760
2761 Reported by maks <maksqwe1@ukr.net>.
2762
Werner Lemberg4e754132014-07-17 17:34:49 +090027632014-07-17 Werner Lemberg <wl@gnu.org>
2764
2765 Fix Savannah bug #42788.
2766
2767 * src/pfr/pfrobjs.c: Include `ftcalc.h'.
2768
Alexei Podtelezhnikovc0a6f202014-07-16 22:05:56 -040027692014-07-16 Alexei Podtelezhnikov <apodtele@gmail.com>
2770
2771 Replace `ft_highpow2' function.
2772
2773 * src/pfr/pfrobjs.c (pfr_face_get_kerning): Use `FT_MSB' instead of
2774 `ft_highpow2'.
2775
2776 * src/base/ftutil.c, include/internal/ftobjs.h (ft_highpow2): Remove
2777 it.
2778
Alexei Podtelezhnikov71330ce2014-07-15 23:30:45 -040027792014-07-15 Alexei Podtelezhnikov <apodtele@gmail.com>
2780
Werner Lembergcbbf26b2014-07-17 17:27:12 +09002781 * src/base/ftcalc.c (FT_MSB): Utilize gcc builtins.
Alexei Podtelezhnikov177982e2014-07-15 23:54:34 -04002782
27832014-07-15 Alexei Podtelezhnikov <apodtele@gmail.com>
2784
Alexei Podtelezhnikov71330ce2014-07-15 23:30:45 -04002785 [base] Move assembler code back in the source file.
2786
2787 FT_MulFix assembler used to reside in ftcalc.c before f47d263f1b.
2788
2789 * include/config/ftconfig.h, builds/unix/ftconfig.in,
2790 builds/vms/ftconfig.h [FT_MULFIX_ASSEMBLER]: Move code from here...
2791
2792 * src/base/ftcalc.c [FT_MULFIX_ASSEMBLER]: ... to here.
2793
27942014-07-14 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov1183cd42014-07-14 22:30:55 -04002795
2796 [base] Further clean up color bitmap conversion.
2797
2798 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Stop
2799 using FT_MulFix and FT_DivFix since all calculations fit into 32 bits.
2800
Werner Lemberg441b3f32014-07-13 02:28:14 +090028012014-07-13 Werner Lemberg <wl@gnu.org>
2802
2803 [truetype] Improve handling of buggy `prep' tables.
2804
2805 In case of an error in the `prep' table, no longer try to execute it
2806 again and again. This makes FreeType handle endless loops in buggy
2807 fonts much faster.
2808
2809 * src/truetype/ttobjs.h (TT_SizeRec): The fields `bytecode_ready'
2810 and `cvt_ready' are now negative if not initialized yet, otherwise
2811 they indicate the error code of the last run.
2812
2813 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep,
2814 tt_size_done_bytecode, tt_size_init_bytecode,
2815 tt_size_ready_bytecode, tt_size_init, tt_size_done, tt_size_reset):
2816 Updated.
2817
2818 * src/truetype/ttgload.c (tt_loader_init): Updated.
2819 * src/truetype/ttinterp.c (TT_RunIns): Force reexecution of `fpgm'
2820 and `prep' only if we are in the `glyf' table.
2821
Werner Lemberge98e2bc2014-07-12 16:37:39 +090028222014-07-12 Werner Lemberg <wl@gnu.org>
2823
2824 * builds/vms/ftconfig.h: Synchronize.
2825 Problem reported by Alexei.
2826
Alexei Podtelezhnikov35576bf2014-07-11 22:40:34 -040028272014-07-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2828
2829 [base] Clean up bitmap conversion.
2830
2831 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
2832 appropriate FT_DivFix and remove superfluous upscaling.
2833
Alexei Podtelezhnikovceab95a2014-07-04 23:01:32 -040028342014-07-04 Alexei Podtelezhnikov <apodtele@gmail.com>
2835
2836 [base] Small optimization of the ancient code.
2837
2838 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round): Loosen up the
2839 condition for direct 32-bit calculations.
2840
Werner Lemberg38975562014-06-27 06:55:56 +020028412014-06-27 Werner Lemberg <wl@gnu.org>
2842
2843 Fix Apple standard glyph names.
2844
2845 * src/sfnt/ttpost.c (tt_post_default_names): Synchronize with
2846 `tools/glnames.py'
2847
2848 Problem reported by Adam Twardoch <adam@fontlab.com>.
2849
Werner Lembergcf2347c2014-06-17 09:01:04 +020028502014-06-17 Werner Lemberg <wl@gnu.org>
2851
Werner Lemberg231171f2014-06-17 09:14:32 +02002852 Partially revert commit from 2014-06-13.
2853
2854 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Move
2855 declaration of `p_first' and `p_last' out of the loop.
2856
28572014-06-17 Werner Lemberg <wl@gnu.org>
2858
Werner Lembergcf2347c2014-06-17 09:01:04 +02002859 * builds/unix/freetype2.m4: s/AC_PATH_PROG/AC_PATH_TOOL/.
2860
2861 This simplifies cross-compiling.
2862
Werner Lemberg6497b9c2014-06-13 09:28:00 +020028632014-06-13 Werner Lemberg <wl@gnu.org>
2864
Werner Lemberge5c0fff2014-06-13 14:01:20 +02002865 Fix more compiler warnings.
2866 Reported by Wojciech Mamrak <wmamrak@gmail.com>.
2867
2868 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
2869 Make integer constant unsigned.
2870
2871 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
2872 <TT_SBIT_TABLE_TYPE_SBIX>: Fix types.
2873 (tt_sbit_decoder_load_compound, tt_face_load_sbix_image): Add proper
2874 casts.
2875
28762014-06-13 Werner Lemberg <wl@gnu.org>
2877
Werner Lemberg6497b9c2014-06-13 09:28:00 +02002878 Fix compiler warnings.
2879 Reported by Wojciech Mamrak <wmamrak@gmail.com>.
2880
2881 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage),
Werner Lembergcbbf26b2014-07-17 17:27:12 +09002882 src/autofit/afmodule.c (af_property_set): Fix `signed' vs.
Werner Lemberg6497b9c2014-06-13 09:28:00 +02002883 `unsigned' issues.
2884
2885 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Make compiler
2886 happy.
2887
2888 * src/base/ftlcdfil.c (_ft_lcd_filter_fir): Use only four elements
2889 for `fir'.
2890 Fix `signed' vs. `unsigned' issues.
2891
2892 * src/sfnt/sfobjs.c (WRITE_BYTE): Removed, unused.
2893 (WRITE_USHORT, WRITE_ULONG): Add proper casts.
2894
2895 * src/truetype/ttgload.c (TT_Get_VMetrics): Add proper casts.
2896
2897 * src/truetype/ttinterp.c (Ins_DELTAP): Add proper casts for `B1'
2898 and `B2'.
2899
Alexey Petruchik02f21702014-05-16 08:09:43 +020029002014-05-16 Alexey Petruchik <alexey.petruchik@gmail.com>
2901
2902 [cmake] Add option to build OS X framework.
2903
2904 * CMakeLists.txt: Update accordingly.
2905
2906 * builds/mac/freetype-Info.plist: New file.
2907
Pavel Koshevoy15da66a2014-05-13 07:33:48 +020029082014-05-13 Pavel Koshevoy <pkoshevoy@gmail.com>
2909
2910 * CMakeLists.txt (BASE_SRCS): Add missing `ftbdf.c'.
2911
Werner Lemberg07e7b8a2014-05-11 08:00:25 +020029122014-05-11 Werner Lemberg <wl@gnu.org>
2913
Werner Lembergfaa21472014-05-11 12:44:00 +02002914 [autofit] Fix variable initializations.
2915
2916 * src/autofit/afhints.c (af_glyph_hints_reload): Assign default
2917 values to `in_dir' and `out_dir' for all points.
2918
29192014-05-11 Werner Lemberg <wl@gnu.org>
2920
Werner Lemberg07e7b8a2014-05-11 08:00:25 +02002921 [autofit] Fix crash with font `CabinSketch-Bold.ttf'.
2922
2923 Problem reported by Ralf S. Engelschall <rse@engelschall.com>.
2924
2925 * src/autofit/afhints.c (af_glyph_hints_reload): Fix threshold for
2926 finding first non-near point.
2927 Properly initialize non-near point deltas.
2928
Werner Lemberg63bef9a2014-05-01 07:16:05 +020029292014-05-01 Werner Lemberg <wl@gnu.org>
2930
Werner Lembergc576bb02014-05-01 17:24:19 +02002931 [autofit] Add blue-zone support for Devanagari.
2932
2933 This essentially moves the Devanagari script from the `Indic' hinter
2934 to the `Latin' hinter. Thanks to Girish Dalvi
2935 <girish.dalvi@gmail.com> for guidance with blue zone characters!
2936
2937 * src/autofit/afblue.dat: Add blue zone data for Devanagari.
2938
2939 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2940
2941 * src/autofit/afscript.h: Add Devanagari standard characters and
2942 move data out of AF_CONFIG_OPTION_INDIC block.
2943
2944 * src/autofit/afranges.c: Move Devanagari data out of
2945 AF_CONFIG_OPTION_INDIC block.
2946 Move U+20B9, (new) Rupee sign, from Latin to Devanagari.
2947
2948 * src/autofit/afstyles.h: Update Devanagari data; in particular, use
2949 AF_WRITING_SYSTEM_LATIN.
2950
29512014-05-01 Werner Lemberg <wl@gnu.org>
2952
Werner Lemberg63bef9a2014-05-01 07:16:05 +02002953 [autofit] Fix handling of neutral blue zones in stems.
2954
2955 * src/autofit/afhints.h (AF_Edge_Flags): New value
2956 `AF_EDGE_NEUTRAL'.
2957
2958 * src/autofit/aflatin.c (af_latin_hints_compute_blue_edges): Trace
2959 neutral blue zones with AF_EDGE_NEUTRAL.
2960 (af_latin_hint_edges): Skip neutral blue zones if necessary.
2961
Werner Lembergccfc4b42014-04-28 21:13:14 +020029622014-04-28 Werner Lemberg <wl@gnu.org>
2963
2964 [autofit] Introduce neutral blue zones to the latin module.
2965
2966 Such blue zones match either the top or the bottom of a contour. We
2967 need them for scripts where accent-like elements directly touch the
2968 base character (for example, some vowel signs in Devanagari, cf.
2969 U+0913 or U+0914).
2970
2971 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_NEUTRAL): New
2972 property.
2973
2974 * src/autofit/afblue.h: Regenerated.
2975
2976 * src/autofit/aflatin.h (AF_LATIN_IS_NEUTRAL_BLUE): New macro.
2977 (AF_LATIN_BLUE_NEUTRAL): New enumeration value.
2978
2979 * src/autofit/aflatin.c (af_latin_metrics_init_blues,
2980 af_latin_hints_compute_blue_edges): Handle neutral blue zones.
2981
Werner Lembergabb3fca2014-04-25 22:13:32 +020029822014-04-25 Werner Lemberg <wl@gnu.org>
2983
2984 * src/autofit/hbshim.c: Partially revert commit from 2014-04-17.
2985
2986 Using input glyph coverage data is simply wrong.
2987
2988 Problem reported by Nikolaus Waxweiler <madigens@gmail.com> and
2989 Mantas MikulÄ—nas <grawity@gmail.com>.
2990
Werner Lembergf1936372014-04-23 08:22:33 +020029912014-04-23 Werner Lemberg <wl@gnu.org>
2992
2993 * src/raster/ftraster.c (Vertical_Sweep_Span): Use drop-out mode.
2994
2995 This spot has been missed while introducing support for various
2996 drop-out modes years ago (including no drop-out mode, which this
2997 commit fixes).
2998
2999 Problem reported by Patrick Thomas <pthomas505@gmail.com>.
3000
Werner Lembergd9b44702014-04-22 07:33:07 +020030012014-04-22 Werner Lemberg <wl@gnu.org>
3002
3003 * src/sfnt/pngshim.c (error_callback): s/longjmp/ft_longjmp/.
3004
Werner Lemberg98e510e2014-04-20 22:11:27 +020030052014-04-20 Werner Lemberg <wl@gnu.org>
3006
3007 [autofit] Fix Savannah bug #42148.
3008
3009 The adaptation of the cjk auto-hinter module to blue stringsets in
3010 2013-08-25 had three severe bugs. Mea culpa.
3011
3012 1. Contrary to the latin auto-hinter, characters for reference and
3013 overshoot values of a blue zone are specified separately. Due to
3014 the screwed-up change it didn't work at all.
3015
3016 2. A boolean comparison was erroneously replaced with a cast,
3017 causing invalid results with the `^' operator later on. The
3018 visual artifact caused by this problem is the topic of the bug
3019 report.
3020
3021 3. Two flag values were inverted, causing incorrect assignment of
3022 reference and overshoot values.
3023
3024 * src/autofit/afblue.dat: Fix CJK bluestrings, introducing a new
3025 syntax to have both reference and overshoot characters in a single
3026 string. This is error #1.
3027 Add extensive comments.
3028
3029 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_CJK_FILL): Removed, no
3030 longer used.
Werner Lembergccfc4b42014-04-28 21:13:14 +02003031 (AF_BLUE_PROPERTY_CJK_TOP, AF_BLUE_PROPERTY_CJK_HORIZ): Fix values.
Werner Lemberg98e510e2014-04-20 22:11:27 +02003032 This is error #3.
3033
3034 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
3035
3036 * src/autofit/afcjk.c (af_cjk_metrics_init_blues): Correct error #1.
3037 Use character `|' to separate characters for reference and overshoot
3038 values.
3039 Improve tracing messages, synchronizing them with the latin
3040 auto-hinter.
Werner Lembergccfc4b42014-04-28 21:13:14 +02003041 (af_cjk_hints_compute_blue_edges): Fix value of `is_top_right_blue'.
Werner Lemberg98e510e2014-04-20 22:11:27 +02003042 This is error #2.
3043 (af_cjk_align_linked_edge): Add tracing message.
3044
3045 * src/autofit/afcjk.h (AF_CJK_IS_FILLED_BLUE): Removed, no longer
3046 used.
3047
Werner Lembergbbd83132014-04-17 01:24:36 +020030482014-04-17 Werner Lemberg <wl@gnu.org>
3049
Werner Lemberg8c7fb782014-04-17 15:53:25 +02003050 [autofit] More coverage fixes for complex scripts.
3051
3052 * src/autofit/hbshim.c (af_get_coverage): Merge input glyph coverage
3053 of GSUB lookups into output coverage. Otherwise, ligatures are not
3054 handled properly.
3055 Don't check blue zone characters for default coverage.
3056
30572014-04-17 Werner Lemberg <wl@gnu.org>
3058
Werner Lembergbbd83132014-04-17 01:24:36 +02003059 Make `FT_Get_SubGlyph_Info' actually work.
3060
3061 * src/base/ftobjs.c (FT_Get_SubGlyph_Info): Return FT_Err_Ok
3062 if there is no error.
3063
Werner Lemberg181fd072014-04-15 16:47:05 +020030642014-04-15 Werner Lemberg <wl@gnu.org>
3065
3066 [afblue.pl]: Minor improvements.
3067
3068 * src/tools/afblue.pl: Allow whitespace before comments.
3069 Ignore whitespace in strings.
3070
Werner Lemberg8b1f2a62014-04-14 07:58:19 +020030712014-04-14 Werner Lemberg <wl@gnu.org>
3072
3073 [autofit] Improve coverage handling.
3074
3075 * src/autofit/hbshim.c (af_get_coverage): Don't exclude glyphs
3076 appearing in the GPOS table if we are processing the default
3077 coverage.
3078
David Weber76307872014-04-13 15:41:13 +020030792014-04-13 David Weber <weber.aulendorf@googlemail.com>
3080
3081 [smooth] Fix stand-alone compilation.
3082
3083 * src/smooth/ftgrays.c (FT_BEGIN_STMNT, FT_END_STMNT): Define.
3084
Werner Lemberg8a94b1e2014-04-12 20:44:33 +020030852014-04-12 Werner Lemberg <wl@gnu.org>
3086
3087 [autofit] Redesign the recognition algorithm of strong points.
3088
3089 In particular, local extrema without horizontal or vertical segments
3090 are better recognized:
3091
3092 + A + D
3093 \ /
3094 \ /
3095 \ /
3096 \ /
3097 \ + C
3098 \ /
3099 B +/
3100
3101 If the distances AB and CD are large, point B wasn't previously
3102 detected as an extremum since the `ft_corner_is_flat' function
3103 `swallowed' BC regardless of its direction, tagging point B as weak.
3104 The next iteration started at B and made `ft_corner_is_flat' swallow
3105 point C, tagging it as weak also, et voilà.
3106
3107 To improve that, another pass gets now performed before calling
3108 `ft_corner_is_flat' to improve the `topology' of an outline: A
3109 sequence of non-horizontal or non-vertical vectors that point into
3110 the same quadrant are handled as a single, large vector.
3111
3112 Additionally, distances of near points are now accumulated, which
3113 makes the auto-hinter handle them as if they were prepended to the
3114 next non-near vector.
3115
3116 This generally improves the auto-hinter's rendering results.
3117
3118 * src/autofit/afhints.c (af_glyph_hints_reload): Implement it.
3119
3120 * src/autofit/afhints.h (AF_FLAGS): Remove no longer used flag
3121 `AF_FLAG_NEAR'.
3122
Werner Lemberg71f53e12014-04-05 16:27:19 +020031232014-04-05 Werner Lemberg <wl@gnu.org>
3124
3125 [autofit] Improve scoring algorithm for identifying stems.
3126
3127 Problem reported by Karsten Lücke <karsten.luecke@kltf.de>.
3128
3129 The new algorithm takes care of the width of stems: If the distance
3130 between two segments is larger than the largest stem width, the
3131 demerits quickly increase for larger distances. This improves
3132 hinting of slanted fonts (especially if the inner parts of serifs
3133 have non-horizontal `shoulders'), avoiding false stem links.
3134
3135 * src/autofit/aflatin.c (af_latin_hints_link_segments): Use largest
3136 stem width (if available) to compute better demerits for distances
3137 between stems.
3138 (af_latin_hints_detect_features): Pass stem width array and array
3139 size.
3140 (af_latin_metrics_init_widths): Updated to use original algorithm.
3141 (af_latin_hints_apply): Updated to use new algorithm.
3142
3143 * src/autofit/aflatin.h: Updated.
3144 * src/autofit/afcjk.c: Updated.
3145
Werner Lembergf8555b52014-04-03 05:45:38 +020031462014-04-03 Werner Lemberg <wl@gnu.org>
3147
3148 Don't require `gzip' module for `sfnt'.
3149
3150 Reported by Preet <prismatic.project@gmail.com>.
3151
3152 * src/sfnt/sfobjs.c (woff_open_font): Guard use of
3153 FT_Gzip_Uncompress with FT_CONFIG_OPTION_USE_ZLIB.
3154
Werner Lembergf41070f2014-03-27 17:38:23 +010031552014-03-27 Werner Lemberg <wl@gnu.org>
3156
3157 Fix Savannah bug #38235.
3158
3159 Work around a bug in pkg-config version 0.28 and earlier: If a
3160 variable value gets surrounded by doublequotes (in particular values
3161 for the `prefix' variable), the prefix override mechanism fails.
3162
3163 * builds/unix/freetype2.in: Don't use doublequotes.
3164 * builds/unix/unix-def.in (freetype.pc): Escape spaces in directory
3165 names with backslashes.
3166
Werner Lembergab76d972014-03-24 19:45:03 +010031672014-03-24 Werner Lemberg <wl@gnu.org>
3168
3169 Fix Savannah bug #41946.
3170
3171 Based on a patch from Marek Kašík <mkasik@redhat.com>.
3172
3173 * builds/unix/configure.raw (LIBS_CONFIG): Remove.
3174 * builds/unix/freetype-config.in (libs): Hard-code value.
3175 * builds/unix/unix-def.in: Updated.
3176
Werner Lembergd5159922014-03-22 06:20:54 +010031772014-03-22 Werner Lemberg <wl@gnu.org>
3178
3179 Another revert for the change from 2014-03-18.
3180
3181 Problem reported by Nikolaus Waxweiler <madigens@gmail.com>.
3182
3183 * src/base/ftcalc.c (FT_MulFix): Ensure that an `FT_MulFix' symbol
3184 gets always exported.
3185
Werner Lembergf0c471a2014-03-20 07:13:12 +010031862014-03-20 Werner Lemberg <wl@gnu.org>
3187
3188 CMakeLists.txt: Another fix for include directories.
3189
3190 Problem reported by Taylor Holberton <taylorcholberton@gmail.com>.
3191
Werner Lembergcc7cf2c2014-03-19 07:35:35 +010031922014-03-19 Werner Lemberg <wl@gnu.org>
3193
Werner Lemberg606c74f2014-03-19 23:46:42 +01003194 CMakeLists.txt: Fix include directories.
3195
3196 Problem reported by Taylor Holberton <taylorcholberton@gmail.com>.
3197
31982014-03-19 Werner Lemberg <wl@gnu.org>
3199
Werner Lembergcc7cf2c2014-03-19 07:35:35 +01003200 Partially revert last commit.
3201
3202 Found by Alexei.
3203
3204 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Initializing
3205 those variables is plain wrong, since we are in a loop.
3206
Sean McBride87628722014-03-18 08:39:35 +010032072014-03-18 Sean McBride <sean@rogue-research.com>
3208 Werner Lemberg <wl@gnu.org>
3209
3210 Fix clang warnings.
3211
3212 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Initialize
3213 some variables.
3214
3215 * src/base/ftcalc.c (FT_MulFix): Only use code if
3216 `FT_MULFIX_INLINED' is not defined.
3217
3218 * src/bdf/bdfdrivr.c (bdf_cmap_class), src/cache/ftcbasic.c
3219 (ftc_basic_image_family_class, ftc_basic_image_cache_class,
3220 ftc_basic_sbit_family_class, ftc_basic_sbit_cache_class),
3221 src/cache/ftccmap.c (ftc_cmap_cache_class), src/cache/ftcmanag.c
3222 (ftc_size_list_class, ftc_face_list_class), src/pcf/pcfdrivr.c
3223 (pcf_cmap_class), src/pfr/pfrdrivr.c (pfr_metrics_service_rec): Make
3224 function static.
3225
3226 * src/type1/t1driver.c (t1_ps_get_font_value): Remove redundant
3227 code.
3228
Werner Lemberg23367ff2014-03-17 07:33:14 +010032292014-03-17 Werner Lemberg <wl@gnu.org>
3230
3231 Fix Savannah bug #41869.
3232
3233 This works around a problem with HarfBuzz (<= 0.9.26), which doesn't
3234 validate glyph indices returned by
3235 `hb_ot_layout_lookup_collect_glyphs'.
3236
3237 * src/autofit/hbshim.c (af_get_coverage): Guard `idx'.
3238
3239 * docs/CHANGES: Updated.
3240
Werner Lemberg03181682014-03-14 08:06:06 +010032412014-03-14 Werner Lemberg <wl@gnu.org>
3242
3243 * builds/unix/configure.raw: Don't show error messages of `which'.
3244
Alan Coopersmithed372b72014-03-09 06:14:12 +010032452014-03-09 Alan Coopersmith <alan.coopersmith@oracle.com>
3246
3247 Fix cppcheck 1.64 warning.
3248
3249 * src/autofit/afglobal.c (af_face_globals_new): Catch NULL pointer
3250 dereference in case of error.
3251
Werner Lemberg1a69dc72014-03-09 06:06:58 +010032522014-03-09 Sean McBride <sean@rogue-research.com>
3253
3254 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Remove clang warning.
3255
Werner Lemberg05565362014-03-06 18:56:58 +010032562014-03-06 Werner Lemberg <wl@gnu.org>
3257
Werner Lembergec8853c2014-03-06 19:13:45 +01003258 * Version 2.5.3 released.
3259 =========================
3260
3261
3262 Tag sources with `VER-2-5-3'.
3263
3264 * docs/VERSION.DLL: Update documentation and bump version number to
3265 2.5.3.
3266
3267 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
3268 builds/windows/vc2005/index.html,
3269 builds/windows/vc2008/freetype.vcproj,
3270 builds/windows/vc2008/index.html,
3271 builds/windows/vc2010/freetype.vcxproj,
3272 builds/windows/vc2010/index.html,
3273 builds/windows/visualc/freetype.dsp,
3274 builds/windows/visualc/freetype.vcproj,
3275 builds/windows/visualc/index.html,
3276 builds/windows/visualce/freetype.dsp,
3277 builds/windows/visualce/freetype.vcproj,
3278 builds/windows/visualce/index.html,
3279 builds/wince/vc2005-ce/freetype.vcproj,
3280 builds/wince/vc2005-ce/index.html,
3281 builds/wince/vc2008-ce/freetype.vcproj,
3282 builds/wince/vc2008-ce/index.html: s/2.5.2/2.5.3/, s/252/253/.
3283
3284 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 3.
3285
3286 * builds/unix/configure.raw (version_info): Set to 17:2:11.
3287 * CMakeLists.txt (VERSION_PATCH): Set to 3.
3288 * docs/CHANGES: Updated.
3289
32902014-03-06 Werner Lemberg <wl@gnu.org>
3291
Werner Lemberg05565362014-03-06 18:56:58 +01003292 Fixes for compilation with C++.
3293
3294 * src/autofit/hbshim.c (scripts): Change type to `hb_script_t'.
3295 (af_get_coverage): Updated.
3296 (COVERAGE): Add cast.
3297
Sean McBrideb24e8d32014-03-06 14:54:22 +010032982014-03-06 Sean McBride <sean@rogue-research.com>
3299
3300 Remove more clang analyzer warnings.
3301
3302 * src/bdf/bdflib.c (_bdf_readstream), src/truetype/ttgload.c
3303 (TT_Load_Glyph): Remove dead stores.
3304
Werner Lemberga32758f2014-03-05 08:02:46 +010033052014-03-05 Werner Lemberg <wl@gnu.org>
3306
3307 * builds/unix/configure.raw: Simplify.
3308
suzuki toshiya382f3ef2014-03-05 10:19:15 +090033092014-03-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3310
3311 Fix a bug in configure in library dependency setting
Werner Lemberga32758f2014-03-05 08:02:46 +01003312 Reported in https://bugs.freedesktop.org/show_bug.cgi?id=75652.
suzuki toshiya382f3ef2014-03-05 10:19:15 +09003313
3314 * builds/unix/configure.raw: Use `x"${xxx}" != xno' style.
3315
Werner Lembergf48f7dc2014-03-04 04:40:07 +010033162014-03-04 Werner Lemberg <wl@gnu.org>
3317
3318 Minor fix for `make devel'.
3319
3320 * builds/freetype.mk (INCLUDE_FLAGS) [DEVEL_DIR]: Don't use
3321 pkg-config for bzip2 since not all GNU/Linux distributions have
3322 `bzip2.pc' (and the header file `bzlib.h' is located in /usr/include
3323 normally).
3324
Werner Lemberg7ac76b52014-03-04 04:29:17 +010033252014-03-04 Sean McBride <sean@rogue-research.com>
3326
3327 Fix several clang static analyzer dead store warnings.
3328
3329 * src/autofit/afhints.c (af_glyph_hints_reload,
3330 af_glyph_hints_align_weak_points): Remove unnecessary assignments.
3331
3332 * src/bdf/bdflib.c (bdf_font_load): Ditto.
3333
3334 * src/pshinter/pshalgo.c (psh_glyph_compute_extrema,
3335 psh_glyph_interpolate_other_points): Ditto.
3336
3337 * src/type1/t1load.c (T1_Set_MM_Blend): Ditto.
3338
Werner Lemberg93ebcbd2014-03-03 07:13:45 +010033392014-03-03 Werner Lemberg <wl@gnu.org>
3340
3341 Rewrite library option handling in `configure'.
3342
3343 o Introduce `auto' value for `--with-XXX' library options; this is
3344 now the default.
3345
3346 o First use `pkg-config' for library detection, then fall back to
3347 other tests.
3348
3349 * builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
3350 --with-harfbuzz): Rewrite.
3351 Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
3352 variables to collect data for `freetype2.pc' and `freetype-config'.
3353 (FT2_EXTRA_LIBS): Renamed to ...
3354 (ft2_extra_libs): This since it gets no longer substituted.
3355 (REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
3356 New output variables, replacing `XXX_PKG' and `LIBXXX'.
3357 Add notice at the end of `configure' showing the library
3358 configuration.
3359
3360 * builds/unix/freetype-config.in (--static): New command line
3361 option.
3362 (libs): Updated.
3363 (staticlibs): New variable, to be used if `--static' is given.
Werner Lemberg8fa69a82014-12-03 20:07:14 +01003364 * docs/freetype-config.1: Document `--static'.
Werner Lemberg93ebcbd2014-03-03 07:13:45 +01003365
3366 * builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
3367
Werner Lemberg86026a42014-03-01 06:57:19 +010033682014-03-01 Werner Lemberg <wl@gnu.org>
3369
Werner Lemberge962a912014-03-01 21:00:02 +01003370 Avoid `long long' warnings with older gcc compilers.
3371 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
3372
3373 * builds/unix/configure.raw: Don't use gcc's `-pedantic' flag for
3374 versions < 4.6. This is especially needed for Max OS X since this
3375 OS runs a gcc variant (or emulation) based on version 4.2.1.
3376
33772014-03-01 Werner Lemberg <wl@gnu.org>
3378
Werner Lemberg6030a9f2014-03-01 14:01:12 +01003379 * docs/INSTALL.CROSS: Revised and updated.
3380
33812014-03-01 Werner Lemberg <wl@gnu.org>
3382
Werner Lemberg646db052014-03-01 12:48:07 +01003383 Make `make clean' remove `freetype2.pc'.
3384
3385 This is a generated file at build time, not configure time.
3386
3387 * builds/unix/unix-def.in (DISTCLEAN): Move `freetype2.pc' to ...
3388 (CLEAN): This variable.
3389
33902014-03-01 Werner Lemberg <wl@gnu.org>
3391
Werner Lemberg00c79ed2014-03-01 12:32:20 +01003392 Use pkg-config for detecting libpng and libbz2 also.
3393
3394 * builds/unix/configure.raw (HAVE_PKG): New variable.
3395 Search for libbz2 using `pkg-config'; s/BZ2/BZIP2/.
3396 Search for libpng using `pkg-config'.
3397 Fix definition of `LIBHARFBUZZ' variable.
3398 * builds/unix/freetype-config.in ($libs): Updated.
3399 * builds/unix/freetype2.in: Add `URL' field.
3400 Update `Requires.private' and `Libs.private'.
3401 * builds/unix/unix-def.in: Updated.
3402
34032014-03-01 Werner Lemberg <wl@gnu.org>
3404
Werner Lemberg86026a42014-03-01 06:57:19 +01003405 Add configure support for HarfBuzz.
3406
3407 * builds/unix/pkg.m4: New file.
3408 * builds/unix/configure.raw: Search for libharfbuzz using
3409 `pkg-config'.
3410 Add `--without-harfbuzz' option.
3411 * builds/unix/freetype-config.in, builds/unix/freetype2.in,
3412 builds/unix/unix-def.in (freetype-config, freetype2.pc): Handle
3413 HarfBuzz.
3414
3415 * docs/INSTALL.UNIX: Document interdependency of Freetype with
3416 HarfBuzz.
3417
Alexei Podtelezhnikov6adda682014-02-28 09:24:26 +010034182014-02-28 Alexei Podtelezhnikov <apodtele@gmail.com>
3419
3420 [cff] Math simplifications.
3421
3422 * src/cf2blues.c (cf2_blues_init): Use `FT_MulDiv'.
3423 * src/cf2ft.c (cf2_getScaleAndHintFlag): Use simple division.
3424
Dave Arnold0eae6eb2014-02-28 07:40:01 +010034252014-02-28 Dave Arnold <darnold@adobe.com>
3426
Dave Arnold135c3fa2014-02-28 07:42:42 +01003427 [cff] Fix Savannah bug #41697, part 2.
3428
3429 * src/cff/cf2ft.c (cf2_initLocalRegionBuffer,
3430 cf2_initGlobalRegionBuffer): It is possible for a charstring to call
3431 a subroutine if no subroutines exist. This is an error but should
3432 not trigger an assert. Split the assert to account for this.
3433
34342014-02-28 Dave Arnold <darnold@adobe.com>
3435
Dave Arnold0eae6eb2014-02-28 07:40:01 +01003436 [cff] Fix Savannah bug #41697, part 1.
3437
3438 * src/cff/cf2hints.c (cf2_hintmap_build): Return when `hintMask' is
3439 invalid. In this case, it is not safe to use the length of
3440 `hStemHintArray'; the exception has already been recorded in
3441 `hintMask'.
3442
Werner Lembergeee4ff82014-02-26 18:12:36 +010034432014-02-26 Werner Lemberg <wl@gnu.org>
3444
Werner Lemberga2b5f662014-02-26 19:50:18 +01003445 [sfnt] Fix Savannah bug #41696.
3446
3447 * src/sfnt/ttcmap.c (tt_cmap0_validate, tt_cmap2_validate,
3448 tt_cmap4_validate, tt_cmap14_validate): Fix limit tests.
3449
34502014-02-26 Werner Lemberg <wl@gnu.org>
3451
Werner Lembergeee4ff82014-02-26 18:12:36 +01003452 [winfnt] Fix Savannah bug #41694.
3453
3454 * src/winfonts/winfnt.c (FNT_Load_Glyph): Check glyph offset.
3455
34562014-02-26 Werner Lemberg <wl@gnu.org>
Werner Lemberg9a567642014-02-26 13:08:07 +01003457
Werner Lemberg08c628d2014-02-26 14:18:03 +01003458 [cff] Fix Savannah bug #41693.
3459
3460 * src/cff/cffload.c (CFF_Load_FD_Select): Reject empty array.
3461
Werner Lembergeee4ff82014-02-26 18:12:36 +010034622014-02-26 Werner Lemberg <wl@gnu.org>
Werner Lemberg08c628d2014-02-26 14:18:03 +01003463
Werner Lemberg9a567642014-02-26 13:08:07 +01003464 [bdf] Fix Savannah bug #41692.
3465
3466 bdflib puts data from the input stream into a buffer in chunks of
3467 1024 bytes. The data itself gets then parsed line by line, simply
3468 increasing the current pointer into the buffer; if the search for
3469 the final newline character exceeds the buffer size, more data gets
3470 read.
3471
3472 However, in case the current line's end is very near to the buffer
3473 end, and the keyword to compare with is longer than the current
3474 line's length, an out-of-bounds read might happen since `memcmp'
3475 doesn't stop properly at the string end.
3476
3477 * src/bdf/bdflib.c: s/ft_memcmp/ft_strncmp/ to make comparisons
3478 stop at string ends.
3479
suzuki toshiya91c7a972014-02-17 16:38:31 +090034802014-02-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3481
3482 [autofit] Fix `make multi' compilation.
3483
suzuki toshiyacc9a0c22014-02-17 16:43:54 +09003484 * src/autofit/hbshim.c: Include `afglobal.h' and `aftypes.h'.
suzuki toshiya91c7a972014-02-17 16:38:31 +09003485
Werner Lemberg6b290fd2014-02-19 09:26:54 +010034862014-02-19 Werner Lemberg <wl@gnu.org>
3487 Simon Bünzli <zeniko@gmail.com>
3488
3489 Fix Savannah bug #32902.
3490
3491 Patch taken from
3492
3493 https://code.google.com/p/sumatrapdf/source/browse/trunk/ext/_patches/freetype2.patch?spec=svn8620&r=8620#87
3494
3495 with slight modifications.
3496
3497 * src/type1/t1parse.c (T1_Get_Private_Dict): Add heuristic test to
3498 handle fonts that incorrectly use \r at the beginning of an eexec
3499 block.
3500
Simon Bünzlidf14e6c2014-02-19 08:42:52 +010035012014-02-19 Simon Bünzli <zeniko@gmail.com>
3502
3503 Fix Savannah bug #41590.
3504
3505 * src/type1/t1load.c (parse_encoding): Protect against invalid
3506 number.
3507
Dave Arnold89a94d42014-02-12 23:45:47 +010035082014-02-12 Dave Arnold <darnold@adobe.com>
3509
3510 [cff] Optimize by using `FT_MulDiv'.
3511 Suggested by Alexei.
3512
3513 * src/cff/cf2font.c (cf2_computeDarkening): Do it.
3514
Werner Lemberg85ee27a2014-02-12 23:27:41 +010035152014-02-12 Werner Lemberg <wl@gnu.org>
3516
3517 Fix Savannah bug #41465.
3518
3519 * builds/unix/unix-def.in (CLEAN): Add `freetype-config'.
3520 (DISTCLEAN): Remove `freetype-config'.
3521
Sean McBride7be2a942014-02-08 13:55:38 +010035222014-02-08 Sean McBride <sean@rogue-research.com>
3523
3524 Fix clang static analyzer and compiler warnings.
3525
3526 * src/autofit/afhints.c (af_glyph_hints_align_weak_points),
3527 src/autofit/afloader (af_loader_load_g) <FT_GLYPH_FORMAT_COMPOSITE>,
3528 src/base/ftcalc.c (FT_MSB), src/base/ftoutln.c
3529 (FT_Outline_Decompose), src/bdf/bdfdrivr.c (bdf_interpret_style),
3530 src/cff/cffparse.c (cff_parse_integer), src/cid/cidparse.c
3531 (cid_parser_new), src/pfr/pfrload.c (pfr_phy_font_load),
3532 src/raster/ftraster.c (Decompose_Curve), src/sfnt/sfdriver.c
3533 (sfnt_get_ps_name), src/sfnt/ttcmap.c (tt_cmap12_next,
3534 tt_cmap13_next), src/smooth/ftgrays.c (gray_hline): Remove dead
3535 code.
3536
3537 * src/autofit/afmodule.c (af_property_get_face_globals,
3538 af_property_set, af_property_get), src/base/ftbitmap.c
3539 (ft_gray_for_premultiplied_srgb_bgra): Make functions static.
3540
3541 * src/base/ftobjs.c (ft_remove_renderer): Protect against
3542 library == NULL.
3543 (ft_property_do): Make function static.
3544
3545 * src/base/ftrfork.c: Include `ftbase.h'.
3546
3547 * src/sfnt/ttsbit.c (tt_face_load_sbix_image)
3548 [!FT_CONFIG_OPTION_USE_PNG], src/type1/t1gload.c
3549 (T1_Compute_Max_Advance): Avoid compiler warning.
3550
3551 * src/truetype/ttinterp.c (TT_New_Context): Reduce scope of
3552 variable.
3553
Werner Lembergab98c5e2014-02-08 11:34:33 +010035542014-02-08 Werner Lemberg <wl@gnu.org>
3555
3556 Fix Windows build directories.
3557
3558 The build target is now `windows' instead of `win32'.
3559
3560 Problem reported by Nickolas George <darknova.clan@gmail.com>.
3561
3562 * builds/modules.mk: Don't use `win32' and `win16' (!) but
3563 `windows'.
3564
3565 * builds/windows/detect.mk, builds/windows/win32-def.mk:
3566 s/win32/windows/.
3567
Eugen Sawina8ceae42014-02-08 06:30:06 +010035682014-02-08 Eugen Sawin <esawin@mozilla.com>
3569
3570 Fix Savannah bug #41507.
3571
3572 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap)
3573 [!FT_CONFIG_OPTION_USE_PNG] <17, 17, 19>: Fix error handling.
3574
Dave Arnold355b3592014-02-08 06:23:04 +010035752014-02-08 Dave Arnold <darnold@adobe.com>
3576
3577 [cff] Fix minor performance bug.
3578
3579 * src/cff/cf2font.c (cf2_font_setup): Darkening amount and blue zone
3580 calculations are now cached and not recomputed on each glyph.
3581
Werner Lemberg6dce1362014-02-05 15:40:47 +010035822014-02-05 Werner Lemberg <wl@gnu.org>
3583
3584 Fix problems with perl 5.8.8 as distributed with current MinGW.
3585
3586 * src/tools/afblue.pl: Work-around for Perl bug #63402.
3587 (string_re): Avoid `possessive quantifiers', which have been
3588 introduced in Perl version 5.10.
3589
Werner Lemberga8772912014-02-04 11:36:08 +010035902014-02-04 Werner Lemberg <wl@gnu.org>
3591
Werner Lembergd87f9a62014-02-04 16:14:09 +01003592 Fix compilation with MinGW.
3593
3594 Right now, compilation out of the box with latest MinGW is broken
3595 due to bugs in header files of mingwrt 4.0.3 in strict ANSI mode,
3596 cf.
3597
3598 https://sourceforge.net/p/mingw/bugs/2024/
3599 https://sourceforge.net/p/mingw/bugs/2046/
3600
3601 * builds/unix/configure.raw: Don't set `-ansi' flag for MinGW.
3602
36032014-02-04 Werner Lemberg <wl@gnu.org>
3604
Werner Lemberga8772912014-02-04 11:36:08 +01003605 [autofit] Minor fix.
3606
3607 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
3608 src/autofit/aflatin.c (af_latin_metrics_init_widths): Fix handling
3609 of alternative standard characters.
3610 This also fixes a compilation warning in non-debug mode.
3611
Werner Lembergee3778d2014-02-03 11:16:47 +010036122014-02-03 Werner Lemberg <wl@gnu.org>
3613
3614 [cff] Fix Savannah bug #41363.
3615
3616 * src/cff/cf2ft.c (cf2_checkTransform): Convert assertion into
3617 parameter check.
3618 (cf2_decoder_parse_charstrings): Call `cf2_checkTransform' only if
3619 we are scaling the outline.
3620 (cf2_getPpemY): Remove problematic assertion.
3621
Werner Lemberga3364002014-01-26 09:45:23 +010036222014-01-26 Werner Lemberg <wl@gnu.org>
3623
3624 [autofit] Introduce two more slots for standard characters.
3625
3626 This is useful for OpenType features like `c2sc' (caps to small
3627 caps) that don't have lowercase letters by definition, or other
3628 features that mainly operate on numerals.
3629
3630 * src/autofit/afscript.h: Add more standard characters.
3631
3632 * src/autofit/aftypes.h: Update use of `SCRIPT' macro.
3633 (AF_ScriptClassRec): Add members to hold two more standard
3634 characters.
3635 (AF_DEFINE_SCRIPT_CLASS): Updated.
3636
3637 * src/autofit/afglobal.c, src/autofit/afglobal.h,
3638 * src/autofit/afpic.c, src/autofit/afranges.h, src/autofit/hbshim.c:
3639 Update use of `SCRIPT' macro.
3640
3641 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
3642 src/autofit/aflatin.c (af_latin_metrics_init_widths): Scan two more
3643 standard characters.
3644
Werner Lembergeb7691c2014-01-24 19:04:22 +010036452014-01-24 Werner Lemberg <wl@gnu.org>
3646
3647 Fix Savannah bug #41320.
3648
3649 * src/autofit/aflatin.c (af_latin_metrics_init_blues)
3650 <AF_LATIN_IS_LONG_BLUE>: Avoid negative index of `last'.
3651
Werner Lemberg8b281f82014-01-23 08:14:53 +010036522014-01-23 Werner Lemberg <wl@gnu.org>
3653
Werner Lemberg752f3912014-01-23 09:14:25 +01003654 Fix Savannah bug #41310.
3655
3656 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap) <glyph_format==5>:
3657 Don't check metrics, which this format doesn't have.
3658 This is another correction to the commit from 2013-11-21.
3659
36602014-01-23 Werner Lemberg <wl@gnu.org>
3661
Werner Lemberg8b281f82014-01-23 08:14:53 +01003662 Fix Savannah bug #41309.
3663
3664 * src/type1/t1load.c (t1_parse_font_matrix): Properly handle result
3665 of `T1_ToFixedArray'.
3666
3667 * src/cid/cidload.c (cid_parse_font_matrix): Synchronize with
3668 `t1_parse_font_matrix'.
3669
3670 * src/type42/t42parse.c (t42_parse_font_matrix): Synchronize with
3671 `t1_parse_font_matrix'.
3672 (t42_parse_encoding): Synchronize with `t1_parse_encoding'.
3673
3674 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_BBOX>,
3675 <T1_FIELD_TYPE_MMOX>: Properly handle result of `ps_tofixedarray'.
3676
Werner Lembergff8dc312014-01-22 09:19:57 +010036772014-01-22 Werner Lemberg <wl@gnu.org>
3678
3679 * src/autofit/hbshim.c (af_get_coverage): Fix memory leaks.
3680
Werner Lemberg6a700782014-01-16 08:55:40 +010036812014-01-16 Werner Lemberg <wl@gnu.org>
3682
3683 [autofit] Improve tracing of style coverages.
3684
3685 * include/internal/fttrace.h: Add `afglobal' for tracing style
3686 coverages.
3687
3688 * src/autofit/afglobal.c: Include FT_INTERNAL_DEBUG_H.
3689 (FT_COMPONENT): Define.
3690 (af_face_globals_compute_style_coverage): Trace `gstyles' array
3691 data.
3692
Werner Lemberg7cbfdff2014-01-09 07:26:06 +010036932014-01-09 Werner Lemberg <wl@gnu.org>
3694
3695 Fix Savannah bug #41158.
3696
3697 * builds/unix/install.mk (install): Create man page directory.
3698
Chongyu Zhu94c66942014-01-08 08:52:59 +010036992014-01-08 Chongyu Zhu <lembacon@gmail.com>
3700
3701 [arm] Fix Savannah bug #41138, part 2.
3702
3703 * builds/unix/ftconfig.in (FT_MulFix_arm), include/config/ftconfig.h
3704 (FT_MulFix_arm), src/truetype/ttinterp.c (TT_MulFix14_arm): Fix
3705 preprocessor conditionals for `add.w'.
3706
Werner Lembergc46fa862014-01-08 08:45:40 +010037072014-01-08 Werner Lemberg <wl@gnu.org>
3708
3709 [autofit] Fix Savannah bug #41138, part 1.
3710
3711 * src/tools/afblue.pl <Handling #endif>: Produce correct auxiliary
3712 enumeration names for generated `#else'.
3713
3714 * src/autofit/afblue.h: Regenerated.
3715
Werner Lemberg3e5a3742014-01-06 07:53:10 +010037162014-01-06 Werner Lemberg <wl@gnu.org>
3717
3718 Add manual page for `freetype-config'.
3719 Contributed by Nis Martensen <nis.martensen@web.de>.
3720
3721 * docs/freetype-config.1: New file.
3722
3723 * builds/unix/unix-def.in (mandir): Define.
3724 * builds/unix/install.mk (install, uninstall): Handle manpage.
3725
Werner Lemberg991cbcc2014-01-05 13:24:56 +010037262014-01-05 Werner Lemberg <wl@gnu.org>
3727
3728 [autofit] Minor fixes for `afblue.pl'.
3729
3730 * src/tools/afblue.pl (aux_name): Don't use `reverse'.
3731 <Handling #endif>: Use proper indentation for generated `#else'.
3732
3733 * src/autofit/afblue.h: Regenerated.
3734
Werner Lemberg0d977442014-01-04 11:46:34 +010037352014-01-04 Werner Lemberg <wl@gnu.org>
3736
3737 [autofit] Fix Indic scripts.
3738
3739 Split the single, incorrect Indic entry into separate scripts so
3740 that the covered ranges are the same: Bengali, Devanagari, Gujarati,
3741 Gurmukhi, Kannada, Limbu, Malayalam, Oriya, Sinhala, Sundanese,
3742 Syloti Nagri, Tamil, Telugu, and Tibetan. At the same time, remove
3743 entries for Meetai Mayak and Sharada – the Unicode ranges were
3744 incorrect (and nobody has complained about that), fonts are scarce
3745 for those scripts, and the Indic auto-hinter support is rudimentary
3746 anyways.
3747
3748 * src/autofit/afscript.h: Updated, using AF_CONFIG_OPTION_INDIC and
3749 AF_CONFIG_OPTION_CJK.
3750
3751 * src/autofit/afstyles.h (STYLE_DEFAULT_INDIC): New auxiliary macro.
3752 Use it, together with AF_CONFIG_OPTION_INDIC and
3753 AF_CONFIG_OPTION_CJK, to update.
3754
3755 * src/autofit/afranges.c [AF_CONFIG_OPTION_INDIC]: Updated.
3756 [!AF_CONFIG_OPTION_INDIC, !AF_CONFIG_OPTION_CJK]: Removed.
3757 Sort entries by tags.
3758
Werner Lemberg5c7f5502014-01-03 10:48:26 +010037592014-01-03 Werner Lemberg <wl@gnu.org>
3760
Werner Lembergecdb0e32014-01-03 20:49:31 +01003761 [autofit] Thinko.
3762
3763 * src/autofit/hbshim.c (af_get_char_index): Similar to
3764 `af_get_coverage', reject glyphs which are not substituted.
3765
37662014-01-03 Werner Lemberg <wl@gnu.org>
3767
Werner Lemberga42f9182014-01-03 18:29:41 +01003768 [autofit] Fix handling of default coverages.
3769
Werner Lemberg1b5bc892014-01-03 18:33:24 +01003770 With this commit, the implementation of coverage handling is
3771 completed.
3772
3773 * src/autofit/hbshim.c (af_get_coverage): Exit early if nothing to
3774 do.
3775 Reject coverages which don't contain appropriate glyphs for blue
3776 zones.
3777
37782014-01-03 Werner Lemberg <wl@gnu.org>
3779
3780 [autofit] Fix handling of default coverages.
3781
Werner Lemberga42f9182014-01-03 18:29:41 +01003782 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
3783 First handle non-default coverages, then the default coverage of the
3784 default script, and finally the other default coverages.
3785
37862014-01-03 Werner Lemberg <wl@gnu.org>
3787
Werner Lembergf45749b2014-01-03 18:09:36 +01003788 [autofit] Fix scaling of HarfBuzz shaping.
3789
3790 * src/autofit/hbshim.c (af_get_char_index): Scale to units per EM.
3791
37922014-01-03 Werner Lemberg <wl@gnu.org>
3793
Werner Lemberg5c7f5502014-01-03 10:48:26 +01003794 [autofit] Better ftgrid support.
3795
3796 * src/autofit/afhints.c (af_glyph_hints_get_segment_offset): Add
3797 parameters `is_blue' and `blue_offset'.
3798
Werner Lemberg73cc8332014-01-01 07:10:36 +010037992014-01-01 Werner Lemberg <wl@gnu.org>
3800
Werner Lemberg55cd7e02014-01-02 13:07:48 +01003801 [autofit] Remove some styles.
3802
3803 * src/autofit/afcover.h: Remove coverages for alternative fractions,
3804 denominators, numerators, and fractions.
3805
3806 * src/autofit/afstyles.h (META_STYLE_LATIN): Updated.
3807
38082014-01-01 Werner Lemberg <wl@gnu.org>
3809
Werner Lembergc973e672014-01-01 16:34:42 +01003810 [autofit] Add more styles.
3811
3812 * src/autofit/afstyles.h (STYLE_LATIN, META_STYLE_LATIN): New
3813 auxiliary macros; use them to define styles for Cyrillic, Greek, and
3814 Latin.
3815
3816 * src/autofit/afcover.h: Remove coverage for oldstyle figures.
3817 Since those digits are used in combination with ordinary letters, it
3818 makes no sense to handle them separately.
3819
3820 * src/autofit/afglobal.c (af_face_globals_get_metrics): Don't limit
3821 `options' parameter to 4 bits.
3822
38232014-01-01 Werner Lemberg <wl@gnu.org>
3824
Werner Lembergabb2f732014-01-01 08:00:16 +01003825 [autofit] Fix style assignments to glyphs.
3826
3827 * src/autofit/hbshim.c (af_get_coverage)
3828 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Scan GPOS coverage of features also
3829 so that we can skip glyphs that have both GSUB and GPOS data.
3830
38312014-01-01 Werner Lemberg <wl@gnu.org>
3832
Werner Lemberg0950f3a2014-01-01 07:48:20 +01003833 * src/autofit/hbshim.c: s/{lookups,glyphs}/gsub_{lookups,glyphs}/.
3834
38352014-01-01 Werner Lemberg <wl@gnu.org>
3836
Werner Lemberg73cc8332014-01-01 07:10:36 +01003837 [autofit] Implement and use `af_get_char_index' with HarfBuzz.
3838
3839 * src/autofit/hbshim.c (COVERAGE) [FT_CONFIG_OPTION_USE_HARFBUZZ]:
3840 Redefine to construct HarfBuzz features.
3841 (af_get_char_index) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Rewritten.
3842
3843 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Use
3844 `y_offset' to adjust `best_y'.
3845
Werner Lembergc9d99472013-12-31 08:16:57 +010038462013-12-31 Werner Lemberg <wl@gnu.org>
3847
Werner Lemberg785f3852013-12-31 09:45:10 +01003848 [autofit] s/AF_STYLE_...._DEFAULT/AF_STYLE_...._DFLT/i.
3849
38502013-12-31 Werner Lemberg <wl@gnu.org>
3851
Werner Lembergc9d99472013-12-31 08:16:57 +01003852 [autofit] Fix interface of `af_get_char_index'.
3853
3854 * src/autofit/hbshim.c (af_get_char_index): Return error value.
3855 Add argument for y offset (to be used in a yet-to-come patch).
3856
3857 * src/autofit/hbshim.h, src/autofit/afcjk.c,
3858 src/autofit/aflatin.c: Updated.
3859
Werner Lemberg44aa7e02013-12-30 07:41:22 +010038602013-12-30 Werner Lemberg <wl@gnu.org>
3861
3862 [autofit] Don't combine multiple features into one set.
3863
3864 Combining them, as originally envisioned, would lead to much more
3865 complicated code, as investigations have shown meanwhile. The major
3866 drawback is that we run out of available style slots much earlier.
3867 However, this is only a theoretical issue since we don't support a
3868 large number of scripts currently.
3869
3870 * src/autofit/afcover.h: Replace `COVERAGE_{1,2,3}' macros with
3871 a single-element `COVERAGE' macro, sort the elements by the feature
3872 tags, and add entry for `ruby'.
3873
3874 * src/autofit/aftypes.h: Updated.
3875 * src/autofit/hbshim.c: Updated.
3876
Werner Lemberg6af01a02013-12-28 08:55:24 +010038772013-12-28 Werner Lemberg <wl@gnu.org>
3878
Werner Lemberg072dc452013-12-28 12:26:21 +01003879 [autofit] Code shuffling to reduce use of cpp macros.
3880
3881 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
3882 Call `af_get_coverage' unconditionally.
3883
3884 * src/autofit/autofit.c: Include `hbshim.c' unconditionally.
3885
3886 * src/autofit/hbshim.c (af_get_coverage)
3887 [!FT_CONFIG_OPTION_USE_HARFBUZZ]: Provide dummy function.
3888
3889 * src/autofit/hbshim.h: Provide function declarations
3890 unconditionally.
3891
38922013-12-28 Werner Lemberg <wl@gnu.org>
3893
Werner Lemberg17af5862013-12-28 10:33:01 +01003894 [autofit] Add wrapper function for `FT_Get_Char_Index'.
3895
3896 Yet-to-come changes will provide HarfBuzz functionality for the new
3897 function.
3898
3899 * src/autofit/hbshim.c (af_get_char_index): New function.
3900 * src/autofit/hbshim.h: Updated.
3901
3902 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
3903 af_cjk_metrics_init_blues, af_cjk_metrics_check_digits): Updated.
3904
3905 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
3906 af_latin_metrics_init_blues, af_latin_metrics_check_digits):
3907 Updated.
3908
39092013-12-28 Werner Lemberg <wl@gnu.org>
3910
Werner Lemberg6af01a02013-12-28 08:55:24 +01003911 [autofit] Use `global' HarfBuzz font object.
3912
3913 We now use `hb_font' instead of `hb_face' since yet-to-come changes
3914 need this.
3915
3916 * src/autofit/afglobal.h: Include `hbshim.h'.
3917 (AF_FaceGlobalsRec) [FT_CONFIG_OPTION_USE_HARFBUZZ]: New member
3918 `hb_font'.
3919
3920 * src/autofit/afglobal.c (af_face_globals_new)
3921 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Create `hb_font'.
3922 (af_face_globals_free) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Destroy
3923 `hb_font'.
3924
3925 * src/autofit/hbshim.h: Include HarfBuzz headers.
3926
3927 * src/autofit/hbshim.c: Include `hbshim.h' instead of HarfBuzz
3928 headers.
3929 (af_get_coverage): Updated.
3930
Werner Lembergd32a7d32013-12-27 19:26:04 +010039312013-12-27 Werner Lemberg <wl@gnu.org>
3932
3933 [autofit] Handle `DFLT' OpenType script for coverages.
3934
3935 * include/ftautoh.h: Document new `default-script' property.
3936
3937 * src/autofit/hbshim.c (af_get_coverage): Use `AF_FaceGlobals' for
3938 type of first parameter.
3939 (script_tags): Add one more element.
3940 (af_get_coverage): Adjust `script_tags' to handle `DFLT' script tag.
3941
3942 * src/autofit/hbshim.h: Updated.
3943
3944 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
3945 Updated.
3946
3947 * src/autofit/afglobal.h (AF_SCRIPT_DEFAULT): New macro.
3948
3949 * src/autofit/afmodule.h (AF_ModuleRec): New `default_script'
3950 member.
3951
3952 * src/autofit/afmodule.c (af_property_set, af_property_get): Handle
3953 `default-script' property.
3954 (af_autofitter_init): Updated.
3955
suzuki toshiyae2d2b152013-12-27 16:44:24 +090039562013-12-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3957
3958 [ftrfork] Fix the face order difference between POSIX and Carbon.
3959
3960 The fragmented resources in Suitcase and .dfont should be reordered
Werner Lemberg00a7b512013-12-27 19:18:49 +01003961 when `POST' resource for Type1 is being restored, but reordering of
suzuki toshiyae2d2b152013-12-27 16:44:24 +09003962 sfnt resources induces the different face order. Now the ordering
Werner Lemberg00a7b512013-12-27 19:18:49 +01003963 is restricted to `POST' resource only, to prevent the different
3964 order issue (e.g. the face index in the fontconfig cache generated
3965 with Carbon framework is incompatible with that by FreeType 2
3966 without Carbon framework.) Found by Khaled Hosny and Hin-Tak Leung.
3967
suzuki toshiyae2d2b152013-12-27 16:44:24 +09003968 http://lists.gnu.org/archive/html/freetype-devel/2013-02/msg00035.html
3969 http://lists.gnu.org/archive/html/freetype-devel/2013-12/msg00027.html
3970
3971 * src/base/ftrfork.c (FT_Raccess_Get_DataOffsets): Add a switch
Werner Lemberg44aa7e02013-12-30 07:41:22 +01003972 `sort_by_res_id' to control the fragmented resource ordering.
Werner Lemberg00a7b512013-12-27 19:18:49 +01003973 * include/internal/ftrfork.h: Declare new switch.
3974 * src/base/ftobjs.c (IsMacResource): Enable the sorting for `POST'
3975 resource, and disable the sorting for `sfnt' resource.
suzuki toshiyae2d2b152013-12-27 16:44:24 +09003976
Werner Lemberg5f577462013-12-25 08:50:50 +010039772013-12-25 Werner Lemberg <wl@gnu.org>
3978
3979 Fix Savannah bug #40997.
3980
3981 * src/bdf/bdfdrivr.c (BDF_Face_Init): Only use OR operator to
3982 adjust face flags since FT_FACE_FLAG_EXTERNAL_STREAM might already
3983 be set.
3984 * src/cff/cffobjs.c (cff_face_init): Ditto.
3985 * src/cid/cidobjs.c (cid_face_init): Ditto.
3986 * src/pcf/pcfread.c (pcf_load_font): Ditto.
3987 * src/pfr/pfrobjs.c (pfr_face_init): Ditto.
3988 * src/type1/t1objs.c (T1_Face_Init): Ditto.
3989 * src/type42/t42objs.c (T42_Face_Init): Ditto.
3990 * src/winfonts/winfnt.c (FNT_Face_Init): Ditto.
3991
Werner Lembergc4e968e2013-12-21 07:23:08 +010039922013-12-21 Werner Lemberg <wl@gnu.org>
3993
Werner Lemberg19241342013-12-21 21:31:38 +01003994 [autofit] Introduce `coverages'.
3995
3996 Coverages are the interface to the HarfBuzz library to acces
3997 OpenType features for handling glyphs not addressable by the cmap.
3998
3999 Right now, compilation of HarfBuzz is only added to the development
4000 build. A solution for standard build mode will be delayed until
4001 HarfBuzz gets split into two libraries to avoid mutual dependencies
4002 between FreeType and HarfBuzz.
4003
4004 Note that this is only a first step in handling coverages, basically
4005 providing the framework only. Code for handling selected OpenType
4006 features (this is, actually using the data in `afcover.h') will
4007 follow.
4008
4009 * devel/ftoption.h, include/config/ftoption.h
4010 (FT_CONFIG_OPTION_USE_HARFBUZZ): New macro.
4011
4012 * src/autofit/hbshim.c, src/autofit/hbshim.h, src/autofit/afcover.h:
4013 New files.
4014
4015 * src/autofit/afscript.h: Add HarfBuzz script name tags.
4016
4017 * src/autofit/afstyles.h: Add default coverage enumeration values.
4018
4019 * src/autofit/aftypes.h: Update use of `SCRIPT' and `STYLE' macros.
4020 (AF_Coverage): New enumeration (generated by `afcover.h').
4021 (AF_StyleClassRec): New member `coverage'.
4022 (AF_DEFINE_STYLE_CLASS): Updated.
4023
4024 * include/internal/fttrace.h: Add `afharfbuzz' for tracing coverage
4025 data.
4026
4027 * src/autofit/afglobal.h: Update use of `SCRIPT' and `STYLE' macros.
4028 (AF_SCRIPT_FALLBACK): Renamed to ...
4029 (AF_STYLE_FALLBACK): ... this.
4030
4031 * src/autofit/afglobal.c: Include `hbshim.c'.
4032 Update use of `SCRIPT' and `STYLE' macros.
4033 (af_face_globals_compute_style_coverage)
4034 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Call `af_get_coverage'.
4035 Update.
4036
4037 * src/autofit/afmodule.h (AF_ModuleRec):
4038 s/fallback_script/fallback_style/.
4039
4040 * src/autofit/afmodule.c (af_property_set): Adapt handling of
4041 `fallback-script' property to set a fallback style.
4042 (af_property_get, af_autofitter_init): Updated.
4043
4044 * src/autofit/afpic.c: Update use of `SCRIPT' and `STYLE' macros.
4045
4046 * src/autofit/afranges.h: Update use of `SCRIPT' macro.
4047
4048 * src/autofit/autofit.c [FT_CONFIG_OPTION_USE_HARFBUZZ]: Include
4049 `hbshim.c'.
4050
4051 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `hbshim.c'.
4052 (AUTOF_DRV_H): Add `afcover.h'.
4053
4054 * builds/freetype.mk (INCLUDE_FLAGS) [DEVEL_DIR]: Use pkg-config for
4055 all libraries needed by FreeType.
4056
40572013-12-21 Werner Lemberg <wl@gnu.org>
4058
Werner Lembergb337fa22013-12-21 19:33:15 +01004059 Fix Savannah bug #40975 (sort of).
4060
4061 * src/truetype/ttinterp.c (Ins_IP): Fix sign typo to make FreeType
4062 behave the same as the Windows TrueType engine for the invalid case.
4063
40642013-12-21 Werner Lemberg <wl@gnu.org>
4065
Werner Lemberg3bf60952013-12-21 08:49:11 +01004066 [autofit] Make PIC mode work actually.
4067
4068 * src/autofit/afpic.h (AFModulePIC): Fix array sizes to fit the
4069 enumeration values automatically generated by including `afscript.h'
4070 and friends.
4071
4072 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
4073
40742013-12-21 Werner Lemberg <wl@gnu.org>
4075
Werner Lembergbd413862013-12-21 08:14:25 +01004076 Fix PIC linking.
4077
4078 * include/internal/ftrfork.h (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Fix
4079 generated function name.
4080
4081 * src/base/basepic.c (FT_Init_Table_raccess_guess_table): Rename
4082 to ...
4083 (FT_Init_Table_ft_raccess_guess_table): ... this so that the
4084 function name correctly corresponds to what the macro framework
4085 expects.
4086
4087 * src/psnames/rules.mk (PSNAMES_DRV_SRC_S): Use correct file name so
4088 that PIC functions are compiled also.
4089
40902013-12-21 Werner Lemberg <wl@gnu.org>
4091
Werner Lembergc4e968e2013-12-21 07:23:08 +01004092 [base] Add missing dependencies to Makefile.
4093
4094 * src/base/rules.mk (BASE_SRC): Add `basepic.c' and `ftpic.c'.
4095 (BASE_H): Add `basepic.h'.
4096
Werner Lemberg974b1932013-12-20 17:26:26 +010040972013-12-20 Werner Lemberg <wl@gnu.org>
4098
Werner Lemberg8a8f3752013-12-20 18:35:35 +01004099 [autofit] Fix PIC compilation.
4100
4101 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
4102 src/autofit/aflatin.c (af_latin_metrics_init_widths)
4103 [FT_CONFIG_OPTION_PIC]: Declare `globals'.
4104
4105 * src/autofit/afglobal.c: Always call AF_DEFINE_SCRIPT_CLASS, and
4106 AF_DEFINE_STYLE_CLASS.
4107
4108 * src/autofit/afpic.c: Include `afglobal.h'.
4109 (autofit_module_class_pic_init): Typo.
4110
4111 * src/autofit/aftypes.h (AF_DEFINE_SCRIPT_CLASS,
4112 AF_DEFINE_STYLE_CLASS): Don't use the same identifier for macro
4113 parameter and structure member.
4114
41152013-12-20 Werner Lemberg <wl@gnu.org>
4116
Werner Lemberg974b1932013-12-20 17:26:26 +01004117 [autofit] Introduce `styles'.
4118
4119 This is the new top-level structure for handling glyph input data;
4120 scripts are now defined separately.
4121
4122 * src/autofit/aftypes.h (SCRIPT): Updated.
4123 (AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
4124 members to ...
4125 (AF_Style_ClassRec): ... this new structure.
4126 (AF_Style): New enumeration.
4127 (AF_StyleMetricsRec): Replace `script' enumeration with
4128 `style_class' pointer.
4129 (AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
4130 (AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
4131
4132 * src/autofit/afstyles.h: New file, using data from `afscript.h'.
4133 * src/autofit/afscript.h: Updated.
4134
4135 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
4136 af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
4137
4138 * src/autofit/afglobal.c (SCRIPT): Updated.
4139 (STYLE): Redefine macro to load `afstyles.h'.
4140 (af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
4141 (af_style_names): ... this array.
4142 (af_face_globals_compute_script_coverage): Renamed to...
4143 (af_face_globals_compute_style_coverage): ... this.
4144 Updated.
4145 (af_face_globals_new, af_face_globals_free,
4146 af_face_globals_get_metrics): Updated.
4147
4148 * src/autofit/afglobal.h (SCRIPT): Updated.
4149 (STYLE): Redefine macro to load `afstyles.h'.
4150 (AF_SCRIPT_FALLBACK): Update definition. This will get more
4151 refinements with later on.
4152 (AF_SCRIPT_UNASSIGNED): Replace with...
4153 (AF_STYLE_UNASSIGNED): ... this macro.
4154 (AF_FaceGlobalsRec): Updated.
4155
4156 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
4157 af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
4158 af_latin_hint_edges): Updated.
4159
4160 * src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
4161 (af_ltn2_uniranges): Removed.
4162
4163 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
4164 Updated.
4165
4166 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
4167 * src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
4168 (AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
4169 members.
4170
4171 * src/autofit/afranges.h: Updated.
4172
4173 * src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
4174
Werner Lembergd8324572013-12-19 15:45:24 +010041752013-12-19 Werner Lemberg <wl@gnu.org>
4176
4177 [autofit] Factor scripts and uniranges out of writing system files.
4178
4179 * src/autofit/afranges.c, src/autofit/afranges.h: New files.
4180
4181 * src/autofit/afscript.h: Extend `SCRIPT' macro with more
4182 parameters, taking data from the writing system files.
4183
4184 * src/autofit/aftypes.h: Updated.
4185
4186 * src/autofit/afglobal.c: Include `afranges.h'.
4187 Load `afscript.h' to call AF_DEFINE_SCRIPT_CLASS.
4188 * src/autofit/afglobal.c: Include `afranges.h'.
4189 Load `afscript.h' to call AF_DECLARE_SCRIPT_CLASS.
4190
4191 * src/autofit/afcjk.c, src/autofit/afcjk.h: Updated.
4192 * src/autofit/afdummy.c, src/autofit/afdummy.h: Updated.
4193 * src/autofit/afindic.c, src/autofit/afindic.h: Updated.
4194 * src/autofit/aflatin.c, src/autofit/aflatin.h: Updated.
4195 * src/autofit/aflatn2.c, src/autofit/aflatn2.h: Updated.
4196
4197 * src/autofit/afpic.c: Updated.
4198
4199 * src/autofir/autofit.c: Include `afranges.c'.
4200 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afranges.c'.
4201
Werner Lemberg9a354552013-12-18 10:36:06 +010042022013-12-18 Werner Lemberg <wl@gnu.org>
4203
Werner Lemberg73f31982013-12-19 15:24:17 +01004204 [autofit] More code orthogonality.
4205
4206 * src/autofit/aftypes.h (AF_StyleMetrics): Replace `script_class'
4207 pointer to an `AF_ScriptClass' structure with `script' index of type
4208 `AF_Script'.
4209 Move some code around.
4210
4211 * src/autofit/afcjk.c: Include `afpic.h'.
4212 (af_cjk_metrics_init_widths, af_cjk_metrics_init_blues,
4213 af_cjk_hint_edges): Updated.
4214
4215 * src/autofit/aflatin.c: Include `afpic.h'.
4216 (af_latin_metrics_init_widths, af_latin_metrics_init_blues,
4217 af_latin_metrics_scale_dim, af_latin_hint_edges): Updated.
4218
4219 * src/autofit/afglobal.c (af_face_globals_get_metrics): Updated.
4220
4221 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
4222 Updated.
4223
42242013-12-18 Werner Lemberg <wl@gnu.org>
4225
Werner Lemberg3f91cb32013-12-18 12:59:35 +01004226 [autofit] s/ScriptMetrics/StyleMetrics/.
4227
42282013-12-18 Werner Lemberg <wl@gnu.org>
4229
Werner Lemberg4fccc212013-12-18 12:53:01 +01004230 [autofit] s/script_{metrics,hints}/style_{metrics,hints}/
4231
42322013-12-18 Werner Lemberg <wl@gnu.org>
4233
Werner Lembergf4df4072013-12-18 10:39:30 +01004234 [autofit] s/gscripts/gstyles/.
4235
42362013-12-18 Werner Lemberg <wl@gnu.org>
4237
Werner Lemberg9a354552013-12-18 10:36:06 +01004238 [autofit] s/glyph_scripts/glyph_styles/.
4239
4240 This is the first commit of a series to create a new top-level
4241 structure (a `style') for handling scripts, writing_systems, and
4242 soon-to-be-added coverages.
4243
Werner Lemberg7a5fc2f2013-12-17 13:29:53 +010042442013-12-17 Werner Lemberg <wl@gnu.org>
4245
4246 [autofit] s/AF_Script_/AF_WritingSystem_/ where appropriate.
4247
Infinality8bb09b02013-12-11 09:01:13 +010042482013-12-11 Infinality <infinality@infinality.net>
4249
4250 [truetype] Simplify logic of rendering modes.
4251
4252 This patch unifies the subpixel and non-subpixel cases.
4253
4254 * src/truetype/ttinterp.h (TT_ExecContextRec): Remove
4255 `grayscale_hinting'; all code should refer to `grayscale' instead.
4256 Remove unused `native_hinting' member.
4257 Rename `subpixel_hinting' member to `subpixel.
4258
4259 * src/truetype/ttgload.c (TT_LOADER_SET_PP): Updated.
4260 (tt_loader_init): Updated.
4261
4262 * src/truetype/ttinterp.c (Ins_GETINFO): Simplify.
4263 Updated.
4264
Werner Lemberge9d95aa2013-12-11 07:48:51 +010042652013-12-11 Werner Lemberg <wl@gnu.org>
4266
4267 [documentation] Add section how to include FreeType header files.
4268 Problem reported by David Kastrup <dak@gnu.org>.
4269
4270 Surprisingly, a description how to do that was completely missing in
4271 the API reference.
4272
4273 * include/freetype.h, include/ftchapters.h: New documentation
4274 section `header_inclusion'.
4275
Werner Lemberg05c786d2013-12-10 08:38:57 +010042762013-12-10 Werner Lemberg <wl@gnu.org>
4277
Werner Lemberg91932592013-12-10 13:24:07 +01004278 [autofit] s/DFLT/NONE/, s/dflt/none/.
4279
42802013-12-10 Werner Lemberg <wl@gnu.org>
4281
Werner Lemberg45244f82013-12-10 13:18:11 +01004282 [autofit] s/AF_SCRIPT_NONE/AF_SCRIPT_UNASSIGNED/.
4283
42842013-12-10 Werner Lemberg <wl@gnu.org>
4285
Werner Lemberg69d1a362013-12-10 10:12:27 +01004286 [truetype] Fix scaling of vertical phantom points.
4287
4288 * src/truetype/ttgload.c (load_truetype_glyph): Scale pp3.x and
4289 pp4.x also.
4290
42912013-12-10 Werner Lemberg <wl@gnu.org>
4292
Werner Lemberg05c786d2013-12-10 08:38:57 +01004293 [truetype] Fix positioning of composite glyphs.
4294 Problem reported by Nigel Tao <nigeltao@golang.org>.
4295
4296 * src/truetype/ttgload.c (TT_Hint_Glyph): Remove code that shifts
4297 the glyph (component) by a fractional value computed from the LSB
4298 phantom point. This is wrong, since the horizontal phantom points
4299 get rounded horizontally later on.
4300
Werner Lembergdd8050a2013-12-08 23:14:46 +010043012013-12-08 Werner Lemberg <wl@gnu.org>
4302
4303 * Version 2.5.2 released.
4304 =========================
4305
4306
4307 Tag sources with `VER-2-5-2'.
4308
4309 * docs/VERSION.DLL: Update documentation and bump version number to
4310 2.5.2.
4311
4312 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
4313 builds/windows/vc2005/index.html,
4314 builds/windows/vc2008/freetype.vcproj,
4315 builds/windows/vc2008/index.html,
4316 builds/windows/vc2010/freetype.vcxproj,
4317 builds/windows/vc2010/index.html,
4318 builds/windows/visualc/freetype.dsp,
4319 builds/windows/visualc/freetype.vcproj,
4320 builds/windows/visualc/index.html,
4321 builds/windows/visualce/freetype.dsp,
4322 builds/windows/visualce/freetype.vcproj,
4323 builds/windows/visualce/index.html,
4324 builds/wince/vc2005-ce/freetype.vcproj,
4325 builds/wince/vc2005-ce/index.html,
4326 builds/wince/vc2008-ce/freetype.vcproj,
4327 builds/wince/vc2008-ce/index.html: s/2.5.1/2.5.2/, s/251/252/.
4328
Werner Lembergec8853c2014-03-06 19:13:45 +01004329 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
Werner Lembergdd8050a2013-12-08 23:14:46 +01004330
4331 * builds/unix/configure.raw (version_info): Set to 17:1:11.
Werner Lembergec8853c2014-03-06 19:13:45 +01004332 * CMakeLists.txt (VERSION_PATCH): Set to 2.
Werner Lembergdd8050a2013-12-08 23:14:46 +01004333 * docs/CHANGES: Updated.
4334
Werner Lemberg98d185c2013-12-07 09:26:55 +010043352013-12-07 Werner Lemberg <wl@gnu.org>
4336
4337 [truetype] Next round in phantom point handling.
4338
4339 Greg Hitchcock provided very interesting insights into the
4340 complicated history of the horizontal positions of the TSB and BSB
4341 phantom points.
4342
4343 * src/truetype/ttgload.c (TT_LOADER_SET_PP)
4344 [TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Use `subpixel_hinting' and
4345 `grayscale_hinting' flags as conditionals for the x position of TSB
4346 and BSB.
4347
Werner Lembergfcdb7842013-12-05 15:53:27 +010043482013-12-05 Werner Lemberg <wl@gnu.org>
4349
4350 * builds/freetype.mk (FT_CC): Removed. Unused.
4351
Werner Lemberg64b395c2013-12-04 06:18:56 +010043522013-12-04 Werner Lemberg <wl@gnu.org>
4353
4354 [sfnt] Fix handling of embedded bitmap strikes.
4355
4356 This corrects the commit from 2013-11-21. Problem reported by
4357 Andrey Panov <panov@canopus.iacp.dvo.ru>.
4358
4359 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Fix logic to
4360 detect excessive bytes for bit-aligned bitmaps.
4361
Werner Lembergbdd5e752013-12-03 06:57:02 +010043622013-12-03 Werner Lemberg <wl@gnu.org>
4363
Werner Lembergc2b47532013-12-03 07:01:57 +01004364 [truetype] Remove dead code.
4365
4366 Reported by Nigel Tao <nigeltao@golang.org>.
4367
4368 * include/internal/tttypes.h (TT_LoaderRec): Remove unused
4369 `preserve_pps' field.
4370 * src/truetype/ttgload.c (TT_Hint_Glyph): Updated.
4371
43722013-12-03 Werner Lemberg <wl@gnu.org>
4373
Werner Lembergbdd5e752013-12-03 06:57:02 +01004374 [truetype] Fix phantom point handling.
4375
4376 This is a further improvement to the changes from 2013-11-06.
4377
4378 * src/truetype/ttgload.c (TT_Hint_Glyph): Horizontal phantom points
4379 are rounded horizontally, vertical ones are rounded vertically.
4380 (TT_LOADER_SET_PP): The horizontal position of vertical phantom
4381 points in pre-ClearType mode is zero, as shown in the OpenType
4382 specification.
4383
Werner Lemberg64872a52013-12-02 07:51:17 +010043842013-12-02 Werner Lemberg <wl@gnu.org>
4385
4386 [truetype] Fix change from 2013-11-20.
4387
4388 Problem reported by Akira Kakuto <kakuto@fuk.kindai.ac.jp>.
4389
4390 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Protect call to
4391 `Update_Max' with both a TT_USE_BYTECODE_INTERPRETER guard and a
4392 `IS_HINTED' clause.
4393 Also remove redundant check using `maxSizeOfInstructions' – in
4394 simple glyphs, the bytecode data comes before the outline data, and
4395 a validity test for this is already present.
4396
Werner Lemberg52166ab2013-11-27 10:10:16 +010043972013-11-27 Werner Lemberg <wl@gnu.org>
4398
4399 [autofit] Fix use of dumping functions in `ftgrid' demo program.
4400
4401 * src/autofit/afhints.c (AF_DUMP) [FT_DEBUG_AUTOFIT]: New macro.
4402 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
4403 af_glyph_hints_dump_edges) [FT_DEBUG_AUTOFIT]: Add parameter to
4404 handle output to stdout.
4405 Use AF_DUMP.
4406 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
4407 af_glyph_hints_dump_edges) [!FT_DEBUG_AUTOFIT]: Removed.
4408
Werner Lemberg3aee4292013-11-25 00:28:11 +010044092013-11-25 Werner Lemberg <wl@gnu.org>
4410
4411 * Version 2.5.1 released.
4412 =========================
4413
4414
4415 Tag sources with `VER-2-5-1'.
4416
4417 * docs/VERSION.DLL: Update documentation and bump version number to
4418 2.5.1.
4419
4420 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
4421 builds/windows/vc2005/index.html,
4422 builds/windows/vc2008/freetype.vcproj,
4423 builds/windows/vc2008/index.html,
4424 builds/windows/vc2010/freetype.vcxproj,
4425 builds/windows/vc2010/index.html,
4426 builds/windows/visualc/freetype.dsp,
4427 builds/windows/visualc/freetype.vcproj,
4428 builds/windows/visualc/index.html,
4429 builds/windows/visualce/freetype.dsp,
4430 builds/windows/visualce/freetype.vcproj,
4431 builds/windows/visualce/index.html,
4432 builds/wince/vc2005-ce/freetype.vcproj,
4433 builds/wince/vc2005-ce/index.html,
4434 builds/wince/vc2008-ce/freetype.vcproj,
4435 builds/wince/vc2008-ce/index.html: s/2.5.0/2.5.1/, s/250/251/.
4436
4437 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
4438
4439 * builds/unix/configure.raw (version_info): Set to 17:0:11.
Werner Lembergec8853c2014-03-06 19:13:45 +01004440 * CMakeLists.txt (VERSION_PATCH): Set to 1.
Werner Lemberg3aee4292013-11-25 00:28:11 +01004441 * docs/CHANGES, docs/release: Updated.
4442
Werner Lemberg9326caf2013-11-23 23:59:25 +010044432013-11-23 Werner Lemberg <wl@gnu.org>
4444
Werner Lemberg063ee6b2013-11-24 00:19:17 +01004445 [truetype]: Add tricky font names `hkscsiic.ttf' and `iicore.ttf'.
4446
4447 * src/truetype/ttobjs.c (TRICK_NAMES_MAX_CHARACTERS,
4448 TRICK_NAMES_COUNT): Updated.
4449 (trick_names): Add family name for the two fonts.
4450
44512013-11-23 Werner Lemberg <wl@gnu.org>
4452
Werner Lemberg9326caf2013-11-23 23:59:25 +01004453 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Typo.
4454
Werner Lemberg427b1762013-11-21 13:10:56 +010044552013-11-21 Werner Lemberg <wl@gnu.org>
4456
Werner Lemberg9326caf2013-11-23 23:59:25 +01004457 [sfnt] Typo.
Werner Lemberg8af2a1c2013-11-21 13:13:12 +01004458
4459 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
4460
4461 * src/sfnt/sfobjs.c (sfnt_load_face): Return correct `bsize->width'
4462 value if the font lacks an `OS/2' table.
4463
44642013-11-21 Werner Lemberg <wl@gnu.org>
4465
Werner Lemberg64b395c2013-12-04 06:18:56 +01004466 [sfnt] Improve handling of buggy embedded bitmap strikes.
Werner Lemberg427b1762013-11-21 13:10:56 +01004467
4468 We are now able to successfully load `AppleMyoungJo.ttf'.
4469 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
4470
4471 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Don't trust glyph
4472 format.
4473
Werner Lemberg28626862013-11-20 21:06:18 +010044742013-11-20 Werner Lemberg <wl@gnu.org>
4475
4476 [truetype] Don't trust `maxp's `maxSizeOfInstructions'.
4477
4478 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>; see
4479
4480 http://lists.nongnu.org/archive/html/freetype-devel/2013-08/msg00005.html
4481
4482 for details.
4483
4484 * src/base/ftobjs.c (FT_Load_Glyph): Check size of `fpgm' and `prep'
4485 tables also for setting `autohint'.
4486
4487 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Use code from
4488 `TT_Process_Composite_Glyph' for handling unreliable values of
4489 `maxSizeOfInstructions'.
4490
Werner Lembergbc25de62013-11-16 07:52:20 +010044912013-11-16 Werner Lemberg <wl@gnu.org>
4492
4493 [sfnt] Fix `OS/2' table version 5 support.
4494
4495 We now follow the `official' announcement from Microsoft (on the
4496 OpenType mailing list, which unfortunately hasn't a public archive).
4497
4498 * include/freetype/tttables.h (TT_OS2):
4499 s/usLowerPointSize/usLowerOpticalPointSize/,
4500 s/usUpperPointSize/usUpperOpticalPointSize/.
4501
4502 * src/sfnt/ttload.c (tt_face_load_os2): Update, and set correct
4503 default values.
4504
Werner Lembergfae38202013-11-13 08:55:46 +010045052013-11-13 Werner Lemberg <wl@gnu.org>
4506
Werner Lembergc52b1292013-11-13 10:06:00 +01004507 * builds/unix/ft2unix.h: Remove. No longer necessary.
4508
4509 * builds/unix/install.mk (install): Updated.
4510
45112013-11-13 Werner Lemberg <wl@gnu.org>
4512
Werner Lembergfae38202013-11-13 08:55:46 +01004513 Simplify header file hierarchy.
4514
4515 This large patch changes the header file directory layout from
4516 `include/freetype/...' to `include/...', effectively removing one
4517 level. Since the file `ft2build.h' is also located in `include'
4518 (and it stays there even after installation), all FreeType header
4519 files are now in a single directory.
4520
4521 Applications that use (a) `freetype-config' or FreeType's
4522 `pkg-config' file to get the include directory for the compiler, and
4523 (b) the documented way for header inclusion like
4524
4525 #include <ft2build.h>
4526 #include FT_FREETYPE_H
4527 ...
4528
4529 don't need any change to the source code.
4530
4531 * include/freetype/*: Move up to...
4532 * include/*: ... this directory.
4533
4534 * builds/amiga/include/freetype/*: Move up to...
4535 * builds/amiga/include/*: ... this directory.
4536
4537 */*: Essentially do `s@/freetype/@/@' where appropriate.
4538
4539 * CMakeList.txt: Simplify.
4540 * builds/unix/freetype-config.in, builds/unix/freetype2.in: For
4541 `--cflags', return a single directory.
4542 * builds/unix/install.mk (install): No longer try to remove `cache'
4543 and `internal' subdirectories; instead, remove the `freetype'
4544 subdirectory.
4545
Werner Lembergea5c7812013-11-12 08:55:26 +010045462013-11-12 Werner Lemberg <wl@gnu.org>
4547
4548 [truetype] Fix last `truetype' commit.
4549
4550 * src/truetype/ttgload.c (tt_get_metrics): Preserve stream position.
4551 Return error value.
4552 (load_truetype_glyph): Updated.
4553
Werner Lemberg78333282013-11-10 06:26:52 +010045542013-11-10 Werner Lemberg <wl@gnu.org>
4555
4556 * docs/CMAKE: New dummy file.
4557
Dave Arnolddd213012013-11-08 10:52:51 +010045582013-11-08 Dave Arnold <darnold@adobe.com>
4559
4560 [cff] Fix for hints that touch.
4561
4562 * src/cff/cf2hints.c (cf2_hintmap_insertHint): Fix condition for
4563 finding index value of insertion point.
4564
Werner Lemberg7e4b0fb2013-11-06 07:14:49 +010045652013-11-06 Werner Lemberg <wl@gnu.org>
4566
Werner Lemberg5e225b72013-11-06 08:41:59 +01004567 [truetype] Fix handling of phantom points in composite glyphs.
4568 Problem reported by Nigel Tao <nigeltao@golang.org>.
4569
4570 This is a follow-up commit to the previous one.
4571
4572 * src/truetype/ttgload.c (load_truetype_glyph): Call
4573 `tt_get_metrics' after loading the glyph header.
4574
45752013-11-06 Werner Lemberg <wl@gnu.org>
4576
Werner Lemberg7e4b0fb2013-11-06 07:14:49 +01004577 [truetype] Improve emulation of vertical metrics.
4578
4579 This commit also improves the start values of vertical phantom
4580 points. Kudos to Greg Hitchcock for help.
4581
4582 * src/truetype/ttgload.c (TT_Get_VMetrics): Add parameter to pass
4583 `yMax' value. Replace code with fixed Microsoft definition.
4584 (tt_get_metrics): Updated.
4585 (TT_LOADER_SET_PP): Add explanation how to initialize phantom
4586 points, taken from both the OpenType specification and private
4587 communication with Greg (which will eventually be added to the
4588 standard).
4589 Fix horizontal position of `pp3' and `pp4'.
4590
4591 * src/truetype/ttgload.h: Updated.
4592
4593 * src/truetype/ttdriver.c (tt_get_advances): Updated.
4594
4595 * docs/CHANGES: Updated.
4596
Werner Lembergc6064282013-11-05 13:29:15 +010045972013-11-05 Werner Lemberg <wl@gnu.org>
4598
Werner Lemberg50740532013-11-05 23:19:18 +01004599 * builds/windows/vc2010/freetype.vcxproj: s/v110/v100/.
4600 PlatformToolSet version 110 is for VC2012.
4601
4602 Problem reported (with solution) by Dave Arnold <darnold@adobe.com>.
4603
46042013-11-05 Werner Lemberg <wl@gnu.org>
4605
Werner Lembergc6064282013-11-05 13:29:15 +01004606 [truetype] Correctly reset point tags for glyph components.
4607 Problem reported by Nigel Tao <nigeltao@golang.org>.
4608
4609 * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Fix loop.
4610
Werner Lemberg35b08182013-11-02 08:28:41 +010046112013-11-02 Werner Lemberg <wl@gnu.org>
4612
Werner Lemberg7d449432013-11-02 11:36:37 +01004613 [truetype] Fix GETINFO opcode handling of subpixel hinting bits.
4614
4615 * src/truetype/ttinterp.c (Ins_GETINFO): Don't request bit 6 set to
4616 get info on subpixel hinting.
4617
4618 * docs/CHANGES: Updated.
4619
46202013-11-02 Werner Lemberg <wl@gnu.org>
4621
Werner Lemberg35b08182013-11-02 08:28:41 +01004622 Fix Savannah bug #40451.
4623
4624 Simply apply the patch from the bug report.
4625
4626 * builds/unix/ftconfig.in, builds/vms/ftconfig.h,
4627 include/freetype/config/ftconfig.h: The used #pragma directives only
4628 work with gcc versions 4.6 and higher.
4629
Werner Lembergebf52d62013-11-01 13:26:28 +010046302013-11-01 Werner Lemberg <wl@gnu.org>
4631
Werner Lembergafa0d592013-11-01 22:27:27 +01004632 * docs/CHANGES: Updated.
4633
46342013-11-01 Werner Lemberg <wl@gnu.org>
4635
Werner Lembergebf52d62013-11-01 13:26:28 +01004636 [truetype] Minor code refactoring.
4637
4638 Two benefits: The allocated FDEF (and IDEF) array gets slightly
4639 smaller, and the `ttdebug' demo program has access to function
4640 numbers without additional costs.
4641
4642 Fortunately, no changes to FontForge are necessary – this is the
4643 only external TrueType debugger I know of, but others may exist and
4644 should check the code accordingly.
4645
4646 * src/truetype/ttinterp.h (TT_CallRec): Replace `Cur_Restart' and
4647 `Cur_End' with a pointer to the corresponding `TT_DefRecord'
4648 structure.
4649
4650 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF, Ins_ENDF,
4651 Ins_CALL, Ins_LOOPCALL, Ins_UNKNOWN, TT_RunIns <Invalid_Opcode>):
4652 Updated.
4653
Werner Lembergee510512013-10-27 07:25:35 +010046542013-10-27 Werner Lemberg <wl@gnu.org>
4655
4656 [sfnt] Implement support for `OS/2' table version 5.
4657
4658 See
4659
4660 http://typedrawers.com/discussion/470/new-microsoft-size-specific-design-selection-mechanism
4661
4662 for the announcement.
4663
4664 * include/freetype/tttables.h (TT_OS2): Add fields
4665 `usLowerPointSize' and `usUpperPointSize'. Since FreeType returns
4666 this structure only as a pointer through `FT_Get_Sfnt_Table', there
4667 shouldn't be any ABI problems.
4668
4669 * src/sfnt/ttload.c (tt_face_load_os2): Implement it.
4670
4671 * docs/CHANGES: Updated.
4672
Werner Lemberg994a8592013-10-24 08:50:34 +020046732013-10-24 Werner Lemberg <wl@gnu.org>
4674
4675 * README.git, docs/CHANGES, docs/INSTALL: Updated.
4676
John Carya0e4a732013-10-24 08:49:08 +020046772013-10-24 John Cary <cary@txcorp.com>
4678
4679 Provide cmake support.
4680
4681 * CMakeLists.txt: New file.
4682
Kenneth Miller4d87ac82013-10-23 20:10:56 +020046832013-10-23 Kenneth Miller <kennethadammiller@yahoo.com>
4684 Werner Lemberg <wl@gnu.org>
4685
4686 Provide support for x64 builds in Visual C++ project files.
4687
4688 * src/builds/win32: Renamed to...
4689 * src/builds/windows: This.
4690
4691 * src/builds/windows/vc2010/*: Updated to handle x64 target.
4692
4693 * src/builds/windows/*.mk, docs/INSTALL.GNU: s/win32/windows/ where
4694 appropriate.
4695
Werner Lemberg604838d2013-10-22 01:10:10 +020046962013-10-22 Werner Lemberg <wl@gnu.org>
4697
4698 * src/base/md5.c, src/base/md5.h: Updated to recent version.
4699
4700 * src/base/ftobjs.c: Updated; `md5.c' no longer uses `free'.
4701
Werner Lembergdb9159c2013-10-22 10:27:50 +02004702 The canonical URL to get updates for this file is
4703
4704 http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/popa3d/popa3d/md5/
4705
4706 as the author told me in private communication.
4707
Werner Lemberg34efe052013-10-19 21:14:40 +020047082013-10-19 Werner Lemberg <wl@gnu.org>
4709
Werner Lemberg75efc2d2013-10-19 21:46:03 +02004710 [autofit] s/SMALL_TOP/X_HEIGHT/.
4711
4712 * src/autofit/afblue.dat: Updated.
4713
4714 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4715
4716 * src/autofit/aflatin.c, src/autofit/aflatin.h,
4717 src/autofit/atlatin2.c: Updated.
4718
47192013-10-19 Werner Lemberg <wl@gnu.org>
4720
Werner Lemberg34efe052013-10-19 21:14:40 +02004721 * src/autofit/afblue.dat: s/MINOR/DESCENDER/.
4722
4723 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4724
Werner Lemberg955f6a82013-10-16 19:47:57 +020047252013-10-16 Werner Lemberg <wl@gnu.org>
4726
Werner Lemberga5f22a92013-10-17 11:08:25 +02004727 [autofit] Add description strings to script entries.
4728
4729 Currently, this is unused.
4730
4731 * src/autofit/afscript.h: Do it.
4732 * src/autofit/afglobal.c, src/autofit/afpic.c,
4733 src/autofit/aftypes.h: Updated.
4734
47352013-10-16 Werner Lemberg <wl@gnu.org>
4736
Werner Lemberg955f6a82013-10-16 19:47:57 +02004737 [autofit] Improve tracing message for extra light flag.
4738
4739 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Do it.
4740
Chongyu Zhu41632b52013-10-15 11:40:34 +020047412013-10-15 Chongyu Zhu <lembacon@gmail.com>
4742
4743 [arm] Fix thumb2 inline assembly under LLVM.
4744
4745 When using `ADD' with an immediate operand, the instruction is
4746 actually `ADD Rd, Rn, #<imm12>', that is, the maximum of the
4747 immediate operand cannot exceed 4095. It will fail to compile with
4748 LLVM.
4749
4750 However, in GCC, due to some legacy compatibility considerations,
4751 `ADD.W' will be automatically emitted when the immediate operand is
4752 larger than 4095.
4753
4754 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
4755 (FT_MulFix_arm) [__GNUC__]: Support clang compiler.
4756
4757 * src/truetype/ttinterp.c (TT_MulFix14_arm) [__GNUC__]: Ditto.
4758
Werner Lembergb6695242013-10-12 10:33:04 +020047592013-10-12 Werner Lemberg <wl@gnu.org>
4760
4761 [autofit] Improve tracing of `latin' hinter.
4762
4763 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Report blue
4764 zone types.
4765 (af_latin_metrics_scale_dim): Report scaling changes due to x height
4766 alignment.
4767 Report scaled stroke width and blue zone values.
4768
Dave Arnolde845a852013-10-03 23:04:29 +020047692013-10-03 Dave Arnold <darnold@adobe.com>
4770
4771 * src/cff/cf2font.c (cf2_computeDarkening): Avoid division by zero.
4772
Werner Lemberg2c56f2a2013-10-07 22:01:00 +02004773 Note that the old code avoided using a region of the piecewise
4774 linear function where the slope was zero. The recovery was to use a
4775 different section of the function, which produced a different,
4776 incorrect amount of darkening.
4777
Darrell Bellert01af71d2013-10-02 22:04:07 +020047782013-10-02 Darrell Bellert <darrell.bellert@hl.konicaminolta.us>
4779
4780 * src/sfnt/ttload.c (tt_face_load_pclt): Fix `pclt_fields'.
4781
Dave Arnold0b330452013-10-02 11:04:06 +020047822013-10-02 Dave Arnold <darnold@adobe.com>
4783
4784 * src/cff/cf2font.c (cf2_computeDarkening): Initialize darkenAmount.
4785
4786 This line was lost in commit 89ca1fd6 (from 2013-06-25). The effect
4787 is to use a previous darkening amount when producing an unhinted,
4788 unscaled outline. This can cause autohint samples in ftgrid and
4789 ftview to be based on darkened CFF outlines instead of unhinted,
4790 undarkened ones.
4791
Dave Arnold3a2cb0f2013-09-29 16:17:02 +020047922013-09-29 Dave Arnold <darnold@adobe.com>
4793
4794 Fix Savannah bug #39295.
4795
4796 The bug was caused by switching to the initial hintmap (the one in
4797 effect when `moveto' executes) just before drawing the final element
4798 in the charstring. This ensured that the path was closed (in both
4799 Character Space and Device Space). But if the final element was a
4800 curve and if the final hintmap was different enough from the initial
4801 one, then the curve was visibly distorted.
4802
4803 The first part of the fix is to draw the final curve using the final
4804 hintmap as specified by the charstring. This corrects the
4805 distortion but does not ensure closing in Device Space. It may
4806 require the rasterizer to automatically generate an extra closing
4807 line. Depending on the hintmap differences, this line could be from
4808 zero to a couple pixels in length.
4809
4810 The second part of the fix covers the case where the charstring
4811 subpath is closed with an explicit line. We now modify that line's
4812 end point to avoid the distortion.
4813
4814 Some glyphs in the bug report font (TexGyreHeros-Regular) that show
4815 the change are:
4816
4817 25ppem S (98)
4818 24ppem eight (52)
4819 25.5ppem p (85)
4820
4821 Curves at the *end* of a subpath are no longer distorted. However,
4822 some of these glyphs have bad hint substitutions in the middle of a
4823 subpath, and these are not affected.
4824
4825 The patch has been tested with a set of 106 fonts that shipped with
4826 Adobe Creative Suite 4, together with 756 Open Source CFF fonts from
4827 Google Fonts. There are 1.5 million glyphs, of which some 20k are
4828 changed with the fix. A sampling of a few hundred of these changes
4829 have been examined more closely, and the changes look good (or at
4830 least acceptable).
4831
4832 * src/cff/cf2hints.h (CF2_GlyphPathRec): New element `pathIsClosing'
4833 to indicate that we synthesize a closepath line.
4834
4835 * src/cff/cf2hints.c (cf2_glyphpath_init): Updated.
4836 (cf2_glyphpath_pushPrevElem): If closing, use first hint map (for
4837 `lineto' operator) and adjust hint zone.
4838 For synthesized closing lines, use end point in first hint zone.
4839 (cf2_glyphpath_lineTo): Take care of synthesized closing lines. In
4840 particular, shift the detection of zero-length lines from character
4841 space to device space.
4842 (cf2_glyphpath_closeOpenPath): Remove assertion.
4843 Updated.
4844
Werner Lembergb75a8b82013-09-25 09:46:36 +020048452013-09-25 Werner Lemberg <wl@gnu.org>
4846
4847 * src/autofit/aflatin.c (af_{grek,cyrl}_uniranges): Fix arrays.
4848
suzuki toshiyaac0f4452013-09-25 10:57:17 +090048492013-09-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4850
4851 [bdf, pcf] Refuse non-zero face_index.
Werner Lemberg964317e2013-09-25 09:22:40 +02004852
suzuki toshiyaac0f4452013-09-25 10:57:17 +09004853 Suggested by Akira Tagoh, see
4854
4855 http://lists.gnu.org/archive/html/freetype/2013-09/msg00030.html
4856
Werner Lemberg964317e2013-09-25 09:22:40 +02004857 * src/bdf/bdfdrivr.c (BDF_Face_Init): Return `Invalid_Argument'
4858 error if the font could be opened but non-zero `face_index' is
4859 given.
suzuki toshiyaac0f4452013-09-25 10:57:17 +09004860 * src/pcf/pcfdrivr.c (PCF_Face_Init): Ditto.
4861
4862 * src/type42/t42objs.c (T42_Face_Init): Remove unrequired FT_UNUSED
Werner Lemberg964317e2013-09-25 09:22:40 +02004863 macro for `face_index' because it is validated later.
suzuki toshiyaac0f4452013-09-25 10:57:17 +09004864
Werner Lemberg4de77872013-09-23 22:10:08 +020048652013-09-23 Werner Lemberg <wl@gnu.org>
4866
4867 Fix Savannah bug #40090.
4868
4869 * src/autofit/afcjk.c (af_cjk_metrics_scale): Revert commit
4870 306f8c5d (from 2013-08-25) affecting this function.
4871
Werner Lemberg5a4c5a52013-09-22 22:37:26 +020048722013-09-22 Werner Lemberg <wl@gnu.org>
4873
4874 [autofit] Disunify Cyrillic and Greek handling from Latin.
4875
4876 * src/autofit/afscript.h: Add Cyrillic and Greek.
4877
4878 * src/autofit/afblue.dat (AF_BLUE_STRINGSET_GREK,
4879 AF_BLUE_STRINGSET_CYRL): Add blue zones for Greek and Cyrillic.
4880 (AF_BLUE_STRINGSET_LATN): Fix typo.
4881 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4882
4883 * src/autofit/aflatin.c (af_grek_uniranges, af_cyrl_uniranges): New
4884 arrays.
4885 (af_grek_script_class, af_cyrl_script_class): New scripts.
4886 * src/autofit/aflatin.h: Updated.
4887
Werner Lemberg2cca9662013-09-20 07:23:34 +020048882013-09-20 Werner Lemberg <wl@gnu.org>
4889
4890 * docs/CHANGES: Updated.
4891
Behdad Esfahbod31e726d2013-09-20 07:20:53 +020048922013-09-20 Behdad Esfahbod <behdad@behdad.org>
4893
4894 Fix vertical size of emboldened glyphs.
4895
4896 Cf. https://bugzilla.gnome.org/show_bug.cgi?id=686709
4897
4898 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Adjust `horiBearingY'
4899 also.
4900
Alexei Podtelezhnikov52381c12013-09-11 23:25:56 -040049012013-09-11 Alexei Podtelezhnikov <apodtele@gmail.com>
4902
4903 * include/freetype/ftoutln.h: Correct FT_Outline_Get_Orientation
4904 algorithm description.
4905
Werner Lemberg3f542492013-09-11 23:08:31 +020049062013-09-11 Werner Lemberg <wl@gnu.org>
4907
4908 [autofit] Improve Hebrew rendering.
4909
4910 This change introduces a new blue zone property
4911 `AF_BLUE_PROPERTY_LATIN_LONG' to make the auto-hinter ignore short
4912 top segments.
4913
4914 * src/autofit/afblue.dat: Fix Hebrew blue strings.
4915 Use AF_BLUE_PROPERTY_LATIN_LONG for AF_BLUE_STRING_HEBREW_TOP.
4916
4917 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_LONG): New macro.
4918
4919 * src/autofit/afblue.c, src/autofit/afblue.h: Updated.
4920
4921 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Handle
4922 `AF_LATIN_IS_LONG_BLUE'.
4923
4924 * src/autofit/aflatin.h (AF_LATIN_IS_LONG_BLUE): New macro.
4925
Werner Lemberg85a7fdf2013-08-29 21:03:05 +020049262013-08-28 Behdad Esfahbod <behdad@google.com>
4927
4928 [sfnt] Fix frame access while reading WOFF table directory.
4929
4930 * src/sfnt/sfobjs.c (woff_open_font): Using single memory frame
4931 while reading the directory entries for the whole loop.
4932
49332013-08-29 Werner Lemberg <wl@gnu.org>
Werner Lembergd689d1c2013-08-29 17:53:40 +02004934 Behdad Esfahbod <behdad@google.com>
4935
4936 Implement support for WOFF containers.
4937
4938 We simply synthesize a SFNT from the WOFF, create a memory stream
4939 for the new data, and load the SFNT as usual.
4940
4941 Does NOT add any API to access WOFF metadata or private blocks.
4942
4943 * include/freetype/internal/tttypes.h (WOFF_HeaderRec,
4944 WOFF_TableRec): New structures.
4945
4946 * include/freetype/tttags.h (TTAG_wOFF): New macro.
4947
4948 * src/base/ftobjs.c (FT_Open_Face): Set `stream' after calling
4949 `open_face'.
4950
4951 * src/sfnt/sfobjs.c [FT_CONFIG_OPTION_SYSTEM_ZLIB]: Include
4952 `FT_GZIP_H'.
4953 (WRITE_BYTE, WRITE_USHORT, WRITE_ULONG): New temporary macros for
4954 writing to a stream.
4955 (sfnt_stream_close, compare_offsets, woff_open_font): New functions.
4956 (sfnt_open_font): Handle `TTAG_wOFF'.
4957 (sfnt_init_face): Set `stream' after calling `sfnt_open_font'.
4958
4959 * src/truetype/ttobjs.c (tt_face_init): Set `stream' after calling
4960 `sfnt->init_face'.
4961
4962 * src/base/ftobjs.c (open_face): Use a pointer to FT_Stream as an
4963 argument so that a changed stream survives.
4964 Update callers.
4965
49662013-08-28 Werner Lemberg <wl@gnu.org>
Werner Lemberge0f39ae2013-08-28 17:34:01 +02004967
Werner Lembergdc240522013-08-29 17:53:24 +02004968 [gzip] New function `FT_Gzip_Uncompress'.
4969
4970 This is modeled after zlib's `uncompress' function. We need this
4971 for WOFF support.
4972
4973 * include/freetype/ftgzip.h, src/gzip/ftgzip.c (FT_Gzip_Uncompress):
4974 New function.
4975
4976 * src/gzip/rules.mk: Rewrite to better reflect dependencies.
4977
49782013-08-28 Werner Lemberg <wl@gnu.org>
4979
Werner Lemberg5195ecd2013-08-28 17:41:21 +02004980 [autofit] Fix `make multi' compilation.
4981
4982 * src/autofit/afblue.cin, src/autofit/afblue.c: Don't include
4983 `afblue.h' but `aftypes.h'.
4984 * src/autofit/afcjk.c: Don't include `aftypes.h' but `afglobal.h'.
4985
49862013-08-28 Werner Lemberg <wl@gnu.org>
4987
Werner Lemberge0f39ae2013-08-28 17:34:01 +02004988 [autofit] Fix C++ compilation.
4989
4990 * src/autofit/afglobal.c (af_face_globals_get_metrics),
4991 src/autofit/afdummy.c (af_dflt_script_class), src/autofit/afindic.c
4992 (af_deva_script_class): Use proper casts.
4993
Behdad Esfahbodbd3849e2013-08-27 21:43:38 +020049942013-08-27 Behdad Esfahbod <behdad@google.com>
4995
Behdad Esfahbodc799dd62013-08-27 21:46:03 +02004996 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix sign typos.
4997
49982013-08-27 Behdad Esfahbod <behdad@google.com>
4999
Behdad Esfahbodbd3849e2013-08-27 21:43:38 +02005000 FT_Open_Face: Improve external stream handling.
5001
5002 If the font's `clazz->init_face' function wants to swap to new
5003 stream, handling of whether original stream was external could
5004 result to either memory leak or double free. Mark externality into
5005 face flags before calling `init_face' such that the clazz can handle
5006 external streams properly.
5007
5008 * src/base/ftobjs.c (FT_Open_Face): Move code to set
5009 FT_FACE_FLAG_EXTERNAL_STREAM to...
5010 (open_face): This function.
5011
Werner Lemberg5e53db22013-08-27 18:37:39 +020050122013-08-27 Werner Lemberg <wl@gnu.org>
5013
Werner Lembergbcd8c0b2013-08-27 21:36:03 +02005014 Remove `FT_SqrtFixed' function.
5015
5016 It's no longer used.
5017
5018 * include/freetype/internal/ftcalc.h, src/base/ftcalc.c: Do it.
5019
50202013-08-27 Werner Lemberg <wl@gnu.org>
5021
Werner Lemberg5e53db22013-08-27 18:37:39 +02005022 [autofit] While tracing, report script names instead of ID values.
5023
5024 * src/autofit/afglobal.c (af_script_names) [FT_DEBUG_LEVEL_TRACE]:
5025 New array.
5026 * src/autofit/afglobal.h: Updated.
5027
5028 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
5029 af_cjk_hint_edges): Use `af_script_names'.
5030 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
5031 af_latin_hint_edges): Ditto.
5032
Werner Lemberg92f5a042013-08-26 09:22:27 +020050332013-08-26 Werner Lemberg <wl@gnu.org>
5034
Werner Lemberg278f64b2013-08-26 20:20:03 +02005035 [autofit] Report used script while hinting a glyph.
5036
5037 * src/autofit/afcjk.c (af_cjk_hint_edges), src/autofit/aflatin.c
5038 (af_latin_hint_edges): Implement it.
5039
50402013-08-26 Werner Lemberg <wl@gnu.org>
5041
Werner Lemberg371f5c32013-08-26 20:11:24 +02005042 [autofit] Add support for Hebrew script.
5043
5044 * src/autofit/afblue.dat: Add blue strings for Hebrew.
5045 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
5046
5047 * src/autofit/aflatin.c (af_hebr_uniranges): New array.
5048 (af_hebr_script_class): New script.
5049 * src/autofit/aflatin.h, src/autofit/afscript.h: Updated.
5050
50512013-08-26 Werner Lemberg <wl@gnu.org>
5052
Werner Lemberg098121d2013-08-26 18:54:05 +02005053 [autofit] Improve tracing messages.
5054
5055 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Mention script
5056 ID in tracing message.
5057 (af_cjk_metrics_init_blues): Initialize `axis' outside of the inner
5058 loop.
5059 Improve tracing messages.
5060 (af_cjk_hint_edges) [FT_DEBUG_LEVEL_TRACE]: New variable
5061 `num_actions' to count hinting actions.
5062 Improve tracing messages.
5063
5064 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Mention
5065 script ID in tracing message.
5066 (af_latin_metrics_init_blues, af_latin_hint_edges): Improve tracing
5067 messages.
5068
50692013-08-26 Werner Lemberg <wl@gnu.org>
5070
Werner Lembergffee64a2013-08-26 12:55:48 +02005071 Better tracing of loaded glyphs.
5072
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005073 Previously, the loading of a glyph was traced at level 4, if at all.
Werner Lembergffee64a2013-08-26 12:55:48 +02005074 With this change, all font loading routines emit a tracing message
5075 at level 1, making it easier to select tracing output (for example
5076 using F2_DEBUG="any:1 afhints:7 aflatin:7").
5077
5078 * src/bdf/bdfdrivr.c (BDF_Glyph_Load): Add tracing message.
5079 * src/cff/cffdrivr.c (cff_glyph_load): Ditto.
5080 * src/cff/cffgload.c (cff_decoder_prepare): Improve tracing
5081 messages.
5082 * src/cid/cidgload.c (cid_load_glyph): Use level 1 for tracing
5083 message.
5084 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Ditto.
5085 * src/pfr/pfrobjs.c (pfr_slot_load): Add tracing message.
5086 * src/truetype/ttgload.c (TT_Load_Glyph): Ditto.
5087 * src/type1/t1gload.c (T1_Load_Glyph): Ditto.
5088 * src/type42/t42objs.c (T42_GlyphSlot_Load): Ditto.
5089 * src/winfonts/winfnt.c (FNT_Load_Glyph): Ditto.
5090
50912013-08-26 Werner Lemberg <wl@gnu.org>
5092
Werner Lemberg33655a92013-08-26 09:58:50 +02005093 [autofit] Fix script selection.
5094
5095 * src/autofit/afglobal.c (af_face_globals_get_metrics): Use
5096 `AF_SCRIPT_DFLT', not value 0.
5097 Simplify code.
5098
5099 * src/autofit/afscript.h: Sort by script name.
5100
51012013-08-26 Werner Lemberg <wl@gnu.org>
5102
Werner Lemberg92f5a042013-08-26 09:22:27 +02005103 [autofit] Make `dummy' hinter work as expected.
5104
5105 * src/autofit/afdummy.c (af_dummy_hints_init): Properly set scaling
5106 information.
5107 (af_dummy_hints_apply): Scale the glyphs.
5108
Werner Lemberg8b8be782013-08-25 08:01:41 +020051092013-08-25 Werner Lemberg <wl@gnu.org>
5110
Werner Lembergc1eb4452013-08-25 19:47:26 +02005111 [autofit] Make `cjk' module use blue stringsets.
5112
5113 * src/autofit/afcjk.c (AF_CJK_MAX_TEST_CHARACTERS): Removed.
5114 (af_cjk_hani_blue_chars): Removed.
5115 (AF_CJK_BLUE_TYPE_*): Removed.
5116 (af_cjk_metrics_init_blues): Replace AF_CJK_MAX_TEST_CHARACTERS with
5117 AF_BLUE_STRING_MAX_LEN.
5118 Change loops to use offsets (in file `afblue.h') into the new arrays
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005119 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
Werner Lembergc1eb4452013-08-25 19:47:26 +02005120 Instead of three dimensions (as used in the old blue string array)
5121 we now use properties to do the same, saving one loop nesting level.
5122
5123 * src/autofit/afcjk.h: Remove old enumeration values superseded by
5124 the new data in `afblue.h'.
5125 (AF_CJK_IS_TOP_BLUE, AF_CJK_IS_HORIZ_BLUE, AF_CJK_IS_FILLED_BLUE,
5126 AF_CJK_IS_RIGHT_BLUE): New macros, to be used in
5127 `af_cjk_metrics_init_blues'.
5128 (AF_CJK_BLUE_IS_RIGHT): Remove this now redundant enum value.
5129 (AF_CJK_BLUE_IS_TOP): Renamed to...
5130 (AF_CJK_BLUE_TOP): This.
5131 (AF_CJK_MAX_BLUES): Remove.
5132 (AF_CJKAxisRec): Updated.
5133
51342013-08-25 Werner Lemberg <wl@gnu.org>
5135
Werner Lemberg5c4a23a2013-08-25 19:29:07 +02005136 [autofit] Typo.
5137
5138 * src/autofit/afblue.hin, src/autofit/afblue.c (GET_UTF8_CHAR): Use
5139 cast.
5140
51412013-08-25 Werner Lemberg <wl@gnu.org>
5142
Werner Lemberg306f8c52013-08-25 13:07:08 +02005143 [autofit] Synchronize `cjk' with `latin' module (and vice versa).
5144
5145 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Add tracing
5146 messages.
5147 (af_cjk_metrics_init_blues): Don't pass blue string array as
5148 argument but use the global array directly.
5149 Use `outline' directly.
5150 Update and add tracing messages.
5151 (af_cjk_metrics_init): Simplify code.
5152 (af_cjk_metrics_scale_dim): Improve tracing message.
5153 (af_cjk_metrics_scale): Synchronize.
5154
5155 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
5156 af_latin_metrics_init_blues): Improve and add tracing messages.
5157
51582013-08-25 Werner Lemberg <wl@gnu.org>
5159
Werner Lemberg0975d682013-08-25 08:37:47 +02005160 [autofit] Make `latin' module use blue stringsets.
5161
5162 * src/autofit/aflatin.c (AF_LATIN_MAX_TEST_CHARACTERS): Removed.
5163 (af_latin_blue_chars): Removed.
5164 (af_latin_metrics_init_blues): Replace AF_LATIN_MAX_TEST_CHARACTERS
5165 with AF_BLUE_STRING_MAX_LEN.
5166 Change loops to use offsets (in file `afblue.h') into the new arrays
5167 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
5168 Use `AF_LATIN_IS_SMALL_TOP_BLUE' macro.
5169
5170 * src/autofit/aflatin.h: Remove old enumeration values superseded by
5171 the new data in `afblue.h'.
5172 (AF_LATIN_IS_TOP_BLUE): Updated definition.
5173 (AF_LATIN_IS_SMALL_TOP_BLUE): New macro.
5174 (AF_LATIN_MAX_BLUES): Remove.
5175 (AF_LatinAxisRec): Updated.
5176
51772013-08-25 Werner Lemberg <wl@gnu.org>
5178
Werner Lembergdb3e5b92013-08-25 08:23:22 +02005179 [autofit] Add blue stringsets.
5180
5181 * src/autofit/aftypes.h: Include `afblue.h'.
5182 (AF_ScriptClassRec): Add `blue_stringset' field.
5183 (AF_DEFINE_SCRIPT_CLASS): Updated.
5184
5185 * src/autofit/autofit.c: Include `afblue.c'.
5186
5187 * src/autofit/afcjk.c (af_hani_script_class), src/autofit/afdummy.c
5188 (af_dflt_script_class), src/autofit/afindic.c
5189 (af_deva_script_class), src/autofit/aflatin.c
5190 (af_latn_script_class), src/autofit/aflatin2.c
5191 (af_ltn2_script_class): Updated.
5192
5193 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afblue.c'.
5194
51952013-08-25 Werner Lemberg <wl@gnu.org>
5196
Werner Lemberg8b8be782013-08-25 08:01:41 +02005197 [autofit] Introduce data file for blue strings.
5198
5199 The idea is to have a central file which gets processed by a Perl
5200 script to create proper `.c' and `.h' files using templates. There
5201 are two other reasons to do that:
5202
5203 . The data file should be easily readable. We use UTF-8 encoding
5204 which then gets converted to single bytes.
5205
5206 . Since the number of supported scripts will increase soon, the
5207 current usage of blue string arrays is a waste of space. Using
5208 the Perl script it is possible to imitate jagged arrays,
5209 defining enumeration constants as offsets into the arrays.
5210
5211 This commit only adds files without changing any functionality.
5212
5213 * src/autofit/afblue.dat: New data file.
5214 * src/tools/afblue.pl: New Perl script for processing `afblue.dat'.
5215
5216 * src/autofit/afblue.cin, src/autofit/afblue.hin: New template files
5217 for...
5218 * src/autofit/afblue.c, src/autofit/afblue.c: New source files.
5219 To avoid a dependency on Perl, we add them too.
5220
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -040052212013-08-19 Alexei Podtelezhnikov <apodtele@gmail.com>
5222
Werner Lemberg71c0ad62013-08-27 21:30:09 +02005223 [base] Enable new algorithm for `BBox_Cubic_Check'.
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -04005224
Werner Lemberg71c0ad62013-08-27 21:30:09 +02005225 * src/base/ftbbox.c: Enable new BBox_Cubic_Check algorithm, remove
5226 the old one.
5227 Improve comments.
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -04005228
Werner Lemberg6bfa2632013-08-18 18:34:05 +020052292013-08-18 Werner Lemberg <wl@gnu.org>
5230
Werner Lemberg4af44442013-08-18 18:46:30 +02005231 * builds/unix/unix-def.in (freetype2.pc): Don't set executable bit.
5232
52332013-08-18 Werner Lemberg <wl@gnu.org>
5234
Werner Lemberg6bfa2632013-08-18 18:34:05 +02005235 Fix Savannah bug #39804.
5236
5237 * builds/unix/configure.raw (LIBPNG): Define and export.
5238 * builds/unix/freetype-config.in, builds/unix/freetype2.in: Handle
5239 libpng.
5240
Alexei Podtelezhnikov32a7d872013-08-17 22:19:21 -040052412013-08-17 Alexei Podtelezhnikov <apodtele@gmail.com>
5242
5243 [base] Clean up BBox_Conic_Check.
5244
5245 * src/base/ftbbox.c (BBox_Conic_Check): Remove redundant checks for
5246 extremum at the segment ends, which are already within the bbox.
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005247 Slightly modify calculations.
Alexei Podtelezhnikov32a7d872013-08-17 22:19:21 -04005248
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -040052492013-08-15 Alexei Podtelezhnikov <apodtele@gmail.com>
5250
5251 [base] Finish experimental (disabled) BBox_Cubic_Check implementation.
5252
5253 * src/base/ftbbox.c (BBox_Cubic_Check): Scale arguments to improve
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005254 accuracy and avoid overflows.
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -04005255
Alexei Podtelezhnikov61a65512013-08-13 22:28:57 -040052562013-08-13 Alexei Podtelezhnikov <apodtele@gmail.com>
5257
5258 [base] Refactor experimental (disabled) BBox_Cubic_Check.
5259
5260 * src/base/ftbbox.c (BBox_Cubic_Check): Implement the minimum search
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -04005261 as the mirror image of the maximum search implemented here...
5262 (update_max): New function.
Alexei Podtelezhnikov61a65512013-08-13 22:28:57 -04005263
John Tytgat9bcfab82013-08-06 08:55:19 +020052642013-08-06 John Tytgat <John.Tytgat@esko.com>
5265
5266 Fix Savannah bug #39702.
5267
5268 * src/cff/cffload.c (cff_index_get_pointers): Check for `cur_offset
5269 != 0'; this stronger test is mandated by the CFF specification.
5270 Fix test for INDEX structures which have one or more empty entries
5271 at the end.
5272
Werner Lembergcc25e3a2013-08-05 08:46:15 +020052732013-08-05 Werner Lemberg <wl@gnu.org>
5274
Werner Lemberga32682f2013-08-06 00:21:46 +02005275 Fix gcc pragmas, part 2.
5276
5277 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
5278 TT_DotFix14_long_long): `#pragma gcc diagnostic {push,pop}' has been
5279 introduced with gcc version 4.6.
5280
52812013-08-05 Werner Lemberg <wl@gnu.org>
5282
Werner Lemberg69e524d2013-08-05 23:38:32 +02005283 Fix gcc pragmas.
5284
5285 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
5286 TT_DotFix14_long_long): Older gcc versions don't accept diagnostic
5287 pragmas within a function body.
5288
52892013-08-05 Werner Lemberg <wl@gnu.org>
5290
Werner Lemberg9e6de362013-08-05 16:37:21 +02005291 Fix Savannah bug #39700.
5292
5293 * builds/unix/ftconfig.h: Synchronize with
5294 `include/freetype/config/ftconfig.h'.
5295
5296 * builds/vms/ftconfig.h: Ditto.
5297 Make the differences to the master `ftconfig.h' file as small as
5298 possible for easier maintainance.
5299
53002013-08-05 Werner Lemberg <wl@gnu.org>
5301
Werner Lembergcc25e3a2013-08-05 08:46:15 +02005302 [autofit] Improve handling of `near' points.
5303
5304 Points which are very near to each other are now marked as such.
5305 The `weak' flag is then computed by using the `in' vector of the
5306 first and the `out' vector of the last point of a group of near
5307 points.
5308
5309 For example, this fixes the rendering of glyph `Oslash' in
5310 `Roboto-Thin.ttf'.
5311
5312 * src/autofit/afhints.h (AF_Flags): New value `AF_FLAGS_NEAR'.
5313
5314 * src/autofit/afhints.c (af_glyph_hints_reload): Introduce
5315 the heuristic value `near_limit' to decide whether the current point
5316 is near to the previous one, then set `AF_FLAG_NEAR' accordingly.
5317 Store good `in' vector (of last non-near point) in
5318 `last_good_in_{x,y}' and use it as an argument to
5319 `ft_corner_is_flat' if necessary.
5320
Werner Lemberg74a9b672013-08-02 14:53:32 +020053212013-08-02 Werner Lemberg <wl@gnu.org>
5322
Werner Lemberg0d28a7d2013-08-02 22:59:43 +02005323 * include/freetype/ftcffdrv.h: Improve documentation.
5324 This is based on blog entries from David Lemon and Dave Arnold (both
5325 from Adobe) with kind permission. Dave also helped in
5326 proof-reading.
5327
53282013-08-02 Werner Lemberg <wl@gnu.org>
5329
Werner Lemberg456cc442013-08-02 20:25:21 +02005330 [autofit] Move declaration of scripts into separate file.
5331
5332 This has the benefit that we don't need to duplicate the data at
5333 different places.
5334
5335 * src/autofit/afscript.h: New file.
5336
5337 * src/autofit/aftypes.h (AF_Script): Include `afscript.h' to define
5338 the enumeration values.
5339
5340 * src/autofit/afglobal.c: Include `afscript.h' to get the script
5341 specific header files.
5342 (af_script_classes): Include `afscript.h' to fill this array.
5343
5344 * src/autofit/afpic.c: Include `afscript.h' to get the script
5345 specific header files.
5346 (autofit_module_class_pic_init): Include `afscript.h' for
5347 initialization.
5348 * src/autofit/afpic.h (AF_SCRIPT_CLASSES_COUNT,
5349 AF_SCRIPT_CLASSES_REC_COUNT): Removed. Use `AF_SCRIPT_MAX' instead.
5350
5351 * src/autofit/rules.mk (AUTOF_DRV_H): Updated.
5352
53532013-08-02 Werner Lemberg <wl@gnu.org>
5354
Werner Lemberg773601d2013-08-02 19:51:17 +02005355 [autofit] Move declaration of writing systems into separate file.
5356
5357 This has the benefit that we don't need to duplicate the data at
5358 different places.
5359
5360 * src/autofit/afwrtsys.h: New file.
5361
5362 * src/autofit/aftypes.h (AF_WritingSystem): Include `afwrtsys.h' to
5363 define the enumeration values.
5364
5365 * src/autofit/afglobal.c: Include `afwrtsys.h' to get the writing
5366 system specific header files.
5367 Include `afpic.h'.
5368 (af_writing_system_classes): Include `afwrtsys.h' to fill this
5369 array.
5370
5371 * src/autofit/afpic.c: Include `afwrtsys.h' to get the writing
5372 system specific header files.
5373 (autofit_module_class_pic_init): Include `afwrtsys.h' for
5374 initialization.
5375 * src/autofit/afpic.h (AF_WRITING_SYSTEM_CLASSES_COUNT,
5376 AF_WRITING_SYSTEM_CLASSES_REC_COUNT): Removed. Use
5377 `AF_WRITING_SYSTEM_MAX' instead.
5378
53792013-08-02 Werner Lemberg <wl@gnu.org>
5380
Werner Lemberg74a9b672013-08-02 14:53:32 +02005381 [sfnt] Fix compilation with g++.
5382
5383 * src/sfnt/pngshim.c (error_callback, read_data_from_FT_stream): Use
5384 cast.
5385 (Load_SBit_Png): Pacify compiler.
5386
Werner Lemberg89a529f2013-08-02 14:50:23 +020053872013-08-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5388 Werner Lemberg <wl@gnu.org>
5389
5390 [autofit] Fix `make multi'.
5391
5392 * include/freetype/config/ftconfig.h (FT_LOCAL_ARRAY,
5393 FT_LOCAL_ARRAY_DEF): New macros.
5394
5395 * src/autofit/afglobal.c (af_writing_system_classes,
5396 af_script_classes): Use FT_LOCAL_ARRAY_DEF.
5397 * src/autofit/afglobal.h: Declare `af_writing_system_classes' and
5398 `af_script_classes'.
5399 * src/autofit/afloader.c: Include `afpic.h'.
5400
Werner Lemberge8ed2d62013-08-01 12:20:20 +020054012013-08-01 Werner Lemberg <wl@gnu.org>
5402
5403 Another round of cppcheck nitpicks.
5404
5405 The call was (from the top-level of the FreeType tree):
5406
5407 cppcheck --force \
5408 --enable=all \
5409 -I /usr/include \
5410 -I /usr/local/include \
5411 -I /usr/lib/gcc/i586-suse-linux/4.7/include \
5412 -I include \
5413 -I include/freetype \
5414 -I include/freetype/config \
5415 -I include/freetype/internal \
5416 -DFT2_BUILD_LIBRARY \
5417 . &> cppcheck.log
5418
5419 using cppcheck git commit f7e93f99.
5420
5421 Note that cppcheck still can't handle `#include FOO' (with `FOO' a
5422 macro).
5423
5424 */* Improve variable scopes.
5425 */* Remove redundant initializations which get overwritten.
5426
5427 * src/gxvalid/*: Comment out redundant code or guard it with
5428 FT_DEBUG_LEVEL_TRACE.
5429
Werner Lemberg5d6a3602013-07-30 23:17:04 +020054302013-07-30 Werner Lemberg <wl@gnu.org>
5431
Werner Lemberg72f5ff52013-07-31 22:49:29 +02005432 [autofit] Introduce `writing systems'.
5433
5434 This patch adds a new top level to the auto-hinter's script class
5435 hierarchy. It defines `writing systems' which can contain multiple
5436 scripts.
5437
5438 For example, the `latin' writing system (in file `aflatin.c') is
5439 able to support scripts like Latin, Cyrillic, Armenian, etc., which
5440 can be handled similarly.
5441
5442 Scripts are now named using four-letter OpenType tags.
5443
5444 * src/autofit/aftypes.h (AF_ScriptClassRec): Move relevant members
5445 to...
5446 (AF_WritingSystemClassRec): This new structure. It holds pointers
5447 to functions which can be shared among related scripts.
5448 (AF_WritingSystem): New enumeration.
5449 (AF_Script): Revised values using four-letter tags.
5450 (AF_DEFINE_WRITING_SYSTEM_CLASS): New macro.
5451 (AF_DEFINE_SCRIPT_CLASS): Updated.
5452
5453 * src/autofit/afglobal.c (af_writing_system_classes): New global,
5454 constant array.
5455 (af_script_classes): Updated.
5456 (af_face_globals_free): Updated.
5457 Remove assertion.
5458 (af_face_globals_get_metrics): Updated.
5459
5460 * src/autofit/afglobal.h (AF_SCRIPT_FALLBACK)
5461 [!AF_CONFIG_OPTION_CJK]: Handle this case.
5462
5463 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
5464 Updated.
5465
5466 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated;
5467 initialize structures for both writing systems and scripts.
5468 * src/autofit/afpic.h: Updated.
5469 (AF_WRITING_SYSTEM_CLASSES_GET): New macro.
5470
5471 * src/autofit/afcjk.c (af_cjk_writing_system_class): New writing
5472 system.
5473 (af_cjk_uniranges): Renamed to...
5474 (af_hani_uniranges): This.
5475 (af_cjk_script_class): Reduced and renamed to...
5476 (af_hani_script_class): This.
5477 * src/autofit/afcjk.h: Updated.
5478
5479 * src/autofit/afdummy.c (af_dummy_writing_system_class): New writing
5480 system.
5481 (af_dummy_script_class): Reduced and renamed to...
5482 (af_dflt_script_class): This.
5483 * src/autofit/afdummy.h: Updated.
5484
5485 * src/autofit/afindic.c (af_indic_writing_system_class): New writing
5486 system.
5487 (af_indic_uniranges): Renamed to...
5488 (af_deva_uniranges): This.
5489 (af_indic_script_class): Reduced and renamed to...
5490 (af_deva_script_class): This.
5491 * src/autofit/afcjk.h: Updated.
5492
5493 * src/autofit/aflatin.c (af_latin_writing_system_class): New writing
5494 system.
5495 (af_latin_uniranges): Renamed to...
5496 (af_latn_uniranges): This.
5497 (af_latin_script_class): Reduced and renamed to...
5498 (af_latn_script_class): This.
5499 * src/autofit/aflatin.h: Updated.
5500
5501 * src/autofit/aflatin2.c (af_latin2_writing_system_class): New
5502 writing system.
5503 (af_latin2_uniranges): Renamed to...
5504 (af_ltn2_uniranges): This.
5505 Synchronize ranges with `latin'.
5506 (af_latin2_script_class): Reduced and renamed to...
5507 (af_ltn2_script_class): This.
5508 * src/autofit/aflatin2.h: Updated.
5509
55102013-07-30 Werner Lemberg <wl@gnu.org>
5511
Werner Lemberg5d6a3602013-07-30 23:17:04 +02005512 [autofit] Variable renaming.
5513
5514 * src/autofit/aftypes.h (AF_ScriptMetricsRec):
5515 s/clazz/script_class/.
5516 Update all users.
5517
suzuki toshiya2b29ed62013-07-30 13:55:29 +090055182013-07-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5519
5520 Ignore libpng-config under cross-building configuration,
5521 because it will return the flags for the hosting environment.
5522
5523 * builds/unix/configure.raw: Ignore libpng-config when
5524 `cross_compiling' == yes.
5525
suzuki toshiyaf2e7f1e2013-07-30 13:32:57 +090055262013-07-30 Behdad Esfahbod <behdad@google.com>
5527
5528 Prevent division by zero by a transparent color.
5529
5530 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra):
5531 Return 0 immediately, when alpha channel is zero.
5532
Behdad Esfahbod21c32b02013-07-25 21:53:18 +020055332013-07-25 Behdad Esfahbod <behdad@google.com>
5534
5535 Add FT_FACE_FLAG_COLOR and FT_HAS_COLOR.
5536
5537 Also disambiguate Google's color bitmap tables.
5538
5539 * include/freetype/freetype.h (FT_FACE_FLAG_COLOR, FT_HAS_COLOR):
5540 New macros.
5541
5542 * include/freetype/internal/tttypes.h (TT_SbitTableType): Add
5543 TT_SBIT_TABLE_TYPE_CBLC.
5544
5545 * src/sfnt/sfobjs.c (sfnt_load_face): Handle FT_FACE_FLAG_COLOR.
5546
5547 * src/sfnt/ttsbit.c (tt_face_load_sbit,
5548 tt_face_load_strike_metrics, tt_face_load_sbit_image): Handle
5549 TT_SBIT_TABLE_TYPE_CBLC.
5550
suzuki toshiyab4725cb2013-07-24 14:25:39 +090055512013-07-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5552
5553 [sfnt] Fix for `make multi' target.
5554
5555 * src/sfnt/pngshim.c (Load_SBit_Png): Use FT_LOCAL_DEF().
5556
Werner Lemberg6a7df622013-07-20 10:48:37 +020055572013-07-20 Werner Lemberg <wl@gnu.org>
5558
5559 * docs/INSTALL.GNU: Updated.
5560
Behdad Esfahbodff269522013-07-20 08:02:39 +020055612013-07-20 Behdad Esfahbod <behdad@google.com>
5562
5563 [sfnt] Fix `sbix' table version handling.
5564
5565 * src/sfnt/ttsbit.c (tt_face_load_sbit) [TT_SBIT_TABLE_TYPE_SBIX]:
5566 USHORT version numbers are to be considered as `minor'.
5567
Werner Lemberg05c14212013-07-19 23:11:23 +020055682013-07-19 Werner Lemberg <wl@gnu.org>
5569
5570 [autofit] Fix segment classification for blue zones.
5571
5572 The old code (essentially unchanged since the very beginning)
5573 incorrectly handled this configuration
5574
5575 x -o- x
5576 / \
5577 / \
5578 / \
5579 o o
5580
5581 as flat and this
5582
5583 o o
5584 / /
5585 x| x|
5586 | |
5587 o---------------o
5588
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005589 as round. (`o' and `x' are on and off points, respectively).
Werner Lemberg05c14212013-07-19 23:11:23 +02005590
5591 This is a major change which should improve the rendering results
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005592 enormously for many TrueType fonts, especially in the range approx.
Werner Lemberg05c14212013-07-19 23:11:23 +02005593 20-40ppem, fixing the appearance of many overshoots.
5594
5595 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Look at the
5596 first and last points of the segment, not the points right before
5597 and after.
5598
55992013-07-19 Behdad Esfahbod <behdad@google.com>
Werner Lemberg01705392013-07-18 13:13:12 +02005600
Behdad Esfahbod778a7e62013-07-19 14:28:28 +02005601 [sfnt] `sbix' fix-ups.
5602
5603 * src/sfnt/sfobjs.c (sfnt_load_face): Apple's `sbix' color bitmaps
5604 are rendered scaled and then the `glyf' outline rendered on top. We
5605 don't support that yet, so just ignore the `glyf' outline and
5606 advertise it as a bitmap-only font.
5607
5608 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
5609 [TT_SBIT_TABLE_TYPE_SBIX]: Return metrics in 26.6 units.
5610 (tt_face_load_sbix_image): Typo.
5611
56122013-07-18 Behdad Esfahbod <behdad@google.com>
5613
Werner Lemberg01705392013-07-18 13:13:12 +02005614 [sfnt] Add support for Apple's `sbix' color bitmap table.
5615
5616 * include/freetype/internal/tttypes.h (TT_SBit_MetricsRec): Widen
5617 fields to FT_Short and FT_UShort, respectively.
5618 (TT_SBitTableType): New enumeration.
5619 (TT_FaceRec): Add `sbit_table_type' field.
5620
5621 * include/freetype/tttags.h (TTAG_sbix): New macro.
5622
5623 * src/sfnt/pngshim.c (Load_SBit_Png): Pass a more generic
5624 FT_GlyphSlot argument instead FT_Bitmap.
5625 Add flag to control map and metrics handling.
5626 Update all users.
5627
5628 * src/sfnt/ttsbit.c: Include `ttmtx.h'.
5629 (tt_face_load_eblc): Renamed to...
5630 (tt_face_load_sbit): This.
5631 Handlic `sbix' bitmaps.
5632 (tt_face_free_eblc): Renamed to...
5633 (tt_face_load_sbit): This.
5634 Updated.
5635 (tt_face_load_strike_metrics): Handle `sbix' bitmaps.
5636 (tt_face_load_sbix_image): New function.
5637 (tt_sbit_decoder_alloc_bitmap, tt_sbit_decoder_load_image,
5638 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
5639 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
5640 tt_sbit_decoder_load_image, tt_sbit_decoder_load_bitmap): Don't pass
5641 and handle load flags.
5642 (tt_sbit_decoder_load_bitmap) [!FT_CONFIG_OPTION_USE_PNG]: Better
5643 handle formats 17-19.
5644 Move color to grayscale conversion to...
5645 (tt_face_load_sbit_image): Here.
5646 Handle `sbix' bitmaps.
5647
5648 * src/sfnt/pngshim.h: Updated.
5649 * src/sfnt/ttsbit.h: Updated.
5650 * src/sfnt/sfdriver.c: Updated.
5651
Werner Lemberg274207e2013-07-18 12:38:57 +020056522013-07-18 Werner Lemberg <wl@gnu.org>
5653
5654 [sfnt] Ignore invalid magic number in `head' or `bhed'.
5655
5656 Other font engines seem to ignore it also. Problem reported by
5657 Hin-Tak Leung <htl10@users.sourceforge.net>.
5658
5659 * src/sfnt/ttload.c (check_table_dir): Don't abort but warn only if
5660 we have an invalid magic number.
5661
Werner Lemberg9a7951d2013-07-16 15:25:24 +020056622013-07-16 Werner Lemberg <wl@gnu.org>
5663
5664 [smooth] Fix segfault caused by previous commit.
5665
5666 * src/smooth/ftgrays.c (gray_set_cell): Always compute
5667 `ras.invalid'.
5668
David Turnera5f33ee2013-07-16 12:40:03 +020056692013-07-16 David Turner <digit@google.com>
5670
David Turner89929ec2013-07-16 13:36:07 +02005671 [smooth] Improve performance.
5672
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005673 Provide a work-around for an ARM-specific performance bug in GCC.
David Turner89929ec2013-07-16 13:36:07 +02005674 This speeds up the rasterizer by more than 5%.
5675
5676 Also slightly optimize `set_gray_cell' and `gray_record_cell' (which
5677 also improves performance on other platforms by a tiny bit (<1%).
5678
5679 * src/smooth/ftgrays.c (FT_DIV_MOD): New macro.
5680 Use it where appropriate.
5681
5682 (gray_record_cell, gray_set_cell, gray_move_to,
5683 gray_convert_glyph_inner): Streamline condition handling.
5684
56852013-07-16 David Turner <digit@google.com>
5686
David Turnerf66d48e2013-07-16 13:18:00 +02005687 [truetype] Add assembler code for TT_MulFix14 and TT_DotFix14.
5688
5689 This patch provides slightly optimized versions for ARM, x86, and
5690 x86_64 CPUs if built with GCC.
5691
5692 Also remove some dead code.
5693
5694 * src/truetype/ttinterp.c (TT_MulFix14_arm, TT_MulFix14_long_long,
5695 TT_DotFix14_long_long): New functions.
5696
56972013-07-16 David Turner <digit@google.com>
5698
David Turnerb2890882013-07-16 12:52:18 +02005699 Optimize FT_MulFix for x86_64 GCC builds.
5700
5701 This patch provides an optimized `FT_MulFix' implementation for
5702 x86_64 machines when FreeType is built with GCC, or compatible
5703 compilers like Clang.
5704
5705 Example:
5706 bin/ftbench -p -t 5 -s 14 -f 0008 Arial.ttf
5707
5708 Before:
5709
5710 Load 4.863 us/op
5711 Load_Advances (Normal) 4.816 us/op
5712 Load_Advances (Fast) 0.028 us/op
5713 Render 2.753 us/op
5714 Get_Glyph 0.463 us/op
5715 Get_CBox 0.077 us/op
5716 Get_Char_Index 0.023 us/op
5717 Iterate CMap 13.898 us/op
5718 New_Face 12.368 us/op
5719 Embolden 0.028 us/op
5720 Get_BBox 0.302 us/op
5721
5722 After:
5723
5724 Load 4.617 us/op
5725 Load_Advances (Normal) 4.645 us/op
5726 Load_Advances (Fast) 0.027 us/op
5727 Render 2.789 us/op
5728 Get_Glyph 0.460 us/op
5729 Get_CBox 0.077 us/op
5730 Get_Char_Index 0.024 us/op
5731 Iterate CMap 13.403 us/op
5732 New_Face 12.278 us/op
5733 Embolden 0.028 us/op
5734 Get_BBox 0.301 us/op
5735
5736 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
5737 (FT_MulFix_x86_64): New function.
5738
57392013-07-16 David Turner <digit@google.com>
5740
David Turnera5f33ee2013-07-16 12:40:03 +02005741 Speed up ARMv7 support.
5742
5743 When building for ARMv7 with thumb2 instructions, the optimized
5744 `FT_MulFix_arm' assembly routine was not being used.
5745
5746 The reason for this is in the `ftconfig.h' header, namely:
5747
5748 - The assembly routine uses the `smull' instruction which is not
5749 available when generating Thumb-1 machine code. It is available
5750 in Thumb-2 mode, though.
5751
5752 - The header was written a long time ago before Thumb-2 became
5753 widely popular (e.g. with Android). So it simply doesn't use the
5754 assembly routine if the `__thumb__' built-in macro is defined.
5755
5756 - When compiling in Thumb-2 mode, the compiler will define both
5757 `__thumb__' and `__thumb2__'.
5758
5759 By checking for `(__thumb2__ || !__thumb__)', we ensure that the
5760 assembly routine is only avoided when generating Thumb-1 code.
5761
5762 Given that this is performance-sensitive function, this improves
5763 `ftbench' as follows on a Galaxy Nexus:
5764
5765 Before (us/op) After (us/op)
5766
5767 - loading Arial.ttf glyphs at 14 ppem [1]
5768
5769 Load 34.285 33.098
5770
5771 - same operation with the light auto-hinter [2]
5772
5773 Load 31.317 29.590
5774
5775 - same operation without hinting [3]
5776
5777 Load 6.143 5.376
5778
5779 - loading Arial.ttf advances at 14 ppem [4]
5780
5781 Load_Advances (normal) 34.216 33.016
5782 Load_Advances (fast) 0.176 0.176
5783
5784 [1] ftbench -t 5 -p -s 14 -b a -f 0008 Arial.ttf
5785 [2] ftbench -t 5 -p -s 14 -b a -r 1 -f 0028 Arial.ttf
5786 [3] ftbench -t 5 -p -s 14 -b a -f 000a Arial.ttf
5787 [4] ftbench -t 5 -p -s 14 -b b -f 0008 Arial.ttf
5788
5789 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
5790 (FT_MULFIX_ASSEMBLER): Fix handling for ARMv7.
5791
Werner Lemberge12fc772013-06-28 07:57:32 +020057922013-06-28 Werner Lemberg <wl@gnu.org>
5793
5794 * docs/CHANGES: Updated.
5795
Werner Lemberg680c1d42013-06-27 17:21:59 +020057962013-06-27 Werner Lemberg <wl@gnu.org>
5797
5798 * src/winfonts/winfnt.c (FNT_Load_Glyph): Fix bitmap width guard.
5799
Werner Lembergc7cc9eb2013-06-25 07:24:02 +020058002013-06-25 Werner Lemberg <wl@gnu.org>
5801
Werner Lembergb8850fc2013-06-26 12:22:10 +02005802 [cff] Add darkening limit to `darkening-parameters'.
5803
5804 * src/cff/cffdrivr.c (cff_property_set): Add check.
5805
58062013-06-25 Werner Lemberg <wl@gnu.org>
5807
Werner Lemberg89ca1fd2013-06-25 23:28:02 +02005808 [cff] Add `darkening-parameters' property.
5809
5810 * include/freetype/ftcffdrv.h: Document it.
5811
5812 * src/cff/cffdrivr.c (cff_property_set, cff_property_get): Handle
5813 `darkening-parameters' property.
5814
5815 * src/cff/cf2font.h (CF2_FontRec): Add `darkenParams' array.
5816
5817 * src/cff/cf2font.c (cf2_computeDarkening): Add `darkenParams'
5818 argument and use it.
5819 Update all callers.
5820
5821 * src/cff/cf2ft.c (cf2_decoder_parse_charstrings): Copy
5822 `darken_params' values.
5823
5824 * src/cff/cffobjs.h (CFF_DriverRec): Add `darken_params' array.
5825
5826 * src/cff/cffobjs.c (cff_driver_init): Set default values for
5827 `darken_params'.
5828
58292013-06-25 Werner Lemberg <wl@gnu.org>
5830
Werner Lembergfad93262013-06-25 10:41:37 +02005831 [docmaker] Code shuffling.
5832
5833 * src/tools/docmaker/tohtml.py (re_url): Move regexp...
5834 * src/tools/docmaker/sources.py: ... to this file.
5835
58362013-06-25 Werner Lemberg <wl@gnu.org>
5837
Werner Lemberg8bdc4072013-06-25 10:20:53 +02005838 [docmaker] Remove unused functions.
5839
5840 * src/tools/docmaker/content.py (DocMarkup.get_start,
5841 DocBlock.get_markup_name): Removed.
5842 * src/tools/docmaker/tohtml.py (html_quote0, dump_html_code,
5843 HtmlFormatter.make_html_words): Removed.
5844
58452013-06-25 Werner Lemberg <wl@gnu.org>
5846
Werner Lembergffb8b472013-06-25 09:09:30 +02005847 * builds/freetype.mk (dll): Remove target.
5848
5849 Problem reported by Jörg Günnewig <joerg.guennewig@googlemail.com>.
5850
58512013-06-25 Werner Lemberg <wl@gnu.org>
5852
Werner Lembergc7cc9eb2013-06-25 07:24:02 +02005853 [docmaker] Recognise URLs.
5854
5855 * src/tools/docmaker/tohtml.py (re_url): New regular expression.
5856 (make_html_para): Use it.
5857
Werner Lemberg25b7da52013-06-19 10:23:36 +020058582013-06-19 Werner Lemberg <wl@gnu.org>
5859
Werner Lembergfe4f5712013-06-19 23:27:47 +02005860 * Version 2.5.0.1 released.
5861 ===========================
5862
5863
5864 Tag sources with `VER-2-5-0-1'.
5865
5866 * include/freetype/config/ftoption.h: Undefine
5867 CFF_CONFIG_OPTION_OLD_ENGINE.
5868 * devel/ftoption.h: Define CFF_CONFIG_OPTION_OLD_ENGINE.
5869
58702013-06-19 Werner Lemberg <wl@gnu.org>
5871
Werner Lemberg609f0ca2013-06-19 14:41:47 +02005872 * builds/unix/install.mk (install): Don't create `cache' directory.
5873
5874 Found by Peter Breitenlohner <peb@mppmu.mpg.de>.
5875
58762013-06-19 Werner Lemberg <wl@gnu.org>
5877
Werner Lemberg25b7da52013-06-19 10:23:36 +02005878 * Version 2.5.0 released.
5879 =========================
5880
5881
5882 Tag sources with `VER-2-5-0'.
5883
5884 * docs/VERSION.DLL: Update documentation and bump version number to
5885 2.5.0.
5886
5887 * README, Jamfile (RefDoc),
5888 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5889 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5890 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
5891 builds/win32/visualc/freetype.dsp,
5892 builds/win32/visualc/freetype.vcproj,
5893 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5894 builds/win32/visualce/freetype.vcproj,
5895 builds/win32/visualce/index.html,
5896 builds/wince/vc2005-ce/freetype.vcproj,
5897 builds/wince/vc2005-ce/index.html,
5898 builds/wince/vc2008-ce/freetype.vcproj,
5899 builds/wince/vc2008-ce/index.html: s/2.4.12/2.5.0/, s/2412/250/.
5900
5901 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 5.
5902 (FREETYPE_PATCH): Set to 0.
5903
5904 * builds/unix/configure.raw (version_info): Set to 16:2:10.
5905
5906 * src/base/ftobjs.c (FT_Open_Face): Pacify compiler.
5907 * src/truetype/ttinterp.c (Ins_MSIRP, Ins_MIRP): Ditto.
5908
Werner Lembergf56691a2013-06-18 10:17:48 +020059092013-06-18 Werner Lemberg <wl@gnu.org>
5910
5911 Fix Savannah bug #39269.
5912
5913 * src/base/ftgloadr.c (FT_GlyphLoader_CheckPoints): Free memory in
5914 case of reacollocation failures.
5915
Andrew Church67cf7a82013-06-18 09:35:34 +020059162013-06-18 Andrew Church <achurch+savannah@achurch.org>
5917
5918 Fix Savannah bug #39266.
5919
5920 If memory allocations fail at certain points while opening a font,
5921 FreeType can either crash due to a NULL dereference or leak memory.
5922
5923 * include/freetype/internal/ftobjs.c (FT_Face_InternalRec,
5924 FT_LibraryRec): Make `refcount' a signed integer. If, for example,
5925 FT_Open_Face() fails in a memory allocation before the face's
5926 reference count is set to 1, a subsequent `FT_Done_Library' call
5927 would otherwise loop over `FT_Done_Face' 2^32 times before freeing
5928 the face.
5929
5930 * src/base/ftobjs.c (open_face): Initialize `stream' and friends
5931 earlier.
5932 (FT_Open_Face) <Fail>: Behave correctly if `node' is NULL.
5933 (FT_Destroy_Module) <Fail>: Check that `renderer_clazz' is valid.
5934
59352013-06-14 Werner Lemberg <wl@gnu.org>
Werner Lembergd7e34442013-06-14 18:33:39 +02005936
5937 * src/smooth/ftgrays.c One final pragma to silence 64-bit MSVC.
5938
Dave Arnoldcb23a622013-06-13 07:46:32 +020059392013-06-06 Dave Arnold <darnold@adobe.com>
5940 Werner Lemberg <wl@gnu.org>
5941
5942 [cff] Add code to Adobe's engine to handle ppem > 2000.
5943
5944 * src/cff/cffgload.c (cff_slot_load): If we get
5945 FT_Err_Glyph_Too_Big, retry unhinted and scale up later on.
5946
Andrew Church67cf7a82013-06-18 09:35:34 +020059472013-06-12 Werner Lemberg <wl@gnu.org>
Werner Lemberg25b6e602013-06-12 11:06:34 +02005948
Werner Lemberg294ce112013-06-12 23:33:11 +02005949 Another try on pragmas.
5950
5951 * include/freetype/internal/ftdebug.h: Move pragmas to...
5952 * include/freetype/internal/internal.h: ... this file since it gets
5953 included by all source files.
5954 * include/freetype/internal/ftserv.h: Remove pragma which has no
5955 effect.
5956
Dave Arnoldcb23a622013-06-13 07:46:32 +020059572013-06-12 Werner Lemberg <wl@gnu.org>
Werner Lemberg294ce112013-06-12 23:33:11 +02005958
Werner Lemberg25b6e602013-06-12 11:06:34 +02005959 * include/freetype/internal/ftdebug.h: Disable MSVC warning C4127.
5960
5961 This partially undoes commit 3f6e0e0c.
5962
Werner Lembergc06889e2013-06-12 10:58:06 +020059632013-06-12 Werner Lemberg <wl@gnu.org>
5964
5965 More compiler warning fixes.
5966
5967 */*: Use cast to `FT_Bool' (or `Bool') where appropriate.
5968
Werner Lemberg99e60d82013-06-10 01:44:37 +020059692013-06-10 Werner Lemberg <wl@gnu.org>
5970
Werner Lemberg5e094c62013-06-10 14:59:21 +02005971 [truetype] Improve handling of broken sbit advance widths.
5972
5973 * src/truetype/ttgload.c (TT_Load_Glyph): Use the glyph's (scaled)
5974 `linearHoriAdvance' if the sbit's `horiAdvance' value is zero.
5975
5976 Cf. font `Fixedsys Excelsior' v3.01 (FSEX300.ttf), glyph A, 16ppem.
5977
59782013-06-10 Werner Lemberg <wl@gnu.org>
5979
Werner Lemberga25ecfd2013-06-10 12:57:16 +02005980 [sfnt] Improve embedded bitmap tracing.
5981
5982 * src/base/ftobjs.c (FT_Request_Size): Move trace message regarding
5983 bitmap strike match to...
5984 (FT_Match_Size): This function.
5985
5986 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics,
5987 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
5988 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
5989 tt_sbit_decoder_load_image): Decorate with tracing messages.
5990
59912013-06-10 Werner Lemberg <wl@gnu.org>
5992
Werner Lemberg99e60d82013-06-10 01:44:37 +02005993 Fix Savannah bug #39160.
5994
5995 * src/truetype/ttinterp.c (Ins_SDPVTL): Set projection vector too
5996 for the degenerate case.
5997
Werner Lemberg2ba871b2013-06-09 08:20:54 +020059982013-06-09 David Turner <digit@google.com>
5999
6000 * src/cache/ftcmanag.c (FTC_Manager_Reset): Add missing cache flush.
6001
6002 This code, present since eight(!) years in the unused `CACHE'
6003 branch, has been forgotten to apply to the master branch. It's
6004 really amazing that noone has ever complained since
6005 `FTC_Manager_Reset' is pretty useless without flushing the cache.
6006
Werner Lemberg85fd84b2013-06-07 17:10:21 +020060072013-06-07 Werner Lemberg <wl@gnu.org>
6008
Werner Lemberg3f6e0e02013-06-07 18:10:40 +02006009 Add and improve pragmas for MSVC compiler.
6010
6011 * include/freetype/internal/ftdebug.h: Remove pragmas.
6012 * include/freetype/internal/ftserv.h: Use push and pop for pragmas.
6013 * include/freetype/internal/ftvalid.h: Handle warning C4324.
6014 * src/base/ftobjs.c: Use push and pop for pragmas.
6015 * src/gzip/ftgzip.c: Handle warning C4244.
6016
60172013-06-07 Werner Lemberg <wl@gnu.org>
6018
Werner Lemberg85fd84b2013-06-07 17:10:21 +02006019 [cff] s/cf2_getGlyphWidth/cf2_getGlyphOutline/.
6020
6021 * src/cff/cf2font.c, src/cff/cf2font.h, src/cff/cf2ft.c: Do it.
6022
Werner Lemberg4447b2c2013-06-06 21:28:36 +020060232013-06-06 Dave Arnold <darnold@adobe.com>
6024
6025 [cff] Add early exit feature for width-only calls.
6026
6027 This is for `FT_Get_Advance'.
6028
6029 There are 7 places where the spec says the width can be defined:
6030
6031 hstem/hstemhm
6032 vstem/vstemhm
6033 cntrmask/hintmask
6034 hmoveto
6035 vmoveto
6036 rmoveto
6037 endchar
6038
6039 * src/cff/cf2intrp.c (cf2_doStems): Exit early for width-only calls,
6040 if possible.
6041
6042 (cf2_interpT2CharString) <cf2_cmdHSTEM>, <cf2_cmdVSTEM>,
6043 <cf2_cmdVMOVETO>, <cf2_cmdENDCHAR>, <cf2_cmdHINTMASK>,
6044 <cf2_cmdRMOVETO>, <cf2_cmdHMOVETO>: Exit early for width-only calls.
6045
Werner Lembergbadf3172013-06-06 09:16:38 +020060462013-06-06 Werner Lemberg <wl@gnu.org>
6047
6048 Next round of compiler fixes.
6049
6050 * builds/win32/ftdebug.c, builds/wince/ftdebug.c (ft_debug_init):
6051 Add proper cast.
6052
6053 * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Fix
6054 cast.
6055 * include/freetype/internal/ftstream.h: Decorate stream and frame
6056 macros with `FT_Long' and `FT_ULong' as appropriate.
6057
6058 * src/base/ftrfork.c (raccess_guess_darwin_hfsplus,
6059 raccess_guess_darwin_newvfs): Use cast.
6060
6061 * src/bdf/bdflib.c (_bdf_set_default_spacing): Use cast.
6062
6063 * src/cache/ftcmanag.c (FTC_Manager_Check): Fix cast.
6064 * src/cache/ftcmanag.h (FTC_ManagerRec): Ditto.
6065
6066 * src/cff/cf2arrst.c (cf2_arrstack_setNum_Elements): Use cast.
6067 * src/cff/cf2ft.c (cf2_freeSeacComponent): Ditto.
6068 * src/cff/cffobjs.c (remove_subset_prefix, remove_style): Ditto.
6069
6070 * src/cid/cidparse.c (cid_parser_new): Use cast.
6071
6072 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Use cast.
6073
6074 * src/psaux/psobjs.c (reallocate_t1_table): Fix argument type.
6075
6076 * src/raster/ftraster.c (ft_black_reset): Use cast.
6077
6078 * src/truetype/ttgxvar.c (FT_Stream_FTell): Use cast.
6079 (ALL_POINTS): Fix cast.
6080
6081 * src/type1/t1driver.c (t1_ps_get_font_value): Add casts.
6082 * src/type1/t1parse.c (T1_Get_Private_Dict): Add cast.
6083
Dave Arnoldc3782492013-06-05 19:57:55 +020060842013-06-05 Dave Arnold <darnold@adobe.com>
6085
6086 Fix more MSVC Win32 compiler warnings.
6087
6088 * src/base/ftobjs.c: Fix typo in MS pragma.
6089
6090 * src/base/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
6091 `lineno' is only used in debug mode.
6092
6093 * src/cff/cf2ft.c (cf2_builder_moveTo): `params' is only used in
6094 debug mode.
6095
Werner Lemberg45392b72013-06-05 13:43:20 +020060962013-06-05 Werner Lemberg <wl@gnu.org>
6097
6098 Fix compiler warnings.
6099
6100 * include/freetype/internal/ftmemory.h: Decorate memory allocation
6101 macros with `FT_Long' where appropriate.
6102 Remove duplicate of FT_MEM_QRENEW_ARRAY definition.
6103
6104 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
6105 cast.
6106
6107 * src/base/ftobjs.c: Add warning disabling pragma for MSVC while
6108 including `md5.c'.
6109
6110 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdESC>: Add
6111 cast.
6112
6113 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_compound): Fix casts.
6114 (tt_sbit_decoder_load_bitmap): Beautification.
6115
6116 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Initialize
6117 variables (earlier).
6118
6119 * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Pacify compiler.
6120
6121 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Use unsigned constants
6122 where appropriate.
6123
6124 * src/type1/t1load.c (T1_Get_MM_Var): Ditto.
6125
Werner Lembergdc624ca2013-06-04 10:30:48 +020061262013-06-04 Werner Lemberg <wl@gnu.org>
6127
Werner Lembergd9634982013-06-04 20:18:57 +02006128 * src/cff/cf2font.c (cf2_getGlyphWidth): Initialize `advWidth'.
6129
6130 Problem reported by Ingmar Sittl <ingmar.sittl@elektrobit.com>.
6131
61322013-06-04 Werner Lemberg <wl@gnu.org>
6133
Werner Lembergdc624ca2013-06-04 10:30:48 +02006134 Apply fixes for cppcheck nitpicks.
6135
6136 http://cppcheck.sourceforge.net/
6137
Werner Lemberg8d8508e2013-06-04 13:09:01 +02006138 The call was (from the top-level of the FreeType tree):
6139
6140 cppcheck --force \
6141 --enable=all \
6142 -I include \
6143 -I include/freetype/ \
6144 -I include/freetype/config/ \
6145 -I include/freetype/internal/ \
6146 . &> cppcheck.log
6147
Werner Lembergdc624ca2013-06-04 10:30:48 +02006148 Note that the current version heavily chokes on FreeType, delivering
Werner Lemberg8d8508e2013-06-04 13:09:01 +02006149 many wrong results. I will report those issues to the cppcheck team
Werner Lembergdc624ca2013-06-04 10:30:48 +02006150 so that a newer version gives improved results hopefully.
6151
6152 */* Improve variable scopes.
6153 */* Remove redundant initializations which get overwritten.
6154
Werner Lemberge8ed2d62013-08-01 12:20:20 +02006155 * src/base/ftmac.c, builds/mac/ftmac.c (count_faces_scalable):
Werner Lembergdc624ca2013-06-04 10:30:48 +02006156 Remove unused variable.
6157
6158 * src/base/ftdbgmem.c (ft_mem_table_destroy): `table' can't be zero.
6159
6160 * src/gxvalid/gxvkern.c (gxv_kern_subtable_fmt1_entry_validate):
6161 Remove functionless code.
6162
6163 * src/tools/ftrandom.c (main): Fix memory leak.
6164
Werner Lemberg2429dc32013-06-03 12:41:58 +020061652013-06-03 Werner Lemberg <wl@gnu.org>
6166
6167 Add CFF_CONFIG_OPTION_OLD_ENGINE configuration option.
6168
6169 This controls whether the old FreeType CFF engine gets compiled into
6170 FreeType. It is now disabled by default.
6171
6172 * devel/ftoption.h, include/freetype/config/ftoption.h
6173 (CFF_CONFIG_OPTION_OLD_ENGINE): New macro.
6174
6175 * src/cff/cffdrivr.c (cff_property_set), src/cff/cffgload.c
6176 (CFF_Operator, cff_argument_counts, cff_builder_add_point,
6177 cff_operator_seac, cff_decoder_parse_charstrings, cff_slot_load),
6178 src/cff/cffgload.h, src/cff/cffobjs.c (cff_driver_init): Use
6179 CFF_CONFIG_OPTION_OLD_ENGINE to guard the affected code.
6180
6181 * docs/CHANGES: Updated.
6182
Werner Lembergf9cceeb2013-06-02 23:38:13 +020061832013-06-02 Werner Lemberg <wl@gnu.org>
6184
6185 Fix PNG library handling.
6186
6187 * builds/unix/configure.raw: Don't use LIBPNG_LIBS but
6188 LIBPNG_LDFLAGS.
6189
Behdad Esfahbod760d3422013-05-29 11:36:18 +020061902013-05-23 Behdad Esfahbod <behdad@google.com>
6191
6192 Add support for color embedded bitmaps (eg. color emoji).
6193
6194 A new load flag, FT_LOAD_COLOR, makes FreeType load color
6195 embedded-bitmaps, following this draft specification
6196
6197 https://color-emoji.googlecode.com/git/specification/v1.html
6198
6199 which defines two new SFNT tables, `CBDT' and `CBLC' (named and
6200 modeled after `EBDT' and `EBLC', respectively). The color bitmaps
6201 are stored in the new FT_PIXEL_MODE_BGRA format to represent BGRA
6202 pre-multiplied sRGB images. If PNG support is available, PNG color
6203 images as defined in the same proposed specification are supported
6204 also.
6205
6206 Note that color bitmaps are converted to grayscale if client didn't
6207 ask for color.
6208
6209 * builds/unix/configure.raw: Search for libpng.
6210 Add `--without-png' option.
6211
6212 * devel/ftoption.h, include/freetype/config/ftoption.h
6213 (FT_CONFIG_OPTION_USE_PNG): New macro.
6214
6215 * include/freetype/freetype.h (FT_LOAD_COLOR): New load flag.
6216
6217 * include/freetype/ftimage.h (FT_Pixel_Mode): Add
6218 `FT_PIXEL_MODE_BGRA'.
6219
6220 * include/freetype/tttags.h (TTAG_CBDT, TTAG_CBLC): New tags.
6221
6222 * src/base/ftbitmap.c (FT_Bitmap_Embolden): Updated.
6223 (ft_gray_for_premultiplied_srgb_bgra): New function.
6224 (FT_Bitmap_Convert): Handle FT_PIXEL_MODE_BGRA.
6225
6226 * src/sfnt/pngshim.c, src/sfnt/pngshim.h: New files.
6227
6228 * src/sfnt/sfnt.c: Include `pngshim.c'.
6229
6230 * src/sfnt/ttsbit.c: Include FT_BITMAP_H and `pngshim.h'
6231 (tt_face_load_eblc): Load `CBLC'.
6232 (tt_sbit_decoder_init): Load `CBDT'.
6233 (tt_sbit_decoder_alloc_bitmap): Pass load flags to select between
6234 color and grayscale bitmaps.
6235 Set `num_grays'. This is used by `ftview' to choose the blending
6236 algorithm.
6237 (tt_sbit_decoder_load_byte_aligned,
6238 tt_sbit_decoder_load_bit_aligned, tt_sbit_decoder_load_compound,
6239 tt_sbit_decoder_load_image): Pass load flag.
6240 s/write/pwrite/.
6241 Don't call `tt_sbit_decoder_alloc_bitmap'.
6242 Updated.
6243 (tt_sbit_decoder_load_png) [FT_CONFIG_OPTION_USE_PNG]: New function.
6244 (tt_sbit_decoder_load_bitmap): Pass load flag.
6245 Handle new glyph formats 17, 18, and 19.
6246 Call `tt_sbit_decoder_alloc_bitmap'.
6247 Flatten color bitmaps if necessary.
6248 (tt_face_load_sbit_image): Updated.
6249
6250 * src/sfnt/rules.mk (SFNT_DRV_SRC): Add `pngshim.c'.
6251
6252 * docs/CHANGES: Updated.
6253
Guenter41e44802013-05-24 11:38:09 +020062542013-05-24 Guenter <info@gknw.net>
6255
6256 Apply Savannah patch #8055.
6257
6258 Make `apinames' create an import file for NetWare.
6259
6260 * src/tools/apinames.c (PROGRAM_VERSION): Set to 0.2.
6261 (OutputFormat): Add `OUTPUT_NETWARE_IMP'.
6262 (names_dump): Handle it.
6263 (usage): Updated.
6264 (main): Handle new command line flag `-wN'.
6265
Behdad Esfahbod2d6e1fb2013-05-23 08:01:20 +020062662013-05-23 Behdad Esfahbod <behdad@behdad.org>
6267
6268 Compilation fix.
6269
6270 * src/truetype/ttinterp.c (TT_RunIns)
6271 [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Make it work.
6272
Infinality18f35ed2013-05-21 20:51:15 -050062732013-05-22 Infinality <infinality@infinality.net>
6274
Infinality3c783c12013-05-21 21:03:00 -05006275 [truetype] Formatting and an additional subpixel tweak.
6276
6277 * src/truetype/ttinterp.c (Ins_SHPIX): Formatting fix.
6278 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules):
6279 Revert previous modification for Verdana clones.
6280
62812013-05-22 Infinality <infinality@infinality.net>
6282
Infinality18f35ed2013-05-21 20:51:15 -05006283 [truetype] Adjust subpixel zp2 moves and tweak rules.
6284
6285 These modifications fix thin diagonal stems in some legacy fonts.
6286
6287 * src/truetype/ttinterp.c (Direct_Move_X): Remove unused macro.
6288 (Move_Zp2_Point): Don't always disable x moves for subpixel rendering.
6289 (Ins_SHP): Disable x moves here for subpixel rendering.
6290 (Ins_SHPIX): Only disable x moves in compatibility mode.
6291 Split out zp2 move reversals and reorder conditional respectively.
6292
6293 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules): Fix oversight.
6294 Only adjust Verdana clones for 17 ppem.
6295 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Courier New.
6296 (ALWAYS_SKIP_DELTAP_Rules): Found additional cases for Arial `s'.
6297
Infinality63bfa832013-05-20 07:38:21 +020062982013-05-20 Infinality <infinality@infinality.net>
6299
6300 [truetype] Simplify and improve subpixel function detection.
6301
6302 Some small enhancements have allowed the removal of many macros and
6303 the simplification of existing rules in `ttsubpix.c'.
6304
6305 * src/truetype/ttsubpix.h (SPH_TWEAK_ALLOW_X_DMOVEX,
6306 SPH_TWEAK_ALLOW_X_MOVE_ZP2,
6307 SPH_TWEAK_DELTAP_SKIP_EXAGGERATED_VALUES,
6308 SPH_TWEAK_SKIP_INLINE_DELTAS, SPH_TWEAK_MIRP_CVT_ZERO): Removed.
6309 (SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES_DELTAP): New rule macro.
6310
6311 * src/truetype/ttsubpix.c: Updated affected rules.
6312
6313 * src/truetype/ttinterp.c (Direct_Move_X): Updated.
6314 (INS_FDEF): Add additional function detection.
6315 (INS_ENDF): Set runtime flag.
6316 (Ins_CALL): Skip the call under certain conditions.
6317 Remove bad code.
6318 (Ins_LOOPCALL): Skip the call under certain conditions.
6319 Remove bad code.
6320 (Move_Zp2_Point): Updated.
6321 (Ins_SHPIX): Updated.
6322 Skip the move under some situations.
6323 (Ins_MIAP): Improve conditions.
6324 (Ins_MIRP): Updated.
6325 (Ins_DELTAP): Skip move under certain conditions.
6326 Simplify conditions.
6327 (TT_RunIns): Updated.
6328 Add code to handle new function detection.
6329 Trace messages.
6330
Werner Lembergfd664692013-05-17 17:40:27 +020063312013-05-17 Werner Lemberg <wl@gnu.org>
6332
6333 Update more FT_Err_XXX macros using FT_ERR and FT_THROW;
6334
6335 * builds/amiga/src/base/ftsystem.c, builds/mac/ftmac.c,
6336 builds/unix/ftsystem.c, builds/vms/ftsystem.c: Do it.
6337
Werner Lembergf04951a2013-05-17 13:51:07 +020063382013-05-15 Werner Lemberg <wl@gnu.org>
6339
6340 [truetype] Add `interpreter-version' property.
6341
6342 This makes the option TT_CONFIG_OPTION_SUBPIXEL_HINTING controllable
6343 at runtime.
6344
Werner Lemberg27991332013-05-17 14:00:26 +02006345 * include/freetype/ftttdrv.h: New file.
6346
6347 * include/freetype/config/ftheader.h (FT_TRUETYPE_DRIVER_H): New
6348 macro.
6349
Werner Lembergf04951a2013-05-17 13:51:07 +02006350 * src/truetype/ttdriver.c: Include FT_TRUETYPE_DRIVER_H.
6351 (tt_property_set, tt_property_get): Fill templates.
6352
6353 * src/truetype/ttobjs.h (TT_DriverRec): Add `interpreter_version'
6354 member.
6355 Remove unused `extension_component' member.
6356
6357 * src/truetype/ttgload.c: Include FT_TRUETYPE_DRIVER_H.
6358 (tt_get_metrics, TT_Hint_Glyph, TT_Process_Simple_Glyph,
6359 compute_glyph_metrics, tt_loader_init): Use `interpreter_version'.
6360
6361 * src/truetype/ttinterp.c: Include FT_TRUETYPE_DRIVER_H.
6362 (SUBPIXEL_HINTING): New macro to check `interpreter_version' flag.
6363 Update all affected functions to use it.
6364 Use TT_INTERPRETER_VERSION_XXX where appropriate.
6365
6366 * src/truetype/ttobjs.c: Include FT_TRUETYPE_DRIVER_H.
6367 (tt_driver_init): Initialize `interpreter_version'.
6368
6369 * src/truetype/ttsubpix.c: Include FT_TRUETYPE_DRIVER_H.
6370 Use TT_INTERPRETER_VERSION_XXX where appropriate.
6371
Werner Lemberg7441dd82013-05-13 09:12:46 +020063722013-05-13 Werner Lemberg <wl@gnu.org>
6373
Werner Lemberg6650be72013-05-13 10:05:29 +02006374 [truetype] Avoid empty source file.
6375
6376 * src/truetype/ttsubpix.c [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]:
6377 Provide dummy typedef.
6378
63792013-05-13 Werner Lemberg <wl@gnu.org>
6380
Werner Lemberg7441dd82013-05-13 09:12:46 +02006381 * src/cff/cf2font.c (cf2_getGlyphWidth): Fix uninitialized variable.
6382
6383 Fix suggested by Vaibhav Nagarnaik <vnagarnaik@gmail.com>.
6384
Brian Nixon8d6025c2013-05-13 09:06:42 +020063852013-05-13 Brian Nixon <bnixon@yahoo.com>
6386
6387 Fix Savannah bug #38970.
6388
6389 * src/base/ftdebug.c, builds/win32/ftdebug.c,
6390 builds/wince/ftdebug.c, builds/amiga/src/base/ftdebug.c
6391 (ft_debug_init): Don't read past the environment variable FT2_DEBUG.
6392
Werner Lembergd51ac9c2013-05-12 06:00:27 +020063932013-05-12 Werner Lemberg <wl@gnu.org>
6394
Werner Lembergcd888752013-05-12 15:08:57 +02006395 [truetype] Add framework for TrueType properties.
6396
6397 * src/truetype/ttdrivr.c: Include FT_SERVICE_PROPERTIES_H.
6398 (tt_property_set, tt_property_get): New functions, still empty.
6399 Define `tt_service_properties' service.
6400 Update `tt_services'.
6401
6402 * src/truetype/ttpic.h: Include FT_SERVICE_PROPERTIES_H.
6403 (TT_SERVICE_PROPERTIES_GET): New macro.
6404 (TTModulePIC): Add `tt_service_properties'.
6405
64062013-05-12 Werner Lemberg <wl@gnu.org>
6407
Werner Lembergb112fa42013-05-12 07:29:04 +02006408 Fix Savannah bug #38967.
6409
6410 * src/base/ftcalc.c (FT_DivFix) [FT_LONG64]: Fix cast.
6411
64122013-05-12 Werner Lemberg <wl@gnu.org>
6413
Werner Lembergcbcf33d2013-05-12 07:27:48 +02006414 Introduce unsigned 64bit type (if available).
6415
6416 * include/freetype/config/ftconfig.h: Define FT_UINT64 if available.
6417 [FT_LONG64]: Provide FT_UInt64.
6418
6419 * builds/unix/ftconfig.in: Synchronized.
6420
64212013-05-12 Werner Lemberg <wl@gnu.org>
6422
Werner Lembergd51ac9c2013-05-12 06:00:27 +02006423 Fix Savannah bug #38968.
6424
6425 * include/freetype/ftmodapi.h: Add `FT_EXPORT' to
6426 FT_Property_{Set,Get}.
6427 * src/base/ftobjs.c: Add `FT_EXPORT_DEF' to
6428 FT_Property_{Set,Get}.
6429
Werner Lembergf6aa0892013-05-10 07:58:47 +020064302013-05-10 Werner Lemberg <wl@gnu.org>
6431
Werner Lembergea2b4752013-05-10 08:04:33 +02006432 [sfnt] Clean up bitmap code.
6433
6434 * src/sfnt/ttsbit.c: Deleted.
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006435 * src/sfnt/ttsbit0.c: Renamed to `ttsbit.c'.
Werner Lembergea2b4752013-05-10 08:04:33 +02006436 * rules.mk (SFNT_DRV_H): Updated.
6437
64382013-05-10 Werner Lemberg <wl@gnu.org>
6439
Werner Lembergf6aa0892013-05-10 07:58:47 +02006440 */* [FT_CONFIG_OPTION_OLD_INTERNALS]: Remove macro and guarded code.
6441
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00006442----------------------------------------------------------------------------
6443
Werner Lembergf57fc592015-01-17 20:41:43 +01006444Copyright 2013-2015 by
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00006445David Turner, Robert Wilhelm, and Werner Lemberg.
6446
6447This file is part of the FreeType project, and may only be used, modified,
6448and distributed under the terms of the FreeType project license,
6449LICENSE.TXT. By continuing to use, modify, or distribute this file you
6450indicate that you have read the license and understand and accept it
6451fully.
6452
6453
6454Local Variables:
6455version-control: never
Werner Lemberg4e03fe72006-04-29 06:20:09 +00006456coding: utf-8
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00006457End: