blob: 130c1ee6b9e7716616484cf762b70c0be0afc2cf [file] [log] [blame]
Behdad Esfahbod8183eeb2016-08-06 23:12:55 +020012016-07-16 Behdad Esfahbod <behdad@behdad.org>
2
3 [truetype] Fix GX variation handling of composites.
4
5 * src/truetype/ttgload.c (load_truetype_glyph)
6 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Check `ARGS_ARE_XY_VALUES' flag.
7
Alexei Podtelezhnikov97718f32016-08-05 23:36:16 -040082016-08-05 Alexei Podtelezhnikov <apodtele@gmail.com>
9
10 [smooth] Minor refactoring.
11
12 * src/smooth/ftgrays.c (gray_render_scanline, gray_render_line):
13 Updated.
14
Werner Lembergfae4ec02016-07-29 06:43:32 +0200152016-07-29 Werner Lemberg <wl@gnu.org>
16
17 [sfnt, truetype] Don't abort on invalid `maxComponentDepth'.
18
19 Since 2016-05-16 we detect infinite recursion directly.
20
21 * src/sfnt/ttload.c (tt_face_load_maxp): Don't adjust
22 `maxComponentDepth'.
23 * src/truetype/ttgload.c (load_truetype_glyph): Don't abort if
24 `maxComponentDepth' is not valid. Instead, simply adjust its value
25 and emit a tracing message.
26
Werner Lembergd9c7f5a2016-07-26 20:20:27 +0200272016-07-26 Werner Lemberg <wl@gnu.org>
28
29 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Minor.
30
31 No functional change.
32
Hin-Tak Leung3a528bb2016-07-22 06:59:36 +0200332016-07-22 Hin-Tak Leung <htl10@users.sourceforge.net>
34
35 [truetype] Record the end of IDEFs.
36
37 To match the logic in FDEF. The value of the end is only used for
38 bound-checking in `Ins_JMPR', so it may not have been obvious that
39 it was not recorded. Tested (as part of Font Validator 2.0) all the
40 fonts on Fedora and did not see any change.
41
42 * src/truetype/ttinterp.c (Ins_IDEF): Updated.
43
Werner Lemberge69f34b2016-07-19 07:06:19 +0200442016-07-19 Werner Lemberg <wl@gnu.org>
45
Werner Lemberg7f631052016-07-19 21:35:58 +020046 [truetype] Sanitizer fix, second try.
47
48 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Fix boundary
49 tests and use only one slot more.
50
512016-07-19 Werner Lemberg <wl@gnu.org>
52
Werner Lemberge69f34b2016-07-19 07:06:19 +020053 [truetype] Sanitizer fix.
54
55 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Increase array
56 to fix nested loops.
57
Werner Lemberga3b70d72016-07-18 06:23:36 +0200582016-07-18 Werner Lemberg <wl@gnu.org>
59
60 [truetype] Make GETDATA work only for GX fonts.
61
62 * src/truetype/ttinterp.c (opcode_name): Updated.
63 (Ins_GETDATA): Only define for `TT_CONFIG_OPTION_GX_VAR_SUPPORT'.
64 (TT_RunIns): Updated.
65
662016-07-17 Werner Lemberg <wl@gnu.org>
Werner Lemberg32a32062016-07-16 16:39:26 +020067
Werner Lemberg8c930132016-07-17 22:40:31 +020068 [truetype] Add support for Apple's
69
70 GETDATA[], opcode 0x92
71
72 bytecode instruction. It always returns 17, and we have absolutely
73 no idea what it is good for...
74
75 * src/truetype/ttinterp.c (Pop_Push_Count, opcode_name): Updated.
76 (Ins_GETDATA): New function.
77 (TT_RunIns): Add it.
78
792016-07-16 Werner Lemberg <wl@gnu.org>
80
Werner Lemberge0843602016-07-16 18:46:28 +020081 [truetype] Add bytecode support for GX variation fonts.
82
83 This commit implements undocumented (but confirmed) stuff from
84 Apple's old bytecode engine.
85
86 GETVARIATION[], opcode 0x91
87 This opcode pushes normalized variation coordinates for all axes
88 onto the stack (in 2.14 format). Coordinate of first axis gets
89 pushed first.
90
91 GETINFO[], selector bit 3
92 If GX variation support is enabled, bit 10 of the result is set
93 to 1.
94
95 * src/truetype/ttinterp.c: Include FT_MULTIPLE_MASTERS_H.
96 (opcode_name) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Updated.
97 (Ins_GETINFO) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Handle selector
98 bit 3, checking support for variation glyph hinting.
99 (Ins_GETVARIATION) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: New function
100 to implement opcode 0x91.
101 (TT_RunIns) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Handle opcode 0x91.
102
1032016-07-16 Werner Lemberg <wl@gnu.org>
104
Werner Lemberg32a32062016-07-16 16:39:26 +0200105 [truetype] Fix GETINFO bytecode instruction.
106
107 * src/truetype/ttinterp.c (Ins_GETINFO): Fix return value for
108 stretching information.
109
Behdad Esfahbod69446dd2016-07-16 10:52:38 +02001102016-07-16 Behdad Esfahbod <behdad@behdad.org>
111
112 [truetype] Make all glyphs in `Zycon' GX font work.
113
114 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Fix boundary
115 tests.
116
Werner Lemberga3b61252016-07-16 08:16:16 +02001172016-07-16 Werner Lemberg <wl@gnu.org>
118
119 [truetype] Fix GX delta tracing.
120
121 * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Trace
122 relative point movements.
123
1242016-07-16 Behdad Esfahbod <behdad@behdad.org>
Werner Lembergf147fb22016-07-16 07:06:21 +0200125
126 [truetype] More fixes for GX.
127
128 This finally fixes the rendering of the cyclist and the lizard in
129 the `Zycon' font.
130
131 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): `first' point
132 index is always cumulative.
133
134 (tt_handle_deltas): Rename to...
135 (tt_interpolate_deltas): ... This.
136 Add new parameter for output point array.
137 Update caller.
138
139 (TT_Vary_Apply_Glyph_Deltas): Add `points_out' array; it now holds
140 the intermediate results of `tt_interpolate_deltas' that are to be
141 added to `outline->points'.
142
Werner Lembergaafff572016-07-16 06:41:39 +02001432016-07-15 Werner Lemberg <wl@gnu.org>
144
145 * src/autofit/aflatin.c (af_latin_hints_compute_segments): Thinko.
146
147 `max_pos' is always larger than `min_pos' so `FT_ABS' is not needed.
148
149 Reported by Alexei.
150
Nikolaus Waxweiler86eb43a2016-07-16 06:37:57 +02001512016-07-16 Nikolaus Waxweiler <madigens@gmail.com>
152
153 * src/truetype/ttinterp.c (Ins_MIRP): Fix copy-and-paste error.
154
155 Problem reported by Hin-Tak Leung.
156
Werner Lemberg894c0222016-07-15 10:23:11 +02001572016-07-15 Werner Lemberg <wl@gnu.org>
158
Werner Lemberg1831e6f2016-07-15 10:35:32 +0200159 [autofit] Update and improve segment and edge tracing.
160
161 * src/autofit/afhints.c (af_glyph_hints_dump_segments): Trace
162 `delta' also.
163 Don't show first point of segment as a replacement for `pos'; this
164 is (a) misleading, since the difference to `pos' can be almost
165 arbitrarily large in corner cases, and (b) it is better to have all
166 segment data in font units instead of a single value given in output
167 space coordinates.
168 Improve layout.
169 (af_glyph_hints_dump_edges): Show px->units and units->px conversion
170 values for convenience.
171 Improve layout.
172
1732016-07-15 Werner Lemberg <wl@gnu.org>
174
Werner Lemberg894c0222016-07-15 10:23:11 +0200175 [autofit] For edges, reject segments wider than 1px (#41334).
176
177 * src/autofit/afhints.h (AF_SegmentRec): New member `delta'.
178
179 * src/autofit/aflatin.c (af_latin_hints_compute_segments): Compute
180 `delta'.
181 (af_latin_hints_compute_edges): Reject segments with a delta larger
182 than 0.5px.
183
Werner Lemberg631e2182016-07-14 06:25:05 +02001842016-07-14 Werner Lemberg <wl@gnu.org>
185
Werner Lembergff655432016-07-14 15:01:55 +0200186 * include/freetype/freetype.h (FT_IS_NAMED_INSTANCE): New macro.
187
1882016-07-14 Werner Lemberg <wl@gnu.org>
189
Werner Lembergee3f36f2016-07-14 10:25:20 +0200190 [sfnt] Fix `face_index' value in `FT_Face' for named instances.
191
192 * src/sfnt/sfobjc.s (sfnt_init_face): Don't strip off higher 16bits.
193
1942016-07-14 Werner Lemberg <wl@gnu.org>
195
Werner Lemberg631e2182016-07-14 06:25:05 +0200196 * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Fix tracing.
197
Behdad Esfahbod0f9ddf22016-07-14 06:08:39 +02001982016-07-14 Behdad Esfahbod <behdad@behdad.org>
199
200 [truetype] Fix gxvar delta interpolation.
201
202 The coordinates of the base font should be used for interpolation
203 purposes, NOT the current points (i.e., the result of accumulation
204 of previous deltas).
205
206 * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Initialize
207 `points_org' before looping over all tuples.
208
Werner Lembergf9b18712016-07-12 06:18:49 +02002092016-07-12 Werner Lemberg <wl@gnu.org>
210
211 * Version 2.6.5 released.
212 =========================
213
214
215 Tag sources with `VER-2-6-5'.
216
Werner Lemberg42611032016-07-14 06:03:52 +0200217 This commit immediately follows `[mac] Fix ftexport.sym target in
218 Jamfile.' on a separate branch, which was then merged with master
219 after the release.
220
Werner Lembergf9b18712016-07-12 06:18:49 +0200221 * include/freetype/config/ftoption.h
222 (TT_CONFIG_OPTION_SUBPIXEL_HINTING): Comment out.
223
224 * docs/VERSION.TXT: Add entry for version 2.6.5.
225
226 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
227 builds/windows/vc2005/index.html,
228 builds/windows/vc2008/freetype.vcproj,
229 builds/windows/vc2008/index.html,
230 builds/windows/vc2010/freetype.vcxproj,
231 builds/windows/vc2010/index.html,
232 builds/windows/visualc/freetype.dsp,
233 builds/windows/visualc/freetype.vcproj,
234 builds/windows/visualc/index.html,
235 builds/windows/visualce/freetype.dsp,
236 builds/windows/visualce/freetype.vcproj,
237 builds/windows/visualce/index.html,
238 builds/wince/vc2005-ce/freetype.vcproj,
239 builds/wince/vc2005-ce/index.html,
240 builds/wince/vc2008-ce/freetype.vcproj,
241 builds/wince/vc2008-ce/index.html: s/2.6.4/2.6.5/, s/264/265/.
242
243 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 5.
244
245 * builds/unix/configure.raw (version_info): Set to 18:5:12.
246 * CMakeLists.txt (VERSION_PATCH): Set to 5.
247
248 * docs/CHANGES: Updated.
249
Werner Lembergc3e83b42016-07-11 05:56:26 +02002502016-07-11 Werner Lemberg <wl@gnu.org>
251
Werner Lemberg605946a2016-07-11 16:14:36 +0200252 Conditionally compile environment support.
253
254 * include/freetype/internal/ftobjs.h, src/autofit/afmodule.c,
255 src/base/ftobjs.c, src/cff/cffdrivr.c, src/truetype/ttdriver.c:
256 Decorate with `FT_CONFIG_OPTION_ENVIRONMENT_PROPERTIES' where
257 necessary.
258
2592016-07-11 Werner Lemberg <wl@gnu.org>
260
Werner Lemberg8f8ae8c2016-07-11 15:11:38 +0200261 Handle properties in `FREETYPE_PROPERTIES' environment variable.
262
263 This commit covers the most important one.
264
265 * src/autofit/afmodule.c (af_property_set): Handle `warping',
266 `darkening-parameters', and `no-stem-darkening'.
267
268 * src/cff/cffdrivr.c (cff_property_set): Handle
269 `darkening-parameters', `hinting-engine', and `no-stem-darkening'.
270
271 * src/truetype/ttdriver.c (tt_property_set): Handle
272 `interpreter-version'.
273
2742016-07-11 Werner Lemberg <wl@gnu.org>
275
Werner Lembergc3e83b42016-07-11 05:56:26 +0200276 Replace calls to `atol' with `strtol'.
277
278 We later on need strtol's `endptr' feature.
279
280 * include/freetype/config/ftstdlib.h (ft_atol): Replace with...
281 (ft_strtol): ... this.
282
283 * src/base/ftdbgmem.c (ft_mem_debug_init): Updated.
284 * src/cid/cidparse.c (cid_parser_new): Ditto.
285 * src/type42/t42drivr.c (t42_get_name_index), src/type42/t42objs.c
286 (T42_GlyphSlot_Load): Ditto.
287
Werner Lemberg84d3df72016-07-11 00:12:11 +02002882016-07-10 Werner Lemberg <wl@gnu.org>
289
290 Implement handling of `FREETYPE_PROPERTIES' environment variable.
291
292 Recognizing properties follows in another commit.
293
294 * devel/ftoption.h, include/freetype/config/ftoption.h
295 (FT_CONFIG_OPTION_ENVIRONMENT_PROPERTIES): New macro.
296
297 * include/freetype/config/ftstdlib.h (ft_getenv): New macro.
298
299 * src/base/ftinit.c (ft_set_default_properties): New function to
300 parse `FREETYPE_PROPERTIES' and calling `ft_property_string_set'.
301 (FT_Init_FreeType): Updated.
302
Werner Lembergc3beb302016-07-10 07:11:45 +02003032016-07-09 Werner Lemberg <wl@gnu.org>
304
305 Add function `ft_property_string_set'.
306
307 This is a preparation for handling an `FREETYPE_PROPERTIES'
308 environment variable to control (some) driver properties.
309
310 No change in functionality.
311
312 * src/base/ftobjs.c (ft_property_do): Add `value_is_string'
313 parameter.
314 (ft_property_string_set): New function.
315 (FT_Property_Set, FT_Property_Get): Updated.
316
317 * include/freetype/internal/ftobjs.h: Updated.
318
319 * include/freetype/internal/services/svprop.h
320 (FT_Properties_SetFunc): Add `value_is_string' parameter.
321
322 * src/autofit/afmodule.c (af_property_set), src/cff/cffdrivr.c
323 (cff_property_set), src/truetype/ttdriver.c (tt_property_set):
324 Updated, emitting an error currently if `value_is_string' is set.
325
suzuki toshiya83c877f2016-07-09 13:36:27 +09003262016-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
327
328 [mac] Fix ftexport.sym target in Jamfile.
329
330 * Jamfile: Update the directories of the header files scanned for
331 ftexport.sym. They were incorrect since the migration of the
332 header files, on 2015-06-22. Either inexisting include/cache
333 (removed on 2006-03-20) is not needed to be listed explicitly.
334 Now ftmac.h is scanned only in the case of Mac OS & Mac OS X.
335
Alexei Podtelezhnikov4a2f8f12016-07-08 00:16:07 -04003362016-07-08 Alexei Podtelezhnikov <apodtele@gmail.com>
337
338 [smooth] Sub-banding protocol revision.
339
Werner Lemberg971f10b2016-07-08 06:59:31 +0200340 Rasterization sub-banding is utilized at large sizes while using a
341 rather small fixed memory pool. Indeed it is possible to make an
Alexei Podtelezhnikov4a2f8f12016-07-08 00:16:07 -0400342 educated guess how much memory is necessary at a given size for a
Werner Lemberg971f10b2016-07-08 06:59:31 +0200343 given glyph. It turns out that, for a large majority of European
344 glyphs, you should store about 8 times more boundary pixels than
345 their height. Or, vice versa, if your memory pool can hold 800
346 pixels the band height should be 100 and you should sub-band
347 anything larger than that. Should you still run out of memory,
348 FreeType bisects the band but you have wasted some time. This is
349 what has been implemented in FreeType since the beginning.
Alexei Podtelezhnikov4a2f8f12016-07-08 00:16:07 -0400350
Werner Lemberg971f10b2016-07-08 06:59:31 +0200351 It was overlooked, however, that the top band could grow to twice
352 the default band size leading to unnecessary memory overflows there.
353 This commit fixes that. Now the bands are distributed more evenly
354 and cannot exceed the default size.
Alexei Podtelezhnikov4a2f8f12016-07-08 00:16:07 -0400355
356 Now the magic number 8 is really suitable for rather simple European
Werner Lemberg971f10b2016-07-08 06:59:31 +0200357 scripts. For complex Chinese logograms the magic number should be
358 13 but that is subject for another day.
Alexei Podtelezhnikov4a2f8f12016-07-08 00:16:07 -0400359
360 * src/smooth/ftgrays.c (gray_convert_glyph): Revise sub-banding
361 protocol.
362
suzuki toshiya783cbcd2016-07-07 18:55:37 +09003632016-07-07 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
364
365 [mac] Fix Savannah bug #48417.
366
367 Mac OS X linker throws errors when `-exported_symbol_list' input
368 file includes non-existing symbols. Reported by Ryan Schmidt.
369
370 * builds/exports.mk: Exclude ftmac.h from the headers for apinames
371 by default. Include it when ftmac.c would be compiled.
372
Werner Lemberg474682f2016-07-06 08:54:35 +02003732016-07-06 Werner Lemberg <wl@gnu.org>
374
375 * src/truetype/ttinterp.c (TInstruction_Function): Removed, unused.
376
Werner Lembergadfec0a2016-07-05 07:38:52 +02003772016-07-05 Werner Lemberg <wl@gnu.org>
378
Werner Lembergd80fe692016-07-05 15:40:19 +0200379 * Version 2.6.4 released.
380 =========================
381
382
383 Tag sources with `VER-2-6-4'.
384
385 * docs/VERSION.TXT: Update documentation and bump version number to
386 2.6.4.
387
388 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
389 builds/windows/vc2005/index.html,
390 builds/windows/vc2008/freetype.vcproj,
391 builds/windows/vc2008/index.html,
392 builds/windows/vc2010/freetype.vcxproj,
393 builds/windows/vc2010/index.html,
394 builds/windows/visualc/freetype.dsp,
395 builds/windows/visualc/freetype.vcproj,
396 builds/windows/visualc/index.html,
397 builds/windows/visualce/freetype.dsp,
398 builds/windows/visualce/freetype.vcproj,
399 builds/windows/visualce/index.html,
400 builds/wince/vc2005-ce/freetype.vcproj,
401 builds/wince/vc2005-ce/index.html,
402 builds/wince/vc2008-ce/freetype.vcproj,
403 builds/wince/vc2008-ce/index.html: s/2.6.3/2.6.4/, s/263/264/.
404
405 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 4.
406
407 * builds/unix/configure.raw (version_info): Set to 18:4:12.
408 * CMakeLists.txt (VERSION_PATCH): Set to 4.
409
410 * docs/CHANGES: Updated.
411
4122016-07-05 Werner Lemberg <wl@gnu.org>
413
Werner Lembergadfec0a2016-07-05 07:38:52 +0200414 * src/pfr/pfrsbit.c (pfr_lookup_bitmap_data): Fix compiler warning.
415
Alexei Podtelezhnikovd1876e52016-07-04 23:46:53 -04004162016-07-04 Alexei Podtelezhnikov <apodtele@gmail.com>
417
418 [smooth] Variable type revision (part 2).
419
420 * src/smooth/ftgrays.c (TArea): Restore original definition as `int'.
421 (gray_render_line) [FT_LONG64]: Updated.
422 (gray_convert_glyph): 32-bit band bisection stack should be 32 bands.
423 (gray_convert_glyph_inner): Trace successes and failures.
424
Werner Lemberg5e353f02016-07-04 14:59:22 +02004252016-07-04 Werner Lemberg <wl@gnu.org>
426
427 [autofit] Handle single-point contours as segments.
428
429 Doing so allows us to link them to edges – some fonts like
430 `NotoSansGurmukhi-Regular' have such isolated points sitting exactly
431 on other outlines.
432
433 * src/autofit/aflatin.c (af_latin_hints_compute_segments): Don't
434 ignore one-point contours but handle them specially as one-point
435 segments.
436 (af_latin_hints_compute_edges): Append one-point segments to edges
437 if possible.
438
Werner Lembergaab2b8d2016-07-02 08:37:44 +02004392016-07-02 Werner Lemberg <wl@gnu.org>
440
Werner Lemberg8b8c4402016-07-02 18:35:50 +0200441 [autofit] Remove unused structure members.
442
443 * src/autofit/afhints.h (AF_SegmentRec, AF_EdgeRec): Remove
444 `num_linked'.
445
446 * src/autofit/afcjk.c (af_cjk_hints_link_segments): Updated.
447
4482016-07-02 Werner Lemberg <wl@gnu.org>
449
Werner Lembergaab2b8d2016-07-02 08:37:44 +0200450 [autofit] Update to Unicode 9.0.0.
451
452 * src/autofit/afranges.c (af_arab_nonbase_uniranges,
453 af_cyrl_uniranges): Add new data.
454
Alexei Podtelezhnikov597c6952016-07-01 23:27:41 -04004552016-07-01 Alexei Podtelezhnikov <apodtele@gmail.com>
456
457 [smooth] Variable type revision (part 1).
458
459 This patch restores original `TCoord' definition as `int' so that the
460 rendering pool is used more efficiently on LP64 platforms (unix).
461
462 * src/smooth/ftgrays.c (gray_TWorker, TCell, gray_TBand): Switch some
463 fields to `TCoord'.
464 (gray_find_cell, gray_render_scanline, gray_render_line, gray_hline,
465 gray_sweep, gray_convert_glyph): Updated.
466
Alexei Podtelezhnikovef0a3e72016-06-28 22:56:22 -04004672016-06-28 Alexei Podtelezhnikov <apodtele@gmail.com>
468
469 [smooth] Minor clean-ups.
470
471 * src/smooth/ftgrays.c (gray_TWorker): Remove redundant `ycount'.
472 (gray_sweep, gray_convert_glyph, gray_dump_cells): Updated.
473
4742016-06-27 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov999bcee2016-06-26 08:27:29 +0200475
Alexei Podtelezhnikovc9cf3592016-06-28 00:30:58 -0400476 [smooth] Minor clean-ups.
477
478 * src/smooth/ftgrays.c (gray_convert_glyph): Do not use volatile
479 qualifier.
480 (gray_raster_render): Move span initializations from here.
481 (gray_sweep): ... to here and remove unused `target' argument.
482
4832016-06-26 Alexei Podtelezhnikov <apodtele@gmail.com>
484
Alexei Podtelezhnikov999bcee2016-06-26 08:27:29 +0200485 [pcf] Fix handling of very large fonts (#47708).
486
487 * src/pcf/pcfread.c (pcf_get_encodings): Make `encodingOffset' an
488 unsigned short.
489 Only reject `0xFFFF' as an invalid encoding offset.
490
4912016-06-25 Werner Lemberg <wl@gnu.org>
Werner Lemberg8ba407a2016-06-25 18:09:22 +0200492
493 [truetype] Really fix deallocation in case of error (#47726).
494
495 * src/truetype/ttgload.c (load_truetype_glyph): Thinko; initialize
496 `outline.points' also.
497
Alexei Podtelezhnikov25e82bc2016-06-23 23:17:39 -04004982016-06-23 Alexei Podtelezhnikov <apodtele@gmail.com>
499
500 [smooth] Consolidate memory management.
501
502 * src/smooth/ftgrays.c (gray_init_cells): Remove function.
503 (gray_TWorker): Remove fields that become local variables.
504 (gray_raster_render): Move rendering buffer declaration from here.
505 (gray_convert_glyph): ... to here and update accordingly.
506
Alexei Podtelezhnikove2233482016-06-22 23:14:26 -04005072016-06-22 Alexei Podtelezhnikov <apodtele@gmail.com>
508
509 [smooth] Consolidate boundary checks.
510
511 Removing the checks from `gray_hline' shaves 1% off rendering speed.
512
513 * src/smooth/ftgrays.c [STANDALONE_]: Duplicate `FT_MIN' and `FT_MAX'.
514 (gray_TWorker): No need to store `clip_box'.
515 (gray_hline): Remove unnecessary boundary checks.
516 (gray_convert_glyph): Move boundary checks from here.
517 (gray_raster_render): ... to here and consolidate.
518
Alexei Podtelezhnikov78e8fc02016-06-22 00:04:08 -04005192016-06-21 Alexei Podtelezhnikov <apodtele@gmail.com>
520
521 [smooth] Use `FT_Outline_Get_CBox'.
522
523 * src/smooth/ftgrays.c [STANDALONE_]: Duplicate `FT_Outline_Get_CBox'.
524 (gray_compute_cbox): Remove this function.
525 (gray_convert_glyph): Update to use `FT_Outline_Get_CBox'.
526
Werner Lemberg20c6ef42016-06-21 11:39:34 +02005272016-06-20 Werner Lemberg <wl@gnu.org>
528
529 [smooth] Remove compiler warnings.
530
531 * src/smooth/ftgrays.c (gray_convert_glyph): Fix reports from clang.
532
Alexei Podtelezhnikov3c64af92016-06-20 00:01:55 -04005332016-06-20 Alexei Podtelezhnikov <apodtele@gmail.com>
534
535 [smooth] Sanitize memory managenent.
536
537 * src/smooth/ftgrays.c (gray_convert_glyph): Cleaned up.
538
Alexei Podtelezhnikov74fd2512016-06-18 22:31:26 -04005392016-06-18 Alexei Podtelezhnikov <apodtele@gmail.com>
540
541 [smooth] Remove `band_shoot' that never worked.
542
543 * src/smooth/ftgrays.c (gray_TWorker): Remove `band_shoot'.
544 (gray_convert_glyph): Updated.
545
Alexei Podtelezhnikov72a06532016-06-17 23:10:22 -04005462016-06-17 Alexei Podtelezhnikov <apodtele@gmail.com>
547
548 [raster, smooth] Handle FT_RENDER_POOL_SIZE better.
549
550 * src/raster/ftraster.c (FT_MAX_BLACK_POOL): New macro.
551 (ft_black_render): Updated.
552 * src/smooth/ftgrays.c (FT_MAX_GRAY_POOL): New macro.
553 (gray_raster_render): Updated.
554
Werner Lemberg1e36c2e2016-06-16 06:17:54 +02005552016-06-16 Werner Lemberg <wl@gnu.org>
556
557 * src/base/md5.c: Updated to recent version.
558
Alexei Podtelezhnikov32accef2016-06-14 23:38:17 -04005592016-06-14 Alexei Podtelezhnikov <apodtele@gmail.com>
560
561 * src/smooth/ftgrays.c (gray_hline): Optimize if-condition.
562
Werner Lemberg05a55a52016-06-13 12:16:45 +02005632016-06-13 Werner Lemberg <wl@gnu.org>
564
565 [autofit] Add support for Cherokee script.
566
567 * src/autofit/afblue.dat: Add blue zone data for Cherokee.
568
569 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
570
571 * src/autofit/afscript.h: Add Cherokee standard characters.
572
573 * src/autofit/afranges.c: Add Cherokee data.
574
575 * src/autofit/afstyles.h: Add Cherokee data.
576
David Capellof40d7d22016-06-09 10:55:52 +02005772016-06-09 David Capello <davidcapello@gmail.com>
578
579 [cmake] Avoid modifying `ftconfig.h' and `ftoption.h' files.
580
581 * CMakeLists.txt: Each time cmake is run those files are
582 modified and the whole FreeType library is recompiled. With this
583 change we change the files only if there are real modifications, so
584 we can avoid recompilations.
585
Werner Lembergb6b26f42016-06-09 06:53:48 +02005862016-06-09 Werner Lemberg <wl@gnu.org>
587
588 [bdf] Check number of properties (#48166).
589
590 * src/bdf/bdflib.c (_bdf_parse_start): Implement.
591
Alexei Podtelezhnikov9cf232e2016-06-08 23:19:41 -04005922016-06-08 Alexei Podtelezhnikov <apodtele@gmail.com>
593
Alexei Podtelezhnikov77180c72016-06-08 23:31:28 -0400594 [smooth] Re-enable new line renderer on 64-bit archs.
595
Alexei Podtelezhnikov32accef2016-06-14 23:38:17 -0400596 * src/smooth/ftgrays.c (gray_render_line): Conditionally re-enable new
Alexei Podtelezhnikov77180c72016-06-08 23:31:28 -0400597 implementation, where it is safe from overflows.
598
5992016-06-08 Alexei Podtelezhnikov <apodtele@gmail.com>
600
Alexei Podtelezhnikov9cf232e2016-06-08 23:19:41 -0400601 [smooth] Minor clean-ups.
602
603 * src/smooth/ftgrays.c (gray_dump_cells): Move out of the way.
604 (gray_render_span): Remove spurious casts and streamline.
605
Werner Lemberg15eab362016-06-07 10:36:27 +02006062016-06-07 Werner Lemberg <wl@gnu.org>
607
Werner Lemberg223d0022016-06-07 13:52:14 +0200608 [autofit] Add support for Ethiopic script.
609
610 * src/autofit/afblue.dat: Add blue zone data for Ethiopic.
611
612 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
613
614 * src/autofit/afscript.h: Add Ethiopic standard characters.
615
616 * src/autofit/afranges.c: Add Ethiopic data.
617
618 * src/autofit/afstyles.h: Add Ethiopic data.
619
6202016-06-07 Werner Lemberg <wl@gnu.org>
621
Werner Lemberg15eab362016-06-07 10:36:27 +0200622 [autofit] Fix compilation with VS2016 (#48126).
623
624 This compiler doesn't recognize the end-of-comment sequence `*/' if
625 it immediately follows non-ASCII characters.
626
627 * src/autofit/afscript.h: Ensure whitespace before `*/'.
628
Werner Lemberg5485a342016-06-04 06:57:32 +02006292016-06-04 Werner Lemberg <wl@gnu.org>
630
Werner Lemberg969960c2016-06-04 07:02:46 +0200631 Fix a test for named instances (#48122).
Werner Lemberg5485a342016-06-04 06:57:32 +0200632
Werner Lemberg969960c2016-06-04 07:02:46 +0200633 This was missed while giving negative face indices an extended
634 meaning.
635
636 * src/base/ftobjs.c (Mac_Read_sfnt_Resource): Implement.
Werner Lemberg5485a342016-06-04 06:57:32 +0200637
6382016-05-31 Nikolaus Waxweiler <madigens@gmail.com>
Nikolaus Waxweilerb4598822016-05-31 08:39:52 +0200639
640 [truetype] Let SHPIX move points in the twilight zone in v40.
641
642 * src/truetype/ttinterp.c (Ins_SHPIX): Allow SHPIX to move points in
643 the twilight zone. Otherwise, treat SHPIX the same as DELTAP.
644 Unbreaks various fonts such as older versions of Rokkitt and DTL
645 Argo T Light that would glitch severly after calling ALIGNRP after a
646 blocked SHPIX.
647
Werner Lembergd28eac22016-05-30 00:23:59 +02006482016-05-30 Werner Lemberg <wl@gnu.org>
649
650 [type42] Support `CharStrings' entry format as created by LilyPond.
651
652 * src/type42/t42parse.c (t42_parse_charstrings): Handle entries
653 having the format
654
655 (foo) cvn 12345 def
656
Werner Lemberg46d36902016-05-28 19:38:43 +02006572016-05-28 Werner Lemberg <wl@gnu.org>
658
659 * src/autofit/afranges.c: Remove `UL' postfix from hex numbers.
660
661 Suggested by Alexei. `UL' is only needed for 16bit compilers, but
662 it seems noone is using this anymore (and we no longer test whether
663 FreeType compiles in such an environment). Otherwise, it is easy to
664 add the postfix to the `AF_UNICODE_RANGE' macro.
665
Alexei Podtelezhnikove9f95092016-05-26 23:46:38 -04006662016-05-26 Alexei Podtelezhnikov <apodtele@gmail.com>
667
668 [smooth] Shrink bisection stack.
669
670 The convergence of Bézier flatteners is fast with the deviation
671 from straight line being assymptotically cut 4-fold on each bisection.
672 This justifies smaller bisection stack size.
673
674 * src/smooth/ftgrays.c (gray_TWorker): Remove common `bez_stack'.
675 (gray_render_conic): Create and use conic `bez_stack'. Move back the
676 band analysis from...
677 (gray_conic_to): ... here.
678 (gray_render_cubic): Create and use cubic `bez_stack'. Move back the
679 band analysis from...
680 (gray_cubic_to): ... here.
681 (gray_move_to): Updated.
682
Werner Lemberge97918c2016-05-25 07:13:29 +02006832016-05-25 Werner Lemberg <wl@gnu.org>
684
685 [autofit] Fixes for Armenian and Gujarati ranges.
686
687 * src/autofit/afranges.c (af_armn_uniranges): Corrected.
688 (af_guru_nonbase_uniranges): Make U+0A3E a base character.
689
Werner Lemberga74f40f2016-05-24 18:27:18 +02006902016-05-24 Werner Lemberg <wl@gnu.org>
691
692 [autofit] Add support for Armenian script.
693
694 * src/autofit/afblue.dat: Add blue zone data for Armenian.
695
696 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
697
698 * src/autofit/afscript.h: Add Armenian standard characters.
699
700 * src/autofit/afranges.c: Add Armenian data.
701
702 * src/autofit/afstyles.h: Add Armenian data.
703
Werner Lemberg771d3c82016-05-23 06:49:38 +02007042016-05-23 Werner Lemberg <wl@gnu.org>
705
706 * builds/unix/unix-cc.in (LINK_LIBRARY): Use `-export-symbols'.
707
708 This was commented about 10 years ago – I think the reason then to
709 disable libtool's `-export-symbols' option was to give some badly
710 programmed applications access to internal FreeType functions.
711
712 I believe that we should no longer take care of such programs; the
713 number of symbols exported should be rather restricted as much as
714 possible.
715
Werner Lemberg9d179e32016-05-22 08:38:41 +02007162016-05-22 Werner Lemberg <wl@gnu.org>
717
718 [autofit] Add blue-zone support for Gurmukhi script.
719
720 This essentially moves the Gurmukhi script from the `Indic' hinter to
721 the `Latin' hinter.
722
723 * src/autofit/afblue.dat: Add blue zone data for Gurmukhi.
724
725 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
726
727 * src/autofit/afscript.h: Add Gurmukhi standard characters and move
728 data out of AF_CONFIG_OPTION_INDIC block.
729
730 * src/autofit/afranges.c: Move Gurmukhi data out of
731 AF_CONFIG_OPTION_INDIC block.
732
733 * src/autofit/afstyles.h: Update Gurmukhi data; in particular, use
734 AF_WRITING_SYSTEM_LATIN.
735
Werner Lemberg6e80a092016-05-21 10:58:40 +02007362016-05-21 Werner Lemberg <wl@gnu.org>
737
Werner Lembergd5835612016-05-21 11:20:42 +0200738 Minor clang++ fixes.
739
740 * src/base/ftobjs.c (FT_Add_Module), src/psaux/psobjs.c
741 (ps_parser_load_field), src/type1/t1load.c (parse_subrs): Add
742 initializer.
743
744 * src/cache/ftccache.h (FTC_CACHE_TRYLOOP_END): Avoid implicit
745 conversion from NULL to boolean.
746
7472016-05-21 Werner Lemberg <wl@gnu.org>
748
Werner Lemberg6e80a092016-05-21 10:58:40 +0200749 Work around a bug of the C 8.0.0.1 compiler on AIX 5.3 (#47955).
750
751 * include/freetype/internal/ftmemory.h (cplusplus_typeof): Use
752 braces for `extern "C++"'.
753
Nikolaus Waxweiler59615732016-05-18 06:57:59 +02007542016-05-17 Nikolaus Waxweiler <madigens@gmail.com>
755
Nikolaus Waxweiler01de37e2016-05-18 07:07:44 +0200756 [truetype] Make TT_LOADER_SET_PP support subpixel hinting [3/3].
757
758 * src/truetype/ttgload.c (TT_LOADER_SET_PP): Replace macro with...
759 (tt_loader_set_pp): ... this new function.
760 Update all callers.
761
7622016-05-17 Nikolaus Waxweiler <madigens@gmail.com>
763
Nikolaus Waxweilered1d8982016-05-18 06:58:44 +0200764 [truetype] New implementation of v38 bytecode interpreter [2/3].
765
766 This patch actually modifies the bytecode interpreter.
767
768 See added comments in `ttinterp.h' for more information on this and
769 the following commit in the series.
770
771 * src/truetype/ttinterp.c (SUBPIXEL_HINTING): Replaced by...
772 (NO_SUBPIXEL_HINTING, SUBPIXEL_HINTING_INFINALITY,
773 SUBPIXEL_HINTING_MINIMAL): ...new macros.
774 (Direct_Move, Direct_Move_X, Direct_Move_Y): Handle backwards
775 compatibility.
776 Updated.
777 (Ins_RS, Ins_FDEF, Ins_ENDF, Ins_CALL, Ins_LOOPCALL, Ins_MD):
778 Updated.
779 (Ins_INSTCTRL): Handle native ClearType mode flag.
780 Updated.
781 (Ins_FLIPPT, Ins_FLIPRGON, Ins_FLIPRGOFF): Handle backwards
782 compatibility.
783 (Move_Zp2_Point): Ditto.
784 (Ins_SHP): Updated.
785 (Ins_SHPIX): Handle backwards compatibility.
786 Updated.
787 (Ins_MSIRP, Ins_MDAP, Ins_MIAP, Ins_MDRP, Ins_MIRP): Updated.
788 (Ins_ALIGNRP): Updated.
789 (Ins_IUP, Ins_DELTAP): Handle backwards compatibility.
790 Updated.
791 (Ins_GETINFO): Handle v38 flags.
792 Updated.
793 (TT_RunIns): Handle backwards compatibility mode.
794 Updated.
795
7962016-05-17 Nikolaus Waxweiler <madigens@gmail.com>
797
Nikolaus Waxweiler59615732016-05-18 06:57:59 +0200798 [truetype] New implementation of v38 bytecode interpreter [1/3].
799
800 This patch prepares data structures and the like.
801
802 See added comments in `ttinterp.h' for more information on this and
803 the following commits in the series.
804
805 * devel/ftoption.h, include/freetype/config/ftoption.h
806 (TT_CONFIG_OPTION_SUBPIXEL_HINTING): Assign values to differentiate
807 between subpixel versions.
808 (TT_SUPPORT_SUBPIXEL_HINTING_INFINALITY,
809 TT_SUPPORT_SUBPIXEL_HINTING_MINIMAL): New macros.
810
811 * include/freetype/ftttdrv.h (TT_INTERPRETER_VERSION_40): New macro.
812
813 * include/freetype/internal/tttypes.h (TT_FaceRec): Updated.
814
815 * src/truetype/ttinterp.h (TT_ExecContextRec): Define new fields
816 `subpixel_hinting_lean', `vertical_lcd_lean',
817 `backwards_compatibility', `iupx_called', iupy_called', and
818 `grayscale_cleartype' for new hinting mode.
819
820 * src/truetype/ttdriver.c (tt_property_set): Handle v38 and v40
821 interpreters conditionally.
822
823 * src/truetype/ttgload.c (TT_Hint_Glyph): Save phantom points unless
824 in v38 backwards compatibility mode.
825 Updated.
826 (compute_glyph_metrics): Add v38 backwards compatibility mode
827 constraint for adjusting advance widths.
828 Updated.
829 (tt_loader_init): Handle new flags `subpixel_hinting_lean',
830 `grayscale_cleartype', and `vertical_lcd_lean'.
831 Updated.
832 (tt_get_metrics, TT_Process_Simple_Glyph, TT_LOADER_SET_PP):
833 Updated.
834
835 * src/truetype/ttobjs.c (tt_driver_init): Conditionally set
836 default interpreter version number.
837
838 * src/truetype/ttsubpix.c, src/truetype/ttsubpix.h: Updated.
839
Werner Lemberg119e8e42016-05-17 19:54:09 +02008402016-05-17 Werner Lemberg <wl@gnu.org>
841
842 [cff] Fix matrix scaling (#47848).
843
844 * include/freetype/config/ftstdlib.h (FT_LONG_MIN): New macro.
845
846 * src/cff/cffparse.c (cff_parse_font_matrix): Use largest scaling
847 value of all matrix coefficients to scale matrix.
848
849 * src/cff/cffobjs.c (cff_face_init): Use `matrix->yx' member for
850 matrix normalization if `matrix->yy' is zero.
851
Werner Lemberg09f0e0f2016-05-16 19:44:19 +02008522016-05-16 Werner Lemberg <wl@gnu.org>
853
Werner Lembergbebac3c2016-05-16 20:16:35 +0200854 [base] Reject invalid sfnt Mac resource (#47891).
855
856 * src/base/ftobjs.c (open_face_PS_from_sfnt_stream): Check validity
857 of `CID ' and `TYPE1' table offset and length.
858
8592016-05-16 Werner Lemberg <wl@gnu.org>
860
Werner Lemberg09f0e0f2016-05-16 19:44:19 +0200861 [cid] Fix scanning for `StartData' and `/sfnts' (#47892).
862
863 * src/cid/cidparse.c (STARTDATA, STARTDATA_LEN, SFNTS, SFNTS_LEN):
864 New macros.
865 (cid_parser_new): Fix and document algorithm.
866
suzuki toshiyaa7d8bdb2016-05-16 21:54:32 +09008672016-05-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
868
869 [truetype] Improve the recursive reference detector.
870
871 The previous fix for #46372 misunderstood a composite glyph referring
872 same component twice as a recursive reference. See the discussion
873
Werner Lemberg533887a2016-05-16 20:38:41 +0200874 http://lists.gnu.org/archive/html/freetype/2016-05/msg00000.html
suzuki toshiyaa7d8bdb2016-05-16 21:54:32 +0900875
876 Thanks to Khaled Hosny for finding this issue.
877
878 * src/truetype/ttgload.c (ft_list_get_node_at): A function to get
Werner Lemberg533887a2016-05-16 20:38:41 +0200879 the i-th node from FT_List.
880 (load_truetype_glyph): In the traversal scan of the reference tree
881 in the composite glyph, we clear the nodes filled by previous
882 sibling chain.
suzuki toshiyaa7d8bdb2016-05-16 21:54:32 +0900883
Werner Lemberg7ae9b992016-05-07 16:24:03 +02008842016-05-07 Werner Lemberg <wl@gnu.org>
885
886 [cache] Allow value 0 for face ID.
887
888 We never dereference `face_id', and some implementations might use a
889 running number instead of a pointer. Additionally, disallowing
890 value zero was undocumented.
891
892 * src/cache/ftccmap.c (FTC_CMapCache_Lookup), src/cache/ftcmanag.c
893 (FTC_Manager_LookupFace, FTC_Manager_RemoveFaceID): Remove test for
894 `face_id'.
895
Alexei Podtelezhnikov6e880872016-05-05 23:41:03 -04008962016-05-05 Alexei Podtelezhnikov <apodtele@gmail.com>
897
898 [smooth] More efficient accounting of conic splits and draws.
899
900 A single decrement counter of segments to draw, instead of an array,
901 contains all the information necessary to decide when to split and
902 when to draw a conic segment. The number of splits before each draw is
903 equal to the number of trailing zeros in the counter.
904
905 * src/smooth/ftgrays.c (gray_TWorker): Remove `lev_stack'.
906 (gray_render_conic): Updated to use decrement counter of segments.
907
Werner Lemberg0b3cb8a2016-05-05 12:28:48 +02009082016-05-05 Werner Lemberg <wl@gnu.org>
909
910 [cff, truetype] Fix logic for `FT_Property_Set'.
911
912 Otherwise some properties could be set to arbitrary values, which is
913 harmless, but querying could give wrong positive results.
914
915 * src/cff/cffdrivr.c (cff_property_set) [hinting-engine],
916 * src/truetype/ttdriver.c (tt_property_set) [interpreter-version]:
917 Only allow defined values.
918
Werner Lemberg22167622016-04-25 21:18:24 +02009192016-04-25 Werner Lemberg <wl@gnu.org>
920
921 [autofit] Add blue-zone support for Gujarati script.
922
923 This essentially moves the Gujarati script from the `Indic' hinter to
924 the `Latin' hinter.
925
926 * src/autofit/afblue.dat: Add blue zone data for Gujarati.
927
928 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
929
930 * src/autofit/afscript.h: Add Gujarati standard characters and move
931 data out of AF_CONFIG_OPTION_INDIC block.
932
933 * src/autofit/afranges.c: Move Gujarati data out of
934 AF_CONFIG_OPTION_INDIC block.
935
936 * src/autofit/afstyles.h: Update Gujarati data; in particular, use
937 AF_WRITING_SYSTEM_LATIN.
938
Werner Lemberg432e00d2016-04-24 08:14:07 +02009392016-04-24 Werner Lemberg <wl@gnu.org>
940
Werner Lembergd9fb2172016-04-24 15:27:32 +0200941 Minor.
942
943 * include/freetype/freetype.h (FT_HAS_*, FT_IS_*): Protect macro
944 argument with parentheses.
945
9462016-04-24 Werner Lemberg <wl@gnu.org>
947
Werner Lemberg432e00d2016-04-24 08:14:07 +0200948 [truetype] Fix deallocation in case of error (#47726).
949
950 * src/truetype/ttgload.c (load_truetype_glyph): Initialize fields in
951 `outline' that are going to be deallocated in case of error.
952
Werner Lemberg80afef82016-04-23 21:34:15 +02009532016-04-23 Werner Lemberg <wl@gnu.org>
954
955 [autofit] Improve Georgian blue zone characters.
956
957 Suggested by Akaki Razmadze <razmadzekoko@gmail.com>.
958
959 * src/autofit/afblue.dat (AF_BLUE_STRING_GEORGIAN_MKHEDRULI_BOTTOM):
960 Updated.
961
962 * src/autofit/afblue.c: Regenerated.
963
David Capello9224f052016-04-16 10:24:24 +02009642016-04-16 David Capello <davidcapello@gmail.com>
965
966 [cmake] Honor SKIP_INSTALL_* settings (as used in zlib).
967
968 As FreeType depends on zlib, if we don't install zlib (e.g., because
969 we defined SKIP_INSTALL_ALL), FreeType cannot be installed, too
970 (cmake triggers an error saying that FreeType cannot be installed
971 because zlib target isn't in the export set).
972
973 * CMakeLists.txt: Honor `SKIP_INSTALL_HEADERS',
974 `SKIP_INSTALL_LIBRARIES', and `SKIP_INSTALL_ALL' settings.
975
Behdad Esfahbod99eff672016-04-16 07:32:23 +02009762016-04-16 Behdad Esfahbod <behdad@behdad.org>
977
978 [truetype] Another fix for non-intermediate GX tuples.
979
980 * src/truetype/ttgxvar.c (ft_var_apply_tuple): Add some missing
981 cases.
982
Alexei Podtelezhnikov213f0ca2016-04-13 00:19:54 -04009832016-04-12 Alexei Podtelezhnikov <apodtele@gmail.com>
984
985 Remove forgotten macro.
986
987 * include/freetype/internal/internal.h
988 [FT_INTERNAL_POSTSCRIPT_GLOBALS_H]: Remove.
989
Werner Lembergc8c7ad72016-04-09 08:24:00 +02009902016-04-09 Werner Lemberg <wl@gnu.org>
991
992 [autofit] Add support for Georgian scripts.
993
994 Georgian is problematic, since `uppercase' forms of Mkhedruli
995 (called Mtavruli) are not yet defined in Unicode, which means that
996 proper blue zones can't be defined. However, there is already a
997 proposal submitted to Unicode; see
998
999 http://www.unicode.org/L2/L2016/16034-n4707-georgian.pdf
1000
1001 Additionally, due to historical reasons, Unicode treats Khutsuri as
1002 the same script as Mkhedruli, and so does OpenType. However, since
1003 the two scripts have completely different shapes it can happen that
1004 blue zones differ considerably. The tag `geok' used here (derived
1005 from ISO 15924) to differentiate the two scripts is not an OpenType
1006 tag in use. If we now have a font that contains both glyphs for
1007 Mkhedruli and Khutsuri, and it uses OpenType features for both also,
1008 HarfBuzz unavoidably treats all glyphs as `geor'. As a consequence,
1009 blue zones for `geok' are not used for glyphs involved in the
1010 OpenType features.
1011
1012 An issue not yet resolved is which OpenType feature should be used
1013 to access Mtavruli glyph shapes; right now, FreeType doesn't set up
1014 support for them, but it is easy to add them later on as soon as
1015 more information is available.
1016
1017 * src/autofit/afblue.dat: Add blue zone data for Georgian.
1018
1019 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
1020
1021 * src/autofit/afscript.h: Add Georgian standard characters.
1022
1023 * src/autofit/afranges.c: Add Georgian data.
1024
1025 * src/autofit/afstyles.h: Add Georgian data.
1026
Werner Lembergbf8f1002016-04-05 11:43:58 +020010272016-04-05 Werner Lemberg <wl@gnu.org>
1028
1029 [autofit] Provide dummy blue zone for pseudo script `none'.
1030
1031 Even if the dummy hinter is used as the handler for `none' (which
1032 doesn't use blue zones), it is more consistent than the old value
1033 (which was 0), pointing to Arabic...
1034
1035 * src/autofit/afblue.dat: Add `AF_BLUE_STRINGSET_NONE'.
1036 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
1037
1038 * src/autofit/afstyles.h (none_dflt): Use AF_BLUE_STRINGSET_NONE.
1039
Werner Lembergccd771c2016-03-30 08:44:46 +020010402016-03-30 Werner Lemberg <wl@gnu.org>
1041
Werner Lembergfb550bf2016-03-30 18:55:27 +02001042 * src/pfr/pfrload.c (pfr_aux_name_load): Thinko (#47567).
1043
10442016-03-30 Werner Lemberg <wl@gnu.org>
1045
Werner Lembergaff6ebb2016-03-30 09:11:02 +02001046 * src/pfr/pfrload.c (pfr_log_font_count): Better font size estimate.
1047
10482016-03-30 Werner Lemberg <wl@gnu.org>
1049
Werner Lembergccd771c2016-03-30 08:44:46 +02001050 * src/pfr/pfrload.c (pfr_aux_name_load): Fix memory leak (#47567).
1051
Werner Lemberg31dc8f92016-03-29 08:37:07 +020010522016-03-29 Werner Lemberg <wl@gnu.org>
1053
Alexei Podtelezhnikovc6d99a42016-04-08 00:05:50 -04001054 * src/base/ftadvanc.c (FT_Get_Advances): Fix invalid left shift.
Werner Lembergff827472016-03-29 09:19:22 +02001055
10562016-03-29 Werner Lemberg <wl@gnu.org>
1057
Werner Lemberg351fc4b2016-03-29 09:13:13 +02001058 [pfr] Fix binary search (#47514).
1059
1060 * src/pfr/pfrsbit.c (pfr_lookup_bitmap_data): Handle border
1061 conditions correctly.
1062
10632016-03-29 Werner Lemberg <wl@gnu.org>
1064
Werner Lemberg2a03e5d2016-03-29 08:56:03 +02001065 [pfr] Minor.
1066
1067 * src/pfr/pfrsbit.c (pfr_lookup_bitmap_data): Replace `left',
1068 `right', and `middle' with `min', `max', and `mid' as used in other
1069 FreeType binary search code.
1070 (pfr_load_bitmap_metrics): Fix invalid left shift.
1071
10722016-03-29 Werner Lemberg <wl@gnu.org>
1073
Werner Lemberg31dc8f92016-03-29 08:37:07 +02001074 * src/pfr/pfrtypes.h: Replace all enums with macros.
1075
1076 We need `~FOO' to unset bits, and only with unsigned values (which
1077 `enum' isn't normally) this works cleanly.
1078
Werner Lembergb069a592016-03-26 08:00:07 +010010792016-03-26 Werner Lemberg <wl@gnu.org>
1080
1081 [pfr] Robustify bitmap strike handling (#47514).
1082
1083 We did a binary search for a charcode without ensuring that the
1084 searched data is ordered. Validating the order is now done lazily,
1085 this is, the first access to a bitmap glyph triggers the order check
1086 in the corresponding bitmap strike.
1087
1088 * src/pfr/pfrtypes.h (PFR_BitmapFlags): New values
1089 `PFR_BITMAP_VALID_CHARCODES' and `PFR_BITMAP_CHARCODES_VALIDATED'.
1090
1091 * src/pfr/pfrsbit.c (pfr_lookup_bitmap_data): Make `flags' argument
1092 a pointer. Handle new PFR_BITMAP_XXX flags.
1093 (pfr_slot_load_bitmap): Updated.
1094
10952016-03-26 Werner Lemberg <wl@gnu.org>
Werner Lemberg59828f72016-03-25 08:47:14 +01001096
Werner Lemberg0003cb92016-03-26 07:34:30 +01001097 [pfr] Fix handling of compound glyphs.
1098
1099 Extra items are indicated with different bit positions.
1100
1101 * src/pfr/pfrtypes.h (PFR_GlyphFlags): Replace
1102 `PFR_GLYPH_EXTRA_ITEMS' with `PFR_GLYPH_SIMPLE_EXTRA_ITEMS' and
1103 `PFR_GLYPH_COMPOUND_EXTRA_ITEMS'.
1104
1105 * src/pfr/pfrgload.c (pfr_glyph_load_simple,
1106 pfr_glyph_load_compound): Use them.
1107
11082016-03-25 Werner Lemberg <wl@gnu.org>
1109
Werner Lemberg2aa69562016-03-25 10:54:37 +01001110 [pfr] Minor.
1111
Alexei Podtelezhnikovf46b2822016-04-11 23:22:57 -04001112 * src/pfr/pfrsbit.c, src/pfr/pfrobjs.c: Use flag names instead of
Werner Lemberg2aa69562016-03-25 10:54:37 +01001113 bare numbers.
1114
11152016-03-25 Werner Lemberg <wl@gnu.org>
1116
Werner Lemberg59828f72016-03-25 08:47:14 +01001117 [pfr] Various clang sanitizer fixes.
1118
1119 * src/pfr/pfrsbit.c (pfr_load_bitmap_metrics): Correctly handle
1120 signed nibbles.
1121 (pfr_slot_load_bitmap): Correctly exit frame in case of error.
1122 Fix invalid left shifts.
1123
Werner Lemberge9181ab2016-03-23 06:58:20 +010011242016-03-23 Werner Lemberg <wl@gnu.org>
1125
Werner Lemberg6e89ad42016-03-23 07:40:12 +01001126 Rename `VERSION.DLL' (#47472).
1127
1128 * docs/VERSION.DLL: Renamed to...
1129 * docs/VERSIONS.TXT: ...this.
1130
11312016-03-23 Werner Lemberg <wl@gnu.org>
1132
Werner Lemberg31f2dc12016-03-23 07:31:59 +01001133 [raster, smooth] Directly test outline size (#47500).
1134
1135 This improves stand-alone compilation.
1136
1137 * src/base/ftoutln.c (FT_Outline_Render): Move cbox size test to...
1138
1139 * src/raster/ftraster.c (ft_black_render), src/smooth/ftgrays.c
1140 (gray_raster_render): ...these functions.
1141
11422016-03-23 Werner Lemberg <wl@gnu.org>
1143
Werner Lemberge9181ab2016-03-23 06:58:20 +01001144 [raster, smooth] Fix some clang sanitizer runtime issues.
1145
1146 * src/raster/ftraster.c (ft_black_reset, ft_black_set_mode,
1147 ft_black_render): Harmonize signatures with `ftimage.h'.
1148
1149 * src/smooth/ftgrays.c (gray_raster_render, gray_raster_reset):
1150 Ditto.
1151
Werner Lembergb6633072016-03-22 08:26:55 +010011522016-03-22 Werner Lemberg <wl@gnu.org>
1153
1154 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Minor.
1155
1156 This fixes an AddressSanitizer issue:
1157
1158 ttgload.c:430:7: runtime error: null pointer passed as argument 1,
1159 which is declared to never be null
1160
Werner Lemberg614a8f12016-03-21 19:39:14 +010011612016-03-21 Werner Lemberg <wl@gnu.org>
1162
1163 * src/autofit/afhints.c (af_glyph_hints_reload): Thinko.
1164
1165 This fixes the previous commit to this file.
1166
Alexei Podtelezhnikov3beccbd2016-03-21 00:07:47 -040011672016-03-21 Alexei Podtelezhnikov <apodtele@gmail.com>
1168
1169 [smooth] Partly revert recent changes.
1170
1171 * src/smooth/ftgrays.c (gray_conic_to, gray_cubic_to): Rework
1172 conditions to fix rendering issues.
1173
Werner Lemberg709486d2016-03-20 22:20:32 +010011742016-03-20 Werner Lemberg <wl@gnu.org>
1175
1176 [autofit] Show `near' points in tracing.
1177
1178 * src/autofit/afhints.h (AF_FLAG_NEAR): New macro.
1179
1180 * src/autofit/afhints.c (af_glyph_hints_dump_points): Implement it.
1181 (af_glyph_hints_reload): Handle AF_FLAG_NEAR.
1182
Alexei Podtelezhnikov8e8bb122016-03-18 23:21:59 -040011832016-03-18 Alexei Podtelezhnikov <apodtele@gmail.com>
1184
1185 [smooth] Minor refactoring and microoptimizations.
1186
1187 * src/smooth/ftgrays.c (gray_render_conic, gray_render_cubic): Move
1188 band clipping from here.
1189 (gray_conic_to, gray_cubic_to): ... to here.
1190 (gray_rander_line, gray_render_scanline): Initialize variables closer
1191 to their use.
1192
Alexei Podtelezhnikov84b2c632016-03-17 00:53:09 -040011932016-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
1194
1195 [smooth] Minor refactoring.
1196
1197 * src/smooth/ftgrays.c (gray_render_conic, gray_render_cubic): Move
Alexei Podtelezhnikov8e8bb122016-03-18 23:21:59 -04001198 upscaling from here.
1199 (gray_conic_to, gray_cubic_to): ... to here.
Alexei Podtelezhnikov84b2c632016-03-17 00:53:09 -04001200
Werner Lembergda86b732016-03-15 07:55:05 +010012012016-03-15 Werner Lemberg <wl@gnu.org>
1202
1203 * src/autofit/aflatin.c (af_latin_compute_stem_width): Optimize.
1204
Alexei Podtelezhnikov18655752016-03-14 22:39:22 -040012052016-03-14 Alexei Podtelezhnikov <apodtele@gmail.com>
1206
1207 [smooth] Temporarily revert 6eb6158dd787 (#47114).
1208
1209 * src/smooth/ftgrays.c (gray_render_line): Old implementation.
1210
Werner Lembergee6b4112016-03-12 23:48:13 +010012112016-03-12 Werner Lemberg <wl@gnu.org>
1212
1213 [ftfuzzer] Improve coverage of rasterfuzzer.
1214
1215 * src/tools/ftfuzzer/rasterfuzzer.cc (LLVMFuzzerTestOneInput): Use
1216 input data for `tags' array also.
1217 Trim input data to get more positive hits.
1218
Werner Lemberg10265db2016-03-11 06:50:23 +010012192016-03-11 Pavlo Denysov <paul.kiev+savannah@gmail.com>
1220
1221 Fix CMake issues for iOS (patch #8941).
1222
1223 * CMakeLists.txt (CMAKE_TOOLCHAIN_FILE): Fix directory.
1224 * builds/cmake/iOS.cmake: No longer enforce gcc.
1225
Behdad Esfahbod74c0a722016-03-09 20:35:27 +010012262016-03-09 Behdad Esfahbod <behdad@behdad.org>
1227
1228 [truetype] Fix handling of non-intermediate GX tuples.
1229
1230 We probably did not notice this as all fonts we tested had only
1231 tuple_coords[i] be +1 or -1 for non-intermediate tuples.
1232
1233 * src/truetype/ttgxvar.c (ft_var_apply_tuple): Implement it.
1234
Alexei Podtelezhnikovd0b0e312016-03-06 23:01:50 -050012352016-03-06 Alexei Podtelezhnikov <apodtele@gmail.com>
1236
Alexei Podtelezhnikov495de6c2016-03-06 23:54:34 -05001237 [base] Refuse to render enormous outlines (#47114).
1238
1239 The goal is to avoid integer overflows in the rendering algorithms.
1240 The limit is chosen arbitrarily at some 2^18 pixels, which should be
1241 enough for modern devices including printers.
1242
1243 * src/base/ftoutln.c (FT_Outline_Render): Check CBox and reject
1244 enormous outlines.
1245
12462016-03-06 Alexei Podtelezhnikov <apodtele@gmail.com>
1247
Alexei Podtelezhnikovd0b0e312016-03-06 23:01:50 -05001248 [smooth] Replace left shifts with multiplications (#47114).
1249
1250 * src/smooth/ftgrays.c (SUBPIXELS, UPSCALE, DOWNSCALE): Do it.
1251
Werner Lembergcaa48b02016-03-05 19:47:07 +010012522016-03-05 Werner Lemberg <wl@gnu.org>
1253
1254 [autofit] Avoid excessive stem length rounding (#25392).
1255
1256 * src/autofit/aflatin.c (af_latin_compute_stem_width): Add argument
1257 to pass difference between hinted and unhinted position of base
1258 point; use this to adjust the stem width depending on the PPEM so
1259 that it doesn't become too large under certain circumstances.
1260 Update all callers using value 0 for this argument except...
1261 (af_latin_align_linked_edge): Pass position delta of base point to
1262 `af_latin_compute_stem_width'.
1263
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040012642016-03-05 J Raynor <jxraynor@gmail.com>
J Raynor1fd2bc82016-03-05 16:38:35 +01001265
1266 Make FreeType compile on AIX out of the box.
1267
1268 * builds/unix/configure.raw (XX_ANSIFLAGS): Don't use `-ansi' on
1269 AIX.
1270
Werner Lemberg015c6e02016-03-01 06:45:52 +010012712016-03-01 Werner Lemberg <wl@gnu.org>
Werner Lemberga8b95622016-03-01 09:37:12 +01001272 Kostya Serebryany <kcc@google.com>
1273
1274 [ftfuzzer] Add unit for testing smooth and black rasterizers.
1275
1276 * src/tools/ftfuzzer/rasterfuzzer.cc: New file.
1277
12782016-03-01 Werner Lemberg <wl@gnu.org>
Werner Lemberg015c6e02016-03-01 06:45:52 +01001279
Werner Lemberg3eb6f662016-03-01 07:10:30 +01001280 [autofit] Fix reallocation error introduced in 2016-02-27 (#47310).
1281
1282 * src/autofit/aflatin.c (af_latin_hints_compute_segments): Reassign
1283 `prev_segment' after reallocation.
1284
12852016-03-01 Werner Lemberg <wl@gnu.org>
1286
Werner Lemberg015c6e02016-03-01 06:45:52 +01001287 Fix clang warnings.
1288
1289 * src/autofit/aflatin.c (af_latin_hints_compute_segments): Use
1290 FT_UShort for `min_flags' and `max_flags'.
1291 Initialize `prev_*' variables.
1292
1293 * src/cff/cffobjs.c (cff_face_init) [FT_DEBUG_LEVEL_TRACE]: Fix
1294 types of local variables.
1295
1296 * src/smooth/ftgrays.c (gray_dump_cells) [FT_DEBUG_LEVEL_TRACE]:
1297 Update `printf' format string.
1298
1299 * src/tools/ftfuzzer/ftfuzzer.cc (setIntermediateAxis): Add cast.
1300 (LLVMFuzzerTestOneInput): Fix loop type.
1301
Werner Lemberg5c7646d2016-02-29 09:12:35 +010013022016-02-29 Werner Lemberg <wl@gnu.org>
1303
1304 [autofit] Add blue-zone support for Sinhala script.
1305
1306 This essentially moves the Sinhala script from the `Indic' hinter to
1307 the `Latin' hinter.
1308
1309 * src/autofit/afblue.dat: Add blue zone data for Sinhala.
1310
1311 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
1312
1313 * src/autofit/afscript.h: Add Sinhala standard character and move data
1314 out of AF_CONFIG_OPTION_INDIC block.
1315
1316 * src/autofit/afranges.c: Move Sinhala data out of
1317 AF_CONFIG_OPTION_INDIC block.
1318
1319 * src/autofit/afstyles.h: Update Sinhala data; in particular, use
1320 AF_WRITING_SYSTEM_LATIN.
1321
Werner Lembergce486642016-02-27 15:01:49 +010013222016-02-27 Werner Lemberg <wl@gnu.org>
1323
Werner Lembergf2169472016-02-28 22:48:34 +01001324 [autofit] Properly handle spikes pointing to the x-axis.
1325
1326 An example that gets better rendered is glyph `uusignTaml' (glyph
1327 index 2286) in font `FreeSerif.ttf' (Version 0412.2263) at 22ppem.
1328
1329 * src/autofit/aflatin.c (af_latin_hints_compute_segments): Properly
1330 handle segments where the last point of the first segment is
1331 identical to the first point in the second one. This can happen for
1332 malformed fonts or spikes. We either merge the new segment with the
1333 previous one (both segments point into the same direction), or we
1334 discard the shorter segment if they point into different directions.
1335
13362016-02-27 Werner Lemberg <wl@gnu.org>
1337
Werner Lembergce486642016-02-27 15:01:49 +01001338 [autofit] Minor code clean-up.
1339
1340 * src/autofit/aflatin.c (af_latin_hints_compute_segments): Change
1341 some local variable names to better differentiate between values
1342 along a segment and values orthogonal to it.
1343
Werner Lembergebfd7ce2016-02-26 08:10:41 +010013442016-02-26 Werner Lemberg <wl@gnu.org>
1345
1346 [autofit] Improve BOUND action.
1347
1348 In complex glyph shapes, the original logic was too simple to cater
1349 for situations that would actually need something similar to PS Hint
1350 masks. This fix should alleviate the worst cases.
1351
1352 * src/autofit/aflatin.c (af_latin_hint_edges): Don't allow
1353 complete disappearance of stems.
1354
Werner Lemberg44324b32016-02-25 06:58:47 +010013552016-02-25 Werner Lemberg <wl@gnu.org>
1356
1357 [autofit] Add blue-zone support for Tamil script.
1358
1359 This essentially moves the Tamil script from the `Indic' hinter to
1360 the `Latin' hinter.
1361
1362 * src/autofit/afblue.dat: Add blue zone data for Tamil.
1363
1364 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
1365
Werner Lemberg5c7646d2016-02-29 09:12:35 +01001366 * src/autofit/afscript.h: Add Tamil standard character and move data
Werner Lemberg44324b32016-02-25 06:58:47 +01001367 out of AF_CONFIG_OPTION_INDIC block.
1368
1369 * src/autofit/afranges.c: Move Tamil data out of
1370 AF_CONFIG_OPTION_INDIC block.
1371
1372 * src/autofit/afstyles.h: Update Tamil data; in particular, use
1373 AF_WRITING_SYSTEM_LATIN.
1374
Werner Lemberga5952d32016-02-18 12:56:38 +010013752016-02-18 Werner Lemberg <wl@gnu.org>
1376
1377 [autofit] Add blue-zone support for Malayalam script.
1378
1379 This essentially moves the Malayalam script from the `Indic' hinter
1380 to the `Latin' hinter.
1381
1382 * src/autofit/afblue.dat: Add blue zone data for Malayalam.
1383
1384 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
1385
1386 * src/autofit/afscript.h: Add Malayalam standard characters and move
1387 data out of AF_CONFIG_OPTION_INDIC block.
1388
1389 * src/autofit/afranges.c: Move Malayalam data out of
1390 AF_CONFIG_OPTION_INDIC block.
1391
1392 * src/autofit/afstyles.h: Update Malayalam data; in particular, use
1393 AF_WRITING_SYSTEM_LATIN.
1394
Alexei Podtelezhnikov08e89b72016-02-16 22:32:13 -050013952016-02-16 Alexei Podtelezhnikov <apodtele@gmail.com>
1396
1397 [smooth] Fix integer overflow (#47114).
1398
1399 * src/smooth/ftgrays.c (TArea): Make it unconditionally `long'.
1400
Werner Lemberg658f5302016-02-15 14:28:28 +010014012016-02-15 Werner Lemberg <wl@gnu.org>
1402
Werner Lemberg3a5e5072016-02-15 22:21:01 +01001403 * src/cff/cffparse.c (cff_parse_multiple_master): Improve tracing.
1404
14052016-02-15 Werner Lemberg <wl@gnu.org>
1406
Werner Lemberg28730102016-02-15 20:53:22 +01001407 [cff] Handle T2 operator only with old CFF engine (#47157).
1408
1409 * src/cff/cffparse.c (cff_parser_run) <opcode 31>: Enclose with
1410 #ifdef CFF_CONFIG_OPTION_OLD_ENGINE...#endif.
1411
14122016-02-15 Werner Lemberg <wl@gnu.org>
1413
Werner Lemberg8ed9eaf2016-02-15 20:41:58 +01001414 [cff] Partially handle `load' and `store' ops in old CFF engine.
1415
1416 Now all glyphs of MM CFFs like `ITCGaramondMM-It.otf' can be
1417 displayed.
1418
1419 * src/cff/cffgload.c (cff_decoder_parse_charstrings) <cff_op_store,
1420 cff_op_load>: Partially implement it.
1421
1422 * src/cff/cffparse.c (cff_parser_init): Add new parameter to pass
1423 the number of Multiple Master axes.
1424 Update all callers.
1425 (cff_parse_multiple_master): Get number of axes.
1426 (cff_parser_run) <opcode 31>: Updated.
1427 * src/cff/cffparse.h: Updated.
1428 (CFF_ParserRec): Add `num_axes' field.
1429
1430 * src/cff/cffload.c: Updated.
1431
1432 * src/cff/cfftypes.h (CFF_FontRecDictRec): Add `num_axes' field.
1433
14342016-02-15 Werner Lemberg <wl@gnu.org>
1435
Werner Lemberg658f5302016-02-15 14:28:28 +01001436 [cff] Correctly trace SIDs that contain NULL bytes.
1437
1438 We need this to properly trace Multiple Master CFFs, which contain
1439 two SIDs that are charstrings.
1440
1441 This commit makes FreeType also show the last SID, omitted
1442 previously due to a bug.
1443
1444 * src/cff/cfftypes.h (CFF_FontRec): Add `string_pool_size' field.
1445
1446 * src/cff/cffload.c (cff_index_get_pointers): Add argument to return
1447 the pool size.
1448 Update all callers.
1449
1450 * src/cff/cffobjs.c (cff_face_init) [FT_DEBUG_LEVEL_TRACE]: Directly
1451 access `cff->strings' to display the non-default strings.
1452
Werner Lemberg813aca52016-02-14 16:03:15 +010014532016-02-14 Werner Lemberg <wl@gnu.org>
1454
Werner Lemberge411d382016-02-14 20:48:59 +01001455 * src/base/fthash.c: Include FT_INTERNAL_MEMORY_H.
1456
14572016-02-14 Werner Lemberg <wl@gnu.org>
1458
Werner Lembergdc5b2e82016-02-14 20:47:28 +01001459 * src/cff/cffparse.c: Include `cffgload.h'.
1460
1461 Problem reported by Colin Walters <walters@verbum.org>.
1462
14632016-02-14 Werner Lemberg <wl@gnu.org>
1464
Werner Lemberg813aca52016-02-14 16:03:15 +01001465 [cff] Make old CFF engine show MM CFFs (without variations).
1466
1467 The new code only displays the first master in the font.
1468
1469 * src/cff/cffgload.c (cff_decode_parse_charstrings): Add new
1470 parameter to allow function calls from dictionaries also.
1471 <cff_op_blend>: Partially implement it.
1472 Update all callers.
1473 * src/cff/cffgload.h: Updated.
1474
1475 * src/cff/cffparse.c (cff_parser_init): Add new parameter to pass the
1476 number of Multiple Master designs.
1477 Update all callers.
1478 (cff_parse_multiple_master): New function to rudimentarily parse
1479 operator.
1480 (cff_parser_run): Handle `T2' operator.
1481 * src/cff/cffparse.h: Updated.
1482 (CFF_ParserRec): Add `num_designs' field.
1483
1484 * src/cff/cffload.c: Updated.
1485
1486 * src/cff/cfftoken.h: Handle `MultipleMaster' operator.
1487
1488 * src/cff/cfftypes.h (CFF_FontRecDictRec): Add `num_designs' field.
1489
1490 * src/sfnt/sfobjs.c (sfnt_init_face): Don't handle `fvar' table for
1491 MM CFFs.
1492
Werner Lemberg4b3ea5c2016-02-09 08:08:17 +010014932016-02-09 Werner Lemberg <wl@gnu.org>
1494
1495 [docmaker] Don't emit trailing newlines.
1496
1497 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_html_code):
1498 Use `rstrip'.
1499
Werner Lemberg950f1692016-02-07 11:39:54 +010015002016-02-07 Werner Lemberg <wl@gnu.org>
1501
Werner Lemberg44accb92016-02-08 19:51:40 +01001502 * Version 2.6.3 released.
1503 =========================
1504
1505
1506 Tag sources with `VER-2-6-3'.
1507
1508 * docs/VERSION.DLL: Update documentation and bump version number to
1509 2.6.3.
1510
1511 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
1512 builds/windows/vc2005/index.html,
1513 builds/windows/vc2008/freetype.vcproj,
1514 builds/windows/vc2008/index.html,
1515 builds/windows/vc2010/freetype.vcxproj,
1516 builds/windows/vc2010/index.html,
1517 builds/windows/visualc/freetype.dsp,
1518 builds/windows/visualc/freetype.vcproj,
1519 builds/windows/visualc/index.html,
1520 builds/windows/visualce/freetype.dsp,
1521 builds/windows/visualce/freetype.vcproj,
1522 builds/windows/visualce/index.html,
1523 builds/wince/vc2005-ce/freetype.vcproj,
1524 builds/wince/vc2005-ce/index.html,
1525 builds/wince/vc2008-ce/freetype.vcproj,
1526 builds/wince/vc2008-ce/index.html: s/2.6.2/2.6.3/, s/262/263/.
1527
1528 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 3.
1529
1530 * builds/unix/configure.raw (version_info): Set to 18:3:12.
Werner Lembergd80fe692016-07-05 15:40:19 +02001531 * CMakeLists.txt (VERSION_PATCH): Set to 3.
Werner Lemberg44accb92016-02-08 19:51:40 +01001532
1533 * docs/CHANGES: Updated.
1534
15352016-02-07 Werner Lemberg <wl@gnu.org>
1536
Werner Lemberg78371bd2016-02-07 21:06:59 +01001537 Fix another runtime error found by clang's sanitizer (#47082).
1538
1539 * src/base/ftstroke.c (ft_stroke_border_export): Properly handle
1540 empty input buffer.
1541
15422016-02-07 Werner Lemberg <wl@gnu.org>
1543
Werner Lemberg0d053ba2016-02-07 19:25:56 +01001544 Fix runtime errors found by clang's sanitizer (#47082).
1545
1546 * src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c
1547 (FT_Outline_Copy), src/cache/ftcsbits.c (ftc_sbit_copy_bitmap):
1548 Properly handle empty input buffer.
1549
15502016-02-07 Werner Lemberg <wl@gnu.org>
1551
Werner Lemberga1460702016-02-07 11:42:37 +01001552 [cff] Minor.
1553
1554 * src/cff/cffgload.c (cff_decoder_parse_charstrings) <cff_op_sqrt>:
1555 Remove dead code.
1556
15572016-02-07 Werner Lemberg <wl@gnu.org>
1558
Werner Lemberg950f1692016-02-07 11:39:54 +01001559 [cff] Implement missing operators in new engine (except `random').
1560
1561 * src/cff/cf2font.h (CF2_STORAGE_SIZE): New macro.
1562
1563 * src/cff/cf2intrp.c (cf2_interpT2CharString): Implement the
1564 following operators: abs, add, and, div, drop, dup, eq, exch, get,
1565 ifelse, index, mul, neg, not, or, put, roll, sqrt, sub.
1566
1567 * src/cff/cf2stack.h, src/cff/cf2stack.c (cf2_stack_roll): New
1568 auxiliary function for `roll' operator.
1569
Werner Lemberg5c8a8cb2016-02-06 08:03:03 +010015702016-02-06 Werner Lemberg <wl@gnu.org>
1571
1572 [cff] Fix some Type 2 operators in old CFF engine.
1573
1574 * src/cff/cffgload.c (cff_decoder_parse_charstrings): Fix `eq'
1575 operator, add `not' and (unsupported) `blend' operators.
1576
Sebastian Rasmussenae7c55d2016-02-05 18:42:19 +010015772016-02-05 Sebastian Rasmussen <sebras@gmail.com>
1578
1579 Make direct call of `make install' work (#47072).
1580
1581 * builds/unix/unix-def.in (freetype-config): Make sure
1582 `freetype-config' is generated for both make targets (`all' and
1583 `install').
1584
Werner Lemberg710ac3d2016-02-05 12:47:29 +010015852016-02-05 Werner Lemberg <wl@gnu.org>
1586
1587 [base] Fix advance width loading for MM and GX fonts (#47064).
1588
1589 * src/base/ftadvanc.c (LOAD_ADVANCE_FAST_CHECK): Return false for
1590 MM and GX fonts.
1591 Update callers.
1592
Werner Lembergcd346da2016-02-03 19:32:03 +010015932016-02-03 Werner Lemberg <wl@gnu.org>
1594
1595 [cff] Fix handling of face_index == -1 for pure CFF.
1596
1597 * src/cff/cffobjs.c (cff_face_init): Return correct number of faces.
1598
Werner Lembergbaa41ff2016-01-30 07:44:30 +010015992016-01-30 Werner Lemberg <wl@gnu.org>
1600
1601 [autofit] Minor tracing improvement.
1602
1603 * src/autofit/afhints.c (af_glyph_hints_dump_points): Insert newline
1604 at the start of a new contour.
1605
Nikolaus Waxweiler68750932016-01-28 12:24:36 +010016062016-01-28 Nikolaus Waxweiler <madigens@gmail.com>
1607
Nikolaus Waxweiler1d8d0b42016-01-28 14:11:14 +01001608 Remove unpatented hinter (3/3).
1609
1610 * include/freetype/config/ftoption.h
1611 (TT_CONFIG_OPTION_UNPATENTED_HINTING): Remove.
1612
1613 * include/freetype/internal/ftobjs.h (FT_Face_InternalRec): Remove
1614 `ignore_unpatented_hinter' field.
1615 Update users.
1616 (FT_DEBUG_HOOK_UNPATENTED_HINTING): Remove.
1617 Update users.
1618
1619 * include/freetype/internal/tttypes.h (TT_FaceRec): Remove
1620 `unpatented_hinting' field.
1621 Update users.
1622
1623 * src/base/ftpatent.c (_tt_check_patents_in_range,
1624 _tt_check_patents_in_table, _tt_face_check_patents): Remove.
1625 (FT_Face_CheckTrueTypePatents, FT_Face_SetUnpatentedHinting):
1626 Replace code with dummies.
1627
Werner Lemberg0d053ba2016-02-07 19:25:56 +01001628 * src/truetype/ttobjs.c (tt_face_init): Remove now defunct code.
Nikolaus Waxweiler1d8d0b42016-01-28 14:11:14 +01001629 * src/truetype/ttobjs.h (TT_GraphicsState): Remove `both_x_axis'
1630 field.
1631
16322016-01-28 Nikolaus Waxweiler <madigens@gmail.com>
1633
Nikolaus Waxweiler5b7871b2016-01-28 12:27:46 +01001634 Remove unpatented hinter (2/3).
1635
1636 * devel/ftoption.h (TT_CONFIG_OPTION_UNPATENTED_HINTING): Remove.
1637
16382016-01-28 Nikolaus Waxweiler <madigens@gmail.com>
1639
Nikolaus Waxweiler68750932016-01-28 12:24:36 +01001640 Remove unpatented hinter (1/3).
1641
1642 * src/truetype/ttinterp.c [TT_CONFIG_OPTION_UNPATENTED_HINTING]:
1643 Remove all code related to this macro.
1644
Werner Lemberg8d810092016-01-28 10:13:24 +010016452016-01-28 Werner Lemberg <wl@gnu.org>
1646
1647 [autofit] Add blue-zone support for Kannada script.
1648
1649 This essentially moves the Kannada script from the `Indic' hinter to
1650 the `Latin' hinter.
1651
1652 * src/autofit/afblue.dat: Add blue zone data for Kannada.
1653
1654 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
1655
1656 * src/autofit/afscript.h: Add Kannada standard characters and move
1657 data out of AF_CONFIG_OPTION_INDIC block.
1658
1659 * src/autofit/afranges.c: Move Kannada data out of
1660 AF_CONFIG_OPTION_INDIC block.
1661
1662 * src/autofit/afstyles.h: Update Kannada data; in particular, use
1663 AF_WRITING_SYSTEM_LATIN.
1664
Alexei Podtelezhnikove4c69d22016-01-22 23:35:49 -050016652016-01-22 Alexei Podtelezhnikov <apodtele@gmail.com>
1666
1667 Better access to 64-bit integers for C99 compilers.
1668
1669 * include/freetype/config/ftconfig.h [FT_LONG64]: Use
1670 __STDC_VERSION__ to define 64-bit integers.
1671 * builds/unix/ftconfig.in [FT_LONG64]: Ditto.
1672 * builds/vms/ftconfig.h [FT_LONG64]: Ditto.
1673
Werner Lembergfc4523b2016-01-21 06:20:20 +010016742016-01-21 Werner Lemberg <wl@gnu.org>
1675
1676 [gxvalid] Remove commented out code.
1677
1678 * src/gxvalid/gxvcommn.c (gxv_EntryTable_validate): Do it.
1679
Werner Lemberg24fbed02016-01-20 21:10:41 +010016802016-01-20 Werner Lemberg <wl@gnu.org>
1681
Werner Lemberg78371bd2016-02-07 21:06:59 +01001682 [autofit] Complete last autofit commit.
Werner Lembergfb672892016-01-20 21:13:16 +01001683
1684 Problem reported by Kostya Serebryany <kcc@google.com>.
1685
1686 * src/autofit/afshaper.c (af_shaper_get_coverage)
1687 [!FT_CONFIG_OPTION_USE_HARFBUZZ]: Update signature.
1688
16892016-01-20 Werner Lemberg <wl@gnu.org>
1690
Werner Lemberg24fbed02016-01-20 21:10:41 +01001691 Still handle `__FTERRORS_H__'.
1692
1693 We need this for backwards compatibility.
1694
1695 Problem reported by John Emmas <johne53@tiscali.co.uk>.
1696
1697 * include/freetype/fterrors.h: Fix inclusion guard so that
1698 undefining either `FTERRORS_H_' or `__FTERRORS_H__' works as
1699 expected.
1700
Werner Lembergfc11af12016-01-19 19:15:54 +010017012016-01-19 Werner Lemberg <wl@gnu.org>
1702
Werner Lembergec776592016-01-19 19:33:57 +01001703 [autofit] Fix handling of default script.
1704
1705 Patch taken from ttfautohint, commit
1706 071ae2c00e0d67f9d19418f4fade1c23d27dc185.
1707
1708 There were two bugs.
1709
1710 - We now use non-standard script tags like `khms' for special
1711 purposes. However, HarfBuzz maps such tags to `DFLT', and
1712 without this commit the associated lookups were incorrectly
1713 assigned to the non-standard tags.
1714
1715 - Let's assume we have a Bengali font, and the font's `DFLT'
1716 script tag handles the necessary lookups for Bengali, too.
1717 Without this commit, the `DFLT' lookups were assigned to
1718 ttfautohint's default script (usually `latn') before the
1719 standard lookups for Bengali were handled.
1720
1721 We now have the following order while searching for covered
1722 glyph indices.
1723
1724 special features of scripts (e.g. `sups' for Cyrillic)
1725 Unicode mappings of scripts
1726 remaining features of scripts (especially important for Indic
1727 scripts)
1728 default features of default script
1729
1730 * src/autofit/afshaper.c, src/autofit/afshaper.h
1731 (af_shaper_get_coverage): Add boolean parameter to indicate default
1732 script.
1733 Update all callers.
1734
1735 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
1736 Fix search order for coverages.
1737
17382016-01-19 Werner Lemberg <wl@gnu.org>
1739
Werner Lembergfc11af12016-01-19 19:15:54 +01001740 Various minor clang fixes.
1741
1742 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
1743 src/autofit/aflatin.c (af_latin_metrics_init_widths): Initialize
1744 `ch'.
1745
1746 * src/base/ftcalc.c (FT_MulFix) [FT_LONG64]: Add cast.
1747
1748 * src/base/ftdbgmem.c (ft_mem_table_destroy): Add cast.
1749
1750 * src/base/fthash.c (hash_num_lookup): Add cast.
1751
1752 * src/base/fttrigon.c (ft_trig_downscale) [FT_LONG64]: Fix cast.
1753
1754 * src/gxvalid/gxvcommn.c (gxv_EntryTable_validate): Comment out
1755 redundant code.
1756
1757 * src/type1/t1driver.c (t1_get_ps_font_value) <PS_DICT_SUBR>: Add
1758 cast.
1759
1760 * src/type1/t1load.c (parse_subrs): Fix type of `count'.
1761
Derek B. Noonburg4cdfefd2016-01-19 07:12:44 +010017622016-01-19 Derek B. Noonburg <derekn@glyphandcog.com>
1763
1764 [truetype] Add another tricky font.
1765
1766 * src/truetype/ttobjs.c (TRICK_SFNT_IDS_NUM_FACES): Increase.
1767 (sfnt_id): Add variant of `DFKaiShu'.
1768
Alexei Podtelezhnikov32760d32016-01-14 23:31:08 -050017692016-01-14 Alexei Podtelezhnikov <apodtele@gmail.com>
1770
1771 [base] Empower `FT_Library_SetLcdFilterWeights'.
1772
1773 * src/base/ftlcdfil.c (FT_Library_SetLcdFilterWeights): Enable filter
1774 in addition to setting weights.
1775 (FT_Library_SetLcdFilter): Clean out FT_FORCE_LIGHT_LCD_FILTER and
1776 FT_FORCE_LEGACY_LCD_FILTER.
1777 * include/freetype/ftlcdfil.h: Documentation update.
1778
Werner Lemberg37412ff2016-01-12 21:37:13 +010017792016-01-12 Werner Lemberg <wl@gnu.org>
1780
Werner Lembergc09a90a2016-01-12 22:28:14 +01001781 Don't use macro names that start with `_[A-Z]' [3/3].
1782
1783 Such macro names are reserved for both C and C++.
1784
1785 * src/cache/ftccache.h: s/_FTC_FACE_ID_HASH/FTC_FACE_ID_HASH/.
1786 Update all callers.
1787 (FTC_CACHE_LOOKUP_CMP): Replace `_XXX' with `XXX_'.
1788 * src/cache/ftcmru.c (FTC_MRULIST_LOOKUP_CMP): Ditto.
1789
17902016-01-12 Werner Lemberg <wl@gnu.org>
1791
Werner Lemberg9d0b76d2016-01-12 22:27:29 +01001792 Don't use macro names that start with `_[A-Z]' [2/3].
1793
1794 Such macro names are reserved for both C and C++.
1795
1796 * include/freetype/ftimage.h, src/raster/ftraster.c,
1797 src/smooth/ftgrays.c, src/smooth/ftgrays.h:
1798 s/_STANDALONE_/STANDALONE_/.
1799
18002016-01-12 Werner Lemberg <wl@gnu.org>
1801
Werner Lemberg758587d2016-01-12 22:20:06 +01001802 Don't use macro names that start with `_[A-Z]' [1/3].
1803
1804 Such macro names are reserved for both C and C++.
1805
1806 * src/bdf/bdflib.c: Replace macros of the form `_BDF_XXX' with
1807 `BDF_XXX_'.
1808
18092016-01-12 Werner Lemberg <wl@gnu.org>
1810
Werner Lemberg2e9d2662016-01-12 21:40:53 +01001811 Don't use macro names that contain `__' [2/2].
1812
1813 Such macro names are reserved for both C and C++.
1814
1815 * src/cache/*: s/__/_/.
1816
18172016-01-12 Werner Lemberg <wl@gnu.org>
1818
Werner Lemberg37412ff2016-01-12 21:37:13 +01001819 Don't use macro names that contain `__' [1/2].
1820
1821 Such macro names are reserved for both C and C++.
1822
Werner Lemberg2e9d2662016-01-12 21:40:53 +01001823 * */*: Replace macros of the form `__XXX_H__' with `XXX_H_'.
Werner Lemberg37412ff2016-01-12 21:37:13 +01001824
Jered Grayf53bab92016-01-10 12:03:36 +010018252016-01-10 Jered Gray <jegray@google.com>
1826
1827 [cff] Fix usage of `|' operator.
1828
1829 * src/cff/cf2intrp.c (cf2_interpT2CharString) [cf2_cmdEXTENDEDNMBR,
1830 default]: `|' is not guaranteed to be processed from left to right
1831 by the compiler. However, the code repeatedly calls
1832 `cf2_buf_readByte' to get the arguments to `|' ... Fix this.
1833
Werner Lemberg2e098122015-12-25 08:05:30 +010018342015-12-25 Werner Lemberg <wl@gnu.org>
1835
1836 [autofit] Make top-to-bottom hinting work in latin auto-hinter.
1837
1838 This improves rendering of scripts like Bengali or Devanagari.
1839
1840 * src/autofit/afhints.c (af_axis_hints_new_edge): Add parameter to
1841 pass top-to-bottom hinting flag. This makes the function sort edges
1842 in descending vertical position.
1843
1844 * src/autofit/afhints.c: Updated.
1845
1846 * src/autofit/aflatin.c (af_latin_hints_compute_edges,
1847 af_latin_hint_edges): Use `top_to_bottom_hinting' flag.
1848
1849 * src/autofit/afcjk.c (af_cjk_hints_compute_edges),
1850 src/autofit/aflatin2.c (af_latin2_hints_compute_edges): Updated.
1851
Werner Lemberg172db322015-12-24 08:17:51 +010018522015-12-24 Werner Lemberg <wl@gnu.org>
1853
1854 [autofit] Add hinting direction to `AF_ScriptClassRec'.
1855
1856 Still unused.
1857
1858 * src/autofit/afglobal.c (SCRIPT): Handle hinting direction.
1859
1860 * src/autofit/aftypes.h (AF_ScriptClassRec): Add
1861 `top_to_bottom_hinting' field.
1862 (AF_HINTING_BOTTOM_TO_TOP, AF_HINTING_TOP_TO_BOTTOM): New macros.
1863 (AF_DEFINE_SCRIPT_CLASS): Updated.
1864
Werner Lembergb0de5a82015-12-23 23:25:03 +010018652015-12-23 Werner Lemberg <wl@gnu.org>
1866
1867 [autofit] Start implementing hinting direction (up/down, down/up).
1868
1869 Right now, it does nothing.
1870
1871 * src/autofit/afscript.h: Add another parameter to `SCRIPT',
1872 specifying hinting direction.
1873
Alexei Podtelezhnikovc05a1c32016-06-21 23:12:54 -04001874 * src/autofit/afglobal.c, src/autofit/afglobal.h,
Werner Lembergb0de5a82015-12-23 23:25:03 +01001875 src/autofit/afpic.c, src/autofit/afranges.h, src/autofit/afshaper.c,
1876 src/autofit/aftypes.h: Extend `SCRIPT' definitions.
1877
Werner Lemberg7ce6c432015-12-22 05:39:58 +010018782015-12-22 Werner Lemberg <wl@gnu.org>
1879
Werner Lemberg9c1a2b02015-12-22 12:05:46 +01001880 * src/type1/t1load.c (parse_subrs): Fix memory leak (#46744).
1881
18822015-12-22 Werner Lemberg <wl@gnu.org>
1883
Werner Lemberg7ce6c432015-12-22 05:39:58 +01001884 [base] Make hash interface symmetric.
1885
1886 Use `num' and `str' infixes everywhere.
1887
1888 * src/base/fthash.c (ft_hash_init): Renamed to...
1889 (hash_init): ... This.
1890 (ft_hash_str_init, ft_hash_num_init): New functions.
1891 (ft_hash_free): Renamed to...
1892 (ft_hash_str_free): ... This.
1893
1894 * include/freetype/internal/fthash.h: Updated.
1895
1896 * src/bdf/bdflib.c, src/type1/t1load.c, src/type1/t1objs.c: Updated.
1897
Werner Lemberg60d13bd2015-12-21 17:27:17 +010018982015-12-21 Werner Lemberg <wl@gnu.org>
1899
1900 [type1] Avoid shift of negative numbers (#46732).
1901
1902 * src/type1/t1load.c (parse_subrs): Do it.
1903
Werner Lemberg609546c2015-12-20 07:17:29 +010019042015-12-20 Werner Lemberg <wl@gnu.org>
1905
Werner Lembergbd4b8972015-12-20 19:36:04 +01001906 [type1, psaux] Handle large values of num_subrs correctly (#46692).
1907
1908 We now use a hash to map from subr indices to array elements holding
1909 the subroutines, if necessary.
1910
1911 * include/freetype/internal/t1types.h: Include FT_INTERNAL_HASH_H.
1912 (T1_FontRec): Add `subrs_hash' field.
1913
1914 * include/freetype/internal/psaux.h: Include FT_INTERNAL_HASH_H.
1915 (T1_DecoderRec): Add `subrs_hash' field.
1916
1917 * src/type1/t1load.h (T1_LoaderRec): Add `subrs_hash' field.
1918
1919 * src/type1/t1driver.c: Include FT_INTERNAL_HASH_H.
1920 (t1_ps_get_font_value) [PS_DICT_SUBR]: Look up hash if necessary.
1921
1922 * src/type1/t1load.c: Include FT_INTERNAL_HASH_H.
1923 (parse_subrs): Use hash for subr indices that exceed the allocated
1924 number of subr slots.
1925 (t1_init_loader): Remove unnecessary code.
1926 (t1_done_loader, T1_Open_Face): Updated.
1927
1928 * src/type1/t1gload.c (T1_Compute_Max_Advance, T1_Get_Advances,
1929 T1_Load_Glyph): Updated.
1930
1931 * src/type1/t1objs.c (T1_Face_Done): Updated.
1932
1933 * src/psaux/t1decode.c: Include FT_INTERNAL_HASH_H.
1934 (t1_decoder_parse_charstrings) [op_callsubr]: Look up hash if
1935 necessary.
1936
1937 * src/cid/cidgload.c (cid_load_glyph): Updated.
1938
19392015-12-20 Werner Lemberg <wl@gnu.org>
1940
Werner Lemberg1caf6292015-12-20 19:00:35 +01001941 [base] Thinko: Remove free function pointer.
1942
1943 We don't copy keys or values while hashing.
1944
1945 * include/freetype/internal/fthash.h (FT_Hash_FreeFunc): Removed.
1946 (FT_HashRec): Remove `free' field.
1947
1948 * src/base/fthash.c (hash_str_free): Removed.
1949 (ft_hash_init, ft_hash_free): Updated.
1950
19512015-12-20 Werner Lemberg <wl@gnu.org>
1952
Werner Lemberg76e79ec2015-12-20 09:03:15 +01001953 [base, bdf] Don't expose `FT_Hashnode' in hash functions.
1954
1955 * src/base/fthash.c (hash_lookup, ft_hash_str_lookup,
1956 ft_hash_num_lookup): Return pointer to `size_t' instead of
1957 `FT_Hashnode'.
1958
1959 * include/freetype/internal/fthash.h: Updated.
1960
1961 * src/bdf/bdflib.c (bdf_get_property, _bdf_add_property,
1962 bdf_get_font_property): Updated.
1963
19642015-12-20 Werner Lemberg <wl@gnu.org>
1965
Werner Lembergad306ea2015-12-20 08:33:21 +01001966 [base, bdf] Add number hashing.
1967
1968 * src/base/fthash.c (hash_num_lookup, hash_num_compare): New
1969 functions.
1970 (ft_hash_init): Add argument to select between number and string
1971 hashing.
1972 (ft_hash_num_insert, ft_hash_num_lookup): New functions.
1973
1974 * include/freetype/internal/fthash.h: Updated.
1975
1976 * src/bdf/bdflib.c (_bdf_parse_start): Updated.
1977
19782015-12-20 Werner Lemberg <wl@gnu.org>
1979
Werner Lemberg1b7549c2015-12-20 08:00:33 +01001980 [base] Introduce hash lookup, compare, and free function pointers.
1981
1982 * include/freetype/internal/fthash.c (FT_Hash_LookupFunc,
1983 FT_Hash_CompareFunc, FT_Hash_FreeFunc): New typedefs.
1984 (FT_HashRec): Add `lookup', `compare', and `free' fields.
1985
1986 * src/base/fthash.c (hash_str_lookup, hash_str_compare,
1987 hash_str_free): New functions.
1988 (ft_hash_init): Set function pointers.
1989 (hash_bucket, ft_hash_free): Use them.
1990
19912015-12-20 Werner Lemberg <wl@gnu.org>
1992
Werner Lemberg609546c2015-12-20 07:17:29 +01001993 [base, bdf] Use a union as a hash key.
1994
1995 We want to support both an integer and a string key later on.
1996
1997 * include/freetype/internal/fthash.h (FT_Hashkey): New union.
1998 (FT_HashnodeRec): Updated.
1999 (ft_hash_insert, ft_hash_lookup): Renamed to ...
2000 (ft_hash_str_insert, ft_hash_str_lookup): ... this.
2001
2002 * src/base/fthash.c (hash_bucket): Updated.
2003 (ft_hash_insert, ft_hash_lookup): Renamed to ...
2004 (hash_insert, hash_lookup): ... this.
2005 (ft_hash_str_insert, ft_hash_str_lookup): New wrapper functions.
2006
2007 * src/bdf/bdflib.c: Updated.
2008
Werner Lembergc98a40f2015-12-19 16:59:40 +010020092015-12-19 Werner Lemberg <wl@gnu.org>
2010
Werner Lemberg31343562015-12-19 17:02:13 +01002011 [bdf] Use new hash functions.
2012
2013 * src/bdf/bdf.h: Include FT_INTERNAL_HASH_H.
2014 (hashnode, hashtable): Removed.
2015 (bdf_font_t): Use `FT_HashRec' type for `proptbl'.
2016
2017 * src/bdf/bdflib.c: Remove all hash functions.
2018 Update code for new hash structure and function names.
2019
20202015-12-19 Werner Lemberg <wl@gnu.org>
2021
Werner Lembergc98a40f2015-12-19 16:59:40 +01002022 [bdf, base] Lift hash functions from bdf driver to base module.
2023
2024 * src/base/fthash.c, include/freetype/internal/fthash.h: New files,
2025 containing (massaged) code from `bdflib.c' and `bdf.h'.
2026
2027 * include/freetype/internal/internal.h (FT_INTERNAL_HASH_H): New
2028 macro.
2029
2030 * src/base/ftbase.c: Include `fthash.c'.
2031
2032 * src/base/Jamfile (_sources): Add `fthash'.
2033
2034 * src/base/rules.mk (BASE_SRC): Add `fthash.c'.
2035
2036 * docs/LICENSE.TXT: Updated.
2037
Werner Lemberg02451c72015-12-15 17:53:46 +010020382015-12-15 Werner Lemberg <wl@gnu.org>
2039
2040 [autofit] Add blue-zone support for Bengali script.
2041
2042 This essentially moves the Bengali script from the `Indic' hinter to
2043 the `Latin' hinter.
2044
2045 * src/autofit/afblue.dat: Add blue zone data for Bengali.
2046
2047 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2048
2049 * src/autofit/afscript.h: Add Bengali standard characters and move
2050 data out of AF_CONFIG_OPTION_INDIC block.
2051
2052 * src/autofit/afranges.c: Move Bengali data out of
2053 AF_CONFIG_OPTION_INDIC block.
2054
2055 * src/autofit/afstyles.h: Update Bengali data; in particular, use
2056 AF_WRITING_SYSTEM_LATIN.
2057
Ben Wagnera512b0f2015-12-14 09:19:52 +010020582015-12-14 Ben Wagner <bungeman@gmail.com>
2059
2060 [bdf] Remove dead code (#46625).
2061
2062 The BDF specification only allows decimal numbers, no octal or
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04002063 hexadecimal decoding is needed.
Ben Wagnera512b0f2015-12-14 09:19:52 +01002064
2065 * src/bdf/bdflib.c (_bdf_atoul, _bdf_atol, _bdf_atous,
2066 _bdf_atos): Remove unused code and parameters.
2067 Update all callers.
2068 (odigits): Remove.
2069
Werner Lemberg40992812015-12-14 07:51:25 +010020702015-12-14 Werner Lemberg <wl@gnu.org>
2071
2072 [base] Fix calls to `FT_Stream_Seek'.
2073
2074 * src/base/ftobjs.c (Mac_Read_sfnt_Resource, FT_Open_Face): Set
2075 `error'.
2076
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040020772015-12-14 Ben Wagner <bungeman@gmail.com>
Ben Wagnerf0cc1732015-12-14 07:00:41 +01002078
2079 [base] Check error when seeking to data supplied offset (#46635).
2080
2081 * src/base/ftobjs.c (open_face_PS_from_sfnt_stream):
Alexei Podtelezhnikov500bcbd2016-05-07 22:28:43 -04002082 `ft_lookup_PS_in_sfnt_stream' returns offset and length from
Ben Wagnerf0cc1732015-12-14 07:00:41 +01002083 user supplied data. Use of this these values must be checked.
2084
Werner Lembergd8f9a452015-12-13 15:54:17 +010020852015-12-13 Werner Lemberg <wl@gnu.org>
2086
2087 [autofit] Add support for Myanmar script.
2088
2089 * src/autofit/afblue.dat: Add blue zone data for Myanmar.
2090
2091 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2092
2093 * src/autofit/afscript.h: Add Myanmar standard characters.
2094
2095 * src/autofit/afranges.c: Add Myanmar data.
2096
2097 * src/autofit/afstyles.h: Add Myanmar data.
2098
Werner Lemberg79a42ad2015-12-12 07:27:14 +010020992015-12-12 Werner Lemberg <wl@gnu.org>
2100
Werner Lemberg868d5a02015-12-12 07:28:22 +01002101 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Minor.
2102
21032015-12-12 Werner Lemberg <wl@gnu.org>
2104
Werner Lemberg79a42ad2015-12-12 07:27:14 +01002105 * src/autofit/afscript.h: Avoid potential crash.
2106
Werner Lembergbbe84ed2015-12-10 09:33:41 +010021072015-12-10 Werner Lemberg <wl@gnu.org>
2108
Werner Lemberg4fe3b552015-12-11 08:08:48 +01002109 [autofit] Restore OpenType feature check.
2110
2111 This was removed while rewriting the HarfBuzz interface.
2112
2113 * src/autofit/afglobal.h (AF_FaceGlobalsRec): Add `hb_buf' field to
2114 hold internal HarfBuzz buffer, needed for feature comparison.
2115
2116 * src/autofit/afglobal.c (af_face_globals_new,
2117 af_face_globals_free): Initialize and destroy `hb_buf'.
2118
2119 * src/autofit/afshaper.c (af_shaper_get_cluster): Compare character
2120 (cluster) with and without applied feature.
2121
2122 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Fix tracing
2123 message.
2124
21252015-12-10 Werner Lemberg <wl@gnu.org>
2126
Werner Lembergbbe84ed2015-12-10 09:33:41 +01002127 [autofit] Remove redundant code.
2128
2129 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Do it.
2130
Werner Lembergf02e1df2015-12-09 14:45:30 +010021312015-12-09 Werner Lemberg <wl@gnu.org>
2132
Werner Lembergdd305f32015-12-09 21:00:33 +01002133 [autofit] Thinko.
2134
2135 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Don't count
2136 empty blue zones (bug introduced 2015-12-06).
2137
21382015-12-09 Werner Lemberg <wl@gnu.org>
2139
Werner Lemberg0164d932015-12-09 20:04:18 +01002140 [autofit] Introduce subscript top blue zones.
2141
2142 This feature is mainly for Khmer: The idea is to avoid a clash
2143 between the top of subscript glyphs and the bottom of normal
2144 baseline glyphs.
2145
2146 This only works for character clusters mapped to multiple glyphs.
2147
2148 * src/autofit/afblue.dat: Add subscript top blue zone for Khmer.
2149
2150 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_SUB_TOP): New
2151 macro.
2152
2153 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2154
2155 * src/autofit/aflatin.h (AF_LATIN_IS_SUB_TOP_BLUE,
2156 AF_LATIN_BLUE_SUB_TOP): New macros.
2157
2158 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Handle new
2159 blue zone property.
2160 Update tracing messages.
2161 (af_latin_metrics_scale_dim): Handle new blue zone property.
2162 (af_latin_hints_compute_blue_edges): Updated.
2163
21642015-12-09 Werner Lemberg <wl@gnu.org>
2165
Werner Lembergf02e1df2015-12-09 14:45:30 +01002166 [autofit] Fix tracing message.
2167
2168 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Display
2169 inactive blue zones also.
2170
Werner Lembergf45c0bf2015-12-06 09:58:18 +010021712015-12-06 Werner Lemberg <wl@gnu.org>
2172
Werner Lembergc13526e2015-12-08 09:48:50 +01002173 * src/autofit/afblue.dat: Add more Khmer clusters.
2174
2175 Some fonts have incorrect ligatures; we need more samples to get a
2176 good mean value.
2177
2178 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2179
21802015-12-06 Werner Lemberg <wl@gnu.org>
2181
Werner Lembergb38ca3c2015-12-06 19:48:31 +01002182 [autofit] Typos.
2183
2184 * src/autofit/afshaper.c (af_shaper_buf_create, af_shaper_get_elem)
2185 [!FT_CONFIG_OPTION_USE_HARFBUZZ]: Make it compile.
2186
21872015-12-06 Werner Lemberg <wl@gnu.org>
2188
Werner Lembergfacb79a2015-12-06 19:34:59 +01002189 [autofit] Add support for Khmer script.
2190
2191 We split Khmer into two auto-hinter scripts: `Khmer' (`khmr') and
2192 `Khmer symbols' (`khms', U+19E0-U+19FF).
2193
2194 * src/autofit/afblue.dat: Add blue zone data for Khmer.
2195
2196 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2197
2198 * src/autofit/afscript.h: Add Khmer standard characters.
2199
2200 * src/autofit/afranges.c: Add Khmer data.
2201
2202 * src/autofit/afstyles.h: Add Khmer data.
2203
22042015-12-06 Werner Lemberg <wl@gnu.org>
2205
Werner Lemberg24aa9c62015-12-06 18:52:41 +01002206 [autofit] Rewrite HarfBuzz interface to support character clusters.
2207
2208 Scripts like Khmer have blue zones that can't be directly
2209 represented by Unicode characters. Instead, it is necessary to let
2210 HarfBuzz convert character clusters into proper glyph representation
2211 forms, then deriving the blue zone information from the resulting
2212 glyphs.
2213
2214 * src/autofit/hbshim.c, src/autofit/hbshim.h: Replaced by...
2215 * src/autofit/afshaper.c, src/autofit/afshaper.h: ... these two new
2216 files, providing a new API to access HarfBuzz.
2217
2218 The new API manages a HarfBuzz buffer with `af_shaper_buf_create'
2219 and `af_shaper_buf_destroy'. The buffer receives a UTF8 encoded
2220 string with function `af_shaper_get_cluster', and the resulting
2221 glyph data (indices, advance widths, vertical offsets) can be
2222 iteratively accessed with function `af_shaper_get_elem'.
2223
2224 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
2225 af_cjk_metrics_init_blues, af_cjk_metrics_check_digits): Updated.
2226
2227 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
2228 af_latin_metrics_init_blues, af_latin_metrics_check_digits):
2229 Updated.
2230
2231 * include/freetype/internal/fttrace.h: s/afharfbuzz/afshaper/.
2232
2233 * src/autofit/afglobal.c: s/hbshim.h/afshaper.h/.
2234 (af_face_globals_compute_style_coverage): Updated.
2235
Alexei Podtelezhnikovf46b2822016-04-11 23:22:57 -04002236 * src/autofit/afglobal.h: s/hbshim.h/afshaper.h/.
Werner Lemberg24aa9c62015-12-06 18:52:41 +01002237
2238 * src/autofit/autofit.c: s/hbshim.c/afshaper.c/.
2239
2240 * src/autofit/Jamfile, src/autofit/rules.mk (AUTOF_DRV_SRC):
2241 Updated.
2242
22432015-12-06 Werner Lemberg <wl@gnu.org>
2244
Werner Lembergde599942015-12-06 18:18:02 +01002245 [autofit] Prepare forthcoming changes.
2246
2247 This makes it easier to control the commits.
2248
2249 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Add dummy
2250 loop. No functional change.
2251
22522015-12-06 Werner Lemberg <wl@gnu.org>
2253
Werner Lembergf45c0bf2015-12-06 09:58:18 +01002254 [autofit] Use string of standard characters.
2255
2256 This is more flexible; additionally, it would allow character
2257 clusters.
2258
2259 * src/autofit/aftypes.h (SCRIPT, AF_DEFINE_SCRIPT_CLASS): Updated.
2260 (AF_ScriptClassRec): Replace `standard_char[123]' with
2261 `standard_charstring'.
2262
2263 * src/autofit/afscript.h: Replace last three character arguments
2264 of the `SCRIPT' calls with a string parameter, holding the standard
2265 characters (in UTF-8 encoding) separated with spaces.
2266
2267 * src/autofit/afglobal.c, src/autofit/afglobal.h,
2268 src/autofit/afpic.c, src/autofit/afranges.c, src/autofit/hbshim.c
2269 (SCRIPT): Updated.
2270
2271 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
2272 src/autofit/aflatin.c (af_latin_metrics_init_widths): Updated.
2273
Werner Lemberg53696f02015-12-05 07:44:16 +010022742015-12-05 Werner Lemberg <wl@gnu.org>
2275
Werner Lemberga8a54c32015-12-05 13:26:44 +01002276 * src/autofit/afblue.dat: Separate blue zone characters with spaces.
2277
2278 Another preparation for character cluster support.
2279
2280 * src/autofit/afblue.c, src/autofit.afblue.h: Regenerated.
2281
22822015-12-05 Werner Lemberg <wl@gnu.org>
2283
Werner Lemberg453722d2015-12-05 13:20:30 +01002284 * src/tools/afblue.pl (convert_ascii_chars): Don't ignore spaces.
2285
2286 Instead, reduce multiple spaces to a single one. We need this later
2287 for supporting character clusters in `afblue.dat'.
2288
22892015-12-05 Werner Lemberg <wl@gnu.org>
2290
Werner Lembergf7e6d512015-12-05 13:08:45 +01002291 * src/autofit/afblue.hin (GET_UTF8_CHAR): Use `do...while(0)'.
2292
2293 * src/autofit/afblue.h: Regenerated.
2294
22952015-12-05 Werner Lemberg <wl@gnu.org>
2296
Werner Lemberg53696f02015-12-05 07:44:16 +01002297 * src/autofit/afwarp.c: s/INT_MIN/FT_INT_MIN/.
2298
Werner Lemberga4154732015-12-03 07:49:46 +010022992015-12-03 Werner Lemberg <wl@gnu.org>
2300
2301 * builds/unix/install.mk (install): Remove stale `ft2build.h'.
2302
Werner Lemberg5b05bc62015-12-01 12:09:02 +010023032015-12-01 Werner Lemberg <wl@gnu.org>
2304
2305 [type1] Avoid dangling pointer (#46572).
2306
2307 * src/type1/t1afm.c (T1_Read_Metrics): Properly reset
2308 `face->afm_data'.
2309
Alexei Podtelezhnikovf8c20572015-11-28 22:43:33 -050023102015-11-28 Alexei Podtelezhnikov <apodtele@gmail.com>
2311
2312 * include/freetype/ftlcdfil.h: Documentation tweak.
2313
Werner Lemberg4679bf82015-11-28 19:05:36 +010023142015-11-28 Werner Lemberg <wl@gnu.org>
2315
Werner Lemberg66cf29b2015-11-28 19:08:05 +01002316 * Version 2.6.2 released.
2317 =========================
2318
2319
2320 Tag sources with `VER-2-6-2'.
2321
2322 * docs/VERSION.DLL: Update documentation and bump version number to
2323 2.6.2.
2324
2325 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
2326 builds/windows/vc2005/index.html,
2327 builds/windows/vc2008/freetype.vcproj,
2328 builds/windows/vc2008/index.html,
2329 builds/windows/vc2010/freetype.vcxproj,
2330 builds/windows/vc2010/index.html,
2331 builds/windows/visualc/freetype.dsp,
2332 builds/windows/visualc/freetype.vcproj,
2333 builds/windows/visualc/index.html,
2334 builds/windows/visualce/freetype.dsp,
2335 builds/windows/visualce/freetype.vcproj,
2336 builds/windows/visualce/index.html,
2337 builds/wince/vc2005-ce/freetype.vcproj,
2338 builds/wince/vc2005-ce/index.html,
2339 builds/wince/vc2008-ce/freetype.vcproj,
2340 builds/wince/vc2008-ce/index.html: s/2.6.1/2.6.2/, s/261/262/.
2341
2342 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
2343
2344 * builds/unix/configure.raw (version_info): Set to 18:2:12.
2345 * CMakeLists.txt (VERSION_PATCH): Set to 2.
2346
2347 * docs/CHANGES: Updated.
2348
23492015-11-28 Werner Lemberg <wl@gnu.org>
2350
Werner Lemberg4679bf82015-11-28 19:05:36 +01002351 Fix C++ compilation.
2352
2353 * src/autofit/afloader.c: Include FT_INTERNAL_CALC_H.
2354
2355 * src/truetype/ttgload.c (load_truetype_glyph): Pacify compiler.
2356
Nikolaus Waxweiler01ce1c62015-11-28 12:04:28 +010023572015-11-28 Nikolaus Waxweiler <madigens@gmail.com>
2358
2359 Change default LCD filter to be normalized and color-balanced.
2360
2361 * src/base/ftlcdfil.c (FT_Library_SetLcdFilter): Update
2362 `default_filter'.
2363
Werner Lemberg98afe3f2015-11-28 11:58:49 +010023642015-11-28 Werner Lemberg <wl@gnu.org>
2365
2366 [docmaker] Allow references to section names.
2367
2368 In the reference, we show the section's title enclosed in single
2369 quotes.
2370
2371 * src/tools/docmaker/formatter.py (Formatter::__init__): Collect
2372 section names as identifiers.
2373
2374 * src/tools/docmaker/tohtml.py (section_title_header): Split into...
2375 (section_title_header1, section_title_header2): ... these two
2376 strings.
2377 (HtmlFormatter::make_block_url, make_html_word, html_source_quote):
2378 Handle sections.
2379 (HtmlFormatter::section_enter): Updated to add `id' HTML attribute.
2380
Tamas Kenez4854df62015-11-27 07:04:31 +010023812015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
2382
Tamas Kenez30fdfe62015-11-27 23:16:08 +01002383 [cmake] Add script to test the config module.
2384
2385 * builds/cmake/testbuild.sh: New file.
2386
23872015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
2388
Tamas Kenezc80620c2015-11-27 18:37:21 +01002389 * CMakeLists.txt: Create `freetype-config.cmake' config module.
2390
23912015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
2392
Tamas Kenez9d0544f2015-11-27 18:28:31 +01002393 * CMakeLists.txt: Set CMAKE_DEBUG_POSTFIX to `d'.
2394
23952015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
2396
Tamas Kenezda97b4c2015-11-27 07:11:42 +01002397 [cmake] Add better control of library dependencies.
2398
2399 * CMakeLists.txt: Add `WITH_*' variables to force/auto/omit
2400 ZLIB/BZip2/PNG/HarfBuzz.
2401
24022015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
2403
Alexei Podtelezhnikov6d070342016-06-20 01:09:18 -04002404 [cmake] Make `FindHarfBuzz' observe the REQUIRED option.
Tamas Kenez4854df62015-11-27 07:04:31 +01002405
2406 * builds/cmake/FindHarfBuzz.cmake: Implement it.
2407
Werner Lemberg5b3446b2015-11-27 06:47:13 +010024082015-11-27 Werner Lemberg <wl@gnu.org>
2409
2410 [cmake] Collect files specific to cmake in `builds/cmake'.
2411
2412 * builds/FindHarfBuzz.cmake: Move to ...
2413 * builds/cmake/FindHarfBuzz.cmake: ... this place.
2414
2415 * CMakeLists.txt (CMAKE_MODULE_PATH): Updated.
2416
Alexander Bock8f982b32015-11-27 06:34:39 +010024172015-11-27 Alexander Bock <alexander.j.bock@nasa.gov>
2418
2419 CMakeLists.txt: Honour new command line flag `FREETYPE_NO_DIST'.
2420
Werner Lemberg97b808f2015-11-26 14:29:17 +010024212015-11-26 Werner Lemberg <wl@gnu.org>
2422
2423 [docmaker] Allow `foo[bar]' as identifier.
2424
2425 We need this to handle equally named properties in different
2426 modules.
2427
2428 * src/tools/docmaker/content.py (re_identifier),
2429 src/tools/docmaker/sources.py (re_crossref): Allow `foo[bar]'.
2430
2431 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_html_word,
2432 HtmlFormatter::index_exit, HtmlFormatter::section_enter,
2433 HtmlFormatter::block_enter): Handle `foo[bar]'.
2434
Werner Lemberg4a150132015-11-25 07:53:49 +010024352015-11-25 Werner Lemberg <wl@gnu.org>
2436
2437 * src/bdf/bdflib.c (bdf_load_font): Fix small memory leak (#46480).
2438
2439 (_bdf_parse_glyphs): Always reset `p->glyph_name' after moving its
2440 contents.
2441
Werner Lemberg663f2d72015-11-21 06:30:43 +010024422015-11-21 Werner Lemberg <wl@gnu.org>
2443
2444 * include/freetype/internal/ftcalc.h: Don't use `register' keyword.
2445
2446 This fixes compiler warnings.
2447
2448 Reported by Behdad.
2449
Werner Lembergb96af122015-11-20 16:03:09 +010024502015-11-20 Werner Lemberg <wl@gnu.org>
2451
2452 Add `FT_LCD_FILTER_LEGACY1' enum value.
2453
2454 This does the same as `FT_LCD_FILTER_LEGACY'.
2455
2456 See
2457
2458 https://bugs.freedesktop.org/show_bug.cgi?id=92981
2459
2460 for the reasoning.
2461
2462 * include/freetype/ftlcdfil.h (FT_LcdFilter): New value
2463 `FT_LCD_FILTER_LEGACY1'.
2464
2465 * src/base/ftlcdfil.c (FT_Library_SetLcdFilter): Use it.
2466
Werner Lemberg94cacac2015-11-15 04:45:42 +010024672015-11-15 Werner Lemberg <wl@gnu.org>
2468
Werner Lemberg68fb4782015-11-15 13:06:48 +01002469 * src/autofit/afhints.c (af_get_segment_index): Fix it.
2470
2471 The old code was too simple, returning invalid values in most cases
2472 where a segment crosses the contour start.
2473
24742015-11-15 Werner Lemberg <wl@gnu.org>
2475
Werner Lemberg94cacac2015-11-15 04:45:42 +01002476 * src/bdf/bdflib.c (bdf_load_font): Fix small memory leak (#46439).
2477
Werner Lemberg75722f82015-11-11 09:55:16 +010024782015-11-11 Werner Lemberg <wl@gnu.org>
2479
2480 [cff, autofit] Switch off stem darkening by default.
2481
2482 * src/autofit/afmodule.c (af_autofitter_init), src/cff/cffobjs.c
2483 (cff_driver_init): Do it.
2484
Jan Alexander Steffens (heftig)ccd31882015-11-10 22:33:45 +010024852015-11-10 Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
2486
2487 Allow native CFF hinter in FT_RENDER_MODE_LIGHT.
2488
2489 Both the native CFF hinter and the auto-hinter now have a very
2490 similar rendering style.
2491
2492 * include/freetype/freetype.h: Mention that FT_LOAD_TARGET_LIGHT no
2493 longer implies FT_LOAD_FORCE_AUTOHINT.
2494
2495 * include/freetype/ftmodapi.h (FT_MODULE_DRIVER_HINTS_LIGHTLY): New
2496 macro.
2497
2498 * include/freetype/internal/ftobjs.h (FT_DRIVER_HINTS_LIGHTLY): New
2499 macro.
2500
2501 * src/cff/cffdrivr.c (cff_driver_class): Use it.
2502
2503 * src/base/ftobjs.c (FT_Load_Glyph): Update auto-hinter selection
2504 logic.
2505
Werner Lemberg837285e2015-11-09 09:20:08 +010025062015-11-09 Werner Lemberg <wl@gnu.org>
2507
Werner Lemberg2985e4f2015-11-09 21:37:40 +01002508 * src/cid/cidload.c (cid_face_open): Fix GDBytes guard (#46408).
2509
25102015-11-09 Werner Lemberg <wl@gnu.org>
2511
Werner Lemberg837285e2015-11-09 09:20:08 +01002512 [truetype] Remove integer to pointer conversion compiler warning.
2513
2514 Problem reported by Alexei.
2515
2516 * src/truetype/ttgload.c (load_truetype_glyph): Use a solution found
2517 in the glib library to fix the issue.
2518
Behdad Esfahbodabb33122015-11-08 10:00:34 +010025192015-11-08 Behdad Esfahbod <behdad@behdad.org>
2520
2521 [sfnt] Accept version 3 of `EBLC' and `CBLC' tables also.
2522
2523 * src/sfnt/ttsbit.c (tt_face_load_sbit): Implement it.
2524
25252015-11-08 Philipp Knechtges <philipp-dev@knechtges.com>
Philipp Knechtgesbe32b162015-11-08 08:37:51 +01002526
2527 [autofit] Don't distort (latin) glyphs too much (#46195).
2528
2529 * src/autofit/aflatin.h (AF_LatinBlueRec): Add `ascender' and
2530 `descender' fields.
2531
2532 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Collect
2533 ascender and descender data for blue zones.
2534 (af_latin_metrics_scale_dim): Reject vertical scaling values that
2535 change the result by more than two pixels.
2536
Werner Lemberg0f0a6bb2015-11-05 13:48:11 +010025372015-11-05 Werner Lemberg <wl@gnu.org>
2538
2539 [sfnt] Ignore embedded bitmaps with zero size (#46379).
2540
2541 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bit_aligned): Implement
2542 it.
2543
Werner Lemberg040edaf2015-11-04 07:35:51 +010025442015-11-04 Werner Lemberg <wl@gnu.org>
2545
Werner Lemberg758d55e2015-11-04 11:44:47 +01002546 [truetype] Catch infinite recursion in subglyphs (#46372).
2547
2548 * include/freetype/internal/tttypes.h (TT_LoaderRec): New field
2549 `composites'.
2550
2551 * src/truetype/ttgload.c: Include FT_LIST_H.
2552 (load_truetype_glyph): Add composite subglyph index to a list;
2553 abort if index is already in list.
2554 (tt_loader_init): Updated.
2555 (tt_loader_done): New function.
2556 (TT_Load_Glyph): Call `tt_loader_done'.
2557
25582015-11-04 Werner Lemberg <wl@gnu.org>
2559
Werner Lemberg040edaf2015-11-04 07:35:51 +01002560 [truetype] Better tracing of composite glyphs.
2561
2562 * src/truetype/ttgload.c (TT_Load_Composite_Glyph,
2563 load_truetype_glyph): Implement it.
2564
Werner Lembergaae88082015-11-03 17:30:36 +010025652015-11-03 Werner Lemberg <wl@gnu.org>
2566
2567 [sfnt] Protect against zero-size bitmaps (#46345).
2568
2569 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Check
2570 `glyph_size'.
2571
Nikolaus Waxweilerd682e512015-11-02 09:06:36 +010025722015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
2573
Nikolaus Waxweilerb6fd5bc2015-11-03 10:40:58 +01002574 * src/autofit/afloader.c (af_loader_load_g): Implement emboldening.
2575
25762015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
2577
Nikolaus Waxweilerbf2ba9e2015-11-02 13:12:34 +01002578 [autofit] Implement darkening computation function.
2579
2580 This is a crude adaption of the original `cf2_computeDarkening'
2581 function.
2582
2583 * src/autofit/afloader.c (af_intToFixed, af_fixedToInt,
2584 af_floatToFixed): New macros, taken from `cf2fixed.h'.
2585 (af_loader_compute_darkening): New function.
2586 * src/autofit/afloader.h: Updated.
2587
25882015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
2589
Nikolaus Waxweiler37c401a2015-11-02 09:32:26 +01002590 [autofit] Add functions to get standard widths for writing systems.
2591
2592 We need the computed standard horizontal and vertical widths for the
2593 emboldening calculation. This method provides a convenient way to
2594 extract it from writing-system-specific metrics structures, which
2595 all script definitions must implement.
2596
2597 * src/autofit/aftypes.h (AF_WritingSystem_GetStdWidthsFunc): New
2598 function type.
2599 (AF_WritingSystemClassRec): New member `style_metrics_getstdw'.
2600 (AF_DEFINE_WRITING_SYSTEM_CLASS): Updated.
2601
2602 * src/autofit/afcjk.c (af_cjk_get_standard_width): New function.
2603 (af_cjk_writing_system_class): Updated.
2604 * src/autofit/afdummy.c (af_dummy_writing_system_class): Updated.
2605 * src/autofit/afindic.c (af_cjk_get_standard_width): New function.
2606 (af_indic_writing_system_class): Updated.
2607 * src/autofit/aflatin.c (af_latin_get_standard_width): New function.
2608 (af_indic_writing_system_class): Updated.
2609 * src/autofit/aflatin.c (af_latin_get_standard_width): New function.
2610 (af_indic_writing_system_class): Updated.
2611
26122015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
2613
Nikolaus Waxweilerb2a85ad2015-11-02 09:20:32 +01002614 [autofit] Extend `AF_FaceGlobalsRec' to hold emboldening data.
2615
2616 * src/autofit/afglobal.h (AF_FaceGlobalsRec): Add fields.
2617
2618 * src/autofit/afglobal.c (af_face_globals_new): Initialize new
2619 fields.
2620 (af_face_globals_free): Reset new fields.
2621
26222015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
2623
Nikolaus Waxweilerd682e512015-11-02 09:06:36 +01002624 [autofit] Add stem-darkening properties.
2625
2626 Actual code follows in a later commit.
2627
2628 * include/freetype/ftautoh.h: Document `no-stem-darkening' and
2629 `darkening-parameters'.
2630
2631 * src/autofit/afmodule.h: New fields `no_stem_darkening' and
2632 `darken_params'.
2633
2634 * src/autofit/afmodule.c (af_property_set, af_property_get):
2635 Handle them.
2636 (af_autofitter_init): Initialize them.
2637
Ben Wagnerf0cc1732015-12-14 07:00:41 +010026382015-11-02 Ben Wagner <bungeman@gmail.com>
Werner Lembergbcf618b2015-11-02 06:50:49 +01002639
2640 [ftfuzzer] Add support for multiple files (patch #8779).
2641
2642 Currently, libFuzzer only supports mutation of a single file. We
2643 circumvent this problem by using an uncompressed tar archive as
2644 multiple-file input for the fuzzer.
2645
2646 This patch enables tests of `FT_Attach_Stream' and AFM/PFM parsing;
2647 a constructed tarball should contain a font file as the first
2648 element, and files to be attached as further elements.
2649
2650 * src/tools/ftfuzzer/ftfuzzer.cc: Include libarchive headers.
2651 (archive_read_entry_data, parse_data): New functions.
2652 (LLVMFuzzerTestOneInput): Updated.
2653
2654 * src/tools/ftfuzzer/ftmutator.cc: New file, providing a custom
2655 mutator for libFuzzer that can mutate tarballs in a sensible way.
2656
Werner Lemberg009cc152015-10-31 17:52:56 +010026572015-10-31 Werner Lemberg <wl@gnu.org>
2658
Werner Lemberg57cbb8c2015-10-31 18:47:26 +01002659 [sfnt] Fix cmap 14 validation (#46346).
2660
2661 * src/sfnt/ttcmap.c (tt_cmap14_validate): Check limit before
2662 accessing `numRanges' and `numMappings'.
2663 Fix size check for non-default UVS table.
2664
26652015-10-31 Werner Lemberg <wl@gnu.org>
2666
Werner Lemberg009cc152015-10-31 17:52:56 +01002667 [sfnt] Handle infinite recursion in bitmap strikes (#46344).
2668
2669 * src/sfnt/ttsbit.c (TT_SBitDecoder_LoadFunc,
2670 tt_sbit_decoder_load_bitmap, tt_sbit_decoder_load_byte_aligned,
2671 tt_sbit_decoder_load_bit_aligned, tt_sbit_decoder_load_png): Add
2672 argument for recursion depth.
2673 (tt_sbit_decoder_load_compound): Add argument for recursion depth.
2674 Increase recursion counter for recursive call.
2675 (tt_sbit_decoder_load_image): Add argument for recursion depth.
2676 Check recurse depth.
2677 (tt_face_load_sbit_image): Updated.
2678
Werner Lemberg017db032015-10-29 05:52:09 +010026792015-10-29 Werner Lemberg <wl@gnu.org>
2680
Werner Lemberg02cfd712015-10-29 20:50:57 +01002681 * src/autofit/afhints.c (af_glyph_hints_dump_points): Minor.
2682
26832015-10-29 Werner Lemberg <wl@gnu.org>
2684
Werner Lemberg017db032015-10-29 05:52:09 +01002685 * CMakeLists.txt: Remove code to set MSVC's /FD compiler switch.
2686
2687 Problem reported by David Capello <davidcapello@gmail.com>; see
2688
2689 http://lists.nongnu.org/archive/html/freetype-devel/2015-10/msg00108.html
2690
2691 for details.
2692
Werner Lembergfba29fa2015-10-27 21:04:48 +010026932015-10-27 Werner Lemberg <wl@gnu.org>
2694
2695 [pfr] Add some safety guards (#46302).
2696
2697 * src/pfr/pfrload.h (PFR_CHECK): Rename to...
2698 (PFR_CHECK_SIZE): ... this.
2699 (PFR_SIZE): [!PFR_CONFIG_NO_CHECKS]: Define to PFR_CHECK_SIZE.
2700
Werner Lembergf45c0bf2015-12-06 09:58:18 +01002701 * src/pfr/pfrload.c (pfr_log_font_count): Check `count'.
Werner Lembergfba29fa2015-10-27 21:04:48 +01002702 (pfr_extra_item_load_kerning_pairs): Remove tracing message.
2703 (pfr_phy_font_load): Use PFR_CHECK_SIZE where appropriate.
2704 Allocate `chars' after doing a size checks.
2705
2706 * src/pfr/pfrsbit.c (pfr_load_bitmap_bits): Move test for invalid
2707 bitmap format to...
2708 (pfr_slot_load_bitmap): ... this function.
2709 Check bitmap size.
2710
Werner Lemberg6a19a7d2015-10-26 15:40:22 +010027112015-10-26 Werner Lemberg <wl@gnu.org>
2712
2713 [truetype] Fix sanitizing logic for `loca' (#46223).
2714
2715 * src/truetype/ttpload.c (tt_face_load_loca): A thinko caused an
2716 incorrect adjustment of the number of glyphs, most often using far
2717 too large values.
2718
Werner Lemberg7f00fa62015-10-25 10:59:59 +010027192015-10-25 Werner Lemberg <wl@gnu.org>
2720
2721 [autofit] Improve tracing.
2722
2723 * src/autofit/afhints.c (af_print_idx, af_get_segment_index,
2724 af_get_edge_index): New functions.
2725
2726 (af_glyph_hints_dump_points): Remove unnecessary `|', `[', and `]'.
2727 Add segment and edge index for each point.
2728 Slightly change printing order of some elements.
2729 Don't print `-1' but `--' for missing elements.
2730
2731 (af_glyph_hints_dump_segments, af_glyph_hints_dump_edges): Remove
2732 unnecessary `|', `[', and `]'.
2733 Don't print `-1' but `--' for missing elements.
2734
Werner Lemberg6f090112015-10-24 10:10:22 +020027352015-10-24 Werner Lemberg <wl@gnu.org>
2736
2737 [sfnt] Sanitize bitmap strike glyph height.
2738
2739 Problem reported by Nikolay Sivov <bunglehead@gmail.com>.
2740
2741 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Avoid zero value
2742 for `metrics->height' by applying some heuristics.
2743
Werner Lemberge93d3262015-10-22 10:17:20 +020027442015-10-22 Werner Lemberg <wl@gnu.org>
2745
2746 [sfnt, type42] Fix clang compiler warnings.
2747
2748 * src/sfnt/sfobjs.c (sfnt_init_face): Initialize `offset'.
2749
2750 * src/type42/t42parse.c (t42_parse_sfnts): Use proper cast.
2751
Werner Lembergf1c93432015-10-22 10:11:23 +020027522015-10-22 Dave Arnold <darnold@adobe.com>
2753 Werner Lemberg <wl@gnu.org>
2754
2755 [cff] Avoid overflow/module arithmetic.
2756
2757 This modifies the addition of subroutine number to subroutine bias
2758 from unsigned to signed, but does not change any results.
2759
2760 * src/cff/cf2ft.c (cf2_initGlobalRegionBuffer,
2761 cf2_initLocalRegionBuffer): Change variable names from (unsigned)
2762 `idx' to (signed) `subrNum', since it is not an index until after
2763 the bias is added.
2764 * src/cff/cf2ft.h: Updated.
2765
2766 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdCALLSUBR>:
2767 Updated similarly.
2768
Werner Lemberg59ae73f2015-10-22 09:26:00 +020027692015-10-22 Werner Lemberg <wl@gnu.org>
2770
2771 [cid] Better check of `SubrCount' dictionary entry (#46272).
2772
2773 * src/cid/cidload.c (cid_face_open): Add more sanity tests for
2774 `fd_bytes', `gd_bytes', `sd_bytes', and `num_subrs'.
2775
Werner Lemberg87fefc52015-10-21 20:29:12 +020027762015-10-21 Werner Lemberg <wl@gnu.org>
2777
Werner Lemberge484d362015-10-21 20:48:27 +02002778 [base] Pacify compiler (#46266).
2779
2780 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Initialize `in' and
2781 `anchor'.
2782
27832015-10-21 Werner Lemberg <wl@gnu.org>
2784
Werner Lemberg87fefc52015-10-21 20:29:12 +02002785 [type42] Fix heap buffer overflow (#46269).
2786
2787 * src/type42/t42parse.c (t42_parse_sfnts): Fix off-by-one error in
2788 bounds checking.
2789
Dave Arnold748e3682015-10-21 13:58:43 +020027902015-10-21 Dave Arnold <darnold@adobe.com>
2791
Dave Arnold3cfd5122015-10-21 14:07:25 +02002792 [cff] Fix limit in assert for max hints.
2793
2794 * src/cff/cf2interp.c (cf2_hintmask_setAll): Allow mask equal to the
2795 limit (96 bits).
2796
27972015-10-21 Dave Arnold <darnold@adobe.com>
2798
Dave Arnold748e3682015-10-21 13:58:43 +02002799 [cff] Remove an assert (#46107).
2800
2801 * src/cff/cf2hints.c (cf2_hintmap_insertHint): Ignore paired edges
2802 in wrong order.
2803
Werner Lemberg649ca552015-10-21 07:01:45 +020028042015-10-21 Werner Lemberg <wl@gnu.org>
2805
Werner Lemberge6593382015-10-21 08:04:29 +02002806 [sfnt] Avoid unnecessarily large allocation for WOFFs (#46257).
2807
2808 * src/sfnt/sfobjs.c (woff_open_font): Use WOFF's `totalSfntSize'
2809 only after thorough checks.
2810 Add tracing messages.
2811
28122015-10-21 Werner Lemberg <wl@gnu.org>
2813
Werner Lemberg649ca552015-10-21 07:01:45 +02002814 [type42] Better check invalid `sfnts' array data (#46255).
2815
2816 * src/type42/t42parse.c (t42_parse_sfnts): Table lengths must be
2817 checked individually against available data size.
2818
Werner Lembergd47d3722015-10-20 12:24:36 +020028192015-10-20 Werner Lemberg <wl@gnu.org>
2820
Werner Lemberg3eccc3a2015-10-20 22:31:57 +02002821 [cid] Add a bunch of safety checks.
2822
2823 * src/cid/cidload.c (parse_fd_array): Check `num_dicts' against
2824 stream size.
2825 (cid_read_subrs): Check largest offset against stream size.
2826 (cid_parse_dict): Move safety check to ...
2827 (cid_face_open): ... this function.
2828 Also test length of binary data and values of `SDBytes',
2829 `SubrMapOffset', `SubrCount', `CIDMapOffset', and `CIDCount'.
2830
28312015-10-20 Werner Lemberg <wl@gnu.org>
2832
Werner Lembergd47d3722015-10-20 12:24:36 +02002833 [cid] Avoid segfault with malformed input (#46250).
2834
2835 * src/cid/cidload.c (cid_read_subrs): Return a proper error code for
2836 unsorted offsets.
2837
StudioEtrange5cf83a52015-10-20 07:19:44 +020028382015-10-20 StudioEtrange <nomorgan@gmail.com>
2839
2840 * CMakeLists.txt: Enable shared library builds on MinGW (#46233).
2841
Werner Lemberg3c582062015-10-20 06:57:28 +020028422015-10-20 Werner Lemberg <wl@gnu.org>
2843
2844 * src/type1/t1afm.c (T1_Read_Metrics): Fix memory leak (#46229).
2845
Ben Wagnerf0cc1732015-12-14 07:00:41 +010028462015-10-19 Ben Wagner <bungeman@gmail.com>
Bungemanba8a5282015-10-19 23:27:06 +02002847
2848 [cid] Better handle invalid glyph stream offsets (#46221).
2849
2850 * src/cid/cidgload.c (cid_load_glyph): Check minimum size of glyph
2851 length.
2852
Werner Lembergdcfc4d92015-10-18 16:47:06 +020028532015-10-18 Werner Lemberg <wl@gnu.org>
2854
Werner Lemberg24cee3a2015-10-19 23:00:28 +02002855 [psaux] Fix tracing of negative numbers.
2856
2857 Due to incorrect casting negative numbers were shown as very large
2858 (positive) integers on 64bit systems.
2859
2860 * src/psaux/t1decode.c (t1_decoder_parse_charstrings) <op_none>:
2861 Use division instead of shift.
2862
28632015-10-18 Werner Lemberg <wl@gnu.org>
2864
Werner Lemberg14213b52015-10-18 18:15:04 +02002865 [truetype] Improve TT_CONFIG_OPTION_MAX_RUNNABLE_OPCODES (#46223).
2866
2867 * devel/ftoption.h, include/freetype/config/ftoption.h: Surround it
2868 with #ifndef ... #endif, as suggested in the tracker issue.
2869
28702015-10-18 Werner Lemberg <wl@gnu.org>
2871
Werner Lembergdcfc4d92015-10-18 16:47:06 +02002872 [truetype] Better protection against malformed `fpgm' (#46223).
2873
2874 * src/truetype/ttobjs.c (tt_size_init_bytecode): Don't execute a
2875 malformed `fpgm' table more than once.
2876
Werner Lemberg8edfcbe2015-10-17 08:11:16 +020028772015-10-17 Werner Lemberg <wl@gnu.org>
2878
Werner Lemberg7643b582015-10-17 15:51:29 +02002879 * src/cid/cidgload.c (cid_load_glyph): Fix memory leak.
2880
2881 Reported by Kostya Serebryany <kcc@google.com>.
2882
28832015-10-17 Werner Lemberg <wl@gnu.org>
2884
Werner Lembergb1857472015-10-17 14:21:41 +02002885 [bdf] Prevent memory leak (#46217).
2886
2887 * src/bdf/bdflib.c (_bdf_parse_glyphs) <STARTCHAR>: Check
2888 _BDF_GLYPH_BITS.
2889
28902015-10-17 Werner Lemberg <wl@gnu.org>
2891
Werner Lemberge1ca18d2015-10-17 11:51:27 +02002892 [bdf] Use stream size to adjust number of glyphs.
2893
2894 * src/bdf/bdflib.c (ACMSG17): New message macro.
2895 (_bdf_parse_t): Add member `size'.
2896 (bdf_load_font): Set `size'.
2897 (_bdf_parse_glyphs): Adjust `cnt' if necessary.
2898
28992015-10-17 Werner Lemberg <wl@gnu.org>
2900
Werner Lemberg0af21dc2015-10-17 09:29:52 +02002901 * src/cid/cidload.c (cid_parse_dict): Check `[FG]DBytes' size.
2902
29032015-10-17 Werner Lemberg <wl@gnu.org>
2904
Werner Lemberg0ba98da2015-10-17 09:11:02 +02002905 * src/cid/cidgload.c (cid_glyph_load): Check file offsets (#46222).
2906
29072015-10-17 Werner Lemberg <wl@gnu.org>
2908
Werner Lemberg8edfcbe2015-10-17 08:11:16 +02002909 [psaux] Fix heap buffer overflow (#46221).
2910
2911 * src/psaux/t1decode.c (t1_decoder_parse_charstring) <operator 12>:
2912 Fix limit check.
2913
29142015-10-17 Werner Lemberg <wl@gnu.org>
Werner Lemberga5ecfb42015-10-17 06:15:55 +02002915
2916 * src/cid/cidload.c (cid_parse_dict): Handle invalid input (#46220).
2917
29182015-10-15 Kostya Serebryany <kcc@google.com>
Kostya Serebryany266976b2015-10-15 22:15:53 -07002919
2920 [ftfuzzer] Add README.
2921
2922 * src/tools/ftfuzzer/README: New file.
2923
Ben Wagnerf0cc1732015-12-14 07:00:41 +010029242015-10-15 Ben Wagner <bungeman@gmail.com>
Bungeman65d89802015-10-15 23:50:16 +02002925
2926 [bdf] Fix memory leak (#46213).
2927
2928 * src/bdf/bdflib.c (bdf_load_font): Always go to label `Fail' in
2929 case of error.
2930
Werner Lemberg837ad9d2015-10-15 21:15:45 +020029312015-10-15 Werner Lemberg <wl@gnu.org>
2932
Werner Lemberg24a1fcd2015-10-15 21:50:15 +02002933 [truetype] Add TT_CONFIG_OPTION_MAX_RUNNABLE_OPCODES (#46208).
2934
2935 * devel/ftoption.h, include/freetype/config/ftoption.h
2936 (TT_CONFIG_OPTION_MAX_RUNNABLE_OPCODES): New configuration macro.
2937
2938 * src/truetype/ttinterp.c (MAX_RUNNABLE_OPCODES): Removed.
2939 (TT_RunIns): Updated.
2940
29412015-10-15 Werner Lemberg <wl@gnu.org>
2942
Werner Lemberg837ad9d2015-10-15 21:15:45 +02002943 * src/truetype/ttinterp.c (TT_RunIns): Fix bytecode stack tracing.
2944
2945 The used indices were off by 1.
2946
Ben Wagnerf0cc1732015-12-14 07:00:41 +010029472015-10-15 Ben Wagner <bungeman@gmail.com>
Werner Lemberg8b76eaf2015-10-15 18:28:43 +02002948 Werner Lemberg <wl@gnu.org>
2949
2950 * src/tools/ftfuzzer/ftfuzzer.cc: Handle fixed sizes (#46211).
2951
Werner Lemberge03214e2015-10-15 16:58:13 +020029522015-10-15 Werner Lemberg <wl@gnu.org>
2953
2954 [base] Compute MD5 checksums only if explicitly requested.
2955
2956 This improves profiling accuracy.
2957
2958 * src/base/ftobjs.c (FT_Render_Glyph_Internal): Implement it.
2959
Werner Lemberg2a20c922015-10-14 15:23:15 +020029602015-10-14 Werner Lemberg <wl@gnu.org>
2961
2962 [base] Use `FT_' namespace for MD5 functions (#42366).
2963
2964 * src/base/ftobjs.c (MD5_*): Define as `FT_MD5_*'.
2965 Undefine HAVE_OPENSSL.
2966
Werner Lembergf96094e2015-10-13 07:13:56 +020029672015-10-13 Werner Lemberg <wl@gnu.org>
2968
Werner Lemberg85399152015-10-13 20:43:19 +02002969 [type1] Correctly handle missing MM axis names (#46202).
2970
2971 * src/type1/t1load.c (T1_Get_MM_Var): Implement it.
2972
29732015-10-13 Werner Lemberg <wl@gnu.org>
2974
Werner Lemberg58b61b62015-10-13 18:26:18 +02002975 [pcf] Quickly exit if font index < 0.
2976
2977 Similar to other font formats, this commit makes the parser no
2978 longer check the whole PCF file but only the header and the TOC if
2979 we just want to get the number of available faces (and a proper
2980 recognition of the font format).
2981
2982 * src/pcf/pcfdrivr.c (PCF_Face_Init): Updated.
2983 Exit quickly if face_index < 0.
2984
2985 * src/pcfread.c (pcf_load_font): Add `face_index' argument.
2986 Exit quickly if face_index < 0.
2987
2988 * src/pcf/pcf.h: Updated.
2989
29902015-10-13 Werner Lemberg <wl@gnu.org>
2991
Werner Lembergbdb56bb2015-10-13 11:51:13 +02002992 [ftfuzzer] Handle TTCs and MM/GX variations.
2993
2994 This patch also contains various other improvements.
2995
2996 * src/tools/ftfuzzer/ftfuzzer.cc: Add preprocessor guard to reject
2997 pre-C++11 compilers.
2998 (FT_Global): New class. Use it to provide a global constructor and
2999 destructor for the `FT_Library' object.
3000 (setIntermediateAxis): New function to select an (arbitrary)
3001 instance.
3002 (LLVMFuzzerTestOneInput): Loop over all faces and named instances.
3003 Also call `FT_Set_Char_Size'.
3004
30052015-10-13 Werner Lemberg <wl@gnu.org>
3006
Werner Lemberg43a96eb2015-10-13 11:18:55 +02003007 [truetype] Refine some GX sanity tests.
3008
3009 Use the `gvar' table size instead of the remaining bytes in the
3010 stream.
3011
3012 * src/truetype/ttgxvar.h (GX_BlendRec): New field `gvar_size'.
3013
3014 * src/truetype/ttgxvar.c (ft_var_load_gvar): Set `gvar_size'.
3015 (ft_var_readpackedpoints, ft_var_readpackeddeltas: New argument
3016 `size'.
3017 (tt_face_vary_cvt, TT_Vary_Apply_Glyph_Deltas): Updated.
3018
30192015-10-13 Werner Lemberg <wl@gnu.org>
3020
Werner Lemberg052f6c52015-10-13 08:24:32 +02003021 [truetype] Another GX sanity test.
3022
3023 * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Check
3024 `tupleCount'.
3025 Add tracing message.
3026
30272015-10-13 Werner Lemberg <wl@gnu.org>
3028
Werner Lemberg7ef0d862015-10-13 08:14:20 +02003029 [truetype] Fix memory leak for broken GX fonts (#46188).
3030
3031 * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Fix scope of
3032 deallocation.
3033
30342015-10-13 Werner Lemberg <wl@gnu.org>
3035
Werner Lembergf96094e2015-10-13 07:13:56 +02003036 [truetype] Fix commit from 2015-10-10.
3037
3038 * src/truetype/ttgxvar.c (ft_var_load_gvar): Add missing error
3039 handling body to condition.
3040
Werner Lembergb9880aa2015-10-12 10:13:26 +020030412015-10-12 Werner Lemberg <wl@gnu.org>
3042
3043 [unix] Make MKDIR_P actually work.
3044
3045 * builds/unix/configure.raw: Fix underquoting of `INSTALL' and
3046 `MKDIR_P'.
3047
3048 Problem reported by Dan Liddell <lddll@yahoo.com>.
3049
Werner Lemberg4f7f6f62015-10-11 07:55:25 +020030502015-10-11 Werner Lemberg <wl@gnu.org>
3051
3052 [sfnt] Improve extraction of number of named instances.
3053
3054 * src/sfnt/sfobjs.c (sfnt_init_face)
3055 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Check number of instances against
3056 `fvar' table size.
3057
Alexei Podtelezhnikovc14ae9c2015-10-10 22:28:26 -040030582015-10-10 Alexei Podtelezhnikov <apodtele@gmail.com>
3059
3060 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Fix overflow
3061 (#46149).
3062
Werner Lembergd353f6e2015-10-10 06:54:46 +020030632015-10-10 Werner Lemberg <wl@gnu.org>
3064
Werner Lemberg8de39a72015-10-10 13:34:11 +02003065 [sfnt] Fix infinite loops with broken cmaps (#46167).
3066
3067 * src/sfnt/ttcmap.c (tt_cmap8_char_next, tt_cmap12_next): Take care
Werner Lemberga724dcf2015-10-11 05:50:07 +02003068 of border conditions (i.e., if the loops exit naturally).
Werner Lemberg8de39a72015-10-10 13:34:11 +02003069
30702015-10-10 Werner Lemberg <wl@gnu.org>
3071
Werner Lembergda346732015-10-10 10:21:27 +02003072 [truetype] More sanity tests for GX handling.
3073
3074 These tests should mainly help avoid unnecessarily large memory
3075 allocations in case of malformed fonts.
3076
3077 * src/truetype/ttgxvar.c (ft_var_readpackedpoints,
3078 ft_var_readpackeddeltas): Check number of points against stream
3079 size.
3080 (ft_var_load_avar): Check `pairCount' against table length.
3081 (ft_var_load_gvar): Check `globalCoordCount' and `glyphCount'
3082 against table length.
3083 (tt_face_vary_cvt): Check `tupleCount' and `offsetToData'.
3084 Fix trace.
3085 (TT_Vary_Apply_Glyph_Deltas): Fix trace.
3086 Free `sharedpoints' to avoid memory leak.
3087
30882015-10-10 Werner Lemberg <wl@gnu.org>
3089
Werner Lembergc220d8b2015-10-10 08:13:04 +02003090 [truetype] Better protection against malformed GX data (#46166).
3091
3092 * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Correctly
3093 handle empty `localpoints' array.
3094
30952015-10-10 Werner Lemberg <wl@gnu.org>
3096
Werner Lembergd353f6e2015-10-10 06:54:46 +02003097 * src/pcf/pcfread.c (pcf_read_TOC): Check stream size (#46162).
3098
Werner Lembergc12956e2015-10-09 09:38:32 +020030992015-10-09 Werner Lemberg <wl@gnu.org>
3100
3101 * src/gzip/ftgzip.c (FT_Stream_OpenGzip): Use real stream size.
3102
Werner Lemberg12112242015-10-08 08:55:15 +020031032015-10-08 Werner Lemberg <wl@gnu.org>
3104
Werner Lembergd98053c2015-10-08 23:17:41 +02003105 [pcf] Protect against invalid number of TOC entries (#46159).
3106
3107 * src/pcf/pcfread.c (pcf_read_TOC): Check number of TOC entries
3108 against size of data stream.
3109
31102015-10-08 Werner Lemberg <wl@gnu.org>
3111
Werner Lemberg06c2d332015-10-08 21:31:57 +02003112 [type42] Protect against invalid number of glyphs (#46159).
3113
3114 * src/type42/t42parse.c (t42_parse_charstrings): Check number of
3115 `CharStrings' dictionary entries against size of data stream.
3116
31172015-10-08 Werner Lemberg <wl@gnu.org>
3118
Werner Lemberg983b00e2015-10-08 18:44:45 +02003119 [sfnt] Fix some signed overflows (#46149).
3120
3121 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
3122 <TT_SBIT_TABLE_TYPE_SBIX>: Use `FT_MulDiv'.
3123
31242015-10-08 Werner Lemberg <wl@gnu.org>
3125
Werner Lemberg12112242015-10-08 08:55:15 +02003126 [type1] Protect against invalid number of subroutines (#46150).
3127
3128 * src/type1/t1load.c (parse_subrs): Check number of
3129 `Subrs' dictionary entries against size of data stream.
3130
Kostya Serebryanydde84f22015-10-07 22:18:22 +020031312015-10-07 Kostya Serebryany <kcc@google.com>
3132
3133 [ftfuzzer] Add support for LLVM's LibFuzzer.
3134
3135 * src/tools/ftfuzzer/ftfuzzer.cc, src/tools/runinput.cc: New files.
3136
Alexei Podtelezhnikovc14ae9c2015-10-10 22:28:26 -040031372015-10-06 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov6eb61582015-10-06 22:39:54 -04003138
3139 [smooth] Faster alternative line renderer.
3140
3141 This implementation renders the entire line segment at once without
3142 subdividing it into scanlines. The main speed improvement comes from
3143 reducing the number of divisions to just two per line segment, which
3144 is a bare minimum to calculate cell coverage in a smooth rasterizer.
3145 Notably, the progression from cell to cell does not itself require any
3146 divisions at all. The speed improvement is more noticeable at larger
3147 sizes.
3148
3149 * src/smooth/ftgrays.c (gray_render_line): New implementation.
3150
Werner Lemberg066a4912015-10-06 07:55:32 +020031512015-10-06 Werner Lemberg <wl@gnu.org>
3152
3153 [cff] Return correct PS names from pure CFF (#46130).
3154
3155 * src/cff/cffdrivr.c (cff_get_ps_name): Use SFNT service only for
3156 SFNT.
3157
Werner Lemberg8cabd912015-10-04 08:18:01 +020031582015-10-04 Werner Lemberg <wl@gnu.org>
3159
Werner Lemberg30fe5e72015-10-04 13:08:08 +02003160 [base] Replace left shifts with multiplication (#46118).
3161
3162 * src/base/ftglyph.c (ft_bitmap_glyph_bbox, FT_Get_Glyph): Do it.
3163
31642015-10-04 Werner Lemberg <wl@gnu.org>
3165
Werner Lemberg8cabd912015-10-04 08:18:01 +02003166 * Version 2.6.1 released.
3167 =========================
3168
3169
3170 Tag sources with `VER-2-6-1'.
3171
3172 * docs/VERSION.DLL: Update documentation and bump version number to
3173 2.6.1.
3174
3175 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
3176 builds/windows/vc2005/index.html,
3177 builds/windows/vc2008/freetype.vcproj,
3178 builds/windows/vc2008/index.html,
3179 builds/windows/vc2010/freetype.vcxproj,
3180 builds/windows/vc2010/index.html,
3181 builds/windows/visualc/freetype.dsp,
3182 builds/windows/visualc/freetype.vcproj,
3183 builds/windows/visualc/index.html,
3184 builds/windows/visualce/freetype.dsp,
3185 builds/windows/visualce/freetype.vcproj,
3186 builds/windows/visualce/index.html,
3187 builds/wince/vc2005-ce/freetype.vcproj,
3188 builds/wince/vc2005-ce/index.html,
3189 builds/wince/vc2008-ce/freetype.vcproj,
3190 builds/wince/vc2008-ce/index.html: s/2.6/2.6.1/, s/26/261/.
3191
3192 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
3193
3194 * builds/unix/configure.raw (version_info): Set to 18:1:12.
3195 * CMakeLists.txt (VERSION_PATCH): Set to 1.
3196
3197 * src/autofit/afmodule.c [AF_DEBUG_AUTOFIT]: Ensure C linking for
3198 dumping functions.
3199
32002015-10-04 Werner Lemberg <wl@gnu.org>
Werner Lemberg53838ce2015-10-03 21:12:25 +02003201
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04003202 [bzip2, gzip] Avoid access of uninitialized memory (#46109).
Werner Lemberg53838ce2015-10-03 21:12:25 +02003203
Werner Lembergb260dc92015-10-04 07:39:22 +02003204 * src/bzip2/ftbzip2.c (ft_bzip2_file_fill_input), src/gzip/ftgzip.c
3205 (ft_gzip_file_fill_input): In case of an error, adjust the limit to
3206 avoid copying uninitialized memory.
3207
32082015-10-03 Werner Lemberg <wl@gnu.org>
3209
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04003210 [bzip2, gzip] Avoid access of uninitialized memory (#46109).
Werner Lembergb260dc92015-10-04 07:39:22 +02003211
Werner Lemberg53838ce2015-10-03 21:12:25 +02003212 * src/bzip2/ftbzip2.c (ft_bzip2_file_fill_output), src/gzip/ftgzip.c
3213 (ft_gzip_file_fill_output): In case of an error, adjust the limit to
3214 avoid copying uninitialized memory.
3215
Alexei Podtelezhnikove2dae8f2015-10-01 22:03:34 -040032162015-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
3217
3218 [smooth] Clean up worker.
3219
3220 * src/smooth/ftgrays.c (gray_TWorker): Remove never used fields.
3221
Werner Lemberg5f8f44d2015-10-01 14:16:03 +020032222015-10-01 Werner Lemberg <wl@gnu.org>
3223
Werner Lemberg90e437e2015-10-01 20:00:27 +02003224 [sfnt] Make `tt_cmap4_char_map_linear' more robust (#46078).
3225
3226 * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Take care of
3227 border conditions (i.e., if the loop exits naturally).
3228
32292015-10-01 Werner Lemberg <wl@gnu.org>
3230
Werner Lembergfab67b82015-10-01 16:47:05 +02003231 * src/autofit/afranges.c (af_deva_nonbase_uniranges): Fix ranges.
3232 They should be a subset of `af_deva_uniranges'.
3233
32342015-10-01 Werner Lemberg <wl@gnu.org>
3235
Werner Lemberg5f8f44d2015-10-01 14:16:03 +02003236 [sfnt] Make `tt_cmap4_char_map_linear' faster (#46078).
3237
3238 * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Use inner loop to
3239 reject too large glyph indices.
3240
Alexei Podtelezhnikov8bbcfb22015-09-30 23:08:53 -040032412015-09-30 Alexei Podtelezhnikov <apodtele@gmail.com>
3242
3243 [smooth] Clean up worker.
3244
3245 * src/smooth/ftgrays.c (gray_TWorker): Remove lightly used `last_ey'.
3246 (gray_start_cell, gray_render_line): Update.
3247
Werner Lemberg8651f372015-09-30 10:26:10 +020032482015-09-30 Werner Lemberg <wl@gnu.org>
3249
Werner Lembergdbd04262015-09-30 17:52:42 +02003250 [autofit] Replace `no-base' with `non-base'.
3251
3252 * src/autofit/*: Do it.
3253
32542015-09-30 Werner Lemberg <wl@gnu.org>
3255
Werner Lemberg2ff83a52015-09-30 14:44:29 +02003256 [sfnt] Rewrite `tt_cmap4_char_map_linear' (#46078).
3257
3258 * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Add code to better
3259 skip invalid segments.
3260 If searching the next character, provide a more efficient logic to
3261 speed up the code.
3262
32632015-09-30 Werner Lemberg <wl@gnu.org>
3264
Werner Lemberg8651f372015-09-30 10:26:10 +02003265 [truetype] Adjust number of glyphs for malformed `loca' tables.
3266
3267 * src/truetype/ttpload.c (tt_face_load_loca): Implement it.
3268
Werner Lemberg483007f2015-09-29 11:22:15 +020032692015-09-29 Werner Lemberg <wl@gnu.org>
3270
3271 [pshinter] Avoid harmless overflow (#45984).
3272
3273 * src/pshinter/pshglob.c (psh_blues_set_zones): Fix it.
3274
Werner Lemberga3046562015-09-28 09:45:56 +020032752015-09-28 Werner Lemberg <wl@gnu.org>
3276
3277 [autofit] Add support for Lao script.
3278
3279 Thanks to Danh Hong <danhhong@gmail.com> for guidance with blue zone
3280 characters!
3281
3282 * src/autofit/afblue.dat: Add blue zone data for Lao.
3283
3284 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
3285
3286 * src/autofit/afscript.h: Add Lao standard characters.
3287
3288 * src/autofit/afranges.c: Add Lao data.
3289
3290 * src/autofit/afstyles.h: Add Lao data.
3291
suzuki toshiya8a05d252015-09-28 01:40:21 +090032922015-09-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
Werner Lembergf45c0bf2015-12-06 09:58:18 +01003293
suzuki toshiyafb5268c2015-09-28 02:01:43 +09003294 [base] Fix a leak by broken sfnt-PS or resource fork (#46028).
3295
3296 open_face_from_buffer() frees passed buffer if valid font
3297 is not found. But if copying to the buffer is failed,
3298 the allocated buffer should be freed within the caller.
3299
3300 * src/base/ftobjs.c (open_face_PS_from_sfnt_stream): Free
3301 the buffer `sfnt_ps' if an error caused before calling
3302 open_face_from_buffer().
3303 (Mac_Read_sfnt_Resource): Free the buffer `sfnt_data' if
3304 an error caused before calling open_face_from_buffer();
3305
33062015-09-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
suzuki toshiya8a05d252015-09-28 01:40:21 +09003307
3308 [mac] Fix buffer size calculation for LWFN font.
3309
3310 * src/base/ftmac.c (read_lwfn): Cast post_size to FT_ULong
3311 to prevent confused copy by too large chunk size.
3312
Alexei Podtelezhnikov3dffe8e2015-09-27 11:30:17 -040033132015-09-26 Alexei Podtelezhnikov <apodtele@gmail.com>
3314
3315 * src/smooth/ftgrays.c (PIXEL_MASK): Remove unused macro.
3316
Werner Lemberg41877532015-09-26 15:19:54 +020033172015-09-26 Werner Lemberg <wl@gnu.org>
3318
Werner Lemberg19188a92015-09-26 16:57:17 +02003319 [autofit] Minor tracing improvement.
3320
3321 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Don't emit
3322 blue zones header line if there are no blue zones.
3323
33242015-09-26 Werner Lemberg <wl@gnu.org>
3325
Werner Lemberg41877532015-09-26 15:19:54 +02003326 [bzip2, gzip, lzw] Harmonize function signatures with prototype.
3327
3328 Suggested by Hin-Tak Leung.
3329
3330 * src/bzip2/ftbzip2.c (ft_bzip2_stream_io), src/gzip/ftgzip.c
3331 (ft_gzip_stream_io), src/lzw/ftlzw.c (ft_lzw_stream_io): Do it.
3332
Hin-Tak Leung265ade82015-09-26 14:51:30 +020033332015-09-26 Hin-Tak Leung <htl10@users.sourceforge.net>
3334
3335 Add new FT_LOAD_COMPUTE_METRICS load flag.
3336
3337 * include/freetype/freetype.h (FT_LOAD_COMPUTE_METRICS): New macro.
3338 * src/truetype/ttgload.c (compute_glyph_metrics): Usage.
3339
Werner Lembergd57f2272015-09-26 08:44:26 +020033402015-09-26 Werner Lemberg <wl@gnu.org>
3341
3342 * src/base/ftobjs.c (Mac_Read_sfnt_Resource): Add cast.
3343
Werner Lemberg2439c512015-09-25 16:54:28 +020033442015-09-25 Werner Lemberg <wl@gnu.org>
3345
3346 [type1] Protect against invalid number of glyphs (#46029).
3347
3348 * src/type1/t1load.c (parse_charstrings): Check number of
3349 `CharStrings' dictionary entries against size of data stream.
3350
Werner Lembergc409eb12015-09-24 12:39:38 +020033512015-09-23 Werner Lemberg <wl@gnu.org>
3352
Werner Lemberg5339c752015-09-24 13:39:44 +02003353 [sfnt] Better checks for invalid cmaps (2/2) (#46019).
3354
3355 While the current code in `FT_Get_Next_Char' correctly rejects
3356 out-of-bounds glyph indices, it can be extremely slow for malformed
3357 cmaps that use 32bit values. This commit tries to improve that.
3358
3359 * src/sfnt/ttcmap.c (tt_cmap8_char_next, tt_cmap12_next,
3360 tt_cmap12_char_map_binary, tt_cmap13_next,
3361 tt_cmap13_char_map_binary): Reject glyph indices larger than or
3362 equal to the number of glyphs.
3363
33642015-09-23 Werner Lemberg <wl@gnu.org>
3365
Werner Lembergc409eb12015-09-24 12:39:38 +02003366 [base, sfnt] Better checks for invalid cmaps (1/2).
3367
3368 * src/base/ftobjs.c (FT_Get_Char_Index): Don't return out-of-bounds
3369 glyph indices.
3370 (FT_Get_First_Char): Updated.
3371
3372 * src/sfnt/ttcmap.c (tt_cmap6_char_next): Don't return character
3373 codes greater than 0xFFFF.
3374
3375 (tt_cmap8_char_index): Avoid integer overflow in computation of
3376 glyph index.
3377 (tt_cmap8_char_next): Avoid integer overflows in computation of
3378 both next character code and glyph index.
3379
3380 (tt_cmap10_char_index): Fix unsigned integer logic.
3381 (tt_cmap10_char_next): Avoid integer overflow in computation of
3382 next character code.
3383
3384 (tt_cmap12_next): Avoid integer overflows in computation of both
3385 next character code and glyph index.
3386 (tt_cmap12_char_map_binary): Ditto.
3387 (tt_cmap12_char_next): Simplify.
3388
3389 (tt_cmap13_char_map_binary): Avoid integer overflow in computation
3390 of next character code.
3391 (tt_cmap13_char_next): Simplify.
3392
suzuki toshiyae982f5b2015-09-21 23:07:22 +090033932015-09-21 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3394
Werner Lembergd7f456e2015-09-26 08:37:14 +02003395 [base] Check too long POST and sfnt resource (#45919).
suzuki toshiyae982f5b2015-09-21 23:07:22 +09003396
Werner Lembergd7f456e2015-09-26 08:37:14 +02003397 * src/base/ftbase.h (FT_MAC_RFORK_MAX_LEN): Maximum length of the
3398 resource fork for Mac OS. Resource forks larger than 16 MB can be
3399 written but can't be handled correctly, at least in Carbon routine.
3400 See https://support.microsoft.com/en-us/kb/130437.
suzuki toshiyae982f5b2015-09-21 23:07:22 +09003401
Werner Lembergd7f456e2015-09-26 08:37:14 +02003402 * src/base/ftobjs.c (Mac_Read_POST_Resource): No need to use `0x'
3403 prefix for `%p' formatter.
suzuki toshiyae982f5b2015-09-21 23:07:22 +09003404
Werner Lembergd7f456e2015-09-26 08:37:14 +02003405 * src/base/ftbase.c (Mac_Read_POST_Resource): Check the fragment and
3406 total size of the concatenated POST resource before buffer
3407 allocation.
3408 (Mac_Read_sfnt_Resource): Check the declared size of sfnt resource
suzuki toshiyae982f5b2015-09-21 23:07:22 +09003409 before buffer allocation.
suzuki toshiyae982f5b2015-09-21 23:07:22 +09003410
Werner Lembergd7f456e2015-09-26 08:37:14 +02003411 * src/base/ftmac.c (read_lwfn, FT_New_Face_From_SFNT): Check the
3412 total resource size before buffer allocation.
suzuki toshiyae982f5b2015-09-21 23:07:22 +09003413
Werner Lembergcb7a5122015-09-19 07:58:03 +020034142015-09-19 Werner Lemberg <wl@gnu.org>
3415
Werner Lemberg730b6d72015-09-19 12:41:12 +02003416 [sfnt] Improve handling of invalid SFNT table entries (#45987).
3417
3418 This patch fixes weaknesses in function `tt_face_load_font_dir'.
3419
3420 - It incorrectly assumed that valid tables are always at the
3421 beginning. As a consequence, some valid tables after invalid
3422 entries (which are ignored) were never seen.
3423
3424 - Duplicate table entries (this is, having the same tag) were not
3425 rejected.
3426
3427 - The number of valid tables was sometimes too large, leading to
3428 access of invalid tables.
3429
3430 * src/sfnt/ttload.c (check_table_dir): Add argument to return number
3431 of valid tables.
3432 Add another tracing message.
3433 (tt_face_load_font_dir): Only allocate table array for valid
3434 entries as returned by `check_table_dir'.
3435 Reject duplicate tables and adjust number of valid tables
3436 accordingly.
3437
34382015-09-19 Werner Lemberg <wl@gnu.org>
3439
Werner Lembergcb7a5122015-09-19 07:58:03 +02003440 [pcf] Improve `FT_ABS' fix from 2015-09-17 (#45999).
3441
3442 * src/pcf/pcfread.c (pcf_load_font): Do first the cast to FT_Short,
3443 then take the absolute value.
3444 Also apply FT_ABS to `height'.
3445
Werner Lemberg9db9add2015-09-17 13:42:59 +020034462015-09-17 Werner Lemberg <wl@gnu.org>
3447
Werner Lembergf28c95c2015-09-17 19:30:26 +02003448 [type42] Fix memory leak (#45989).
3449
3450 * src/type42/t42parse.c (t42_parse_charstrings): Allow only a single
3451 `CharStrings' array.
3452
34532015-09-17 Werner Lemberg <wl@gnu.org>
3454
Werner Lemberg4942c2b2015-09-17 17:56:53 +02003455 [psaux] Fix memory leak (#45986).
3456
3457 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
3458 Free `temp' in case of error.
3459
34602015-09-17 Werner Lemberg <wl@gnu.org>
3461
Werner Lemberg7d364b72015-09-17 16:31:58 +02003462 [psaux] Improve tracing message.
3463
3464 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
3465 Handle plural correctly.
3466
34672015-09-17 Werner Lemberg <wl@gnu.org>
3468
Werner Lembergc838c4f2015-09-17 16:22:40 +02003469 [pcf] Fix integer overflows (#45985).
3470
3471 * src/pcf/pcfread.c (pcf_load_font): Use FT_MulDiv.
3472
34732015-09-17 Werner Lemberg <wl@gnu.org>
3474
Werner Lemberg9db9add2015-09-17 13:42:59 +02003475 [pcf] Use FT_ABS for some property values (#45893).
3476
3477 * src/pcf/pcfread.c (pcf_load_font): Take absolute values for
3478 AVERAGE_WIDTH, POINT_SIZE, PIXEL_SIZE, RESOLUTION_X, and
3479 RESOLUTION_Y. In tracing mode, add warnings.
3480
Werner Lembergbd0438a2015-09-16 18:05:43 +020034812015-09-16 Werner Lemberg <wl@gnu.org>
3482
3483 Minor fixes for some clang warnings.
3484
3485 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Cast, possible missing
3486 initialization.
3487
3488 * src/truetype/ttgload.c (TT_Process_Composite_Component): Cast.
3489
Werner Lemberg581c7e22015-09-15 06:49:06 +020034902015-09-15 Werner Lemberg <wl@gnu.org>
3491
Werner Lemberg19cb1122015-09-15 08:52:36 +02003492 [type1, type42] Fix memory leaks (#45966).
3493
3494 * src/type1/t1load.c (parse_blend_axis_types): Handle multiple axis
3495 names.
3496 (parse_blend_design_map): Allow only a single design map.
3497 (parse_encoding): Handle multiple encoding vectors.
3498
3499 * src/type42/t42parse.c (t42_parse_encoding): Handle multiple
3500 encoding vectors.
3501
35022015-09-15 Werner Lemberg <wl@gnu.org>
3503
Werner Lemberg7f0f4012015-09-15 07:23:53 +02003504 [truetype] Fix integer type (#45965).
3505
3506 * src/truetype/ttobjs.c (tt_synth_sfnt_checksum): Implement it.
3507
35082015-09-15 Werner Lemberg <wl@gnu.org>
3509
Werner Lemberg577daf12015-09-15 07:10:16 +02003510 * src/pcf/pcfread.c (pcf_load_font): Fix integer overflow (#45964).
3511
35122015-09-15 Werner Lemberg <wl@gnu.org>
3513
Werner Lemberg581c7e22015-09-15 06:49:06 +02003514 [type1, type42] Check encoding array size (#45961).
3515
3516 * src/type1/t1load.c (parse_encoding), src/type42/t42parse.c
3517 (t42_parse_encoding): Do it.
3518
Alexei Podtelezhnikov3ea0d2c2015-09-13 23:19:34 -040035192015-09-14 Alexei Podtelezhnikov <apodtele@gmail.com>
3520
3521 * src/base/ftcalc.c (FT_MulFix) [FT_LONG64]: Improve.
3522
Werner Lemberg7962a152015-09-14 00:38:26 +020035232015-09-14 Werner Lemberg <wl@gnu.org>
3524
3525 [type1] Fix another potential buffer overflow (#45955).
3526
3527 * src/type1/t1parse (T1_Get_Private_Dict): Assure that check for
3528 `eexec' doesn't exceed `limit'.
3529
Werner Lemberge40e8b32015-09-13 08:05:50 +020035302015-09-13 Werner Lemberg <wl@gnu.org>
3531
Werner Lembergff7d6402015-09-13 23:53:16 +02003532 Replace `mkinstalldirs' with AC_PROG_MKDIR_P.
3533
3534 * builds/unix/mkinstalldirs: Removed, no longer needed.
3535
3536 * builds/unix/configure.raw: Call `AC_PROG_MKDIR_P'.
3537 Update pwd call for `$INSTALL'.
3538
3539 * builds/unix/unix-def.in (MKINSTALLDIRS): Use `@MKDIR_P@'.
3540
3541 * autogen.sh: Updated.
3542
35432015-09-13 Werner Lemberg <wl@gnu.org>
3544
Werner Lemberg3df92aa2015-09-13 09:21:52 +02003545 [winfonts] Check alignment shift count for resource data (#45938).
3546
3547 * src/winfonts/winfnt.c (fnt_face_get_dll_font): Implement it.
3548
35492015-09-13 Werner Lemberg <wl@gnu.org>
3550
Werner Lemberge3058612015-09-13 08:41:43 +02003551 [type1] Fix potential buffer overflow (#45923).
3552
3553 * src/type1/t1parse.c (T1_Get_Private_Dict): Assure `cur' doesn't
3554 point to end of file buffer.
3555
35562015-09-13 Werner Lemberg <wl@gnu.org>
3557
Werner Lemberge40e8b32015-09-13 08:05:50 +02003558 [gzip] Fix access of small compressed files (#45937).
3559
3560 * src/gzip/ftgzip.c (ft_gzip_stream_close): Avoid memory leak.
3561
3562 (ft_gzip_get_uncompressed_file): Correct byte order while reading
3563 unsigned long value. Without this change, the whole optimization of
3564 accessing small files in `FT_Stream_OpenGzip' is never executed! As
3565 a consequence, access to PCF files in general (which are normally
3566 small files) should be much improved now as originally intended.
3567
Werner Lemberg23423bc2015-09-11 08:28:27 +020035682015-09-11 Werner Lemberg <wl@gnu.org>
3569
Werner Lembergdb5a4a92015-09-12 08:32:55 +02003570 [psaux] Fix potential buffer overflow (#45922).
3571
3572 * src/psaux/psobjs.c (ps_parser_skip_PS_token): If a token is
3573 enclosed in balanced expressions, ensure that the cursor position
3574 doesn't get larger than the current limit.
3575
35762015-09-11 Werner Lemberg <wl@gnu.org>
3577
Werner Lemberg19b82cf2015-09-11 20:25:32 +02003578 [base] Avoid crash while tracing `load_mac_face'.
3579
3580 Reported in Savannah bug #45919.
3581
3582 * src/base/ftobjs.c (load_mac_face): Honour FT_OPEN_MEMORY while
3583 tracing.
3584
35852015-09-11 Werner Lemberg <wl@gnu.org>
3586
Werner Lemberg23423bc2015-09-11 08:28:27 +02003587 [type42] Fix endless loop (#45920).
3588
3589 * src/type42/t42parse.c (t42_parse_encoding): Synchronize with
3590 type1's `parse_encoding'.
3591
Werner Lemberge5a27a72015-09-10 07:44:11 +020035922015-09-10 Werner Lemberg <wl@gnu.org>
3593
3594 [docmaker] Allow `-' in bold and italic markup.
3595
3596 * src/tools/docmaker/sources.py (re_italic, re_bold): Adjust
3597 accordingly.
3598
Alexei Podtelezhnikov09948e42015-09-09 21:30:15 -040035992015-09-09 Alexei Podtelezhnikov <apodtele@gmail.com>
3600
3601 * src/base/ftcalc.c (FT_RoundFix): Improve.
3602
Wojciech Mamrak822acb02015-09-09 07:59:10 +020036032015-09-09 Wojciech Mamrak <wmamrak@gmail.com>
3604
3605 * src/base/ftcalc.c (FT_CeilFix, FT_FloorFix): Normalize.
3606
3607 This commit makes the functions behave as expected, this is,
3608 rounding towards plus or minus infinity.
3609
Alexei Podtelezhnikovb002f682015-09-07 13:47:36 -040036102015-09-07 Alexei Podtelezhnikov <apodtele@gmail.com>
3611
3612 * src/smooth/ftgrays.c (gray_render_line): Simplify clipping.
3613
Alexei Podtelezhnikov5a6dc872015-09-04 23:14:46 -040036142015-09-04 Alexei Podtelezhnikov <apodtele@gmail.com>
3615
3616 [raster,smooth] Microoptimizations.
3617
3618 * src/raster/ftraster.c (Insert_Y_Turn, Finalize_Profile_Table,
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04003619 Bezier_Up, ): Use do-while loops.
Alexei Podtelezhnikov5a6dc872015-09-04 23:14:46 -04003620
3621 * src/smooth/ftgrays.c (gray_render_scanline, gray_render_line,
3622 gray_convert_glyph): Ditto.
3623
Werner Lemberg696b7122015-09-04 10:10:59 +020036242015-09-04 Werner Lemberg <wl@gnu.org>
3625
Werner Lembergd3cba0e2015-09-04 10:28:53 +02003626 [autofit] Redesign code ranges (2/2).
3627
3628 This commit adds two fallback scripts (`latb', `latp') and
3629 implements support for the no-base character ranges introduced in
3630 the previous commit.
3631
3632 * src/autofit/aftypes.h (AF_ScriptClassRec): Add
3633 `script_uni_nobase_ranges' field.
3634 (AF_DEFINE_SCRIPT_CLASS): Updated.
3635
3636 * src/autofit/afscript.h, src/autofit/afstyles.h: Add `latb' and
3637 `latp' fallback scripts.
3638
3639 * src/autofit/afblue.dat: Add blue zones for Latin subscript and
3640 superscript fallback scripts.
3641
3642 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
3643
3644 * src/autofit/afglobal.h (AF_NOBASE): New style flag for no-base
3645 characters.
3646 (AF_STYLE_MASK): Updated.
3647
3648 * src/autofit/afglobal.c (SCRIPT): Updated.
3649 (af_face_globals_compute_style_coverage): Handle new style flag.
3650
3651 * src/autofit/aflatin.c (af_latin_hints_apply): Handle new style
3652 flag.
3653
3654 * src/autofit/afranges.h (SCRIPT): Use it to export no-base ranges.
3655
36562015-09-04 Werner Lemberg <wl@gnu.org>
3657
Werner Lemberg696b7122015-09-04 10:10:59 +02003658 [autofit] Redesign code ranges (1/2).
3659
3660 This patch introduces auxiliary code ranges that identify no-base
3661 characters; they refer to glyphs of a script that should be hinted
3662 without alignments to blue zones (mostly diacritics).
3663
3664 It also splits off ranges for fallback scripts that handle subscript
3665 and superscript characters not covered by OpenType features. For
3666 example, this greatly helps improve the hinting of various phonetic
3667 alphabets, which contain a large amount characters that look like
3668 superscript glyphs.
3669
3670 Finally, code ranges are updated to Unicode 8.0, and enclosed
3671 characters are removed in general since they normally look better if
3672 they stay unhinted.
3673
3674 * src/autofit/afranges.c (af_latn_uniranges): Updated to Unicode
3675 8.0.
3676 Split off superscript-like and subscript-like glyphs into...
3677
3678 (af_latb_uniranges, af_latp_uniranges): ... these two new arrays.
3679
3680 (af_xxxx_nobase_uniranges): New arrays that hold no-base characters
3681 of the corresponding character ranges.
3682
Werner Lemberg8cbbcf62015-09-03 06:47:30 +020036832015-09-03 Werner Lemberg <wl@gnu.org>
3684
3685 [autofit] Pass glyph index to hinting function.
3686
3687 No functionality change yet.
3688
3689 * src/autofit/aftypes.h (AF_WritingSystem_ApplyHintsFunc): Pass
3690 glyph index.
3691
3692 * src/autofit/afcjk.c, src/autofit/afcjk.h (af_cjk_hints_apply),
3693 src/autofit/afdummy.c (af_dummy_hints_apply), src/autofit/afindic.c
3694 (af_indic_hints_apply), src/autofit/aflatin.c
3695 (af_latin_hints_apply), src/autofit/aflatin2.c
3696 (af_latin2_hints_apply), src/autofit/afloader.c (af_loader_load_g):
3697 Updated.
3698
Werner Lemberg87c81f02015-08-30 10:35:21 +020036992015-08-30 Werner Lemberg <wl@gnu.org>
3700
Werner Lemberg40103a32015-08-31 08:51:52 +02003701 [autofit] Code clean-up.
3702
3703 * src/autofit/afglobal.h (AF_STYLE_MASK): New macro.
3704 (AF_STYLE_UNASSIGNED): Use AF_STYLE_MASK for definition.
3705
3706 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
3707 Updated.
3708
37092015-08-30 Werner Lemberg <wl@gnu.org>
3710
Werner Lemberg87c81f02015-08-30 10:35:21 +02003711 [autofit] Make glyph style array use 16bit values.
3712
3713 * include/freetype/ftautoh.h (FT_Prop_GlyphToScriptMap): Use
3714 `FT_UShort' for `map' field.
3715
3716 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage,
3717 af_face_globals_new), src/autofit/hbshim.c, src/autofit/hbshim.h
3718 (af_get_coverage): Use FT_UShort for `glyph_styles' array.
3719
3720 * src/autofit/afglobal.h (AF_STYLE_UNASSIGNED, AF_DIGIT): Extend to
3721 16 bits.
3722 (AF_FaceGlobalsRec): Use `FT_UShort' for `glyph_styles' field.
3723
Werner Lemberg633d8ed2015-08-26 06:18:47 +020037242015-08-26 Werner Lemberg <wl@gnu.org>
3725
3726 * builds/unix/configure.raw: Need harfbuzz >= 0.9.21 (#45828).
3727
Werner Lemberg78b01402015-08-25 07:23:01 +020037282015-08-25 Werner Lemberg <wl@gnu.org>
3729
3730 [base] Improve kerning tracing and documentation.
3731
3732 * src/base/ftobjs.c (FT_Get_Kerning): Emit tracing message if
3733 scaled-down kerning values differ.
3734
Werner Lemberg91d59162015-08-18 06:04:36 +020037352015-08-18 Werner Lemberg <wl@gnu.org>
3736
3737 [raster] Remove last remnants of `raster5' driver.
3738
3739 * src/raster/ftrend1.h (ft_raster5_renderer_class): Removed.
3740
3741 * src/raster/rastpic.c, src/raster/rastpic.h
3742 (ft_raster5_renderer_class_pic_init,
3743 ft_raster5_renderer_class_pic_free): Removed.
3744
Alexei Podtelezhnikova0172d12015-08-17 22:58:59 -040037452015-08-17 Alexei Podtelezhnikov <apodtele@gmail.com>
3746
3747 [base] Improve emboldener (#45596).
3748
3749 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Correct displacement
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04003750 of zero-length segments.
Alexei Podtelezhnikova0172d12015-08-17 22:58:59 -04003751
Alexei Podtelezhnikov00d89952015-08-16 22:57:34 -040037522015-08-16 Alexei Podtelezhnikov <apodtele@gmail.com>
3753
Alexei Podtelezhnikov815c3242015-08-17 21:48:46 -04003754 [base] Reoptimize arithmetic.
Alexei Podtelezhnikov00d89952015-08-16 22:57:34 -04003755
3756 * src/base/ftcalc.c (FT_MulDiv, FT_MulFix) [!FT_LONG64]: Remove
3757 special cases that slow down the general use.
3758
pazerf0ed30e2015-08-15 06:53:09 +020037592015-08-15 pazer <ibemad@gmail.com>
3760
3761 Fix C++ compilation (#45762).
3762
3763 * src/base/ftstroke.c (ft_outline_glyph_class): Use
3764 FT_CALLBACK_TABLE.
3765
Alexei Podtelezhnikovae258aa2015-08-14 23:23:18 -040037662015-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
3767
3768 [truetype] Clean up.
3769
3770 * src/truetype/ttgload.c (TT_Process_Composite_Component): Use
3771 `FT_Outline_Transform' and `FT_Outline_Translate'.
3772 (translate_array): Dropped.
3773
Werner Lembergd0d7ee02015-08-14 14:30:58 +020037742015-08-14 Andreas Enge <andreas.enge@inria.fr>
3775
3776 * builds/unix/detect.mk (CONFIG_SHELL): Don't handle it (#44261).
3777
Werner Lemberg14d6b5d2015-08-13 15:22:17 +020037782015-08-13 Werner Lemberg <wl@gnu.org>
3779
3780 [truetype] Introduce named instance access to GX fonts.
3781
3782 For functions querying a face, bits 16-30 of the face index can hold
3783 the named instance index if we have a GX font. The indices start
3784 with value 1; value 0 indicates font access without GX variation
3785 data.
3786
3787 * include/freetype/freetype.h (FT_FaceRec): Update documentation.
3788 * include/freetype/internal/sfnt.h: Ditto.
3789
3790 * src/sfnt/sfobjs.c (sfnt_init_face)
3791 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Get number of named instances and
3792 do argument checks.
3793 (sfnt_load_face): Updated.
3794
3795 * src/truetype/ttobjs.c (tt_face_init)
3796 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Use named instance, overwriting
3797 the style name.
3798
3799 * src/base/ftobjs.c (open_face_from_buffer,
3800 open_face_PS_from_sfnt_stream): Updated.
3801 * src/bdf/bdfdrivr.c (BDF_Face_Init): Updated.
3802 * src/cff/cffload.c (cff_font_load): Updated.
3803
3804 * src/cff/cffobjs.c (cff_face_init): Make function exit early for
3805 pure CFF fonts if `font_index < 0'.
3806 Updated.
3807
3808 * src/cid/cidobjs.c (cid_face_init): Updated.
3809 * src/pcf/pcfdrivr.c (PCF_Face_Init): Updated.
3810 * src/pfr/pfrobjs.c (pfr_face_init): Updated.
3811 * src/type1/t1objs.c (T1_Face_Init): Updated.
3812 * src/type42/t42objs.c (T42_Face_Init): Updated.
3813 * src/winfonts/winfnt.c (fnt_face_get_dll_font, FNT_Face_Init):
3814 Updated.
3815
3816 * docs/CHANGES: Updated.
3817
Alexei Podtelezhnikov4a466862015-08-12 23:45:40 -040038182015-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
3819
3820 [type1,cff,cid] Streamline font matrix application.
3821
3822 * src/type1/t1gload.c (T1_Load_Glyph): Directly modify advances only
3823 if font matrix is not trivial.
3824 * src/cff/cffgload.c (cff_slot_load): Ditto.
Alexei Podtelezhnikovf46b2822016-04-11 23:22:57 -04003825 * src/cid/cidgload.c (cid_slot_load_glyph): Ditto for advances and the
Alexei Podtelezhnikov4a466862015-08-12 23:45:40 -04003826 entire outline.
3827
Werner Lemberg7ebe6ac2015-08-11 06:47:25 +020038282015-08-11 Werner Lemberg <wl@gnu.org>
3829
3830 [builds/unix] Minor.
3831
3832 * builds/unix/configure.raw:
3833 s/lib{priv,staticconf}/libs{priv,staticconf}/ for orthogonality with
3834 similarly named uppercase variables.
3835
Alexei Podtelezhnikova37da212015-08-10 23:05:02 -040038362015-08-10 Alexei Podtelezhnikov <apodtele@gmail.com>
3837
3838 [type1,cid,type42] Minor improvements.
3839
3840 * src/type1/t1load.c (t1_parse_font_matrix): Scale units per EM only
3841 when necessary. Refresh comments.
3842 * src/cid/cidload.c (cid_parse_font_matrix): Ditto.
3843 * src/type42/t42parse.c (t42_parse_font_matrix): Refresh comments.
3844
Werner Lemberge5f44692015-08-08 07:45:03 +020038452015-08-08 Werner Lemberg <wl@gnu.org>
3846
Werner Lembergbd75a512015-08-08 08:39:45 +02003847 [type42] Fix glyph access.
3848
3849 This is a severe bug: We've missed one level of indirection, as
3850 described in the Type 42 specification. As a result, ftview
3851 sometimes showed incorrect glyphs for given glyph names, and even
3852 displayed `error 0x0006' (invalid argument!) in case the number of
3853 glyph indices differed between the Type 42 font and the embedded
3854 TTF.
3855
3856 Apparently, noone ever noticed it; this shows how much Type 42 fonts
3857 are in use...
3858
3859 * src/type42/t42objs.c (T42_GlyphSlot_Load): Map Type 42 glyph index
3860 to embedded TTF's glyph index.
3861
38622015-08-08 Werner Lemberg <wl@gnu.org>
3863
Werner Lemberge5f44692015-08-08 07:45:03 +02003864 [type42] Minor clean-up.
3865
3866 * src/type42/t42parse.c (t42_parse_font_matrix): Remove unused
3867 variable.
3868
Alexei Podtelezhnikovfd705122015-08-06 21:49:08 -040038692015-08-06 Alexei Podtelezhnikov <apodtele@gmail.com>
3870
3871 [type42] Parse FontMatrix according to specifications.
3872
3873 * src/type42/t42parse.c (t42_parse_font_matrix): Type 42 FontMatrix
3874 does not need scaling by 1000. Units_per_EM are taken from the
3875 embedded TrueType.
3876
Werner Lembergff406e22015-08-06 07:34:50 +020038772015-08-06 Werner Lemberg <wl@gnu.org>
3878
3879 [autofit] Improve Arabic hinting.
3880
3881 Problem reported by Titus Nemeth <tn@tntypography.eu> (by using
3882 ttfautohint).
3883
3884 * src/autofit/afblue.dat: Add neutral blue zone for the tatweel
3885 character.
3886
3887 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
3888
Alexei Podtelezhnikov98e8e992015-08-06 00:06:14 -040038892015-08-05 Alexei Podtelezhnikov <apodtele@gmail.com>
3890
3891 [truetype] Clean up types.
3892
3893 * src/truetype/ttobjs.c (TT_Size): Move declaration from here.
3894 * include/freetype/internal/tttypes.h (TT_Size): ... to here.
3895 (TT_LoaderRec): Switch to appropriate types for `face' and `size'.
3896 * src/truetype/ttgload.c: Remove corresponding type casts.
3897 * src/truetype/ttsubpix.c: Ditto.
3898
Werner Lemberg15e2a4f2015-08-05 21:53:50 +020038992015-08-05 Werner Lemberg <wl@gnu.org>
3900
3901 [autofit] Improve recognition of flat vs. rounded segments.
3902
3903 Lower the flatness threshold from upem/8 to upem/14, making the
3904 auto-hinter accept shorter elements.
3905
3906 Synchronize flat/round stem selection algorithm with blue zone code.
3907
3908 * src/autofit/aflatin.c (FLAT_THRESHOLD): New macro.
3909 (af_latin_metrics_init_blues): Use it.
3910 (af_latin_hints_compute_segments): Collect information on maximum
3911 and minimum coordinates of `on' points; use this to add a constraint
3912 for the flat/round decision similar to
3913 `af_latin_metrics_init_blues'.
3914
Werner Lembergeb22ef22015-08-04 06:50:04 +020039152015-08-04 Werner Lemberg <wl@gnu.org>
3916
3917 Another left-shift bug (#45681).
3918
3919 * src/base/ftobjs.c (IsMacBinary): Only accept positive values for
3920 `dlen'.
3921
Alexei Podtelezhnikov7e6c3212015-08-03 23:26:13 -040039222015-08-03 Alexei Podtelezhnikov <apodtele@gmail.com>
3923
3924 [base] Fix `ft_corner_orientation'.
3925
3926 Remove casting from `FT_Long' to `FT_Int' that might change the sign
3927 of the return value and make it faster too.
3928
3929 * src/base/ftcalc.c (ft_corner_orientation): On 32-bit systems, stay
3930 with 32-bit arithmetic when safe. Use plain math on 64-bit systems.
3931 * src/pshinter/pshalgo.c: Remove old unused code.
3932
Werner Lembergca6a5cf2015-08-03 08:51:18 +020039332015-08-03 Werner Lemberg <wl@gnu.org>
3934
Werner Lemberg8dfc7602015-08-03 12:23:30 +02003935 * src/truetype/ttgload.c (load_truetype_glyph)
3936 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Fix crash for composite glyphs
3937 having a depth greater than 1.
3938
39392015-08-03 Werner Lemberg <wl@gnu.org>
3940
Werner Lembergca6a5cf2015-08-03 08:51:18 +02003941 Fix typo in clang bug from 2015-07-31 (#45678).
3942
3943 * src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Fix inequality.
3944
Werner Lemberg70e9d812015-08-02 09:42:12 +020039452015-08-02 Werner Lemberg <wl@gnu.org>
3946
Werner Lemberga82c45d2015-08-02 18:35:49 +02003947 * CMakeLists.txt: Improve shared library support.
3948
3949 Based on a patch from John Cary <cary@txcorp.com>.
3950
39512015-08-02 Werner Lemberg <wl@gnu.org>
3952
Werner Lemberg682c2712015-08-02 15:46:26 +02003953 * builds/unix/freetype-config.in (enable_shared): Remove. Unused.
3954
39552015-08-02 Werner Lemberg <wl@gnu.org>
3956
Werner Lemberg70e9d812015-08-02 09:42:12 +02003957 Fix more invalid left-shifts.
3958
3959 * src/pfr/pfrgload.c (pfr_glyph_load_compound): Use multiplication,
3960 not left-shift.
3961
3962 * src/truetype/ttgxvar.c (ft_var_load_avar, ft_var_load_gvar,
3963 tt_face_vary_cvt, TT_Vary_Apply_Glyph_Deltas): Use multiplication,
3964 not left-shift.
3965
Werner Lemberg5d1b8ab2015-07-31 21:49:07 +020039662015-07-31 Werner Lemberg <wl@gnu.org>
3967
Werner Lemberg6343ba22015-08-01 07:53:48 +02003968 Fix some bugs found by clang's `-fsanitize=undefined' (#45661).
3969
3970 * src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Only accept
3971 positive values from header.
3972 Check overflow.
3973
3974 * src/base/ftoutln.c (SCALED): Correctly handle left-shift of
3975 negative values.
3976
3977 * src/bdf/bdf.h (_bdf_glyph_modified, _bdf_set_glyph_modified,
3978 _bdf_clear_glyph_modified): Use unsigned long constant.
3979
3980 * src/bdf/bdfdrivr.c (BDF_Size_Select, BDF_Glyph_Load): Don't
3981 left-shift values that can be negative.
3982
3983 * src/pcf/pcfdrivr.c (PCF_Size_Select, PCF_Glyph_Load): Don't
3984 left-shift values that can be negative.
3985
3986 * src/raster/ftraster.c (SCALED): Correctly handle left-shift of
3987 negative values.
3988
3989 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Don't left-shift
3990 values that can be negative.
3991
3992 * src/truetype/ttgload.c (TT_Load_Composite_Glyph,
3993 compute_glyph_metrics, load_sbit_image): Don't left-shift values
3994 that can be negative.
3995
39962015-07-31 Werner Lemberg <wl@gnu.org>
3997
Werner Lemberg5d1b8ab2015-07-31 21:49:07 +02003998 Define FT_LONG_MAX.
3999
4000 * include/freetype/config/ftstdlib.h (FT_LONG_MAX): New macro.
4001 * src/cff/cf2arrst.c (cf2_arrstack_setNumElements): Use it.
4002
40032015-07-28 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov2b07a5a2015-07-28 23:14:30 -04004004
4005 * src/base/ftcalc.c (FT_Vector_NormLen): Clarify.
4006
Werner Lemberg5d1b8ab2015-07-31 21:49:07 +020040072015-07-27 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikove8b186e2015-07-27 23:22:34 -04004008
4009 * src/base/ftcalc.c (FT_Vector_NormLen): Explicate type conversions.
4010
Matthias Clasenb650dfb2015-07-26 21:08:34 +020040112015-07-26 Matthias Clasen <matthias.clasen@gmail.com>
4012
4013 [cff] Don't use `hmtx' table for LSB (#45520).
4014
4015 * src/cff/cffgload.c (cff_slot_load): Use `htmx' table for advance
4016 width only. Bug introduced 2015-04-10.
4017
Werner Lembergf9be5672015-07-09 15:10:31 +020040182015-07-09 Werner Lemberg <wl@gnu.org>
4019
4020 Better support of user-supplied C++ namespaces.
4021
4022 See
4023
4024 http://lists.nongnu.org/archive/html/freetype-devel/2015-07/msg00008.html
4025
4026 for a rationale.
4027
4028 * src/autofit/afpic.h, src/base/basepic.h, src/cff/cffpic.h,
4029 src/pshinter/pshpic.h, src/psnames/pspic.h, src/raster/rastpic.h,
4030 src/sfnt/sfntpic.h, src/smooth/ftspic.h, src/truetype/ttpic.h
4031 (FT_BEGIN_HEADER, FT_END_HEADER): Move macro calls to not enclose
4032 header files that contain FT_{BEGIN,END}_HEADER macros by
4033 themselves.
4034
4035 * src/autofit/aftypes.h [FT_DEBUG_AUTOFIT]: Include
4036 FT_CONFIG_STANDARD_LIBRARY_H earlier.
4037
Alexei Podtelezhnikovc05a1c32016-06-21 23:12:54 -04004038 * src/truetype/ttpic.h: Include FT_INTERNAL_PIC_H.
Werner Lembergf9be5672015-07-09 15:10:31 +02004039
Werner Lemberg1cdac102015-07-07 14:04:44 +020040402015-07-07 Werner Lemberg <wl@gnu.org>
4041
4042 [sfnt] Make `tt_face_get_name' member of the SFNT interface.
4043
4044 * include/freetype/internal/sfnt.h (TT_Get_Name_Func): New
4045 prototype.
4046 (SFNT_Interface, FT_DEFINE_SFNT_INTERFACE): New member `get_name'.
4047
4048 * src/sfnt/sfdriver.c (sfnt_interface): Updated.
4049
4050 * src/sfnt/sfobjs.c (tt_face_get_name): Tag it with `LOCAL_DEF'.
4051 * src/sfnt/sfobjs.h: Add prototype for it.
4052
Werner Lembergeb1bba92015-06-30 09:46:39 +020040532015-06-30 Werner Lemberg <wl@gnu.org>
4054
4055 Fix some clang compiler warnings.
4056
4057 * src/base/ftoutln.c (FT_Outline_EmboldenXY), src/cff/cf2intrp.c
4058 (cf2_interpT2CharString), src/truetype/ttgload.c
4059 (load_truetype_glyph), src/truetype/ttgxvar.c (tt_handle_deltas),
4060 src/truetype/ttinterp.c (Ins_INSTCTRL): Fix signedness issues.
4061
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040040622015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov884e4e62015-06-29 22:32:05 -04004063
Alexei Podtelezhnikov5aaabb42015-06-29 22:46:54 -04004064 [truetype] Speed up bytecode interpreter.
4065
4066 * src/truetype/ttinterp.c (Normalize): Use `FT_Vector_NormLen'.
4067
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040040682015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov5aaabb42015-06-29 22:46:54 -04004069
Alexei Podtelezhnikov9ef02bd2015-06-29 22:39:10 -04004070 [base] Speed up emboldening.
4071
Werner Lembergeb1bba92015-06-30 09:46:39 +02004072 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Use
4073 `FT_Vector_NormLen'.
Alexei Podtelezhnikov9ef02bd2015-06-29 22:39:10 -04004074
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040040752015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov9ef02bd2015-06-29 22:39:10 -04004076
Alexei Podtelezhnikov884e4e62015-06-29 22:32:05 -04004077 [base] Implement fast vector normalization.
4078
4079 The function uses Newton's iterations instead of dividing vector
4080 components by its length, which needs a square root. This is,
4081 literally, a bit less accurate but a lot faster.
4082
4083 * src/base/ftcalc.c (FT_Vector_NormLen): New function.
4084
Werner Lemberg22479ca2015-06-28 10:26:33 +020040852015-06-28 Werner Lemberg <wl@gnu.org>
4086
Werner Lemberg7cdc77f2015-06-28 11:40:02 +02004087 * CMakeLists.txt: Always create `ftconfig.h'.
4088
4089 For non-UNIX builds, the file stays unmodified. However, it's
4090 better to have the main configuration files at the same place
4091 regardless of the OS.
4092
40932015-06-28 Werner Lemberg <wl@gnu.org>
4094
Werner Lemberg2c89e2c2015-06-28 11:06:47 +02004095 * CMakeLists.txt: Improve MSVC support (#43737).
4096
40972015-06-28 Werner Lemberg <wl@gnu.org>
4098
Werner Lemberg52c9b1a2015-06-28 11:03:10 +02004099 [cmake] Check for libraries and create `ftoption.h'.
4100
4101 * builds/FindHarfBuzz.cmake: New file, taken from
4102
4103 https://trac.webkit.org/browser/trunk/Source/cmake/FindHarfBuzz.cmake
4104
4105 * CMakeLists.Txt: Add path to local cmake modules.
4106 Find dependencies for zlib, bzip2, libpng, and harfbuzz.
4107 Create `ftoption.h' file.
4108 Set up include and linker stuff for libraries.
4109
41102015-06-28 Werner Lemberg <wl@gnu.org>
4111
Werner Lemberg97b757d2015-06-28 10:42:47 +02004112 * CMakeLists.txt: Fix creation of `ftconfig.h'.
4113 Check for UNIX header files using `check_include_file'.
4114 Set up correct header include directories.
4115
41162015-06-28 Werner Lemberg <wl@gnu.org>
4117
Werner Lemberg22479ca2015-06-28 10:26:33 +02004118 * CMakeLists.txt: Disallow in-source builds.
4119
Werner Lemberg802f6a92015-06-27 07:12:42 +020041202015-06-27 Werner Lemberg <wl@gnu.org>
4121
4122 * src/tools/docmaker/utils.py (check_output): Add missing `\n'.
4123
Werner Lemberg94c79c22015-06-26 06:46:59 +020041242015-06-26 Werner Lemberg <wl@gnu.org>
4125
Werner Lemberg802f6a92015-06-27 07:12:42 +02004126 * CMakeLists.txt: Select platform-dependent `ftdebug.c'.
Werner Lemberg94c79c22015-06-26 06:46:59 +02004127
Werner Lemberg392cf222015-06-25 13:04:57 +020041282015-06-25 Werner Lemberg <wl@gnu.org>
4129
Werner Lemberg68222dd2015-06-25 16:38:11 +02004130 * CMakeLists.txt: Use cmake functions for generating `ftconfig.h'.
4131 Additionally, do this for UNIX only.
4132
41332015-06-25 Werner Lemberg <wl@gnu.org>
4134
Werner Lemberg5ef5a4f2015-06-25 15:45:13 +02004135 * CMakeLists.txt (BASE_SRCS): Use `ftbase.c' and `psnames.c'.
4136
41372015-06-25 Werner Lemberg <wl@gnu.org>
4138
Werner Lemberg392cf222015-06-25 13:04:57 +02004139 Another adjustment to header locations.
4140
4141 This change is a result of a discussion thread on freetype-devel
4142
4143 http://lists.nongnu.org/archive/html/freetype-devel/2015-06/msg00041.html
4144
4145 Re-introduce the `freetype2' subdirectory for all FreeType header
4146 files after installation, and rename the `freetype2' subdirectory in
4147 the git repository to `freetype'.
4148
4149 * include/freetype2: Renamed to...
4150 * include/freetype: This.
4151
4152 * CMakeLists.txt (PUBLIC_HEADERS, PUBLIC_CONFIG_HEADERS,
4153 PRIVATE_HEADERS): Updated.
4154 Update creation of `ftconfig.h'.
4155 Install generated `ftconfig.h'.
4156
4157 * Jamfile (HDRMACRO, RefDoc), autogen.sh: Updated.
4158
4159 * builds/amiga/include/config/ftconfig.h, builds/freetype.mk
4160 (PUBLIC_DIR), builds/symbian/bld.inf, builds/toplevel.mk (work),
4161 builds/unix/freetype2.in: Updated.
4162
4163 * builds/unix/freetype-config.in: Updated.
4164 * builds/unix/configure.raw: Don't check for `rmdir'.
4165 * builds/unix/unix-def.in (DELDIR): Use `rm -rf', which is portable
4166 according to the autoconf info manual.
4167 * builds/unix/install.mk (install, uninstall,
4168 distclean_project_unix): Update and simplify.
4169
4170 * builds/wince/*, builds/windows/*: Updated.
4171
4172 * devel/ft2build.h, include/ft2build.h: Updated.
4173
4174 * include/freetype2/config/ftheader.h,
4175 include/freetype2/internal/ftserv.h,
4176 include/freetype2/internal/internal.h: Update all header file
4177 macros.
4178
4179 * src/tools/chktrcmp.py (TRACE_DEF_FILES): Updated.
4180
4181 * docs/*: Updated.
4182
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040041832015-06-24 Alexei Podtelezhnikov <apodtele@gmail.com>
Werner Lemberg1982a882015-06-26 06:52:34 +02004184
4185 * src/bdf/bdflib.c (_bdf_parse_start): Disallow 0 bpp.
4186
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040041872015-06-24 Alexei Podtelezhnikov <apodtele@gmail.com>
Werner Lemberg1982a882015-06-26 06:52:34 +02004188
4189 * src/bdf/bdflib.c (_bdf_parse_start): Simplify bpp parsing.
4190
Werner Lemberg59312682015-06-23 09:24:48 +020041912015-06-23 Werner Lemberg <wl@gnu.org>
4192
4193 s/TYPEOF/FT_TYPEOF/ (#45376).
4194
4195 * builds/unix/ftconfig.in, builds/vms/ftconfig.in,
4196 include/freetype2/config/ftconfig.h,
4197 include/freetype2/internal/ftobjs.h, src/autofit/afwarp.h: Do it.
4198
Werner Lemberg8502c982015-06-22 06:35:23 +020041992015-06-22 Werner Lemberg <wl@gnu.org>
4200
4201 Fix Savannah bug #45097.
4202
4203 We no longer `pollute' the namespace of possible header file names;
4204 instead we move `ft2build.h' up by one level so that it gets
4205 installed in the default include directory (e.g.,
4206 /usr/local/include). After this commit, only `ft2build.h' stays in
4207 the compiler's include path.
4208
4209 No visible changes for the user who follows the standard FreeType
4210 header inclusion rules.
4211
4212 * include/*: Move to ...
4213 * include/freetype2/*: This directory, except `ft2build.h'.
4214
4215 * CMakeLists.txt (PUBLIC_HEADERS, PUBLIC_CONFIG_HEADERS,
4216 PRIVATE_HEADERS), Jamfile (HDRMACRO, RefDoc), autogen.sh: Updated.
4217
4218 * builds/amiga/include/config/ftconfig.h, builds/freetype.mk
4219 (PUBLIC_DIR), builds/symbian/bld.inf, builds/toplevel.mk (work),
4220 builds/unix/install.mk (install, uninstall),
4221 builds/unix/freetype2.in: Updated.
4222
4223 * builds/unix/freetype-config.in: Updated.
4224 Emit -I directory only if it is not `/usr/include'.
4225
4226 * builds/wince/*, builds/windows/*: Updated.
4227
4228 * devel/ft2build.h, include/ft2build.h: Updated.
4229
4230 * include/freetype2/config/ftheader.h,
4231 include/freetype2/internal/ftserv.h,
4232 include/freetype2/internal/internal.h: Update all header file
4233 macros.
4234
4235 * src/tools/chktrcmp.py (TRACE_DEF_FILES): Updated.
4236
Werner Lemberg31d97df2015-06-21 19:12:12 +020042372015-06-21 Werner Lemberg <wl@gnu.org>
4238
4239 Make Jam support work again.
4240
4241 This is just very basic stuff and just a little bit tested on
4242 GNU/Linux only. I won't delve into this since I'm not a Jam user.
4243
4244 * Jamfile: Call `HDRMACRO' for `ftserv.h' also.
4245 (DEFINES): Replace with...
4246 (CCFLAGS): ... this.
4247
4248 * src/Jamfile: Don't call `HDRMACRO' for `internal.h'; this is
4249 already handled in the top-level Jamfile.
4250
4251 * src/autofit/Jamfile (DEFINES): Replace with...
4252 (CCFLAGS): ... this.
4253 (_sources): Add missing files.
4254
4255 * src/cache/Jamfile: Don't call `HDRMACRO' for `ftcache.h'; it no
4256 longer contains macro header definitions.
4257
4258 * src/base/Jamfile, src/cff/Jamfile, src/sfnt/Jamfile,
4259 src/truetype/Jamfile (_sources): Add missing files.
4260
Werner Lemberg1a147ac2015-06-16 10:20:07 +020042612015-06-16 Werner Lemberg <wl@gnu.org>
4262
4263 Fix Savannah bug #45326.
4264
4265 * src/sfnt/sfntpic.h (SFNT_SERVICES_GET): Remove duplicate
4266 definitions.
4267
Werner Lemberge1862302015-06-07 16:11:18 +020042682015-06-07 Werner Lemberg <wl@gnu.org>
4269
4270 * Version 2.6 released.
4271 =======================
4272
4273
4274 Tag sources with `VER-2-6'.
4275
4276 * docs/VERSION.DLL: Update documentation and bump version number to
4277 2.6.
4278
4279 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
4280 builds/windows/vc2005/index.html,
4281 builds/windows/vc2008/freetype.vcproj,
4282 builds/windows/vc2008/index.html,
4283 builds/windows/vc2010/freetype.vcxproj,
4284 builds/windows/vc2010/index.html,
4285 builds/windows/visualc/freetype.dsp,
4286 builds/windows/visualc/freetype.vcproj,
4287 builds/windows/visualc/index.html,
4288 builds/windows/visualce/freetype.dsp,
4289 builds/windows/visualce/freetype.vcproj,
4290 builds/windows/visualce/index.html,
4291 builds/wince/vc2005-ce/freetype.vcproj,
4292 builds/wince/vc2005-ce/index.html,
4293 builds/wince/vc2008-ce/freetype.vcproj,
4294 builds/wince/vc2008-ce/index.html: s/2.5.5/2.6/, s/255/26/.
4295
4296 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 6.
4297 (FREETYPE_PATCH): Set to 0.
4298
4299 * builds/unix/configure.raw (version_info): Set to 18:0:12.
Werner Lemberg8cabd912015-10-04 08:18:01 +02004300 * CMakeLists.txt (VERSION_MINOR): Set to 6.
4301 (VERSION_PATCH): Set to 0.
Werner Lemberge1862302015-06-07 16:11:18 +02004302
4303 * src/autofit/afmodule.c [!FT_MAKE_OPTION_SINGLE_OBJECT]: Add
4304 declarations for dumping functions.
4305
4306 * src/truetype/ttinterp.c (TT_New_Context): Pacify compiler.
4307
4308 * builds/toplevel.mk: Use `freetype.mk's code to compute the version
4309 string.
4310 Don't include a zero patch level in version string.
4311 * builds/freetype.mk: Remove code for computing the version string.
4312
Ashish Azad472119a2015-06-06 05:45:17 +020043132015-06-06 Ashish Azad <ashish.azad@samsung.com>
4314
4315 Fix Savannah bug #45260.
4316
4317 * src/pfr/pfrdrivr.c (pfr_get_kerning): Fix typo.
4318
Werner Lemberg75534a02015-06-03 00:54:09 +020043192015-06-03 Werner Lemberg <wl@gnu.org>
4320
4321 [truetype] Fix memory leak.
4322
4323 Problem reported by Grissiom <chaos.proton@gmail.com>; in
4324
4325 http://lists.nongnu.org/archive/html/freetype/2015-05/msg00013.html
4326
4327 there is an example code to trigger the bug.
4328
4329 * src/truetype/ttobjs.c (tt_size_init_bytecode): Free old `size'
4330 data before allocating again. Bug most probably introduced four
4331 years ago in version 2.4.3.
4332
43332015-06-02 Werner Lemberg <wl@gnu.org>
Werner Lemberg54d04282015-06-01 12:12:06 +02004334
Werner Lembergd1ade6d2015-06-02 11:44:52 +02004335 [raster] Add more tracing.
4336
4337 * src/raster/ftraster.c (FT_TRACE7) [_STANDALONE_]: Define.
4338 (Vertical_Sweep_Span, Vertical_Sweep_Drop, Horizontal_Sweep_Span,
4339 Horizontal_Sweep_Drop, Render_Glyph): Add tracing calls.
4340
43412015-06-01 Werner Lemberg <wl@gnu.org>
4342
Werner Lemberg54d04282015-06-01 12:12:06 +02004343 [truetype] While tracing opcodes, show code position and stack.
4344
4345 * src/truetype/ttinterp.c: Change all existing TRACE7 calls to
4346 TRACE6.
4347 (opcode_name): Add string lengths.
4348 (TT_RunIns): Implement display of code position and stack.
4349
Werner Lembergcdee7d12015-05-31 11:54:42 +020043502015-05-31 Werner Lemberg <wl@gnu.org>
4351
Werner Lemberge9df4e42015-05-31 12:21:34 +02004352 [truetype] In GX, make private point numbers work correctly.
4353
4354 This is completely missing in Apple's documentation: If a `gvar'
4355 tuple uses private point numbers (this is, deltas are specified for
4356 some points only), the uncovered points must be interpolated for
4357 this tuple similar to the IUP bytecode instruction. Examples that
4358 need this functionality are glyphs `Oslash' and `Q' in Skia.ttf.
4359
4360 * src/truetype/ttgxvar.c (tt_delta_shift, tt_delta_interpolate,
4361 tt_handle_deltas): New functions.
4362 (TT_Vary_Get_Glyph_Deltas): Renamed to...
4363 (TT_Vary_Apply_Glyph_Deltas): ... this; it directly processes the
4364 points and does no longer return an array of deltas.
4365 Add tracing information.
4366 Call `tt_handle_deltas' to interpolate missing deltas.
4367 Also fix a minor memory leak in case of error.
4368
4369 * src/truetype/ttgxvar.h: Updated.
4370
4371 * src/truetype/ttgload.c (TT_Process_Simple_Glyph,
4372 load_truetype_glyph): Updated.
4373
43742015-05-31 Werner Lemberg <wl@gnu.org>
4375
Werner Lemberg9845c1d2015-05-31 11:57:31 +02004376 [truetype] In GX, make intermediate tuplets work at extrema.
4377
4378 * src/truetype/ttgxvar.c (ft_var_apply_tuple): Fix range condition.
4379
43802015-05-31 Werner Lemberg <wl@gnu.org>
4381
Werner Lembergcdee7d12015-05-31 11:54:42 +02004382 [truetype] Add tracing information to GX code.
4383
4384 * src/truetype/ttgxvar.c (ft_var_load_avar, ft_var_load_gvar,
4385 ft_var_apply_tuple, TT_Get_MM_Var, TT_Set_MM_Blend,
4386 TT_Set_Var_Design, tt_face_vary_cvt): Do it.
4387
Werner Lemberg366b2ea2015-05-28 10:58:40 +020043882015-05-28 Werner Lemberg <wl@gnu.org>
4389
4390 * src/tools/apinames.c (names_dump): Fix invalid reference.
4391
4392 Problem reported by Guzman Mosqueda, Jose R
4393 <jose.r.guzman.mosqueda@intel.com>.
4394
Werner Lemberga5e1f6f2015-05-24 23:29:23 +020043952015-05-24 Werner Lemberg <wl@gnu.org>
4396
4397 [truetype] Fix commit from 2015-05-22.
4398
4399 * src/truetype/ttgload.c, src/truetype/ttinterp.c: Guard new code
4400 with `TT_CONFIG_OPTION_SUBPIXEL_HINTING'.
4401
4402 Problem reported by Nikolaus Waxweiler <madigens@gmail.com>.
4403
Werner Lembergbb435da2015-05-23 07:21:25 +020044042015-05-23 Werner Lemberg <wl@gnu.org>
4405
Werner Lemberg7f099482015-05-24 09:50:24 +02004406 [truetype] Fix return values of GETINFO bytecode instruction.
4407
4408 * src/truetype/ttinterp.h (TT_ExecContextRec): New fields
4409 `vertical_lcd' and `gray_cleartype'.
4410
4411 * src/truetype/ttgload.c (tt_loader_init): Initialize new fields.
4412 Change `symmetrical smoothing' to TRUE, since FreeType produces
4413 exactly this.
4414
4415 * src/truetype/ttinterp.c (Ins_GETINFO): Fix selector/return bit
4416 values for symmetrical smoothing, namely 11/18.
4417 Handle bits for vertical LCD subpixels (8/15) and Gray ClearType
4418 (12/19).
4419
44202015-05-23 Werner Lemberg <wl@gnu.org>
4421
Werner Lembergbb435da2015-05-23 07:21:25 +02004422 [truetype] Minor.
4423
4424 * src/truetype/ttinterp.h (TT_ExecContext):
4425 s/subpixel/subpixel_hinting.
4426
4427 * src/truetype/ttgload.c, src/truetype/ttgload.h: Updated.
4428
44292015-05-22 Werner Lemberg <wl@gnu.org>
Werner Lemberg790b8df2015-05-20 12:33:40 +02004430
Werner Lembergc61cad82015-05-22 22:02:15 +02004431 [truetype] Support selector index 3 of the INSTCTRL instruction.
4432
4433 This flag activates `native ClearType hinting', disabling backwards
4434 compatibility mode as described in Greg Hitchcocks whitepaper. In
4435 other words, it enables unrestricted functionality of all TrueType
4436 instructions in ClearType.
4437
4438 * src/truetype/ttgload.c (tt_get_metrics): Call `sph_set_tweaks'
4439 unconditionally.
4440 (tt_loader_init): Unset `ignore_x_mode' flag if bit 2 of
4441 `GS.instruct_control' is active.
4442
4443 * src/truetype/ttinterp.c (Ins_INSTCTRL): Handle selector index 3.
4444 (Ins_GETINFO): Updated.
4445
4446 * docs/CHANGES: Document it.
4447
44482015-05-20 Werner Lemberg <wl@gnu.org>
4449
Werner Lemberg790b8df2015-05-20 12:33:40 +02004450 [truetype] Minor.
4451
4452 * src/truetype/ttinterp.h (SetSuperRound): Fix type of `GridPeriod'
4453 argument.
4454
Werner Lemberg0a6b6ff2015-05-17 22:54:48 +020044552015-05-17 Werner Lemberg <wl@gnu.org>
4456
4457 [truetype] Fix loading of composite glyphs.
4458
4459 * src/truetype/ttgload.c (TT_Load_Composite_Glyph): If the
4460 ARGS_ARE_XY_VALUES flag is not set, handle argument values as
4461 unsigned. I trust `ttx' (which has exactly such code) that it does
4462 the right thing here...
4463
4464 The reason that noone has ever noticed this bug is probably the fact
4465 that point-aligned subglyphs are rare, as are subglyphs with a
4466 number of points in the range [128;255], which is quite large (or
4467 even in the range [32768;65535], which is extremely unlikely).
4468
Chris Liddelld65bf722015-05-12 07:16:46 +020044692015-05-12 Chris Liddell <chris.liddell@artifex.com>
4470
Chris Liddella87fb8c2015-05-12 07:27:35 +02004471 [cff] Make the `*curveto' operators more tolerant.
4472
4473 * src/cff/cf2intrp.c (cf2_interpT2CharString): The opcodes
4474 `vvcurveto', `hhcurveto', `vhcurveto', and `hvcurveto' all iterate,
4475 pulling values off the stack until the stack is exhausted.
4476 Implicitly the stack must be a multiple (or for subtly different
4477 behaviour) a multiple plus a specific number of extra values deep.
4478 If that's not the case, enforce it (as the old code did).
4479
44802015-05-12 Chris Liddell <chris.liddell@artifex.com>
4481
Chris Liddelld65bf722015-05-12 07:16:46 +02004482 [cff] fix incremental interface with new cff code.
4483
4484 * src/cff/cf2ft.c (cf2_getSeacComponent): When using the incremental
4485 interface to retrieve glyph data for a SEAC, it be left to the
4486 incremental interface callback to apply the encoding to raw
4487 character index (as it was in the previous code).
4488
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040044892015-04-29 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov40914952015-04-29 21:57:30 -04004490
4491 [autofit] Speed up IUP.
4492
4493 * src/autofit/afhints.c (af_iup_interp): Separate trivial snapping to
4494 the same position from true interpolation, use `scale' to reduce
4495 divisions.
4496
Werner Lemberg3cc076d2015-04-28 09:16:27 +020044972015-04-28 Werner Lemberg <wl@gnu.org>
4498
4499 [cff] Use `name' table for PS name if we have a SFNT-CFF.
4500
4501 This follows the OpenType 1.7 specification. See
4502
4503 http://tug.org/pipermail/tex-live/2015-April/036634.html
4504
4505 for a discussion.
4506
4507 * src/cff/cffdrivr.c (cff_get_ps_name): Use the `sfnt' service if we
4508 have an SFNT.
4509
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040045102015-04-27 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov40623a12015-04-27 22:27:00 -04004511
4512 [truetype] Speed up IUP.
4513
4514 * src/truetype/ttinterp.c (_iup_worker_interpolate): Separate trivial
4515 snapping to the same position from true interpolation.
4516
Werner Lemberg12661a52015-04-21 07:13:59 +020045172015-04-21 Werner Lemberg <wl@gnu.org>
4518
Werner Lemberg14df6b12015-04-22 11:14:35 +02004519 [autofit] By default, enable warping code but switch off warping.
4520
4521 Suggested by Behdad.
4522
4523 * include/config/ftoption.h: Define AF_CONFIG_OPTION_USE_WARPER.
4524
4525 * src/autofit/afmodule.c (af_autofitter_init): Initialize `warping'
4526 with `false'.
4527
45282015-04-21 Werner Lemberg <wl@gnu.org>
4529
Werner Lembergd164f702015-04-21 07:51:41 +02004530 * docs/CHANGES: Updated.
4531
45322015-04-21 Werner Lemberg <wl@gnu.org>
4533
Werner Lemberg12661a52015-04-21 07:13:59 +02004534 [autofit] Introduce `warping' property.
4535
4536 This code replaces the debugging hook from the previous commit with
4537 a better, more generic solution.
4538
4539 * include/ftautoh.h: Document it.
4540
4541 * src/autofit/afmodule.h (AF_ModuleRec)
4542 [AF_CONFIG_OPTION_USE_WARPER]: Add `warping' field.
4543
4544 * src/autofit/afmodule.c (_af_debug_disable_warper): Remove.
4545 (af_property_set, af_property_get, af_autofitter_init)
4546 [AF_CONFIG_OPTION_USE_WARPER]: Handle `warping' option.
4547
4548 * src/autofit/afhints.h (AF_HINTS_DO_WARP): Remove use of the no
4549 longer existing `_af_debug_disable_warper'.
4550
4551 * src/autofit/afcjk.c (af_cjk_hints_init), src/autofit/aflatin.c
4552 (af_latin_hints_init), src/autofit/aflatin2.c (af_latin2_hints_init)
4553 [AF_CONFIG_OPTION_USE_WARPER]: Add `AF_SCALER_FLAG_NO_WARPER' to the
4554 scaler flags if warping is off.
4555
4556 * src/autofit/aftypes.h: Updated.
4557
Werner Lemberg58f48f02015-04-16 20:11:49 +020045582015-04-16 Werner Lemberg <wl@gnu.org>
4559
4560 [autofit] Add debugging hook to disable warper.
4561
4562 * src/autofit/afmodule.c (_af_debug_disable_warper)
4563 [FT_DEBUG_AUTOFIT]: New global variable.
4564
4565 * src/autofit/aftypes.h: Updated.
4566 (AF_SCALER_FLAG_NO_WARPER): New macro (not actively used yet).
4567
4568 * src/autofit/afhints.h (AF_HINTS_DO_WARP): New macro.
4569
Alexei Podtelezhnikovc6d99a42016-04-08 00:05:50 -04004570 * src/autofit/aflatin.c (af_latin_hints_apply)
Werner Lemberg58f48f02015-04-16 20:11:49 +02004571 [AF_CONFIG_OPTION_USE_WARPER]: Use `AF_HINTS_DO_WARP' to control use
4572 of warper.
4573
4574 * src/autofit/afcjk.c (af_cjk_hints_init, af_cjk_hints_apply)
4575 [AF_CONFIG_OPTION_USE_WARPER]: Synchronize with `aflatin.c'.
4576
4577 * src/autofit/aflatin2.c (af_latin2_hints_apply)
4578 [AF_CONFIG_OPTION_USE_WARPER]: Synchronize with `aflatin.c'.
4579
Werner Lemberg5cd21552015-04-10 07:01:01 +020045802015-04-10 Werner Lemberg <wl@gnu.org>
4581
4582 [cff] Update advance width handling to OpenType 1.7.
4583
4584 Problem reported by Behdad.
4585
4586 * src/cff/cffdrivr.c (cff_get_advances): Handle SFNT case
4587 separately.
4588
4589 * src/cff/cffgload.c (cff_slot_load): Use advance width and side
4590 bearing values from `hmtx' table if present.
4591
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040045922015-04-03 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov67b912d2015-04-03 22:38:11 -04004593
4594 * src/autofit/afhints.c (af_glyph_hints_reload): Use do-while loop.
4595
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040045962015-04-02 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov770b5d02015-04-02 23:15:36 -04004597
4598 * src/autofit/aflatin.c (af_latin_hint_edges): Reduce logic.
4599
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040046002015-04-01 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov886f4d02015-04-01 22:57:43 -04004601
4602 [autofit] Finish the thought.
4603
4604 * src/autofit/afhints.c (af_direction_compute): make sure the long arm
4605 is never negative so that its `FT_ABS' is not necessary.
4606
Werner Lemberg16217e52015-04-01 13:13:56 +020046072015-04-01 Werner Lemberg <wl@gnu.org>
4608
Werner Lemberga2fa6572015-04-01 15:55:41 +02004609 [autofit] Call dumper functions for tracing.
4610
4611 * src/autofit/afcjk.c (af_cjk_hints_apply): Remove dead code.
4612 * src/autofit/afhints.c (af_glyph_hints_dump_points): Minor
4613 improvement.
4614 * src/autofit/afmodule.c (af_autofitter_load_glyph): Implement it.
4615
46162015-04-01 Werner Lemberg <wl@gnu.org>
4617
Werner Lembergdb8df792015-04-01 13:30:55 +02004618 [autofit] Make debugging stuff work again.
4619
4620 The interface to ftgrid was broken in the series of commits starting
4621 with
4622
4623 [autofit] Allocate AF_Loader on the stack instead of AF_Module.
4624
4625 from 2015-01-14.
4626
4627 * src/autofit/afmodule.c (_af_debug_hints_rec) [FT_DEBUG_AUTOFIT]:
4628 Use a global AF_GlyphHintsRec object for debugging.
4629 (af_autofitter_done, af_autofitter_load_glyph): Updated.
4630
4631 * src/autofit/afloader.c (af_loader_init, af_loader_done): Updated.
4632
46332015-04-01 Werner Lemberg <wl@gnu.org>
4634
Werner Lemberg16217e52015-04-01 13:13:56 +02004635 * src/autofit/afhints.c (af_glyph_hints_done): Fix minor thinko.
4636
Werner Lemberg10e2bb82015-03-29 13:32:47 +020046372015-03-29 Werner Lemberg <wl@gnu.org>
4638
Werner Lembergf353a382015-03-29 14:47:49 +02004639 [cff] Fix Savannah bug #44629.
4640
4641 * src/cff/cf2font.h (CF2_MAX_SUBR), src/cff/cffgload.h
4642 (CFF_MAX_SUBRS_CALLS): Set to 16.
4643
46442015-03-29 Werner Lemberg <wl@gnu.org>
4645
Werner Lemberg10e2bb82015-03-29 13:32:47 +02004646 [type1, truetype] Make the MM API more flexible w.r.t. `num_coords'.
4647
4648 This commit allows `num_coords' to be larger or smaller than the
4649 number of available axes while selecting a design instance, either
4650 ignoring excess data or using defaults if data is missing.
4651
4652 * src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design):
4653 Implement it.
4654
4655 * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design,
4656 T1_Set_Var_Design): Ditto.
4657
46582015-03-29 Werner Lemberg <wl@gnu.org>
Werner Lemberg8ce30262015-03-27 08:33:47 +01004659
Werner Lembergdd5d6d72015-03-29 10:04:22 +02004660 [type1] Minor.
4661
4662 * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design): Use
4663 FT_THROW.
4664 (T1_Set_Var_Design): Use T1_MAX_MM_AXIS and FT_THROW.
4665
46662015-03-27 Werner Lemberg <wl@gnu.org>
4667
Werner Lemberg8ce30262015-03-27 08:33:47 +01004668 [cff] Trace charstring nesting levels.
4669
4670 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdCALLGSUBR,
4671 cf2_cmdCALLSUBR, cf2_cmdRETURN>: Implement it.
4672
4673 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
4674 <cff_op_callsubr, cff_op_callgsubr, cff_op_return>: Ditto.
4675
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040046762015-03-21 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovdac56442015-03-21 23:30:16 -04004677
4678 [base] Optimize `FT_Angle_Diff'.
4679
4680 Under normal circumstances we are usually close to the desired range
4681 of angle values, so that the remainder is not really necessary.
4682
4683 * src/base/fttrigon.c (FT_Angle_Diff): Use loops instead of remainder.
4684
4685 * src/autofit/aftypes.h (AF_ANGLE_DIFF): Ditto in the unused macro.
4686
Werner Lemberg6cc425d2015-03-21 06:51:07 +010046872015-03-21 Werner Lemberg <wl@gnu.org>
4688
4689 [truetype] Improve `gvar' handling.
4690
4691 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Correctly handle
4692 single-element runs. Cf. glyph `Q' in Skia.ttf with weights larger
4693 than the default.
4694
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040046952015-03-20 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov2d7284e2015-03-20 21:34:19 -04004696
4697 * src/base/fttrigon.c (FT_Vector_Rotate): Minor refactoring.
4698
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040046992015-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov6a171722015-03-17 22:43:08 -04004700
4701 Fix Savannah bug #44412 (part 2).
4702
4703 * src/base/fttrigon.c (FT_Sin, FT_Cos, FT_Tan): Call `FT_Vector_Unit'.
4704
Werner Lemberg06339952015-03-11 06:30:23 +010047052015-03-11 Werner Lemberg <wl@gnu.org>
4706
Werner Lembergd3284462015-03-11 16:45:58 +01004707 [autofit] Add support for Arabic script.
4708
4709 Thanks to Titus Nemeth <tn@tntypography.eu> for guidance!
4710
4711 * src/autofit/afblue.dat: Add blue zone data for Arabic.
4712
4713 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4714
4715 * src/autofit/afscript.h: Add Arabic standard characters.
4716
4717 * src/autofit/afranges.c: Add Arabic data.
4718
4719 * src/autofit/afstyles.h: Add Arabic data.
4720
4721 * docs/CHANGES: Document it.
4722
47232015-03-11 Werner Lemberg <wl@gnu.org>
4724
Werner Lemberga4516382015-03-11 08:09:13 +01004725 Rename `svxf86nm.h' to `svfntfmt.h'; update related symbols.
4726
4727 * include/internal/ftserv.h (FT_SERVICE_XFREE86_NAME_H): Renamed
4728 to...
4729 (FT_SERVICE_FONT_FORMAT_H): This.
4730
4731 * include/internal/services/svfntfmt.h (FT_XF86_FORMAT_*): Renamed
4732 to ...
4733 (FT_FONT_FORMAT_*): This.
4734
4735 src/base/ftfntfmt.c, src/bdf/bdfdrivr.c, src/cff/cffdrivr.c,
4736 src/cid/cidriver.c, src/pcf/pcfdrivr.c, src/pfr/pfrdrivr.c,
4737 src/truetype/ttdriver.c, src/type1/t1driver.c,
4738 src/type42/t42drivr.c, src/winfonts/winfnt.c: Updated.
4739
47402015-03-11 Werner Lemberg <wl@gnu.org>
4741
Werner Lembergdd7028c2015-03-11 07:45:05 +01004742 [base] Rename `FT_XFREE86_H' to `FT_FONT_FORMATS_H'.
4743
4744 * include/config/ftheader.h: Implement it.
4745 * src/base/ftfntfmt.c, docs/CHANGES: Updated.
4746
47472015-03-11 Werner Lemberg <wl@gnu.org>
4748
Werner Lembergf4d1c112015-03-11 07:32:58 +01004749 [base] Rename `FT_Get_X11_Font_Format' to `FT_Get_Font_Format'.
4750
4751 * include/ftfntfmt.h, src/base/ftfntfmt.c: Implement it.
4752
4753 * docs/CHANGES: Updated.
4754
47552015-03-11 Werner Lemberg <wl@gnu.org>
4756
Werner Lembergcb0f7b62015-03-11 06:51:27 +01004757 Fix automatic copyright updating.
4758
4759 * src/tools/update-copyright: Make scanning of `no-copyright'
4760 actually work.
4761
4762 * src/tools/no-copyright: Don't include README in general.
4763
47642015-03-11 Werner Lemberg <wl@gnu.org>
4765
Werner Lemberg06339952015-03-11 06:30:23 +01004766 Rename `ftxf86.[ch]' to `ftfntfmt.[ch]'.
4767
4768 CMakeLists.txt, builds/amiga/makefile, builds/amiga/makefile.os4,
4769 builds/amiga/smakefile, builds/mac/FreeType.m68k_cfm.make.txt,
4770 builds/mac/FreeType.m68k_far.make.txt,
4771 builds/mac/FreeType.ppc_carbon.make.txt,
4772 builds/mac/FreeType.ppc_classic.make.txt, builds/symbian/bld.inf,
4773 builds/symbian/freetype.mmp, builds/wince/vc2005-ce/freetype.vcproj,
4774 builds/wince/vc2008-ce/freetype.vcproj,
4775 builds/windows/vc2005/freetype.vcproj,
4776 builds/windows/vc2008/freetype.vcproj,
4777 builds/windows/vc2010/freetype.vcxproj,
4778 builds/windows/vc2010/freetype.vcxproj.filters,
4779 builds/windows/visualc/freetype.dsp,
4780 builds/windows/visualc/freetype.vcproj,
4781 builds/windows/visualce/freetype.dsp,
4782 builds/windows/visualce/freetype.vcproj, docs/INSTALL.ANY,
4783 include/config/ftheader.h, include/ftfntfmt.h, modules.cfg,
4784 src/base/ftfntfmt.c, vms_make.com: Updated.
4785
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040047862015-03-10 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov6b832c82015-03-10 23:25:49 -04004787
4788 Fix Savannah bug #44412 (part 1).
4789
4790 * src/base/ftstroke.c (ft_stroker_inside): Handle near U-turns.
4791
Werner Lembergeee7d8b2015-03-10 11:15:15 +010047922015-03-10 Werner Lemberg <wl@gnu.org>
4793
4794 [base] Rename `FT_Bitmap_New' to `FT_Bitmap_Init'.
4795
4796 * include/ftbitmap.h, src/base/ftbitmap.c: Implement it.
4797 Update all callers.
4798
4799 * docs/CHANGES: Updated.
4800
Werner Lemberg493cc032015-03-06 05:38:31 +010048012015-03-06 Werner Lemberg <wl@gnu.org>
4802
4803 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix compiler warning.
4804
4805 Found by Alexei.
4806
Alexei Podtelezhnikov04e7c742016-06-04 23:05:59 -040048072015-03-05 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovdd7498d2015-03-05 22:51:36 -05004808
4809 * src/base/ftstroke.c: Simplify.
4810
Werner Lemberg328b7922015-03-04 08:40:23 +010048112015-03-04 Werner Lemberg <wl@gnu.org>
4812
4813 [truetype] Some fixes and code refactoring in `ttgxvar.c'.
4814
4815 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Fix return value
4816 of `point_cnt' if two bytes are read.
4817 Use a more vertical coding style.
4818 (ft_var_readpackeddeltas): Use FT_UInt for `delta_cnt' parameter.
4819 Use a more vertical coding style.
4820
Werner Lemberga374c9c2015-03-03 11:23:45 +010048212015-03-03 Werner Lemberg <wl@gnu.org>
4822
4823 [autofit] Fix Savannah bug #44241.
4824
4825 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Reject glyphs
4826 with less than 3 points.
4827
Werner Lemberga07029e2015-03-02 06:54:08 +010048282015-03-02 Werner Lemberg <wl@gnu.org>
4829
4830 Simplify `TYPEOF' macro.
4831
4832 No need for two arguments.
4833
4834 * include/config/ftconfig.h, builds/unix/ftconfig.in,
4835 builds/vms/ftconfig.h (TYPEOF): Updated.
4836
4837 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
4838 src/autofit/afwarp.h (AF_WARPER_FLOOR): Updated.
4839
48402015-03-01 Werner Lemberg <wl@gnu.org>
Werner Lemberg4b9234b2015-02-25 06:31:43 +01004841
Werner Lemberg851e8152015-03-01 19:27:09 +01004842 Various compiler warning fixes for `make multi'.
4843
4844 * src/autofit/afcjk.c (af_cjk_hints_compute_blue_edges),
4845 src/autofit/aflatin.c (af_latin_hint_compute_blue_edges,
4846 af_latin_hint_edges), src/autofit/aflatin2.c
4847 (af_latin2_hints_compute_blue_edges, af_latin2_hint_edges): Declare
4848 as `static'.
4849
4850 * src/cache/ftccmap.c (FTC_CMAP_QUERY_HASH, FTC_CMAP_NODE_HASH):
4851 Removed. Unused.
4852 * src/cache/ftcimage.c: Include FT_INTERNAL_OBJECTS_H.
4853 * src/cache/ftcmanag.c (FTC_LRU_GET_MANAGER): Removed. Unused.
4854
4855 * src/cff/cf2intrp.c: Include `cf2intrp.h'.
4856 * src/cff/cffdrivr.c (PAIR_TAG): Removed. Unused.
4857
4858 * src/gzip/ftgzip.c (NO_DUMMY_DECL): Removed. Unused.
4859
4860 * src/psaux/afmparse.c (afm_parser_read_int): Declare as `static'.
4861
4862 * src/pshinter/pshalgo.c (STRONGER, PSH_ZONE_MIN, PSH_ZONE_MAX):
4863 Removed. Unused.
4864
4865 * src/raster/ftraster.c (Render_Glyph): Declare as `static'.
4866
4867 * src/sfnt/ttpost.c (load_format_20): Fix signedness warning.
4868
4869 * src/truetype/ttdriver.c (PAIR_TAG): Removed. Unused.
4870 * src/truetype/ttsubpix.c (is_member_of_family_class,
4871 is_member_of_style_class): Declare as `static'.
4872
4873 * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Declare
4874 as `static'.
4875 * src/type1/t1load.c (mm_axis_unmap, mm_weights_unmap): Declare as
4876 `static'.
4877 (T1_FIELD_COUNT): Removed. Unused.
4878 * src/type1/t1parse.h (T1_Done_Table): Removed. Unused.
4879
4880 * src/type42/t42parse.c (T1_Done_Table): Removed. Unused.
4881
48822015-02-25 Werner Lemberg <wl@gnu.org>
4883
Werner Lemberg04c22372015-02-25 11:20:20 +01004884 [psaux] Signedness fixes.
4885
4886 * include/internal/psaux.h, src/psaux/afmparse.c,
4887 src/psaux/afmparse.h, src/psaux/psconv.c, src/psaux/psobjs.c,
4888 src/psaux/t1cmap.c, src/psaux/t1decode.c: Apply.
4889
48902015-02-25 Werner Lemberg <wl@gnu.org>
4891
Werner Lembergd25ec162015-02-25 09:19:59 +01004892 [otvalid] Signedness fixes.
4893
4894 * src/otvalid/otvcommn.c, src/otvalid/otvgdef.c,
4895 src/otvalid/otvgpos.c, src/otvalid/otvgsub.c, src/otvalid/otvmath.c:
4896 Apply.
4897
48982015-02-25 Werner Lemberg <wl@gnu.org>
4899
Werner Lemberg5c9d9bf2015-02-25 08:13:40 +01004900 * src/bzip2/ftbzip2.c (ft_bzip2_alloc): Signedness fix.
4901
49022015-02-25 Werner Lemberg <wl@gnu.org>
4903
Werner Lemberg83d41812015-02-25 08:10:58 +01004904 [lzw] Signedness fixes.
4905
4906 * src/lzw/ftzopen.c, src/lzw/ftzopen.h: Apply.
4907
49082015-02-25 Werner Lemberg <wl@gnu.org>
4909
Werner Lemberg17b62912015-02-25 07:53:09 +01004910 [gxvalid] Signedness fixes.
4911
4912 * src/gxvalid/gxvbsln.c, src/gxvalid/gxvcommn.c,
4913 src/gxvalid/gxvcommn.h, src/gxvalid/gxvjust.c,
4914 src/gxvalid/gxvkern.c, src/gxvalid/gxvlcar.c, src/gxvalid/gxvmort.c,
4915 src/gxvalid/gxvmort1.c, src/gxvalid/gxvmort2.c,
4916 src/gxvalid/gxvmorx.c, src/gxvalid/gxvmorx1.c,
4917 src/gxvalid/gxvmorx2.c, src/gxvalid/gxvopbd.c,
4918 src/gxvalid/gxvprop.c, src/gxvalid/gxvtrak.c: Apply.
4919
49202015-02-25 Werner Lemberg <wl@gnu.org>
4921
Werner Lemberg24e4e962015-02-25 06:57:16 +01004922 [cache] Signedness fixes.
4923
4924 * src/cache/ftcbasic.c, src/cache/ftccmap.c, src/cache/ftcimage.c,
4925 src/cache/ftcmanag.c, src/cache/ftcsbits.c: Apply.
4926
49272015-02-25 Werner Lemberg <wl@gnu.org>
4928
Werner Lemberg559727d2015-02-25 06:55:00 +01004929 Change dimension fields in `FTC_ImageTypeRec' to unsigned type.
4930
4931 This doesn't break ABI.
4932
4933 * include/ftcache.h (FTC_ImageTypeRec): Use unsigned types for
4934 `width' and `height'.
4935
4936 * docs/CHANGES: Document it.
4937
49382015-02-25 Werner Lemberg <wl@gnu.org>
4939
Werner Lemberg4b9234b2015-02-25 06:31:43 +01004940 [cache] Don't use `labs'.
4941
4942 This is the only place in FreeType where this function was used.
4943
4944 * include/config/ftstdlib.h (ft_labs): Remove.
4945
4946 * src/cache/ftcimage.c (ftc_inode_weight): Replace `ft_labs' with
4947 `FT_ABS'.
4948
Werner Lemberg4d1f7af2015-02-23 07:04:36 +010049492015-02-23 Werner Lemberg <wl@gnu.org>
4950
Werner Lemberg3aaebe32015-02-23 08:20:27 +01004951 [cache] Replace `FT_PtrDist' with `FT_Offset'.
4952
4953 * src/cache/ftccache.h (FTC_NodeRec): `FT_Offset' (a.k.a. `size_t')
4954 is a better choice for `hash' to hold a pointer than `FT_PtrDist'
4955 (a.k.a. `ptrdiff_t'), especially since the latter is signed,
4956 causing zillions of signedness warnings. [Note that `hash' was of
Werner Lemberg17b62912015-02-25 07:53:09 +01004957 type `FT_UInt32' before the change to `FT_PtrDist'.]
Werner Lemberg3aaebe32015-02-23 08:20:27 +01004958 Update all users.
4959
4960 * src/cache/ftcbasic.c, src/cache/ftccache.c, src/cache/ftccmap.c,
4961 src/cache/ftcglyph.c, src/cache/ftcglyph.h: Updated.
4962
49632015-02-23 Werner Lemberg <wl@gnu.org>
4964
Werner Lemberg4d1f7af2015-02-23 07:04:36 +01004965 [smooth, raster] Re-enable standalone compilation.
4966
4967 * src/raster/ftraster.c (FT_RENDER_POOL_SIZE, FT_MAX)
4968 [_STANDALONE_]: Define macros.
4969
4970 * src/smooth/ftgrays.c (FT_RENDER_POOL_SIZE, FT_MAX, FT_ABS,
4971 FT_HYPOT) [_STANDALONE_]: Define macros.
4972
Werner Lemberg03ccfd02015-02-22 08:25:16 +010049732015-02-22 Werner Lemberg <wl@gnu.org>
4974
Werner Lembergcb13e712015-02-23 06:41:52 +01004975 [smooth] Signedness fixes.
4976
4977 * src/smooth/ftgrays.c, src/smooth/ftsmooth.c: Apply.
4978
49792015-02-22 Werner Lemberg <wl@gnu.org>
4980
Werner Lemberga974e9a2015-02-22 21:02:13 +01004981 * src/raster/ftraster.c: Use the file's typedefs everywhere.
4982
49832015-02-22 Werner Lemberg <wl@gnu.org>
4984
Werner Lembergb0ebcdc2015-02-22 20:42:49 +01004985 * src/sfnt/ttpost.c (load_format_20): Fix error tracing message.
4986
4987 Bug introduced 6 commits earlier.
4988
49892015-02-22 Werner Lemberg <wl@gnu.org>
4990
Werner Lemberg22b1d5c2015-02-22 20:41:03 +01004991 [pshinter] Fix thinko.
4992
4993 * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Correctly
4994 check `count'.
4995 Bug introduced two commits earlier.
4996
49972015-02-22 Werner Lemberg <wl@gnu.org>
4998
Werner Lembergca96fe02015-02-22 20:05:04 +01004999 [raster] Signedness fixes.
5000
5001 * src/raster/ftraster.c, src/raster/ftrend1.c: Apply.
5002
50032015-02-22 Werner Lemberg <wl@gnu.org>
5004
Werner Lemberg452066c2015-02-22 15:59:02 +01005005 [pshinter] Signedness fixes.
5006
5007 * src/pshinter/pshalgo.c, src/pshinter/pshglob.c,
5008 src/pshinter/pshrec.c: Apply.
5009
50102015-02-22 Werner Lemberg <wl@gnu.org>
5011
Werner Lemberg41c2ed82015-02-22 15:57:47 +01005012 [pshinter] Use macros for (unsigned) flags, not enumerations.
5013
5014 * src/pshinter/pshalgo.h (PSH_Hint_Flags): Replace with macros.
5015 Updated.
5016 * src/pshinter/pshrec.h (PS_Hint_Flags): Replace with macros.
5017
50182015-02-22 Werner Lemberg <wl@gnu.org>
5019
Werner Lemberg25c2f882015-02-22 15:54:31 +01005020 * src/pshinter/pshrec.c: Simplify.
5021 (ps_hints_open, ps_hints_stem): Remove switch statement.
5022
50232015-02-22 Werner Lemberg <wl@gnu.org>
5024
Werner Lemberg01f08422015-02-22 12:03:28 +01005025 [sfnt] Signedness fixes.
5026
5027 * src/sfnt/pngshim.c, src/sfnt/sfobjs.c, src/sfnt/ttcmap.c,
5028 src/sfnt/ttkern.c, src/sfnt/ttload.c, src/sfnt/ttpost.c,
5029 src/sfnt/ttsbit.c: Apply.
5030 * src/sfnt/sfdriver.c: Apply.
5031 (sfnt_get_ps_name): Simplify.
5032
50332015-02-22 Werner Lemberg <wl@gnu.org>
5034
Werner Lemberg3c374c82015-02-22 09:16:53 +01005035 [bdf] Signedness fixes.
5036
5037 * src/bdf/bdf.h, src/bdf/bdfdrivr.c, src/bdf/bdfdrivr.h,
5038 src/bdf/bdflib.c: Apply.
5039
50402015-02-22 Werner Lemberg <wl@gnu.org>
5041
Werner Lembergb13945a2015-02-22 09:15:47 +01005042 * src/bdf/bdflib.c (_bdf_atous): New function.
5043 (_bdf_parse_glyphs, _bdf_parse_start): Use it.
5044
50452015-02-22 Werner Lemberg <wl@gnu.org>
5046
Werner Lemberg03ccfd02015-02-22 08:25:16 +01005047 [pcf] Signedness fixes.
5048
5049 * src/pcf/pcf.h, src/pcf/pcfdrivr.c: Apply.
5050 * src/pcf/pcfread.c: Apply.
5051 (pcf_get_encodings): Ignore invalid negative encoding offsets.
5052
Werner Lemberg633a7292015-02-21 07:02:01 +010050532015-02-21 Werner Lemberg <wl@gnu.org>
5054
Werner Lemberg3d7e53f2015-02-21 11:30:54 +01005055 * src/winfonts/winfnt.c: Signedness fixes.
5056
50572015-02-21 Werner Lemberg <wl@gnu.org>
5058
Werner Lemberg7b6b4172015-02-21 10:39:34 +01005059 [type42] Signedness fixes.
5060
5061 * src/type42/t42parse.c, src/type42/t42parse.h,
5062 src/type42/t42types.h: Apply.
5063
50642015-02-21 Werner Lemberg <wl@gnu.org>
5065
Werner Lemberg8bfffb42015-02-21 09:52:29 +01005066 [pfr] Signedness fixes.
5067
5068 * src/pfr/pfrdrivr.c, src/pfr/pfrgload.c, src/pfr/pfrload.c,
5069 src/pfr/pfrload.h, src/pfr/pfrobjs.c, src/pfr/pfrsbit.c,
5070 src/pfr/pfrtypes.h: Apply.
5071
50722015-02-21 Werner Lemberg <wl@gnu.org>
5073
Werner Lemberg633a7292015-02-21 07:02:01 +01005074 [cff] Minor signedness fixes related to last commit.
5075
5076 * src/cff/cf2ft.c, src/cff/cf2intrp.c, src/cff/cffgload.c: Apply.
5077
Werner Lemberg3a8d0532015-02-20 08:35:32 +010050782015-02-20 Werner Lemberg <wl@gnu.org>
5079
Werner Lembergc00b05f2015-02-20 20:42:55 +01005080 [cff] Thinkos in bias handling.
5081
5082 Only the final result is always positive.
5083
5084 Bug introduced three commits earlier.
5085
5086 * src/cff/cffgload.c, src/cff/cffgload.h: Apply.
5087
50882015-02-20 Werner Lemberg <wl@gnu.org>
5089
Werner Lemberg2bf03eb2015-02-20 20:14:11 +01005090 [cid] Fix signedness issues and emit some better error codes.
5091
5092 * src/cid/cidgload.c, src/cid/cidload.h, src/cid/cidobjs.c,
5093 src/cid/cidparse.h: Apply.
5094 * src/cid/cidload.c: Apply.
5095 (parse_fd_array): Reject negative values for number of dictionaries.
5096 * src/cid/cidparse.c: Apply.
5097 (cid_parser_new): Reject negative values for hex data length.
5098
50992015-02-20 Werner Lemberg <wl@gnu.org>
5100
Werner Lembergeb05bfb2015-02-20 08:37:35 +01005101 [cff] Signedness fixes for new engine.
5102
5103 * src/cff/cf2arrst.c, src/cff/cf2fixed.h, src/cff/cf2ft.c,
5104 src/cff/cf2ft.h, src/cff/cf2hints.c, src/cff/cf2intrp.c: Apply.
5105
51062015-02-20 Werner Lemberg <wl@gnu.org>
5107
Werner Lemberg3a8d0532015-02-20 08:35:32 +01005108 [cff] Signedness fixes for basic infrastructure and old engine.
5109
5110 * include/internal/pshints.h, src/cff/cffdrivr.c,
5111 src/cff/cffgload.c, src/cff/cffgload.h, src/cff/cffload.c,
5112 src/cff/cffobjs.c, src/cff/cffparse.c, src/pshinter/pshrec.c: Apply.
5113
Werner Lemberg81e5ff52015-02-19 09:46:48 +010051142015-02-19 Werner Lemberg <wl@gnu.org>
5115
Werner Lemberg3a1df3e2015-02-19 15:42:48 +01005116 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Ignore `countSizePairs'.
5117
5118 This is hard-coded to value 2 in `fvar' version 1.0 (and no newer
5119 version exists), but some fonts set it incorrectly.
5120
5121 Problem reported by Adam Twardoch <adam@fontlab.com>.
5122
51232015-02-19 Werner Lemberg <wl@gnu.org>
5124
Werner Lemberg93a884c2015-02-19 14:11:16 +01005125 [cff] Emit better error code for invalid private dict size.
5126
5127 * src/cff/cffparse.c (cff_parse_private_dict): Reject negative
5128 values for size and offset.
5129
51302015-02-19 Werner Lemberg <wl@gnu.org>
5131
Werner Lembergb57bb112015-02-19 10:44:18 +01005132 [autofit] Fix signedness issues.
5133
5134 * src/autofit/afangles.c, src/autofit/afcjk.c,
5135 src/autofit/afglobal.c, src/autofit/afhints.c,
5136 src/autofit/aflatin.c, src/autofit/aflatin2.c, src/autofit/afwarp.c,
5137 src/autofit/hbshim.c: Apply.
5138
51392015-02-19 Werner Lemberg <wl@gnu.org>
5140
Werner Lemberg81e5ff52015-02-19 09:46:48 +01005141 [autofit] Use macros for (unsigned) flags, not enumerations.
5142
5143 This harmonizes with other code in FreeType (and reduces the number
5144 of necessary casts to avoid compiler warnings).
5145
5146 * src/autofit/afblue.hin: Make flag macros unsigned.
5147 * src/autofit/afblue.h: Regenerated.
5148
5149 * src/autofit/afcjk.h: Replace flag enumeration with macros.
5150 * src/autofit/afcjk.c: Updated.
5151
5152 * src/autofit/afhints.h (AF_Flags, AF_Edge_Flags): Replace with
5153 macros.
5154 * src/autofit/afhints.c: Updated.
5155
5156 * src/autofit/aflatin.h: Replace flag enumerations with macros.
5157 * src/autofit/aflatin.c, src/autofit/aflatin2.c: Updated.
5158
5159 * src/autofit/aftypes.h (AF_ScalerFlags): Replace with macros.
5160
Werner Lemberg6a0ded72015-02-18 08:51:22 +010051612015-02-18 Werner Lemberg <wl@gnu.org>
5162
Werner Lemberg3b5f3322015-02-18 11:45:22 +01005163 [type1] Fix signedness issues.
5164
5165 * include/internal/psaux.h, include/internal/t1types.h,
5166 src/psaux/psobjs.c, src/psaux/psobjs.h, src/psaux/t1decode.c,
5167 src/type1/t1gload.c, src/type1/t1load.c, src/type1/t1parse.c: Apply.
5168
51692015-02-18 Werner Lemberg <wl@gnu.org>
5170
Werner Lemberg272e3cd2015-02-18 11:38:46 +01005171 [psaux, type1] Fix minor AFM issues.
5172
5173 * include/internal/t1types.h (AFM_KernPairRec): Make indices
5174 unsigned.
5175 Update users.
5176 (AFM_FontInfoRec): Make element counters unsigned.
5177 Update users.
5178 * src/psaux/afmparse.h (AFM_ValueRec): Add union member for unsigned
5179 int.
5180
5181 * src/psaux/afmparse.c (afm_parse_track_kern, afm_parse_kern_pairs):
5182 Reject negative values for number of kerning elements.
5183
5184 * src/type1/t1afm.c, src/tools/test_afm.c: Updated.
5185
51862015-02-18 Werner Lemberg <wl@gnu.org>
5187
Werner Lemberg6bd7d282015-02-18 09:22:06 +01005188 Don't use `FT_PtrDist' for lengths.
5189
5190 Use FT_UInt instead.
5191
5192 * include/internal/psaux.h (PS_Table_FuncsRec, PS_TableRec,
5193 T1_DecoderRec): Do it.
5194
5195 * include/internal/t1types.h (T1_FontRec): Ditto.
5196
5197 * src/cid/cidload.c (cid_parse_dict): Updated.
5198 * src/pfr/pfrload.c (pfr_extra_item_load_font_id): Ditto.
5199 * src/psaux/psobjs.c (ps_table_add), src/psaux/psobjs.h: Ditto.
5200 * src/type1/t1load.c (parse_blend_axis_types, parse_encoding,
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04005201 parse_charstrings, parse_dict): Ditto.
Werner Lemberg6bd7d282015-02-18 09:22:06 +01005202 * src/type42/t42parse.c (t42_parse_encoding, t42_parse_charstrings,
5203 t42_parse_dict): Ditto.
5204
52052015-02-18 Werner Lemberg <wl@gnu.org>
5206
Werner Lemberg6a0ded72015-02-18 08:51:22 +01005207 * src/type1/t1driver.c (t1_ps_get_font_value): Clean up.
5208 This handles negative values better, avoiding many casts.
5209
Werner Lemberg0a33a392015-02-17 08:03:05 +010052102015-02-17 Werner Lemberg <wl@gnu.org>
5211
Werner Lembergd3240c52015-02-17 20:30:36 +01005212 [base] Fix Savannah bug #44284.
5213
5214 * src/base/ftcalc.c (FT_MulFix): Typos.
5215
52162015-02-17 Werner Lemberg <wl@gnu.org>
5217
Werner Lemberg1f7a4e12015-02-17 10:17:56 +01005218 [truetype] Finish compiler warning fixes for signedness issues.
5219
5220 * src/truetype/ttgxvar.c, src/truetype/ttsubpix.c,
5221 src/truetype/ttsubpix.h: Apply.
5222
52232015-02-17 Werner Lemberg <wl@gnu.org>
5224
Werner Lemberg9daea2c2015-02-17 09:27:56 +01005225 * src/truetype/ttsubpix.c: Adding missing `static' keywords.
5226
52272015-02-17 Werner Lemberg <wl@gnu.org>
5228
Werner Lembergd9c3f152015-02-17 09:21:26 +01005229 [truetype] More signedness fixes.
5230
5231 * include/internal/tttypes.h, src/truetype/ttinterp.h,
5232 src/truetype/ttobjs.h, src/truetype/ttinterp.c,
5233 src/truetype/ttobjs.c: Apply.
5234
52352015-02-17 Werner Lemberg <wl@gnu.org>
5236
Werner Lemberg0a33a392015-02-17 08:03:05 +01005237 [truetype] Various signedness fixes.
5238
5239 * include/internal/ftgloadr.h, src/truetype/ttpload.c: Apply.
5240
5241 * src/truetype/ttgload.c: Apply.
5242 (TT_Get_VMetrics): Protect against invalid ascenders and descenders
5243 while constructing advance height.
5244
Werner Lemberg587351b2015-02-16 07:03:22 +010052452015-02-16 Werner Lemberg <wl@gnu.org>
5246
Werner Lemberg76abc752015-02-16 22:00:27 +01005247 [base] Finish compiler warning fixes for signedness issues.
5248
5249 * src/base/ftglyph.c, src/base/ftlcdfil.c, src/base/ftstroke.c:
5250 Apply.
5251
52522015-02-16 Werner Lemberg <wl@gnu.org>
5253
Werner Lemberg10aa8582015-02-16 20:12:54 +01005254 * include/tttables.h (TT_OS2): `fsType' must be FT_UShort.
5255
52562015-02-16 Werner Lemberg <wl@gnu.org>
5257
Werner Lemberg2e814fc2015-02-16 20:05:08 +01005258 More minor signedness warning fixes.
5259
5260 * src/base/ftbbox.c, src/base/ftbitmap.c, src/base/fttrigon.c,
5261 src/base/ftutil.c: Apply.
5262
52632015-02-16 Werner Lemberg <wl@gnu.org>
5264
Werner Lemberg82235d02015-02-16 19:35:16 +01005265 Next round of minor compiler warning fixes.
5266
5267 * include/internal/ftrfork.h (FT_RFork_Ref): Change `offset' member
5268 type to `FT_Long'.
5269 (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Add `static' keyword.
5270
Werner Lemberg3aaebe32015-02-23 08:20:27 +01005271 * include/internal/ftstream.h (FT_Stream_Pos): Return `FT_ULong'.
Werner Lemberg82235d02015-02-16 19:35:16 +01005272
5273 * src/base/ftoutln.c, src/base/ftrfork.c, src/base/ftstream.c:
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04005274 Signedness fixes.
Werner Lemberg82235d02015-02-16 19:35:16 +01005275
52762015-02-16 Werner Lemberg <wl@gnu.org>
5277
Werner Lemberg3cfa4d12015-02-16 17:59:06 +01005278 Various minor signedness fixes.
5279
5280 * include/ftadvanc.h, include/internal/ftobjs.h,
5281 src/base/ftgloadr.c, src/base/ftobjs.c: Apply.
5282
52832015-02-16 Werner Lemberg <wl@gnu.org>
5284
Werner Lemberg6f325c22015-02-16 11:31:32 +01005285 New `TYPEOF' macro.
5286
5287 This helps suppress signedness warnings, avoiding issues with
5288 implicit conversion changes.
5289
5290 * include/config/ftconfig.h, builds/unix/ftconfig.in,
5291 builds/vms/ftconfig.h (TYPEOF): Define.
5292
5293 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
5294 src/autofit/afwarp.h (AF_WARPER_FLOOR): Use it.
5295
52962015-02-16 Werner Lemberg <wl@gnu.org>
5297
Werner Lemberg1f377f02015-02-16 08:37:09 +01005298 * src/base/ftsystem.c: Use casts in standard C function wrappers.
5299 (ft_alloc, ft_realloc, ft_ansi_stream_io, FT_Stream_Open): Do it.
5300
53012015-02-16 Werner Lemberg <wl@gnu.org>
5302
Werner Lemberg0814b802015-02-16 07:29:53 +01005303 Fix Savannah bug #44261.
5304
5305 * builds/unix/detect.mk (setup) [unix]: Set `CONFIG_SHELL' in the
5306 environment also while calling the configure script.
5307
53082015-02-16 Werner Lemberg <wl@gnu.org>
5309
Werner Lemberg587351b2015-02-16 07:03:22 +01005310 * include/internal/ftmemory.h: Add some `FT_Offset' casts.
5311 (FT_MEM_SET, FT_MEM_COPY, FT_MEM_MOVE, FT_ARRAY_ZERO, FT_ARRAY_COPY,
5312 FT_MEM_MOVE): Do it.
5313
Werner Lemberg6d7d6362015-02-15 12:30:42 +010053142015-02-15 Werner Lemberg <wl@gnu.org>
5315
Werner Lemberg48186b82015-02-16 06:37:36 +01005316 [base] Clean up signedness issues in `ftdbgmem.c'.
5317
5318 Also fix other minor issues.
5319
5320 * src/base/ftdbgmem.c (FT_MemTableRec): Replace all FT_ULong types
5321 with FT_Long for consistency.
5322 (ft_mem_primes): Change type to `FT_Int'.
5323 (ft_mem_closest_prime, ft_mem_table_set): Updated.
5324
5325 (ft_mem_debug_panic, ft_mem_debug_alloc, ft_mem_debug_free,
5326 ft_mem_debug_realloc): Use `static' keyword and fix signedness
5327 warnings where necessary.
5328
5329 (ft_mem_table_resize, ft_mem_table_new, ft_mem_table_destroy,
5330 ft_mem_table_get_nodep, ft_mem_debug_init, FT_DumpMemory): Fix types
5331 and add or remove casts to avoid signedness warnings.
5332
53332015-02-15 Werner Lemberg <wl@gnu.org>
5334
Werner Lemberg6d7d6362015-02-15 12:30:42 +01005335 [base] Clean up signedness in arithmetic functions.
5336
5337 This makes the code more readable and reduces compiler warnings.
5338
5339 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round, FT_MulFix,
5340 FT_DivFix): Convert input parameters to unsigned, do the
5341 computation, then convert the result back to signed.
5342 (ft_corner_orientation): Fix casts.
5343
Werner Lemberg92359bd2015-02-07 09:47:23 +010053442015-02-07 Werner Lemberg <wl@gnu.org>
5345
5346 [sfnt] Fix Savannah bug #44184.
5347
5348 * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir): No
5349 longer reject `htmx' and `vmtx' tables with invalid length but
5350 sanitize them.
5351
Jon Anderson416d8792015-02-06 10:16:45 +010053522015-02-06 Jon Anderson <jon@websupergoo.com>
5353
5354 [truetype] Fix regression in the incremental glyph loader.
5355
5356 * src/truetype/ttgload.c (load_truetype_glyph): For incremental
5357 fonts, the glyph index may be greater than the number of glyphs
5358 indicated, so guard the check with a preprocessor conditional.
5359
Werner Lembergb6cb4992015-02-06 08:46:06 +010053602015-02-06 Werner Lemberg <wl@gnu.org>
5361
5362 [autofit] Fix potential memory leak.
5363
5364 While this doesn't show up with FreeType, exactly the same code
5365 leaks with ttfautohint's modified auto-hinter code (which gets used
5366 in a slightly different way).
5367
5368 It certainly doesn't harm since it is similar to already existing
5369 checks in the code for embedded arrays.
5370
5371 * src/autofit/afhints.c (af_glyph_hints_reload): Set `max_contours'
5372 and `max_points' for all cases.
5373
Werner Lemberg19146a52015-01-31 11:01:33 +010053742015-01-31 Werner Lemberg <wl@gnu.org>
5375
5376 [autofit] Add support for Thai script.
5377
5378 Thanks to Ben Mitchell <ben@rosettatype.com> for guidance with blue
5379 zone characters!
5380
5381 * src/autofit/afblue.dat: Add blue zone data for Thai.
5382
5383 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
5384
5385 * src/autofit/afscript.h: Add Thai standard characters.
5386
5387 * src/autofit/afranges.c: Add Thai data.
5388
5389 * src/autofit/afstyles.h: Add Thai data.
5390
Behdad Esfahbod264b5e42015-01-23 21:23:55 +010053912015-01-23 Behdad Esfahbod <behdad@behdad.org>
5392
5393 [raster] Handle `FT_RASTER_FLAG_AA' correctly.
5394
5395 This fixes a breakage caused by the commit `[raster] Remove
5396 5-level gray AA mode from monochrome rasterizer.'.
5397
Werner Lembergd2c531e2015-01-23 22:37:42 +01005398 Problem reported by Markus Trippelsdorf <markus@trippelsdorf.de>.
Behdad Esfahbod264b5e42015-01-23 21:23:55 +01005399
5400 * src/raster/ftraster.c (ft_black_render): Handle
5401 `FT_RASTER_FLAG_AA'.
5402
5403 * src/raster/ftrend1.c (ft_raster1_render): Remove gray AA mode
5404 remnants.
5405
Werner Lemberg79a5ac62015-01-18 07:30:04 +010054062015-01-18 Werner Lemberg <wl@gnu.org>
5407
5408 * src/base/ftobjs.c (FT_New_Library): Fix compiler warning.
5409
Chris Liddell942aa5f2015-01-18 07:29:48 +010054102015-01-18 Chris Liddell <chris.liddell@artifex.com>
5411
5412 [raster] Fix Savannah bug #44022.
5413
5414 Add fallback for glyphs with degenerate bounding boxes.
5415
5416 If a glyph has only one very narrow feature, the bbox can end up
5417 with either the width or height of the bbox being 0, in which case
5418 no raster memory is allocated and no attempt is made to render the
5419 glyph. This is less than ideal when the drop-out compensation in
5420 the rendering code would actually result in the glyph being
5421 rendered.
5422
5423 This problem can be observed with the `I' glyph (gid 47) in the
5424 Autodesk RomanS TrueType font.
5425
5426 * src/raster/ftrend1.c (ft_raster1_render): Add a fallback if either
5427 dimension is zero to explicitly round up/down (instead of simply
5428 round).
5429
Werner Lemberg50be00d2015-01-17 20:38:31 +010054302015-01-17 Werner Lemberg <wl@gnu.org>
5431
5432 Add some tools to handle yearly copyright notice updates.
5433
5434 We are now following the GNU guidelines: A new release automatically
5435 means that the copyright year of all affected files gets updated; it
5436 is no longer used to track years of modification changes.
5437
5438 * src/tools/update-copyright-year: New Perl script.
5439 * src/tools/update-copyright: New shell script that calls
5440 `update-copyright-year' on all files.
5441 * src/tools/no-copyright: Exceptions that should not be handled by
5442 `update-copyright'
5443
Werner Lemberg4eff8542015-01-14 20:06:19 +010054442015-01-14 Werner Lemberg <wl@gnu.org>
5445
5446 * docs/CHANGES: Updated, using a description from Behdad.
5447
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +010054482015-01-14 Behdad Esfahbod <behdad@behdad.org>
5449
Behdad Esfahbod48c86622015-01-14 19:38:36 +01005450 * src/autofit/afmodule.c (af_autofitter_done): Fix compiler warning.
5451
54522015-01-14 Behdad Esfahbod <behdad@behdad.org>
5453
Behdad Esfahbod56ddafa2015-01-14 19:36:02 +01005454 [autofit] Add embedded array of segments and edges.
5455
5456 Avoids multiple mallocs per typical glyphs.
5457
5458 With this and recent changes to avoid mallocs, the thread-safe
5459 stack-based loader is now as fast as the previous model that had one
5460 cached singleton.
5461
5462 * src/autofit/afhints.h (AF_SEGMENTS_EMBEDDED, AF_EDGES_EMBEDDED):
5463 New macros.
5464 (AF_AxisHintsRec): Add two arrays for segments and edges.
5465
5466 * src/autofit/afhints.c (af_axis_hints_new_segment): Only allocate
5467 data if number of segments exceeds given threshold value.
5468 (af_axis_hints_new_edge): Only allocate data if number of edges
5469 exceeds given threshold value.
5470 (af_glyph_hints_done): Updated.
5471
54722015-01-14 Behdad Esfahbod <behdad@behdad.org>
5473
Behdad Esfahbod6f16b102015-01-14 19:26:49 +01005474 [autofit] Add embedded arrays for points and contours.
5475
5476 This avoids at least two malloc calls for typical glyphs.
5477
5478 * src/autofit/afhints.h (AF_POINTS_EMBEDDED, AF_CONTOURS_EMBEDDED):
5479 New macros.
5480 (AF_GlyphHintsRec): Add two arrays for contours and points.
5481
5482 * src/autofit/afhints.c (af_glyph_hints_init, af_glyph_hints_done):
5483 Updated.
5484 (af_glyph_hints_reload): Only allocate data if number of contours or
5485 points exceeds given threshold values.
5486
54872015-01-14 Behdad Esfahbod <behdad@behdad.org>
5488
Behdad Esfahbodc2733652015-01-14 19:16:12 +01005489 [autofit] Allocate hints object on the stack.
5490
5491 This avoids one malloc per load.
5492
5493 * src/autofit/afloader.h (AF_LoaderRec): Change type of `hints' to
5494 `AF_GlyphHints'.
5495 Update prototype.
5496
5497 * src/autofit/afloader.c (af_loader_init): Use `AF_GlyphHints'
5498 parameter instead of `FT_Memory'.
5499 (af_loader_done): Directly reset `load_hints'.
5500 (af_loader_load_g): Updated.
5501
5502 * src/autofit/afmodule.c (af_autofitter_load_glyph): Use local
5503 `hints' object.
5504
55052015-01-14 Behdad Esfahbod <behdad@behdad.org>
5506
Behdad Esfahboda4117fb2015-01-14 19:07:54 +01005507 [autofit] Reuse slot glyph loader.
5508
5509 No need to create a new glyph loader; we can reuse the one from
5510 `slot->internal->loader'. It's hard to tell why it was written that
5511 way originally, but new code looks sound and correct to me, and
5512 avoids lots of allocations.
5513
5514 * src/autofit/afloader.c (af_loader_init): Change return type to
5515 `void'.
5516 Don't call `FT_GlyphLoader_New'.
5517 (af_loader_reset): Don't call `FT_GlyphLoader_Rewind'.
5518 (af_loader_load_g): Update code to use `internal->loader', which
5519 doesn't need copying of data.
5520
5521 * src/autofit/afloader.h (AF_LoaderRec): Remove `gloader' member.
5522 Update prototype.
5523
5524 * src/autofit/afmodule.c (af_autofitter_load_glyph): Updated.
5525
55262015-01-14 Behdad Esfahbod <behdad@behdad.org>
5527
Behdad Esfahbodae6699f2015-01-14 18:55:39 +01005528 [autofit] Remove (unused) support for composite glyphs.
5529
5530 We never have to deal with composite glyphs in the autohinter, as
5531 those will be loaded into FORMAT_OUTLINE by the recursed
5532 `FT_Load_Glyph' function.
5533
5534 In the rare cases that FT_LOAD_NO_RECURSE is set, it will imply
5535 FT_LOAD_NO_SCALE as per `FT_Load_Glyph', which then implies
5536 FT_LOAD_NO_HINTING:
5537
5538 /* resolve load flags dependencies */
5539
5540 if ( load_flags & FT_LOAD_NO_RECURSE )
5541 load_flags |= FT_LOAD_NO_SCALE |
5542 FT_LOAD_IGNORE_TRANSFORM;
5543
5544 if ( load_flags & FT_LOAD_NO_SCALE )
5545 {
5546 load_flags |= FT_LOAD_NO_HINTING |
5547 FT_LOAD_NO_BITMAP;
5548
5549 load_flags &= ~FT_LOAD_RENDER;
5550 }
5551
5552 and as such the auto-hinter is never called. Thus, the recursion in
5553 `af_loader_load_g' never actually happens. So remove the depth
5554 counter as well.
5555
5556 * src/autofit/afloader.c (af_loader_load_g): Remove `depth'
5557 parameter.
5558 <FT_GLYPH_FORMAT_COMPOSITE>: Remove associated code.
5559 (af_loader_load_glyph): Updated.
5560
55612015-01-14 Behdad Esfahbod <behdad@behdad.org>
5562
Behdad Esfahbodc242fe42015-01-14 18:48:14 +01005563 [raster] Fix uninitialized memory access.
5564
5565 Apparently `ras.cProfile' might be uninitialized. This will be the
5566 case if `ras.top == ras.cProfile->offset', as can be seen in
5567 `End_Profile'. The overshoot code introduced in a change `Fix B/W
5568 rasterization of subglyphs with different drop-out modes.' (from
5569 2009-06-18) violated this, accessing `ras.cProfile->flags'
5570 unconditionally just before calling `End_Profile' (which then
5571 detected that `cProfile' is uninitialized and didn't touch it).
5572
5573 This was harmless, and was not detected by valgrind before because
5574 the objects were allocated on the `raster_pool', which was always
5575 initialized. With recent change to allocate raster buffers on the
5576 stack, valgrind now reported this invalid access.
5577
5578 * src/raster/ftraster.c (Convert_Glyph): Don't access an
5579 uninitialized `cProfile'.
5580
55812015-01-14 Behdad Esfahbod <behdad@behdad.org>
5582
Behdad Esfahbodb2ba6862015-01-14 18:43:13 +01005583 [smooth] Fix uninitialized memory access.
5584
5585 Looks like `ras.span_y' could always be used without initialization.
5586 This was never detected by valgrind before because the library-wide
5587 `raster_pool' was used for the worker object and `raster_pool' was
5588 originally zero'ed. But subsequent reuses of it were using `span_y'
5589 uninitialized. With the recent change to not use `render_pool' and
5590 allocate worker and buffer on the stack, valgrind now detects this
5591 uninitialized access.
5592
5593 * src/smooth/ftgrays.c (gray_raster_render): Initialize
5594 `ras.span_y'.
5595
55962015-01-14 Behdad Esfahbod <behdad@behdad.org>
5597
Behdad Esfahbod603292d2015-01-14 18:35:56 +01005598 [base] Don't initialize unused `driver->glyph_loader'.
5599
5600 * src/base/ftobjs.c (Destroy_Driver): Don't call
5601 `FT_GlyphLoader_Done'.
5602 (FT_Add_Module): Don't call `FT_GlyphLoader_New'.
5603
56042015-01-14 Behdad Esfahbod <behdad@behdad.org>
5605
Behdad Esfahbod51634252015-01-14 18:30:59 +01005606 [base] Don't allocate `library->raster_pool' anymore.
5607
5608 It's unused after the following commits:
5609
5610 [raster] Allocate render pool for mono rasterizer on the stack.
5611 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
5612
5613 The value of FT_RENDER_POOL_SIZE still serves the purpose it used to
5614 serve, which is, to adjust the pool size. But the pool is now
5615 allocated on the stack on demand.
5616
5617 * src/base/ftobjs.c (FT_New_Library, FT_Done_Library): Implement.
5618
56192015-01-14 Behdad Esfahbod <behdad@behdad.org>
5620
Behdad Esfahbod6dfdaf42015-01-14 18:21:13 +01005621 [base] Do not reorder library->renderers upon use.
5622
5623 Instead of keeping `library->renderers' in a MRU order, just leave
5624 it as-is. The MRU machinery wasn't thread-safe.
5625
5626 With this patch, rasterizing glyphs from different faces from
5627 different threads doesn't fail choosing rasterizer
5628 (FT_Err_Cannot_Render_Glyph).
5629
5630 Easiest to see that crash was to add a `printf' (or otherwise let
5631 thread yield in FT_Throw with debugging enabled).
5632
5633 * src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c
5634 (FT_Outline_Render): Don't call `FT_Set_Renderer'.
5635
56362015-01-14 Behdad Esfahbod <behdad@behdad.org>
5637
Behdad Esfahboda773c302015-01-14 18:16:20 +01005638 [raster] Allocate render pool for mono rasterizer on the stack.
5639
5640 Instead of using the `render_pool' member of `FT_Library' that is
5641 provided down to the rasterizer, completely ignore that and allocate
5642 needed objects on the stack instead.
5643
5644 With this patch, rasterizing glyphs from different faces from
5645 different threads doesn't crash in the monochrome rasterizer.
5646
5647 * src/raster/ftraster.c (black_TRaster): Remove `buffer',
5648 `buffer_size', and `worker' members.
5649
5650 (ft_black_render): Create `buffer' locally.
5651 (ft_black_reset): Updated.
5652
56532015-01-14 Behdad Esfahbod <behdad@behdad.org>
5654
Behdad Esfahbod8dc86352015-01-14 18:06:22 +01005655 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
5656
5657 It was off by default and couldn't be turned on at runtime. And the
5658 smooth rasterizer superceded it over ten years ago. No point in
5659 keeping. Comments suggested that it was there for compatibility
5660 with FreeType 1.
5661
5662 550 lines down.
5663
5664 * src/raster/ftraster.c (FT_RASTER_OPTION_ANTI_ALIASING,
5665 RASTER_GRAY_LINES): Remove macros and all associated code.
5666
5667 (black_TWorker): Remove `gray_min_x' and `gray_max_x'.
5668 (black_TRaster): Remove `grays' and `gray_width'.
5669
5670 (Vertical_Sweep_Init, Vertical_Sweep_Span, Vertical_Sweep_Drop,
5671 ft_black_render): Updated.
5672
5673 * src/raster/ftrend1.c (ft_raster1_render): Simplify code.
5674 (ft_raster5_renderer_class): Removed.
5675
56762015-01-14 Behdad Esfahbod <behdad@behdad.org>
5677
Behdad Esfahbod747ae2c2015-01-14 17:54:26 +01005678 [smooth] Allocate render pool for smooth rasterizer on the stack.
5679
5680 Instead of using the `render_pool' member of `FT_Library' that is
5681 provided down to the rasterizer, completely ignore that and allocate
5682 needed objects on the stack instead.
5683
5684 With this patch, rasterizing glyphs from different faces from
5685 different threads doesn't crash in the smooth rasterizer.
5686
5687 Bugs:
5688
5689 https://bugzilla.redhat.com/show_bug.cgi?id=678397
5690 https://bugzilla.redhat.com/show_bug.cgi?id=1004315
5691 https://bugzilla.redhat.com/show_bug.cgi?id=1165471
5692 https://bugs.freedesktop.org/show_bug.cgi?id=69034
5693
5694 * src/smooth/ftgrays.c (gray_TRaster): Remove `buffer',
5695 `buffer_size', `band_size', and `worker' members.
5696
5697 (gray_raster_render): Create `buffer', `buffer_size', and
5698 `band_size' locally.
5699 (gray_raster_reset): Updated.
5700
57012015-01-14 Behdad Esfahbod <behdad@behdad.org>
5702
Behdad Esfahbod531d4632015-01-14 17:46:55 +01005703 [truetype] Allocate TT_ExecContext in TT_Size instead of TT_Driver.
5704
5705 Previously the code had stipulation for using a per-TT_Size exec
5706 context if `size->debug' was true. But there was no way that
5707 `size->debug' could *ever* be true. As such, the code was always
5708 using the singleton `TT_ExecContext' that was stored in `TT_Driver'.
5709 This was, clearly, not threadsafe.
5710
5711 With this patch, loading glyphs from different faces from different
5712 threads doesn't crash in the bytecode loader code.
5713
5714 * src/truetype/ttobjs.h (TT_SizeRec): Remove `debug' member.
5715 (TT_DriverRec): Remove `context' member.
5716
5717 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Remove
5718 `TT_ExecContext' code related to a global `TT_Driver' object.
5719
5720 (tt_driver_done): Don't remove `TT_ExecContext' object here but ...
5721 (tt_size_done_bytecode): ... here.
5722
5723 (tt_driver_init): Don't create `TT_ExecContext' object here but ...
5724 (tt_size_init_bytecode): ... here, only on demand.
5725
5726 * src/truetype/ttinterp.c (TT_Run_Context): Remove defunct debug
5727 code.
5728 (TT_New_Context): Remove `TT_ExecContext' code related to a global
5729 `TT_Driver' object.
5730
5731 * src/truetype/ttinterp.h: Updated.
5732
5733 * src/truetype/ttgload.c (TT_Hint_Glyph, tt_loader_init): Updated.
5734
57352015-01-14 Behdad Esfahbod <behdad@behdad.org>
5736
Behdad Esfahbod89bc8d42015-01-14 16:01:19 +01005737 [autofit] Allocate AF_Loader on the stack instead of AF_Module.
5738
5739 Stop sharing a global `AF_Loader'. Allocate one on the stack during
5740 glyph load.
5741
5742 Right now this results in about 25% slowdown, to be fixed in a
5743 following commit.
5744
5745 With this patch loading glyphs from different faces from different
5746 threads doesn't immediately crash in the autohinting loader code.
5747
5748 Bugs:
5749
5750 https://bugzilla.redhat.com/show_bug.cgi?id=1164941
5751
5752 * src/autofit/afloader.c (af_loader_init): Pass
5753 `AF_Loader' and `FT_Memory' instead of `AF_Module' as arguments.
5754 (af_loader_reset, af_loader_load_glyph): Also pass `loader' as
5755 argument.
5756 (af_loader_done): Use `AF_Loader' instead of `AF_Module' as
5757 argument.
5758
5759 * src/autofit/afmodule.c (af_autofitter_init): Don't call
5760 `af_loader_init'.
5761 (af_autofitter_done): Don't call `af_loader_done'.
5762 (af_autofitter_load_glyph): Use a local `AF_Loader' object.
5763
5764 * src/autofit/afloader.h: Include `afmodule.h'.
5765 Update prototypes.
5766 Move typedef for `AF_Module' to...
5767
5768 * src/autofit/afmodule.h: ... this place.
5769 No longer include `afloader.h'.
5770
57712015-01-14 Behdad Esfahbod <behdad@behdad.org>
5772
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +01005773 * src/type42/t42objs.h (T42_DriverRec): Remove unused member.
5774
Werner Lemberg36d03c92015-01-12 11:26:30 +010057752015-01-12 Werner Lemberg <wl@gnu.org>
5776
5777 Fix Savannah bug #43976.
5778
5779 Assure that FreeType's internal include directories are found before
5780 `CPPFLAGS' (which might be set by the user in the environment), and
5781 `CPPFLAGS' before `CFLAGS'.
5782
5783 * builds/freetype.mk (FT_CFLAGS): Don't add `INCLUDE_FLAGS'.
5784 (FT_COMPILE): Make this a special variable for compiling only the
5785 files handled in `freetype.mk'.
5786 (.c.$O): Removed, unused.
5787
5788 * src/*/rules.mk (*_COMPILE): Fix order of include directories.
5789
Werner Lembergd03a67a2015-01-11 08:39:14 +010057902015-01-11 Werner Lemberg <wl@gnu.org>
5791
Alexei Podtelezhnikovc6d99a42016-04-08 00:05:50 -04005792 [truetype] Prettifying.
Werner Lemberg95b57052015-01-11 09:50:49 +01005793
5794 * src/truetype/ttinterp.c (project, dualproj, fast_project,
5795 fast_dualproj): Rename to...
5796 (PROJECT, DUALPROJ, FAST_PROJECT, FAST_DUALPROJ): ... this.
5797
57982015-01-11 Werner Lemberg <wl@gnu.org>
5799
Werner Lembergea173c02015-01-11 08:58:54 +01005800 * src/truetype/ttinterp.c (Ins_JROT, Ins_JROF): Simplify.
5801
5802 Based on a patch from Behdad.
5803
58042015-01-11 Werner Lemberg <wl@gnu.org>
5805
Werner Lemberg628578c2015-01-11 08:53:31 +01005806 * src/truetype/ttinterp.c (Ins_SxVTL): Simplify function call.
5807
58082015-01-11 Werner Lemberg <wl@gnu.org>
5809
Werner Lemberg08e79092015-01-11 08:45:50 +01005810 * src/truetype/ttinterp.c (Normalize): Remove unused argument.
5811
58122015-01-11 Werner Lemberg <wl@gnu.org>
5813
Werner Lembergd03a67a2015-01-11 08:39:14 +01005814 [truetype] More macro expansions.
5815
Werner Lemberg4aaadf42015-01-11 08:42:28 +01005816 * src/truetype/ttinterp.c (FT_UNUSED_EXEC): Remove macro by
5817 expansion.
5818
58192015-01-11 Werner Lemberg <wl@gnu.org>
5820
5821 [truetype] More macro expansions.
5822
Werner Lembergd03a67a2015-01-11 08:39:14 +01005823 * src/truetype/ttinterp.c (INS_ARG): Remove macro by expansion,
Alexei Podtelezhnikovbbb60962016-04-07 01:29:44 -04005824 adjusting function calls where necessary.
Werner Lembergd03a67a2015-01-11 08:39:14 +01005825 (FT_UNUSED_ARG): Removed, no longer needed.
5826
Werner Lemberg1b4d68c2015-01-10 19:56:28 +010058272015-01-10 Werner Lemberg <wl@gnu.org>
5828
Werner Lembergeb341362015-01-11 00:23:27 +01005829 [truetype] More macro expansions.
5830
5831 Based on a patch from Behdad.
5832
5833 * src/truetype/ttinterp.c (DO_*): Expand macros into corresponding
5834 `Ins_*' functions.
5835 (TT_RunIns): Replace `DO_*' macros with `Ins_*' function calls.
5836 (ARRAY_BOUND_ERROR): Remove second definition, which is no longer
5837 needed.
5838 (Ins_SVTCA, Ins_SPVTCA, Ins_SFVTCA): Replaced with...
5839 (Ins_SxyTCA): New function.
5840
58412015-01-10 Werner Lemberg <wl@gnu.org>
5842
Werner Lemberg01be1302015-01-10 23:05:37 +01005843 [truetype] Remove TT_CONFIG_OPTION_INTERPRETER_SWITCH.
5844
5845 Behdad suggested this code simplification, and nobody objected...
5846
5847 * include/config/ftoption.h, devel/ftoption.h
5848 (TT_CONFIG_OPTION_INTERPRETER_SWITCH): Remove.
5849
5850 * src/truetype/ttinterp.c [TT_CONFIG_OPTION_INTERPRETER_SWITCH]:
5851 Remove related code.
5852 (ARRAY_BOUND_ERROR): Use do-while loop.
5853
58542015-01-10 Werner Lemberg <wl@gnu.org>
5855
Werner Lembergfae0c812015-01-10 20:23:10 +01005856 [truetype] More macro expansions.
5857
Werner Lemberg6cc1f122015-01-10 21:56:59 +01005858 * src/truetype/ttinterp.c, src/truetype/ttinterp.h (EXEC_ARG_,
5859 EXEC_ARG): Remove by replacing with expansion.
5860
58612015-01-10 Werner Lemberg <wl@gnu.org>
5862
5863 [truetype] More macro expansions.
5864
Werner Lemberg24681452015-01-10 21:53:48 +01005865 Based on a patch from Behdad.
5866
5867 * src/truetype/ttinterp.c (SKIP_Code, GET_ShortIns, NORMalize,
5868 SET_SuperRound, ROUND_None, INS_Goto_CodeRange, CUR_Func_move,
5869 CUR_Func_move_orig, CUR_Func_round, CUR_Func_cur_ppem,
5870 CUR_Func_read_cvt, CUR_Func_write_cvt, CUR_Func_move_cvt,
5871 CURRENT_Ratio, INS_SxVTL, COMPUTE_Funcs, COMPUTE_Round,
5872 COMPUTE_Point_Displacement, MOVE_Zp2_Point): Remove by replacing
5873 with expansion.
5874
5875 (Cur_Func_project, CUR_Func_dualproj, CUR_fast_project,
5876 CUR_fast_dualproj): Replace with macros `project', `dualproj',
5877 `fast_project', `fast_dualproj'.
5878
58792015-01-10 Werner Lemberg <wl@gnu.org>
5880
5881 [truetype] More macro expansions.
5882
Werner Lembergfae0c812015-01-10 20:23:10 +01005883 * src/truetype/ttinterp.c (EXEC_OP_, EXEC_OP): Remove by replacing
5884 with expansion.
5885
58862015-01-10 Werner Lemberg <wl@gnu.org>
5887
Werner Lemberg5a752f32015-01-10 20:08:35 +01005888 [truetype] Remove code for static TrueType interpreter.
5889
5890 This is a follow-up patch.
5891
5892 * src/truetype/ttinterp.c, src/truetype/ttinterp.h
5893 [TT_CONFIG_OPTION_STATIC_INTERPRETER,
5894 TT_CONFIG_OPTION_STATIC_RASTER]: Remove macros and related code.
5895
58962015-01-10 Werner Lemberg <wl@gnu.org>
5897
Werner Lemberg1b4d68c2015-01-10 19:56:28 +01005898 * src/truetype/ttinterp.c (CUR): Remove by replacing with expansion.
5899
5900 This starts a series of patches that simplifies the code of the
5901 bytecode interpreter.
5902
Werner Lembergf6aa0892013-05-10 07:58:47 +02005903
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00005904----------------------------------------------------------------------------
5905
Werner Lemberg9adeab62016-01-13 11:54:10 +01005906Copyright 2015-2016 by
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00005907David Turner, Robert Wilhelm, and Werner Lemberg.
5908
5909This file is part of the FreeType project, and may only be used, modified,
5910and distributed under the terms of the FreeType project license,
5911LICENSE.TXT. By continuing to use, modify, or distribute this file you
5912indicate that you have read the license and understand and accept it
5913fully.
5914
5915
5916Local Variables:
5917version-control: never
Werner Lemberg4e03fe72006-04-29 06:20:09 +00005918coding: utf-8
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00005919End: