blob: 8dc1ce24ea20acbdf3c2f2ddd808800b5fc3ab67 [file] [log] [blame]
Werner Lemberg6cc425d2015-03-21 06:51:07 +010012015-03-21 Werner Lemberg <wl@gnu.org>
2
3 [truetype] Improve `gvar' handling.
4
5 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Correctly handle
6 single-element runs. Cf. glyph `Q' in Skia.ttf with weights larger
7 than the default.
8
Alexei Podtelezhnikov2d7284e2015-03-20 21:34:19 -040092015-03-20 Alexei Podtelezhnikov <apodtele@gmail.com>
10
11 * src/base/fttrigon.c (FT_Vector_Rotate): Minor refactoring.
12
Alexei Podtelezhnikov6a171722015-03-17 22:43:08 -0400132015-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
14
15 Fix Savannah bug #44412 (part 2).
16
17 * src/base/fttrigon.c (FT_Sin, FT_Cos, FT_Tan): Call `FT_Vector_Unit'.
18
Werner Lemberg06339952015-03-11 06:30:23 +0100192015-03-11 Werner Lemberg <wl@gnu.org>
20
Werner Lembergd3284462015-03-11 16:45:58 +010021 [autofit] Add support for Arabic script.
22
23 Thanks to Titus Nemeth <tn@tntypography.eu> for guidance!
24
25 * src/autofit/afblue.dat: Add blue zone data for Arabic.
26
27 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
28
29 * src/autofit/afscript.h: Add Arabic standard characters.
30
31 * src/autofit/afranges.c: Add Arabic data.
32
33 * src/autofit/afstyles.h: Add Arabic data.
34
35 * docs/CHANGES: Document it.
36
372015-03-11 Werner Lemberg <wl@gnu.org>
38
Werner Lemberga4516382015-03-11 08:09:13 +010039 Rename `svxf86nm.h' to `svfntfmt.h'; update related symbols.
40
41 * include/internal/ftserv.h (FT_SERVICE_XFREE86_NAME_H): Renamed
42 to...
43 (FT_SERVICE_FONT_FORMAT_H): This.
44
45 * include/internal/services/svfntfmt.h (FT_XF86_FORMAT_*): Renamed
46 to ...
47 (FT_FONT_FORMAT_*): This.
48
49 src/base/ftfntfmt.c, src/bdf/bdfdrivr.c, src/cff/cffdrivr.c,
50 src/cid/cidriver.c, src/pcf/pcfdrivr.c, src/pfr/pfrdrivr.c,
51 src/truetype/ttdriver.c, src/type1/t1driver.c,
52 src/type42/t42drivr.c, src/winfonts/winfnt.c: Updated.
53
542015-03-11 Werner Lemberg <wl@gnu.org>
55
Werner Lembergdd7028c2015-03-11 07:45:05 +010056 [base] Rename `FT_XFREE86_H' to `FT_FONT_FORMATS_H'.
57
58 * include/config/ftheader.h: Implement it.
59 * src/base/ftfntfmt.c, docs/CHANGES: Updated.
60
612015-03-11 Werner Lemberg <wl@gnu.org>
62
Werner Lembergf4d1c112015-03-11 07:32:58 +010063 [base] Rename `FT_Get_X11_Font_Format' to `FT_Get_Font_Format'.
64
65 * include/ftfntfmt.h, src/base/ftfntfmt.c: Implement it.
66
67 * docs/CHANGES: Updated.
68
692015-03-11 Werner Lemberg <wl@gnu.org>
70
Werner Lembergcb0f7b62015-03-11 06:51:27 +010071 Fix automatic copyright updating.
72
73 * src/tools/update-copyright: Make scanning of `no-copyright'
74 actually work.
75
76 * src/tools/no-copyright: Don't include README in general.
77
782015-03-11 Werner Lemberg <wl@gnu.org>
79
Werner Lemberg06339952015-03-11 06:30:23 +010080 Rename `ftxf86.[ch]' to `ftfntfmt.[ch]'.
81
82 CMakeLists.txt, builds/amiga/makefile, builds/amiga/makefile.os4,
83 builds/amiga/smakefile, builds/mac/FreeType.m68k_cfm.make.txt,
84 builds/mac/FreeType.m68k_far.make.txt,
85 builds/mac/FreeType.ppc_carbon.make.txt,
86 builds/mac/FreeType.ppc_classic.make.txt, builds/symbian/bld.inf,
87 builds/symbian/freetype.mmp, builds/wince/vc2005-ce/freetype.vcproj,
88 builds/wince/vc2008-ce/freetype.vcproj,
89 builds/windows/vc2005/freetype.vcproj,
90 builds/windows/vc2008/freetype.vcproj,
91 builds/windows/vc2010/freetype.vcxproj,
92 builds/windows/vc2010/freetype.vcxproj.filters,
93 builds/windows/visualc/freetype.dsp,
94 builds/windows/visualc/freetype.vcproj,
95 builds/windows/visualce/freetype.dsp,
96 builds/windows/visualce/freetype.vcproj, docs/INSTALL.ANY,
97 include/config/ftheader.h, include/ftfntfmt.h, modules.cfg,
98 src/base/ftfntfmt.c, vms_make.com: Updated.
99
Alexei Podtelezhnikov6b832c82015-03-10 23:25:49 -04001002015-03-10 Alexei Podtelezhnikov <apodtele@gmail.com>
101
102 Fix Savannah bug #44412 (part 1).
103
104 * src/base/ftstroke.c (ft_stroker_inside): Handle near U-turns.
105
Werner Lembergeee7d8b2015-03-10 11:15:15 +01001062015-03-10 Werner Lemberg <wl@gnu.org>
107
108 [base] Rename `FT_Bitmap_New' to `FT_Bitmap_Init'.
109
110 * include/ftbitmap.h, src/base/ftbitmap.c: Implement it.
111 Update all callers.
112
113 * docs/CHANGES: Updated.
114
Werner Lemberg493cc032015-03-06 05:38:31 +01001152015-03-06 Werner Lemberg <wl@gnu.org>
116
117 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix compiler warning.
118
119 Found by Alexei.
120
Alexei Podtelezhnikovdd7498d2015-03-05 22:51:36 -05001212015-03-05 Alexei Podtelezhnikov <apodtele@gmail.com>
122
123 * src/base/ftstroke.c: Simplify.
124
Werner Lemberg328b7922015-03-04 08:40:23 +01001252015-03-04 Werner Lemberg <wl@gnu.org>
126
127 [truetype] Some fixes and code refactoring in `ttgxvar.c'.
128
129 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Fix return value
130 of `point_cnt' if two bytes are read.
131 Use a more vertical coding style.
132 (ft_var_readpackeddeltas): Use FT_UInt for `delta_cnt' parameter.
133 Use a more vertical coding style.
134
Werner Lemberga374c9c2015-03-03 11:23:45 +01001352015-03-03 Werner Lemberg <wl@gnu.org>
136
137 [autofit] Fix Savannah bug #44241.
138
139 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Reject glyphs
140 with less than 3 points.
141
Werner Lemberga07029e2015-03-02 06:54:08 +01001422015-03-02 Werner Lemberg <wl@gnu.org>
143
144 Simplify `TYPEOF' macro.
145
146 No need for two arguments.
147
148 * include/config/ftconfig.h, builds/unix/ftconfig.in,
149 builds/vms/ftconfig.h (TYPEOF): Updated.
150
151 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
152 src/autofit/afwarp.h (AF_WARPER_FLOOR): Updated.
153
1542015-03-01 Werner Lemberg <wl@gnu.org>
Werner Lemberg4b9234b2015-02-25 06:31:43 +0100155
Werner Lemberg851e8152015-03-01 19:27:09 +0100156 Various compiler warning fixes for `make multi'.
157
158 * src/autofit/afcjk.c (af_cjk_hints_compute_blue_edges),
159 src/autofit/aflatin.c (af_latin_hint_compute_blue_edges,
160 af_latin_hint_edges), src/autofit/aflatin2.c
161 (af_latin2_hints_compute_blue_edges, af_latin2_hint_edges): Declare
162 as `static'.
163
164 * src/cache/ftccmap.c (FTC_CMAP_QUERY_HASH, FTC_CMAP_NODE_HASH):
165 Removed. Unused.
166 * src/cache/ftcimage.c: Include FT_INTERNAL_OBJECTS_H.
167 * src/cache/ftcmanag.c (FTC_LRU_GET_MANAGER): Removed. Unused.
168
169 * src/cff/cf2intrp.c: Include `cf2intrp.h'.
170 * src/cff/cffdrivr.c (PAIR_TAG): Removed. Unused.
171
172 * src/gzip/ftgzip.c (NO_DUMMY_DECL): Removed. Unused.
173
174 * src/psaux/afmparse.c (afm_parser_read_int): Declare as `static'.
175
176 * src/pshinter/pshalgo.c (STRONGER, PSH_ZONE_MIN, PSH_ZONE_MAX):
177 Removed. Unused.
178
179 * src/raster/ftraster.c (Render_Glyph): Declare as `static'.
180
181 * src/sfnt/ttpost.c (load_format_20): Fix signedness warning.
182
183 * src/truetype/ttdriver.c (PAIR_TAG): Removed. Unused.
184 * src/truetype/ttsubpix.c (is_member_of_family_class,
185 is_member_of_style_class): Declare as `static'.
186
187 * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Declare
188 as `static'.
189 * src/type1/t1load.c (mm_axis_unmap, mm_weights_unmap): Declare as
190 `static'.
191 (T1_FIELD_COUNT): Removed. Unused.
192 * src/type1/t1parse.h (T1_Done_Table): Removed. Unused.
193
194 * src/type42/t42parse.c (T1_Done_Table): Removed. Unused.
195
1962015-02-25 Werner Lemberg <wl@gnu.org>
197
Werner Lemberg04c22372015-02-25 11:20:20 +0100198 [psaux] Signedness fixes.
199
200 * include/internal/psaux.h, src/psaux/afmparse.c,
201 src/psaux/afmparse.h, src/psaux/psconv.c, src/psaux/psobjs.c,
202 src/psaux/t1cmap.c, src/psaux/t1decode.c: Apply.
203
2042015-02-25 Werner Lemberg <wl@gnu.org>
205
Werner Lembergd25ec162015-02-25 09:19:59 +0100206 [otvalid] Signedness fixes.
207
208 * src/otvalid/otvcommn.c, src/otvalid/otvgdef.c,
209 src/otvalid/otvgpos.c, src/otvalid/otvgsub.c, src/otvalid/otvmath.c:
210 Apply.
211
2122015-02-25 Werner Lemberg <wl@gnu.org>
213
Werner Lemberg5c9d9bf2015-02-25 08:13:40 +0100214 * src/bzip2/ftbzip2.c (ft_bzip2_alloc): Signedness fix.
215
2162015-02-25 Werner Lemberg <wl@gnu.org>
217
Werner Lemberg83d41812015-02-25 08:10:58 +0100218 [lzw] Signedness fixes.
219
220 * src/lzw/ftzopen.c, src/lzw/ftzopen.h: Apply.
221
2222015-02-25 Werner Lemberg <wl@gnu.org>
223
Werner Lemberg17b62912015-02-25 07:53:09 +0100224 [gxvalid] Signedness fixes.
225
226 * src/gxvalid/gxvbsln.c, src/gxvalid/gxvcommn.c,
227 src/gxvalid/gxvcommn.h, src/gxvalid/gxvjust.c,
228 src/gxvalid/gxvkern.c, src/gxvalid/gxvlcar.c, src/gxvalid/gxvmort.c,
229 src/gxvalid/gxvmort1.c, src/gxvalid/gxvmort2.c,
230 src/gxvalid/gxvmorx.c, src/gxvalid/gxvmorx1.c,
231 src/gxvalid/gxvmorx2.c, src/gxvalid/gxvopbd.c,
232 src/gxvalid/gxvprop.c, src/gxvalid/gxvtrak.c: Apply.
233
2342015-02-25 Werner Lemberg <wl@gnu.org>
235
Werner Lemberg24e4e962015-02-25 06:57:16 +0100236 [cache] Signedness fixes.
237
238 * src/cache/ftcbasic.c, src/cache/ftccmap.c, src/cache/ftcimage.c,
239 src/cache/ftcmanag.c, src/cache/ftcsbits.c: Apply.
240
2412015-02-25 Werner Lemberg <wl@gnu.org>
242
Werner Lemberg559727d2015-02-25 06:55:00 +0100243 Change dimension fields in `FTC_ImageTypeRec' to unsigned type.
244
245 This doesn't break ABI.
246
247 * include/ftcache.h (FTC_ImageTypeRec): Use unsigned types for
248 `width' and `height'.
249
250 * docs/CHANGES: Document it.
251
2522015-02-25 Werner Lemberg <wl@gnu.org>
253
Werner Lemberg4b9234b2015-02-25 06:31:43 +0100254 [cache] Don't use `labs'.
255
256 This is the only place in FreeType where this function was used.
257
258 * include/config/ftstdlib.h (ft_labs): Remove.
259
260 * src/cache/ftcimage.c (ftc_inode_weight): Replace `ft_labs' with
261 `FT_ABS'.
262
Werner Lemberg4d1f7af2015-02-23 07:04:36 +01002632015-02-23 Werner Lemberg <wl@gnu.org>
264
Werner Lemberg3aaebe32015-02-23 08:20:27 +0100265 [cache] Replace `FT_PtrDist' with `FT_Offset'.
266
267 * src/cache/ftccache.h (FTC_NodeRec): `FT_Offset' (a.k.a. `size_t')
268 is a better choice for `hash' to hold a pointer than `FT_PtrDist'
269 (a.k.a. `ptrdiff_t'), especially since the latter is signed,
270 causing zillions of signedness warnings. [Note that `hash' was of
Werner Lemberg17b62912015-02-25 07:53:09 +0100271 type `FT_UInt32' before the change to `FT_PtrDist'.]
Werner Lemberg3aaebe32015-02-23 08:20:27 +0100272 Update all users.
273
274 * src/cache/ftcbasic.c, src/cache/ftccache.c, src/cache/ftccmap.c,
275 src/cache/ftcglyph.c, src/cache/ftcglyph.h: Updated.
276
2772015-02-23 Werner Lemberg <wl@gnu.org>
278
Werner Lemberg4d1f7af2015-02-23 07:04:36 +0100279 [smooth, raster] Re-enable standalone compilation.
280
281 * src/raster/ftraster.c (FT_RENDER_POOL_SIZE, FT_MAX)
282 [_STANDALONE_]: Define macros.
283
284 * src/smooth/ftgrays.c (FT_RENDER_POOL_SIZE, FT_MAX, FT_ABS,
285 FT_HYPOT) [_STANDALONE_]: Define macros.
286
Werner Lemberg03ccfd02015-02-22 08:25:16 +01002872015-02-22 Werner Lemberg <wl@gnu.org>
288
Werner Lembergcb13e712015-02-23 06:41:52 +0100289 [smooth] Signedness fixes.
290
291 * src/smooth/ftgrays.c, src/smooth/ftsmooth.c: Apply.
292
2932015-02-22 Werner Lemberg <wl@gnu.org>
294
Werner Lemberga974e9a2015-02-22 21:02:13 +0100295 * src/raster/ftraster.c: Use the file's typedefs everywhere.
296
2972015-02-22 Werner Lemberg <wl@gnu.org>
298
Werner Lembergb0ebcdc2015-02-22 20:42:49 +0100299 * src/sfnt/ttpost.c (load_format_20): Fix error tracing message.
300
301 Bug introduced 6 commits earlier.
302
3032015-02-22 Werner Lemberg <wl@gnu.org>
304
Werner Lemberg22b1d5c2015-02-22 20:41:03 +0100305 [pshinter] Fix thinko.
306
307 * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Correctly
308 check `count'.
309 Bug introduced two commits earlier.
310
3112015-02-22 Werner Lemberg <wl@gnu.org>
312
Werner Lembergca96fe02015-02-22 20:05:04 +0100313 [raster] Signedness fixes.
314
315 * src/raster/ftraster.c, src/raster/ftrend1.c: Apply.
316
3172015-02-22 Werner Lemberg <wl@gnu.org>
318
Werner Lemberg452066c2015-02-22 15:59:02 +0100319 [pshinter] Signedness fixes.
320
321 * src/pshinter/pshalgo.c, src/pshinter/pshglob.c,
322 src/pshinter/pshrec.c: Apply.
323
3242015-02-22 Werner Lemberg <wl@gnu.org>
325
Werner Lemberg41c2ed82015-02-22 15:57:47 +0100326 [pshinter] Use macros for (unsigned) flags, not enumerations.
327
328 * src/pshinter/pshalgo.h (PSH_Hint_Flags): Replace with macros.
329 Updated.
330 * src/pshinter/pshrec.h (PS_Hint_Flags): Replace with macros.
331
3322015-02-22 Werner Lemberg <wl@gnu.org>
333
Werner Lemberg25c2f882015-02-22 15:54:31 +0100334 * src/pshinter/pshrec.c: Simplify.
335 (ps_hints_open, ps_hints_stem): Remove switch statement.
336
3372015-02-22 Werner Lemberg <wl@gnu.org>
338
Werner Lemberg01f08422015-02-22 12:03:28 +0100339 [sfnt] Signedness fixes.
340
341 * src/sfnt/pngshim.c, src/sfnt/sfobjs.c, src/sfnt/ttcmap.c,
342 src/sfnt/ttkern.c, src/sfnt/ttload.c, src/sfnt/ttpost.c,
343 src/sfnt/ttsbit.c: Apply.
344 * src/sfnt/sfdriver.c: Apply.
345 (sfnt_get_ps_name): Simplify.
346
3472015-02-22 Werner Lemberg <wl@gnu.org>
348
Werner Lemberg3c374c82015-02-22 09:16:53 +0100349 [bdf] Signedness fixes.
350
351 * src/bdf/bdf.h, src/bdf/bdfdrivr.c, src/bdf/bdfdrivr.h,
352 src/bdf/bdflib.c: Apply.
353
3542015-02-22 Werner Lemberg <wl@gnu.org>
355
Werner Lembergb13945a2015-02-22 09:15:47 +0100356 * src/bdf/bdflib.c (_bdf_atous): New function.
357 (_bdf_parse_glyphs, _bdf_parse_start): Use it.
358
3592015-02-22 Werner Lemberg <wl@gnu.org>
360
Werner Lemberg03ccfd02015-02-22 08:25:16 +0100361 [pcf] Signedness fixes.
362
363 * src/pcf/pcf.h, src/pcf/pcfdrivr.c: Apply.
364 * src/pcf/pcfread.c: Apply.
365 (pcf_get_encodings): Ignore invalid negative encoding offsets.
366
Werner Lemberg633a7292015-02-21 07:02:01 +01003672015-02-21 Werner Lemberg <wl@gnu.org>
368
Werner Lemberg3d7e53f2015-02-21 11:30:54 +0100369 * src/winfonts/winfnt.c: Signedness fixes.
370
3712015-02-21 Werner Lemberg <wl@gnu.org>
372
Werner Lemberg7b6b4172015-02-21 10:39:34 +0100373 [type42] Signedness fixes.
374
375 * src/type42/t42parse.c, src/type42/t42parse.h,
376 src/type42/t42types.h: Apply.
377
3782015-02-21 Werner Lemberg <wl@gnu.org>
379
Werner Lemberg8bfffb42015-02-21 09:52:29 +0100380 [pfr] Signedness fixes.
381
382 * src/pfr/pfrdrivr.c, src/pfr/pfrgload.c, src/pfr/pfrload.c,
383 src/pfr/pfrload.h, src/pfr/pfrobjs.c, src/pfr/pfrsbit.c,
384 src/pfr/pfrtypes.h: Apply.
385
3862015-02-21 Werner Lemberg <wl@gnu.org>
387
Werner Lemberg633a7292015-02-21 07:02:01 +0100388 [cff] Minor signedness fixes related to last commit.
389
390 * src/cff/cf2ft.c, src/cff/cf2intrp.c, src/cff/cffgload.c: Apply.
391
Werner Lemberg3a8d0532015-02-20 08:35:32 +01003922015-02-20 Werner Lemberg <wl@gnu.org>
393
Werner Lembergc00b05f2015-02-20 20:42:55 +0100394 [cff] Thinkos in bias handling.
395
396 Only the final result is always positive.
397
398 Bug introduced three commits earlier.
399
400 * src/cff/cffgload.c, src/cff/cffgload.h: Apply.
401
4022015-02-20 Werner Lemberg <wl@gnu.org>
403
Werner Lemberg2bf03eb2015-02-20 20:14:11 +0100404 [cid] Fix signedness issues and emit some better error codes.
405
406 * src/cid/cidgload.c, src/cid/cidload.h, src/cid/cidobjs.c,
407 src/cid/cidparse.h: Apply.
408 * src/cid/cidload.c: Apply.
409 (parse_fd_array): Reject negative values for number of dictionaries.
410 * src/cid/cidparse.c: Apply.
411 (cid_parser_new): Reject negative values for hex data length.
412
4132015-02-20 Werner Lemberg <wl@gnu.org>
414
Werner Lembergeb05bfb2015-02-20 08:37:35 +0100415 [cff] Signedness fixes for new engine.
416
417 * src/cff/cf2arrst.c, src/cff/cf2fixed.h, src/cff/cf2ft.c,
418 src/cff/cf2ft.h, src/cff/cf2hints.c, src/cff/cf2intrp.c: Apply.
419
4202015-02-20 Werner Lemberg <wl@gnu.org>
421
Werner Lemberg3a8d0532015-02-20 08:35:32 +0100422 [cff] Signedness fixes for basic infrastructure and old engine.
423
424 * include/internal/pshints.h, src/cff/cffdrivr.c,
425 src/cff/cffgload.c, src/cff/cffgload.h, src/cff/cffload.c,
426 src/cff/cffobjs.c, src/cff/cffparse.c, src/pshinter/pshrec.c: Apply.
427
Werner Lemberg81e5ff52015-02-19 09:46:48 +01004282015-02-19 Werner Lemberg <wl@gnu.org>
429
Werner Lemberg3a1df3e2015-02-19 15:42:48 +0100430 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Ignore `countSizePairs'.
431
432 This is hard-coded to value 2 in `fvar' version 1.0 (and no newer
433 version exists), but some fonts set it incorrectly.
434
435 Problem reported by Adam Twardoch <adam@fontlab.com>.
436
4372015-02-19 Werner Lemberg <wl@gnu.org>
438
Werner Lemberg93a884c2015-02-19 14:11:16 +0100439 [cff] Emit better error code for invalid private dict size.
440
441 * src/cff/cffparse.c (cff_parse_private_dict): Reject negative
442 values for size and offset.
443
4442015-02-19 Werner Lemberg <wl@gnu.org>
445
Werner Lembergb57bb112015-02-19 10:44:18 +0100446 [autofit] Fix signedness issues.
447
448 * src/autofit/afangles.c, src/autofit/afcjk.c,
449 src/autofit/afglobal.c, src/autofit/afhints.c,
450 src/autofit/aflatin.c, src/autofit/aflatin2.c, src/autofit/afwarp.c,
451 src/autofit/hbshim.c: Apply.
452
4532015-02-19 Werner Lemberg <wl@gnu.org>
454
Werner Lemberg81e5ff52015-02-19 09:46:48 +0100455 [autofit] Use macros for (unsigned) flags, not enumerations.
456
457 This harmonizes with other code in FreeType (and reduces the number
458 of necessary casts to avoid compiler warnings).
459
460 * src/autofit/afblue.hin: Make flag macros unsigned.
461 * src/autofit/afblue.h: Regenerated.
462
463 * src/autofit/afcjk.h: Replace flag enumeration with macros.
464 * src/autofit/afcjk.c: Updated.
465
466 * src/autofit/afhints.h (AF_Flags, AF_Edge_Flags): Replace with
467 macros.
468 * src/autofit/afhints.c: Updated.
469
470 * src/autofit/aflatin.h: Replace flag enumerations with macros.
471 * src/autofit/aflatin.c, src/autofit/aflatin2.c: Updated.
472
473 * src/autofit/aftypes.h (AF_ScalerFlags): Replace with macros.
474
Werner Lemberg6a0ded72015-02-18 08:51:22 +01004752015-02-18 Werner Lemberg <wl@gnu.org>
476
Werner Lemberg3b5f3322015-02-18 11:45:22 +0100477 [type1] Fix signedness issues.
478
479 * include/internal/psaux.h, include/internal/t1types.h,
480 src/psaux/psobjs.c, src/psaux/psobjs.h, src/psaux/t1decode.c,
481 src/type1/t1gload.c, src/type1/t1load.c, src/type1/t1parse.c: Apply.
482
4832015-02-18 Werner Lemberg <wl@gnu.org>
484
Werner Lemberg272e3cd2015-02-18 11:38:46 +0100485 [psaux, type1] Fix minor AFM issues.
486
487 * include/internal/t1types.h (AFM_KernPairRec): Make indices
488 unsigned.
489 Update users.
490 (AFM_FontInfoRec): Make element counters unsigned.
491 Update users.
492 * src/psaux/afmparse.h (AFM_ValueRec): Add union member for unsigned
493 int.
494
495 * src/psaux/afmparse.c (afm_parse_track_kern, afm_parse_kern_pairs):
496 Reject negative values for number of kerning elements.
497
498 * src/type1/t1afm.c, src/tools/test_afm.c: Updated.
499
5002015-02-18 Werner Lemberg <wl@gnu.org>
501
Werner Lemberg6bd7d282015-02-18 09:22:06 +0100502 Don't use `FT_PtrDist' for lengths.
503
504 Use FT_UInt instead.
505
506 * include/internal/psaux.h (PS_Table_FuncsRec, PS_TableRec,
507 T1_DecoderRec): Do it.
508
509 * include/internal/t1types.h (T1_FontRec): Ditto.
510
511 * src/cid/cidload.c (cid_parse_dict): Updated.
512 * src/pfr/pfrload.c (pfr_extra_item_load_font_id): Ditto.
513 * src/psaux/psobjs.c (ps_table_add), src/psaux/psobjs.h: Ditto.
514 * src/type1/t1load.c (parse_blend_axis_types, parse_encoding,
515 parse_chharstrings, parse_dict): Ditto.
516 * src/type42/t42parse.c (t42_parse_encoding, t42_parse_charstrings,
517 t42_parse_dict): Ditto.
518
5192015-02-18 Werner Lemberg <wl@gnu.org>
520
Werner Lemberg6a0ded72015-02-18 08:51:22 +0100521 * src/type1/t1driver.c (t1_ps_get_font_value): Clean up.
522 This handles negative values better, avoiding many casts.
523
Werner Lemberg0a33a392015-02-17 08:03:05 +01005242015-02-17 Werner Lemberg <wl@gnu.org>
525
Werner Lembergd3240c52015-02-17 20:30:36 +0100526 [base] Fix Savannah bug #44284.
527
528 * src/base/ftcalc.c (FT_MulFix): Typos.
529
5302015-02-17 Werner Lemberg <wl@gnu.org>
531
Werner Lemberg1f7a4e12015-02-17 10:17:56 +0100532 [truetype] Finish compiler warning fixes for signedness issues.
533
534 * src/truetype/ttgxvar.c, src/truetype/ttsubpix.c,
535 src/truetype/ttsubpix.h: Apply.
536
5372015-02-17 Werner Lemberg <wl@gnu.org>
538
Werner Lemberg9daea2c2015-02-17 09:27:56 +0100539 * src/truetype/ttsubpix.c: Adding missing `static' keywords.
540
5412015-02-17 Werner Lemberg <wl@gnu.org>
542
Werner Lembergd9c3f152015-02-17 09:21:26 +0100543 [truetype] More signedness fixes.
544
545 * include/internal/tttypes.h, src/truetype/ttinterp.h,
546 src/truetype/ttobjs.h, src/truetype/ttinterp.c,
547 src/truetype/ttobjs.c: Apply.
548
5492015-02-17 Werner Lemberg <wl@gnu.org>
550
Werner Lemberg0a33a392015-02-17 08:03:05 +0100551 [truetype] Various signedness fixes.
552
553 * include/internal/ftgloadr.h, src/truetype/ttpload.c: Apply.
554
555 * src/truetype/ttgload.c: Apply.
556 (TT_Get_VMetrics): Protect against invalid ascenders and descenders
557 while constructing advance height.
558
Werner Lemberg587351b2015-02-16 07:03:22 +01005592015-02-16 Werner Lemberg <wl@gnu.org>
560
Werner Lemberg76abc752015-02-16 22:00:27 +0100561 [base] Finish compiler warning fixes for signedness issues.
562
563 * src/base/ftglyph.c, src/base/ftlcdfil.c, src/base/ftstroke.c:
564 Apply.
565
5662015-02-16 Werner Lemberg <wl@gnu.org>
567
Werner Lemberg10aa8582015-02-16 20:12:54 +0100568 * include/tttables.h (TT_OS2): `fsType' must be FT_UShort.
569
5702015-02-16 Werner Lemberg <wl@gnu.org>
571
Werner Lemberg2e814fc2015-02-16 20:05:08 +0100572 More minor signedness warning fixes.
573
574 * src/base/ftbbox.c, src/base/ftbitmap.c, src/base/fttrigon.c,
575 src/base/ftutil.c: Apply.
576
5772015-02-16 Werner Lemberg <wl@gnu.org>
578
Werner Lemberg82235d02015-02-16 19:35:16 +0100579 Next round of minor compiler warning fixes.
580
581 * include/internal/ftrfork.h (FT_RFork_Ref): Change `offset' member
582 type to `FT_Long'.
583 (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Add `static' keyword.
584
Werner Lemberg3aaebe32015-02-23 08:20:27 +0100585 * include/internal/ftstream.h (FT_Stream_Pos): Return `FT_ULong'.
Werner Lemberg82235d02015-02-16 19:35:16 +0100586
587 * src/base/ftoutln.c, src/base/ftrfork.c, src/base/ftstream.c:
588 Signedess fixes.
589
5902015-02-16 Werner Lemberg <wl@gnu.org>
591
Werner Lemberg3cfa4d12015-02-16 17:59:06 +0100592 Various minor signedness fixes.
593
594 * include/ftadvanc.h, include/internal/ftobjs.h,
595 src/base/ftgloadr.c, src/base/ftobjs.c: Apply.
596
5972015-02-16 Werner Lemberg <wl@gnu.org>
598
Werner Lemberg6f325c22015-02-16 11:31:32 +0100599 New `TYPEOF' macro.
600
601 This helps suppress signedness warnings, avoiding issues with
602 implicit conversion changes.
603
604 * include/config/ftconfig.h, builds/unix/ftconfig.in,
605 builds/vms/ftconfig.h (TYPEOF): Define.
606
607 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
608 src/autofit/afwarp.h (AF_WARPER_FLOOR): Use it.
609
6102015-02-16 Werner Lemberg <wl@gnu.org>
611
Werner Lemberg1f377f02015-02-16 08:37:09 +0100612 * src/base/ftsystem.c: Use casts in standard C function wrappers.
613 (ft_alloc, ft_realloc, ft_ansi_stream_io, FT_Stream_Open): Do it.
614
6152015-02-16 Werner Lemberg <wl@gnu.org>
616
Werner Lemberg0814b802015-02-16 07:29:53 +0100617 Fix Savannah bug #44261.
618
619 * builds/unix/detect.mk (setup) [unix]: Set `CONFIG_SHELL' in the
620 environment also while calling the configure script.
621
6222015-02-16 Werner Lemberg <wl@gnu.org>
623
Werner Lemberg587351b2015-02-16 07:03:22 +0100624 * include/internal/ftmemory.h: Add some `FT_Offset' casts.
625 (FT_MEM_SET, FT_MEM_COPY, FT_MEM_MOVE, FT_ARRAY_ZERO, FT_ARRAY_COPY,
626 FT_MEM_MOVE): Do it.
627
Werner Lemberg6d7d6362015-02-15 12:30:42 +01006282015-02-15 Werner Lemberg <wl@gnu.org>
629
Werner Lemberg48186b82015-02-16 06:37:36 +0100630 [base] Clean up signedness issues in `ftdbgmem.c'.
631
632 Also fix other minor issues.
633
634 * src/base/ftdbgmem.c (FT_MemTableRec): Replace all FT_ULong types
635 with FT_Long for consistency.
636 (ft_mem_primes): Change type to `FT_Int'.
637 (ft_mem_closest_prime, ft_mem_table_set): Updated.
638
639 (ft_mem_debug_panic, ft_mem_debug_alloc, ft_mem_debug_free,
640 ft_mem_debug_realloc): Use `static' keyword and fix signedness
641 warnings where necessary.
642
643 (ft_mem_table_resize, ft_mem_table_new, ft_mem_table_destroy,
644 ft_mem_table_get_nodep, ft_mem_debug_init, FT_DumpMemory): Fix types
645 and add or remove casts to avoid signedness warnings.
646
6472015-02-15 Werner Lemberg <wl@gnu.org>
648
Werner Lemberg6d7d6362015-02-15 12:30:42 +0100649 [base] Clean up signedness in arithmetic functions.
650
651 This makes the code more readable and reduces compiler warnings.
652
653 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round, FT_MulFix,
654 FT_DivFix): Convert input parameters to unsigned, do the
655 computation, then convert the result back to signed.
656 (ft_corner_orientation): Fix casts.
657
Werner Lemberg92359bd2015-02-07 09:47:23 +01006582015-02-07 Werner Lemberg <wl@gnu.org>
659
660 [sfnt] Fix Savannah bug #44184.
661
662 * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir): No
663 longer reject `htmx' and `vmtx' tables with invalid length but
664 sanitize them.
665
Jon Anderson416d8792015-02-06 10:16:45 +01006662015-02-06 Jon Anderson <jon@websupergoo.com>
667
668 [truetype] Fix regression in the incremental glyph loader.
669
670 * src/truetype/ttgload.c (load_truetype_glyph): For incremental
671 fonts, the glyph index may be greater than the number of glyphs
672 indicated, so guard the check with a preprocessor conditional.
673
Werner Lembergb6cb4992015-02-06 08:46:06 +01006742015-02-06 Werner Lemberg <wl@gnu.org>
675
676 [autofit] Fix potential memory leak.
677
678 While this doesn't show up with FreeType, exactly the same code
679 leaks with ttfautohint's modified auto-hinter code (which gets used
680 in a slightly different way).
681
682 It certainly doesn't harm since it is similar to already existing
683 checks in the code for embedded arrays.
684
685 * src/autofit/afhints.c (af_glyph_hints_reload): Set `max_contours'
686 and `max_points' for all cases.
687
Werner Lemberg19146a52015-01-31 11:01:33 +01006882015-01-31 Werner Lemberg <wl@gnu.org>
689
690 [autofit] Add support for Thai script.
691
692 Thanks to Ben Mitchell <ben@rosettatype.com> for guidance with blue
693 zone characters!
694
695 * src/autofit/afblue.dat: Add blue zone data for Thai.
696
697 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
698
699 * src/autofit/afscript.h: Add Thai standard characters.
700
701 * src/autofit/afranges.c: Add Thai data.
702
703 * src/autofit/afstyles.h: Add Thai data.
704
Behdad Esfahbod264b5e42015-01-23 21:23:55 +01007052015-01-23 Behdad Esfahbod <behdad@behdad.org>
706
707 [raster] Handle `FT_RASTER_FLAG_AA' correctly.
708
709 This fixes a breakage caused by the commit `[raster] Remove
710 5-level gray AA mode from monochrome rasterizer.'.
711
Werner Lembergd2c531e2015-01-23 22:37:42 +0100712 Problem reported by Markus Trippelsdorf <markus@trippelsdorf.de>.
Behdad Esfahbod264b5e42015-01-23 21:23:55 +0100713
714 * src/raster/ftraster.c (ft_black_render): Handle
715 `FT_RASTER_FLAG_AA'.
716
717 * src/raster/ftrend1.c (ft_raster1_render): Remove gray AA mode
718 remnants.
719
Werner Lemberg79a5ac62015-01-18 07:30:04 +01007202015-01-18 Werner Lemberg <wl@gnu.org>
721
722 * src/base/ftobjs.c (FT_New_Library): Fix compiler warning.
723
Chris Liddell942aa5f2015-01-18 07:29:48 +01007242015-01-18 Chris Liddell <chris.liddell@artifex.com>
725
726 [raster] Fix Savannah bug #44022.
727
728 Add fallback for glyphs with degenerate bounding boxes.
729
730 If a glyph has only one very narrow feature, the bbox can end up
731 with either the width or height of the bbox being 0, in which case
732 no raster memory is allocated and no attempt is made to render the
733 glyph. This is less than ideal when the drop-out compensation in
734 the rendering code would actually result in the glyph being
735 rendered.
736
737 This problem can be observed with the `I' glyph (gid 47) in the
738 Autodesk RomanS TrueType font.
739
740 * src/raster/ftrend1.c (ft_raster1_render): Add a fallback if either
741 dimension is zero to explicitly round up/down (instead of simply
742 round).
743
Werner Lemberg50be00d2015-01-17 20:38:31 +01007442015-01-17 Werner Lemberg <wl@gnu.org>
745
746 Add some tools to handle yearly copyright notice updates.
747
748 We are now following the GNU guidelines: A new release automatically
749 means that the copyright year of all affected files gets updated; it
750 is no longer used to track years of modification changes.
751
752 * src/tools/update-copyright-year: New Perl script.
753 * src/tools/update-copyright: New shell script that calls
754 `update-copyright-year' on all files.
755 * src/tools/no-copyright: Exceptions that should not be handled by
756 `update-copyright'
757
Werner Lemberg4eff8542015-01-14 20:06:19 +01007582015-01-14 Werner Lemberg <wl@gnu.org>
759
760 * docs/CHANGES: Updated, using a description from Behdad.
761
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +01007622015-01-14 Behdad Esfahbod <behdad@behdad.org>
763
Behdad Esfahbod48c86622015-01-14 19:38:36 +0100764 * src/autofit/afmodule.c (af_autofitter_done): Fix compiler warning.
765
7662015-01-14 Behdad Esfahbod <behdad@behdad.org>
767
Behdad Esfahbod56ddafa2015-01-14 19:36:02 +0100768 [autofit] Add embedded array of segments and edges.
769
770 Avoids multiple mallocs per typical glyphs.
771
772 With this and recent changes to avoid mallocs, the thread-safe
773 stack-based loader is now as fast as the previous model that had one
774 cached singleton.
775
776 * src/autofit/afhints.h (AF_SEGMENTS_EMBEDDED, AF_EDGES_EMBEDDED):
777 New macros.
778 (AF_AxisHintsRec): Add two arrays for segments and edges.
779
780 * src/autofit/afhints.c (af_axis_hints_new_segment): Only allocate
781 data if number of segments exceeds given threshold value.
782 (af_axis_hints_new_edge): Only allocate data if number of edges
783 exceeds given threshold value.
784 (af_glyph_hints_done): Updated.
785
7862015-01-14 Behdad Esfahbod <behdad@behdad.org>
787
Behdad Esfahbod6f16b102015-01-14 19:26:49 +0100788 [autofit] Add embedded arrays for points and contours.
789
790 This avoids at least two malloc calls for typical glyphs.
791
792 * src/autofit/afhints.h (AF_POINTS_EMBEDDED, AF_CONTOURS_EMBEDDED):
793 New macros.
794 (AF_GlyphHintsRec): Add two arrays for contours and points.
795
796 * src/autofit/afhints.c (af_glyph_hints_init, af_glyph_hints_done):
797 Updated.
798 (af_glyph_hints_reload): Only allocate data if number of contours or
799 points exceeds given threshold values.
800
8012015-01-14 Behdad Esfahbod <behdad@behdad.org>
802
Behdad Esfahbodc2733652015-01-14 19:16:12 +0100803 [autofit] Allocate hints object on the stack.
804
805 This avoids one malloc per load.
806
807 * src/autofit/afloader.h (AF_LoaderRec): Change type of `hints' to
808 `AF_GlyphHints'.
809 Update prototype.
810
811 * src/autofit/afloader.c (af_loader_init): Use `AF_GlyphHints'
812 parameter instead of `FT_Memory'.
813 (af_loader_done): Directly reset `load_hints'.
814 (af_loader_load_g): Updated.
815
816 * src/autofit/afmodule.c (af_autofitter_load_glyph): Use local
817 `hints' object.
818
8192015-01-14 Behdad Esfahbod <behdad@behdad.org>
820
Behdad Esfahboda4117fb2015-01-14 19:07:54 +0100821 [autofit] Reuse slot glyph loader.
822
823 No need to create a new glyph loader; we can reuse the one from
824 `slot->internal->loader'. It's hard to tell why it was written that
825 way originally, but new code looks sound and correct to me, and
826 avoids lots of allocations.
827
828 * src/autofit/afloader.c (af_loader_init): Change return type to
829 `void'.
830 Don't call `FT_GlyphLoader_New'.
831 (af_loader_reset): Don't call `FT_GlyphLoader_Rewind'.
832 (af_loader_load_g): Update code to use `internal->loader', which
833 doesn't need copying of data.
834
835 * src/autofit/afloader.h (AF_LoaderRec): Remove `gloader' member.
836 Update prototype.
837
838 * src/autofit/afmodule.c (af_autofitter_load_glyph): Updated.
839
8402015-01-14 Behdad Esfahbod <behdad@behdad.org>
841
Behdad Esfahbodae6699f2015-01-14 18:55:39 +0100842 [autofit] Remove (unused) support for composite glyphs.
843
844 We never have to deal with composite glyphs in the autohinter, as
845 those will be loaded into FORMAT_OUTLINE by the recursed
846 `FT_Load_Glyph' function.
847
848 In the rare cases that FT_LOAD_NO_RECURSE is set, it will imply
849 FT_LOAD_NO_SCALE as per `FT_Load_Glyph', which then implies
850 FT_LOAD_NO_HINTING:
851
852 /* resolve load flags dependencies */
853
854 if ( load_flags & FT_LOAD_NO_RECURSE )
855 load_flags |= FT_LOAD_NO_SCALE |
856 FT_LOAD_IGNORE_TRANSFORM;
857
858 if ( load_flags & FT_LOAD_NO_SCALE )
859 {
860 load_flags |= FT_LOAD_NO_HINTING |
861 FT_LOAD_NO_BITMAP;
862
863 load_flags &= ~FT_LOAD_RENDER;
864 }
865
866 and as such the auto-hinter is never called. Thus, the recursion in
867 `af_loader_load_g' never actually happens. So remove the depth
868 counter as well.
869
870 * src/autofit/afloader.c (af_loader_load_g): Remove `depth'
871 parameter.
872 <FT_GLYPH_FORMAT_COMPOSITE>: Remove associated code.
873 (af_loader_load_glyph): Updated.
874
8752015-01-14 Behdad Esfahbod <behdad@behdad.org>
876
Behdad Esfahbodc242fe42015-01-14 18:48:14 +0100877 [raster] Fix uninitialized memory access.
878
879 Apparently `ras.cProfile' might be uninitialized. This will be the
880 case if `ras.top == ras.cProfile->offset', as can be seen in
881 `End_Profile'. The overshoot code introduced in a change `Fix B/W
882 rasterization of subglyphs with different drop-out modes.' (from
883 2009-06-18) violated this, accessing `ras.cProfile->flags'
884 unconditionally just before calling `End_Profile' (which then
885 detected that `cProfile' is uninitialized and didn't touch it).
886
887 This was harmless, and was not detected by valgrind before because
888 the objects were allocated on the `raster_pool', which was always
889 initialized. With recent change to allocate raster buffers on the
890 stack, valgrind now reported this invalid access.
891
892 * src/raster/ftraster.c (Convert_Glyph): Don't access an
893 uninitialized `cProfile'.
894
8952015-01-14 Behdad Esfahbod <behdad@behdad.org>
896
Behdad Esfahbodb2ba6862015-01-14 18:43:13 +0100897 [smooth] Fix uninitialized memory access.
898
899 Looks like `ras.span_y' could always be used without initialization.
900 This was never detected by valgrind before because the library-wide
901 `raster_pool' was used for the worker object and `raster_pool' was
902 originally zero'ed. But subsequent reuses of it were using `span_y'
903 uninitialized. With the recent change to not use `render_pool' and
904 allocate worker and buffer on the stack, valgrind now detects this
905 uninitialized access.
906
907 * src/smooth/ftgrays.c (gray_raster_render): Initialize
908 `ras.span_y'.
909
9102015-01-14 Behdad Esfahbod <behdad@behdad.org>
911
Behdad Esfahbod603292d2015-01-14 18:35:56 +0100912 [base] Don't initialize unused `driver->glyph_loader'.
913
914 * src/base/ftobjs.c (Destroy_Driver): Don't call
915 `FT_GlyphLoader_Done'.
916 (FT_Add_Module): Don't call `FT_GlyphLoader_New'.
917
9182015-01-14 Behdad Esfahbod <behdad@behdad.org>
919
Behdad Esfahbod51634252015-01-14 18:30:59 +0100920 [base] Don't allocate `library->raster_pool' anymore.
921
922 It's unused after the following commits:
923
924 [raster] Allocate render pool for mono rasterizer on the stack.
925 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
926
927 The value of FT_RENDER_POOL_SIZE still serves the purpose it used to
928 serve, which is, to adjust the pool size. But the pool is now
929 allocated on the stack on demand.
930
931 * src/base/ftobjs.c (FT_New_Library, FT_Done_Library): Implement.
932
9332015-01-14 Behdad Esfahbod <behdad@behdad.org>
934
Behdad Esfahbod6dfdaf42015-01-14 18:21:13 +0100935 [base] Do not reorder library->renderers upon use.
936
937 Instead of keeping `library->renderers' in a MRU order, just leave
938 it as-is. The MRU machinery wasn't thread-safe.
939
940 With this patch, rasterizing glyphs from different faces from
941 different threads doesn't fail choosing rasterizer
942 (FT_Err_Cannot_Render_Glyph).
943
944 Easiest to see that crash was to add a `printf' (or otherwise let
945 thread yield in FT_Throw with debugging enabled).
946
947 * src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c
948 (FT_Outline_Render): Don't call `FT_Set_Renderer'.
949
9502015-01-14 Behdad Esfahbod <behdad@behdad.org>
951
Behdad Esfahboda773c302015-01-14 18:16:20 +0100952 [raster] Allocate render pool for mono rasterizer on the stack.
953
954 Instead of using the `render_pool' member of `FT_Library' that is
955 provided down to the rasterizer, completely ignore that and allocate
956 needed objects on the stack instead.
957
958 With this patch, rasterizing glyphs from different faces from
959 different threads doesn't crash in the monochrome rasterizer.
960
961 * src/raster/ftraster.c (black_TRaster): Remove `buffer',
962 `buffer_size', and `worker' members.
963
964 (ft_black_render): Create `buffer' locally.
965 (ft_black_reset): Updated.
966
9672015-01-14 Behdad Esfahbod <behdad@behdad.org>
968
Behdad Esfahbod8dc86352015-01-14 18:06:22 +0100969 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
970
971 It was off by default and couldn't be turned on at runtime. And the
972 smooth rasterizer superceded it over ten years ago. No point in
973 keeping. Comments suggested that it was there for compatibility
974 with FreeType 1.
975
976 550 lines down.
977
978 * src/raster/ftraster.c (FT_RASTER_OPTION_ANTI_ALIASING,
979 RASTER_GRAY_LINES): Remove macros and all associated code.
980
981 (black_TWorker): Remove `gray_min_x' and `gray_max_x'.
982 (black_TRaster): Remove `grays' and `gray_width'.
983
984 (Vertical_Sweep_Init, Vertical_Sweep_Span, Vertical_Sweep_Drop,
985 ft_black_render): Updated.
986
987 * src/raster/ftrend1.c (ft_raster1_render): Simplify code.
988 (ft_raster5_renderer_class): Removed.
989
9902015-01-14 Behdad Esfahbod <behdad@behdad.org>
991
Behdad Esfahbod747ae2c2015-01-14 17:54:26 +0100992 [smooth] Allocate render pool for smooth rasterizer on the stack.
993
994 Instead of using the `render_pool' member of `FT_Library' that is
995 provided down to the rasterizer, completely ignore that and allocate
996 needed objects on the stack instead.
997
998 With this patch, rasterizing glyphs from different faces from
999 different threads doesn't crash in the smooth rasterizer.
1000
1001 Bugs:
1002
1003 https://bugzilla.redhat.com/show_bug.cgi?id=678397
1004 https://bugzilla.redhat.com/show_bug.cgi?id=1004315
1005 https://bugzilla.redhat.com/show_bug.cgi?id=1165471
1006 https://bugs.freedesktop.org/show_bug.cgi?id=69034
1007
1008 * src/smooth/ftgrays.c (gray_TRaster): Remove `buffer',
1009 `buffer_size', `band_size', and `worker' members.
1010
1011 (gray_raster_render): Create `buffer', `buffer_size', and
1012 `band_size' locally.
1013 (gray_raster_reset): Updated.
1014
10152015-01-14 Behdad Esfahbod <behdad@behdad.org>
1016
Behdad Esfahbod531d4632015-01-14 17:46:55 +01001017 [truetype] Allocate TT_ExecContext in TT_Size instead of TT_Driver.
1018
1019 Previously the code had stipulation for using a per-TT_Size exec
1020 context if `size->debug' was true. But there was no way that
1021 `size->debug' could *ever* be true. As such, the code was always
1022 using the singleton `TT_ExecContext' that was stored in `TT_Driver'.
1023 This was, clearly, not threadsafe.
1024
1025 With this patch, loading glyphs from different faces from different
1026 threads doesn't crash in the bytecode loader code.
1027
1028 * src/truetype/ttobjs.h (TT_SizeRec): Remove `debug' member.
1029 (TT_DriverRec): Remove `context' member.
1030
1031 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Remove
1032 `TT_ExecContext' code related to a global `TT_Driver' object.
1033
1034 (tt_driver_done): Don't remove `TT_ExecContext' object here but ...
1035 (tt_size_done_bytecode): ... here.
1036
1037 (tt_driver_init): Don't create `TT_ExecContext' object here but ...
1038 (tt_size_init_bytecode): ... here, only on demand.
1039
1040 * src/truetype/ttinterp.c (TT_Run_Context): Remove defunct debug
1041 code.
1042 (TT_New_Context): Remove `TT_ExecContext' code related to a global
1043 `TT_Driver' object.
1044
1045 * src/truetype/ttinterp.h: Updated.
1046
1047 * src/truetype/ttgload.c (TT_Hint_Glyph, tt_loader_init): Updated.
1048
10492015-01-14 Behdad Esfahbod <behdad@behdad.org>
1050
Behdad Esfahbod89bc8d42015-01-14 16:01:19 +01001051 [autofit] Allocate AF_Loader on the stack instead of AF_Module.
1052
1053 Stop sharing a global `AF_Loader'. Allocate one on the stack during
1054 glyph load.
1055
1056 Right now this results in about 25% slowdown, to be fixed in a
1057 following commit.
1058
1059 With this patch loading glyphs from different faces from different
1060 threads doesn't immediately crash in the autohinting loader code.
1061
1062 Bugs:
1063
1064 https://bugzilla.redhat.com/show_bug.cgi?id=1164941
1065
1066 * src/autofit/afloader.c (af_loader_init): Pass
1067 `AF_Loader' and `FT_Memory' instead of `AF_Module' as arguments.
1068 (af_loader_reset, af_loader_load_glyph): Also pass `loader' as
1069 argument.
1070 (af_loader_done): Use `AF_Loader' instead of `AF_Module' as
1071 argument.
1072
1073 * src/autofit/afmodule.c (af_autofitter_init): Don't call
1074 `af_loader_init'.
1075 (af_autofitter_done): Don't call `af_loader_done'.
1076 (af_autofitter_load_glyph): Use a local `AF_Loader' object.
1077
1078 * src/autofit/afloader.h: Include `afmodule.h'.
1079 Update prototypes.
1080 Move typedef for `AF_Module' to...
1081
1082 * src/autofit/afmodule.h: ... this place.
1083 No longer include `afloader.h'.
1084
10852015-01-14 Behdad Esfahbod <behdad@behdad.org>
1086
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +01001087 * src/type42/t42objs.h (T42_DriverRec): Remove unused member.
1088
Werner Lemberg36d03c92015-01-12 11:26:30 +010010892015-01-12 Werner Lemberg <wl@gnu.org>
1090
1091 Fix Savannah bug #43976.
1092
1093 Assure that FreeType's internal include directories are found before
1094 `CPPFLAGS' (which might be set by the user in the environment), and
1095 `CPPFLAGS' before `CFLAGS'.
1096
1097 * builds/freetype.mk (FT_CFLAGS): Don't add `INCLUDE_FLAGS'.
1098 (FT_COMPILE): Make this a special variable for compiling only the
1099 files handled in `freetype.mk'.
1100 (.c.$O): Removed, unused.
1101
1102 * src/*/rules.mk (*_COMPILE): Fix order of include directories.
1103
Werner Lembergd03a67a2015-01-11 08:39:14 +010011042015-01-11 Werner Lemberg <wl@gnu.org>
1105
Werner Lemberg95b57052015-01-11 09:50:49 +01001106 [truetype] Prettyfing.
1107
1108 * src/truetype/ttinterp.c (project, dualproj, fast_project,
1109 fast_dualproj): Rename to...
1110 (PROJECT, DUALPROJ, FAST_PROJECT, FAST_DUALPROJ): ... this.
1111
11122015-01-11 Werner Lemberg <wl@gnu.org>
1113
Werner Lembergea173c02015-01-11 08:58:54 +01001114 * src/truetype/ttinterp.c (Ins_JROT, Ins_JROF): Simplify.
1115
1116 Based on a patch from Behdad.
1117
11182015-01-11 Werner Lemberg <wl@gnu.org>
1119
Werner Lemberg628578c2015-01-11 08:53:31 +01001120 * src/truetype/ttinterp.c (Ins_SxVTL): Simplify function call.
1121
11222015-01-11 Werner Lemberg <wl@gnu.org>
1123
Werner Lemberg08e79092015-01-11 08:45:50 +01001124 * src/truetype/ttinterp.c (Normalize): Remove unused argument.
1125
11262015-01-11 Werner Lemberg <wl@gnu.org>
1127
Werner Lembergd03a67a2015-01-11 08:39:14 +01001128 [truetype] More macro expansions.
1129
Werner Lemberg4aaadf42015-01-11 08:42:28 +01001130 * src/truetype/ttinterp.c (FT_UNUSED_EXEC): Remove macro by
1131 expansion.
1132
11332015-01-11 Werner Lemberg <wl@gnu.org>
1134
1135 [truetype] More macro expansions.
1136
Werner Lembergd03a67a2015-01-11 08:39:14 +01001137 * src/truetype/ttinterp.c (INS_ARG): Remove macro by expansion,
1138 adjusting funtion calls where necessary.
1139 (FT_UNUSED_ARG): Removed, no longer needed.
1140
Werner Lemberg1b4d68c2015-01-10 19:56:28 +010011412015-01-10 Werner Lemberg <wl@gnu.org>
1142
Werner Lembergeb341362015-01-11 00:23:27 +01001143 [truetype] More macro expansions.
1144
1145 Based on a patch from Behdad.
1146
1147 * src/truetype/ttinterp.c (DO_*): Expand macros into corresponding
1148 `Ins_*' functions.
1149 (TT_RunIns): Replace `DO_*' macros with `Ins_*' function calls.
1150 (ARRAY_BOUND_ERROR): Remove second definition, which is no longer
1151 needed.
1152 (Ins_SVTCA, Ins_SPVTCA, Ins_SFVTCA): Replaced with...
1153 (Ins_SxyTCA): New function.
1154
11552015-01-10 Werner Lemberg <wl@gnu.org>
1156
Werner Lemberg01be1302015-01-10 23:05:37 +01001157 [truetype] Remove TT_CONFIG_OPTION_INTERPRETER_SWITCH.
1158
1159 Behdad suggested this code simplification, and nobody objected...
1160
1161 * include/config/ftoption.h, devel/ftoption.h
1162 (TT_CONFIG_OPTION_INTERPRETER_SWITCH): Remove.
1163
1164 * src/truetype/ttinterp.c [TT_CONFIG_OPTION_INTERPRETER_SWITCH]:
1165 Remove related code.
1166 (ARRAY_BOUND_ERROR): Use do-while loop.
1167
11682015-01-10 Werner Lemberg <wl@gnu.org>
1169
Werner Lembergfae0c812015-01-10 20:23:10 +01001170 [truetype] More macro expansions.
1171
Werner Lemberg6cc1f122015-01-10 21:56:59 +01001172 * src/truetype/ttinterp.c, src/truetype/ttinterp.h (EXEC_ARG_,
1173 EXEC_ARG): Remove by replacing with expansion.
1174
11752015-01-10 Werner Lemberg <wl@gnu.org>
1176
1177 [truetype] More macro expansions.
1178
Werner Lemberg24681452015-01-10 21:53:48 +01001179 Based on a patch from Behdad.
1180
1181 * src/truetype/ttinterp.c (SKIP_Code, GET_ShortIns, NORMalize,
1182 SET_SuperRound, ROUND_None, INS_Goto_CodeRange, CUR_Func_move,
1183 CUR_Func_move_orig, CUR_Func_round, CUR_Func_cur_ppem,
1184 CUR_Func_read_cvt, CUR_Func_write_cvt, CUR_Func_move_cvt,
1185 CURRENT_Ratio, INS_SxVTL, COMPUTE_Funcs, COMPUTE_Round,
1186 COMPUTE_Point_Displacement, MOVE_Zp2_Point): Remove by replacing
1187 with expansion.
1188
1189 (Cur_Func_project, CUR_Func_dualproj, CUR_fast_project,
1190 CUR_fast_dualproj): Replace with macros `project', `dualproj',
1191 `fast_project', `fast_dualproj'.
1192
11932015-01-10 Werner Lemberg <wl@gnu.org>
1194
1195 [truetype] More macro expansions.
1196
Werner Lembergfae0c812015-01-10 20:23:10 +01001197 * src/truetype/ttinterp.c (EXEC_OP_, EXEC_OP): Remove by replacing
1198 with expansion.
1199
12002015-01-10 Werner Lemberg <wl@gnu.org>
1201
Werner Lemberg5a752f32015-01-10 20:08:35 +01001202 [truetype] Remove code for static TrueType interpreter.
1203
1204 This is a follow-up patch.
1205
1206 * src/truetype/ttinterp.c, src/truetype/ttinterp.h
1207 [TT_CONFIG_OPTION_STATIC_INTERPRETER,
1208 TT_CONFIG_OPTION_STATIC_RASTER]: Remove macros and related code.
1209
12102015-01-10 Werner Lemberg <wl@gnu.org>
1211
Werner Lemberg1b4d68c2015-01-10 19:56:28 +01001212 * src/truetype/ttinterp.c (CUR): Remove by replacing with expansion.
1213
1214 This starts a series of patches that simplifies the code of the
1215 bytecode interpreter.
1216
Werner Lemberg232bd942014-12-30 21:44:51 +010012172014-12-30 Werner Lemberg <wl@gnu.org>
1218
1219 * Version 2.5.5 released.
1220 =========================
1221
1222
1223 Tag sources with `VER-2-5-5'.
1224
1225 * docs/VERSION.DLL: Update documentation and bump version number to
1226 2.5.5.
1227
1228 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
1229 builds/windows/vc2005/index.html,
1230 builds/windows/vc2008/freetype.vcproj,
1231 builds/windows/vc2008/index.html,
1232 builds/windows/vc2010/freetype.vcxproj,
1233 builds/windows/vc2010/index.html,
1234 builds/windows/visualc/freetype.dsp,
1235 builds/windows/visualc/freetype.vcproj,
1236 builds/windows/visualc/index.html,
1237 builds/windows/visualce/freetype.dsp,
1238 builds/windows/visualce/freetype.vcproj,
1239 builds/windows/visualce/index.html,
1240 builds/wince/vc2005-ce/freetype.vcproj,
1241 builds/wince/vc2005-ce/index.html,
1242 builds/wince/vc2008-ce/freetype.vcproj,
1243 builds/wince/vc2008-ce/index.html: s/2.5.4/2.5.5/, s/254/255/.
1244
1245 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 5.
1246
1247 * builds/unix/configure.raw (version_info): Set to 17:4:11.
1248 * CMakeLists.txt (VERSION_PATCH): Set to 5.
1249 * docs/CHANGES: Updated.
1250
1251 * builds/toplevel.mk (dist): Fix typos.
1252
Alexei Podtelezhnikov70241552014-12-24 12:11:46 -050012532014-12-24 Alexei Podtelezhnikov <apodtele@gmail.com>
1254
1255 [base] Formatting and nanooptimizations.
1256
1257 * src/base/ftcalc.c,
1258 * src/base/fttrigon.c: Revise sign restoration.
1259
Werner Lemberg06842c72014-12-13 07:42:51 +010012602014-12-13 Werner Lemberg <wl@gnu.org>
1261
1262 * src/pcf/pcfread.c (pcf_read_TOC): Improve fix from 2014-12-08.
1263
Werner Lembergb9438112014-12-11 13:33:14 +010012642014-12-11 Werner Lemberg <wl@gnu.org>
1265
Werner Lemberg82119502014-12-11 22:27:06 +01001266 * builds/toplevel.mk (dist): Use older POSIX standard for `tar'.
1267
1268 Apparently, BSD tar isn't capable yet of handling POSIX-1.2001
1269 (contrary to GNU tar), so force the POSIX-1.1988 format.
1270
1271 Problem reported by Stephen Fisher <sfisher@SDF.ORG>.
1272
12732014-12-11 Werner Lemberg <wl@gnu.org>
1274
Werner Lemberg812ed342014-12-11 14:07:29 +01001275 * src/type42/t42parse.c (t42_parse_sfnts): Reject invalid TTF size.
1276
12772014-12-11 Werner Lemberg <wl@gnu.org>
1278
Werner Lembergc9ca6ff2014-12-11 13:39:39 +01001279 * src/base/ftobjs.c (FT_Get_Glyph_Name): Fix off-by-one check.
1280
1281 Problem reported by Dennis Felsing <dennis@felsin9.de>.
1282
12832014-12-11 Werner Lemberg <wl@gnu.org>
1284
Werner Lembergb9438112014-12-11 13:33:14 +01001285 * src/type42/t42parse.c (t42_parse_sfnts): Check `string_size'.
1286
1287 Problem reported by Dennis Felsing <dennis@felsin9.de>.
1288
suzuki toshiya2b592822014-12-10 00:27:41 +090012892014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1290
suzuki toshiya9bd1e552014-12-09 14:51:52 +09001291 [gxvalid] Fix a naming convention conflicting with ftvalid.
1292
1293 See previous changeset for otvalid.
1294
1295 * src/gxvalid/{gxvcommn.h, gxvmort.h, gxvmorx.h}: Replace
1296 `valid' by `gxvalid'.
1297 * src/gxvalid/{gxvbsln.c, gxvcommn.c, gxvfeat.c, gxvjust.c,
1298 gxvkern.c, gxvlcar.c, gxvmort.c, gxvmort0.c, gxvmort1.c,
1299 gxvmort2.c, gxvmort4.c, gxvmort5.c, gxvmorx.c, gxvmorx0.c,
1300 gxvmorx1.c, gxvmorx2.c, gxvmorx4.c, gxvmorx5.c, gxvopbd.c,
1301 gxvprop.c, gxvtrak.c}: Replace `valid' by `gxvalid' if
1302 it is typed as GXV_Validator.
1303
13042014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1305
suzuki toshiya51abdf62014-12-09 00:58:04 +09001306 [otvalid] Fix a naming convention conflicting with ftvalid.
1307
1308 Some prototypes in ftvalid.h use `valid' for the variables
1309 typed as FT_Validator. Their implementations in src/base/
1310 ftobjs.c and utilizations in src/sfnt/ttcmap.c do similar.
1311
1312 Some macros in otvcommn.h assume the exist of the variable
1313 `valid' typed as OTV_Validator in the caller.
1314
1315 Mixing these two conventions cause invalid pointer conversion
1316 and unexpected SEGV in longjmp. To prevent it, all variables
1317 typed as OTV_Validator are renamed to `otvalid'.
1318
1319 * src/otvalid/otvcommn.h: Replace `valid' by `otvalid'.
1320 * src/otvalid/{otvcommn.c, otvbase.c, otvgdef.c, otvgpos.c,
1321 otvgsub.c, otvjstf.c, otvmath.c}: Replace `valid' by `otvalid'
1322 if it is typed as OTV_Validator.
1323
13242014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1325
suzuki toshiya2b592822014-12-10 00:27:41 +09001326 [ftvalid] Introduce FT_THROW() in FT_INVALID_XXX macros.
1327
1328 Original patch is designed by Werner Lemberg. Extra part
1329 for otvalid and gxvalid are added by suzuki toshiya, see
1330 discussion:
1331 http://lists.nongnu.org/archive/html/freetype-devel/2014-12/msg00002.html
1332 http://lists.nongnu.org/archive/html/freetype-devel/2014-12/msg00007.html
1333
1334 * include/internal/ftvalid.h: Introduce FT_THROW() in FT_INVALID_().
1335 * src/gxvalid/gxvcommn.h: Ditto.
1336 * src/otvalid/otvcommn.h: Ditto.
1337
Werner Lemberg74af85c2014-12-08 16:01:50 +010013382014-12-08 Werner Lemberg <wl@gnu.org>
1339
1340 [pcf] Fix Savannah bug #43774.
1341
1342 Work around `features' of X11's `pcfWriteFont' and `pcfReadFont'
1343 functions. Since the PCF format doesn't have an official
1344 specification, we have to exactly follow these functions' behaviour.
1345
1346 The problem was unveiled with a patch from 2014-11-06, fixing issue
1347 #43547.
1348
1349 * src/pcf/pcfread.c (pcf_read_TOC): Don't check table size for last
1350 element. Instead, assign real size.
1351
Werner Lemberg66883b52014-12-07 09:17:06 +010013522014-12-07 Werner Lemberg <wl@gnu.org>
1353
Werner Lemberg553c9672014-12-07 19:29:52 +01001354 Work around a bug in Borland's C++ compiler.
1355
1356 See
1357
1358 http://qc.embarcadero.com/wc/qcmain.aspx?d=118998
1359
1360 for Borland's bug tracker entry.
1361
1362 Reported by Yuliana Zigangirova <zigangirova@inbox.ru>,
1363 http://lists.gnu.org/archive/html/freetype-devel/2014-04/msg00001.html.
1364
1365 * include/internal/ftvalid.h (FT_ValidatorRec), src/smooth/ftgrays.c
1366 (gray_TWorker_): Move `ft_jmp_buf' field to be the first element.
1367
13682014-12-07 Werner Lemberg <wl@gnu.org>
1369
Werner Lemberg9870d6d2014-12-07 09:40:47 +01001370 */*: Decorate hex constants with `U' and `L' where appropriate.
1371
13722014-12-07 Werner Lemberg <wl@gnu.org>
1373
Werner Lemberg66883b52014-12-07 09:17:06 +01001374 [truetype] Prevent memory leak for buggy fonts.
1375
1376 * src/truetype/ttobjs.c (tt_size_done): Unconditionally call
1377 `tt_size_done_bytecode'.
1378
Werner Lemberg94926682014-12-06 07:11:44 +010013792014-12-06 Werner Lemberg <wl@gnu.org>
1380
1381 * Version 2.5.4 released.
1382 =========================
1383
1384
1385 Tag sources with `VER-2-5-4'.
1386
1387 * docs/VERSION.DLL: Update documentation and bump version number to
1388 2.5.4.
1389
1390 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
1391 builds/windows/vc2005/index.html,
1392 builds/windows/vc2008/freetype.vcproj,
1393 builds/windows/vc2008/index.html,
1394 builds/windows/vc2010/freetype.vcxproj,
1395 builds/windows/vc2010/index.html,
1396 builds/windows/visualc/freetype.dsp,
1397 builds/windows/visualc/freetype.vcproj,
1398 builds/windows/visualc/index.html,
1399 builds/windows/visualce/freetype.dsp,
1400 builds/windows/visualce/freetype.vcproj,
1401 builds/windows/visualce/index.html,
1402 builds/wince/vc2005-ce/freetype.vcproj,
1403 builds/wince/vc2005-ce/index.html,
1404 builds/wince/vc2008-ce/freetype.vcproj,
1405 builds/wince/vc2008-ce/index.html: s/2.5.3/2.5.4/, s/253/254/.
1406
1407 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 4.
1408
1409 * builds/unix/configure.raw (version_info): Set to 17:3:11.
1410 * CMakeLists.txt (VERSION_PATCH): Set to 4.
1411 * docs/CHANGES: Updated.
1412
Werner Lemberg934ef382014-12-04 06:38:51 +010014132014-12-04 Werner Lemberg <wl@gnu.org>
1414
1415 docs/CHANGES: Updated, formatted.
1416
Dave Arnold2cdc4562014-12-04 06:10:16 +010014172014-12-04 Dave Arnold <darnold@adobe.com>
1418
Dave Arnoldf89396c2014-12-04 06:17:26 +01001419 [cff] Modify an FT_ASSERT.
1420
1421 * src/cff/cf2hints.c (cf2_hintmap_map): After the fix for Savannah
1422 bug #43661, the test font `...aspartam.otf' still triggers an
1423 FT_ASSERT. Since hintmap still works with count==0, ...
1424 (cf2_glyphpath_lineTo, cf2_glyphpath_curveTo): ... add that term to
1425 suppress the assert.
1426
14272014-12-04 Dave Arnold <darnold@adobe.com>
1428
Dave Arnold2cdc4562014-12-04 06:10:16 +01001429 [cff] Fix Savannah bug #43661.
1430
1431 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdHSTEM,
1432 cf2_cmdVSTEM, cf2_cmdHINTMASK>: Don't append to stem arrays after
1433 hintmask is constructed.
1434
1435 * src/cff/cf2hints.c (cf2_hintmap_build): Add defensive code to
1436 avoid reading past end of hintmask.
1437
Werner Lemberg16188eb2014-12-03 10:18:34 +010014382014-12-03 Werner Lemberg <wl@gnu.org>
1439
Werner Lemberg8fa69a82014-12-03 20:07:14 +01001440 docs/CHANGES: Updated.
1441
14422014-12-03 Werner Lemberg <wl@gnu.org>
1443
Werner Lemberga632b5f2014-12-03 19:30:44 +01001444 [autofit] Better fix for conversion specifiers in debug messages.
1445
1446 Using `%ld' for pointer differences causes warnings on 32bit
1447 platforms. The correct type would be (the relatively new) `%td',
1448 however, this is missing on some important platforms.
1449
1450 This patch improves the change from 2014-11-28.
1451
1452 * src/autofit/afhints.c (AF_INDEX_NUM): Use `int' typecast. Our
1453 pointer differences are always sufficiently small.
1454 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
1455 af_glyph_hints_dump_edge): Revert to `%d' and use `AF_INDEX_NUM'.
1456
14572014-12-03 Werner Lemberg <wl@gnu.org>
1458
Werner Lemberg16188eb2014-12-03 10:18:34 +01001459 FT_Sfnt_Tag: s/ft_sfnt_xxx/FT_SFNT_XXX/ for orthogonality.
1460
1461 All public FreeType enumeration and flag values are uppercase...
1462
1463 * include/tttables.h (FT_Sfnt_Tag): Implement it. For backwards
1464 compatilibity, retain the old values as macros.
1465
1466 * src/base/ftfstype.c (FT_Get_FSType_Flags), src/sfnt/sfdriver.c
1467 (get_sfnt_table): Updated.
1468
Werner Lemberg2af25ac2014-12-02 08:38:57 +010014692014-12-02 Werner Lemberg <wl@gnu.org>
1470
Werner Lembergde43ace2014-12-02 23:06:04 +01001471 * include/*: Improve structure of documentation.
1472
1473 . Add and update many `<Order>' tags.
1474 . Apply various documentation fixes.
1475 . Remove details to deprecated (or never implemented) data.
1476
14772014-12-02 Werner Lemberg <wl@gnu.org>
1478
Werner Lembergca1f5cc2014-12-02 22:49:25 +01001479 [docmaker] Always handle `<Order>' section elements.
1480
1481 Previously, those elements were handled only for sections present in
1482 a `<Sections>' chapter element.
1483
1484 * src/tools/docmaker/content.py (ContentProcessor::finish):
1485 Implement it.
1486
14872014-12-02 Werner Lemberg <wl@gnu.org>
1488
Werner Lembergef6a3522014-12-02 21:16:59 +01001489 [docmaker] Properly handle empty rows in Synopsis.
1490
1491 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Emit
1492 `&nbsp;' for empty fields.
1493
14942014-12-02 Werner Lemberg <wl@gnu.org>
1495
Werner Lemberg0e96f052014-12-02 11:08:31 +01001496 [docmaker] Thinko.
1497
1498 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
1499 Emit `/empty/' string for first element also.
1500
15012014-12-02 Werner Lemberg <wl@gnu.org>
1502
Werner Lemberg102d4a72014-12-02 10:27:40 +01001503 [docmaker] Honour empty lines in `<Order>' section element.
1504
1505 This greatly improves the readability of the `Synopsis' links.
1506
1507 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
1508 Insert string `/empty/' between items.
1509
1510 * src/tools/docmaker/formatter.py (Formatter::section_dump): Make it
1511 robust against nonexistent keys.
1512
1513 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Emit
1514 empty <td> elements for `/empty/'.
1515
15162014-12-02 Werner Lemberg <wl@gnu.org>
1517
Werner Lemberg2af25ac2014-12-02 08:38:57 +01001518 [docmaker] Ensure Python 3 compatibility.
1519
1520 * src/tools/docmaker/content.py (ContentProcessor::set_section,
1521 ContentProcessor::finish): Replace `has_key' function with `in'
1522 keyword.
1523
1524 * src/tools/docmaker/formatter.py (Formatter::__init__): Replace
1525 sorting function with a key generator.
1526 (Formatter::add_identifier): Replace `has_key' function with `in'
1527 keyword.
1528
1529 * src/tools/docmaker/tohtml.py (HtmlFormatter::html_source_quote):
1530 Replace `has_key' function with `in' keyword.
1531 (HtmlFormatter::index_exit, HtmlFormatter::section_enter): Use
1532 integer division.
1533 s/<>/>/.
1534
1535 * src/tools/docmaker/utils.py: Import `itertools'.
1536 (index_sort): Replaced by...
1537 (index_key): ... this new key generator (doing exactly the same).
1538
Werner Lemberg8f795112014-11-29 06:49:15 +010015392014-11-29 Werner Lemberg <wl@gnu.org>
1540
Werner Lemberg80bfeb12014-12-01 10:07:52 +01001541 [docmaker] Don't output a block multiple times.
1542
1543 This bug was hidden by not processing all lines of `<Order>' blocks.
1544
1545 * src/tools/docmaker/formatter.py (Formatter::section_dump): Filter
1546 out field names.
1547
15482014-11-29 Werner Lemberg <wl@gnu.org>
1549
Werner Lemberg0dbad762014-12-01 08:44:48 +01001550 [docmaker] Use field values as HTML link targets where possible.
1551
1552 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_block_url):
1553 Accept second, optional argument to specify a name.
1554 (HtmlFormatter::html_source_quote): Link to field ID if possible.
1555 (HtmlFormatter::print_html_field_list): Emit `id' attribute.
1556
15572014-11-29 Werner Lemberg <wl@gnu.org>
1558
Werner Lemberg785b1d02014-11-30 22:16:34 +01001559 [docmaker] Allow empty lines in `<Order>' blocks.
1560
1561 Before this patch, the suggested order of entries stopped at the
1562 first empty line.
1563
1564 Obviously, nobody noticed that this problem caused a much reduced
1565 set of links in the `Synopsis' sections; in particular, the
1566 `<Order>' blocks contain a lot of entries that wouldn't be listed
1567 otherwise...
1568
1569 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
1570 New function to iterate over all items.
1571 (DocSection::process): Use it.
1572
15732014-11-29 Werner Lemberg <wl@gnu.org>
1574
Werner Lemberg16b3e622014-11-30 20:58:27 +01001575 * src/tools/docmaker/sources.py (column) [Format 2]: Fix regexp.
1576
1577 After the single asterisk there must be no other immediately following
1578 asterisk.
1579
15802014-11-29 Werner Lemberg <wl@gnu.org>
1581
Werner Lemberg434bc692014-11-29 23:12:55 +01001582 * src/tools/docmaker/tohtml.py: Improve CSS for vertical spacing.
Werner Lemberg51987ea2014-11-29 22:19:29 +01001583
Werner Lemberg434bc692014-11-29 23:12:55 +010015842014-11-29 Werner Lemberg <wl@gnu.org>
1585
1586 [docmaker] Improve HTML code for table of contents.
1587
1588 * src/tools/docmaker/tohtml.py: Introduce a new table class `toc',
Werner Lemberg51987ea2014-11-29 22:19:29 +01001589 together with proper CSS.
1590
15912014-11-29 Werner Lemberg <wl@gnu.org>
1592
Werner Lembergaa834ce2014-11-29 20:08:29 +01001593 [docmaker] Provide higher-level markup and simplify HTML.
1594
1595 * src/tools/docmaker/tohtml.py: Instead of using extraneous `<div>'
1596 elements, use CSS descendants (of class `section') to format the
1597 data.
1598
1599 Also remove reduntant <p> and <br> elements, replacing them with
1600 proper CSS.
1601
1602 Globally reduce page width to 75%.
1603
1604 (block_header): Rename <div> class to `section'.
1605
16062014-11-29 Werner Lemberg <wl@gnu.org>
1607
Werner Lemberg3bb97022014-11-29 16:12:37 +01001608 [docmaker] Add `top' links after blocks.
1609
1610 * src/tools/docmaker/tohtml.py (block_footer_middle): Implement it.
1611
16122014-11-29 Werner Lemberg <wl@gnu.org>
1613
Werner Lemberga31f9712014-11-29 07:18:44 +01001614 * src/tools/docmaker/tohtml.py: Improve CSS for fields.
1615
Werner Lemberg3bb97022014-11-29 16:12:37 +01001616 Make fields align horizontally relative to full line width.
Werner Lemberga31f9712014-11-29 07:18:44 +01001617
16182014-11-29 Werner Lemberg <wl@gnu.org>
1619
Werner Lemberg8f795112014-11-29 06:49:15 +01001620 * src/tools/docmaker/tohtml.py: Fix index and TOC templates.
1621
1622 This thinko was introduced 2014-11-27.
1623
Werner Lembergba1ba0c2014-11-28 22:04:14 +010016242014-11-28 Werner Lemberg <wl@gnu.org>
1625
1626 [docmaker] Format field lists with CSS.
1627
1628 This also simplifies the inserted HTML code.
1629
1630 * src/tools/docmaker/tohtml.py
1631 (HtmlFormatter::print_html_field_list): Do it.
1632
suzuki toshiya348fffa2014-11-28 16:05:59 +090016332014-11-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1634
1635 Fix compiler warning to the comparison between signed and
1636 unsigned variable.
1637
1638 * src/pfr/pfrsbit.c (pfr_slot_load_bitmap): Fix the comparison
1639 between `ypos + ysize' and FT_INT_{MAX,MIN}.
1640
Werner Lembergba1ba0c2014-11-28 22:04:14 +010016412014-11-28 Werner Lemberg <wl@gnu.org>
Werner Lemberg984e0712014-11-28 05:33:58 +01001642
Werner Lembergba1ba0c2014-11-28 22:04:14 +01001643 [docmaker] Replace empty `<td>' with CSS.
Werner Lemberg46d4dc82014-11-28 05:49:56 +01001644
1645 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Do
1646 it.
1647
Werner Lembergba1ba0c2014-11-28 22:04:14 +010016482014-11-28 Werner Lemberg <wl@gnu.org>
Werner Lemberg46d4dc82014-11-28 05:49:56 +01001649
Werner Lemberg984e0712014-11-28 05:33:58 +01001650 [docmaker] Replace some `<table>' tags with `<h4>' and `<div>'.
1651
1652 * src/tools/docmaker/tohtml.py (marker_*): Use `<h4>'.
1653 (source_*): Use `<div>'.
1654 (HtmlFormatter::block_enter): s/<h4>/<h3>/.
1655
suzuki toshiya9ee6a0a2014-11-28 11:14:18 +090016562014-11-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1657
1658 Fix compiler warning to conversion specifiers in debug messages.
1659
1660 * src/autofit/afhints.c (af_glyph_hints_dump_points): Add length
Werner Lemberga632b5f2014-12-03 19:30:44 +01001661 modifier to dump long integers.
1662 (af_glyph_hints_dump_segments, af_glyph_hints_dump_edges): Ditto.
suzuki toshiya9ee6a0a2014-11-28 11:14:18 +09001663
Werner Lemberg26d699e2014-11-27 19:22:52 +010016642014-11-27 Werner Lemberg <wl@gnu.org>
1665
Werner Lemberg984e0712014-11-28 05:33:58 +01001666 * src/tools/docmaker/tohtml.py: Use more CSS for index.
Werner Lemberg7ea36342014-11-27 19:38:31 +01001667
16682014-11-27 Werner Lemberg <wl@gnu.org>
1669
Werner Lembergedcf8172014-11-27 19:28:48 +01001670 [docmaker] Replace `name' attribute of `<a>' with `id'.
1671
1672 * src/tools/docmaker/tohtml.py (HtmlFormatter::block_enter): Do it.
1673
16742014-11-27 Werner Lemberg <wl@gnu.org>
1675
Werner Lemberg26d699e2014-11-27 19:22:52 +01001676 * src/tools/docmaker/tohtml.py: Remove remaining `width' attributes.
1677
1678 For `Index' and `TOC' links, we now simply use the `text-align' CSS
1679 property of `<td>' to enforce flush-left and flush-right,
1680 eliminating the hack with an empty, full-width `<td>' element
1681 inbetween.
1682
1683 The change also enforces the same (smaller) size for all index and
1684 TOC links.
1685
suzuki toshiya2676e072014-11-28 00:58:25 +090016862014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1687
suzuki toshiya1b12f5d2014-11-28 01:22:26 +09001688 * src/cff/cf2font.c: Include `ftcalc.h' to use FT_MSB(),
1689 cf2font.c could not find it under `make multi' build.
1690
16912014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1692
suzuki toshiya2676e072014-11-28 00:58:25 +09001693 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Remove
1694 unrequired negative value check for `width' and `height'.
1695
Werner Lemberg8585cf52014-11-27 10:49:05 +010016962014-11-27 Werner Lemberg <wl@gnu.org>
1697
Werner Lembergdd3fee02014-11-27 13:20:52 +01001698 * src/tools/docmaker/tohtml.py: More HTML table refactoring.
1699
1700 Replace some `<table>' tags with `<div>' to simplify structure.
1701
1702 Move `bgcolor' attribute to CSS.
1703
1704 Replace most `width' attributes with CSS. The remaining instances
1705 (providing a similar effect as LaTeX's `\hfill' command) are removed
1706 in a later patch.
1707
17082014-11-27 Werner Lemberg <wl@gnu.org>
1709
Werner Lemberga5ad26a2014-11-27 10:52:24 +01001710 * src/tools/docmaker/tohtml.py: Replace <font> with CSS.
1711
17122014-11-27 Werner Lemberg <wl@gnu.org>
1713
Werner Lembergba67c612014-11-27 10:51:49 +01001714 * src/tools/docmaker/tohtml.py: Center <table> with CSS.
1715
17162014-11-27 Werner Lemberg <wl@gnu.org>
1717
Werner Lemberg5594fa52014-11-27 10:50:50 +01001718 * src/tools/docmaker/tohtml.py: Replace `<center>' with `<div>'.
1719
17202014-11-27 Werner Lemberg <wl@gnu.org>
1721
Werner Lemberg8585cf52014-11-27 10:49:05 +01001722 * src/tools/docmaker/tohtml.py: Remove redundant `<center>' tags.
1723
1724 This starts a series of commits into the direction of generating
1725 valid HTML 5 code, especially using much more CSS.
1726
suzuki toshiya1b057042014-11-27 17:53:20 +090017272014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1728
1729 Prevent too negative values (< FT_INT_MIN) in bitmap metrics,
1730 suggested by Alexei.
1731
1732 * src/pfr/pfrsbit.c (pfr_slot_load_bitmap): Prevent too
1733 negative values in `xpos' and `ypos + ysize'.
1734 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Prevent
1735 too negative values in `x_left' and `y_top'. Either negative
1736 values in `width' and `height' are checked.
1737
Werner Lemberg3d167cb2014-11-27 05:19:41 +010017382014-11-27 Werner Lemberg <wl@gnu.org>
1739
Werner Lembergc52882a2014-11-27 08:01:25 +01001740 [docmaker] Produce better HTML code.
1741
1742 * src/tools/docmaker/tohtml.py: Always use double quotes for
1743 attribute values.
1744 (source_footer): Close `td' and `tr' groups.
1745
17462014-11-27 Werner Lemberg <wl@gnu.org>
1747
Werner Lembergdbb93152014-11-27 07:20:48 +01001748 Use better way to disable creation of .pyc files for `make refdoc'.
1749
1750 Python 2.6 was released in 2008...
1751
1752 * builds/freetype.mk (refdoc): Use python's `-B' option.
1753
1754 * builds/detect.mk (std_setup, dos_setup): Mention required python
1755 version for `refdoc' target.
1756
17572014-11-27 Werner Lemberg <wl@gnu.org>
1758
Werner Lemberge8a5c332014-11-27 06:48:37 +01001759 * src/tools/docmaker/sources.py (re_bold, re_italic): Use
1760 non-grouping parentheses.
1761 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_html_word):
1762 Updated.
1763
17642014-11-27 Werner Lemberg <wl@gnu.org>
1765
Werner Lemberg3d167cb2014-11-27 05:19:41 +01001766 * src/base/ftobjs.c (FT_Get_Glyph_Name): Fix compiler warning.
1767
1768 Introdruced in previous change. Reported by Alexei.
1769
Werner Lemberga593a042014-11-26 18:42:48 +010017702014-11-26 Werner Lemberg <wl@gnu.org>
1771
Werner Lembergf34f1922014-11-26 21:59:21 +01001772 * src/*: Add checks for parameters of API functions where missing.
1773
1774 `API functions' are functions tagged with `FT_EXPORT_DEF'.
1775
1776 Besides trivial fixes, the following changes are included, too.
1777
1778 * src/base/ftbdf.c (FT_Get_BDF_Charset_ID, FT_Get_BDF_Property): Set
1779 error code if no service is available.
1780
1781 * src/base/ftinit.c (FT_Done_FreeType): Change return value for
1782 invalid `library' parameter to `Invalid_Library_Handle'.
1783
1784 * src/base/ftobjs.c (FT_New_Size): Change return value for invalid
1785 `asize' parameter to `Invalid_Argument'.
1786
1787 * src/base/ftoutln.c (FT_Outline_Copy): Change return value for
1788 invalid `source' and `target' parameters to `Invalid_Outline'.
1789 (FT_Outline_Done_Internal): Change return value for invalid
1790 `outline' parameter to `Invalid_Outline'.
1791
17922014-11-26 Werner Lemberg <wl@gnu.org>
1793
Werner Lemberga593a042014-11-26 18:42:48 +01001794 * src/cache/ftcbasic.c: Use single calls to `FT_TRACE'.
1795
suzuki toshiya5aff8532014-11-26 14:36:12 +090017962014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1797
suzuki toshiyacd4a5a22014-11-27 00:20:48 +09001798 * src/base/ftobj.c (Mac_Read_POST_Resource): Additional
1799 overflow check in the summation of POST fragment lengths,
1800 suggested by Mateusz Jurczyk <mjurczyk@google.com>.
1801
18022014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1803
suzuki toshiya1720e812014-11-26 16:39:00 +09001804 * src/base/ftobjs.c (Mac_Read_POST_Resource): Insert comments
1805 and fold too long tracing messages.
1806
18072014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1808
suzuki toshiya18a8f0d2014-11-26 16:11:38 +09001809 Fix Savannah bug #43540.
1810
1811 * src/base/ftmac.c (parse_fond): Prevent a buffer overrun
1812 caused by a font including too many (> 63) strings to store
1813 names[] table.
1814
18152014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1816
suzuki toshiya45331672014-11-26 16:02:17 +09001817 * src/base/ftobjs.c (Mac_Read_POST_Resource): Use unsigned long
1818 variables to read the lengths in POST fragments. Suggested by
1819 Mateusz Jurczyk <mjurczyk@google.com>.
1820
18212014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1822
suzuki toshiya35252ae2014-11-26 15:52:23 +09001823 Fix Savannah bug #43539.
1824
1825 * src/base/ftobjs.c (Mac_Read_POST_Resource): Fix integer overflow
1826 by a broken POST table in resource-fork.
1827
18282014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1829
suzuki toshiya240c94a2014-11-26 15:43:29 +09001830 Fix Savannah bug #43538.
1831
1832 * src/base/ftobjs.c (Mac_Read_POST_Resource): Fix integer overflow
1833 by a broken POST table in resource-fork.
1834
18352014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
1836
suzuki toshiya5aff8532014-11-26 14:36:12 +09001837 * src/base/ftobjs.c (Mac_Read_POST_Resource): Avoid memory leak
1838 by a broken POST table in resource-fork. Return after freeing
1839 the buffered POST table when it is found to be broken.
1840
Werner Lemberg04edbbd2014-11-25 10:21:13 +010018412014-11-25 Werner Lemberg <wl@gnu.org>
1842
Werner Lemberg02b8e7e2014-11-25 11:31:51 +01001843 */*: s/Invalid_Argument/Invalid_Size_Handle/ where appropriate.
1844
18452014-11-25 Werner Lemberg <wl@gnu.org>
1846
Werner Lemberg0d4aa232014-11-25 11:26:14 +01001847 */*: s/Invalid_Argument/Invalid_Stream_Handle/ where appropriate.
1848
18492014-11-25 Werner Lemberg <wl@gnu.org>
1850
Werner Lembergf4f9e682014-11-25 11:11:55 +01001851 */*: s/Invalid_Argument/Invalid_Library_Handle/ where appropriate.
1852
18532014-11-25 Werner Lemberg <wl@gnu.org>
1854
Werner Lemberg04c2aa12014-11-25 10:22:12 +01001855 */*: s/Invalid_Argument/Invalid_Outline/ where appropriate.
1856
18572014-11-25 Werner Lemberg <wl@gnu.org>
1858
Werner Lemberg04edbbd2014-11-25 10:21:13 +01001859 */*: s/Invalid_Argument/Invalid_Face_Handle/ where appropriate.
1860
Werner Lembergeca0f062014-11-24 10:22:08 +010018612014-11-24 Werner Lemberg <wl@gnu.org>
1862
Werner Lemberg3e867112014-11-25 09:01:07 +01001863 [Savannah bug #43682] Adjust some renderer callbacks.
1864
1865 * src/raster/ftraster.c (ft_black_set_mode): Change return type to
1866 `int' to stay in sync with `FT_Renderer_SetModeFunc' prototype.
1867
1868 * src/smooth/ftgrays.c (gray_raster_set_mode): New dummy function
1869 for orthogonality.
1870 (ft_grays_raster): Use it.
1871
Werner Lemberg04edbbd2014-11-25 10:21:13 +010018722014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lemberg3e867112014-11-25 09:01:07 +01001873
Werner Lemberg6689a002014-11-25 08:53:09 +01001874 [Savannah bug #43682] Properly handle missing return errors.
1875
1876 The functions in this patch *do* return non-trivial errors that must
1877 be taken care of.
1878
1879 * src/autofit/afloader.c (af_loader_load_g), src/base/ftobjs.c
1880 (FT_Render_Glyph_Internal), src/base/ftoutln.c (FT_Outline_Render),
1881 src/cff/cffgload.c (cff_decoder_parse_charstrings) <cff_op_endchar>,
1882 src/psaux/psobjs.c (ps_parser_load_field_table), src/psaux/t1decode
1883 (t1_decoder_parse_charstrings) <op_endchar>, src/truetype/ttgload.c
1884 (load_truetype_glyph <subglyph loop>, tt_loader_init,
1885 TT_Load_Glyph), src/truetype/ttgxvar.c (TT_Set_MM_Blend),
1886 src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Do it.
1887
Werner Lemberg04edbbd2014-11-25 10:21:13 +010018882014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lemberg6689a002014-11-25 08:53:09 +01001889
Werner Lembergb24e8ba2014-11-25 08:30:49 +01001890 [Savannah bug #43682] Add/remove `void' casts to some functions.
1891
1892 We use a cast to indicate that we intentionally ignore a function's
1893 return value. However, this doesn't apply to API functions where
1894 errors can only happen for trivially invalid input.
1895
1896 * src/base/ftstroke.c (FT_Glyph_Stroke, FT_Glyph_StrokeBorder),
1897 src/base/ftsynth.c (FT_GlyphSlot_Embolden), src/cff/cffgload.c
1898 (cff_slot_load), src/pfr/pfrdrivr.c (pfr_get_kerning),
1899 src/type1/t1load.c (parse_encoding), src/type42/t42parse.c
1900 (t42_parse_encoding): Do it.
1901
Werner Lemberg04edbbd2014-11-25 10:21:13 +010019022014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lembergb24e8ba2014-11-25 08:30:49 +01001903
Werner Lembergef439fd2014-11-25 08:14:15 +01001904 [Savannah bug #43682] Change some signatures to `void' return type.
1905
1906 * include/internal/pshints.h (PSH_Globals_SetScaleFunc),
1907 include/internal/sfnt.h (TT_Get_Metrics_Func),
1908 src/pshinter/pshglob.c (psh_globals_set_scale),
1909 src/pshinter/pshrec.c (ps_hints_init), src/sfnt/ttmtx.c
1910 (tt_face_get_metrics), src/truetype/ttinterp.c (TT_Goto_CodeRange,
1911 TT_Set_CodeRange, TT_Clear_CodeRange, TT_Done_Context,
1912 TT_Save_Context): Do it.
1913
1914 * src/pshinter/pshglob.h, src/pshinter/pshrec.h, src/sfnt/ttmtx.h,
1915 src/truetype/ttgload.c (TT_Hint_Glyph), src/truetype/ttinterp.c
1916 (TT_Run_Context), src/truetype/ttinterp.h, src/truetype/ttobjs.c
1917 (tt_size_run_fpgm, tt_size_run_prep): Updated.
1918
19192014-11-24 Werner Lemberg <wl@gnu.org>
1920
Werner Lemberg6889f7b2014-11-24 17:16:08 +01001921 Remove all code related to FT_MAX_CHARMAP_CACHEABLE.
1922
1923 This is no longer used.
1924
1925 * src/base/ftobjs.c, src/cache/ftccmap.c, src/cff/cffobjs.c,
1926 src/sfnt/ttcmap.c: Do it.
1927
19282014-11-24 Werner Lemberg <wl@gnu.org>
1929
Werner Lembergf0292bb2014-11-24 10:51:21 +01001930 [sfnt] Fix Savannah bug #43680.
1931
1932 This adds an additional constraint to make the fix from 2013-01-25
1933 really work.
1934
1935 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_image) <index_format==4>:
1936 Check `p' before `num_glyphs'.
1937
19382014-11-24 Werner Lemberg <wl@gnu.org>
1939
Werner Lembergeca0f062014-11-24 10:22:08 +01001940 [truetype] Fix Savannah bug #43679.
1941
1942 * src/truetype/ttpload.c (tt_face_load_hdmx): Check minimum size of
1943 `record_size'.
1944
Jarkko Pöyry96341dc2014-11-24 09:53:07 +010019452014-11-24 Jarkko Pöyry <jarkko.poyry@gmail.com>
1946
1947 [cff, pfr, psaux, winfonts] Fix Savannah bug #43676.
1948
Werner Lemberged6a9df2014-12-06 23:28:58 +01001949 Don't cast cmap init function pointers to an incompatible type.
Jarkko Pöyry96341dc2014-11-24 09:53:07 +01001950
1951 Without this patch, the number of parameters between declaration and
1952 the real signature differs. Calling such a function results in
1953 undefined behavior.
1954
1955 ISO/IEC 9899:TC3 (Committee Draft September 7, 2007)
1956 6.5.2.2 Function calls
1957 9 If the function is defined with a type that is not
1958 compatible with the type (of the expression) pointed to by
1959 the expression that denotes the called function, the
1960 behavior is undefined.
1961
1962 On certain platforms (c -> js with emscripten) this causes
1963 termination of execution or invalid calls because in the emscripten
1964 implementation, function pointers of different types are stored in
1965 different pointer arrays. Incorrect pointer type here results in
1966 indexing of an incorrect array.
1967
1968 * src/cff/cffcmap.c (cff_cmap_encoding_init, cff_cmap_unicode_init),
1969 src/pfr/pfrcmap.c (pfr_cmap_init), src/psaux/t1cmap.c
1970 t1_cmap_standard_init, t1_cmap_expert_init, t1_cmap_custom_init,
1971 t1_cmap_unicode_init), src/winfonts/winfnt.c (fnt_cmap_init): Fix
1972 signature.
1973
Werner Lemberga7a42072014-11-24 06:44:45 +010019742014-11-24 Werner Lemberg <wl@gnu.org>
1975
Werner Lembergf70d9342014-11-24 09:31:32 +01001976 [sfnt] Fix Savannah bug #43672.
1977
1978 * src/sfnt/ttkern.c (tt_face_load_kern): Use correct value for
1979 minimum table length test.
1980
19812014-11-24 Werner Lemberg <wl@gnu.org>
1982
Werner Lemberg73be9f92014-11-24 07:30:05 +01001983 [type1, type42] Another fix for Savannah bug #43655.
1984
1985 * src/type1/t1load.c (parse_charstrings), src/type42/t42parse.c
1986 (t42_parse_charstrings): Add another boundary testing.
1987
19882014-11-24 Werner Lemberg <wl@gnu.org>
1989
Werner Lemberga7a42072014-11-24 06:44:45 +01001990 [docmaker] Formatting, copyright, improved documentation.
1991
1992 * src/tools/docmaker/*: No code changes besides trivial
1993 modifications.
1994
Werner Lemberg9bd20b72014-11-22 06:24:45 +010019952014-11-22 Werner Lemberg <wl@gnu.org>
1996
Werner Lembergaf834612014-11-22 13:29:10 +01001997 [bdf] Fix Savannah bug #43660.
1998
1999 * src/bdf/bdflib.c (_bdf_parse_glyphs) <"ENDFONT">: Check
2000 `_BDF_GLYPH_BITS'.
2001
20022014-11-22 Werner Lemberg <wl@gnu.org>
2003
Werner Lemberg42fcd662014-11-22 12:44:33 +01002004 [type42] Allow only embedded TrueType fonts.
2005
2006 This is a follow-up to Savannah bug #43659.
2007
2008 * src/type42/t42objs.c (T42_Face_Init): Exclusively use the
2009 `truetype' font driver for loading the font contained in the `sfnts'
2010 array.
2011
20122014-11-22 Werner Lemberg <wl@gnu.org>
2013
Werner Lemberg37881872014-11-22 10:46:47 +01002014 [type42] Fix Savannah bug #43659.
2015
2016 * src/type42/t42objs.c (T42_Open_Face): Initialize `face->ttf_size'.
2017
2018 * src/type42/t42parse.c (t42_parse_sfnts): Always set
2019 `face->ttf_size' directly. This ensures a correct stream size in
2020 the call to `FT_Open_Face', which follows after parsing, even for
2021 buggy input data.
2022 Fix error messages.
2023
20242014-11-22 Werner Lemberg <wl@gnu.org>
2025
Werner Lemberg5f201ab2014-11-22 09:16:39 +01002026 [cff] Fix Savannah bug #43658.
2027
2028 * src/cff/cf2ft.c (cf2_builder_lineTo, cf2_builder_cubeTo): Handle
2029 return values of point allocation routines.
2030
20312014-11-22 Werner Lemberg <wl@gnu.org>
2032
Werner Lemberg9bd20b72014-11-22 06:24:45 +01002033 [sfnt] Fix Savannah bug #43656.
2034
2035 * src/sfnt/ttcmap.c (tt_cmap4_validate): Fix order of validity
2036 tests.
2037
Werner Lemberg6de76172014-11-21 06:05:49 +010020382014-11-21 Werner Lemberg <wl@gnu.org>
2039
Werner Lembergdd897102014-11-21 22:19:28 +01002040 [type1, type42] Fix Savannah bug #43655.
2041
2042 * src/type1/t1load.c (parse_charstrings), src/type42/t42parse.c
2043 (t42_parse_charstrings): Fix boundary testing.
2044
20452014-11-21 Werner Lemberg <wl@gnu.org>
2046
Werner Lembergb1fc00d2014-11-21 12:06:40 +01002047 * src/pcf/pcfread.c (pcf_get_metrics): Sanitize invalid metrics.
2048
20492014-11-21 Werner Lemberg <wl@gnu.org>
2050
Werner Lemberg9154dab2014-11-21 08:03:51 +01002051 [ftlcdfil] Obey flow direction.
2052
2053 * src/base/ftlcdfil.c (_ft_lcd_filter_fir, _ft_lcd_filter_legacy):
2054 Handle `up' flow.
2055
20562014-11-21 Werner Lemberg <wl@gnu.org>
2057
Werner Lemberg644d6fa2014-11-21 07:28:50 +01002058 * src/base/ftbitmap.c (FT_Bitmap_Convert): Improve.
2059
2060 This commit completes argument checks and adds support for different
2061 flow directions.
2062
20632014-11-21 Werner Lemberg <wl@gnu.org>
2064
Werner Lemberg6de76172014-11-21 06:05:49 +01002065 * src/base/ftbitmap.c (FT_Bitmap_Copy): Improve.
2066
2067 This commit adds argument checks and support for different flow
2068 directions.
2069
Werner Lemberg1e6e1b82014-11-20 21:07:56 +010020702014-11-20 Werner Lemberg <wl@gnu.org>
2071
2072 * src/base/ftbitmap.c (FT_Bitmap_New): Check argument.
2073
Werner Lembergd6061212014-11-19 21:13:23 +010020742014-11-19 Werner Lemberg <wl@gnu.org>
2075
Werner Lembergb3500af2014-11-19 21:28:21 +01002076 Change some fields in `FT_Bitmap' to unsigned type.
2077
2078 This doesn't break ABI.
2079
2080 * include/ftimage.h (FT_Bitmap): Make `rows', `width', `num_grays',
2081 `pixel_mode', and `palette_mode' unsigned types.
2082
2083 * src/base/ftbitmap.c: Updated.
2084 (FT_Bitmap_Copy): Fix casts.
2085
2086 * src/cache/ftcsbits.c, src/raster/ftraster.c, src/sfnt/pngshim.c:
2087 Updated.
2088
20892014-11-19 Werner Lemberg <wl@gnu.org>
2090
Werner Lembergdf485772014-11-19 21:21:23 +01002091 Make `FT_Bitmap_Convert' correctly handle negative `pitch' values.
2092
2093 * src/base/ftbitmap.c (FT_Bitmap_Convert): Always use positive value
2094 for the pitch while copying data.
2095 Correctly set pitch sign in target bitmap.
2096
20972014-11-19 Werner Lemberg <wl@gnu.org>
2098
Werner Lembergd6061212014-11-19 21:13:23 +01002099 Minor code improvement in `FT_Bitmap_Embolden'.
2100
2101 * src/base/ftbitmap.c (FT_Bitmap_Embolden) <FT_PIXEL_MODE_GRAY[24]>:
2102 Fix thinko.
2103
Alexei Podtelezhnikovf841ad32014-11-19 21:19:06 -050021042014-11-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2105
2106 * src/base/fttrigon.c: Use dedicated `FT_Angle' for arctan table.
2107
Werner Lemberga67c43e2014-11-19 06:46:23 +010021082014-11-19 Behdad Esfahbod <behdad@behdad.org>
2109
2110 Avoid compiler warnings on x86-64 for `FT_MulFix'.
2111
2112 `FT_MulFix' takes `FT_Long' parameters as defined in `freetype.h',
2113 but several inline implementations of it in `ftcalc.h' take
2114 `FT_Int32' arguments. This is causing compiler warnings on x86-64:
2115 If parameters of type `FT_Fixed' (= `FT_Long') are passed to the
2116 inline implementation of this function, integer values are truncated
2117 from 64bit to 32bit.
2118
2119 * include/internal/ftcalc.h (FT_MulFix) [FT_MULFIX_ASSEMBLER]: Add
2120 casts.
2121
Werner Lemberg54abd222014-11-15 09:05:22 +010021222014-11-15 Werner Lemberg <wl@gnu.org>
2123
2124 [sfnt] Fix Savannah bug #43597.
2125
2126 * src/sfnt/pngshim.c (Load_SBit_Png): Protect against too large
2127 bitmaps.
2128
Werner Lemberg602040b2014-11-12 20:51:20 +010021292014-11-12 Werner Lemberg <wl@gnu.org>
2130
Werner Lemberg257c2702014-11-12 21:42:13 +01002131 [sfnt] Fix Savannah bug #43591.
2132
2133 * src/sfnt/ttsbit.c (tt_sbit_decoder_init): Protect against addition
2134 and multiplication overflow.
2135
21362014-11-12 Werner Lemberg <wl@gnu.org>
2137
Werner Lemberg677ddf42014-11-12 21:26:44 +01002138 [sfnt] Fix Savannah bug #43590.
2139
2140 * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir):
2141 Protect against addition overflow.
2142
21432014-11-12 Werner Lemberg <wl@gnu.org>
2144
Werner Lembergf46add12014-11-12 21:06:08 +01002145 [sfnt] Fix Savannah bug #43589.
2146
2147 * src/sfnt/sfobjs.c (woff_open_font): Protect against addition
2148 overflow.
2149
21502014-11-12 Werner Lemberg <wl@gnu.org>
2151
Werner Lemberg602040b2014-11-12 20:51:20 +01002152 [sfnt] Fix Savannah bug #43588.
2153
2154 * src/sfnt/ttcmap.c (tt_cmap8_validate, tt_cmap10_validate,
2155 tt_cmap12_validate, tt_cmap13_validate, tt_cmap14_validate): Protect
2156 against overflow in additions and multiplications.
2157
Alexei Podtelezhnikov2e73a1b2014-11-09 23:22:43 -050021582014-11-10 Alexei Podtelezhnikov <apodtele@gmail.com>
2159
2160 [base] CORDIC improvements.
2161
2162 The scaling between the hypotenuse and its CORDIC approximation is
2163 based on regression analysis. The smaller padding for `theta' is
2164 justifed by its maximum error of less than 6.
2165
2166 * src/base/fttrigon.c (ft_trig_downscale): Borrow code from
2167 ./ftcalc.c (ft_multo64), change linear intercept.
2168 (ft_trig_pseudo_polarize): Decrease `theta' padding.
2169
Werner Lemberg0e73d212014-11-09 01:27:38 +010021702014-11-09 Werner Lemberg <wl@gnu.org>
2171
2172 * src/base/ftstroke.c (ft_stroker_inside): Fix border intersections.
2173
2174 One more place to check whether `radius' is zero.
2175
2176 Problem reported by Marco Wertz <marco.wertz@gmx.de>.
2177
Werner Lemberg2c4832d2014-11-07 07:42:33 +010021782014-11-07 Werner Lemberg <wl@gnu.org>
2179
Werner Lemberg602040b2014-11-12 20:51:20 +01002180 [bdf] Fix Savannah bug #43535.
Werner Lemberg2c4832d2014-11-07 07:42:33 +01002181
2182 * src/bdf/bdflib.c (_bdf_strncmp): New macro that checks one
2183 character more than `strncmp'.
2184 s/ft_strncmp/_bdf_strncmp/ everywhere.
2185
Werner Lembergf49a1002014-11-06 13:30:28 +010021862014-11-06 Werner Lemberg <wl@gnu.org>
2187
Werner Lemberg602040b2014-11-12 20:51:20 +01002188 [pcf] Fix Savannah bug #43548.
Werner Lembergef1eba72014-11-06 23:25:05 +01002189
Werner Lemberg2c4832d2014-11-07 07:42:33 +01002190 * src/pcf/pcfread.c (pcf_get_encodings): Add sanity checks for row
2191 and column values.
Werner Lembergef1eba72014-11-06 23:25:05 +01002192
21932014-11-06 Werner Lemberg <wl@gnu.org>
2194
Werner Lemberg602040b2014-11-12 20:51:20 +01002195 [pcf] Fix Savannah bug #43547.
Werner Lemberg0e2f5d52014-11-06 22:32:46 +01002196
2197 * src/pcf/pcfread.c (pcf_read_TOC): Check `size' and `offset'
2198 values.
2199
22002014-11-06 Werner Lemberg <wl@gnu.org>
2201
Werner Lembergf49a1002014-11-06 13:30:28 +01002202 * src/pcf/pcfread.c (pcf_read_TOC): Avoid memory leak.
2203
Infinalityfacfc792014-11-03 07:24:59 +010022042014-11-03 Infinality <infinality@infinality.net>
2205
2206 * src/truetype/ttsubpix.c (COMPATIBILITY_MODE_Rules): Updated.
2207
2208 The previous commit deteriorates rendering of DejaVu and similar
2209 fonts; this gets compensated with this rule.
2210
Werner Lemberg706f7522014-11-03 07:20:57 +010022112014-11-03 Werner Lemberg <wl@gnu.org>
2212
2213 * src/truetype/ttinterp.c (Ins_DELTAP): Fix subpixel hinting.
2214
2215 Before this patch, it was impossible to ever call DELTAP[123] in
2216 subpixel hinting mode as described in the ClearType whitepaper; it
2217 only worked if in `compatibility mode'. However, compatibility mode
2218 essentially disables SHPIX, completely ruining hinting of
2219 ttfautohint output, for example.
2220
2221 We now follow the whitepaper more closely so that DELTAP[123]
2222 instructions for touched points in the non-subpixel direction are
2223 executed.
2224
Alexei Podtelezhnikove1efe0a2014-10-31 00:07:14 -040022252014-10-31 Alexei Podtelezhnikov <apodtele@gmail.com>
2226
Alexei Podtelezhnikov525d4872014-10-31 22:12:37 -04002227 [smooth] Improve code readability.
2228
2229 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Rearrange code.
2230
22312014-10-31 Alexei Podtelezhnikov <apodtele@gmail.com>
2232
Alexei Podtelezhnikove1efe0a2014-10-31 00:07:14 -04002233 [smooth] Reduce outline translations during rendering.
2234
2235 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Translate origin
2236 virtually by modifying cbox, actually translate outline if cumulative
2237 shift is not zero.
2238
Alexei Podtelezhnikovc7fd9352014-10-30 22:43:01 -040022392014-10-30 Alexei Podtelezhnikov <apodtele@gmail.com>
2240
2241 [smooth] Fix Savannah bug #35604 (cont'd).
2242
2243 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Remove checks and
2244 casts that became unnecessary after the variable type upgrades.
2245
Alexei Podtelezhnikov74916992014-10-29 22:24:24 -040022462014-10-29 Alexei Podtelezhnikov <apodtele@gmail.com>
2247
Alexei Podtelezhnikov465ab992014-10-29 23:45:23 -04002248 [smooth] Improve code readability.
2249
2250 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Rearrange code.
2251
22522014-10-29 Alexei Podtelezhnikov <apodtele@gmail.com>
2253
Alexei Podtelezhnikov74916992014-10-29 22:24:24 -04002254 Unify hypotenuse approximations.
2255
2256 * include/internal/ftcalc.h (FT_HYPOT): Move macro from here...
2257 * include/internal/ftobjs.h: ... to here, next to required `FT_ABS'.
2258 * src/smooth/ftgrays.c (gray_render_cubic): Use it here.
2259
Werner Lembergfe151522014-10-25 05:56:59 +020022602014-10-25 Werner Lemberg <wl@gnu.org>
2261
2262 [cff] Test valid darkening parameter macros in `ftoption.h'.
2263
2264 We no longer need an otherwise unused typedef that can cause a gcc
2265 warning.
2266 Problem reported by Alexei.
2267
2268 * src/cff/cffobjs.c (cff_driver_init): Use
2269 `CFF_CONFIG_OPTION_DARKENING_PARAMETER_XXX' macros directly.
2270 (SET_DARKENING_PARAMETERS): Removed.
2271 Compile time tests are now ...
2272
2273 * devel/ftoption.h, include/config/ftoption.h: ... here.
2274
Alexei Podtelezhnikovaba0f492014-10-24 23:50:57 -040022752014-10-25 Alexei Podtelezhnikov <apodtele@gmail.com>
2276
2277 Improve flat corner definition.
2278
2279 * include/internal/ftcalc.h (FT_HYPOT): Macro to approximate Euclidean
2280 distance with the alpha max plus beta min algorithm.
2281 * src/base/ftcalc.c (ft_corner_is_flat): Use it instead of Taxicab
2282 metric.
2283
David Weißdd8de1a2014-10-23 20:01:48 +020022842014-10-23 David Weiß <David.Weiss@ptvgroup.com>
2285
2286 [build] Improve property file for vc2010.
2287
2288 User-defined properties should be empty by default to prevent linker
2289 failures.
2290
2291 * builds/windows/vc2010/freetype.user.props,
2292 builds/windows/vc2010/freetype.vcxproj:
2293 s/OptionsDirectory/UserOptionDirectory/.
2294 Comment out all user options.
2295
Werner Lembergdd570e92014-10-23 19:57:37 +020022962014-10-23 Werner Lemberg <wl@gnu.org>
2297
2298 [cff] Work around bug in preprocessor of MSVC 2010.
2299
2300 We have been hit by
2301
2302 https://connect.microsoft.com/VisualStudio/feedback/details/718976/msvc-pr
2303
2304 * devel/ftoption.h, include/config/ftoption.h: Replace
2305 `CFF_CONFIG_OPTION_DARKENING_PARAMETERS' with eight macros
2306 `CFF_CONFIG_OPTION_DARKENING_PARAMETER_{X,Y}{1,2,3,4}'.
2307
2308 * src/cff/cffobjs.c (SET_DARKENING_PARAMETERS): Removed. We no
2309 longer need double expansion.
2310 (SET_DARKENING_PARAMETERS_0): Renamed to ...
2311 (SET_DARKENING_PARAMETERS): ... this.
2312 Update call.
2313
Werner Lembergcc7bb802014-10-20 08:35:50 +020023142014-10-20 Werner Lemberg <wl@gnu.org>
2315
2316 [sbit] Minor fixes.
2317
2318 * src/sfnt/ttsbit.c (tt_face_load_sbit) [TT_SBIT_TABLE_TYPE_SBIX]:
2319 Accept overlay format also, but emit warning message in that case.
2320 (tt_sbit_decoder_load_metrics): Add missing newline to error
2321 message.
2322 (tt_sbit_load_sbix_image): Add `rgbl' graphic type (as used on iOS
2323 7.1) to the list of unsupported formats.
2324
Alexei Podtelezhnikov118e6512014-10-19 23:31:08 -040023252014-10-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2326
2327 [truetype] Clean up bytecode rounding.
2328
2329 Zero distance does not have to be treated specially if you follow
2330 specifications and check the sign as the very last step of rounding.
2331
2332 * src/truetype/ttinterp.c (Round_None, Round_To_Grid,
2333 Round_Down_To_Grid, Round_Up_To_Grid, Round_To_Double_Grid): Use
2334 macros when available, do not check for non-zero distance.
2335 (Round_To_Half_Grid, Round_Super, Round_Super_45): Ditto, return phase
2336 if sign changed.
2337
Alexei Podtelezhnikovd4aabda2014-10-18 10:10:04 -040023382014-10-18 Alexei Podtelezhnikov <apodtele@gmail.com>
2339
2340 [truetype] Unwrap engine compensation settings.
2341
2342 * src/truetype/ttobjs.c (tt_size_init_bytecode): Updated.
2343
David Weißfede19e2014-10-18 14:59:20 +020023442014-10-18 David Weiß <David.Weiss@ptvgroup.com>
2345
2346 [build] Add property file to vc2010 project.
2347
2348 This simplifies custom build configurations, especially for
2349 automated build environments.
2350
2351 * builds/windows/vc2010/freetype.user.props: New configuration file.
2352
2353 * builds/windows/vc2010/freetype.vcxproj: Include
2354 `freetype.user.props' and use its data fields.
2355
2356 * builds/windows/vc2010/index.html: Updated.
2357
Werner Lembergc9c33f22014-10-18 11:01:14 +020023582014-10-18 Werner Lemberg <wl@gnu.org>
2359
2360 [autofit] Add blue-zone support for Telugu.
2361
2362 This essentially moves the Telugu script from the `Indic' hinter to
2363 the `Latin' hinter.
2364
2365 Note that this is a first shot and quite certainly needs
2366 refinements.
2367
2368 * src/autofit/afblue.dat: Add blue zone data for Telugu.
2369
2370 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2371
2372 * src/autofit/afscript.h: Add Telugu standard characters and move
2373 data out of AF_CONFIG_OPTION_INDIC block.
2374
2375 * src/autofit/afranges.c: Move Telugu data out of
2376 AF_CONFIG_OPTION_INDIC block.
2377
2378 * src/autofit/afstyles.h: Update Telugu data; in particular, use
2379 AF_WRITING_SYSTEM_LATIN.
2380
Werner Lemberg54306f52014-10-18 10:42:28 +020023812014-10-18 David Wimsey <david@wimsey.us>
2382
2383 [cmake] Add iOS build support.
Werner Lemberg1050aa92014-10-18 10:45:09 +02002384 From Savannah patch #8497.
Werner Lemberg54306f52014-10-18 10:42:28 +02002385
2386 * builds/cmake/iOS.cmake: New file. Universal binaries are built
2387 with both 32 and 64 bit arm architectures.
2388
2389 * CMakeLists.txt (IOS_PLATFORM): New variable for running the iOS
2390 toolchain. Possible values are `OS' to build on iOS, or
2391 `SIMULATOR' to build on APPLE.
2392
Werner Lemberg1a1750f2014-10-16 22:54:01 +020023932014-10-16 Behdad Esfahbod <behdad@behdad.org>
2394 Werner Lemberg <wl@gnu.org>
2395
2396 [cff] Add `CFF_CONFIG_OPTION_DARKENING_PARAMETERS' config macro.
2397
2398 * devel/ftoption.h, include/config/ftoption.h
2399 (CFF_CONFIG_OPTION_DARKENING_PARAMETERS): New macro.
2400
2401 * src/cff/cffobjs.c (SET_DARKENING_PARAMETERS,
2402 SET_DARKENING_PARAMETERS_0): New macros.
2403 (cff_driver_init): Use new macros.
2404
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -040024052014-10-14 Alexei Podtelezhnikov <apodtele@gmail.com>
2406
2407 [truetype] Limit delta shift range.
2408
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002409 The valid range for delta shift is zero through six. Negative values
2410 are invalid according to
2411
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -04002412 https://developer.apple.com/fonts/TrueType-Reference-Manual/RM04/Chap4.html#delta%20shift
2413
2414 * src/truetype/ttobjs.h (delta_shift, delta_base): Make unsigned.
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002415 * src/truetype/ttinterp.h (DO_SDS): Throw an error if `delta_shift'
2416 is out of range.
2417 (Ins_DELTAP, Ins_DELTAC): Optimize for valid `delta_shift'.
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -04002418
Werner Lemberg03987bf2014-10-16 07:19:46 +020024192014-10-16 Werner Lemberg <wl@gnu.org>
2420
2421 A better fix for Savannah bug #43392.
2422 Suggested by Doug Felt <dougfelt@gmail.com>.
2423
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002424 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics): Set
Werner Lemberg03987bf2014-10-16 07:19:46 +02002425 `vertAdvance' to zero...
2426
2427 * src/truetype/ttgload.c (TT_Load_Glyph): ... and set here a default
2428 value for `vertAdvance' based on `linearVertAdvance' in case
2429 `vertAdvance' is zero. Note that the previous computed ad-hoc value
2430 for `linearVertAdvance' was apparently not tested in a real-life
2431 situation.
2432
David Weiß3889cb22014-10-14 11:35:16 +020024332014-10-14 David Weiß <David.Weiss@ptvgroup.com>
2434
2435 [build] Better optimization settings for vc2010 solution file.
2436
2437 * builds/windows/vc2010/freetype.sln,
2438 builds/windows/vc2010/freetype.vcxproj: Updated.
2439
Werner Lemberg8f178092014-10-14 08:28:09 +020024402014-10-14 Werner Lemberg <wl@gnu.org>
2441
2442 [autofit] Adjust Devenagari character range.
2443
2444 * src/autofit/afranges.c (af_deva_uniranges): Omit characters that
2445 are common to all other Indic scripts.
2446
Werner Lemberg1ca5fa12014-10-12 08:31:32 +020024472014-10-12 Werner Lemberg <wl@gnu.org>
2448
2449 [sfnt] Fix Savannah bug #43392.
2450
2451 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics): Don't let
2452 vertical metrics uninitialized.
2453
Alexei Podtelezhnikov673a28e2014-10-11 14:40:51 -040024542014-10-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2455
2456 [base] Small bbox correction.
2457
2458 * src/base/ftbbox.c (FT_Outline_Get_BBox): Start from nonsense bbox
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002459 instead of initial point that could be `off' in conic outlines.
Alexei Podtelezhnikov673a28e2014-10-11 14:40:51 -04002460
Alexei Podtelezhnikov2ffcf172014-10-08 22:01:08 -040024612014-10-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2462
Alexei Podtelezhnikov40dac112014-10-09 00:58:14 -04002463 [base] Fix Savannah bug #43356.
2464
2465 * src/base/ftbbox.c (BBox_Move_To, BBox_Conic_To): Update bbox in case
Werner Lembergdf3d67e2014-10-16 07:24:44 +02002466 of implicit `to'.
Alexei Podtelezhnikov40dac112014-10-09 00:58:14 -04002467 (BBox_Line_To): New emitter that does not update bbox.
2468
24692014-10-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2470
Alexei Podtelezhnikov2ffcf172014-10-08 22:01:08 -04002471 [base] Introduce and use new macro `FT_UPDATE_BBOX'
2472
2473 * src/base/ftbbox.c (FT_UPDATE_BBOX): New macro.
2474 (FT_Outline_Get_BBox): Use it here.
2475
Alexei Podtelezhnikov7abdb8c2014-10-02 23:13:33 -040024762014-10-02 Alexei Podtelezhnikov <apodtele@gmail.com>
2477
2478 [base] Significant optimization of `ft_div64by32'
2479
2480 We shift as many bits as we can into the high register, perform
2481 32-bit division with modulo there, then work through the remaining
2482 bits with long division. This optimization is especially noticeable
2483 for smaller dividends that barely use the high register.
2484
2485 * src/base/ftcalc.c (ft_div64by32): Updated.
2486
Dave Arnold537c55d2014-10-02 06:32:32 +020024872014-10-02 Dave Arnold <darnold@adobe.com>
2488
2489 [cff] Fix Savannah bug #43271.
2490
2491 * src/cff/cf2font.c (cf2_computeDarkening): Change overflow
2492 detection to use logarithms and clamp `scaledStem'.
2493
Alexei Podtelezhnikov418e18f2014-10-01 22:36:40 -040024942014-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
2495
Alexei Podtelezhnikov74d0aad2014-10-01 23:27:15 -04002496 * src/base/ftcalc.c: Remove miscellaneous type casts.
2497
24982014-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
2499
Alexei Podtelezhnikov418e18f2014-10-01 22:36:40 -04002500 [base] Use more common `FT_MSB' implementation with masks.
2501
2502 * src/base/ftcalc.c (FT_MSB): Updated.
2503
Alexei Podtelezhnikov955aff12014-09-30 23:09:39 -040025042014-09-30 Alexei Podtelezhnikov <apodtele@gmail.com>
2505
2506 [base] Clean up.
2507
2508 * src/base/ftcalc.c (FT_MOVE_SIGN): New macro for frequently used
2509 code.
2510
Alexei Podtelezhnikov7f491112014-09-25 22:54:38 -040025112014-09-25 Alexei Podtelezhnikov <apodtele@gmail.com>
2512
2513 [base] Avoid unnecessary long division.
2514
2515 This applies to `FT_MulDiv' but not to `FT_DivFix', where overflows or
2516 lack thereof are predicted accurately.
2517
2518 * src/base/ftcalc.c (ft_div64by32): Improve readability.
2519 (FT_MulDiv, FT_MulDiv_No_Round) [!FT_LONG64]: Use straight division
2520 when multiplication stayed within 32 bits.
2521
Werner Lemberg5b68e4f2014-09-24 19:06:13 +020025222014-09-24 Werner Lemberg <wl@gnu.org>
2523
2524 [autofit] Minor clean-ups.
2525
2526 * src/autofit/afhints.c (AF_FLAGS): Remove obsolete values.
2527
2528 * src/autofit/afhints.c (af_glyph_hints_dump_points,
2529 af_glyph_hints_align_strong_points): Updated.
2530
2531 * src/autofit/aflatin.c (af_latin_hints_link_segments,
2532 af_latin_hints_compute_segments), src/autofit/afcjk.c
2533 (af_cjk_hints_link_segments), src/autofit/aflatin2.c
2534 (af_latin2_hints_link_segments, af_latin2_hints_compute_segments):
2535 There are no longer fake segments since more than 10 years...
2536
Werner Lemberg387a9fe2014-09-22 06:42:24 +020025372014-09-22 Werner Lemberg <wl@gnu.org>
2538
2539 [autofit] Minor code streamlining.
2540
2541 * src/autofit/afhints.c (af_axis_hints_new_edge): Remove redundant
2542 initialization.
2543
Alexei Podtelezhnikov5c894842014-09-19 22:03:15 -040025442014-09-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2545
2546 * src/base/ftcalc.c: Harmonize code.
2547
25482014-09-15 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04002549
Alexei Podtelezhnikovef070d42014-09-15 22:06:19 -04002550 [base] Tighten the overflow check in `FT_MulDiv'.
2551
2552 * src/base/ftcalc.c (FT_MulDiv) [!FT_LONG64]: Updated.
2553
25542014-09-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2555
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04002556 Fix Savannah bug #43153.
2557
2558 * src/psaux/psconv.c (PS_Conv_ToFixed): Add protection against
Alexei Podtelezhnikov7abdb8c2014-10-02 23:13:33 -04002559 overflow in `divider'.
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04002560
Alexei Podtelezhnikov32128522014-09-03 21:57:42 -040025612014-09-03 Alexei Podtelezhnikov <apodtele@gmail.com>
2562
Alexei Podtelezhnikov336735d2014-09-03 22:55:26 -04002563 [base] Tighten the overflow check in `FT_DivFix'.
2564
2565 This fixes a 13-year old bug. The original overflow check should have
2566 been updated when rounding was introduced into this function
2567 (c2cd00443b).
2568
2569 * src/base/ftcalc.c (FT_DivFix) [!FT_LONG64]: Updated.
2570 * include/freetype.h (FT_DivFix): Updated documentation.
2571
25722014-09-03 Alexei Podtelezhnikov <apodtele@gmail.com>
2573
Alexei Podtelezhnikov32128522014-09-03 21:57:42 -04002574 [base] Tighten the overflow check in `FT_MulFix'.
2575
2576 * src/base/ftcalc.c (FT_MulFix) [!FT_LONG64]: Updated.
2577
Alexei Podtelezhnikov125c3ca2014-09-02 22:38:59 -040025782014-09-02 Alexei Podtelezhnikov <apodtele@gmail.com>
2579
2580 [truetype] Shortcut ppem calculations for square pixels.
2581
2582 * src/truetype/ttinterp.h (TT_ExecContextRec): New field
2583 `cur_ppem_func' with a function pointer.
2584 * src/truetype/ttinterp.c (TT_RunIns): Initialize `cur_ppem_func'
2585 depending on the pixel geometry to either...
2586 (Current_Ppem_Stretched): ... this for stretched pixels.
2587 (Current_Ppem): ... or this for square pixels.
2588 (DO_MPPEM, DO_MPS, Ins_DELTAP, Ins_DELTAC): Use `cur_ppem_func'.
2589
Behdad Esfahbod1ec98b22014-08-31 08:47:11 +020025902014-08-31 Behdad Esfahbod <behdad@behdad.org>
2591
2592 Don't use `register' keyword. Fixes compiler warnings.
2593
2594 * src/base/ftcalc.c (FT_Add64) [!FT_LONG64]: Do it.
2595 * src/gzip/inftrees.c (huft_build): Ditto.
2596 * src/truetype/ttinterp.c (TT_MulFix14_arm): Ditto.
2597
Alexei Podtelezhnikova8bc49e2014-08-24 22:14:01 -040025982014-08-24 Alexei Podtelezhnikov <apodtele@gmail.com>
2599
Alexei Podtelezhnikov125c3ca2014-09-02 22:38:59 -04002600 [truetype] Optimize DELTAP and DELTAC.
Alexei Podtelezhnikova8bc49e2014-08-24 22:14:01 -04002601
2602 * src/truetype/ttinterp.c (Ins_DELTAP, Ins_DELTAC): Move ppem
2603 calculations outside of the loop.
2604
Alexei Podtelezhnikov98688592014-08-21 23:28:52 -040026052014-08-21 Alexei Podtelezhnikov <apodtele@gmail.com>
2606
2607 Fix Savannah bug #43033.
2608
2609 * include/config/ftconfig.h, builds/unix/ftconfig.in,
2610 builds/vms/ftconfig.h [FT_LONG64]: Do not disable the macro when
2611 64-bit type is `long'.
2612
Alexei Podtelezhnikov8fd87d42014-08-20 00:57:22 -040026132014-08-20 Alexei Podtelezhnikov <apodtele@gmail.com>
2614
2615 [base] Small optimization of `FT_MulFix'.
2616
2617 * src/base/ftcalc.c (FT_MulFix): Loosen up the condition for direct
2618 32-bit calculations.
2619
Alexei Podtelezhnikovf09326a2014-08-20 00:08:38 -040026202014-08-19 Alexei Podtelezhnikov <apodtele@gmail.com>
2621
2622 [base] Use unsigned calculation in `FT_MulDiv'.
2623
2624 * src/base/ftcalc.c (FT_MulDiv): Updated to expand 32-bit range.
2625
Alexei Podtelezhnikov382f3152014-08-18 23:16:15 -040026262014-08-18 Alexei Podtelezhnikov <apodtele@gmail.com>
2627
2628 [base] Remove truncation in `FT_DivFix'.
2629
2630 * src/base/ftcalc.c (FT_DivFix): Updated.
2631
Alexei Podtelezhnikov5ef20232014-08-14 23:21:46 -040026322014-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
2633
2634 Minor refactoring.
2635
2636 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round): Updated.
2637
26382014-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovc7022462014-08-14 23:01:01 -04002639
2640 Turn FT_MSB into a macro when using gcc builtins.
2641
2642 * src/base/ftcalc.c, include/internal/ftcalc.h: Updated.
2643
Alexei Podtelezhnikovf8efbcf2014-08-12 23:22:17 -040026442014-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
2645
2646 [base] Avoid undefined FT_MSB in `BBox_Cubic_Check'.
2647
2648 * src/base/ftbbox.c (BBox_Cubic_Check): Update.
2649 (update_cubic_max): Repalce with...
2650 (cubic_peak): ... this, which now handles upscaling.
2651
Alexei Podtelezhnikov47289932014-08-11 23:39:34 -040026522014-08-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2653
Alexei Podtelezhnikov28018d42014-08-12 00:26:16 -04002654 [base] Handle collapsed outlines to avoid undefined FT_MSB.
2655
2656 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Update.
2657
26582014-08-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2659
Alexei Podtelezhnikov47289932014-08-11 23:39:34 -04002660 [base] Restore FT_MulFix inlining.
2661
2662 * include/freetype.h (FT_MulFix): Unconditionally defined.
2663
2664 * src/base/ftcalc.c [FT_MULFIX_ASSEMBLER]: Move code from here...
2665
2666 * include/internal/ftcalc.h [FT_MULFIX_ASSEMBLER]: ... to here,
2667 which conditionally replaces the function with an inline version
2668 through the macro.
2669
Alexei Podtelezhnikov90be4b62014-08-08 22:27:10 -040026702014-08-08 Alexei Podtelezhnikov <apodtele@gmail.com>
2671
2672 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Refactor.
2673
Werner Lembergd17cabf2014-07-26 09:53:50 +090026742014-07-26 Werner Lemberg <wl@gnu.org>
2675
2676 [cff] Fix typo.
2677
2678 * src/cff/cf2hints.c (cf2_glyphpath_computeOffset): Use correct
2679 offsets in third quadrant.
2680
2681 Reported by maks <maksqwe1@ukr.net>.
2682
Werner Lemberg4e754132014-07-17 17:34:49 +090026832014-07-17 Werner Lemberg <wl@gnu.org>
2684
2685 Fix Savannah bug #42788.
2686
2687 * src/pfr/pfrobjs.c: Include `ftcalc.h'.
2688
Alexei Podtelezhnikovc0a6f202014-07-16 22:05:56 -040026892014-07-16 Alexei Podtelezhnikov <apodtele@gmail.com>
2690
2691 Replace `ft_highpow2' function.
2692
2693 * src/pfr/pfrobjs.c (pfr_face_get_kerning): Use `FT_MSB' instead of
2694 `ft_highpow2'.
2695
2696 * src/base/ftutil.c, include/internal/ftobjs.h (ft_highpow2): Remove
2697 it.
2698
Alexei Podtelezhnikov71330ce2014-07-15 23:30:45 -040026992014-07-15 Alexei Podtelezhnikov <apodtele@gmail.com>
2700
Werner Lembergcbbf26b2014-07-17 17:27:12 +09002701 * src/base/ftcalc.c (FT_MSB): Utilize gcc builtins.
Alexei Podtelezhnikov177982e2014-07-15 23:54:34 -04002702
27032014-07-15 Alexei Podtelezhnikov <apodtele@gmail.com>
2704
Alexei Podtelezhnikov71330ce2014-07-15 23:30:45 -04002705 [base] Move assembler code back in the source file.
2706
2707 FT_MulFix assembler used to reside in ftcalc.c before f47d263f1b.
2708
2709 * include/config/ftconfig.h, builds/unix/ftconfig.in,
2710 builds/vms/ftconfig.h [FT_MULFIX_ASSEMBLER]: Move code from here...
2711
2712 * src/base/ftcalc.c [FT_MULFIX_ASSEMBLER]: ... to here.
2713
27142014-07-14 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov1183cd42014-07-14 22:30:55 -04002715
2716 [base] Further clean up color bitmap conversion.
2717
2718 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Stop
2719 using FT_MulFix and FT_DivFix since all calculations fit into 32 bits.
2720
Werner Lemberg441b3f32014-07-13 02:28:14 +090027212014-07-13 Werner Lemberg <wl@gnu.org>
2722
2723 [truetype] Improve handling of buggy `prep' tables.
2724
2725 In case of an error in the `prep' table, no longer try to execute it
2726 again and again. This makes FreeType handle endless loops in buggy
2727 fonts much faster.
2728
2729 * src/truetype/ttobjs.h (TT_SizeRec): The fields `bytecode_ready'
2730 and `cvt_ready' are now negative if not initialized yet, otherwise
2731 they indicate the error code of the last run.
2732
2733 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep,
2734 tt_size_done_bytecode, tt_size_init_bytecode,
2735 tt_size_ready_bytecode, tt_size_init, tt_size_done, tt_size_reset):
2736 Updated.
2737
2738 * src/truetype/ttgload.c (tt_loader_init): Updated.
2739 * src/truetype/ttinterp.c (TT_RunIns): Force reexecution of `fpgm'
2740 and `prep' only if we are in the `glyf' table.
2741
Werner Lemberge98e2bc2014-07-12 16:37:39 +090027422014-07-12 Werner Lemberg <wl@gnu.org>
2743
2744 * builds/vms/ftconfig.h: Synchronize.
2745 Problem reported by Alexei.
2746
Alexei Podtelezhnikov35576bf2014-07-11 22:40:34 -040027472014-07-11 Alexei Podtelezhnikov <apodtele@gmail.com>
2748
2749 [base] Clean up bitmap conversion.
2750
2751 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
2752 appropriate FT_DivFix and remove superfluous upscaling.
2753
Alexei Podtelezhnikovceab95a2014-07-04 23:01:32 -040027542014-07-04 Alexei Podtelezhnikov <apodtele@gmail.com>
2755
2756 [base] Small optimization of the ancient code.
2757
2758 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round): Loosen up the
2759 condition for direct 32-bit calculations.
2760
Werner Lemberg38975562014-06-27 06:55:56 +020027612014-06-27 Werner Lemberg <wl@gnu.org>
2762
2763 Fix Apple standard glyph names.
2764
2765 * src/sfnt/ttpost.c (tt_post_default_names): Synchronize with
2766 `tools/glnames.py'
2767
2768 Problem reported by Adam Twardoch <adam@fontlab.com>.
2769
Werner Lembergcf2347c2014-06-17 09:01:04 +020027702014-06-17 Werner Lemberg <wl@gnu.org>
2771
Werner Lemberg231171f2014-06-17 09:14:32 +02002772 Partially revert commit from 2014-06-13.
2773
2774 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Move
2775 declaration of `p_first' and `p_last' out of the loop.
2776
27772014-06-17 Werner Lemberg <wl@gnu.org>
2778
Werner Lembergcf2347c2014-06-17 09:01:04 +02002779 * builds/unix/freetype2.m4: s/AC_PATH_PROG/AC_PATH_TOOL/.
2780
2781 This simplifies cross-compiling.
2782
Werner Lemberg6497b9c2014-06-13 09:28:00 +020027832014-06-13 Werner Lemberg <wl@gnu.org>
2784
Werner Lemberge5c0fff2014-06-13 14:01:20 +02002785 Fix more compiler warnings.
2786 Reported by Wojciech Mamrak <wmamrak@gmail.com>.
2787
2788 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
2789 Make integer constant unsigned.
2790
2791 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
2792 <TT_SBIT_TABLE_TYPE_SBIX>: Fix types.
2793 (tt_sbit_decoder_load_compound, tt_face_load_sbix_image): Add proper
2794 casts.
2795
27962014-06-13 Werner Lemberg <wl@gnu.org>
2797
Werner Lemberg6497b9c2014-06-13 09:28:00 +02002798 Fix compiler warnings.
2799 Reported by Wojciech Mamrak <wmamrak@gmail.com>.
2800
2801 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage),
Werner Lembergcbbf26b2014-07-17 17:27:12 +09002802 src/autofit/afmodule.c (af_property_set): Fix `signed' vs.
Werner Lemberg6497b9c2014-06-13 09:28:00 +02002803 `unsigned' issues.
2804
2805 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Make compiler
2806 happy.
2807
2808 * src/base/ftlcdfil.c (_ft_lcd_filter_fir): Use only four elements
2809 for `fir'.
2810 Fix `signed' vs. `unsigned' issues.
2811
2812 * src/sfnt/sfobjs.c (WRITE_BYTE): Removed, unused.
2813 (WRITE_USHORT, WRITE_ULONG): Add proper casts.
2814
2815 * src/truetype/ttgload.c (TT_Get_VMetrics): Add proper casts.
2816
2817 * src/truetype/ttinterp.c (Ins_DELTAP): Add proper casts for `B1'
2818 and `B2'.
2819
Alexey Petruchik02f21702014-05-16 08:09:43 +020028202014-05-16 Alexey Petruchik <alexey.petruchik@gmail.com>
2821
2822 [cmake] Add option to build OS X framework.
2823
2824 * CMakeLists.txt: Update accordingly.
2825
2826 * builds/mac/freetype-Info.plist: New file.
2827
Pavel Koshevoy15da66a2014-05-13 07:33:48 +020028282014-05-13 Pavel Koshevoy <pkoshevoy@gmail.com>
2829
2830 * CMakeLists.txt (BASE_SRCS): Add missing `ftbdf.c'.
2831
Werner Lemberg07e7b8a2014-05-11 08:00:25 +020028322014-05-11 Werner Lemberg <wl@gnu.org>
2833
Werner Lembergfaa21472014-05-11 12:44:00 +02002834 [autofit] Fix variable initializations.
2835
2836 * src/autofit/afhints.c (af_glyph_hints_reload): Assign default
2837 values to `in_dir' and `out_dir' for all points.
2838
28392014-05-11 Werner Lemberg <wl@gnu.org>
2840
Werner Lemberg07e7b8a2014-05-11 08:00:25 +02002841 [autofit] Fix crash with font `CabinSketch-Bold.ttf'.
2842
2843 Problem reported by Ralf S. Engelschall <rse@engelschall.com>.
2844
2845 * src/autofit/afhints.c (af_glyph_hints_reload): Fix threshold for
2846 finding first non-near point.
2847 Properly initialize non-near point deltas.
2848
Werner Lemberg63bef9a2014-05-01 07:16:05 +020028492014-05-01 Werner Lemberg <wl@gnu.org>
2850
Werner Lembergc576bb02014-05-01 17:24:19 +02002851 [autofit] Add blue-zone support for Devanagari.
2852
2853 This essentially moves the Devanagari script from the `Indic' hinter
2854 to the `Latin' hinter. Thanks to Girish Dalvi
2855 <girish.dalvi@gmail.com> for guidance with blue zone characters!
2856
2857 * src/autofit/afblue.dat: Add blue zone data for Devanagari.
2858
2859 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2860
2861 * src/autofit/afscript.h: Add Devanagari standard characters and
2862 move data out of AF_CONFIG_OPTION_INDIC block.
2863
2864 * src/autofit/afranges.c: Move Devanagari data out of
2865 AF_CONFIG_OPTION_INDIC block.
2866 Move U+20B9, (new) Rupee sign, from Latin to Devanagari.
2867
2868 * src/autofit/afstyles.h: Update Devanagari data; in particular, use
2869 AF_WRITING_SYSTEM_LATIN.
2870
28712014-05-01 Werner Lemberg <wl@gnu.org>
2872
Werner Lemberg63bef9a2014-05-01 07:16:05 +02002873 [autofit] Fix handling of neutral blue zones in stems.
2874
2875 * src/autofit/afhints.h (AF_Edge_Flags): New value
2876 `AF_EDGE_NEUTRAL'.
2877
2878 * src/autofit/aflatin.c (af_latin_hints_compute_blue_edges): Trace
2879 neutral blue zones with AF_EDGE_NEUTRAL.
2880 (af_latin_hint_edges): Skip neutral blue zones if necessary.
2881
Werner Lembergccfc4b42014-04-28 21:13:14 +020028822014-04-28 Werner Lemberg <wl@gnu.org>
2883
2884 [autofit] Introduce neutral blue zones to the latin module.
2885
2886 Such blue zones match either the top or the bottom of a contour. We
2887 need them for scripts where accent-like elements directly touch the
2888 base character (for example, some vowel signs in Devanagari, cf.
2889 U+0913 or U+0914).
2890
2891 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_NEUTRAL): New
2892 property.
2893
2894 * src/autofit/afblue.h: Regenerated.
2895
2896 * src/autofit/aflatin.h (AF_LATIN_IS_NEUTRAL_BLUE): New macro.
2897 (AF_LATIN_BLUE_NEUTRAL): New enumeration value.
2898
2899 * src/autofit/aflatin.c (af_latin_metrics_init_blues,
2900 af_latin_hints_compute_blue_edges): Handle neutral blue zones.
2901
Werner Lembergabb3fca2014-04-25 22:13:32 +020029022014-04-25 Werner Lemberg <wl@gnu.org>
2903
2904 * src/autofit/hbshim.c: Partially revert commit from 2014-04-17.
2905
2906 Using input glyph coverage data is simply wrong.
2907
2908 Problem reported by Nikolaus Waxweiler <madigens@gmail.com> and
2909 Mantas MikulÄ—nas <grawity@gmail.com>.
2910
Werner Lembergf1936372014-04-23 08:22:33 +020029112014-04-23 Werner Lemberg <wl@gnu.org>
2912
2913 * src/raster/ftraster.c (Vertical_Sweep_Span): Use drop-out mode.
2914
2915 This spot has been missed while introducing support for various
2916 drop-out modes years ago (including no drop-out mode, which this
2917 commit fixes).
2918
2919 Problem reported by Patrick Thomas <pthomas505@gmail.com>.
2920
Werner Lembergd9b44702014-04-22 07:33:07 +020029212014-04-22 Werner Lemberg <wl@gnu.org>
2922
2923 * src/sfnt/pngshim.c (error_callback): s/longjmp/ft_longjmp/.
2924
Werner Lemberg98e510e2014-04-20 22:11:27 +020029252014-04-20 Werner Lemberg <wl@gnu.org>
2926
2927 [autofit] Fix Savannah bug #42148.
2928
2929 The adaptation of the cjk auto-hinter module to blue stringsets in
2930 2013-08-25 had three severe bugs. Mea culpa.
2931
2932 1. Contrary to the latin auto-hinter, characters for reference and
2933 overshoot values of a blue zone are specified separately. Due to
2934 the screwed-up change it didn't work at all.
2935
2936 2. A boolean comparison was erroneously replaced with a cast,
2937 causing invalid results with the `^' operator later on. The
2938 visual artifact caused by this problem is the topic of the bug
2939 report.
2940
2941 3. Two flag values were inverted, causing incorrect assignment of
2942 reference and overshoot values.
2943
2944 * src/autofit/afblue.dat: Fix CJK bluestrings, introducing a new
2945 syntax to have both reference and overshoot characters in a single
2946 string. This is error #1.
2947 Add extensive comments.
2948
2949 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_CJK_FILL): Removed, no
2950 longer used.
Werner Lembergccfc4b42014-04-28 21:13:14 +02002951 (AF_BLUE_PROPERTY_CJK_TOP, AF_BLUE_PROPERTY_CJK_HORIZ): Fix values.
Werner Lemberg98e510e2014-04-20 22:11:27 +02002952 This is error #3.
2953
2954 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2955
2956 * src/autofit/afcjk.c (af_cjk_metrics_init_blues): Correct error #1.
2957 Use character `|' to separate characters for reference and overshoot
2958 values.
2959 Improve tracing messages, synchronizing them with the latin
2960 auto-hinter.
Werner Lembergccfc4b42014-04-28 21:13:14 +02002961 (af_cjk_hints_compute_blue_edges): Fix value of `is_top_right_blue'.
Werner Lemberg98e510e2014-04-20 22:11:27 +02002962 This is error #2.
2963 (af_cjk_align_linked_edge): Add tracing message.
2964
2965 * src/autofit/afcjk.h (AF_CJK_IS_FILLED_BLUE): Removed, no longer
2966 used.
2967
Werner Lembergbbd83132014-04-17 01:24:36 +020029682014-04-17 Werner Lemberg <wl@gnu.org>
2969
Werner Lemberg8c7fb782014-04-17 15:53:25 +02002970 [autofit] More coverage fixes for complex scripts.
2971
2972 * src/autofit/hbshim.c (af_get_coverage): Merge input glyph coverage
2973 of GSUB lookups into output coverage. Otherwise, ligatures are not
2974 handled properly.
2975 Don't check blue zone characters for default coverage.
2976
29772014-04-17 Werner Lemberg <wl@gnu.org>
2978
Werner Lembergbbd83132014-04-17 01:24:36 +02002979 Make `FT_Get_SubGlyph_Info' actually work.
2980
2981 * src/base/ftobjs.c (FT_Get_SubGlyph_Info): Return FT_Err_Ok
2982 if there is no error.
2983
Werner Lemberg181fd072014-04-15 16:47:05 +020029842014-04-15 Werner Lemberg <wl@gnu.org>
2985
2986 [afblue.pl]: Minor improvements.
2987
2988 * src/tools/afblue.pl: Allow whitespace before comments.
2989 Ignore whitespace in strings.
2990
Werner Lemberg8b1f2a62014-04-14 07:58:19 +020029912014-04-14 Werner Lemberg <wl@gnu.org>
2992
2993 [autofit] Improve coverage handling.
2994
2995 * src/autofit/hbshim.c (af_get_coverage): Don't exclude glyphs
2996 appearing in the GPOS table if we are processing the default
2997 coverage.
2998
David Weber76307872014-04-13 15:41:13 +020029992014-04-13 David Weber <weber.aulendorf@googlemail.com>
3000
3001 [smooth] Fix stand-alone compilation.
3002
3003 * src/smooth/ftgrays.c (FT_BEGIN_STMNT, FT_END_STMNT): Define.
3004
Werner Lemberg8a94b1e2014-04-12 20:44:33 +020030052014-04-12 Werner Lemberg <wl@gnu.org>
3006
3007 [autofit] Redesign the recognition algorithm of strong points.
3008
3009 In particular, local extrema without horizontal or vertical segments
3010 are better recognized:
3011
3012 + A + D
3013 \ /
3014 \ /
3015 \ /
3016 \ /
3017 \ + C
3018 \ /
3019 B +/
3020
3021 If the distances AB and CD are large, point B wasn't previously
3022 detected as an extremum since the `ft_corner_is_flat' function
3023 `swallowed' BC regardless of its direction, tagging point B as weak.
3024 The next iteration started at B and made `ft_corner_is_flat' swallow
3025 point C, tagging it as weak also, et voilà.
3026
3027 To improve that, another pass gets now performed before calling
3028 `ft_corner_is_flat' to improve the `topology' of an outline: A
3029 sequence of non-horizontal or non-vertical vectors that point into
3030 the same quadrant are handled as a single, large vector.
3031
3032 Additionally, distances of near points are now accumulated, which
3033 makes the auto-hinter handle them as if they were prepended to the
3034 next non-near vector.
3035
3036 This generally improves the auto-hinter's rendering results.
3037
3038 * src/autofit/afhints.c (af_glyph_hints_reload): Implement it.
3039
3040 * src/autofit/afhints.h (AF_FLAGS): Remove no longer used flag
3041 `AF_FLAG_NEAR'.
3042
Werner Lemberg71f53e12014-04-05 16:27:19 +020030432014-04-05 Werner Lemberg <wl@gnu.org>
3044
3045 [autofit] Improve scoring algorithm for identifying stems.
3046
3047 Problem reported by Karsten Lücke <karsten.luecke@kltf.de>.
3048
3049 The new algorithm takes care of the width of stems: If the distance
3050 between two segments is larger than the largest stem width, the
3051 demerits quickly increase for larger distances. This improves
3052 hinting of slanted fonts (especially if the inner parts of serifs
3053 have non-horizontal `shoulders'), avoiding false stem links.
3054
3055 * src/autofit/aflatin.c (af_latin_hints_link_segments): Use largest
3056 stem width (if available) to compute better demerits for distances
3057 between stems.
3058 (af_latin_hints_detect_features): Pass stem width array and array
3059 size.
3060 (af_latin_metrics_init_widths): Updated to use original algorithm.
3061 (af_latin_hints_apply): Updated to use new algorithm.
3062
3063 * src/autofit/aflatin.h: Updated.
3064 * src/autofit/afcjk.c: Updated.
3065
Werner Lembergf8555b52014-04-03 05:45:38 +020030662014-04-03 Werner Lemberg <wl@gnu.org>
3067
3068 Don't require `gzip' module for `sfnt'.
3069
3070 Reported by Preet <prismatic.project@gmail.com>.
3071
3072 * src/sfnt/sfobjs.c (woff_open_font): Guard use of
3073 FT_Gzip_Uncompress with FT_CONFIG_OPTION_USE_ZLIB.
3074
Werner Lembergf41070f2014-03-27 17:38:23 +010030752014-03-27 Werner Lemberg <wl@gnu.org>
3076
3077 Fix Savannah bug #38235.
3078
3079 Work around a bug in pkg-config version 0.28 and earlier: If a
3080 variable value gets surrounded by doublequotes (in particular values
3081 for the `prefix' variable), the prefix override mechanism fails.
3082
3083 * builds/unix/freetype2.in: Don't use doublequotes.
3084 * builds/unix/unix-def.in (freetype.pc): Escape spaces in directory
3085 names with backslashes.
3086
Werner Lembergab76d972014-03-24 19:45:03 +010030872014-03-24 Werner Lemberg <wl@gnu.org>
3088
3089 Fix Savannah bug #41946.
3090
3091 Based on a patch from Marek Kašík <mkasik@redhat.com>.
3092
3093 * builds/unix/configure.raw (LIBS_CONFIG): Remove.
3094 * builds/unix/freetype-config.in (libs): Hard-code value.
3095 * builds/unix/unix-def.in: Updated.
3096
Werner Lembergd5159922014-03-22 06:20:54 +010030972014-03-22 Werner Lemberg <wl@gnu.org>
3098
3099 Another revert for the change from 2014-03-18.
3100
3101 Problem reported by Nikolaus Waxweiler <madigens@gmail.com>.
3102
3103 * src/base/ftcalc.c (FT_MulFix): Ensure that an `FT_MulFix' symbol
3104 gets always exported.
3105
Werner Lembergf0c471a2014-03-20 07:13:12 +010031062014-03-20 Werner Lemberg <wl@gnu.org>
3107
3108 CMakeLists.txt: Another fix for include directories.
3109
3110 Problem reported by Taylor Holberton <taylorcholberton@gmail.com>.
3111
Werner Lembergcc7cf2c2014-03-19 07:35:35 +010031122014-03-19 Werner Lemberg <wl@gnu.org>
3113
Werner Lemberg606c74f2014-03-19 23:46:42 +01003114 CMakeLists.txt: Fix include directories.
3115
3116 Problem reported by Taylor Holberton <taylorcholberton@gmail.com>.
3117
31182014-03-19 Werner Lemberg <wl@gnu.org>
3119
Werner Lembergcc7cf2c2014-03-19 07:35:35 +01003120 Partially revert last commit.
3121
3122 Found by Alexei.
3123
3124 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Initializing
3125 those variables is plain wrong, since we are in a loop.
3126
Sean McBride87628722014-03-18 08:39:35 +010031272014-03-18 Sean McBride <sean@rogue-research.com>
3128 Werner Lemberg <wl@gnu.org>
3129
3130 Fix clang warnings.
3131
3132 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Initialize
3133 some variables.
3134
3135 * src/base/ftcalc.c (FT_MulFix): Only use code if
3136 `FT_MULFIX_INLINED' is not defined.
3137
3138 * src/bdf/bdfdrivr.c (bdf_cmap_class), src/cache/ftcbasic.c
3139 (ftc_basic_image_family_class, ftc_basic_image_cache_class,
3140 ftc_basic_sbit_family_class, ftc_basic_sbit_cache_class),
3141 src/cache/ftccmap.c (ftc_cmap_cache_class), src/cache/ftcmanag.c
3142 (ftc_size_list_class, ftc_face_list_class), src/pcf/pcfdrivr.c
3143 (pcf_cmap_class), src/pfr/pfrdrivr.c (pfr_metrics_service_rec): Make
3144 function static.
3145
3146 * src/type1/t1driver.c (t1_ps_get_font_value): Remove redundant
3147 code.
3148
Werner Lemberg23367ff2014-03-17 07:33:14 +010031492014-03-17 Werner Lemberg <wl@gnu.org>
3150
3151 Fix Savannah bug #41869.
3152
3153 This works around a problem with HarfBuzz (<= 0.9.26), which doesn't
3154 validate glyph indices returned by
3155 `hb_ot_layout_lookup_collect_glyphs'.
3156
3157 * src/autofit/hbshim.c (af_get_coverage): Guard `idx'.
3158
3159 * docs/CHANGES: Updated.
3160
Werner Lemberg03181682014-03-14 08:06:06 +010031612014-03-14 Werner Lemberg <wl@gnu.org>
3162
3163 * builds/unix/configure.raw: Don't show error messages of `which'.
3164
Alan Coopersmithed372b72014-03-09 06:14:12 +010031652014-03-09 Alan Coopersmith <alan.coopersmith@oracle.com>
3166
3167 Fix cppcheck 1.64 warning.
3168
3169 * src/autofit/afglobal.c (af_face_globals_new): Catch NULL pointer
3170 dereference in case of error.
3171
Werner Lemberg1a69dc72014-03-09 06:06:58 +010031722014-03-09 Sean McBride <sean@rogue-research.com>
3173
3174 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Remove clang warning.
3175
Werner Lemberg05565362014-03-06 18:56:58 +010031762014-03-06 Werner Lemberg <wl@gnu.org>
3177
Werner Lembergec8853c2014-03-06 19:13:45 +01003178 * Version 2.5.3 released.
3179 =========================
3180
3181
3182 Tag sources with `VER-2-5-3'.
3183
3184 * docs/VERSION.DLL: Update documentation and bump version number to
3185 2.5.3.
3186
3187 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
3188 builds/windows/vc2005/index.html,
3189 builds/windows/vc2008/freetype.vcproj,
3190 builds/windows/vc2008/index.html,
3191 builds/windows/vc2010/freetype.vcxproj,
3192 builds/windows/vc2010/index.html,
3193 builds/windows/visualc/freetype.dsp,
3194 builds/windows/visualc/freetype.vcproj,
3195 builds/windows/visualc/index.html,
3196 builds/windows/visualce/freetype.dsp,
3197 builds/windows/visualce/freetype.vcproj,
3198 builds/windows/visualce/index.html,
3199 builds/wince/vc2005-ce/freetype.vcproj,
3200 builds/wince/vc2005-ce/index.html,
3201 builds/wince/vc2008-ce/freetype.vcproj,
3202 builds/wince/vc2008-ce/index.html: s/2.5.2/2.5.3/, s/252/253/.
3203
3204 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 3.
3205
3206 * builds/unix/configure.raw (version_info): Set to 17:2:11.
3207 * CMakeLists.txt (VERSION_PATCH): Set to 3.
3208 * docs/CHANGES: Updated.
3209
32102014-03-06 Werner Lemberg <wl@gnu.org>
3211
Werner Lemberg05565362014-03-06 18:56:58 +01003212 Fixes for compilation with C++.
3213
3214 * src/autofit/hbshim.c (scripts): Change type to `hb_script_t'.
3215 (af_get_coverage): Updated.
3216 (COVERAGE): Add cast.
3217
Sean McBrideb24e8d32014-03-06 14:54:22 +010032182014-03-06 Sean McBride <sean@rogue-research.com>
3219
3220 Remove more clang analyzer warnings.
3221
3222 * src/bdf/bdflib.c (_bdf_readstream), src/truetype/ttgload.c
3223 (TT_Load_Glyph): Remove dead stores.
3224
Werner Lemberga32758f2014-03-05 08:02:46 +010032252014-03-05 Werner Lemberg <wl@gnu.org>
3226
3227 * builds/unix/configure.raw: Simplify.
3228
suzuki toshiya382f3ef2014-03-05 10:19:15 +090032292014-03-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3230
3231 Fix a bug in configure in library dependency setting
Werner Lemberga32758f2014-03-05 08:02:46 +01003232 Reported in https://bugs.freedesktop.org/show_bug.cgi?id=75652.
suzuki toshiya382f3ef2014-03-05 10:19:15 +09003233
3234 * builds/unix/configure.raw: Use `x"${xxx}" != xno' style.
3235
Werner Lembergf48f7dc2014-03-04 04:40:07 +010032362014-03-04 Werner Lemberg <wl@gnu.org>
3237
3238 Minor fix for `make devel'.
3239
3240 * builds/freetype.mk (INCLUDE_FLAGS) [DEVEL_DIR]: Don't use
3241 pkg-config for bzip2 since not all GNU/Linux distributions have
3242 `bzip2.pc' (and the header file `bzlib.h' is located in /usr/include
3243 normally).
3244
Werner Lemberg7ac76b52014-03-04 04:29:17 +010032452014-03-04 Sean McBride <sean@rogue-research.com>
3246
3247 Fix several clang static analyzer dead store warnings.
3248
3249 * src/autofit/afhints.c (af_glyph_hints_reload,
3250 af_glyph_hints_align_weak_points): Remove unnecessary assignments.
3251
3252 * src/bdf/bdflib.c (bdf_font_load): Ditto.
3253
3254 * src/pshinter/pshalgo.c (psh_glyph_compute_extrema,
3255 psh_glyph_interpolate_other_points): Ditto.
3256
3257 * src/type1/t1load.c (T1_Set_MM_Blend): Ditto.
3258
Werner Lemberg93ebcbd2014-03-03 07:13:45 +010032592014-03-03 Werner Lemberg <wl@gnu.org>
3260
3261 Rewrite library option handling in `configure'.
3262
3263 o Introduce `auto' value for `--with-XXX' library options; this is
3264 now the default.
3265
3266 o First use `pkg-config' for library detection, then fall back to
3267 other tests.
3268
3269 * builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
3270 --with-harfbuzz): Rewrite.
3271 Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
3272 variables to collect data for `freetype2.pc' and `freetype-config'.
3273 (FT2_EXTRA_LIBS): Renamed to ...
3274 (ft2_extra_libs): This since it gets no longer substituted.
3275 (REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
3276 New output variables, replacing `XXX_PKG' and `LIBXXX'.
3277 Add notice at the end of `configure' showing the library
3278 configuration.
3279
3280 * builds/unix/freetype-config.in (--static): New command line
3281 option.
3282 (libs): Updated.
3283 (staticlibs): New variable, to be used if `--static' is given.
Werner Lemberg8fa69a82014-12-03 20:07:14 +01003284 * docs/freetype-config.1: Document `--static'.
Werner Lemberg93ebcbd2014-03-03 07:13:45 +01003285
3286 * builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
3287
Werner Lemberg86026a42014-03-01 06:57:19 +010032882014-03-01 Werner Lemberg <wl@gnu.org>
3289
Werner Lemberge962a912014-03-01 21:00:02 +01003290 Avoid `long long' warnings with older gcc compilers.
3291 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
3292
3293 * builds/unix/configure.raw: Don't use gcc's `-pedantic' flag for
3294 versions < 4.6. This is especially needed for Max OS X since this
3295 OS runs a gcc variant (or emulation) based on version 4.2.1.
3296
32972014-03-01 Werner Lemberg <wl@gnu.org>
3298
Werner Lemberg6030a9f2014-03-01 14:01:12 +01003299 * docs/INSTALL.CROSS: Revised and updated.
3300
33012014-03-01 Werner Lemberg <wl@gnu.org>
3302
Werner Lemberg646db052014-03-01 12:48:07 +01003303 Make `make clean' remove `freetype2.pc'.
3304
3305 This is a generated file at build time, not configure time.
3306
3307 * builds/unix/unix-def.in (DISTCLEAN): Move `freetype2.pc' to ...
3308 (CLEAN): This variable.
3309
33102014-03-01 Werner Lemberg <wl@gnu.org>
3311
Werner Lemberg00c79ed2014-03-01 12:32:20 +01003312 Use pkg-config for detecting libpng and libbz2 also.
3313
3314 * builds/unix/configure.raw (HAVE_PKG): New variable.
3315 Search for libbz2 using `pkg-config'; s/BZ2/BZIP2/.
3316 Search for libpng using `pkg-config'.
3317 Fix definition of `LIBHARFBUZZ' variable.
3318 * builds/unix/freetype-config.in ($libs): Updated.
3319 * builds/unix/freetype2.in: Add `URL' field.
3320 Update `Requires.private' and `Libs.private'.
3321 * builds/unix/unix-def.in: Updated.
3322
33232014-03-01 Werner Lemberg <wl@gnu.org>
3324
Werner Lemberg86026a42014-03-01 06:57:19 +01003325 Add configure support for HarfBuzz.
3326
3327 * builds/unix/pkg.m4: New file.
3328 * builds/unix/configure.raw: Search for libharfbuzz using
3329 `pkg-config'.
3330 Add `--without-harfbuzz' option.
3331 * builds/unix/freetype-config.in, builds/unix/freetype2.in,
3332 builds/unix/unix-def.in (freetype-config, freetype2.pc): Handle
3333 HarfBuzz.
3334
3335 * docs/INSTALL.UNIX: Document interdependency of Freetype with
3336 HarfBuzz.
3337
Alexei Podtelezhnikov6adda682014-02-28 09:24:26 +010033382014-02-28 Alexei Podtelezhnikov <apodtele@gmail.com>
3339
3340 [cff] Math simplifications.
3341
3342 * src/cf2blues.c (cf2_blues_init): Use `FT_MulDiv'.
3343 * src/cf2ft.c (cf2_getScaleAndHintFlag): Use simple division.
3344
Dave Arnold0eae6eb2014-02-28 07:40:01 +010033452014-02-28 Dave Arnold <darnold@adobe.com>
3346
Dave Arnold135c3fa2014-02-28 07:42:42 +01003347 [cff] Fix Savannah bug #41697, part 2.
3348
3349 * src/cff/cf2ft.c (cf2_initLocalRegionBuffer,
3350 cf2_initGlobalRegionBuffer): It is possible for a charstring to call
3351 a subroutine if no subroutines exist. This is an error but should
3352 not trigger an assert. Split the assert to account for this.
3353
33542014-02-28 Dave Arnold <darnold@adobe.com>
3355
Dave Arnold0eae6eb2014-02-28 07:40:01 +01003356 [cff] Fix Savannah bug #41697, part 1.
3357
3358 * src/cff/cf2hints.c (cf2_hintmap_build): Return when `hintMask' is
3359 invalid. In this case, it is not safe to use the length of
3360 `hStemHintArray'; the exception has already been recorded in
3361 `hintMask'.
3362
Werner Lembergeee4ff82014-02-26 18:12:36 +010033632014-02-26 Werner Lemberg <wl@gnu.org>
3364
Werner Lemberga2b5f662014-02-26 19:50:18 +01003365 [sfnt] Fix Savannah bug #41696.
3366
3367 * src/sfnt/ttcmap.c (tt_cmap0_validate, tt_cmap2_validate,
3368 tt_cmap4_validate, tt_cmap14_validate): Fix limit tests.
3369
33702014-02-26 Werner Lemberg <wl@gnu.org>
3371
Werner Lembergeee4ff82014-02-26 18:12:36 +01003372 [winfnt] Fix Savannah bug #41694.
3373
3374 * src/winfonts/winfnt.c (FNT_Load_Glyph): Check glyph offset.
3375
33762014-02-26 Werner Lemberg <wl@gnu.org>
Werner Lemberg9a567642014-02-26 13:08:07 +01003377
Werner Lemberg08c628d2014-02-26 14:18:03 +01003378 [cff] Fix Savannah bug #41693.
3379
3380 * src/cff/cffload.c (CFF_Load_FD_Select): Reject empty array.
3381
Werner Lembergeee4ff82014-02-26 18:12:36 +010033822014-02-26 Werner Lemberg <wl@gnu.org>
Werner Lemberg08c628d2014-02-26 14:18:03 +01003383
Werner Lemberg9a567642014-02-26 13:08:07 +01003384 [bdf] Fix Savannah bug #41692.
3385
3386 bdflib puts data from the input stream into a buffer in chunks of
3387 1024 bytes. The data itself gets then parsed line by line, simply
3388 increasing the current pointer into the buffer; if the search for
3389 the final newline character exceeds the buffer size, more data gets
3390 read.
3391
3392 However, in case the current line's end is very near to the buffer
3393 end, and the keyword to compare with is longer than the current
3394 line's length, an out-of-bounds read might happen since `memcmp'
3395 doesn't stop properly at the string end.
3396
3397 * src/bdf/bdflib.c: s/ft_memcmp/ft_strncmp/ to make comparisons
3398 stop at string ends.
3399
suzuki toshiya91c7a972014-02-17 16:38:31 +090034002014-02-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3401
3402 [autofit] Fix `make multi' compilation.
3403
suzuki toshiyacc9a0c22014-02-17 16:43:54 +09003404 * src/autofit/hbshim.c: Include `afglobal.h' and `aftypes.h'.
suzuki toshiya91c7a972014-02-17 16:38:31 +09003405
Werner Lemberg6b290fd2014-02-19 09:26:54 +010034062014-02-19 Werner Lemberg <wl@gnu.org>
3407 Simon Bünzli <zeniko@gmail.com>
3408
3409 Fix Savannah bug #32902.
3410
3411 Patch taken from
3412
3413 https://code.google.com/p/sumatrapdf/source/browse/trunk/ext/_patches/freetype2.patch?spec=svn8620&r=8620#87
3414
3415 with slight modifications.
3416
3417 * src/type1/t1parse.c (T1_Get_Private_Dict): Add heuristic test to
3418 handle fonts that incorrectly use \r at the beginning of an eexec
3419 block.
3420
Simon Bünzlidf14e6c2014-02-19 08:42:52 +010034212014-02-19 Simon Bünzli <zeniko@gmail.com>
3422
3423 Fix Savannah bug #41590.
3424
3425 * src/type1/t1load.c (parse_encoding): Protect against invalid
3426 number.
3427
Dave Arnold89a94d42014-02-12 23:45:47 +010034282014-02-12 Dave Arnold <darnold@adobe.com>
3429
3430 [cff] Optimize by using `FT_MulDiv'.
3431 Suggested by Alexei.
3432
3433 * src/cff/cf2font.c (cf2_computeDarkening): Do it.
3434
Werner Lemberg85ee27a2014-02-12 23:27:41 +010034352014-02-12 Werner Lemberg <wl@gnu.org>
3436
3437 Fix Savannah bug #41465.
3438
3439 * builds/unix/unix-def.in (CLEAN): Add `freetype-config'.
3440 (DISTCLEAN): Remove `freetype-config'.
3441
Sean McBride7be2a942014-02-08 13:55:38 +010034422014-02-08 Sean McBride <sean@rogue-research.com>
3443
3444 Fix clang static analyzer and compiler warnings.
3445
3446 * src/autofit/afhints.c (af_glyph_hints_align_weak_points),
3447 src/autofit/afloader (af_loader_load_g) <FT_GLYPH_FORMAT_COMPOSITE>,
3448 src/base/ftcalc.c (FT_MSB), src/base/ftoutln.c
3449 (FT_Outline_Decompose), src/bdf/bdfdrivr.c (bdf_interpret_style),
3450 src/cff/cffparse.c (cff_parse_integer), src/cid/cidparse.c
3451 (cid_parser_new), src/pfr/pfrload.c (pfr_phy_font_load),
3452 src/raster/ftraster.c (Decompose_Curve), src/sfnt/sfdriver.c
3453 (sfnt_get_ps_name), src/sfnt/ttcmap.c (tt_cmap12_next,
3454 tt_cmap13_next), src/smooth/ftgrays.c (gray_hline): Remove dead
3455 code.
3456
3457 * src/autofit/afmodule.c (af_property_get_face_globals,
3458 af_property_set, af_property_get), src/base/ftbitmap.c
3459 (ft_gray_for_premultiplied_srgb_bgra): Make functions static.
3460
3461 * src/base/ftobjs.c (ft_remove_renderer): Protect against
3462 library == NULL.
3463 (ft_property_do): Make function static.
3464
3465 * src/base/ftrfork.c: Include `ftbase.h'.
3466
3467 * src/sfnt/ttsbit.c (tt_face_load_sbix_image)
3468 [!FT_CONFIG_OPTION_USE_PNG], src/type1/t1gload.c
3469 (T1_Compute_Max_Advance): Avoid compiler warning.
3470
3471 * src/truetype/ttinterp.c (TT_New_Context): Reduce scope of
3472 variable.
3473
Werner Lembergab98c5e2014-02-08 11:34:33 +010034742014-02-08 Werner Lemberg <wl@gnu.org>
3475
3476 Fix Windows build directories.
3477
3478 The build target is now `windows' instead of `win32'.
3479
3480 Problem reported by Nickolas George <darknova.clan@gmail.com>.
3481
3482 * builds/modules.mk: Don't use `win32' and `win16' (!) but
3483 `windows'.
3484
3485 * builds/windows/detect.mk, builds/windows/win32-def.mk:
3486 s/win32/windows/.
3487
Eugen Sawina8ceae42014-02-08 06:30:06 +010034882014-02-08 Eugen Sawin <esawin@mozilla.com>
3489
3490 Fix Savannah bug #41507.
3491
3492 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap)
3493 [!FT_CONFIG_OPTION_USE_PNG] <17, 17, 19>: Fix error handling.
3494
Dave Arnold355b3592014-02-08 06:23:04 +010034952014-02-08 Dave Arnold <darnold@adobe.com>
3496
3497 [cff] Fix minor performance bug.
3498
3499 * src/cff/cf2font.c (cf2_font_setup): Darkening amount and blue zone
3500 calculations are now cached and not recomputed on each glyph.
3501
Werner Lemberg6dce1362014-02-05 15:40:47 +010035022014-02-05 Werner Lemberg <wl@gnu.org>
3503
3504 Fix problems with perl 5.8.8 as distributed with current MinGW.
3505
3506 * src/tools/afblue.pl: Work-around for Perl bug #63402.
3507 (string_re): Avoid `possessive quantifiers', which have been
3508 introduced in Perl version 5.10.
3509
Werner Lemberga8772912014-02-04 11:36:08 +010035102014-02-04 Werner Lemberg <wl@gnu.org>
3511
Werner Lembergd87f9a62014-02-04 16:14:09 +01003512 Fix compilation with MinGW.
3513
3514 Right now, compilation out of the box with latest MinGW is broken
3515 due to bugs in header files of mingwrt 4.0.3 in strict ANSI mode,
3516 cf.
3517
3518 https://sourceforge.net/p/mingw/bugs/2024/
3519 https://sourceforge.net/p/mingw/bugs/2046/
3520
3521 * builds/unix/configure.raw: Don't set `-ansi' flag for MinGW.
3522
35232014-02-04 Werner Lemberg <wl@gnu.org>
3524
Werner Lemberga8772912014-02-04 11:36:08 +01003525 [autofit] Minor fix.
3526
3527 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
3528 src/autofit/aflatin.c (af_latin_metrics_init_widths): Fix handling
3529 of alternative standard characters.
3530 This also fixes a compilation warning in non-debug mode.
3531
Werner Lembergee3778d2014-02-03 11:16:47 +010035322014-02-03 Werner Lemberg <wl@gnu.org>
3533
3534 [cff] Fix Savannah bug #41363.
3535
3536 * src/cff/cf2ft.c (cf2_checkTransform): Convert assertion into
3537 parameter check.
3538 (cf2_decoder_parse_charstrings): Call `cf2_checkTransform' only if
3539 we are scaling the outline.
3540 (cf2_getPpemY): Remove problematic assertion.
3541
Werner Lemberga3364002014-01-26 09:45:23 +010035422014-01-26 Werner Lemberg <wl@gnu.org>
3543
3544 [autofit] Introduce two more slots for standard characters.
3545
3546 This is useful for OpenType features like `c2sc' (caps to small
3547 caps) that don't have lowercase letters by definition, or other
3548 features that mainly operate on numerals.
3549
3550 * src/autofit/afscript.h: Add more standard characters.
3551
3552 * src/autofit/aftypes.h: Update use of `SCRIPT' macro.
3553 (AF_ScriptClassRec): Add members to hold two more standard
3554 characters.
3555 (AF_DEFINE_SCRIPT_CLASS): Updated.
3556
3557 * src/autofit/afglobal.c, src/autofit/afglobal.h,
3558 * src/autofit/afpic.c, src/autofit/afranges.h, src/autofit/hbshim.c:
3559 Update use of `SCRIPT' macro.
3560
3561 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
3562 src/autofit/aflatin.c (af_latin_metrics_init_widths): Scan two more
3563 standard characters.
3564
Werner Lembergeb7691c2014-01-24 19:04:22 +010035652014-01-24 Werner Lemberg <wl@gnu.org>
3566
3567 Fix Savannah bug #41320.
3568
3569 * src/autofit/aflatin.c (af_latin_metrics_init_blues)
3570 <AF_LATIN_IS_LONG_BLUE>: Avoid negative index of `last'.
3571
Werner Lemberg8b281f82014-01-23 08:14:53 +010035722014-01-23 Werner Lemberg <wl@gnu.org>
3573
Werner Lemberg752f3912014-01-23 09:14:25 +01003574 Fix Savannah bug #41310.
3575
3576 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap) <glyph_format==5>:
3577 Don't check metrics, which this format doesn't have.
3578 This is another correction to the commit from 2013-11-21.
3579
35802014-01-23 Werner Lemberg <wl@gnu.org>
3581
Werner Lemberg8b281f82014-01-23 08:14:53 +01003582 Fix Savannah bug #41309.
3583
3584 * src/type1/t1load.c (t1_parse_font_matrix): Properly handle result
3585 of `T1_ToFixedArray'.
3586
3587 * src/cid/cidload.c (cid_parse_font_matrix): Synchronize with
3588 `t1_parse_font_matrix'.
3589
3590 * src/type42/t42parse.c (t42_parse_font_matrix): Synchronize with
3591 `t1_parse_font_matrix'.
3592 (t42_parse_encoding): Synchronize with `t1_parse_encoding'.
3593
3594 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_BBOX>,
3595 <T1_FIELD_TYPE_MMOX>: Properly handle result of `ps_tofixedarray'.
3596
Werner Lembergff8dc312014-01-22 09:19:57 +010035972014-01-22 Werner Lemberg <wl@gnu.org>
3598
3599 * src/autofit/hbshim.c (af_get_coverage): Fix memory leaks.
3600
Werner Lemberg6a700782014-01-16 08:55:40 +010036012014-01-16 Werner Lemberg <wl@gnu.org>
3602
3603 [autofit] Improve tracing of style coverages.
3604
3605 * include/internal/fttrace.h: Add `afglobal' for tracing style
3606 coverages.
3607
3608 * src/autofit/afglobal.c: Include FT_INTERNAL_DEBUG_H.
3609 (FT_COMPONENT): Define.
3610 (af_face_globals_compute_style_coverage): Trace `gstyles' array
3611 data.
3612
Werner Lemberg7cbfdff2014-01-09 07:26:06 +010036132014-01-09 Werner Lemberg <wl@gnu.org>
3614
3615 Fix Savannah bug #41158.
3616
3617 * builds/unix/install.mk (install): Create man page directory.
3618
Chongyu Zhu94c66942014-01-08 08:52:59 +010036192014-01-08 Chongyu Zhu <lembacon@gmail.com>
3620
3621 [arm] Fix Savannah bug #41138, part 2.
3622
3623 * builds/unix/ftconfig.in (FT_MulFix_arm), include/config/ftconfig.h
3624 (FT_MulFix_arm), src/truetype/ttinterp.c (TT_MulFix14_arm): Fix
3625 preprocessor conditionals for `add.w'.
3626
Werner Lembergc46fa862014-01-08 08:45:40 +010036272014-01-08 Werner Lemberg <wl@gnu.org>
3628
3629 [autofit] Fix Savannah bug #41138, part 1.
3630
3631 * src/tools/afblue.pl <Handling #endif>: Produce correct auxiliary
3632 enumeration names for generated `#else'.
3633
3634 * src/autofit/afblue.h: Regenerated.
3635
Werner Lemberg3e5a3742014-01-06 07:53:10 +010036362014-01-06 Werner Lemberg <wl@gnu.org>
3637
3638 Add manual page for `freetype-config'.
3639 Contributed by Nis Martensen <nis.martensen@web.de>.
3640
3641 * docs/freetype-config.1: New file.
3642
3643 * builds/unix/unix-def.in (mandir): Define.
3644 * builds/unix/install.mk (install, uninstall): Handle manpage.
3645
Werner Lemberg991cbcc2014-01-05 13:24:56 +010036462014-01-05 Werner Lemberg <wl@gnu.org>
3647
3648 [autofit] Minor fixes for `afblue.pl'.
3649
3650 * src/tools/afblue.pl (aux_name): Don't use `reverse'.
3651 <Handling #endif>: Use proper indentation for generated `#else'.
3652
3653 * src/autofit/afblue.h: Regenerated.
3654
Werner Lemberg0d977442014-01-04 11:46:34 +010036552014-01-04 Werner Lemberg <wl@gnu.org>
3656
3657 [autofit] Fix Indic scripts.
3658
3659 Split the single, incorrect Indic entry into separate scripts so
3660 that the covered ranges are the same: Bengali, Devanagari, Gujarati,
3661 Gurmukhi, Kannada, Limbu, Malayalam, Oriya, Sinhala, Sundanese,
3662 Syloti Nagri, Tamil, Telugu, and Tibetan. At the same time, remove
3663 entries for Meetai Mayak and Sharada – the Unicode ranges were
3664 incorrect (and nobody has complained about that), fonts are scarce
3665 for those scripts, and the Indic auto-hinter support is rudimentary
3666 anyways.
3667
3668 * src/autofit/afscript.h: Updated, using AF_CONFIG_OPTION_INDIC and
3669 AF_CONFIG_OPTION_CJK.
3670
3671 * src/autofit/afstyles.h (STYLE_DEFAULT_INDIC): New auxiliary macro.
3672 Use it, together with AF_CONFIG_OPTION_INDIC and
3673 AF_CONFIG_OPTION_CJK, to update.
3674
3675 * src/autofit/afranges.c [AF_CONFIG_OPTION_INDIC]: Updated.
3676 [!AF_CONFIG_OPTION_INDIC, !AF_CONFIG_OPTION_CJK]: Removed.
3677 Sort entries by tags.
3678
Werner Lemberg5c7f5502014-01-03 10:48:26 +010036792014-01-03 Werner Lemberg <wl@gnu.org>
3680
Werner Lembergecdb0e32014-01-03 20:49:31 +01003681 [autofit] Thinko.
3682
3683 * src/autofit/hbshim.c (af_get_char_index): Similar to
3684 `af_get_coverage', reject glyphs which are not substituted.
3685
36862014-01-03 Werner Lemberg <wl@gnu.org>
3687
Werner Lemberga42f9182014-01-03 18:29:41 +01003688 [autofit] Fix handling of default coverages.
3689
Werner Lemberg1b5bc892014-01-03 18:33:24 +01003690 With this commit, the implementation of coverage handling is
3691 completed.
3692
3693 * src/autofit/hbshim.c (af_get_coverage): Exit early if nothing to
3694 do.
3695 Reject coverages which don't contain appropriate glyphs for blue
3696 zones.
3697
36982014-01-03 Werner Lemberg <wl@gnu.org>
3699
3700 [autofit] Fix handling of default coverages.
3701
Werner Lemberga42f9182014-01-03 18:29:41 +01003702 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
3703 First handle non-default coverages, then the default coverage of the
3704 default script, and finally the other default coverages.
3705
37062014-01-03 Werner Lemberg <wl@gnu.org>
3707
Werner Lembergf45749b2014-01-03 18:09:36 +01003708 [autofit] Fix scaling of HarfBuzz shaping.
3709
3710 * src/autofit/hbshim.c (af_get_char_index): Scale to units per EM.
3711
37122014-01-03 Werner Lemberg <wl@gnu.org>
3713
Werner Lemberg5c7f5502014-01-03 10:48:26 +01003714 [autofit] Better ftgrid support.
3715
3716 * src/autofit/afhints.c (af_glyph_hints_get_segment_offset): Add
3717 parameters `is_blue' and `blue_offset'.
3718
Werner Lemberg73cc8332014-01-01 07:10:36 +010037192014-01-01 Werner Lemberg <wl@gnu.org>
3720
Werner Lemberg55cd7e02014-01-02 13:07:48 +01003721 [autofit] Remove some styles.
3722
3723 * src/autofit/afcover.h: Remove coverages for alternative fractions,
3724 denominators, numerators, and fractions.
3725
3726 * src/autofit/afstyles.h (META_STYLE_LATIN): Updated.
3727
37282014-01-01 Werner Lemberg <wl@gnu.org>
3729
Werner Lembergc973e672014-01-01 16:34:42 +01003730 [autofit] Add more styles.
3731
3732 * src/autofit/afstyles.h (STYLE_LATIN, META_STYLE_LATIN): New
3733 auxiliary macros; use them to define styles for Cyrillic, Greek, and
3734 Latin.
3735
3736 * src/autofit/afcover.h: Remove coverage for oldstyle figures.
3737 Since those digits are used in combination with ordinary letters, it
3738 makes no sense to handle them separately.
3739
3740 * src/autofit/afglobal.c (af_face_globals_get_metrics): Don't limit
3741 `options' parameter to 4 bits.
3742
37432014-01-01 Werner Lemberg <wl@gnu.org>
3744
Werner Lembergabb2f732014-01-01 08:00:16 +01003745 [autofit] Fix style assignments to glyphs.
3746
3747 * src/autofit/hbshim.c (af_get_coverage)
3748 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Scan GPOS coverage of features also
3749 so that we can skip glyphs that have both GSUB and GPOS data.
3750
37512014-01-01 Werner Lemberg <wl@gnu.org>
3752
Werner Lemberg0950f3a2014-01-01 07:48:20 +01003753 * src/autofit/hbshim.c: s/{lookups,glyphs}/gsub_{lookups,glyphs}/.
3754
37552014-01-01 Werner Lemberg <wl@gnu.org>
3756
Werner Lemberg73cc8332014-01-01 07:10:36 +01003757 [autofit] Implement and use `af_get_char_index' with HarfBuzz.
3758
3759 * src/autofit/hbshim.c (COVERAGE) [FT_CONFIG_OPTION_USE_HARFBUZZ]:
3760 Redefine to construct HarfBuzz features.
3761 (af_get_char_index) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Rewritten.
3762
3763 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Use
3764 `y_offset' to adjust `best_y'.
3765
Werner Lembergc9d99472013-12-31 08:16:57 +010037662013-12-31 Werner Lemberg <wl@gnu.org>
3767
Werner Lemberg785f3852013-12-31 09:45:10 +01003768 [autofit] s/AF_STYLE_...._DEFAULT/AF_STYLE_...._DFLT/i.
3769
37702013-12-31 Werner Lemberg <wl@gnu.org>
3771
Werner Lembergc9d99472013-12-31 08:16:57 +01003772 [autofit] Fix interface of `af_get_char_index'.
3773
3774 * src/autofit/hbshim.c (af_get_char_index): Return error value.
3775 Add argument for y offset (to be used in a yet-to-come patch).
3776
3777 * src/autofit/hbshim.h, src/autofit/afcjk.c,
3778 src/autofit/aflatin.c: Updated.
3779
Werner Lemberg44aa7e02013-12-30 07:41:22 +010037802013-12-30 Werner Lemberg <wl@gnu.org>
3781
3782 [autofit] Don't combine multiple features into one set.
3783
3784 Combining them, as originally envisioned, would lead to much more
3785 complicated code, as investigations have shown meanwhile. The major
3786 drawback is that we run out of available style slots much earlier.
3787 However, this is only a theoretical issue since we don't support a
3788 large number of scripts currently.
3789
3790 * src/autofit/afcover.h: Replace `COVERAGE_{1,2,3}' macros with
3791 a single-element `COVERAGE' macro, sort the elements by the feature
3792 tags, and add entry for `ruby'.
3793
3794 * src/autofit/aftypes.h: Updated.
3795 * src/autofit/hbshim.c: Updated.
3796
Werner Lemberg6af01a02013-12-28 08:55:24 +010037972013-12-28 Werner Lemberg <wl@gnu.org>
3798
Werner Lemberg072dc452013-12-28 12:26:21 +01003799 [autofit] Code shuffling to reduce use of cpp macros.
3800
3801 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
3802 Call `af_get_coverage' unconditionally.
3803
3804 * src/autofit/autofit.c: Include `hbshim.c' unconditionally.
3805
3806 * src/autofit/hbshim.c (af_get_coverage)
3807 [!FT_CONFIG_OPTION_USE_HARFBUZZ]: Provide dummy function.
3808
3809 * src/autofit/hbshim.h: Provide function declarations
3810 unconditionally.
3811
38122013-12-28 Werner Lemberg <wl@gnu.org>
3813
Werner Lemberg17af5862013-12-28 10:33:01 +01003814 [autofit] Add wrapper function for `FT_Get_Char_Index'.
3815
3816 Yet-to-come changes will provide HarfBuzz functionality for the new
3817 function.
3818
3819 * src/autofit/hbshim.c (af_get_char_index): New function.
3820 * src/autofit/hbshim.h: Updated.
3821
3822 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
3823 af_cjk_metrics_init_blues, af_cjk_metrics_check_digits): Updated.
3824
3825 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
3826 af_latin_metrics_init_blues, af_latin_metrics_check_digits):
3827 Updated.
3828
38292013-12-28 Werner Lemberg <wl@gnu.org>
3830
Werner Lemberg6af01a02013-12-28 08:55:24 +01003831 [autofit] Use `global' HarfBuzz font object.
3832
3833 We now use `hb_font' instead of `hb_face' since yet-to-come changes
3834 need this.
3835
3836 * src/autofit/afglobal.h: Include `hbshim.h'.
3837 (AF_FaceGlobalsRec) [FT_CONFIG_OPTION_USE_HARFBUZZ]: New member
3838 `hb_font'.
3839
3840 * src/autofit/afglobal.c (af_face_globals_new)
3841 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Create `hb_font'.
3842 (af_face_globals_free) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Destroy
3843 `hb_font'.
3844
3845 * src/autofit/hbshim.h: Include HarfBuzz headers.
3846
3847 * src/autofit/hbshim.c: Include `hbshim.h' instead of HarfBuzz
3848 headers.
3849 (af_get_coverage): Updated.
3850
Werner Lembergd32a7d32013-12-27 19:26:04 +010038512013-12-27 Werner Lemberg <wl@gnu.org>
3852
3853 [autofit] Handle `DFLT' OpenType script for coverages.
3854
3855 * include/ftautoh.h: Document new `default-script' property.
3856
3857 * src/autofit/hbshim.c (af_get_coverage): Use `AF_FaceGlobals' for
3858 type of first parameter.
3859 (script_tags): Add one more element.
3860 (af_get_coverage): Adjust `script_tags' to handle `DFLT' script tag.
3861
3862 * src/autofit/hbshim.h: Updated.
3863
3864 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
3865 Updated.
3866
3867 * src/autofit/afglobal.h (AF_SCRIPT_DEFAULT): New macro.
3868
3869 * src/autofit/afmodule.h (AF_ModuleRec): New `default_script'
3870 member.
3871
3872 * src/autofit/afmodule.c (af_property_set, af_property_get): Handle
3873 `default-script' property.
3874 (af_autofitter_init): Updated.
3875
suzuki toshiyae2d2b152013-12-27 16:44:24 +090038762013-12-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3877
3878 [ftrfork] Fix the face order difference between POSIX and Carbon.
3879
3880 The fragmented resources in Suitcase and .dfont should be reordered
Werner Lemberg00a7b512013-12-27 19:18:49 +01003881 when `POST' resource for Type1 is being restored, but reordering of
suzuki toshiyae2d2b152013-12-27 16:44:24 +09003882 sfnt resources induces the different face order. Now the ordering
Werner Lemberg00a7b512013-12-27 19:18:49 +01003883 is restricted to `POST' resource only, to prevent the different
3884 order issue (e.g. the face index in the fontconfig cache generated
3885 with Carbon framework is incompatible with that by FreeType 2
3886 without Carbon framework.) Found by Khaled Hosny and Hin-Tak Leung.
3887
suzuki toshiyae2d2b152013-12-27 16:44:24 +09003888 http://lists.gnu.org/archive/html/freetype-devel/2013-02/msg00035.html
3889 http://lists.gnu.org/archive/html/freetype-devel/2013-12/msg00027.html
3890
3891 * src/base/ftrfork.c (FT_Raccess_Get_DataOffsets): Add a switch
Werner Lemberg44aa7e02013-12-30 07:41:22 +01003892 `sort_by_res_id' to control the fragmented resource ordering.
Werner Lemberg00a7b512013-12-27 19:18:49 +01003893 * include/internal/ftrfork.h: Declare new switch.
3894 * src/base/ftobjs.c (IsMacResource): Enable the sorting for `POST'
3895 resource, and disable the sorting for `sfnt' resource.
suzuki toshiyae2d2b152013-12-27 16:44:24 +09003896
Werner Lemberg5f577462013-12-25 08:50:50 +010038972013-12-25 Werner Lemberg <wl@gnu.org>
3898
3899 Fix Savannah bug #40997.
3900
3901 * src/bdf/bdfdrivr.c (BDF_Face_Init): Only use OR operator to
3902 adjust face flags since FT_FACE_FLAG_EXTERNAL_STREAM might already
3903 be set.
3904 * src/cff/cffobjs.c (cff_face_init): Ditto.
3905 * src/cid/cidobjs.c (cid_face_init): Ditto.
3906 * src/pcf/pcfread.c (pcf_load_font): Ditto.
3907 * src/pfr/pfrobjs.c (pfr_face_init): Ditto.
3908 * src/type1/t1objs.c (T1_Face_Init): Ditto.
3909 * src/type42/t42objs.c (T42_Face_Init): Ditto.
3910 * src/winfonts/winfnt.c (FNT_Face_Init): Ditto.
3911
Werner Lembergc4e968e2013-12-21 07:23:08 +010039122013-12-21 Werner Lemberg <wl@gnu.org>
3913
Werner Lemberg19241342013-12-21 21:31:38 +01003914 [autofit] Introduce `coverages'.
3915
3916 Coverages are the interface to the HarfBuzz library to acces
3917 OpenType features for handling glyphs not addressable by the cmap.
3918
3919 Right now, compilation of HarfBuzz is only added to the development
3920 build. A solution for standard build mode will be delayed until
3921 HarfBuzz gets split into two libraries to avoid mutual dependencies
3922 between FreeType and HarfBuzz.
3923
3924 Note that this is only a first step in handling coverages, basically
3925 providing the framework only. Code for handling selected OpenType
3926 features (this is, actually using the data in `afcover.h') will
3927 follow.
3928
3929 * devel/ftoption.h, include/config/ftoption.h
3930 (FT_CONFIG_OPTION_USE_HARFBUZZ): New macro.
3931
3932 * src/autofit/hbshim.c, src/autofit/hbshim.h, src/autofit/afcover.h:
3933 New files.
3934
3935 * src/autofit/afscript.h: Add HarfBuzz script name tags.
3936
3937 * src/autofit/afstyles.h: Add default coverage enumeration values.
3938
3939 * src/autofit/aftypes.h: Update use of `SCRIPT' and `STYLE' macros.
3940 (AF_Coverage): New enumeration (generated by `afcover.h').
3941 (AF_StyleClassRec): New member `coverage'.
3942 (AF_DEFINE_STYLE_CLASS): Updated.
3943
3944 * include/internal/fttrace.h: Add `afharfbuzz' for tracing coverage
3945 data.
3946
3947 * src/autofit/afglobal.h: Update use of `SCRIPT' and `STYLE' macros.
3948 (AF_SCRIPT_FALLBACK): Renamed to ...
3949 (AF_STYLE_FALLBACK): ... this.
3950
3951 * src/autofit/afglobal.c: Include `hbshim.c'.
3952 Update use of `SCRIPT' and `STYLE' macros.
3953 (af_face_globals_compute_style_coverage)
3954 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Call `af_get_coverage'.
3955 Update.
3956
3957 * src/autofit/afmodule.h (AF_ModuleRec):
3958 s/fallback_script/fallback_style/.
3959
3960 * src/autofit/afmodule.c (af_property_set): Adapt handling of
3961 `fallback-script' property to set a fallback style.
3962 (af_property_get, af_autofitter_init): Updated.
3963
3964 * src/autofit/afpic.c: Update use of `SCRIPT' and `STYLE' macros.
3965
3966 * src/autofit/afranges.h: Update use of `SCRIPT' macro.
3967
3968 * src/autofit/autofit.c [FT_CONFIG_OPTION_USE_HARFBUZZ]: Include
3969 `hbshim.c'.
3970
3971 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `hbshim.c'.
3972 (AUTOF_DRV_H): Add `afcover.h'.
3973
3974 * builds/freetype.mk (INCLUDE_FLAGS) [DEVEL_DIR]: Use pkg-config for
3975 all libraries needed by FreeType.
3976
39772013-12-21 Werner Lemberg <wl@gnu.org>
3978
Werner Lembergb337fa22013-12-21 19:33:15 +01003979 Fix Savannah bug #40975 (sort of).
3980
3981 * src/truetype/ttinterp.c (Ins_IP): Fix sign typo to make FreeType
3982 behave the same as the Windows TrueType engine for the invalid case.
3983
39842013-12-21 Werner Lemberg <wl@gnu.org>
3985
Werner Lemberg3bf60952013-12-21 08:49:11 +01003986 [autofit] Make PIC mode work actually.
3987
3988 * src/autofit/afpic.h (AFModulePIC): Fix array sizes to fit the
3989 enumeration values automatically generated by including `afscript.h'
3990 and friends.
3991
3992 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
3993
39942013-12-21 Werner Lemberg <wl@gnu.org>
3995
Werner Lembergbd413862013-12-21 08:14:25 +01003996 Fix PIC linking.
3997
3998 * include/internal/ftrfork.h (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Fix
3999 generated function name.
4000
4001 * src/base/basepic.c (FT_Init_Table_raccess_guess_table): Rename
4002 to ...
4003 (FT_Init_Table_ft_raccess_guess_table): ... this so that the
4004 function name correctly corresponds to what the macro framework
4005 expects.
4006
4007 * src/psnames/rules.mk (PSNAMES_DRV_SRC_S): Use correct file name so
4008 that PIC functions are compiled also.
4009
40102013-12-21 Werner Lemberg <wl@gnu.org>
4011
Werner Lembergc4e968e2013-12-21 07:23:08 +01004012 [base] Add missing dependencies to Makefile.
4013
4014 * src/base/rules.mk (BASE_SRC): Add `basepic.c' and `ftpic.c'.
4015 (BASE_H): Add `basepic.h'.
4016
Werner Lemberg974b1932013-12-20 17:26:26 +010040172013-12-20 Werner Lemberg <wl@gnu.org>
4018
Werner Lemberg8a8f3752013-12-20 18:35:35 +01004019 [autofit] Fix PIC compilation.
4020
4021 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
4022 src/autofit/aflatin.c (af_latin_metrics_init_widths)
4023 [FT_CONFIG_OPTION_PIC]: Declare `globals'.
4024
4025 * src/autofit/afglobal.c: Always call AF_DEFINE_SCRIPT_CLASS, and
4026 AF_DEFINE_STYLE_CLASS.
4027
4028 * src/autofit/afpic.c: Include `afglobal.h'.
4029 (autofit_module_class_pic_init): Typo.
4030
4031 * src/autofit/aftypes.h (AF_DEFINE_SCRIPT_CLASS,
4032 AF_DEFINE_STYLE_CLASS): Don't use the same identifier for macro
4033 parameter and structure member.
4034
40352013-12-20 Werner Lemberg <wl@gnu.org>
4036
Werner Lemberg974b1932013-12-20 17:26:26 +01004037 [autofit] Introduce `styles'.
4038
4039 This is the new top-level structure for handling glyph input data;
4040 scripts are now defined separately.
4041
4042 * src/autofit/aftypes.h (SCRIPT): Updated.
4043 (AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
4044 members to ...
4045 (AF_Style_ClassRec): ... this new structure.
4046 (AF_Style): New enumeration.
4047 (AF_StyleMetricsRec): Replace `script' enumeration with
4048 `style_class' pointer.
4049 (AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
4050 (AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
4051
4052 * src/autofit/afstyles.h: New file, using data from `afscript.h'.
4053 * src/autofit/afscript.h: Updated.
4054
4055 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
4056 af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
4057
4058 * src/autofit/afglobal.c (SCRIPT): Updated.
4059 (STYLE): Redefine macro to load `afstyles.h'.
4060 (af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
4061 (af_style_names): ... this array.
4062 (af_face_globals_compute_script_coverage): Renamed to...
4063 (af_face_globals_compute_style_coverage): ... this.
4064 Updated.
4065 (af_face_globals_new, af_face_globals_free,
4066 af_face_globals_get_metrics): Updated.
4067
4068 * src/autofit/afglobal.h (SCRIPT): Updated.
4069 (STYLE): Redefine macro to load `afstyles.h'.
4070 (AF_SCRIPT_FALLBACK): Update definition. This will get more
4071 refinements with later on.
4072 (AF_SCRIPT_UNASSIGNED): Replace with...
4073 (AF_STYLE_UNASSIGNED): ... this macro.
4074 (AF_FaceGlobalsRec): Updated.
4075
4076 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
4077 af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
4078 af_latin_hint_edges): Updated.
4079
4080 * src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
4081 (af_ltn2_uniranges): Removed.
4082
4083 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
4084 Updated.
4085
4086 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
4087 * src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
4088 (AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
4089 members.
4090
4091 * src/autofit/afranges.h: Updated.
4092
4093 * src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
4094
Werner Lembergd8324572013-12-19 15:45:24 +010040952013-12-19 Werner Lemberg <wl@gnu.org>
4096
4097 [autofit] Factor scripts and uniranges out of writing system files.
4098
4099 * src/autofit/afranges.c, src/autofit/afranges.h: New files.
4100
4101 * src/autofit/afscript.h: Extend `SCRIPT' macro with more
4102 parameters, taking data from the writing system files.
4103
4104 * src/autofit/aftypes.h: Updated.
4105
4106 * src/autofit/afglobal.c: Include `afranges.h'.
4107 Load `afscript.h' to call AF_DEFINE_SCRIPT_CLASS.
4108 * src/autofit/afglobal.c: Include `afranges.h'.
4109 Load `afscript.h' to call AF_DECLARE_SCRIPT_CLASS.
4110
4111 * src/autofit/afcjk.c, src/autofit/afcjk.h: Updated.
4112 * src/autofit/afdummy.c, src/autofit/afdummy.h: Updated.
4113 * src/autofit/afindic.c, src/autofit/afindic.h: Updated.
4114 * src/autofit/aflatin.c, src/autofit/aflatin.h: Updated.
4115 * src/autofit/aflatn2.c, src/autofit/aflatn2.h: Updated.
4116
4117 * src/autofit/afpic.c: Updated.
4118
4119 * src/autofir/autofit.c: Include `afranges.c'.
4120 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afranges.c'.
4121
Werner Lemberg9a354552013-12-18 10:36:06 +010041222013-12-18 Werner Lemberg <wl@gnu.org>
4123
Werner Lemberg73f31982013-12-19 15:24:17 +01004124 [autofit] More code orthogonality.
4125
4126 * src/autofit/aftypes.h (AF_StyleMetrics): Replace `script_class'
4127 pointer to an `AF_ScriptClass' structure with `script' index of type
4128 `AF_Script'.
4129 Move some code around.
4130
4131 * src/autofit/afcjk.c: Include `afpic.h'.
4132 (af_cjk_metrics_init_widths, af_cjk_metrics_init_blues,
4133 af_cjk_hint_edges): Updated.
4134
4135 * src/autofit/aflatin.c: Include `afpic.h'.
4136 (af_latin_metrics_init_widths, af_latin_metrics_init_blues,
4137 af_latin_metrics_scale_dim, af_latin_hint_edges): Updated.
4138
4139 * src/autofit/afglobal.c (af_face_globals_get_metrics): Updated.
4140
4141 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
4142 Updated.
4143
41442013-12-18 Werner Lemberg <wl@gnu.org>
4145
Werner Lemberg3f91cb32013-12-18 12:59:35 +01004146 [autofit] s/ScriptMetrics/StyleMetrics/.
4147
41482013-12-18 Werner Lemberg <wl@gnu.org>
4149
Werner Lemberg4fccc212013-12-18 12:53:01 +01004150 [autofit] s/script_{metrics,hints}/style_{metrics,hints}/
4151
41522013-12-18 Werner Lemberg <wl@gnu.org>
4153
Werner Lembergf4df4072013-12-18 10:39:30 +01004154 [autofit] s/gscripts/gstyles/.
4155
41562013-12-18 Werner Lemberg <wl@gnu.org>
4157
Werner Lemberg9a354552013-12-18 10:36:06 +01004158 [autofit] s/glyph_scripts/glyph_styles/.
4159
4160 This is the first commit of a series to create a new top-level
4161 structure (a `style') for handling scripts, writing_systems, and
4162 soon-to-be-added coverages.
4163
Werner Lemberg7a5fc2f2013-12-17 13:29:53 +010041642013-12-17 Werner Lemberg <wl@gnu.org>
4165
4166 [autofit] s/AF_Script_/AF_WritingSystem_/ where appropriate.
4167
Infinality8bb09b02013-12-11 09:01:13 +010041682013-12-11 Infinality <infinality@infinality.net>
4169
4170 [truetype] Simplify logic of rendering modes.
4171
4172 This patch unifies the subpixel and non-subpixel cases.
4173
4174 * src/truetype/ttinterp.h (TT_ExecContextRec): Remove
4175 `grayscale_hinting'; all code should refer to `grayscale' instead.
4176 Remove unused `native_hinting' member.
4177 Rename `subpixel_hinting' member to `subpixel.
4178
4179 * src/truetype/ttgload.c (TT_LOADER_SET_PP): Updated.
4180 (tt_loader_init): Updated.
4181
4182 * src/truetype/ttinterp.c (Ins_GETINFO): Simplify.
4183 Updated.
4184
Werner Lemberge9d95aa2013-12-11 07:48:51 +010041852013-12-11 Werner Lemberg <wl@gnu.org>
4186
4187 [documentation] Add section how to include FreeType header files.
4188 Problem reported by David Kastrup <dak@gnu.org>.
4189
4190 Surprisingly, a description how to do that was completely missing in
4191 the API reference.
4192
4193 * include/freetype.h, include/ftchapters.h: New documentation
4194 section `header_inclusion'.
4195
Werner Lemberg05c786d2013-12-10 08:38:57 +010041962013-12-10 Werner Lemberg <wl@gnu.org>
4197
Werner Lemberg91932592013-12-10 13:24:07 +01004198 [autofit] s/DFLT/NONE/, s/dflt/none/.
4199
42002013-12-10 Werner Lemberg <wl@gnu.org>
4201
Werner Lemberg45244f82013-12-10 13:18:11 +01004202 [autofit] s/AF_SCRIPT_NONE/AF_SCRIPT_UNASSIGNED/.
4203
42042013-12-10 Werner Lemberg <wl@gnu.org>
4205
Werner Lemberg69d1a362013-12-10 10:12:27 +01004206 [truetype] Fix scaling of vertical phantom points.
4207
4208 * src/truetype/ttgload.c (load_truetype_glyph): Scale pp3.x and
4209 pp4.x also.
4210
42112013-12-10 Werner Lemberg <wl@gnu.org>
4212
Werner Lemberg05c786d2013-12-10 08:38:57 +01004213 [truetype] Fix positioning of composite glyphs.
4214 Problem reported by Nigel Tao <nigeltao@golang.org>.
4215
4216 * src/truetype/ttgload.c (TT_Hint_Glyph): Remove code that shifts
4217 the glyph (component) by a fractional value computed from the LSB
4218 phantom point. This is wrong, since the horizontal phantom points
4219 get rounded horizontally later on.
4220
Werner Lembergdd8050a2013-12-08 23:14:46 +010042212013-12-08 Werner Lemberg <wl@gnu.org>
4222
4223 * Version 2.5.2 released.
4224 =========================
4225
4226
4227 Tag sources with `VER-2-5-2'.
4228
4229 * docs/VERSION.DLL: Update documentation and bump version number to
4230 2.5.2.
4231
4232 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
4233 builds/windows/vc2005/index.html,
4234 builds/windows/vc2008/freetype.vcproj,
4235 builds/windows/vc2008/index.html,
4236 builds/windows/vc2010/freetype.vcxproj,
4237 builds/windows/vc2010/index.html,
4238 builds/windows/visualc/freetype.dsp,
4239 builds/windows/visualc/freetype.vcproj,
4240 builds/windows/visualc/index.html,
4241 builds/windows/visualce/freetype.dsp,
4242 builds/windows/visualce/freetype.vcproj,
4243 builds/windows/visualce/index.html,
4244 builds/wince/vc2005-ce/freetype.vcproj,
4245 builds/wince/vc2005-ce/index.html,
4246 builds/wince/vc2008-ce/freetype.vcproj,
4247 builds/wince/vc2008-ce/index.html: s/2.5.1/2.5.2/, s/251/252/.
4248
Werner Lembergec8853c2014-03-06 19:13:45 +01004249 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
Werner Lembergdd8050a2013-12-08 23:14:46 +01004250
4251 * builds/unix/configure.raw (version_info): Set to 17:1:11.
Werner Lembergec8853c2014-03-06 19:13:45 +01004252 * CMakeLists.txt (VERSION_PATCH): Set to 2.
Werner Lembergdd8050a2013-12-08 23:14:46 +01004253 * docs/CHANGES: Updated.
4254
Werner Lemberg98d185c2013-12-07 09:26:55 +010042552013-12-07 Werner Lemberg <wl@gnu.org>
4256
4257 [truetype] Next round in phantom point handling.
4258
4259 Greg Hitchcock provided very interesting insights into the
4260 complicated history of the horizontal positions of the TSB and BSB
4261 phantom points.
4262
4263 * src/truetype/ttgload.c (TT_LOADER_SET_PP)
4264 [TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Use `subpixel_hinting' and
4265 `grayscale_hinting' flags as conditionals for the x position of TSB
4266 and BSB.
4267
Werner Lembergfcdb7842013-12-05 15:53:27 +010042682013-12-05 Werner Lemberg <wl@gnu.org>
4269
4270 * builds/freetype.mk (FT_CC): Removed. Unused.
4271
Werner Lemberg64b395c2013-12-04 06:18:56 +010042722013-12-04 Werner Lemberg <wl@gnu.org>
4273
4274 [sfnt] Fix handling of embedded bitmap strikes.
4275
4276 This corrects the commit from 2013-11-21. Problem reported by
4277 Andrey Panov <panov@canopus.iacp.dvo.ru>.
4278
4279 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Fix logic to
4280 detect excessive bytes for bit-aligned bitmaps.
4281
Werner Lembergbdd5e752013-12-03 06:57:02 +010042822013-12-03 Werner Lemberg <wl@gnu.org>
4283
Werner Lembergc2b47532013-12-03 07:01:57 +01004284 [truetype] Remove dead code.
4285
4286 Reported by Nigel Tao <nigeltao@golang.org>.
4287
4288 * include/internal/tttypes.h (TT_LoaderRec): Remove unused
4289 `preserve_pps' field.
4290 * src/truetype/ttgload.c (TT_Hint_Glyph): Updated.
4291
42922013-12-03 Werner Lemberg <wl@gnu.org>
4293
Werner Lembergbdd5e752013-12-03 06:57:02 +01004294 [truetype] Fix phantom point handling.
4295
4296 This is a further improvement to the changes from 2013-11-06.
4297
4298 * src/truetype/ttgload.c (TT_Hint_Glyph): Horizontal phantom points
4299 are rounded horizontally, vertical ones are rounded vertically.
4300 (TT_LOADER_SET_PP): The horizontal position of vertical phantom
4301 points in pre-ClearType mode is zero, as shown in the OpenType
4302 specification.
4303
Werner Lemberg64872a52013-12-02 07:51:17 +010043042013-12-02 Werner Lemberg <wl@gnu.org>
4305
4306 [truetype] Fix change from 2013-11-20.
4307
4308 Problem reported by Akira Kakuto <kakuto@fuk.kindai.ac.jp>.
4309
4310 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Protect call to
4311 `Update_Max' with both a TT_USE_BYTECODE_INTERPRETER guard and a
4312 `IS_HINTED' clause.
4313 Also remove redundant check using `maxSizeOfInstructions' – in
4314 simple glyphs, the bytecode data comes before the outline data, and
4315 a validity test for this is already present.
4316
Werner Lemberg52166ab2013-11-27 10:10:16 +010043172013-11-27 Werner Lemberg <wl@gnu.org>
4318
4319 [autofit] Fix use of dumping functions in `ftgrid' demo program.
4320
4321 * src/autofit/afhints.c (AF_DUMP) [FT_DEBUG_AUTOFIT]: New macro.
4322 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
4323 af_glyph_hints_dump_edges) [FT_DEBUG_AUTOFIT]: Add parameter to
4324 handle output to stdout.
4325 Use AF_DUMP.
4326 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
4327 af_glyph_hints_dump_edges) [!FT_DEBUG_AUTOFIT]: Removed.
4328
Werner Lemberg3aee4292013-11-25 00:28:11 +010043292013-11-25 Werner Lemberg <wl@gnu.org>
4330
4331 * Version 2.5.1 released.
4332 =========================
4333
4334
4335 Tag sources with `VER-2-5-1'.
4336
4337 * docs/VERSION.DLL: Update documentation and bump version number to
4338 2.5.1.
4339
4340 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
4341 builds/windows/vc2005/index.html,
4342 builds/windows/vc2008/freetype.vcproj,
4343 builds/windows/vc2008/index.html,
4344 builds/windows/vc2010/freetype.vcxproj,
4345 builds/windows/vc2010/index.html,
4346 builds/windows/visualc/freetype.dsp,
4347 builds/windows/visualc/freetype.vcproj,
4348 builds/windows/visualc/index.html,
4349 builds/windows/visualce/freetype.dsp,
4350 builds/windows/visualce/freetype.vcproj,
4351 builds/windows/visualce/index.html,
4352 builds/wince/vc2005-ce/freetype.vcproj,
4353 builds/wince/vc2005-ce/index.html,
4354 builds/wince/vc2008-ce/freetype.vcproj,
4355 builds/wince/vc2008-ce/index.html: s/2.5.0/2.5.1/, s/250/251/.
4356
4357 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
4358
4359 * builds/unix/configure.raw (version_info): Set to 17:0:11.
Werner Lembergec8853c2014-03-06 19:13:45 +01004360 * CMakeLists.txt (VERSION_PATCH): Set to 1.
Werner Lemberg3aee4292013-11-25 00:28:11 +01004361 * docs/CHANGES, docs/release: Updated.
4362
Werner Lemberg9326caf2013-11-23 23:59:25 +010043632013-11-23 Werner Lemberg <wl@gnu.org>
4364
Werner Lemberg063ee6b2013-11-24 00:19:17 +01004365 [truetype]: Add tricky font names `hkscsiic.ttf' and `iicore.ttf'.
4366
4367 * src/truetype/ttobjs.c (TRICK_NAMES_MAX_CHARACTERS,
4368 TRICK_NAMES_COUNT): Updated.
4369 (trick_names): Add family name for the two fonts.
4370
43712013-11-23 Werner Lemberg <wl@gnu.org>
4372
Werner Lemberg9326caf2013-11-23 23:59:25 +01004373 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Typo.
4374
Werner Lemberg427b1762013-11-21 13:10:56 +010043752013-11-21 Werner Lemberg <wl@gnu.org>
4376
Werner Lemberg9326caf2013-11-23 23:59:25 +01004377 [sfnt] Typo.
Werner Lemberg8af2a1c2013-11-21 13:13:12 +01004378
4379 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
4380
4381 * src/sfnt/sfobjs.c (sfnt_load_face): Return correct `bsize->width'
4382 value if the font lacks an `OS/2' table.
4383
43842013-11-21 Werner Lemberg <wl@gnu.org>
4385
Werner Lemberg64b395c2013-12-04 06:18:56 +01004386 [sfnt] Improve handling of buggy embedded bitmap strikes.
Werner Lemberg427b1762013-11-21 13:10:56 +01004387
4388 We are now able to successfully load `AppleMyoungJo.ttf'.
4389 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
4390
4391 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Don't trust glyph
4392 format.
4393
Werner Lemberg28626862013-11-20 21:06:18 +010043942013-11-20 Werner Lemberg <wl@gnu.org>
4395
4396 [truetype] Don't trust `maxp's `maxSizeOfInstructions'.
4397
4398 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>; see
4399
4400 http://lists.nongnu.org/archive/html/freetype-devel/2013-08/msg00005.html
4401
4402 for details.
4403
4404 * src/base/ftobjs.c (FT_Load_Glyph): Check size of `fpgm' and `prep'
4405 tables also for setting `autohint'.
4406
4407 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Use code from
4408 `TT_Process_Composite_Glyph' for handling unreliable values of
4409 `maxSizeOfInstructions'.
4410
Werner Lembergbc25de62013-11-16 07:52:20 +010044112013-11-16 Werner Lemberg <wl@gnu.org>
4412
4413 [sfnt] Fix `OS/2' table version 5 support.
4414
4415 We now follow the `official' announcement from Microsoft (on the
4416 OpenType mailing list, which unfortunately hasn't a public archive).
4417
4418 * include/freetype/tttables.h (TT_OS2):
4419 s/usLowerPointSize/usLowerOpticalPointSize/,
4420 s/usUpperPointSize/usUpperOpticalPointSize/.
4421
4422 * src/sfnt/ttload.c (tt_face_load_os2): Update, and set correct
4423 default values.
4424
Werner Lembergfae38202013-11-13 08:55:46 +010044252013-11-13 Werner Lemberg <wl@gnu.org>
4426
Werner Lembergc52b1292013-11-13 10:06:00 +01004427 * builds/unix/ft2unix.h: Remove. No longer necessary.
4428
4429 * builds/unix/install.mk (install): Updated.
4430
44312013-11-13 Werner Lemberg <wl@gnu.org>
4432
Werner Lembergfae38202013-11-13 08:55:46 +01004433 Simplify header file hierarchy.
4434
4435 This large patch changes the header file directory layout from
4436 `include/freetype/...' to `include/...', effectively removing one
4437 level. Since the file `ft2build.h' is also located in `include'
4438 (and it stays there even after installation), all FreeType header
4439 files are now in a single directory.
4440
4441 Applications that use (a) `freetype-config' or FreeType's
4442 `pkg-config' file to get the include directory for the compiler, and
4443 (b) the documented way for header inclusion like
4444
4445 #include <ft2build.h>
4446 #include FT_FREETYPE_H
4447 ...
4448
4449 don't need any change to the source code.
4450
4451 * include/freetype/*: Move up to...
4452 * include/*: ... this directory.
4453
4454 * builds/amiga/include/freetype/*: Move up to...
4455 * builds/amiga/include/*: ... this directory.
4456
4457 */*: Essentially do `s@/freetype/@/@' where appropriate.
4458
4459 * CMakeList.txt: Simplify.
4460 * builds/unix/freetype-config.in, builds/unix/freetype2.in: For
4461 `--cflags', return a single directory.
4462 * builds/unix/install.mk (install): No longer try to remove `cache'
4463 and `internal' subdirectories; instead, remove the `freetype'
4464 subdirectory.
4465
Werner Lembergea5c7812013-11-12 08:55:26 +010044662013-11-12 Werner Lemberg <wl@gnu.org>
4467
4468 [truetype] Fix last `truetype' commit.
4469
4470 * src/truetype/ttgload.c (tt_get_metrics): Preserve stream position.
4471 Return error value.
4472 (load_truetype_glyph): Updated.
4473
Werner Lemberg78333282013-11-10 06:26:52 +010044742013-11-10 Werner Lemberg <wl@gnu.org>
4475
4476 * docs/CMAKE: New dummy file.
4477
Dave Arnolddd213012013-11-08 10:52:51 +010044782013-11-08 Dave Arnold <darnold@adobe.com>
4479
4480 [cff] Fix for hints that touch.
4481
4482 * src/cff/cf2hints.c (cf2_hintmap_insertHint): Fix condition for
4483 finding index value of insertion point.
4484
Werner Lemberg7e4b0fb2013-11-06 07:14:49 +010044852013-11-06 Werner Lemberg <wl@gnu.org>
4486
Werner Lemberg5e225b72013-11-06 08:41:59 +01004487 [truetype] Fix handling of phantom points in composite glyphs.
4488 Problem reported by Nigel Tao <nigeltao@golang.org>.
4489
4490 This is a follow-up commit to the previous one.
4491
4492 * src/truetype/ttgload.c (load_truetype_glyph): Call
4493 `tt_get_metrics' after loading the glyph header.
4494
44952013-11-06 Werner Lemberg <wl@gnu.org>
4496
Werner Lemberg7e4b0fb2013-11-06 07:14:49 +01004497 [truetype] Improve emulation of vertical metrics.
4498
4499 This commit also improves the start values of vertical phantom
4500 points. Kudos to Greg Hitchcock for help.
4501
4502 * src/truetype/ttgload.c (TT_Get_VMetrics): Add parameter to pass
4503 `yMax' value. Replace code with fixed Microsoft definition.
4504 (tt_get_metrics): Updated.
4505 (TT_LOADER_SET_PP): Add explanation how to initialize phantom
4506 points, taken from both the OpenType specification and private
4507 communication with Greg (which will eventually be added to the
4508 standard).
4509 Fix horizontal position of `pp3' and `pp4'.
4510
4511 * src/truetype/ttgload.h: Updated.
4512
4513 * src/truetype/ttdriver.c (tt_get_advances): Updated.
4514
4515 * docs/CHANGES: Updated.
4516
Werner Lembergc6064282013-11-05 13:29:15 +010045172013-11-05 Werner Lemberg <wl@gnu.org>
4518
Werner Lemberg50740532013-11-05 23:19:18 +01004519 * builds/windows/vc2010/freetype.vcxproj: s/v110/v100/.
4520 PlatformToolSet version 110 is for VC2012.
4521
4522 Problem reported (with solution) by Dave Arnold <darnold@adobe.com>.
4523
45242013-11-05 Werner Lemberg <wl@gnu.org>
4525
Werner Lembergc6064282013-11-05 13:29:15 +01004526 [truetype] Correctly reset point tags for glyph components.
4527 Problem reported by Nigel Tao <nigeltao@golang.org>.
4528
4529 * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Fix loop.
4530
Werner Lemberg35b08182013-11-02 08:28:41 +010045312013-11-02 Werner Lemberg <wl@gnu.org>
4532
Werner Lemberg7d449432013-11-02 11:36:37 +01004533 [truetype] Fix GETINFO opcode handling of subpixel hinting bits.
4534
4535 * src/truetype/ttinterp.c (Ins_GETINFO): Don't request bit 6 set to
4536 get info on subpixel hinting.
4537
4538 * docs/CHANGES: Updated.
4539
45402013-11-02 Werner Lemberg <wl@gnu.org>
4541
Werner Lemberg35b08182013-11-02 08:28:41 +01004542 Fix Savannah bug #40451.
4543
4544 Simply apply the patch from the bug report.
4545
4546 * builds/unix/ftconfig.in, builds/vms/ftconfig.h,
4547 include/freetype/config/ftconfig.h: The used #pragma directives only
4548 work with gcc versions 4.6 and higher.
4549
Werner Lembergebf52d62013-11-01 13:26:28 +010045502013-11-01 Werner Lemberg <wl@gnu.org>
4551
Werner Lembergafa0d592013-11-01 22:27:27 +01004552 * docs/CHANGES: Updated.
4553
45542013-11-01 Werner Lemberg <wl@gnu.org>
4555
Werner Lembergebf52d62013-11-01 13:26:28 +01004556 [truetype] Minor code refactoring.
4557
4558 Two benefits: The allocated FDEF (and IDEF) array gets slightly
4559 smaller, and the `ttdebug' demo program has access to function
4560 numbers without additional costs.
4561
4562 Fortunately, no changes to FontForge are necessary – this is the
4563 only external TrueType debugger I know of, but others may exist and
4564 should check the code accordingly.
4565
4566 * src/truetype/ttinterp.h (TT_CallRec): Replace `Cur_Restart' and
4567 `Cur_End' with a pointer to the corresponding `TT_DefRecord'
4568 structure.
4569
4570 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF, Ins_ENDF,
4571 Ins_CALL, Ins_LOOPCALL, Ins_UNKNOWN, TT_RunIns <Invalid_Opcode>):
4572 Updated.
4573
Werner Lembergee510512013-10-27 07:25:35 +010045742013-10-27 Werner Lemberg <wl@gnu.org>
4575
4576 [sfnt] Implement support for `OS/2' table version 5.
4577
4578 See
4579
4580 http://typedrawers.com/discussion/470/new-microsoft-size-specific-design-selection-mechanism
4581
4582 for the announcement.
4583
4584 * include/freetype/tttables.h (TT_OS2): Add fields
4585 `usLowerPointSize' and `usUpperPointSize'. Since FreeType returns
4586 this structure only as a pointer through `FT_Get_Sfnt_Table', there
4587 shouldn't be any ABI problems.
4588
4589 * src/sfnt/ttload.c (tt_face_load_os2): Implement it.
4590
4591 * docs/CHANGES: Updated.
4592
Werner Lemberg994a8592013-10-24 08:50:34 +020045932013-10-24 Werner Lemberg <wl@gnu.org>
4594
4595 * README.git, docs/CHANGES, docs/INSTALL: Updated.
4596
John Carya0e4a732013-10-24 08:49:08 +020045972013-10-24 John Cary <cary@txcorp.com>
4598
4599 Provide cmake support.
4600
4601 * CMakeLists.txt: New file.
4602
Kenneth Miller4d87ac82013-10-23 20:10:56 +020046032013-10-23 Kenneth Miller <kennethadammiller@yahoo.com>
4604 Werner Lemberg <wl@gnu.org>
4605
4606 Provide support for x64 builds in Visual C++ project files.
4607
4608 * src/builds/win32: Renamed to...
4609 * src/builds/windows: This.
4610
4611 * src/builds/windows/vc2010/*: Updated to handle x64 target.
4612
4613 * src/builds/windows/*.mk, docs/INSTALL.GNU: s/win32/windows/ where
4614 appropriate.
4615
Werner Lemberg604838d2013-10-22 01:10:10 +020046162013-10-22 Werner Lemberg <wl@gnu.org>
4617
4618 * src/base/md5.c, src/base/md5.h: Updated to recent version.
4619
4620 * src/base/ftobjs.c: Updated; `md5.c' no longer uses `free'.
4621
Werner Lembergdb9159c2013-10-22 10:27:50 +02004622 The canonical URL to get updates for this file is
4623
4624 http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/popa3d/popa3d/md5/
4625
4626 as the author told me in private communication.
4627
Werner Lemberg34efe052013-10-19 21:14:40 +020046282013-10-19 Werner Lemberg <wl@gnu.org>
4629
Werner Lemberg75efc2d2013-10-19 21:46:03 +02004630 [autofit] s/SMALL_TOP/X_HEIGHT/.
4631
4632 * src/autofit/afblue.dat: Updated.
4633
4634 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4635
4636 * src/autofit/aflatin.c, src/autofit/aflatin.h,
4637 src/autofit/atlatin2.c: Updated.
4638
46392013-10-19 Werner Lemberg <wl@gnu.org>
4640
Werner Lemberg34efe052013-10-19 21:14:40 +02004641 * src/autofit/afblue.dat: s/MINOR/DESCENDER/.
4642
4643 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4644
Werner Lemberg955f6a82013-10-16 19:47:57 +020046452013-10-16 Werner Lemberg <wl@gnu.org>
4646
Werner Lemberga5f22a92013-10-17 11:08:25 +02004647 [autofit] Add description strings to script entries.
4648
4649 Currently, this is unused.
4650
4651 * src/autofit/afscript.h: Do it.
4652 * src/autofit/afglobal.c, src/autofit/afpic.c,
4653 src/autofit/aftypes.h: Updated.
4654
46552013-10-16 Werner Lemberg <wl@gnu.org>
4656
Werner Lemberg955f6a82013-10-16 19:47:57 +02004657 [autofit] Improve tracing message for extra light flag.
4658
4659 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Do it.
4660
Chongyu Zhu41632b52013-10-15 11:40:34 +020046612013-10-15 Chongyu Zhu <lembacon@gmail.com>
4662
4663 [arm] Fix thumb2 inline assembly under LLVM.
4664
4665 When using `ADD' with an immediate operand, the instruction is
4666 actually `ADD Rd, Rn, #<imm12>', that is, the maximum of the
4667 immediate operand cannot exceed 4095. It will fail to compile with
4668 LLVM.
4669
4670 However, in GCC, due to some legacy compatibility considerations,
4671 `ADD.W' will be automatically emitted when the immediate operand is
4672 larger than 4095.
4673
4674 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
4675 (FT_MulFix_arm) [__GNUC__]: Support clang compiler.
4676
4677 * src/truetype/ttinterp.c (TT_MulFix14_arm) [__GNUC__]: Ditto.
4678
Werner Lembergb6695242013-10-12 10:33:04 +020046792013-10-12 Werner Lemberg <wl@gnu.org>
4680
4681 [autofit] Improve tracing of `latin' hinter.
4682
4683 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Report blue
4684 zone types.
4685 (af_latin_metrics_scale_dim): Report scaling changes due to x height
4686 alignment.
4687 Report scaled stroke width and blue zone values.
4688
Dave Arnolde845a852013-10-03 23:04:29 +020046892013-10-03 Dave Arnold <darnold@adobe.com>
4690
4691 * src/cff/cf2font.c (cf2_computeDarkening): Avoid division by zero.
4692
Werner Lemberg2c56f2a2013-10-07 22:01:00 +02004693 Note that the old code avoided using a region of the piecewise
4694 linear function where the slope was zero. The recovery was to use a
4695 different section of the function, which produced a different,
4696 incorrect amount of darkening.
4697
Darrell Bellert01af71d2013-10-02 22:04:07 +020046982013-10-02 Darrell Bellert <darrell.bellert@hl.konicaminolta.us>
4699
4700 * src/sfnt/ttload.c (tt_face_load_pclt): Fix `pclt_fields'.
4701
Dave Arnold0b330452013-10-02 11:04:06 +020047022013-10-02 Dave Arnold <darnold@adobe.com>
4703
4704 * src/cff/cf2font.c (cf2_computeDarkening): Initialize darkenAmount.
4705
4706 This line was lost in commit 89ca1fd6 (from 2013-06-25). The effect
4707 is to use a previous darkening amount when producing an unhinted,
4708 unscaled outline. This can cause autohint samples in ftgrid and
4709 ftview to be based on darkened CFF outlines instead of unhinted,
4710 undarkened ones.
4711
Dave Arnold3a2cb0f2013-09-29 16:17:02 +020047122013-09-29 Dave Arnold <darnold@adobe.com>
4713
4714 Fix Savannah bug #39295.
4715
4716 The bug was caused by switching to the initial hintmap (the one in
4717 effect when `moveto' executes) just before drawing the final element
4718 in the charstring. This ensured that the path was closed (in both
4719 Character Space and Device Space). But if the final element was a
4720 curve and if the final hintmap was different enough from the initial
4721 one, then the curve was visibly distorted.
4722
4723 The first part of the fix is to draw the final curve using the final
4724 hintmap as specified by the charstring. This corrects the
4725 distortion but does not ensure closing in Device Space. It may
4726 require the rasterizer to automatically generate an extra closing
4727 line. Depending on the hintmap differences, this line could be from
4728 zero to a couple pixels in length.
4729
4730 The second part of the fix covers the case where the charstring
4731 subpath is closed with an explicit line. We now modify that line's
4732 end point to avoid the distortion.
4733
4734 Some glyphs in the bug report font (TexGyreHeros-Regular) that show
4735 the change are:
4736
4737 25ppem S (98)
4738 24ppem eight (52)
4739 25.5ppem p (85)
4740
4741 Curves at the *end* of a subpath are no longer distorted. However,
4742 some of these glyphs have bad hint substitutions in the middle of a
4743 subpath, and these are not affected.
4744
4745 The patch has been tested with a set of 106 fonts that shipped with
4746 Adobe Creative Suite 4, together with 756 Open Source CFF fonts from
4747 Google Fonts. There are 1.5 million glyphs, of which some 20k are
4748 changed with the fix. A sampling of a few hundred of these changes
4749 have been examined more closely, and the changes look good (or at
4750 least acceptable).
4751
4752 * src/cff/cf2hints.h (CF2_GlyphPathRec): New element `pathIsClosing'
4753 to indicate that we synthesize a closepath line.
4754
4755 * src/cff/cf2hints.c (cf2_glyphpath_init): Updated.
4756 (cf2_glyphpath_pushPrevElem): If closing, use first hint map (for
4757 `lineto' operator) and adjust hint zone.
4758 For synthesized closing lines, use end point in first hint zone.
4759 (cf2_glyphpath_lineTo): Take care of synthesized closing lines. In
4760 particular, shift the detection of zero-length lines from character
4761 space to device space.
4762 (cf2_glyphpath_closeOpenPath): Remove assertion.
4763 Updated.
4764
Werner Lembergb75a8b82013-09-25 09:46:36 +020047652013-09-25 Werner Lemberg <wl@gnu.org>
4766
4767 * src/autofit/aflatin.c (af_{grek,cyrl}_uniranges): Fix arrays.
4768
suzuki toshiyaac0f4452013-09-25 10:57:17 +090047692013-09-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4770
4771 [bdf, pcf] Refuse non-zero face_index.
Werner Lemberg964317e2013-09-25 09:22:40 +02004772
suzuki toshiyaac0f4452013-09-25 10:57:17 +09004773 Suggested by Akira Tagoh, see
4774
4775 http://lists.gnu.org/archive/html/freetype/2013-09/msg00030.html
4776
Werner Lemberg964317e2013-09-25 09:22:40 +02004777 * src/bdf/bdfdrivr.c (BDF_Face_Init): Return `Invalid_Argument'
4778 error if the font could be opened but non-zero `face_index' is
4779 given.
suzuki toshiyaac0f4452013-09-25 10:57:17 +09004780 * src/pcf/pcfdrivr.c (PCF_Face_Init): Ditto.
4781
4782 * src/type42/t42objs.c (T42_Face_Init): Remove unrequired FT_UNUSED
Werner Lemberg964317e2013-09-25 09:22:40 +02004783 macro for `face_index' because it is validated later.
suzuki toshiyaac0f4452013-09-25 10:57:17 +09004784
Werner Lemberg4de77872013-09-23 22:10:08 +020047852013-09-23 Werner Lemberg <wl@gnu.org>
4786
4787 Fix Savannah bug #40090.
4788
4789 * src/autofit/afcjk.c (af_cjk_metrics_scale): Revert commit
4790 306f8c5d (from 2013-08-25) affecting this function.
4791
Werner Lemberg5a4c5a52013-09-22 22:37:26 +020047922013-09-22 Werner Lemberg <wl@gnu.org>
4793
4794 [autofit] Disunify Cyrillic and Greek handling from Latin.
4795
4796 * src/autofit/afscript.h: Add Cyrillic and Greek.
4797
4798 * src/autofit/afblue.dat (AF_BLUE_STRINGSET_GREK,
4799 AF_BLUE_STRINGSET_CYRL): Add blue zones for Greek and Cyrillic.
4800 (AF_BLUE_STRINGSET_LATN): Fix typo.
4801 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4802
4803 * src/autofit/aflatin.c (af_grek_uniranges, af_cyrl_uniranges): New
4804 arrays.
4805 (af_grek_script_class, af_cyrl_script_class): New scripts.
4806 * src/autofit/aflatin.h: Updated.
4807
Werner Lemberg2cca9662013-09-20 07:23:34 +020048082013-09-20 Werner Lemberg <wl@gnu.org>
4809
4810 * docs/CHANGES: Updated.
4811
Behdad Esfahbod31e726d2013-09-20 07:20:53 +020048122013-09-20 Behdad Esfahbod <behdad@behdad.org>
4813
4814 Fix vertical size of emboldened glyphs.
4815
4816 Cf. https://bugzilla.gnome.org/show_bug.cgi?id=686709
4817
4818 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Adjust `horiBearingY'
4819 also.
4820
Alexei Podtelezhnikov52381c12013-09-11 23:25:56 -040048212013-09-11 Alexei Podtelezhnikov <apodtele@gmail.com>
4822
4823 * include/freetype/ftoutln.h: Correct FT_Outline_Get_Orientation
4824 algorithm description.
4825
Werner Lemberg3f542492013-09-11 23:08:31 +020048262013-09-11 Werner Lemberg <wl@gnu.org>
4827
4828 [autofit] Improve Hebrew rendering.
4829
4830 This change introduces a new blue zone property
4831 `AF_BLUE_PROPERTY_LATIN_LONG' to make the auto-hinter ignore short
4832 top segments.
4833
4834 * src/autofit/afblue.dat: Fix Hebrew blue strings.
4835 Use AF_BLUE_PROPERTY_LATIN_LONG for AF_BLUE_STRING_HEBREW_TOP.
4836
4837 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_LONG): New macro.
4838
4839 * src/autofit/afblue.c, src/autofit/afblue.h: Updated.
4840
4841 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Handle
4842 `AF_LATIN_IS_LONG_BLUE'.
4843
4844 * src/autofit/aflatin.h (AF_LATIN_IS_LONG_BLUE): New macro.
4845
Werner Lemberg85a7fdf2013-08-29 21:03:05 +020048462013-08-28 Behdad Esfahbod <behdad@google.com>
4847
4848 [sfnt] Fix frame access while reading WOFF table directory.
4849
4850 * src/sfnt/sfobjs.c (woff_open_font): Using single memory frame
4851 while reading the directory entries for the whole loop.
4852
48532013-08-29 Werner Lemberg <wl@gnu.org>
Werner Lembergd689d1c2013-08-29 17:53:40 +02004854 Behdad Esfahbod <behdad@google.com>
4855
4856 Implement support for WOFF containers.
4857
4858 We simply synthesize a SFNT from the WOFF, create a memory stream
4859 for the new data, and load the SFNT as usual.
4860
4861 Does NOT add any API to access WOFF metadata or private blocks.
4862
4863 * include/freetype/internal/tttypes.h (WOFF_HeaderRec,
4864 WOFF_TableRec): New structures.
4865
4866 * include/freetype/tttags.h (TTAG_wOFF): New macro.
4867
4868 * src/base/ftobjs.c (FT_Open_Face): Set `stream' after calling
4869 `open_face'.
4870
4871 * src/sfnt/sfobjs.c [FT_CONFIG_OPTION_SYSTEM_ZLIB]: Include
4872 `FT_GZIP_H'.
4873 (WRITE_BYTE, WRITE_USHORT, WRITE_ULONG): New temporary macros for
4874 writing to a stream.
4875 (sfnt_stream_close, compare_offsets, woff_open_font): New functions.
4876 (sfnt_open_font): Handle `TTAG_wOFF'.
4877 (sfnt_init_face): Set `stream' after calling `sfnt_open_font'.
4878
4879 * src/truetype/ttobjs.c (tt_face_init): Set `stream' after calling
4880 `sfnt->init_face'.
4881
4882 * src/base/ftobjs.c (open_face): Use a pointer to FT_Stream as an
4883 argument so that a changed stream survives.
4884 Update callers.
4885
48862013-08-28 Werner Lemberg <wl@gnu.org>
Werner Lemberge0f39ae2013-08-28 17:34:01 +02004887
Werner Lembergdc240522013-08-29 17:53:24 +02004888 [gzip] New function `FT_Gzip_Uncompress'.
4889
4890 This is modeled after zlib's `uncompress' function. We need this
4891 for WOFF support.
4892
4893 * include/freetype/ftgzip.h, src/gzip/ftgzip.c (FT_Gzip_Uncompress):
4894 New function.
4895
4896 * src/gzip/rules.mk: Rewrite to better reflect dependencies.
4897
48982013-08-28 Werner Lemberg <wl@gnu.org>
4899
Werner Lemberg5195ecd2013-08-28 17:41:21 +02004900 [autofit] Fix `make multi' compilation.
4901
4902 * src/autofit/afblue.cin, src/autofit/afblue.c: Don't include
4903 `afblue.h' but `aftypes.h'.
4904 * src/autofit/afcjk.c: Don't include `aftypes.h' but `afglobal.h'.
4905
49062013-08-28 Werner Lemberg <wl@gnu.org>
4907
Werner Lemberge0f39ae2013-08-28 17:34:01 +02004908 [autofit] Fix C++ compilation.
4909
4910 * src/autofit/afglobal.c (af_face_globals_get_metrics),
4911 src/autofit/afdummy.c (af_dflt_script_class), src/autofit/afindic.c
4912 (af_deva_script_class): Use proper casts.
4913
Behdad Esfahbodbd3849e2013-08-27 21:43:38 +020049142013-08-27 Behdad Esfahbod <behdad@google.com>
4915
Behdad Esfahbodc799dd62013-08-27 21:46:03 +02004916 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix sign typos.
4917
49182013-08-27 Behdad Esfahbod <behdad@google.com>
4919
Behdad Esfahbodbd3849e2013-08-27 21:43:38 +02004920 FT_Open_Face: Improve external stream handling.
4921
4922 If the font's `clazz->init_face' function wants to swap to new
4923 stream, handling of whether original stream was external could
4924 result to either memory leak or double free. Mark externality into
4925 face flags before calling `init_face' such that the clazz can handle
4926 external streams properly.
4927
4928 * src/base/ftobjs.c (FT_Open_Face): Move code to set
4929 FT_FACE_FLAG_EXTERNAL_STREAM to...
4930 (open_face): This function.
4931
Werner Lemberg5e53db22013-08-27 18:37:39 +020049322013-08-27 Werner Lemberg <wl@gnu.org>
4933
Werner Lembergbcd8c0b2013-08-27 21:36:03 +02004934 Remove `FT_SqrtFixed' function.
4935
4936 It's no longer used.
4937
4938 * include/freetype/internal/ftcalc.h, src/base/ftcalc.c: Do it.
4939
49402013-08-27 Werner Lemberg <wl@gnu.org>
4941
Werner Lemberg5e53db22013-08-27 18:37:39 +02004942 [autofit] While tracing, report script names instead of ID values.
4943
4944 * src/autofit/afglobal.c (af_script_names) [FT_DEBUG_LEVEL_TRACE]:
4945 New array.
4946 * src/autofit/afglobal.h: Updated.
4947
4948 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
4949 af_cjk_hint_edges): Use `af_script_names'.
4950 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
4951 af_latin_hint_edges): Ditto.
4952
Werner Lemberg92f5a042013-08-26 09:22:27 +020049532013-08-26 Werner Lemberg <wl@gnu.org>
4954
Werner Lemberg278f64b2013-08-26 20:20:03 +02004955 [autofit] Report used script while hinting a glyph.
4956
4957 * src/autofit/afcjk.c (af_cjk_hint_edges), src/autofit/aflatin.c
4958 (af_latin_hint_edges): Implement it.
4959
49602013-08-26 Werner Lemberg <wl@gnu.org>
4961
Werner Lemberg371f5c32013-08-26 20:11:24 +02004962 [autofit] Add support for Hebrew script.
4963
4964 * src/autofit/afblue.dat: Add blue strings for Hebrew.
4965 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4966
4967 * src/autofit/aflatin.c (af_hebr_uniranges): New array.
4968 (af_hebr_script_class): New script.
4969 * src/autofit/aflatin.h, src/autofit/afscript.h: Updated.
4970
49712013-08-26 Werner Lemberg <wl@gnu.org>
4972
Werner Lemberg098121d2013-08-26 18:54:05 +02004973 [autofit] Improve tracing messages.
4974
4975 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Mention script
4976 ID in tracing message.
4977 (af_cjk_metrics_init_blues): Initialize `axis' outside of the inner
4978 loop.
4979 Improve tracing messages.
4980 (af_cjk_hint_edges) [FT_DEBUG_LEVEL_TRACE]: New variable
4981 `num_actions' to count hinting actions.
4982 Improve tracing messages.
4983
4984 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Mention
4985 script ID in tracing message.
4986 (af_latin_metrics_init_blues, af_latin_hint_edges): Improve tracing
4987 messages.
4988
49892013-08-26 Werner Lemberg <wl@gnu.org>
4990
Werner Lembergffee64a2013-08-26 12:55:48 +02004991 Better tracing of loaded glyphs.
4992
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02004993 Previously, the loading of a glyph was traced at level 4, if at all.
Werner Lembergffee64a2013-08-26 12:55:48 +02004994 With this change, all font loading routines emit a tracing message
4995 at level 1, making it easier to select tracing output (for example
4996 using F2_DEBUG="any:1 afhints:7 aflatin:7").
4997
4998 * src/bdf/bdfdrivr.c (BDF_Glyph_Load): Add tracing message.
4999 * src/cff/cffdrivr.c (cff_glyph_load): Ditto.
5000 * src/cff/cffgload.c (cff_decoder_prepare): Improve tracing
5001 messages.
5002 * src/cid/cidgload.c (cid_load_glyph): Use level 1 for tracing
5003 message.
5004 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Ditto.
5005 * src/pfr/pfrobjs.c (pfr_slot_load): Add tracing message.
5006 * src/truetype/ttgload.c (TT_Load_Glyph): Ditto.
5007 * src/type1/t1gload.c (T1_Load_Glyph): Ditto.
5008 * src/type42/t42objs.c (T42_GlyphSlot_Load): Ditto.
5009 * src/winfonts/winfnt.c (FNT_Load_Glyph): Ditto.
5010
50112013-08-26 Werner Lemberg <wl@gnu.org>
5012
Werner Lemberg33655a92013-08-26 09:58:50 +02005013 [autofit] Fix script selection.
5014
5015 * src/autofit/afglobal.c (af_face_globals_get_metrics): Use
5016 `AF_SCRIPT_DFLT', not value 0.
5017 Simplify code.
5018
5019 * src/autofit/afscript.h: Sort by script name.
5020
50212013-08-26 Werner Lemberg <wl@gnu.org>
5022
Werner Lemberg92f5a042013-08-26 09:22:27 +02005023 [autofit] Make `dummy' hinter work as expected.
5024
5025 * src/autofit/afdummy.c (af_dummy_hints_init): Properly set scaling
5026 information.
5027 (af_dummy_hints_apply): Scale the glyphs.
5028
Werner Lemberg8b8be782013-08-25 08:01:41 +020050292013-08-25 Werner Lemberg <wl@gnu.org>
5030
Werner Lembergc1eb4452013-08-25 19:47:26 +02005031 [autofit] Make `cjk' module use blue stringsets.
5032
5033 * src/autofit/afcjk.c (AF_CJK_MAX_TEST_CHARACTERS): Removed.
5034 (af_cjk_hani_blue_chars): Removed.
5035 (AF_CJK_BLUE_TYPE_*): Removed.
5036 (af_cjk_metrics_init_blues): Replace AF_CJK_MAX_TEST_CHARACTERS with
5037 AF_BLUE_STRING_MAX_LEN.
5038 Change loops to use offsets (in file `afblue.h') into the new arrays
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005039 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
Werner Lembergc1eb4452013-08-25 19:47:26 +02005040 Instead of three dimensions (as used in the old blue string array)
5041 we now use properties to do the same, saving one loop nesting level.
5042
5043 * src/autofit/afcjk.h: Remove old enumeration values superseded by
5044 the new data in `afblue.h'.
5045 (AF_CJK_IS_TOP_BLUE, AF_CJK_IS_HORIZ_BLUE, AF_CJK_IS_FILLED_BLUE,
5046 AF_CJK_IS_RIGHT_BLUE): New macros, to be used in
5047 `af_cjk_metrics_init_blues'.
5048 (AF_CJK_BLUE_IS_RIGHT): Remove this now redundant enum value.
5049 (AF_CJK_BLUE_IS_TOP): Renamed to...
5050 (AF_CJK_BLUE_TOP): This.
5051 (AF_CJK_MAX_BLUES): Remove.
5052 (AF_CJKAxisRec): Updated.
5053
50542013-08-25 Werner Lemberg <wl@gnu.org>
5055
Werner Lemberg5c4a23a2013-08-25 19:29:07 +02005056 [autofit] Typo.
5057
5058 * src/autofit/afblue.hin, src/autofit/afblue.c (GET_UTF8_CHAR): Use
5059 cast.
5060
50612013-08-25 Werner Lemberg <wl@gnu.org>
5062
Werner Lemberg306f8c52013-08-25 13:07:08 +02005063 [autofit] Synchronize `cjk' with `latin' module (and vice versa).
5064
5065 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Add tracing
5066 messages.
5067 (af_cjk_metrics_init_blues): Don't pass blue string array as
5068 argument but use the global array directly.
5069 Use `outline' directly.
5070 Update and add tracing messages.
5071 (af_cjk_metrics_init): Simplify code.
5072 (af_cjk_metrics_scale_dim): Improve tracing message.
5073 (af_cjk_metrics_scale): Synchronize.
5074
5075 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
5076 af_latin_metrics_init_blues): Improve and add tracing messages.
5077
50782013-08-25 Werner Lemberg <wl@gnu.org>
5079
Werner Lemberg0975d682013-08-25 08:37:47 +02005080 [autofit] Make `latin' module use blue stringsets.
5081
5082 * src/autofit/aflatin.c (AF_LATIN_MAX_TEST_CHARACTERS): Removed.
5083 (af_latin_blue_chars): Removed.
5084 (af_latin_metrics_init_blues): Replace AF_LATIN_MAX_TEST_CHARACTERS
5085 with AF_BLUE_STRING_MAX_LEN.
5086 Change loops to use offsets (in file `afblue.h') into the new arrays
5087 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
5088 Use `AF_LATIN_IS_SMALL_TOP_BLUE' macro.
5089
5090 * src/autofit/aflatin.h: Remove old enumeration values superseded by
5091 the new data in `afblue.h'.
5092 (AF_LATIN_IS_TOP_BLUE): Updated definition.
5093 (AF_LATIN_IS_SMALL_TOP_BLUE): New macro.
5094 (AF_LATIN_MAX_BLUES): Remove.
5095 (AF_LatinAxisRec): Updated.
5096
50972013-08-25 Werner Lemberg <wl@gnu.org>
5098
Werner Lembergdb3e5b92013-08-25 08:23:22 +02005099 [autofit] Add blue stringsets.
5100
5101 * src/autofit/aftypes.h: Include `afblue.h'.
5102 (AF_ScriptClassRec): Add `blue_stringset' field.
5103 (AF_DEFINE_SCRIPT_CLASS): Updated.
5104
5105 * src/autofit/autofit.c: Include `afblue.c'.
5106
5107 * src/autofit/afcjk.c (af_hani_script_class), src/autofit/afdummy.c
5108 (af_dflt_script_class), src/autofit/afindic.c
5109 (af_deva_script_class), src/autofit/aflatin.c
5110 (af_latn_script_class), src/autofit/aflatin2.c
5111 (af_ltn2_script_class): Updated.
5112
5113 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afblue.c'.
5114
51152013-08-25 Werner Lemberg <wl@gnu.org>
5116
Werner Lemberg8b8be782013-08-25 08:01:41 +02005117 [autofit] Introduce data file for blue strings.
5118
5119 The idea is to have a central file which gets processed by a Perl
5120 script to create proper `.c' and `.h' files using templates. There
5121 are two other reasons to do that:
5122
5123 . The data file should be easily readable. We use UTF-8 encoding
5124 which then gets converted to single bytes.
5125
5126 . Since the number of supported scripts will increase soon, the
5127 current usage of blue string arrays is a waste of space. Using
5128 the Perl script it is possible to imitate jagged arrays,
5129 defining enumeration constants as offsets into the arrays.
5130
5131 This commit only adds files without changing any functionality.
5132
5133 * src/autofit/afblue.dat: New data file.
5134 * src/tools/afblue.pl: New Perl script for processing `afblue.dat'.
5135
5136 * src/autofit/afblue.cin, src/autofit/afblue.hin: New template files
5137 for...
5138 * src/autofit/afblue.c, src/autofit/afblue.c: New source files.
5139 To avoid a dependency on Perl, we add them too.
5140
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -040051412013-08-19 Alexei Podtelezhnikov <apodtele@gmail.com>
5142
Werner Lemberg71c0ad62013-08-27 21:30:09 +02005143 [base] Enable new algorithm for `BBox_Cubic_Check'.
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -04005144
Werner Lemberg71c0ad62013-08-27 21:30:09 +02005145 * src/base/ftbbox.c: Enable new BBox_Cubic_Check algorithm, remove
5146 the old one.
5147 Improve comments.
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -04005148
Werner Lemberg6bfa2632013-08-18 18:34:05 +020051492013-08-18 Werner Lemberg <wl@gnu.org>
5150
Werner Lemberg4af44442013-08-18 18:46:30 +02005151 * builds/unix/unix-def.in (freetype2.pc): Don't set executable bit.
5152
51532013-08-18 Werner Lemberg <wl@gnu.org>
5154
Werner Lemberg6bfa2632013-08-18 18:34:05 +02005155 Fix Savannah bug #39804.
5156
5157 * builds/unix/configure.raw (LIBPNG): Define and export.
5158 * builds/unix/freetype-config.in, builds/unix/freetype2.in: Handle
5159 libpng.
5160
Alexei Podtelezhnikov32a7d872013-08-17 22:19:21 -040051612013-08-17 Alexei Podtelezhnikov <apodtele@gmail.com>
5162
5163 [base] Clean up BBox_Conic_Check.
5164
5165 * src/base/ftbbox.c (BBox_Conic_Check): Remove redundant checks for
5166 extremum at the segment ends, which are already within the bbox.
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005167 Slightly modify calculations.
Alexei Podtelezhnikov32a7d872013-08-17 22:19:21 -04005168
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -040051692013-08-15 Alexei Podtelezhnikov <apodtele@gmail.com>
5170
5171 [base] Finish experimental (disabled) BBox_Cubic_Check implementation.
5172
5173 * src/base/ftbbox.c (BBox_Cubic_Check): Scale arguments to improve
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005174 accuracy and avoid overflows.
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -04005175
Alexei Podtelezhnikov61a65512013-08-13 22:28:57 -040051762013-08-13 Alexei Podtelezhnikov <apodtele@gmail.com>
5177
5178 [base] Refactor experimental (disabled) BBox_Cubic_Check.
5179
5180 * src/base/ftbbox.c (BBox_Cubic_Check): Implement the minimum search
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -04005181 as the mirror image of the maximum search implemented here...
5182 (update_max): New function.
Alexei Podtelezhnikov61a65512013-08-13 22:28:57 -04005183
John Tytgat9bcfab82013-08-06 08:55:19 +020051842013-08-06 John Tytgat <John.Tytgat@esko.com>
5185
5186 Fix Savannah bug #39702.
5187
5188 * src/cff/cffload.c (cff_index_get_pointers): Check for `cur_offset
5189 != 0'; this stronger test is mandated by the CFF specification.
5190 Fix test for INDEX structures which have one or more empty entries
5191 at the end.
5192
Werner Lembergcc25e3a2013-08-05 08:46:15 +020051932013-08-05 Werner Lemberg <wl@gnu.org>
5194
Werner Lemberga32682f2013-08-06 00:21:46 +02005195 Fix gcc pragmas, part 2.
5196
5197 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
5198 TT_DotFix14_long_long): `#pragma gcc diagnostic {push,pop}' has been
5199 introduced with gcc version 4.6.
5200
52012013-08-05 Werner Lemberg <wl@gnu.org>
5202
Werner Lemberg69e524d2013-08-05 23:38:32 +02005203 Fix gcc pragmas.
5204
5205 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
5206 TT_DotFix14_long_long): Older gcc versions don't accept diagnostic
5207 pragmas within a function body.
5208
52092013-08-05 Werner Lemberg <wl@gnu.org>
5210
Werner Lemberg9e6de362013-08-05 16:37:21 +02005211 Fix Savannah bug #39700.
5212
5213 * builds/unix/ftconfig.h: Synchronize with
5214 `include/freetype/config/ftconfig.h'.
5215
5216 * builds/vms/ftconfig.h: Ditto.
5217 Make the differences to the master `ftconfig.h' file as small as
5218 possible for easier maintainance.
5219
52202013-08-05 Werner Lemberg <wl@gnu.org>
5221
Werner Lembergcc25e3a2013-08-05 08:46:15 +02005222 [autofit] Improve handling of `near' points.
5223
5224 Points which are very near to each other are now marked as such.
5225 The `weak' flag is then computed by using the `in' vector of the
5226 first and the `out' vector of the last point of a group of near
5227 points.
5228
5229 For example, this fixes the rendering of glyph `Oslash' in
5230 `Roboto-Thin.ttf'.
5231
5232 * src/autofit/afhints.h (AF_Flags): New value `AF_FLAGS_NEAR'.
5233
5234 * src/autofit/afhints.c (af_glyph_hints_reload): Introduce
5235 the heuristic value `near_limit' to decide whether the current point
5236 is near to the previous one, then set `AF_FLAG_NEAR' accordingly.
5237 Store good `in' vector (of last non-near point) in
5238 `last_good_in_{x,y}' and use it as an argument to
5239 `ft_corner_is_flat' if necessary.
5240
Werner Lemberg74a9b672013-08-02 14:53:32 +020052412013-08-02 Werner Lemberg <wl@gnu.org>
5242
Werner Lemberg0d28a7d2013-08-02 22:59:43 +02005243 * include/freetype/ftcffdrv.h: Improve documentation.
5244 This is based on blog entries from David Lemon and Dave Arnold (both
5245 from Adobe) with kind permission. Dave also helped in
5246 proof-reading.
5247
52482013-08-02 Werner Lemberg <wl@gnu.org>
5249
Werner Lemberg456cc442013-08-02 20:25:21 +02005250 [autofit] Move declaration of scripts into separate file.
5251
5252 This has the benefit that we don't need to duplicate the data at
5253 different places.
5254
5255 * src/autofit/afscript.h: New file.
5256
5257 * src/autofit/aftypes.h (AF_Script): Include `afscript.h' to define
5258 the enumeration values.
5259
5260 * src/autofit/afglobal.c: Include `afscript.h' to get the script
5261 specific header files.
5262 (af_script_classes): Include `afscript.h' to fill this array.
5263
5264 * src/autofit/afpic.c: Include `afscript.h' to get the script
5265 specific header files.
5266 (autofit_module_class_pic_init): Include `afscript.h' for
5267 initialization.
5268 * src/autofit/afpic.h (AF_SCRIPT_CLASSES_COUNT,
5269 AF_SCRIPT_CLASSES_REC_COUNT): Removed. Use `AF_SCRIPT_MAX' instead.
5270
5271 * src/autofit/rules.mk (AUTOF_DRV_H): Updated.
5272
52732013-08-02 Werner Lemberg <wl@gnu.org>
5274
Werner Lemberg773601d2013-08-02 19:51:17 +02005275 [autofit] Move declaration of writing systems into separate file.
5276
5277 This has the benefit that we don't need to duplicate the data at
5278 different places.
5279
5280 * src/autofit/afwrtsys.h: New file.
5281
5282 * src/autofit/aftypes.h (AF_WritingSystem): Include `afwrtsys.h' to
5283 define the enumeration values.
5284
5285 * src/autofit/afglobal.c: Include `afwrtsys.h' to get the writing
5286 system specific header files.
5287 Include `afpic.h'.
5288 (af_writing_system_classes): Include `afwrtsys.h' to fill this
5289 array.
5290
5291 * src/autofit/afpic.c: Include `afwrtsys.h' to get the writing
5292 system specific header files.
5293 (autofit_module_class_pic_init): Include `afwrtsys.h' for
5294 initialization.
5295 * src/autofit/afpic.h (AF_WRITING_SYSTEM_CLASSES_COUNT,
5296 AF_WRITING_SYSTEM_CLASSES_REC_COUNT): Removed. Use
5297 `AF_WRITING_SYSTEM_MAX' instead.
5298
52992013-08-02 Werner Lemberg <wl@gnu.org>
5300
Werner Lemberg74a9b672013-08-02 14:53:32 +02005301 [sfnt] Fix compilation with g++.
5302
5303 * src/sfnt/pngshim.c (error_callback, read_data_from_FT_stream): Use
5304 cast.
5305 (Load_SBit_Png): Pacify compiler.
5306
Werner Lemberg89a529f2013-08-02 14:50:23 +020053072013-08-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5308 Werner Lemberg <wl@gnu.org>
5309
5310 [autofit] Fix `make multi'.
5311
5312 * include/freetype/config/ftconfig.h (FT_LOCAL_ARRAY,
5313 FT_LOCAL_ARRAY_DEF): New macros.
5314
5315 * src/autofit/afglobal.c (af_writing_system_classes,
5316 af_script_classes): Use FT_LOCAL_ARRAY_DEF.
5317 * src/autofit/afglobal.h: Declare `af_writing_system_classes' and
5318 `af_script_classes'.
5319 * src/autofit/afloader.c: Include `afpic.h'.
5320
Werner Lemberge8ed2d62013-08-01 12:20:20 +020053212013-08-01 Werner Lemberg <wl@gnu.org>
5322
5323 Another round of cppcheck nitpicks.
5324
5325 The call was (from the top-level of the FreeType tree):
5326
5327 cppcheck --force \
5328 --enable=all \
5329 -I /usr/include \
5330 -I /usr/local/include \
5331 -I /usr/lib/gcc/i586-suse-linux/4.7/include \
5332 -I include \
5333 -I include/freetype \
5334 -I include/freetype/config \
5335 -I include/freetype/internal \
5336 -DFT2_BUILD_LIBRARY \
5337 . &> cppcheck.log
5338
5339 using cppcheck git commit f7e93f99.
5340
5341 Note that cppcheck still can't handle `#include FOO' (with `FOO' a
5342 macro).
5343
5344 */* Improve variable scopes.
5345 */* Remove redundant initializations which get overwritten.
5346
5347 * src/gxvalid/*: Comment out redundant code or guard it with
5348 FT_DEBUG_LEVEL_TRACE.
5349
Werner Lemberg5d6a3602013-07-30 23:17:04 +020053502013-07-30 Werner Lemberg <wl@gnu.org>
5351
Werner Lemberg72f5ff52013-07-31 22:49:29 +02005352 [autofit] Introduce `writing systems'.
5353
5354 This patch adds a new top level to the auto-hinter's script class
5355 hierarchy. It defines `writing systems' which can contain multiple
5356 scripts.
5357
5358 For example, the `latin' writing system (in file `aflatin.c') is
5359 able to support scripts like Latin, Cyrillic, Armenian, etc., which
5360 can be handled similarly.
5361
5362 Scripts are now named using four-letter OpenType tags.
5363
5364 * src/autofit/aftypes.h (AF_ScriptClassRec): Move relevant members
5365 to...
5366 (AF_WritingSystemClassRec): This new structure. It holds pointers
5367 to functions which can be shared among related scripts.
5368 (AF_WritingSystem): New enumeration.
5369 (AF_Script): Revised values using four-letter tags.
5370 (AF_DEFINE_WRITING_SYSTEM_CLASS): New macro.
5371 (AF_DEFINE_SCRIPT_CLASS): Updated.
5372
5373 * src/autofit/afglobal.c (af_writing_system_classes): New global,
5374 constant array.
5375 (af_script_classes): Updated.
5376 (af_face_globals_free): Updated.
5377 Remove assertion.
5378 (af_face_globals_get_metrics): Updated.
5379
5380 * src/autofit/afglobal.h (AF_SCRIPT_FALLBACK)
5381 [!AF_CONFIG_OPTION_CJK]: Handle this case.
5382
5383 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
5384 Updated.
5385
5386 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated;
5387 initialize structures for both writing systems and scripts.
5388 * src/autofit/afpic.h: Updated.
5389 (AF_WRITING_SYSTEM_CLASSES_GET): New macro.
5390
5391 * src/autofit/afcjk.c (af_cjk_writing_system_class): New writing
5392 system.
5393 (af_cjk_uniranges): Renamed to...
5394 (af_hani_uniranges): This.
5395 (af_cjk_script_class): Reduced and renamed to...
5396 (af_hani_script_class): This.
5397 * src/autofit/afcjk.h: Updated.
5398
5399 * src/autofit/afdummy.c (af_dummy_writing_system_class): New writing
5400 system.
5401 (af_dummy_script_class): Reduced and renamed to...
5402 (af_dflt_script_class): This.
5403 * src/autofit/afdummy.h: Updated.
5404
5405 * src/autofit/afindic.c (af_indic_writing_system_class): New writing
5406 system.
5407 (af_indic_uniranges): Renamed to...
5408 (af_deva_uniranges): This.
5409 (af_indic_script_class): Reduced and renamed to...
5410 (af_deva_script_class): This.
5411 * src/autofit/afcjk.h: Updated.
5412
5413 * src/autofit/aflatin.c (af_latin_writing_system_class): New writing
5414 system.
5415 (af_latin_uniranges): Renamed to...
5416 (af_latn_uniranges): This.
5417 (af_latin_script_class): Reduced and renamed to...
5418 (af_latn_script_class): This.
5419 * src/autofit/aflatin.h: Updated.
5420
5421 * src/autofit/aflatin2.c (af_latin2_writing_system_class): New
5422 writing system.
5423 (af_latin2_uniranges): Renamed to...
5424 (af_ltn2_uniranges): This.
5425 Synchronize ranges with `latin'.
5426 (af_latin2_script_class): Reduced and renamed to...
5427 (af_ltn2_script_class): This.
5428 * src/autofit/aflatin2.h: Updated.
5429
54302013-07-30 Werner Lemberg <wl@gnu.org>
5431
Werner Lemberg5d6a3602013-07-30 23:17:04 +02005432 [autofit] Variable renaming.
5433
5434 * src/autofit/aftypes.h (AF_ScriptMetricsRec):
5435 s/clazz/script_class/.
5436 Update all users.
5437
suzuki toshiya2b29ed62013-07-30 13:55:29 +090054382013-07-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5439
5440 Ignore libpng-config under cross-building configuration,
5441 because it will return the flags for the hosting environment.
5442
5443 * builds/unix/configure.raw: Ignore libpng-config when
5444 `cross_compiling' == yes.
5445
suzuki toshiyaf2e7f1e2013-07-30 13:32:57 +090054462013-07-30 Behdad Esfahbod <behdad@google.com>
5447
5448 Prevent division by zero by a transparent color.
5449
5450 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra):
5451 Return 0 immediately, when alpha channel is zero.
5452
Behdad Esfahbod21c32b02013-07-25 21:53:18 +020054532013-07-25 Behdad Esfahbod <behdad@google.com>
5454
5455 Add FT_FACE_FLAG_COLOR and FT_HAS_COLOR.
5456
5457 Also disambiguate Google's color bitmap tables.
5458
5459 * include/freetype/freetype.h (FT_FACE_FLAG_COLOR, FT_HAS_COLOR):
5460 New macros.
5461
5462 * include/freetype/internal/tttypes.h (TT_SbitTableType): Add
5463 TT_SBIT_TABLE_TYPE_CBLC.
5464
5465 * src/sfnt/sfobjs.c (sfnt_load_face): Handle FT_FACE_FLAG_COLOR.
5466
5467 * src/sfnt/ttsbit.c (tt_face_load_sbit,
5468 tt_face_load_strike_metrics, tt_face_load_sbit_image): Handle
5469 TT_SBIT_TABLE_TYPE_CBLC.
5470
suzuki toshiyab4725cb2013-07-24 14:25:39 +090054712013-07-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5472
5473 [sfnt] Fix for `make multi' target.
5474
5475 * src/sfnt/pngshim.c (Load_SBit_Png): Use FT_LOCAL_DEF().
5476
Werner Lemberg6a7df622013-07-20 10:48:37 +020054772013-07-20 Werner Lemberg <wl@gnu.org>
5478
5479 * docs/INSTALL.GNU: Updated.
5480
Behdad Esfahbodff269522013-07-20 08:02:39 +020054812013-07-20 Behdad Esfahbod <behdad@google.com>
5482
5483 [sfnt] Fix `sbix' table version handling.
5484
5485 * src/sfnt/ttsbit.c (tt_face_load_sbit) [TT_SBIT_TABLE_TYPE_SBIX]:
5486 USHORT version numbers are to be considered as `minor'.
5487
Werner Lemberg05c14212013-07-19 23:11:23 +020054882013-07-19 Werner Lemberg <wl@gnu.org>
5489
5490 [autofit] Fix segment classification for blue zones.
5491
5492 The old code (essentially unchanged since the very beginning)
5493 incorrectly handled this configuration
5494
5495 x -o- x
5496 / \
5497 / \
5498 / \
5499 o o
5500
5501 as flat and this
5502
5503 o o
5504 / /
5505 x| x|
5506 | |
5507 o---------------o
5508
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005509 as round. (`o' and `x' are on and off points, respectively).
Werner Lemberg05c14212013-07-19 23:11:23 +02005510
5511 This is a major change which should improve the rendering results
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005512 enormously for many TrueType fonts, especially in the range approx.
Werner Lemberg05c14212013-07-19 23:11:23 +02005513 20-40ppem, fixing the appearance of many overshoots.
5514
5515 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Look at the
5516 first and last points of the segment, not the points right before
5517 and after.
5518
55192013-07-19 Behdad Esfahbod <behdad@google.com>
Werner Lemberg01705392013-07-18 13:13:12 +02005520
Behdad Esfahbod778a7e62013-07-19 14:28:28 +02005521 [sfnt] `sbix' fix-ups.
5522
5523 * src/sfnt/sfobjs.c (sfnt_load_face): Apple's `sbix' color bitmaps
5524 are rendered scaled and then the `glyf' outline rendered on top. We
5525 don't support that yet, so just ignore the `glyf' outline and
5526 advertise it as a bitmap-only font.
5527
5528 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
5529 [TT_SBIT_TABLE_TYPE_SBIX]: Return metrics in 26.6 units.
5530 (tt_face_load_sbix_image): Typo.
5531
55322013-07-18 Behdad Esfahbod <behdad@google.com>
5533
Werner Lemberg01705392013-07-18 13:13:12 +02005534 [sfnt] Add support for Apple's `sbix' color bitmap table.
5535
5536 * include/freetype/internal/tttypes.h (TT_SBit_MetricsRec): Widen
5537 fields to FT_Short and FT_UShort, respectively.
5538 (TT_SBitTableType): New enumeration.
5539 (TT_FaceRec): Add `sbit_table_type' field.
5540
5541 * include/freetype/tttags.h (TTAG_sbix): New macro.
5542
5543 * src/sfnt/pngshim.c (Load_SBit_Png): Pass a more generic
5544 FT_GlyphSlot argument instead FT_Bitmap.
5545 Add flag to control map and metrics handling.
5546 Update all users.
5547
5548 * src/sfnt/ttsbit.c: Include `ttmtx.h'.
5549 (tt_face_load_eblc): Renamed to...
5550 (tt_face_load_sbit): This.
5551 Handlic `sbix' bitmaps.
5552 (tt_face_free_eblc): Renamed to...
5553 (tt_face_load_sbit): This.
5554 Updated.
5555 (tt_face_load_strike_metrics): Handle `sbix' bitmaps.
5556 (tt_face_load_sbix_image): New function.
5557 (tt_sbit_decoder_alloc_bitmap, tt_sbit_decoder_load_image,
5558 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
5559 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
5560 tt_sbit_decoder_load_image, tt_sbit_decoder_load_bitmap): Don't pass
5561 and handle load flags.
5562 (tt_sbit_decoder_load_bitmap) [!FT_CONFIG_OPTION_USE_PNG]: Better
5563 handle formats 17-19.
5564 Move color to grayscale conversion to...
5565 (tt_face_load_sbit_image): Here.
5566 Handle `sbix' bitmaps.
5567
5568 * src/sfnt/pngshim.h: Updated.
5569 * src/sfnt/ttsbit.h: Updated.
5570 * src/sfnt/sfdriver.c: Updated.
5571
Werner Lemberg274207e2013-07-18 12:38:57 +020055722013-07-18 Werner Lemberg <wl@gnu.org>
5573
5574 [sfnt] Ignore invalid magic number in `head' or `bhed'.
5575
5576 Other font engines seem to ignore it also. Problem reported by
5577 Hin-Tak Leung <htl10@users.sourceforge.net>.
5578
5579 * src/sfnt/ttload.c (check_table_dir): Don't abort but warn only if
5580 we have an invalid magic number.
5581
Werner Lemberg9a7951d2013-07-16 15:25:24 +020055822013-07-16 Werner Lemberg <wl@gnu.org>
5583
5584 [smooth] Fix segfault caused by previous commit.
5585
5586 * src/smooth/ftgrays.c (gray_set_cell): Always compute
5587 `ras.invalid'.
5588
David Turnera5f33ee2013-07-16 12:40:03 +020055892013-07-16 David Turner <digit@google.com>
5590
David Turner89929ec2013-07-16 13:36:07 +02005591 [smooth] Improve performance.
5592
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02005593 Provide a work-around for an ARM-specific performance bug in GCC.
David Turner89929ec2013-07-16 13:36:07 +02005594 This speeds up the rasterizer by more than 5%.
5595
5596 Also slightly optimize `set_gray_cell' and `gray_record_cell' (which
5597 also improves performance on other platforms by a tiny bit (<1%).
5598
5599 * src/smooth/ftgrays.c (FT_DIV_MOD): New macro.
5600 Use it where appropriate.
5601
5602 (gray_record_cell, gray_set_cell, gray_move_to,
5603 gray_convert_glyph_inner): Streamline condition handling.
5604
56052013-07-16 David Turner <digit@google.com>
5606
David Turnerf66d48e2013-07-16 13:18:00 +02005607 [truetype] Add assembler code for TT_MulFix14 and TT_DotFix14.
5608
5609 This patch provides slightly optimized versions for ARM, x86, and
5610 x86_64 CPUs if built with GCC.
5611
5612 Also remove some dead code.
5613
5614 * src/truetype/ttinterp.c (TT_MulFix14_arm, TT_MulFix14_long_long,
5615 TT_DotFix14_long_long): New functions.
5616
56172013-07-16 David Turner <digit@google.com>
5618
David Turnerb2890882013-07-16 12:52:18 +02005619 Optimize FT_MulFix for x86_64 GCC builds.
5620
5621 This patch provides an optimized `FT_MulFix' implementation for
5622 x86_64 machines when FreeType is built with GCC, or compatible
5623 compilers like Clang.
5624
5625 Example:
5626 bin/ftbench -p -t 5 -s 14 -f 0008 Arial.ttf
5627
5628 Before:
5629
5630 Load 4.863 us/op
5631 Load_Advances (Normal) 4.816 us/op
5632 Load_Advances (Fast) 0.028 us/op
5633 Render 2.753 us/op
5634 Get_Glyph 0.463 us/op
5635 Get_CBox 0.077 us/op
5636 Get_Char_Index 0.023 us/op
5637 Iterate CMap 13.898 us/op
5638 New_Face 12.368 us/op
5639 Embolden 0.028 us/op
5640 Get_BBox 0.302 us/op
5641
5642 After:
5643
5644 Load 4.617 us/op
5645 Load_Advances (Normal) 4.645 us/op
5646 Load_Advances (Fast) 0.027 us/op
5647 Render 2.789 us/op
5648 Get_Glyph 0.460 us/op
5649 Get_CBox 0.077 us/op
5650 Get_Char_Index 0.024 us/op
5651 Iterate CMap 13.403 us/op
5652 New_Face 12.278 us/op
5653 Embolden 0.028 us/op
5654 Get_BBox 0.301 us/op
5655
5656 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
5657 (FT_MulFix_x86_64): New function.
5658
56592013-07-16 David Turner <digit@google.com>
5660
David Turnera5f33ee2013-07-16 12:40:03 +02005661 Speed up ARMv7 support.
5662
5663 When building for ARMv7 with thumb2 instructions, the optimized
5664 `FT_MulFix_arm' assembly routine was not being used.
5665
5666 The reason for this is in the `ftconfig.h' header, namely:
5667
5668 - The assembly routine uses the `smull' instruction which is not
5669 available when generating Thumb-1 machine code. It is available
5670 in Thumb-2 mode, though.
5671
5672 - The header was written a long time ago before Thumb-2 became
5673 widely popular (e.g. with Android). So it simply doesn't use the
5674 assembly routine if the `__thumb__' built-in macro is defined.
5675
5676 - When compiling in Thumb-2 mode, the compiler will define both
5677 `__thumb__' and `__thumb2__'.
5678
5679 By checking for `(__thumb2__ || !__thumb__)', we ensure that the
5680 assembly routine is only avoided when generating Thumb-1 code.
5681
5682 Given that this is performance-sensitive function, this improves
5683 `ftbench' as follows on a Galaxy Nexus:
5684
5685 Before (us/op) After (us/op)
5686
5687 - loading Arial.ttf glyphs at 14 ppem [1]
5688
5689 Load 34.285 33.098
5690
5691 - same operation with the light auto-hinter [2]
5692
5693 Load 31.317 29.590
5694
5695 - same operation without hinting [3]
5696
5697 Load 6.143 5.376
5698
5699 - loading Arial.ttf advances at 14 ppem [4]
5700
5701 Load_Advances (normal) 34.216 33.016
5702 Load_Advances (fast) 0.176 0.176
5703
5704 [1] ftbench -t 5 -p -s 14 -b a -f 0008 Arial.ttf
5705 [2] ftbench -t 5 -p -s 14 -b a -r 1 -f 0028 Arial.ttf
5706 [3] ftbench -t 5 -p -s 14 -b a -f 000a Arial.ttf
5707 [4] ftbench -t 5 -p -s 14 -b b -f 0008 Arial.ttf
5708
5709 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
5710 (FT_MULFIX_ASSEMBLER): Fix handling for ARMv7.
5711
Werner Lemberge12fc772013-06-28 07:57:32 +020057122013-06-28 Werner Lemberg <wl@gnu.org>
5713
5714 * docs/CHANGES: Updated.
5715
Werner Lemberg680c1d42013-06-27 17:21:59 +020057162013-06-27 Werner Lemberg <wl@gnu.org>
5717
5718 * src/winfonts/winfnt.c (FNT_Load_Glyph): Fix bitmap width guard.
5719
Werner Lembergc7cc9eb2013-06-25 07:24:02 +020057202013-06-25 Werner Lemberg <wl@gnu.org>
5721
Werner Lembergb8850fc2013-06-26 12:22:10 +02005722 [cff] Add darkening limit to `darkening-parameters'.
5723
5724 * src/cff/cffdrivr.c (cff_property_set): Add check.
5725
57262013-06-25 Werner Lemberg <wl@gnu.org>
5727
Werner Lemberg89ca1fd2013-06-25 23:28:02 +02005728 [cff] Add `darkening-parameters' property.
5729
5730 * include/freetype/ftcffdrv.h: Document it.
5731
5732 * src/cff/cffdrivr.c (cff_property_set, cff_property_get): Handle
5733 `darkening-parameters' property.
5734
5735 * src/cff/cf2font.h (CF2_FontRec): Add `darkenParams' array.
5736
5737 * src/cff/cf2font.c (cf2_computeDarkening): Add `darkenParams'
5738 argument and use it.
5739 Update all callers.
5740
5741 * src/cff/cf2ft.c (cf2_decoder_parse_charstrings): Copy
5742 `darken_params' values.
5743
5744 * src/cff/cffobjs.h (CFF_DriverRec): Add `darken_params' array.
5745
5746 * src/cff/cffobjs.c (cff_driver_init): Set default values for
5747 `darken_params'.
5748
57492013-06-25 Werner Lemberg <wl@gnu.org>
5750
Werner Lembergfad93262013-06-25 10:41:37 +02005751 [docmaker] Code shuffling.
5752
5753 * src/tools/docmaker/tohtml.py (re_url): Move regexp...
5754 * src/tools/docmaker/sources.py: ... to this file.
5755
57562013-06-25 Werner Lemberg <wl@gnu.org>
5757
Werner Lemberg8bdc4072013-06-25 10:20:53 +02005758 [docmaker] Remove unused functions.
5759
5760 * src/tools/docmaker/content.py (DocMarkup.get_start,
5761 DocBlock.get_markup_name): Removed.
5762 * src/tools/docmaker/tohtml.py (html_quote0, dump_html_code,
5763 HtmlFormatter.make_html_words): Removed.
5764
57652013-06-25 Werner Lemberg <wl@gnu.org>
5766
Werner Lembergffb8b472013-06-25 09:09:30 +02005767 * builds/freetype.mk (dll): Remove target.
5768
5769 Problem reported by Jörg Günnewig <joerg.guennewig@googlemail.com>.
5770
57712013-06-25 Werner Lemberg <wl@gnu.org>
5772
Werner Lembergc7cc9eb2013-06-25 07:24:02 +02005773 [docmaker] Recognise URLs.
5774
5775 * src/tools/docmaker/tohtml.py (re_url): New regular expression.
5776 (make_html_para): Use it.
5777
Werner Lemberg25b7da52013-06-19 10:23:36 +020057782013-06-19 Werner Lemberg <wl@gnu.org>
5779
Werner Lembergfe4f5712013-06-19 23:27:47 +02005780 * Version 2.5.0.1 released.
5781 ===========================
5782
5783
5784 Tag sources with `VER-2-5-0-1'.
5785
5786 * include/freetype/config/ftoption.h: Undefine
5787 CFF_CONFIG_OPTION_OLD_ENGINE.
5788 * devel/ftoption.h: Define CFF_CONFIG_OPTION_OLD_ENGINE.
5789
57902013-06-19 Werner Lemberg <wl@gnu.org>
5791
Werner Lemberg609f0ca2013-06-19 14:41:47 +02005792 * builds/unix/install.mk (install): Don't create `cache' directory.
5793
5794 Found by Peter Breitenlohner <peb@mppmu.mpg.de>.
5795
57962013-06-19 Werner Lemberg <wl@gnu.org>
5797
Werner Lemberg25b7da52013-06-19 10:23:36 +02005798 * Version 2.5.0 released.
5799 =========================
5800
5801
5802 Tag sources with `VER-2-5-0'.
5803
5804 * docs/VERSION.DLL: Update documentation and bump version number to
5805 2.5.0.
5806
5807 * README, Jamfile (RefDoc),
5808 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
5809 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
5810 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
5811 builds/win32/visualc/freetype.dsp,
5812 builds/win32/visualc/freetype.vcproj,
5813 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
5814 builds/win32/visualce/freetype.vcproj,
5815 builds/win32/visualce/index.html,
5816 builds/wince/vc2005-ce/freetype.vcproj,
5817 builds/wince/vc2005-ce/index.html,
5818 builds/wince/vc2008-ce/freetype.vcproj,
5819 builds/wince/vc2008-ce/index.html: s/2.4.12/2.5.0/, s/2412/250/.
5820
5821 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 5.
5822 (FREETYPE_PATCH): Set to 0.
5823
5824 * builds/unix/configure.raw (version_info): Set to 16:2:10.
5825
5826 * src/base/ftobjs.c (FT_Open_Face): Pacify compiler.
5827 * src/truetype/ttinterp.c (Ins_MSIRP, Ins_MIRP): Ditto.
5828
Werner Lembergf56691a2013-06-18 10:17:48 +020058292013-06-18 Werner Lemberg <wl@gnu.org>
5830
5831 Fix Savannah bug #39269.
5832
5833 * src/base/ftgloadr.c (FT_GlyphLoader_CheckPoints): Free memory in
5834 case of reacollocation failures.
5835
Andrew Church67cf7a82013-06-18 09:35:34 +020058362013-06-18 Andrew Church <achurch+savannah@achurch.org>
5837
5838 Fix Savannah bug #39266.
5839
5840 If memory allocations fail at certain points while opening a font,
5841 FreeType can either crash due to a NULL dereference or leak memory.
5842
5843 * include/freetype/internal/ftobjs.c (FT_Face_InternalRec,
5844 FT_LibraryRec): Make `refcount' a signed integer. If, for example,
5845 FT_Open_Face() fails in a memory allocation before the face's
5846 reference count is set to 1, a subsequent `FT_Done_Library' call
5847 would otherwise loop over `FT_Done_Face' 2^32 times before freeing
5848 the face.
5849
5850 * src/base/ftobjs.c (open_face): Initialize `stream' and friends
5851 earlier.
5852 (FT_Open_Face) <Fail>: Behave correctly if `node' is NULL.
5853 (FT_Destroy_Module) <Fail>: Check that `renderer_clazz' is valid.
5854
58552013-06-14 Werner Lemberg <wl@gnu.org>
Werner Lembergd7e34442013-06-14 18:33:39 +02005856
5857 * src/smooth/ftgrays.c One final pragma to silence 64-bit MSVC.
5858
Dave Arnoldcb23a622013-06-13 07:46:32 +020058592013-06-06 Dave Arnold <darnold@adobe.com>
5860 Werner Lemberg <wl@gnu.org>
5861
5862 [cff] Add code to Adobe's engine to handle ppem > 2000.
5863
5864 * src/cff/cffgload.c (cff_slot_load): If we get
5865 FT_Err_Glyph_Too_Big, retry unhinted and scale up later on.
5866
Andrew Church67cf7a82013-06-18 09:35:34 +020058672013-06-12 Werner Lemberg <wl@gnu.org>
Werner Lemberg25b6e602013-06-12 11:06:34 +02005868
Werner Lemberg294ce112013-06-12 23:33:11 +02005869 Another try on pragmas.
5870
5871 * include/freetype/internal/ftdebug.h: Move pragmas to...
5872 * include/freetype/internal/internal.h: ... this file since it gets
5873 included by all source files.
5874 * include/freetype/internal/ftserv.h: Remove pragma which has no
5875 effect.
5876
Dave Arnoldcb23a622013-06-13 07:46:32 +020058772013-06-12 Werner Lemberg <wl@gnu.org>
Werner Lemberg294ce112013-06-12 23:33:11 +02005878
Werner Lemberg25b6e602013-06-12 11:06:34 +02005879 * include/freetype/internal/ftdebug.h: Disable MSVC warning C4127.
5880
5881 This partially undoes commit 3f6e0e0c.
5882
Werner Lembergc06889e2013-06-12 10:58:06 +020058832013-06-12 Werner Lemberg <wl@gnu.org>
5884
5885 More compiler warning fixes.
5886
5887 */*: Use cast to `FT_Bool' (or `Bool') where appropriate.
5888
Werner Lemberg99e60d82013-06-10 01:44:37 +020058892013-06-10 Werner Lemberg <wl@gnu.org>
5890
Werner Lemberg5e094c62013-06-10 14:59:21 +02005891 [truetype] Improve handling of broken sbit advance widths.
5892
5893 * src/truetype/ttgload.c (TT_Load_Glyph): Use the glyph's (scaled)
5894 `linearHoriAdvance' if the sbit's `horiAdvance' value is zero.
5895
5896 Cf. font `Fixedsys Excelsior' v3.01 (FSEX300.ttf), glyph A, 16ppem.
5897
58982013-06-10 Werner Lemberg <wl@gnu.org>
5899
Werner Lemberga25ecfd2013-06-10 12:57:16 +02005900 [sfnt] Improve embedded bitmap tracing.
5901
5902 * src/base/ftobjs.c (FT_Request_Size): Move trace message regarding
5903 bitmap strike match to...
5904 (FT_Match_Size): This function.
5905
5906 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics,
5907 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
5908 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
5909 tt_sbit_decoder_load_image): Decorate with tracing messages.
5910
59112013-06-10 Werner Lemberg <wl@gnu.org>
5912
Werner Lemberg99e60d82013-06-10 01:44:37 +02005913 Fix Savannah bug #39160.
5914
5915 * src/truetype/ttinterp.c (Ins_SDPVTL): Set projection vector too
5916 for the degenerate case.
5917
Werner Lemberg2ba871b2013-06-09 08:20:54 +020059182013-06-09 David Turner <digit@google.com>
5919
5920 * src/cache/ftcmanag.c (FTC_Manager_Reset): Add missing cache flush.
5921
5922 This code, present since eight(!) years in the unused `CACHE'
5923 branch, has been forgotten to apply to the master branch. It's
5924 really amazing that noone has ever complained since
5925 `FTC_Manager_Reset' is pretty useless without flushing the cache.
5926
Werner Lemberg85fd84b2013-06-07 17:10:21 +020059272013-06-07 Werner Lemberg <wl@gnu.org>
5928
Werner Lemberg3f6e0e02013-06-07 18:10:40 +02005929 Add and improve pragmas for MSVC compiler.
5930
5931 * include/freetype/internal/ftdebug.h: Remove pragmas.
5932 * include/freetype/internal/ftserv.h: Use push and pop for pragmas.
5933 * include/freetype/internal/ftvalid.h: Handle warning C4324.
5934 * src/base/ftobjs.c: Use push and pop for pragmas.
5935 * src/gzip/ftgzip.c: Handle warning C4244.
5936
59372013-06-07 Werner Lemberg <wl@gnu.org>
5938
Werner Lemberg85fd84b2013-06-07 17:10:21 +02005939 [cff] s/cf2_getGlyphWidth/cf2_getGlyphOutline/.
5940
5941 * src/cff/cf2font.c, src/cff/cf2font.h, src/cff/cf2ft.c: Do it.
5942
Werner Lemberg4447b2c2013-06-06 21:28:36 +020059432013-06-06 Dave Arnold <darnold@adobe.com>
5944
5945 [cff] Add early exit feature for width-only calls.
5946
5947 This is for `FT_Get_Advance'.
5948
5949 There are 7 places where the spec says the width can be defined:
5950
5951 hstem/hstemhm
5952 vstem/vstemhm
5953 cntrmask/hintmask
5954 hmoveto
5955 vmoveto
5956 rmoveto
5957 endchar
5958
5959 * src/cff/cf2intrp.c (cf2_doStems): Exit early for width-only calls,
5960 if possible.
5961
5962 (cf2_interpT2CharString) <cf2_cmdHSTEM>, <cf2_cmdVSTEM>,
5963 <cf2_cmdVMOVETO>, <cf2_cmdENDCHAR>, <cf2_cmdHINTMASK>,
5964 <cf2_cmdRMOVETO>, <cf2_cmdHMOVETO>: Exit early for width-only calls.
5965
Werner Lembergbadf3172013-06-06 09:16:38 +020059662013-06-06 Werner Lemberg <wl@gnu.org>
5967
5968 Next round of compiler fixes.
5969
5970 * builds/win32/ftdebug.c, builds/wince/ftdebug.c (ft_debug_init):
5971 Add proper cast.
5972
5973 * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Fix
5974 cast.
5975 * include/freetype/internal/ftstream.h: Decorate stream and frame
5976 macros with `FT_Long' and `FT_ULong' as appropriate.
5977
5978 * src/base/ftrfork.c (raccess_guess_darwin_hfsplus,
5979 raccess_guess_darwin_newvfs): Use cast.
5980
5981 * src/bdf/bdflib.c (_bdf_set_default_spacing): Use cast.
5982
5983 * src/cache/ftcmanag.c (FTC_Manager_Check): Fix cast.
5984 * src/cache/ftcmanag.h (FTC_ManagerRec): Ditto.
5985
5986 * src/cff/cf2arrst.c (cf2_arrstack_setNum_Elements): Use cast.
5987 * src/cff/cf2ft.c (cf2_freeSeacComponent): Ditto.
5988 * src/cff/cffobjs.c (remove_subset_prefix, remove_style): Ditto.
5989
5990 * src/cid/cidparse.c (cid_parser_new): Use cast.
5991
5992 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Use cast.
5993
5994 * src/psaux/psobjs.c (reallocate_t1_table): Fix argument type.
5995
5996 * src/raster/ftraster.c (ft_black_reset): Use cast.
5997
5998 * src/truetype/ttgxvar.c (FT_Stream_FTell): Use cast.
5999 (ALL_POINTS): Fix cast.
6000
6001 * src/type1/t1driver.c (t1_ps_get_font_value): Add casts.
6002 * src/type1/t1parse.c (T1_Get_Private_Dict): Add cast.
6003
Dave Arnoldc3782492013-06-05 19:57:55 +020060042013-06-05 Dave Arnold <darnold@adobe.com>
6005
6006 Fix more MSVC Win32 compiler warnings.
6007
6008 * src/base/ftobjs.c: Fix typo in MS pragma.
6009
6010 * src/base/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
6011 `lineno' is only used in debug mode.
6012
6013 * src/cff/cf2ft.c (cf2_builder_moveTo): `params' is only used in
6014 debug mode.
6015
Werner Lemberg45392b72013-06-05 13:43:20 +020060162013-06-05 Werner Lemberg <wl@gnu.org>
6017
6018 Fix compiler warnings.
6019
6020 * include/freetype/internal/ftmemory.h: Decorate memory allocation
6021 macros with `FT_Long' where appropriate.
6022 Remove duplicate of FT_MEM_QRENEW_ARRAY definition.
6023
6024 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
6025 cast.
6026
6027 * src/base/ftobjs.c: Add warning disabling pragma for MSVC while
6028 including `md5.c'.
6029
6030 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdESC>: Add
6031 cast.
6032
6033 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_compound): Fix casts.
6034 (tt_sbit_decoder_load_bitmap): Beautification.
6035
6036 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Initialize
6037 variables (earlier).
6038
6039 * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Pacify compiler.
6040
6041 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Use unsigned constants
6042 where appropriate.
6043
6044 * src/type1/t1load.c (T1_Get_MM_Var): Ditto.
6045
Werner Lembergdc624ca2013-06-04 10:30:48 +020060462013-06-04 Werner Lemberg <wl@gnu.org>
6047
Werner Lembergd9634982013-06-04 20:18:57 +02006048 * src/cff/cf2font.c (cf2_getGlyphWidth): Initialize `advWidth'.
6049
6050 Problem reported by Ingmar Sittl <ingmar.sittl@elektrobit.com>.
6051
60522013-06-04 Werner Lemberg <wl@gnu.org>
6053
Werner Lembergdc624ca2013-06-04 10:30:48 +02006054 Apply fixes for cppcheck nitpicks.
6055
6056 http://cppcheck.sourceforge.net/
6057
Werner Lemberg8d8508e2013-06-04 13:09:01 +02006058 The call was (from the top-level of the FreeType tree):
6059
6060 cppcheck --force \
6061 --enable=all \
6062 -I include \
6063 -I include/freetype/ \
6064 -I include/freetype/config/ \
6065 -I include/freetype/internal/ \
6066 . &> cppcheck.log
6067
Werner Lembergdc624ca2013-06-04 10:30:48 +02006068 Note that the current version heavily chokes on FreeType, delivering
Werner Lemberg8d8508e2013-06-04 13:09:01 +02006069 many wrong results. I will report those issues to the cppcheck team
Werner Lembergdc624ca2013-06-04 10:30:48 +02006070 so that a newer version gives improved results hopefully.
6071
6072 */* Improve variable scopes.
6073 */* Remove redundant initializations which get overwritten.
6074
Werner Lemberge8ed2d62013-08-01 12:20:20 +02006075 * src/base/ftmac.c, builds/mac/ftmac.c (count_faces_scalable):
Werner Lembergdc624ca2013-06-04 10:30:48 +02006076 Remove unused variable.
6077
6078 * src/base/ftdbgmem.c (ft_mem_table_destroy): `table' can't be zero.
6079
6080 * src/gxvalid/gxvkern.c (gxv_kern_subtable_fmt1_entry_validate):
6081 Remove functionless code.
6082
6083 * src/tools/ftrandom.c (main): Fix memory leak.
6084
Werner Lemberg2429dc32013-06-03 12:41:58 +020060852013-06-03 Werner Lemberg <wl@gnu.org>
6086
6087 Add CFF_CONFIG_OPTION_OLD_ENGINE configuration option.
6088
6089 This controls whether the old FreeType CFF engine gets compiled into
6090 FreeType. It is now disabled by default.
6091
6092 * devel/ftoption.h, include/freetype/config/ftoption.h
6093 (CFF_CONFIG_OPTION_OLD_ENGINE): New macro.
6094
6095 * src/cff/cffdrivr.c (cff_property_set), src/cff/cffgload.c
6096 (CFF_Operator, cff_argument_counts, cff_builder_add_point,
6097 cff_operator_seac, cff_decoder_parse_charstrings, cff_slot_load),
6098 src/cff/cffgload.h, src/cff/cffobjs.c (cff_driver_init): Use
6099 CFF_CONFIG_OPTION_OLD_ENGINE to guard the affected code.
6100
6101 * docs/CHANGES: Updated.
6102
Werner Lembergf9cceeb2013-06-02 23:38:13 +020061032013-06-02 Werner Lemberg <wl@gnu.org>
6104
6105 Fix PNG library handling.
6106
6107 * builds/unix/configure.raw: Don't use LIBPNG_LIBS but
6108 LIBPNG_LDFLAGS.
6109
Behdad Esfahbod760d3422013-05-29 11:36:18 +020061102013-05-23 Behdad Esfahbod <behdad@google.com>
6111
6112 Add support for color embedded bitmaps (eg. color emoji).
6113
6114 A new load flag, FT_LOAD_COLOR, makes FreeType load color
6115 embedded-bitmaps, following this draft specification
6116
6117 https://color-emoji.googlecode.com/git/specification/v1.html
6118
6119 which defines two new SFNT tables, `CBDT' and `CBLC' (named and
6120 modeled after `EBDT' and `EBLC', respectively). The color bitmaps
6121 are stored in the new FT_PIXEL_MODE_BGRA format to represent BGRA
6122 pre-multiplied sRGB images. If PNG support is available, PNG color
6123 images as defined in the same proposed specification are supported
6124 also.
6125
6126 Note that color bitmaps are converted to grayscale if client didn't
6127 ask for color.
6128
6129 * builds/unix/configure.raw: Search for libpng.
6130 Add `--without-png' option.
6131
6132 * devel/ftoption.h, include/freetype/config/ftoption.h
6133 (FT_CONFIG_OPTION_USE_PNG): New macro.
6134
6135 * include/freetype/freetype.h (FT_LOAD_COLOR): New load flag.
6136
6137 * include/freetype/ftimage.h (FT_Pixel_Mode): Add
6138 `FT_PIXEL_MODE_BGRA'.
6139
6140 * include/freetype/tttags.h (TTAG_CBDT, TTAG_CBLC): New tags.
6141
6142 * src/base/ftbitmap.c (FT_Bitmap_Embolden): Updated.
6143 (ft_gray_for_premultiplied_srgb_bgra): New function.
6144 (FT_Bitmap_Convert): Handle FT_PIXEL_MODE_BGRA.
6145
6146 * src/sfnt/pngshim.c, src/sfnt/pngshim.h: New files.
6147
6148 * src/sfnt/sfnt.c: Include `pngshim.c'.
6149
6150 * src/sfnt/ttsbit.c: Include FT_BITMAP_H and `pngshim.h'
6151 (tt_face_load_eblc): Load `CBLC'.
6152 (tt_sbit_decoder_init): Load `CBDT'.
6153 (tt_sbit_decoder_alloc_bitmap): Pass load flags to select between
6154 color and grayscale bitmaps.
6155 Set `num_grays'. This is used by `ftview' to choose the blending
6156 algorithm.
6157 (tt_sbit_decoder_load_byte_aligned,
6158 tt_sbit_decoder_load_bit_aligned, tt_sbit_decoder_load_compound,
6159 tt_sbit_decoder_load_image): Pass load flag.
6160 s/write/pwrite/.
6161 Don't call `tt_sbit_decoder_alloc_bitmap'.
6162 Updated.
6163 (tt_sbit_decoder_load_png) [FT_CONFIG_OPTION_USE_PNG]: New function.
6164 (tt_sbit_decoder_load_bitmap): Pass load flag.
6165 Handle new glyph formats 17, 18, and 19.
6166 Call `tt_sbit_decoder_alloc_bitmap'.
6167 Flatten color bitmaps if necessary.
6168 (tt_face_load_sbit_image): Updated.
6169
6170 * src/sfnt/rules.mk (SFNT_DRV_SRC): Add `pngshim.c'.
6171
6172 * docs/CHANGES: Updated.
6173
Guenter41e44802013-05-24 11:38:09 +020061742013-05-24 Guenter <info@gknw.net>
6175
6176 Apply Savannah patch #8055.
6177
6178 Make `apinames' create an import file for NetWare.
6179
6180 * src/tools/apinames.c (PROGRAM_VERSION): Set to 0.2.
6181 (OutputFormat): Add `OUTPUT_NETWARE_IMP'.
6182 (names_dump): Handle it.
6183 (usage): Updated.
6184 (main): Handle new command line flag `-wN'.
6185
Behdad Esfahbod2d6e1fb2013-05-23 08:01:20 +020061862013-05-23 Behdad Esfahbod <behdad@behdad.org>
6187
6188 Compilation fix.
6189
6190 * src/truetype/ttinterp.c (TT_RunIns)
6191 [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Make it work.
6192
Infinality18f35ed2013-05-21 20:51:15 -050061932013-05-22 Infinality <infinality@infinality.net>
6194
Infinality3c783c12013-05-21 21:03:00 -05006195 [truetype] Formatting and an additional subpixel tweak.
6196
6197 * src/truetype/ttinterp.c (Ins_SHPIX): Formatting fix.
6198 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules):
6199 Revert previous modification for Verdana clones.
6200
62012013-05-22 Infinality <infinality@infinality.net>
6202
Infinality18f35ed2013-05-21 20:51:15 -05006203 [truetype] Adjust subpixel zp2 moves and tweak rules.
6204
6205 These modifications fix thin diagonal stems in some legacy fonts.
6206
6207 * src/truetype/ttinterp.c (Direct_Move_X): Remove unused macro.
6208 (Move_Zp2_Point): Don't always disable x moves for subpixel rendering.
6209 (Ins_SHP): Disable x moves here for subpixel rendering.
6210 (Ins_SHPIX): Only disable x moves in compatibility mode.
6211 Split out zp2 move reversals and reorder conditional respectively.
6212
6213 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules): Fix oversight.
6214 Only adjust Verdana clones for 17 ppem.
6215 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Courier New.
6216 (ALWAYS_SKIP_DELTAP_Rules): Found additional cases for Arial `s'.
6217
Infinality63bfa832013-05-20 07:38:21 +020062182013-05-20 Infinality <infinality@infinality.net>
6219
6220 [truetype] Simplify and improve subpixel function detection.
6221
6222 Some small enhancements have allowed the removal of many macros and
6223 the simplification of existing rules in `ttsubpix.c'.
6224
6225 * src/truetype/ttsubpix.h (SPH_TWEAK_ALLOW_X_DMOVEX,
6226 SPH_TWEAK_ALLOW_X_MOVE_ZP2,
6227 SPH_TWEAK_DELTAP_SKIP_EXAGGERATED_VALUES,
6228 SPH_TWEAK_SKIP_INLINE_DELTAS, SPH_TWEAK_MIRP_CVT_ZERO): Removed.
6229 (SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES_DELTAP): New rule macro.
6230
6231 * src/truetype/ttsubpix.c: Updated affected rules.
6232
6233 * src/truetype/ttinterp.c (Direct_Move_X): Updated.
6234 (INS_FDEF): Add additional function detection.
6235 (INS_ENDF): Set runtime flag.
6236 (Ins_CALL): Skip the call under certain conditions.
6237 Remove bad code.
6238 (Ins_LOOPCALL): Skip the call under certain conditions.
6239 Remove bad code.
6240 (Move_Zp2_Point): Updated.
6241 (Ins_SHPIX): Updated.
6242 Skip the move under some situations.
6243 (Ins_MIAP): Improve conditions.
6244 (Ins_MIRP): Updated.
6245 (Ins_DELTAP): Skip move under certain conditions.
6246 Simplify conditions.
6247 (TT_RunIns): Updated.
6248 Add code to handle new function detection.
6249 Trace messages.
6250
Werner Lembergfd664692013-05-17 17:40:27 +020062512013-05-17 Werner Lemberg <wl@gnu.org>
6252
6253 Update more FT_Err_XXX macros using FT_ERR and FT_THROW;
6254
6255 * builds/amiga/src/base/ftsystem.c, builds/mac/ftmac.c,
6256 builds/unix/ftsystem.c, builds/vms/ftsystem.c: Do it.
6257
Werner Lembergf04951a2013-05-17 13:51:07 +020062582013-05-15 Werner Lemberg <wl@gnu.org>
6259
6260 [truetype] Add `interpreter-version' property.
6261
6262 This makes the option TT_CONFIG_OPTION_SUBPIXEL_HINTING controllable
6263 at runtime.
6264
Werner Lemberg27991332013-05-17 14:00:26 +02006265 * include/freetype/ftttdrv.h: New file.
6266
6267 * include/freetype/config/ftheader.h (FT_TRUETYPE_DRIVER_H): New
6268 macro.
6269
Werner Lembergf04951a2013-05-17 13:51:07 +02006270 * src/truetype/ttdriver.c: Include FT_TRUETYPE_DRIVER_H.
6271 (tt_property_set, tt_property_get): Fill templates.
6272
6273 * src/truetype/ttobjs.h (TT_DriverRec): Add `interpreter_version'
6274 member.
6275 Remove unused `extension_component' member.
6276
6277 * src/truetype/ttgload.c: Include FT_TRUETYPE_DRIVER_H.
6278 (tt_get_metrics, TT_Hint_Glyph, TT_Process_Simple_Glyph,
6279 compute_glyph_metrics, tt_loader_init): Use `interpreter_version'.
6280
6281 * src/truetype/ttinterp.c: Include FT_TRUETYPE_DRIVER_H.
6282 (SUBPIXEL_HINTING): New macro to check `interpreter_version' flag.
6283 Update all affected functions to use it.
6284 Use TT_INTERPRETER_VERSION_XXX where appropriate.
6285
6286 * src/truetype/ttobjs.c: Include FT_TRUETYPE_DRIVER_H.
6287 (tt_driver_init): Initialize `interpreter_version'.
6288
6289 * src/truetype/ttsubpix.c: Include FT_TRUETYPE_DRIVER_H.
6290 Use TT_INTERPRETER_VERSION_XXX where appropriate.
6291
Werner Lemberg7441dd82013-05-13 09:12:46 +020062922013-05-13 Werner Lemberg <wl@gnu.org>
6293
Werner Lemberg6650be72013-05-13 10:05:29 +02006294 [truetype] Avoid empty source file.
6295
6296 * src/truetype/ttsubpix.c [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]:
6297 Provide dummy typedef.
6298
62992013-05-13 Werner Lemberg <wl@gnu.org>
6300
Werner Lemberg7441dd82013-05-13 09:12:46 +02006301 * src/cff/cf2font.c (cf2_getGlyphWidth): Fix uninitialized variable.
6302
6303 Fix suggested by Vaibhav Nagarnaik <vnagarnaik@gmail.com>.
6304
Brian Nixon8d6025c2013-05-13 09:06:42 +020063052013-05-13 Brian Nixon <bnixon@yahoo.com>
6306
6307 Fix Savannah bug #38970.
6308
6309 * src/base/ftdebug.c, builds/win32/ftdebug.c,
6310 builds/wince/ftdebug.c, builds/amiga/src/base/ftdebug.c
6311 (ft_debug_init): Don't read past the environment variable FT2_DEBUG.
6312
Werner Lembergd51ac9c2013-05-12 06:00:27 +020063132013-05-12 Werner Lemberg <wl@gnu.org>
6314
Werner Lembergcd888752013-05-12 15:08:57 +02006315 [truetype] Add framework for TrueType properties.
6316
6317 * src/truetype/ttdrivr.c: Include FT_SERVICE_PROPERTIES_H.
6318 (tt_property_set, tt_property_get): New functions, still empty.
6319 Define `tt_service_properties' service.
6320 Update `tt_services'.
6321
6322 * src/truetype/ttpic.h: Include FT_SERVICE_PROPERTIES_H.
6323 (TT_SERVICE_PROPERTIES_GET): New macro.
6324 (TTModulePIC): Add `tt_service_properties'.
6325
63262013-05-12 Werner Lemberg <wl@gnu.org>
6327
Werner Lembergb112fa42013-05-12 07:29:04 +02006328 Fix Savannah bug #38967.
6329
6330 * src/base/ftcalc.c (FT_DivFix) [FT_LONG64]: Fix cast.
6331
63322013-05-12 Werner Lemberg <wl@gnu.org>
6333
Werner Lembergcbcf33d2013-05-12 07:27:48 +02006334 Introduce unsigned 64bit type (if available).
6335
6336 * include/freetype/config/ftconfig.h: Define FT_UINT64 if available.
6337 [FT_LONG64]: Provide FT_UInt64.
6338
6339 * builds/unix/ftconfig.in: Synchronized.
6340
63412013-05-12 Werner Lemberg <wl@gnu.org>
6342
Werner Lembergd51ac9c2013-05-12 06:00:27 +02006343 Fix Savannah bug #38968.
6344
6345 * include/freetype/ftmodapi.h: Add `FT_EXPORT' to
6346 FT_Property_{Set,Get}.
6347 * src/base/ftobjs.c: Add `FT_EXPORT_DEF' to
6348 FT_Property_{Set,Get}.
6349
Werner Lembergf6aa0892013-05-10 07:58:47 +020063502013-05-10 Werner Lemberg <wl@gnu.org>
6351
Werner Lembergea2b4752013-05-10 08:04:33 +02006352 [sfnt] Clean up bitmap code.
6353
6354 * src/sfnt/ttsbit.c: Deleted.
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006355 * src/sfnt/ttsbit0.c: Renamed to `ttsbit.c'.
Werner Lembergea2b4752013-05-10 08:04:33 +02006356 * rules.mk (SFNT_DRV_H): Updated.
6357
63582013-05-10 Werner Lemberg <wl@gnu.org>
6359
Werner Lembergf6aa0892013-05-10 07:58:47 +02006360 */* [FT_CONFIG_OPTION_OLD_INTERNALS]: Remove macro and guarded code.
6361
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00006362----------------------------------------------------------------------------
6363
Werner Lembergf57fc592015-01-17 20:41:43 +01006364Copyright 2013-2015 by
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00006365David Turner, Robert Wilhelm, and Werner Lemberg.
6366
6367This file is part of the FreeType project, and may only be used, modified,
6368and distributed under the terms of the FreeType project license,
6369LICENSE.TXT. By continuing to use, modify, or distribute this file you
6370indicate that you have read the license and understand and accept it
6371fully.
6372
6373
6374Local Variables:
6375version-control: never
Werner Lemberg4e03fe72006-04-29 06:20:09 +00006376coding: utf-8
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00006377End: