blob: 9e2450930cd4b56a9b60b4eb57d28e259d96b7d8 [file] [log] [blame]
Alexei Podtelezhnikove2dae8f2015-10-01 22:03:34 -040012015-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
2
3 [smooth] Clean up worker.
4
5 * src/smooth/ftgrays.c (gray_TWorker): Remove never used fields.
6
Werner Lemberg5f8f44d2015-10-01 14:16:03 +020072015-10-01 Werner Lemberg <wl@gnu.org>
8
Werner Lemberg90e437e2015-10-01 20:00:27 +02009 [sfnt] Make `tt_cmap4_char_map_linear' more robust (#46078).
10
11 * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Take care of
12 border conditions (i.e., if the loop exits naturally).
13
142015-10-01 Werner Lemberg <wl@gnu.org>
15
Werner Lembergfab67b82015-10-01 16:47:05 +020016 * src/autofit/afranges.c (af_deva_nonbase_uniranges): Fix ranges.
17 They should be a subset of `af_deva_uniranges'.
18
192015-10-01 Werner Lemberg <wl@gnu.org>
20
Werner Lemberg5f8f44d2015-10-01 14:16:03 +020021 [sfnt] Make `tt_cmap4_char_map_linear' faster (#46078).
22
23 * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Use inner loop to
24 reject too large glyph indices.
25
Alexei Podtelezhnikov8bbcfb22015-09-30 23:08:53 -0400262015-09-30 Alexei Podtelezhnikov <apodtele@gmail.com>
27
28 [smooth] Clean up worker.
29
30 * src/smooth/ftgrays.c (gray_TWorker): Remove lightly used `last_ey'.
31 (gray_start_cell, gray_render_line): Update.
32
Werner Lemberg8651f372015-09-30 10:26:10 +0200332015-09-30 Werner Lemberg <wl@gnu.org>
34
Werner Lembergdbd04262015-09-30 17:52:42 +020035 [autofit] Replace `no-base' with `non-base'.
36
37 * src/autofit/*: Do it.
38
392015-09-30 Werner Lemberg <wl@gnu.org>
40
Werner Lemberg2ff83a52015-09-30 14:44:29 +020041 [sfnt] Rewrite `tt_cmap4_char_map_linear' (#46078).
42
43 * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Add code to better
44 skip invalid segments.
45 If searching the next character, provide a more efficient logic to
46 speed up the code.
47
482015-09-30 Werner Lemberg <wl@gnu.org>
49
Werner Lemberg8651f372015-09-30 10:26:10 +020050 [truetype] Adjust number of glyphs for malformed `loca' tables.
51
52 * src/truetype/ttpload.c (tt_face_load_loca): Implement it.
53
Werner Lemberg483007f2015-09-29 11:22:15 +0200542015-09-29 Werner Lemberg <wl@gnu.org>
55
56 [pshinter] Avoid harmless overflow (#45984).
57
58 * src/pshinter/pshglob.c (psh_blues_set_zones): Fix it.
59
Werner Lemberga3046562015-09-28 09:45:56 +0200602015-09-28 Werner Lemberg <wl@gnu.org>
61
62 [autofit] Add support for Lao script.
63
64 Thanks to Danh Hong <danhhong@gmail.com> for guidance with blue zone
65 characters!
66
67 * src/autofit/afblue.dat: Add blue zone data for Lao.
68
69 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
70
71 * src/autofit/afscript.h: Add Lao standard characters.
72
73 * src/autofit/afranges.c: Add Lao data.
74
75 * src/autofit/afstyles.h: Add Lao data.
76
suzuki toshiya8a05d252015-09-28 01:40:21 +0900772015-09-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
suzuki toshiyafb5268c2015-09-28 02:01:43 +090078
79 [base] Fix a leak by broken sfnt-PS or resource fork (#46028).
80
81 open_face_from_buffer() frees passed buffer if valid font
82 is not found. But if copying to the buffer is failed,
83 the allocated buffer should be freed within the caller.
84
85 * src/base/ftobjs.c (open_face_PS_from_sfnt_stream): Free
86 the buffer `sfnt_ps' if an error caused before calling
87 open_face_from_buffer().
88 (Mac_Read_sfnt_Resource): Free the buffer `sfnt_data' if
89 an error caused before calling open_face_from_buffer();
90
912015-09-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
suzuki toshiya8a05d252015-09-28 01:40:21 +090092
93 [mac] Fix buffer size calculation for LWFN font.
94
95 * src/base/ftmac.c (read_lwfn): Cast post_size to FT_ULong
96 to prevent confused copy by too large chunk size.
97
Alexei Podtelezhnikov3dffe8e2015-09-27 11:30:17 -0400982015-09-26 Alexei Podtelezhnikov <apodtele@gmail.com>
99
100 * src/smooth/ftgrays.c (PIXEL_MASK): Remove unused macro.
101
Werner Lemberg41877532015-09-26 15:19:54 +02001022015-09-26 Werner Lemberg <wl@gnu.org>
103
Werner Lemberg19188a92015-09-26 16:57:17 +0200104 [autofit] Minor tracing improvement.
105
106 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Don't emit
107 blue zones header line if there are no blue zones.
108
1092015-09-26 Werner Lemberg <wl@gnu.org>
110
Werner Lemberg41877532015-09-26 15:19:54 +0200111 [bzip2, gzip, lzw] Harmonize function signatures with prototype.
112
113 Suggested by Hin-Tak Leung.
114
115 * src/bzip2/ftbzip2.c (ft_bzip2_stream_io), src/gzip/ftgzip.c
116 (ft_gzip_stream_io), src/lzw/ftlzw.c (ft_lzw_stream_io): Do it.
117
Hin-Tak Leung265ade82015-09-26 14:51:30 +02001182015-09-26 Hin-Tak Leung <htl10@users.sourceforge.net>
119
120 Add new FT_LOAD_COMPUTE_METRICS load flag.
121
122 * include/freetype/freetype.h (FT_LOAD_COMPUTE_METRICS): New macro.
123 * src/truetype/ttgload.c (compute_glyph_metrics): Usage.
124
Werner Lembergd57f2272015-09-26 08:44:26 +02001252015-09-26 Werner Lemberg <wl@gnu.org>
126
127 * src/base/ftobjs.c (Mac_Read_sfnt_Resource): Add cast.
128
Werner Lemberg2439c512015-09-25 16:54:28 +02001292015-09-25 Werner Lemberg <wl@gnu.org>
130
131 [type1] Protect against invalid number of glyphs (#46029).
132
133 * src/type1/t1load.c (parse_charstrings): Check number of
134 `CharStrings' dictionary entries against size of data stream.
135
Werner Lembergc409eb12015-09-24 12:39:38 +02001362015-09-23 Werner Lemberg <wl@gnu.org>
137
Werner Lemberg5339c752015-09-24 13:39:44 +0200138 [sfnt] Better checks for invalid cmaps (2/2) (#46019).
139
140 While the current code in `FT_Get_Next_Char' correctly rejects
141 out-of-bounds glyph indices, it can be extremely slow for malformed
142 cmaps that use 32bit values. This commit tries to improve that.
143
144 * src/sfnt/ttcmap.c (tt_cmap8_char_next, tt_cmap12_next,
145 tt_cmap12_char_map_binary, tt_cmap13_next,
146 tt_cmap13_char_map_binary): Reject glyph indices larger than or
147 equal to the number of glyphs.
148
1492015-09-23 Werner Lemberg <wl@gnu.org>
150
Werner Lembergc409eb12015-09-24 12:39:38 +0200151 [base, sfnt] Better checks for invalid cmaps (1/2).
152
153 * src/base/ftobjs.c (FT_Get_Char_Index): Don't return out-of-bounds
154 glyph indices.
155 (FT_Get_First_Char): Updated.
156
157 * src/sfnt/ttcmap.c (tt_cmap6_char_next): Don't return character
158 codes greater than 0xFFFF.
159
160 (tt_cmap8_char_index): Avoid integer overflow in computation of
161 glyph index.
162 (tt_cmap8_char_next): Avoid integer overflows in computation of
163 both next character code and glyph index.
164
165 (tt_cmap10_char_index): Fix unsigned integer logic.
166 (tt_cmap10_char_next): Avoid integer overflow in computation of
167 next character code.
168
169 (tt_cmap12_next): Avoid integer overflows in computation of both
170 next character code and glyph index.
171 (tt_cmap12_char_map_binary): Ditto.
172 (tt_cmap12_char_next): Simplify.
173
174 (tt_cmap13_char_map_binary): Avoid integer overflow in computation
175 of next character code.
176 (tt_cmap13_char_next): Simplify.
177
suzuki toshiyae982f5b2015-09-21 23:07:22 +09001782015-09-21 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
179
Werner Lembergd7f456e2015-09-26 08:37:14 +0200180 [base] Check too long POST and sfnt resource (#45919).
suzuki toshiyae982f5b2015-09-21 23:07:22 +0900181
Werner Lembergd7f456e2015-09-26 08:37:14 +0200182 * src/base/ftbase.h (FT_MAC_RFORK_MAX_LEN): Maximum length of the
183 resource fork for Mac OS. Resource forks larger than 16 MB can be
184 written but can't be handled correctly, at least in Carbon routine.
185 See https://support.microsoft.com/en-us/kb/130437.
suzuki toshiyae982f5b2015-09-21 23:07:22 +0900186
Werner Lembergd7f456e2015-09-26 08:37:14 +0200187 * src/base/ftobjs.c (Mac_Read_POST_Resource): No need to use `0x'
188 prefix for `%p' formatter.
suzuki toshiyae982f5b2015-09-21 23:07:22 +0900189
Werner Lembergd7f456e2015-09-26 08:37:14 +0200190 * src/base/ftbase.c (Mac_Read_POST_Resource): Check the fragment and
191 total size of the concatenated POST resource before buffer
192 allocation.
193 (Mac_Read_sfnt_Resource): Check the declared size of sfnt resource
suzuki toshiyae982f5b2015-09-21 23:07:22 +0900194 before buffer allocation.
suzuki toshiyae982f5b2015-09-21 23:07:22 +0900195
Werner Lembergd7f456e2015-09-26 08:37:14 +0200196 * src/base/ftmac.c (read_lwfn, FT_New_Face_From_SFNT): Check the
197 total resource size before buffer allocation.
suzuki toshiyae982f5b2015-09-21 23:07:22 +0900198
Werner Lembergcb7a5122015-09-19 07:58:03 +02001992015-09-19 Werner Lemberg <wl@gnu.org>
200
Werner Lemberg730b6d72015-09-19 12:41:12 +0200201 [sfnt] Improve handling of invalid SFNT table entries (#45987).
202
203 This patch fixes weaknesses in function `tt_face_load_font_dir'.
204
205 - It incorrectly assumed that valid tables are always at the
206 beginning. As a consequence, some valid tables after invalid
207 entries (which are ignored) were never seen.
208
209 - Duplicate table entries (this is, having the same tag) were not
210 rejected.
211
212 - The number of valid tables was sometimes too large, leading to
213 access of invalid tables.
214
215 * src/sfnt/ttload.c (check_table_dir): Add argument to return number
216 of valid tables.
217 Add another tracing message.
218 (tt_face_load_font_dir): Only allocate table array for valid
219 entries as returned by `check_table_dir'.
220 Reject duplicate tables and adjust number of valid tables
221 accordingly.
222
2232015-09-19 Werner Lemberg <wl@gnu.org>
224
Werner Lembergcb7a5122015-09-19 07:58:03 +0200225 [pcf] Improve `FT_ABS' fix from 2015-09-17 (#45999).
226
227 * src/pcf/pcfread.c (pcf_load_font): Do first the cast to FT_Short,
228 then take the absolute value.
229 Also apply FT_ABS to `height'.
230
Werner Lemberg9db9add2015-09-17 13:42:59 +02002312015-09-17 Werner Lemberg <wl@gnu.org>
232
Werner Lembergf28c95c2015-09-17 19:30:26 +0200233 [type42] Fix memory leak (#45989).
234
235 * src/type42/t42parse.c (t42_parse_charstrings): Allow only a single
236 `CharStrings' array.
237
2382015-09-17 Werner Lemberg <wl@gnu.org>
239
Werner Lemberg4942c2b2015-09-17 17:56:53 +0200240 [psaux] Fix memory leak (#45986).
241
242 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
243 Free `temp' in case of error.
244
2452015-09-17 Werner Lemberg <wl@gnu.org>
246
Werner Lemberg7d364b72015-09-17 16:31:58 +0200247 [psaux] Improve tracing message.
248
249 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
250 Handle plural correctly.
251
2522015-09-17 Werner Lemberg <wl@gnu.org>
253
Werner Lembergc838c4f2015-09-17 16:22:40 +0200254 [pcf] Fix integer overflows (#45985).
255
256 * src/pcf/pcfread.c (pcf_load_font): Use FT_MulDiv.
257
2582015-09-17 Werner Lemberg <wl@gnu.org>
259
Werner Lemberg9db9add2015-09-17 13:42:59 +0200260 [pcf] Use FT_ABS for some property values (#45893).
261
262 * src/pcf/pcfread.c (pcf_load_font): Take absolute values for
263 AVERAGE_WIDTH, POINT_SIZE, PIXEL_SIZE, RESOLUTION_X, and
264 RESOLUTION_Y. In tracing mode, add warnings.
265
Werner Lembergbd0438a2015-09-16 18:05:43 +02002662015-09-16 Werner Lemberg <wl@gnu.org>
267
268 Minor fixes for some clang warnings.
269
270 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Cast, possible missing
271 initialization.
272
273 * src/truetype/ttgload.c (TT_Process_Composite_Component): Cast.
274
Werner Lemberg581c7e22015-09-15 06:49:06 +02002752015-09-15 Werner Lemberg <wl@gnu.org>
276
Werner Lemberg19cb1122015-09-15 08:52:36 +0200277 [type1, type42] Fix memory leaks (#45966).
278
279 * src/type1/t1load.c (parse_blend_axis_types): Handle multiple axis
280 names.
281 (parse_blend_design_map): Allow only a single design map.
282 (parse_encoding): Handle multiple encoding vectors.
283
284 * src/type42/t42parse.c (t42_parse_encoding): Handle multiple
285 encoding vectors.
286
2872015-09-15 Werner Lemberg <wl@gnu.org>
288
Werner Lemberg7f0f4012015-09-15 07:23:53 +0200289 [truetype] Fix integer type (#45965).
290
291 * src/truetype/ttobjs.c (tt_synth_sfnt_checksum): Implement it.
292
2932015-09-15 Werner Lemberg <wl@gnu.org>
294
Werner Lemberg577daf12015-09-15 07:10:16 +0200295 * src/pcf/pcfread.c (pcf_load_font): Fix integer overflow (#45964).
296
2972015-09-15 Werner Lemberg <wl@gnu.org>
298
Werner Lemberg581c7e22015-09-15 06:49:06 +0200299 [type1, type42] Check encoding array size (#45961).
300
301 * src/type1/t1load.c (parse_encoding), src/type42/t42parse.c
302 (t42_parse_encoding): Do it.
303
Alexei Podtelezhnikov3ea0d2c2015-09-13 23:19:34 -04003042015-09-14 Alexei Podtelezhnikov <apodtele@gmail.com>
305
306 * src/base/ftcalc.c (FT_MulFix) [FT_LONG64]: Improve.
307
Werner Lemberg7962a152015-09-14 00:38:26 +02003082015-09-14 Werner Lemberg <wl@gnu.org>
309
310 [type1] Fix another potential buffer overflow (#45955).
311
312 * src/type1/t1parse (T1_Get_Private_Dict): Assure that check for
313 `eexec' doesn't exceed `limit'.
314
Werner Lemberge40e8b32015-09-13 08:05:50 +02003152015-09-13 Werner Lemberg <wl@gnu.org>
316
Werner Lembergff7d6402015-09-13 23:53:16 +0200317 Replace `mkinstalldirs' with AC_PROG_MKDIR_P.
318
319 * builds/unix/mkinstalldirs: Removed, no longer needed.
320
321 * builds/unix/configure.raw: Call `AC_PROG_MKDIR_P'.
322 Update pwd call for `$INSTALL'.
323
324 * builds/unix/unix-def.in (MKINSTALLDIRS): Use `@MKDIR_P@'.
325
326 * autogen.sh: Updated.
327
3282015-09-13 Werner Lemberg <wl@gnu.org>
329
Werner Lemberg3df92aa2015-09-13 09:21:52 +0200330 [winfonts] Check alignment shift count for resource data (#45938).
331
332 * src/winfonts/winfnt.c (fnt_face_get_dll_font): Implement it.
333
3342015-09-13 Werner Lemberg <wl@gnu.org>
335
Werner Lemberge3058612015-09-13 08:41:43 +0200336 [type1] Fix potential buffer overflow (#45923).
337
338 * src/type1/t1parse.c (T1_Get_Private_Dict): Assure `cur' doesn't
339 point to end of file buffer.
340
3412015-09-13 Werner Lemberg <wl@gnu.org>
342
Werner Lemberge40e8b32015-09-13 08:05:50 +0200343 [gzip] Fix access of small compressed files (#45937).
344
345 * src/gzip/ftgzip.c (ft_gzip_stream_close): Avoid memory leak.
346
347 (ft_gzip_get_uncompressed_file): Correct byte order while reading
348 unsigned long value. Without this change, the whole optimization of
349 accessing small files in `FT_Stream_OpenGzip' is never executed! As
350 a consequence, access to PCF files in general (which are normally
351 small files) should be much improved now as originally intended.
352
Werner Lemberg23423bc2015-09-11 08:28:27 +02003532015-09-11 Werner Lemberg <wl@gnu.org>
354
Werner Lembergdb5a4a92015-09-12 08:32:55 +0200355 [psaux] Fix potential buffer overflow (#45922).
356
357 * src/psaux/psobjs.c (ps_parser_skip_PS_token): If a token is
358 enclosed in balanced expressions, ensure that the cursor position
359 doesn't get larger than the current limit.
360
3612015-09-11 Werner Lemberg <wl@gnu.org>
362
Werner Lemberg19b82cf2015-09-11 20:25:32 +0200363 [base] Avoid crash while tracing `load_mac_face'.
364
365 Reported in Savannah bug #45919.
366
367 * src/base/ftobjs.c (load_mac_face): Honour FT_OPEN_MEMORY while
368 tracing.
369
3702015-09-11 Werner Lemberg <wl@gnu.org>
371
Werner Lemberg23423bc2015-09-11 08:28:27 +0200372 [type42] Fix endless loop (#45920).
373
374 * src/type42/t42parse.c (t42_parse_encoding): Synchronize with
375 type1's `parse_encoding'.
376
Werner Lemberge5a27a72015-09-10 07:44:11 +02003772015-09-10 Werner Lemberg <wl@gnu.org>
378
379 [docmaker] Allow `-' in bold and italic markup.
380
381 * src/tools/docmaker/sources.py (re_italic, re_bold): Adjust
382 accordingly.
383
Alexei Podtelezhnikov09948e42015-09-09 21:30:15 -04003842015-09-09 Alexei Podtelezhnikov <apodtele@gmail.com>
385
386 * src/base/ftcalc.c (FT_RoundFix): Improve.
387
Wojciech Mamrak822acb02015-09-09 07:59:10 +02003882015-09-09 Wojciech Mamrak <wmamrak@gmail.com>
389
390 * src/base/ftcalc.c (FT_CeilFix, FT_FloorFix): Normalize.
391
392 This commit makes the functions behave as expected, this is,
393 rounding towards plus or minus infinity.
394
Alexei Podtelezhnikovb002f682015-09-07 13:47:36 -04003952015-09-07 Alexei Podtelezhnikov <apodtele@gmail.com>
396
397 * src/smooth/ftgrays.c (gray_render_line): Simplify clipping.
398
Alexei Podtelezhnikov5a6dc872015-09-04 23:14:46 -04003992015-09-04 Alexei Podtelezhnikov <apodtele@gmail.com>
400
401 [raster,smooth] Microoptimizations.
402
403 * src/raster/ftraster.c (Insert_Y_Turn, Finalize_Profile_Table,
404 Beziier_Up, ): Use do-while loops.
405
406 * src/smooth/ftgrays.c (gray_render_scanline, gray_render_line,
407 gray_convert_glyph): Ditto.
408
Werner Lemberg696b7122015-09-04 10:10:59 +02004092015-09-04 Werner Lemberg <wl@gnu.org>
410
Werner Lembergd3cba0e2015-09-04 10:28:53 +0200411 [autofit] Redesign code ranges (2/2).
412
413 This commit adds two fallback scripts (`latb', `latp') and
414 implements support for the no-base character ranges introduced in
415 the previous commit.
416
417 * src/autofit/aftypes.h (AF_ScriptClassRec): Add
418 `script_uni_nobase_ranges' field.
419 (AF_DEFINE_SCRIPT_CLASS): Updated.
420
421 * src/autofit/afscript.h, src/autofit/afstyles.h: Add `latb' and
422 `latp' fallback scripts.
423
424 * src/autofit/afblue.dat: Add blue zones for Latin subscript and
425 superscript fallback scripts.
426
427 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
428
429 * src/autofit/afglobal.h (AF_NOBASE): New style flag for no-base
430 characters.
431 (AF_STYLE_MASK): Updated.
432
433 * src/autofit/afglobal.c (SCRIPT): Updated.
434 (af_face_globals_compute_style_coverage): Handle new style flag.
435
436 * src/autofit/aflatin.c (af_latin_hints_apply): Handle new style
437 flag.
438
439 * src/autofit/afranges.h (SCRIPT): Use it to export no-base ranges.
440
4412015-09-04 Werner Lemberg <wl@gnu.org>
442
Werner Lemberg696b7122015-09-04 10:10:59 +0200443 [autofit] Redesign code ranges (1/2).
444
445 This patch introduces auxiliary code ranges that identify no-base
446 characters; they refer to glyphs of a script that should be hinted
447 without alignments to blue zones (mostly diacritics).
448
449 It also splits off ranges for fallback scripts that handle subscript
450 and superscript characters not covered by OpenType features. For
451 example, this greatly helps improve the hinting of various phonetic
452 alphabets, which contain a large amount characters that look like
453 superscript glyphs.
454
455 Finally, code ranges are updated to Unicode 8.0, and enclosed
456 characters are removed in general since they normally look better if
457 they stay unhinted.
458
459 * src/autofit/afranges.c (af_latn_uniranges): Updated to Unicode
460 8.0.
461 Split off superscript-like and subscript-like glyphs into...
462
463 (af_latb_uniranges, af_latp_uniranges): ... these two new arrays.
464
465 (af_xxxx_nobase_uniranges): New arrays that hold no-base characters
466 of the corresponding character ranges.
467
Werner Lemberg8cbbcf62015-09-03 06:47:30 +02004682015-09-03 Werner Lemberg <wl@gnu.org>
469
470 [autofit] Pass glyph index to hinting function.
471
472 No functionality change yet.
473
474 * src/autofit/aftypes.h (AF_WritingSystem_ApplyHintsFunc): Pass
475 glyph index.
476
477 * src/autofit/afcjk.c, src/autofit/afcjk.h (af_cjk_hints_apply),
478 src/autofit/afdummy.c (af_dummy_hints_apply), src/autofit/afindic.c
479 (af_indic_hints_apply), src/autofit/aflatin.c
480 (af_latin_hints_apply), src/autofit/aflatin2.c
481 (af_latin2_hints_apply), src/autofit/afloader.c (af_loader_load_g):
482 Updated.
483
Werner Lemberg87c81f02015-08-30 10:35:21 +02004842015-08-30 Werner Lemberg <wl@gnu.org>
485
Werner Lemberg40103a32015-08-31 08:51:52 +0200486 [autofit] Code clean-up.
487
488 * src/autofit/afglobal.h (AF_STYLE_MASK): New macro.
489 (AF_STYLE_UNASSIGNED): Use AF_STYLE_MASK for definition.
490
491 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
492 Updated.
493
4942015-08-30 Werner Lemberg <wl@gnu.org>
495
Werner Lemberg87c81f02015-08-30 10:35:21 +0200496 [autofit] Make glyph style array use 16bit values.
497
498 * include/freetype/ftautoh.h (FT_Prop_GlyphToScriptMap): Use
499 `FT_UShort' for `map' field.
500
501 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage,
502 af_face_globals_new), src/autofit/hbshim.c, src/autofit/hbshim.h
503 (af_get_coverage): Use FT_UShort for `glyph_styles' array.
504
505 * src/autofit/afglobal.h (AF_STYLE_UNASSIGNED, AF_DIGIT): Extend to
506 16 bits.
507 (AF_FaceGlobalsRec): Use `FT_UShort' for `glyph_styles' field.
508
Werner Lemberg633d8ed2015-08-26 06:18:47 +02005092015-08-26 Werner Lemberg <wl@gnu.org>
510
511 * builds/unix/configure.raw: Need harfbuzz >= 0.9.21 (#45828).
512
Werner Lemberg78b01402015-08-25 07:23:01 +02005132015-08-25 Werner Lemberg <wl@gnu.org>
514
515 [base] Improve kerning tracing and documentation.
516
517 * src/base/ftobjs.c (FT_Get_Kerning): Emit tracing message if
518 scaled-down kerning values differ.
519
Werner Lemberg91d59162015-08-18 06:04:36 +02005202015-08-18 Werner Lemberg <wl@gnu.org>
521
522 [raster] Remove last remnants of `raster5' driver.
523
524 * src/raster/ftrend1.h (ft_raster5_renderer_class): Removed.
525
526 * src/raster/rastpic.c, src/raster/rastpic.h
527 (ft_raster5_renderer_class_pic_init,
528 ft_raster5_renderer_class_pic_free): Removed.
529
Alexei Podtelezhnikova0172d12015-08-17 22:58:59 -04005302015-08-17 Alexei Podtelezhnikov <apodtele@gmail.com>
531
532 [base] Improve emboldener (#45596).
533
534 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Correct displacement
535 of zero-lenght segments.
536
Alexei Podtelezhnikov00d89952015-08-16 22:57:34 -04005372015-08-16 Alexei Podtelezhnikov <apodtele@gmail.com>
538
Alexei Podtelezhnikov815c3242015-08-17 21:48:46 -0400539 [base] Reoptimize arithmetic.
Alexei Podtelezhnikov00d89952015-08-16 22:57:34 -0400540
541 * src/base/ftcalc.c (FT_MulDiv, FT_MulFix) [!FT_LONG64]: Remove
542 special cases that slow down the general use.
543
pazerf0ed30e2015-08-15 06:53:09 +02005442015-08-15 pazer <ibemad@gmail.com>
545
546 Fix C++ compilation (#45762).
547
548 * src/base/ftstroke.c (ft_outline_glyph_class): Use
549 FT_CALLBACK_TABLE.
550
Alexei Podtelezhnikovae258aa2015-08-14 23:23:18 -04005512015-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
552
553 [truetype] Clean up.
554
555 * src/truetype/ttgload.c (TT_Process_Composite_Component): Use
556 `FT_Outline_Transform' and `FT_Outline_Translate'.
557 (translate_array): Dropped.
558
Werner Lembergd0d7ee02015-08-14 14:30:58 +02005592015-08-14 Andreas Enge <andreas.enge@inria.fr>
560
561 * builds/unix/detect.mk (CONFIG_SHELL): Don't handle it (#44261).
562
Werner Lemberg14d6b5d2015-08-13 15:22:17 +02005632015-08-13 Werner Lemberg <wl@gnu.org>
564
565 [truetype] Introduce named instance access to GX fonts.
566
567 For functions querying a face, bits 16-30 of the face index can hold
568 the named instance index if we have a GX font. The indices start
569 with value 1; value 0 indicates font access without GX variation
570 data.
571
572 * include/freetype/freetype.h (FT_FaceRec): Update documentation.
573 * include/freetype/internal/sfnt.h: Ditto.
574
575 * src/sfnt/sfobjs.c (sfnt_init_face)
576 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Get number of named instances and
577 do argument checks.
578 (sfnt_load_face): Updated.
579
580 * src/truetype/ttobjs.c (tt_face_init)
581 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Use named instance, overwriting
582 the style name.
583
584 * src/base/ftobjs.c (open_face_from_buffer,
585 open_face_PS_from_sfnt_stream): Updated.
586 * src/bdf/bdfdrivr.c (BDF_Face_Init): Updated.
587 * src/cff/cffload.c (cff_font_load): Updated.
588
589 * src/cff/cffobjs.c (cff_face_init): Make function exit early for
590 pure CFF fonts if `font_index < 0'.
591 Updated.
592
593 * src/cid/cidobjs.c (cid_face_init): Updated.
594 * src/pcf/pcfdrivr.c (PCF_Face_Init): Updated.
595 * src/pfr/pfrobjs.c (pfr_face_init): Updated.
596 * src/type1/t1objs.c (T1_Face_Init): Updated.
597 * src/type42/t42objs.c (T42_Face_Init): Updated.
598 * src/winfonts/winfnt.c (fnt_face_get_dll_font, FNT_Face_Init):
599 Updated.
600
601 * docs/CHANGES: Updated.
602
Alexei Podtelezhnikov4a466862015-08-12 23:45:40 -04006032015-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
604
605 [type1,cff,cid] Streamline font matrix application.
606
607 * src/type1/t1gload.c (T1_Load_Glyph): Directly modify advances only
608 if font matrix is not trivial.
609 * src/cff/cffgload.c (cff_slot_load): Ditto.
610 * sff/cid/cidgload.c (cid_slot_load_glyph): Ditto for advances and the
611 entire outline.
612
Werner Lemberg7ebe6ac2015-08-11 06:47:25 +02006132015-08-11 Werner Lemberg <wl@gnu.org>
614
615 [builds/unix] Minor.
616
617 * builds/unix/configure.raw:
618 s/lib{priv,staticconf}/libs{priv,staticconf}/ for orthogonality with
619 similarly named uppercase variables.
620
Alexei Podtelezhnikova37da212015-08-10 23:05:02 -04006212015-08-10 Alexei Podtelezhnikov <apodtele@gmail.com>
622
623 [type1,cid,type42] Minor improvements.
624
625 * src/type1/t1load.c (t1_parse_font_matrix): Scale units per EM only
626 when necessary. Refresh comments.
627 * src/cid/cidload.c (cid_parse_font_matrix): Ditto.
628 * src/type42/t42parse.c (t42_parse_font_matrix): Refresh comments.
629
Werner Lemberge5f44692015-08-08 07:45:03 +02006302015-08-08 Werner Lemberg <wl@gnu.org>
631
Werner Lembergbd75a512015-08-08 08:39:45 +0200632 [type42] Fix glyph access.
633
634 This is a severe bug: We've missed one level of indirection, as
635 described in the Type 42 specification. As a result, ftview
636 sometimes showed incorrect glyphs for given glyph names, and even
637 displayed `error 0x0006' (invalid argument!) in case the number of
638 glyph indices differed between the Type 42 font and the embedded
639 TTF.
640
641 Apparently, noone ever noticed it; this shows how much Type 42 fonts
642 are in use...
643
644 * src/type42/t42objs.c (T42_GlyphSlot_Load): Map Type 42 glyph index
645 to embedded TTF's glyph index.
646
6472015-08-08 Werner Lemberg <wl@gnu.org>
648
Werner Lemberge5f44692015-08-08 07:45:03 +0200649 [type42] Minor clean-up.
650
651 * src/type42/t42parse.c (t42_parse_font_matrix): Remove unused
652 variable.
653
Alexei Podtelezhnikovfd705122015-08-06 21:49:08 -04006542015-08-06 Alexei Podtelezhnikov <apodtele@gmail.com>
655
656 [type42] Parse FontMatrix according to specifications.
657
658 * src/type42/t42parse.c (t42_parse_font_matrix): Type 42 FontMatrix
659 does not need scaling by 1000. Units_per_EM are taken from the
660 embedded TrueType.
661
Werner Lembergff406e22015-08-06 07:34:50 +02006622015-08-06 Werner Lemberg <wl@gnu.org>
663
664 [autofit] Improve Arabic hinting.
665
666 Problem reported by Titus Nemeth <tn@tntypography.eu> (by using
667 ttfautohint).
668
669 * src/autofit/afblue.dat: Add neutral blue zone for the tatweel
670 character.
671
672 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
673
Alexei Podtelezhnikov98e8e992015-08-06 00:06:14 -04006742015-08-05 Alexei Podtelezhnikov <apodtele@gmail.com>
675
676 [truetype] Clean up types.
677
678 * src/truetype/ttobjs.c (TT_Size): Move declaration from here.
679 * include/freetype/internal/tttypes.h (TT_Size): ... to here.
680 (TT_LoaderRec): Switch to appropriate types for `face' and `size'.
681 * src/truetype/ttgload.c: Remove corresponding type casts.
682 * src/truetype/ttsubpix.c: Ditto.
683
Werner Lemberg15e2a4f2015-08-05 21:53:50 +02006842015-08-05 Werner Lemberg <wl@gnu.org>
685
686 [autofit] Improve recognition of flat vs. rounded segments.
687
688 Lower the flatness threshold from upem/8 to upem/14, making the
689 auto-hinter accept shorter elements.
690
691 Synchronize flat/round stem selection algorithm with blue zone code.
692
693 * src/autofit/aflatin.c (FLAT_THRESHOLD): New macro.
694 (af_latin_metrics_init_blues): Use it.
695 (af_latin_hints_compute_segments): Collect information on maximum
696 and minimum coordinates of `on' points; use this to add a constraint
697 for the flat/round decision similar to
698 `af_latin_metrics_init_blues'.
699
Werner Lembergeb22ef22015-08-04 06:50:04 +02007002015-08-04 Werner Lemberg <wl@gnu.org>
701
702 Another left-shift bug (#45681).
703
704 * src/base/ftobjs.c (IsMacBinary): Only accept positive values for
705 `dlen'.
706
Alexei Podtelezhnikov7e6c3212015-08-03 23:26:13 -04007072015-08-03 Alexei Podtelezhnikov <apodtele@gmail.com>
708
709 [base] Fix `ft_corner_orientation'.
710
711 Remove casting from `FT_Long' to `FT_Int' that might change the sign
712 of the return value and make it faster too.
713
714 * src/base/ftcalc.c (ft_corner_orientation): On 32-bit systems, stay
715 with 32-bit arithmetic when safe. Use plain math on 64-bit systems.
716 * src/pshinter/pshalgo.c: Remove old unused code.
717
Werner Lembergca6a5cf2015-08-03 08:51:18 +02007182015-08-03 Werner Lemberg <wl@gnu.org>
719
Werner Lemberg8dfc7602015-08-03 12:23:30 +0200720 * src/truetype/ttgload.c (load_truetype_glyph)
721 [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Fix crash for composite glyphs
722 having a depth greater than 1.
723
7242015-08-03 Werner Lemberg <wl@gnu.org>
725
Werner Lembergca6a5cf2015-08-03 08:51:18 +0200726 Fix typo in clang bug from 2015-07-31 (#45678).
727
728 * src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Fix inequality.
729
Werner Lemberg70e9d812015-08-02 09:42:12 +02007302015-08-02 Werner Lemberg <wl@gnu.org>
731
Werner Lemberga82c45d2015-08-02 18:35:49 +0200732 * CMakeLists.txt: Improve shared library support.
733
734 Based on a patch from John Cary <cary@txcorp.com>.
735
7362015-08-02 Werner Lemberg <wl@gnu.org>
737
Werner Lemberg682c2712015-08-02 15:46:26 +0200738 * builds/unix/freetype-config.in (enable_shared): Remove. Unused.
739
7402015-08-02 Werner Lemberg <wl@gnu.org>
741
Werner Lemberg70e9d812015-08-02 09:42:12 +0200742 Fix more invalid left-shifts.
743
744 * src/pfr/pfrgload.c (pfr_glyph_load_compound): Use multiplication,
745 not left-shift.
746
747 * src/truetype/ttgxvar.c (ft_var_load_avar, ft_var_load_gvar,
748 tt_face_vary_cvt, TT_Vary_Apply_Glyph_Deltas): Use multiplication,
749 not left-shift.
750
Werner Lemberg5d1b8ab2015-07-31 21:49:07 +02007512015-07-31 Werner Lemberg <wl@gnu.org>
752
Werner Lemberg6343ba22015-08-01 07:53:48 +0200753 Fix some bugs found by clang's `-fsanitize=undefined' (#45661).
754
755 * src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Only accept
756 positive values from header.
757 Check overflow.
758
759 * src/base/ftoutln.c (SCALED): Correctly handle left-shift of
760 negative values.
761
762 * src/bdf/bdf.h (_bdf_glyph_modified, _bdf_set_glyph_modified,
763 _bdf_clear_glyph_modified): Use unsigned long constant.
764
765 * src/bdf/bdfdrivr.c (BDF_Size_Select, BDF_Glyph_Load): Don't
766 left-shift values that can be negative.
767
768 * src/pcf/pcfdrivr.c (PCF_Size_Select, PCF_Glyph_Load): Don't
769 left-shift values that can be negative.
770
771 * src/raster/ftraster.c (SCALED): Correctly handle left-shift of
772 negative values.
773
774 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Don't left-shift
775 values that can be negative.
776
777 * src/truetype/ttgload.c (TT_Load_Composite_Glyph,
778 compute_glyph_metrics, load_sbit_image): Don't left-shift values
779 that can be negative.
780
7812015-07-31 Werner Lemberg <wl@gnu.org>
782
Werner Lemberg5d1b8ab2015-07-31 21:49:07 +0200783 Define FT_LONG_MAX.
784
785 * include/freetype/config/ftstdlib.h (FT_LONG_MAX): New macro.
786 * src/cff/cf2arrst.c (cf2_arrstack_setNumElements): Use it.
787
7882015-07-28 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov2b07a5a2015-07-28 23:14:30 -0400789
790 * src/base/ftcalc.c (FT_Vector_NormLen): Clarify.
791
Werner Lemberg5d1b8ab2015-07-31 21:49:07 +02007922015-07-27 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikove8b186e2015-07-27 23:22:34 -0400793
794 * src/base/ftcalc.c (FT_Vector_NormLen): Explicate type conversions.
795
Matthias Clasenb650dfb2015-07-26 21:08:34 +02007962015-07-26 Matthias Clasen <matthias.clasen@gmail.com>
797
798 [cff] Don't use `hmtx' table for LSB (#45520).
799
800 * src/cff/cffgload.c (cff_slot_load): Use `htmx' table for advance
801 width only. Bug introduced 2015-04-10.
802
Werner Lembergf9be5672015-07-09 15:10:31 +02008032015-07-09 Werner Lemberg <wl@gnu.org>
804
805 Better support of user-supplied C++ namespaces.
806
807 See
808
809 http://lists.nongnu.org/archive/html/freetype-devel/2015-07/msg00008.html
810
811 for a rationale.
812
813 * src/autofit/afpic.h, src/base/basepic.h, src/cff/cffpic.h,
814 src/pshinter/pshpic.h, src/psnames/pspic.h, src/raster/rastpic.h,
815 src/sfnt/sfntpic.h, src/smooth/ftspic.h, src/truetype/ttpic.h
816 (FT_BEGIN_HEADER, FT_END_HEADER): Move macro calls to not enclose
817 header files that contain FT_{BEGIN,END}_HEADER macros by
818 themselves.
819
820 * src/autofit/aftypes.h [FT_DEBUG_AUTOFIT]: Include
821 FT_CONFIG_STANDARD_LIBRARY_H earlier.
822
823 * src/truetype/ttpic.h: Include FT_INTERNL_PIC_H.
824
Werner Lemberg1cdac102015-07-07 14:04:44 +02008252015-07-07 Werner Lemberg <wl@gnu.org>
826
827 [sfnt] Make `tt_face_get_name' member of the SFNT interface.
828
829 * include/freetype/internal/sfnt.h (TT_Get_Name_Func): New
830 prototype.
831 (SFNT_Interface, FT_DEFINE_SFNT_INTERFACE): New member `get_name'.
832
833 * src/sfnt/sfdriver.c (sfnt_interface): Updated.
834
835 * src/sfnt/sfobjs.c (tt_face_get_name): Tag it with `LOCAL_DEF'.
836 * src/sfnt/sfobjs.h: Add prototype for it.
837
Werner Lembergeb1bba92015-06-30 09:46:39 +02008382015-06-30 Werner Lemberg <wl@gnu.org>
839
840 Fix some clang compiler warnings.
841
842 * src/base/ftoutln.c (FT_Outline_EmboldenXY), src/cff/cf2intrp.c
843 (cf2_interpT2CharString), src/truetype/ttgload.c
844 (load_truetype_glyph), src/truetype/ttgxvar.c (tt_handle_deltas),
845 src/truetype/ttinterp.c (Ins_INSTCTRL): Fix signedness issues.
846
Alexei Podtelezhnikov884e4e62015-06-29 22:32:05 -04008472015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
848
Alexei Podtelezhnikov5aaabb42015-06-29 22:46:54 -0400849 [truetype] Speed up bytecode interpreter.
850
851 * src/truetype/ttinterp.c (Normalize): Use `FT_Vector_NormLen'.
852
8532015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
854
Alexei Podtelezhnikov9ef02bd2015-06-29 22:39:10 -0400855 [base] Speed up emboldening.
856
Werner Lembergeb1bba92015-06-30 09:46:39 +0200857 * src/base/ftoutln.c (FT_Outline_EmboldenXY): Use
858 `FT_Vector_NormLen'.
Alexei Podtelezhnikov9ef02bd2015-06-29 22:39:10 -0400859
8602015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
861
Alexei Podtelezhnikov884e4e62015-06-29 22:32:05 -0400862 [base] Implement fast vector normalization.
863
864 The function uses Newton's iterations instead of dividing vector
865 components by its length, which needs a square root. This is,
866 literally, a bit less accurate but a lot faster.
867
868 * src/base/ftcalc.c (FT_Vector_NormLen): New function.
869
Werner Lemberg22479ca2015-06-28 10:26:33 +02008702015-06-28 Werner Lemberg <wl@gnu.org>
871
Werner Lemberg7cdc77f2015-06-28 11:40:02 +0200872 * CMakeLists.txt: Always create `ftconfig.h'.
873
874 For non-UNIX builds, the file stays unmodified. However, it's
875 better to have the main configuration files at the same place
876 regardless of the OS.
877
8782015-06-28 Werner Lemberg <wl@gnu.org>
879
Werner Lemberg2c89e2c2015-06-28 11:06:47 +0200880 * CMakeLists.txt: Improve MSVC support (#43737).
881
8822015-06-28 Werner Lemberg <wl@gnu.org>
883
Werner Lemberg52c9b1a2015-06-28 11:03:10 +0200884 [cmake] Check for libraries and create `ftoption.h'.
885
886 * builds/FindHarfBuzz.cmake: New file, taken from
887
888 https://trac.webkit.org/browser/trunk/Source/cmake/FindHarfBuzz.cmake
889
890 * CMakeLists.Txt: Add path to local cmake modules.
891 Find dependencies for zlib, bzip2, libpng, and harfbuzz.
892 Create `ftoption.h' file.
893 Set up include and linker stuff for libraries.
894
8952015-06-28 Werner Lemberg <wl@gnu.org>
896
Werner Lemberg97b757d2015-06-28 10:42:47 +0200897 * CMakeLists.txt: Fix creation of `ftconfig.h'.
898 Check for UNIX header files using `check_include_file'.
899 Set up correct header include directories.
900
9012015-06-28 Werner Lemberg <wl@gnu.org>
902
Werner Lemberg22479ca2015-06-28 10:26:33 +0200903 * CMakeLists.txt: Disallow in-source builds.
904
Werner Lemberg802f6a92015-06-27 07:12:42 +02009052015-06-27 Werner Lemberg <wl@gnu.org>
906
907 * src/tools/docmaker/utils.py (check_output): Add missing `\n'.
908
Werner Lemberg94c79c22015-06-26 06:46:59 +02009092015-06-26 Werner Lemberg <wl@gnu.org>
910
Werner Lemberg802f6a92015-06-27 07:12:42 +0200911 * CMakeLists.txt: Select platform-dependent `ftdebug.c'.
Werner Lemberg94c79c22015-06-26 06:46:59 +0200912
Werner Lemberg392cf222015-06-25 13:04:57 +02009132015-06-25 Werner Lemberg <wl@gnu.org>
914
Werner Lemberg68222dd2015-06-25 16:38:11 +0200915 * CMakeLists.txt: Use cmake functions for generating `ftconfig.h'.
916 Additionally, do this for UNIX only.
917
9182015-06-25 Werner Lemberg <wl@gnu.org>
919
Werner Lemberg5ef5a4f2015-06-25 15:45:13 +0200920 * CMakeLists.txt (BASE_SRCS): Use `ftbase.c' and `psnames.c'.
921
9222015-06-25 Werner Lemberg <wl@gnu.org>
923
Werner Lemberg392cf222015-06-25 13:04:57 +0200924 Another adjustment to header locations.
925
926 This change is a result of a discussion thread on freetype-devel
927
928 http://lists.nongnu.org/archive/html/freetype-devel/2015-06/msg00041.html
929
930 Re-introduce the `freetype2' subdirectory for all FreeType header
931 files after installation, and rename the `freetype2' subdirectory in
932 the git repository to `freetype'.
933
934 * include/freetype2: Renamed to...
935 * include/freetype: This.
936
937 * CMakeLists.txt (PUBLIC_HEADERS, PUBLIC_CONFIG_HEADERS,
938 PRIVATE_HEADERS): Updated.
939 Update creation of `ftconfig.h'.
940 Install generated `ftconfig.h'.
941
942 * Jamfile (HDRMACRO, RefDoc), autogen.sh: Updated.
943
944 * builds/amiga/include/config/ftconfig.h, builds/freetype.mk
945 (PUBLIC_DIR), builds/symbian/bld.inf, builds/toplevel.mk (work),
946 builds/unix/freetype2.in: Updated.
947
948 * builds/unix/freetype-config.in: Updated.
949 * builds/unix/configure.raw: Don't check for `rmdir'.
950 * builds/unix/unix-def.in (DELDIR): Use `rm -rf', which is portable
951 according to the autoconf info manual.
952 * builds/unix/install.mk (install, uninstall,
953 distclean_project_unix): Update and simplify.
954
955 * builds/wince/*, builds/windows/*: Updated.
956
957 * devel/ft2build.h, include/ft2build.h: Updated.
958
959 * include/freetype2/config/ftheader.h,
960 include/freetype2/internal/ftserv.h,
961 include/freetype2/internal/internal.h: Update all header file
962 macros.
963
964 * src/tools/chktrcmp.py (TRACE_DEF_FILES): Updated.
965
966 * docs/*: Updated.
967
Werner Lemberg1982a882015-06-26 06:52:34 +02009682015-06-24 Alexei Podtelezhnikov <apodtele@gmail.com>
969
970 * src/bdf/bdflib.c (_bdf_parse_start): Disallow 0 bpp.
971
9722015-06-24 Alexei Podtelezhnikov <apodtele@gmail.com>
973
974 * src/bdf/bdflib.c (_bdf_parse_start): Simplify bpp parsing.
975
Werner Lemberg59312682015-06-23 09:24:48 +02009762015-06-23 Werner Lemberg <wl@gnu.org>
977
978 s/TYPEOF/FT_TYPEOF/ (#45376).
979
980 * builds/unix/ftconfig.in, builds/vms/ftconfig.in,
981 include/freetype2/config/ftconfig.h,
982 include/freetype2/internal/ftobjs.h, src/autofit/afwarp.h: Do it.
983
Werner Lemberg8502c982015-06-22 06:35:23 +02009842015-06-22 Werner Lemberg <wl@gnu.org>
985
986 Fix Savannah bug #45097.
987
988 We no longer `pollute' the namespace of possible header file names;
989 instead we move `ft2build.h' up by one level so that it gets
990 installed in the default include directory (e.g.,
991 /usr/local/include). After this commit, only `ft2build.h' stays in
992 the compiler's include path.
993
994 No visible changes for the user who follows the standard FreeType
995 header inclusion rules.
996
997 * include/*: Move to ...
998 * include/freetype2/*: This directory, except `ft2build.h'.
999
1000 * CMakeLists.txt (PUBLIC_HEADERS, PUBLIC_CONFIG_HEADERS,
1001 PRIVATE_HEADERS), Jamfile (HDRMACRO, RefDoc), autogen.sh: Updated.
1002
1003 * builds/amiga/include/config/ftconfig.h, builds/freetype.mk
1004 (PUBLIC_DIR), builds/symbian/bld.inf, builds/toplevel.mk (work),
1005 builds/unix/install.mk (install, uninstall),
1006 builds/unix/freetype2.in: Updated.
1007
1008 * builds/unix/freetype-config.in: Updated.
1009 Emit -I directory only if it is not `/usr/include'.
1010
1011 * builds/wince/*, builds/windows/*: Updated.
1012
1013 * devel/ft2build.h, include/ft2build.h: Updated.
1014
1015 * include/freetype2/config/ftheader.h,
1016 include/freetype2/internal/ftserv.h,
1017 include/freetype2/internal/internal.h: Update all header file
1018 macros.
1019
1020 * src/tools/chktrcmp.py (TRACE_DEF_FILES): Updated.
1021
Werner Lemberg31d97df2015-06-21 19:12:12 +020010222015-06-21 Werner Lemberg <wl@gnu.org>
1023
1024 Make Jam support work again.
1025
1026 This is just very basic stuff and just a little bit tested on
1027 GNU/Linux only. I won't delve into this since I'm not a Jam user.
1028
1029 * Jamfile: Call `HDRMACRO' for `ftserv.h' also.
1030 (DEFINES): Replace with...
1031 (CCFLAGS): ... this.
1032
1033 * src/Jamfile: Don't call `HDRMACRO' for `internal.h'; this is
1034 already handled in the top-level Jamfile.
1035
1036 * src/autofit/Jamfile (DEFINES): Replace with...
1037 (CCFLAGS): ... this.
1038 (_sources): Add missing files.
1039
1040 * src/cache/Jamfile: Don't call `HDRMACRO' for `ftcache.h'; it no
1041 longer contains macro header definitions.
1042
1043 * src/base/Jamfile, src/cff/Jamfile, src/sfnt/Jamfile,
1044 src/truetype/Jamfile (_sources): Add missing files.
1045
Werner Lemberg1a147ac2015-06-16 10:20:07 +020010462015-06-16 Werner Lemberg <wl@gnu.org>
1047
1048 Fix Savannah bug #45326.
1049
1050 * src/sfnt/sfntpic.h (SFNT_SERVICES_GET): Remove duplicate
1051 definitions.
1052
Werner Lemberge1862302015-06-07 16:11:18 +020010532015-06-07 Werner Lemberg <wl@gnu.org>
1054
1055 * Version 2.6 released.
1056 =======================
1057
1058
1059 Tag sources with `VER-2-6'.
1060
1061 * docs/VERSION.DLL: Update documentation and bump version number to
1062 2.6.
1063
1064 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
1065 builds/windows/vc2005/index.html,
1066 builds/windows/vc2008/freetype.vcproj,
1067 builds/windows/vc2008/index.html,
1068 builds/windows/vc2010/freetype.vcxproj,
1069 builds/windows/vc2010/index.html,
1070 builds/windows/visualc/freetype.dsp,
1071 builds/windows/visualc/freetype.vcproj,
1072 builds/windows/visualc/index.html,
1073 builds/windows/visualce/freetype.dsp,
1074 builds/windows/visualce/freetype.vcproj,
1075 builds/windows/visualce/index.html,
1076 builds/wince/vc2005-ce/freetype.vcproj,
1077 builds/wince/vc2005-ce/index.html,
1078 builds/wince/vc2008-ce/freetype.vcproj,
1079 builds/wince/vc2008-ce/index.html: s/2.5.5/2.6/, s/255/26/.
1080
1081 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 6.
1082 (FREETYPE_PATCH): Set to 0.
1083
1084 * builds/unix/configure.raw (version_info): Set to 18:0:12.
1085 * CMakeLists.txt (VERSION_MINOR): Set to 0.
1086 (VERSION_PATCH): Set to 6.
1087
1088 * src/autofit/afmodule.c [!FT_MAKE_OPTION_SINGLE_OBJECT]: Add
1089 declarations for dumping functions.
1090
1091 * src/truetype/ttinterp.c (TT_New_Context): Pacify compiler.
1092
1093 * builds/toplevel.mk: Use `freetype.mk's code to compute the version
1094 string.
1095 Don't include a zero patch level in version string.
1096 * builds/freetype.mk: Remove code for computing the version string.
1097
Ashish Azad472119a2015-06-06 05:45:17 +020010982015-06-06 Ashish Azad <ashish.azad@samsung.com>
1099
1100 Fix Savannah bug #45260.
1101
1102 * src/pfr/pfrdrivr.c (pfr_get_kerning): Fix typo.
1103
Werner Lemberg75534a02015-06-03 00:54:09 +020011042015-06-03 Werner Lemberg <wl@gnu.org>
1105
1106 [truetype] Fix memory leak.
1107
1108 Problem reported by Grissiom <chaos.proton@gmail.com>; in
1109
1110 http://lists.nongnu.org/archive/html/freetype/2015-05/msg00013.html
1111
1112 there is an example code to trigger the bug.
1113
1114 * src/truetype/ttobjs.c (tt_size_init_bytecode): Free old `size'
1115 data before allocating again. Bug most probably introduced four
1116 years ago in version 2.4.3.
1117
11182015-06-02 Werner Lemberg <wl@gnu.org>
Werner Lemberg54d04282015-06-01 12:12:06 +02001119
Werner Lembergd1ade6d2015-06-02 11:44:52 +02001120 [raster] Add more tracing.
1121
1122 * src/raster/ftraster.c (FT_TRACE7) [_STANDALONE_]: Define.
1123 (Vertical_Sweep_Span, Vertical_Sweep_Drop, Horizontal_Sweep_Span,
1124 Horizontal_Sweep_Drop, Render_Glyph): Add tracing calls.
1125
11262015-06-01 Werner Lemberg <wl@gnu.org>
1127
Werner Lemberg54d04282015-06-01 12:12:06 +02001128 [truetype] While tracing opcodes, show code position and stack.
1129
1130 * src/truetype/ttinterp.c: Change all existing TRACE7 calls to
1131 TRACE6.
1132 (opcode_name): Add string lengths.
1133 (TT_RunIns): Implement display of code position and stack.
1134
Werner Lembergcdee7d12015-05-31 11:54:42 +020011352015-05-31 Werner Lemberg <wl@gnu.org>
1136
Werner Lemberge9df4e42015-05-31 12:21:34 +02001137 [truetype] In GX, make private point numbers work correctly.
1138
1139 This is completely missing in Apple's documentation: If a `gvar'
1140 tuple uses private point numbers (this is, deltas are specified for
1141 some points only), the uncovered points must be interpolated for
1142 this tuple similar to the IUP bytecode instruction. Examples that
1143 need this functionality are glyphs `Oslash' and `Q' in Skia.ttf.
1144
1145 * src/truetype/ttgxvar.c (tt_delta_shift, tt_delta_interpolate,
1146 tt_handle_deltas): New functions.
1147 (TT_Vary_Get_Glyph_Deltas): Renamed to...
1148 (TT_Vary_Apply_Glyph_Deltas): ... this; it directly processes the
1149 points and does no longer return an array of deltas.
1150 Add tracing information.
1151 Call `tt_handle_deltas' to interpolate missing deltas.
1152 Also fix a minor memory leak in case of error.
1153
1154 * src/truetype/ttgxvar.h: Updated.
1155
1156 * src/truetype/ttgload.c (TT_Process_Simple_Glyph,
1157 load_truetype_glyph): Updated.
1158
11592015-05-31 Werner Lemberg <wl@gnu.org>
1160
Werner Lemberg9845c1d2015-05-31 11:57:31 +02001161 [truetype] In GX, make intermediate tuplets work at extrema.
1162
1163 * src/truetype/ttgxvar.c (ft_var_apply_tuple): Fix range condition.
1164
11652015-05-31 Werner Lemberg <wl@gnu.org>
1166
Werner Lembergcdee7d12015-05-31 11:54:42 +02001167 [truetype] Add tracing information to GX code.
1168
1169 * src/truetype/ttgxvar.c (ft_var_load_avar, ft_var_load_gvar,
1170 ft_var_apply_tuple, TT_Get_MM_Var, TT_Set_MM_Blend,
1171 TT_Set_Var_Design, tt_face_vary_cvt): Do it.
1172
Werner Lemberg366b2ea2015-05-28 10:58:40 +020011732015-05-28 Werner Lemberg <wl@gnu.org>
1174
1175 * src/tools/apinames.c (names_dump): Fix invalid reference.
1176
1177 Problem reported by Guzman Mosqueda, Jose R
1178 <jose.r.guzman.mosqueda@intel.com>.
1179
Werner Lemberga5e1f6f2015-05-24 23:29:23 +020011802015-05-24 Werner Lemberg <wl@gnu.org>
1181
1182 [truetype] Fix commit from 2015-05-22.
1183
1184 * src/truetype/ttgload.c, src/truetype/ttinterp.c: Guard new code
1185 with `TT_CONFIG_OPTION_SUBPIXEL_HINTING'.
1186
1187 Problem reported by Nikolaus Waxweiler <madigens@gmail.com>.
1188
Werner Lembergbb435da2015-05-23 07:21:25 +020011892015-05-23 Werner Lemberg <wl@gnu.org>
1190
Werner Lemberg7f099482015-05-24 09:50:24 +02001191 [truetype] Fix return values of GETINFO bytecode instruction.
1192
1193 * src/truetype/ttinterp.h (TT_ExecContextRec): New fields
1194 `vertical_lcd' and `gray_cleartype'.
1195
1196 * src/truetype/ttgload.c (tt_loader_init): Initialize new fields.
1197 Change `symmetrical smoothing' to TRUE, since FreeType produces
1198 exactly this.
1199
1200 * src/truetype/ttinterp.c (Ins_GETINFO): Fix selector/return bit
1201 values for symmetrical smoothing, namely 11/18.
1202 Handle bits for vertical LCD subpixels (8/15) and Gray ClearType
1203 (12/19).
1204
12052015-05-23 Werner Lemberg <wl@gnu.org>
1206
Werner Lembergbb435da2015-05-23 07:21:25 +02001207 [truetype] Minor.
1208
1209 * src/truetype/ttinterp.h (TT_ExecContext):
1210 s/subpixel/subpixel_hinting.
1211
1212 * src/truetype/ttgload.c, src/truetype/ttgload.h: Updated.
1213
12142015-05-22 Werner Lemberg <wl@gnu.org>
Werner Lemberg790b8df2015-05-20 12:33:40 +02001215
Werner Lembergc61cad82015-05-22 22:02:15 +02001216 [truetype] Support selector index 3 of the INSTCTRL instruction.
1217
1218 This flag activates `native ClearType hinting', disabling backwards
1219 compatibility mode as described in Greg Hitchcocks whitepaper. In
1220 other words, it enables unrestricted functionality of all TrueType
1221 instructions in ClearType.
1222
1223 * src/truetype/ttgload.c (tt_get_metrics): Call `sph_set_tweaks'
1224 unconditionally.
1225 (tt_loader_init): Unset `ignore_x_mode' flag if bit 2 of
1226 `GS.instruct_control' is active.
1227
1228 * src/truetype/ttinterp.c (Ins_INSTCTRL): Handle selector index 3.
1229 (Ins_GETINFO): Updated.
1230
1231 * docs/CHANGES: Document it.
1232
12332015-05-20 Werner Lemberg <wl@gnu.org>
1234
Werner Lemberg790b8df2015-05-20 12:33:40 +02001235 [truetype] Minor.
1236
1237 * src/truetype/ttinterp.h (SetSuperRound): Fix type of `GridPeriod'
1238 argument.
1239
Werner Lemberg0a6b6ff2015-05-17 22:54:48 +020012402015-05-17 Werner Lemberg <wl@gnu.org>
1241
1242 [truetype] Fix loading of composite glyphs.
1243
1244 * src/truetype/ttgload.c (TT_Load_Composite_Glyph): If the
1245 ARGS_ARE_XY_VALUES flag is not set, handle argument values as
1246 unsigned. I trust `ttx' (which has exactly such code) that it does
1247 the right thing here...
1248
1249 The reason that noone has ever noticed this bug is probably the fact
1250 that point-aligned subglyphs are rare, as are subglyphs with a
1251 number of points in the range [128;255], which is quite large (or
1252 even in the range [32768;65535], which is extremely unlikely).
1253
Chris Liddelld65bf722015-05-12 07:16:46 +020012542015-05-12 Chris Liddell <chris.liddell@artifex.com>
1255
Chris Liddella87fb8c2015-05-12 07:27:35 +02001256 [cff] Make the `*curveto' operators more tolerant.
1257
1258 * src/cff/cf2intrp.c (cf2_interpT2CharString): The opcodes
1259 `vvcurveto', `hhcurveto', `vhcurveto', and `hvcurveto' all iterate,
1260 pulling values off the stack until the stack is exhausted.
1261 Implicitly the stack must be a multiple (or for subtly different
1262 behaviour) a multiple plus a specific number of extra values deep.
1263 If that's not the case, enforce it (as the old code did).
1264
12652015-05-12 Chris Liddell <chris.liddell@artifex.com>
1266
Chris Liddelld65bf722015-05-12 07:16:46 +02001267 [cff] fix incremental interface with new cff code.
1268
1269 * src/cff/cf2ft.c (cf2_getSeacComponent): When using the incremental
1270 interface to retrieve glyph data for a SEAC, it be left to the
1271 incremental interface callback to apply the encoding to raw
1272 character index (as it was in the previous code).
1273
Alexei Podtelezhnikov40914952015-04-29 21:57:30 -040012742015-04-29 Alexei Podtelezhnikov <apodtele@gmail.com>
1275
1276 [autofit] Speed up IUP.
1277
1278 * src/autofit/afhints.c (af_iup_interp): Separate trivial snapping to
1279 the same position from true interpolation, use `scale' to reduce
1280 divisions.
1281
Werner Lemberg3cc076d2015-04-28 09:16:27 +020012822015-04-28 Werner Lemberg <wl@gnu.org>
1283
1284 [cff] Use `name' table for PS name if we have a SFNT-CFF.
1285
1286 This follows the OpenType 1.7 specification. See
1287
1288 http://tug.org/pipermail/tex-live/2015-April/036634.html
1289
1290 for a discussion.
1291
1292 * src/cff/cffdrivr.c (cff_get_ps_name): Use the `sfnt' service if we
1293 have an SFNT.
1294
Alexei Podtelezhnikov40623a12015-04-27 22:27:00 -040012952015-04-27 Alexei Podtelezhnikov <apodtele@gmail.com>
1296
1297 [truetype] Speed up IUP.
1298
1299 * src/truetype/ttinterp.c (_iup_worker_interpolate): Separate trivial
1300 snapping to the same position from true interpolation.
1301
Werner Lemberg12661a52015-04-21 07:13:59 +020013022015-04-21 Werner Lemberg <wl@gnu.org>
1303
Werner Lemberg14df6b12015-04-22 11:14:35 +02001304 [autofit] By default, enable warping code but switch off warping.
1305
1306 Suggested by Behdad.
1307
1308 * include/config/ftoption.h: Define AF_CONFIG_OPTION_USE_WARPER.
1309
1310 * src/autofit/afmodule.c (af_autofitter_init): Initialize `warping'
1311 with `false'.
1312
13132015-04-21 Werner Lemberg <wl@gnu.org>
1314
Werner Lembergd164f702015-04-21 07:51:41 +02001315 * docs/CHANGES: Updated.
1316
13172015-04-21 Werner Lemberg <wl@gnu.org>
1318
Werner Lemberg12661a52015-04-21 07:13:59 +02001319 [autofit] Introduce `warping' property.
1320
1321 This code replaces the debugging hook from the previous commit with
1322 a better, more generic solution.
1323
1324 * include/ftautoh.h: Document it.
1325
1326 * src/autofit/afmodule.h (AF_ModuleRec)
1327 [AF_CONFIG_OPTION_USE_WARPER]: Add `warping' field.
1328
1329 * src/autofit/afmodule.c (_af_debug_disable_warper): Remove.
1330 (af_property_set, af_property_get, af_autofitter_init)
1331 [AF_CONFIG_OPTION_USE_WARPER]: Handle `warping' option.
1332
1333 * src/autofit/afhints.h (AF_HINTS_DO_WARP): Remove use of the no
1334 longer existing `_af_debug_disable_warper'.
1335
1336 * src/autofit/afcjk.c (af_cjk_hints_init), src/autofit/aflatin.c
1337 (af_latin_hints_init), src/autofit/aflatin2.c (af_latin2_hints_init)
1338 [AF_CONFIG_OPTION_USE_WARPER]: Add `AF_SCALER_FLAG_NO_WARPER' to the
1339 scaler flags if warping is off.
1340
1341 * src/autofit/aftypes.h: Updated.
1342
Werner Lemberg58f48f02015-04-16 20:11:49 +020013432015-04-16 Werner Lemberg <wl@gnu.org>
1344
1345 [autofit] Add debugging hook to disable warper.
1346
1347 * src/autofit/afmodule.c (_af_debug_disable_warper)
1348 [FT_DEBUG_AUTOFIT]: New global variable.
1349
1350 * src/autofit/aftypes.h: Updated.
1351 (AF_SCALER_FLAG_NO_WARPER): New macro (not actively used yet).
1352
1353 * src/autofit/afhints.h (AF_HINTS_DO_WARP): New macro.
1354
1355 * src/autofi/aflatin.c (af_latin_hints_apply)
1356 [AF_CONFIG_OPTION_USE_WARPER]: Use `AF_HINTS_DO_WARP' to control use
1357 of warper.
1358
1359 * src/autofit/afcjk.c (af_cjk_hints_init, af_cjk_hints_apply)
1360 [AF_CONFIG_OPTION_USE_WARPER]: Synchronize with `aflatin.c'.
1361
1362 * src/autofit/aflatin2.c (af_latin2_hints_apply)
1363 [AF_CONFIG_OPTION_USE_WARPER]: Synchronize with `aflatin.c'.
1364
Werner Lemberg5cd21552015-04-10 07:01:01 +020013652015-04-10 Werner Lemberg <wl@gnu.org>
1366
1367 [cff] Update advance width handling to OpenType 1.7.
1368
1369 Problem reported by Behdad.
1370
1371 * src/cff/cffdrivr.c (cff_get_advances): Handle SFNT case
1372 separately.
1373
1374 * src/cff/cffgload.c (cff_slot_load): Use advance width and side
1375 bearing values from `hmtx' table if present.
1376
Alexei Podtelezhnikov67b912d2015-04-03 22:38:11 -040013772015-04-03 Alexei Podtelezhnikov <apodtele@gmail.com>
1378
1379 * src/autofit/afhints.c (af_glyph_hints_reload): Use do-while loop.
1380
Alexei Podtelezhnikov770b5d02015-04-02 23:15:36 -040013812015-04-02 Alexei Podtelezhnikov <apodtele@gmail.com>
1382
1383 * src/autofit/aflatin.c (af_latin_hint_edges): Reduce logic.
1384
13852015-04-01 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov886f4d02015-04-01 22:57:43 -04001386
1387 [autofit] Finish the thought.
1388
1389 * src/autofit/afhints.c (af_direction_compute): make sure the long arm
1390 is never negative so that its `FT_ABS' is not necessary.
1391
Werner Lemberg16217e52015-04-01 13:13:56 +020013922015-04-01 Werner Lemberg <wl@gnu.org>
1393
Werner Lemberga2fa6572015-04-01 15:55:41 +02001394 [autofit] Call dumper functions for tracing.
1395
1396 * src/autofit/afcjk.c (af_cjk_hints_apply): Remove dead code.
1397 * src/autofit/afhints.c (af_glyph_hints_dump_points): Minor
1398 improvement.
1399 * src/autofit/afmodule.c (af_autofitter_load_glyph): Implement it.
1400
14012015-04-01 Werner Lemberg <wl@gnu.org>
1402
Werner Lembergdb8df792015-04-01 13:30:55 +02001403 [autofit] Make debugging stuff work again.
1404
1405 The interface to ftgrid was broken in the series of commits starting
1406 with
1407
1408 [autofit] Allocate AF_Loader on the stack instead of AF_Module.
1409
1410 from 2015-01-14.
1411
1412 * src/autofit/afmodule.c (_af_debug_hints_rec) [FT_DEBUG_AUTOFIT]:
1413 Use a global AF_GlyphHintsRec object for debugging.
1414 (af_autofitter_done, af_autofitter_load_glyph): Updated.
1415
1416 * src/autofit/afloader.c (af_loader_init, af_loader_done): Updated.
1417
14182015-04-01 Werner Lemberg <wl@gnu.org>
1419
Werner Lemberg16217e52015-04-01 13:13:56 +02001420 * src/autofit/afhints.c (af_glyph_hints_done): Fix minor thinko.
1421
Werner Lemberg10e2bb82015-03-29 13:32:47 +020014222015-03-29 Werner Lemberg <wl@gnu.org>
1423
Werner Lembergf353a382015-03-29 14:47:49 +02001424 [cff] Fix Savannah bug #44629.
1425
1426 * src/cff/cf2font.h (CF2_MAX_SUBR), src/cff/cffgload.h
1427 (CFF_MAX_SUBRS_CALLS): Set to 16.
1428
14292015-03-29 Werner Lemberg <wl@gnu.org>
1430
Werner Lemberg10e2bb82015-03-29 13:32:47 +02001431 [type1, truetype] Make the MM API more flexible w.r.t. `num_coords'.
1432
1433 This commit allows `num_coords' to be larger or smaller than the
1434 number of available axes while selecting a design instance, either
1435 ignoring excess data or using defaults if data is missing.
1436
1437 * src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design):
1438 Implement it.
1439
1440 * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design,
1441 T1_Set_Var_Design): Ditto.
1442
14432015-03-29 Werner Lemberg <wl@gnu.org>
Werner Lemberg8ce30262015-03-27 08:33:47 +01001444
Werner Lembergdd5d6d72015-03-29 10:04:22 +02001445 [type1] Minor.
1446
1447 * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design): Use
1448 FT_THROW.
1449 (T1_Set_Var_Design): Use T1_MAX_MM_AXIS and FT_THROW.
1450
14512015-03-27 Werner Lemberg <wl@gnu.org>
1452
Werner Lemberg8ce30262015-03-27 08:33:47 +01001453 [cff] Trace charstring nesting levels.
1454
1455 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdCALLGSUBR,
1456 cf2_cmdCALLSUBR, cf2_cmdRETURN>: Implement it.
1457
1458 * src/cff/cffgload.c (cff_decoder_parse_charstrings)
1459 <cff_op_callsubr, cff_op_callgsubr, cff_op_return>: Ditto.
1460
Alexei Podtelezhnikovdac56442015-03-21 23:30:16 -040014612015-03-21 Alexei Podtelezhnikov <apodtele@gmail.com>
1462
1463 [base] Optimize `FT_Angle_Diff'.
1464
1465 Under normal circumstances we are usually close to the desired range
1466 of angle values, so that the remainder is not really necessary.
1467
1468 * src/base/fttrigon.c (FT_Angle_Diff): Use loops instead of remainder.
1469
1470 * src/autofit/aftypes.h (AF_ANGLE_DIFF): Ditto in the unused macro.
1471
Werner Lemberg6cc425d2015-03-21 06:51:07 +010014722015-03-21 Werner Lemberg <wl@gnu.org>
1473
1474 [truetype] Improve `gvar' handling.
1475
1476 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Correctly handle
1477 single-element runs. Cf. glyph `Q' in Skia.ttf with weights larger
1478 than the default.
1479
Alexei Podtelezhnikov2d7284e2015-03-20 21:34:19 -040014802015-03-20 Alexei Podtelezhnikov <apodtele@gmail.com>
1481
1482 * src/base/fttrigon.c (FT_Vector_Rotate): Minor refactoring.
1483
Alexei Podtelezhnikov6a171722015-03-17 22:43:08 -040014842015-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
1485
1486 Fix Savannah bug #44412 (part 2).
1487
1488 * src/base/fttrigon.c (FT_Sin, FT_Cos, FT_Tan): Call `FT_Vector_Unit'.
1489
Werner Lemberg06339952015-03-11 06:30:23 +010014902015-03-11 Werner Lemberg <wl@gnu.org>
1491
Werner Lembergd3284462015-03-11 16:45:58 +01001492 [autofit] Add support for Arabic script.
1493
1494 Thanks to Titus Nemeth <tn@tntypography.eu> for guidance!
1495
1496 * src/autofit/afblue.dat: Add blue zone data for Arabic.
1497
1498 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
1499
1500 * src/autofit/afscript.h: Add Arabic standard characters.
1501
1502 * src/autofit/afranges.c: Add Arabic data.
1503
1504 * src/autofit/afstyles.h: Add Arabic data.
1505
1506 * docs/CHANGES: Document it.
1507
15082015-03-11 Werner Lemberg <wl@gnu.org>
1509
Werner Lemberga4516382015-03-11 08:09:13 +01001510 Rename `svxf86nm.h' to `svfntfmt.h'; update related symbols.
1511
1512 * include/internal/ftserv.h (FT_SERVICE_XFREE86_NAME_H): Renamed
1513 to...
1514 (FT_SERVICE_FONT_FORMAT_H): This.
1515
1516 * include/internal/services/svfntfmt.h (FT_XF86_FORMAT_*): Renamed
1517 to ...
1518 (FT_FONT_FORMAT_*): This.
1519
1520 src/base/ftfntfmt.c, src/bdf/bdfdrivr.c, src/cff/cffdrivr.c,
1521 src/cid/cidriver.c, src/pcf/pcfdrivr.c, src/pfr/pfrdrivr.c,
1522 src/truetype/ttdriver.c, src/type1/t1driver.c,
1523 src/type42/t42drivr.c, src/winfonts/winfnt.c: Updated.
1524
15252015-03-11 Werner Lemberg <wl@gnu.org>
1526
Werner Lembergdd7028c2015-03-11 07:45:05 +01001527 [base] Rename `FT_XFREE86_H' to `FT_FONT_FORMATS_H'.
1528
1529 * include/config/ftheader.h: Implement it.
1530 * src/base/ftfntfmt.c, docs/CHANGES: Updated.
1531
15322015-03-11 Werner Lemberg <wl@gnu.org>
1533
Werner Lembergf4d1c112015-03-11 07:32:58 +01001534 [base] Rename `FT_Get_X11_Font_Format' to `FT_Get_Font_Format'.
1535
1536 * include/ftfntfmt.h, src/base/ftfntfmt.c: Implement it.
1537
1538 * docs/CHANGES: Updated.
1539
15402015-03-11 Werner Lemberg <wl@gnu.org>
1541
Werner Lembergcb0f7b62015-03-11 06:51:27 +01001542 Fix automatic copyright updating.
1543
1544 * src/tools/update-copyright: Make scanning of `no-copyright'
1545 actually work.
1546
1547 * src/tools/no-copyright: Don't include README in general.
1548
15492015-03-11 Werner Lemberg <wl@gnu.org>
1550
Werner Lemberg06339952015-03-11 06:30:23 +01001551 Rename `ftxf86.[ch]' to `ftfntfmt.[ch]'.
1552
1553 CMakeLists.txt, builds/amiga/makefile, builds/amiga/makefile.os4,
1554 builds/amiga/smakefile, builds/mac/FreeType.m68k_cfm.make.txt,
1555 builds/mac/FreeType.m68k_far.make.txt,
1556 builds/mac/FreeType.ppc_carbon.make.txt,
1557 builds/mac/FreeType.ppc_classic.make.txt, builds/symbian/bld.inf,
1558 builds/symbian/freetype.mmp, builds/wince/vc2005-ce/freetype.vcproj,
1559 builds/wince/vc2008-ce/freetype.vcproj,
1560 builds/windows/vc2005/freetype.vcproj,
1561 builds/windows/vc2008/freetype.vcproj,
1562 builds/windows/vc2010/freetype.vcxproj,
1563 builds/windows/vc2010/freetype.vcxproj.filters,
1564 builds/windows/visualc/freetype.dsp,
1565 builds/windows/visualc/freetype.vcproj,
1566 builds/windows/visualce/freetype.dsp,
1567 builds/windows/visualce/freetype.vcproj, docs/INSTALL.ANY,
1568 include/config/ftheader.h, include/ftfntfmt.h, modules.cfg,
1569 src/base/ftfntfmt.c, vms_make.com: Updated.
1570
Alexei Podtelezhnikov6b832c82015-03-10 23:25:49 -040015712015-03-10 Alexei Podtelezhnikov <apodtele@gmail.com>
1572
1573 Fix Savannah bug #44412 (part 1).
1574
1575 * src/base/ftstroke.c (ft_stroker_inside): Handle near U-turns.
1576
Werner Lembergeee7d8b2015-03-10 11:15:15 +010015772015-03-10 Werner Lemberg <wl@gnu.org>
1578
1579 [base] Rename `FT_Bitmap_New' to `FT_Bitmap_Init'.
1580
1581 * include/ftbitmap.h, src/base/ftbitmap.c: Implement it.
1582 Update all callers.
1583
1584 * docs/CHANGES: Updated.
1585
Werner Lemberg493cc032015-03-06 05:38:31 +010015862015-03-06 Werner Lemberg <wl@gnu.org>
1587
1588 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix compiler warning.
1589
1590 Found by Alexei.
1591
Alexei Podtelezhnikovdd7498d2015-03-05 22:51:36 -050015922015-03-05 Alexei Podtelezhnikov <apodtele@gmail.com>
1593
1594 * src/base/ftstroke.c: Simplify.
1595
Werner Lemberg328b7922015-03-04 08:40:23 +010015962015-03-04 Werner Lemberg <wl@gnu.org>
1597
1598 [truetype] Some fixes and code refactoring in `ttgxvar.c'.
1599
1600 * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Fix return value
1601 of `point_cnt' if two bytes are read.
1602 Use a more vertical coding style.
1603 (ft_var_readpackeddeltas): Use FT_UInt for `delta_cnt' parameter.
1604 Use a more vertical coding style.
1605
Werner Lemberga374c9c2015-03-03 11:23:45 +010016062015-03-03 Werner Lemberg <wl@gnu.org>
1607
1608 [autofit] Fix Savannah bug #44241.
1609
1610 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Reject glyphs
1611 with less than 3 points.
1612
Werner Lemberga07029e2015-03-02 06:54:08 +010016132015-03-02 Werner Lemberg <wl@gnu.org>
1614
1615 Simplify `TYPEOF' macro.
1616
1617 No need for two arguments.
1618
1619 * include/config/ftconfig.h, builds/unix/ftconfig.in,
1620 builds/vms/ftconfig.h (TYPEOF): Updated.
1621
1622 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
1623 src/autofit/afwarp.h (AF_WARPER_FLOOR): Updated.
1624
16252015-03-01 Werner Lemberg <wl@gnu.org>
Werner Lemberg4b9234b2015-02-25 06:31:43 +01001626
Werner Lemberg851e8152015-03-01 19:27:09 +01001627 Various compiler warning fixes for `make multi'.
1628
1629 * src/autofit/afcjk.c (af_cjk_hints_compute_blue_edges),
1630 src/autofit/aflatin.c (af_latin_hint_compute_blue_edges,
1631 af_latin_hint_edges), src/autofit/aflatin2.c
1632 (af_latin2_hints_compute_blue_edges, af_latin2_hint_edges): Declare
1633 as `static'.
1634
1635 * src/cache/ftccmap.c (FTC_CMAP_QUERY_HASH, FTC_CMAP_NODE_HASH):
1636 Removed. Unused.
1637 * src/cache/ftcimage.c: Include FT_INTERNAL_OBJECTS_H.
1638 * src/cache/ftcmanag.c (FTC_LRU_GET_MANAGER): Removed. Unused.
1639
1640 * src/cff/cf2intrp.c: Include `cf2intrp.h'.
1641 * src/cff/cffdrivr.c (PAIR_TAG): Removed. Unused.
1642
1643 * src/gzip/ftgzip.c (NO_DUMMY_DECL): Removed. Unused.
1644
1645 * src/psaux/afmparse.c (afm_parser_read_int): Declare as `static'.
1646
1647 * src/pshinter/pshalgo.c (STRONGER, PSH_ZONE_MIN, PSH_ZONE_MAX):
1648 Removed. Unused.
1649
1650 * src/raster/ftraster.c (Render_Glyph): Declare as `static'.
1651
1652 * src/sfnt/ttpost.c (load_format_20): Fix signedness warning.
1653
1654 * src/truetype/ttdriver.c (PAIR_TAG): Removed. Unused.
1655 * src/truetype/ttsubpix.c (is_member_of_family_class,
1656 is_member_of_style_class): Declare as `static'.
1657
1658 * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Declare
1659 as `static'.
1660 * src/type1/t1load.c (mm_axis_unmap, mm_weights_unmap): Declare as
1661 `static'.
1662 (T1_FIELD_COUNT): Removed. Unused.
1663 * src/type1/t1parse.h (T1_Done_Table): Removed. Unused.
1664
1665 * src/type42/t42parse.c (T1_Done_Table): Removed. Unused.
1666
16672015-02-25 Werner Lemberg <wl@gnu.org>
1668
Werner Lemberg04c22372015-02-25 11:20:20 +01001669 [psaux] Signedness fixes.
1670
1671 * include/internal/psaux.h, src/psaux/afmparse.c,
1672 src/psaux/afmparse.h, src/psaux/psconv.c, src/psaux/psobjs.c,
1673 src/psaux/t1cmap.c, src/psaux/t1decode.c: Apply.
1674
16752015-02-25 Werner Lemberg <wl@gnu.org>
1676
Werner Lembergd25ec162015-02-25 09:19:59 +01001677 [otvalid] Signedness fixes.
1678
1679 * src/otvalid/otvcommn.c, src/otvalid/otvgdef.c,
1680 src/otvalid/otvgpos.c, src/otvalid/otvgsub.c, src/otvalid/otvmath.c:
1681 Apply.
1682
16832015-02-25 Werner Lemberg <wl@gnu.org>
1684
Werner Lemberg5c9d9bf2015-02-25 08:13:40 +01001685 * src/bzip2/ftbzip2.c (ft_bzip2_alloc): Signedness fix.
1686
16872015-02-25 Werner Lemberg <wl@gnu.org>
1688
Werner Lemberg83d41812015-02-25 08:10:58 +01001689 [lzw] Signedness fixes.
1690
1691 * src/lzw/ftzopen.c, src/lzw/ftzopen.h: Apply.
1692
16932015-02-25 Werner Lemberg <wl@gnu.org>
1694
Werner Lemberg17b62912015-02-25 07:53:09 +01001695 [gxvalid] Signedness fixes.
1696
1697 * src/gxvalid/gxvbsln.c, src/gxvalid/gxvcommn.c,
1698 src/gxvalid/gxvcommn.h, src/gxvalid/gxvjust.c,
1699 src/gxvalid/gxvkern.c, src/gxvalid/gxvlcar.c, src/gxvalid/gxvmort.c,
1700 src/gxvalid/gxvmort1.c, src/gxvalid/gxvmort2.c,
1701 src/gxvalid/gxvmorx.c, src/gxvalid/gxvmorx1.c,
1702 src/gxvalid/gxvmorx2.c, src/gxvalid/gxvopbd.c,
1703 src/gxvalid/gxvprop.c, src/gxvalid/gxvtrak.c: Apply.
1704
17052015-02-25 Werner Lemberg <wl@gnu.org>
1706
Werner Lemberg24e4e962015-02-25 06:57:16 +01001707 [cache] Signedness fixes.
1708
1709 * src/cache/ftcbasic.c, src/cache/ftccmap.c, src/cache/ftcimage.c,
1710 src/cache/ftcmanag.c, src/cache/ftcsbits.c: Apply.
1711
17122015-02-25 Werner Lemberg <wl@gnu.org>
1713
Werner Lemberg559727d2015-02-25 06:55:00 +01001714 Change dimension fields in `FTC_ImageTypeRec' to unsigned type.
1715
1716 This doesn't break ABI.
1717
1718 * include/ftcache.h (FTC_ImageTypeRec): Use unsigned types for
1719 `width' and `height'.
1720
1721 * docs/CHANGES: Document it.
1722
17232015-02-25 Werner Lemberg <wl@gnu.org>
1724
Werner Lemberg4b9234b2015-02-25 06:31:43 +01001725 [cache] Don't use `labs'.
1726
1727 This is the only place in FreeType where this function was used.
1728
1729 * include/config/ftstdlib.h (ft_labs): Remove.
1730
1731 * src/cache/ftcimage.c (ftc_inode_weight): Replace `ft_labs' with
1732 `FT_ABS'.
1733
Werner Lemberg4d1f7af2015-02-23 07:04:36 +010017342015-02-23 Werner Lemberg <wl@gnu.org>
1735
Werner Lemberg3aaebe32015-02-23 08:20:27 +01001736 [cache] Replace `FT_PtrDist' with `FT_Offset'.
1737
1738 * src/cache/ftccache.h (FTC_NodeRec): `FT_Offset' (a.k.a. `size_t')
1739 is a better choice for `hash' to hold a pointer than `FT_PtrDist'
1740 (a.k.a. `ptrdiff_t'), especially since the latter is signed,
1741 causing zillions of signedness warnings. [Note that `hash' was of
Werner Lemberg17b62912015-02-25 07:53:09 +01001742 type `FT_UInt32' before the change to `FT_PtrDist'.]
Werner Lemberg3aaebe32015-02-23 08:20:27 +01001743 Update all users.
1744
1745 * src/cache/ftcbasic.c, src/cache/ftccache.c, src/cache/ftccmap.c,
1746 src/cache/ftcglyph.c, src/cache/ftcglyph.h: Updated.
1747
17482015-02-23 Werner Lemberg <wl@gnu.org>
1749
Werner Lemberg4d1f7af2015-02-23 07:04:36 +01001750 [smooth, raster] Re-enable standalone compilation.
1751
1752 * src/raster/ftraster.c (FT_RENDER_POOL_SIZE, FT_MAX)
1753 [_STANDALONE_]: Define macros.
1754
1755 * src/smooth/ftgrays.c (FT_RENDER_POOL_SIZE, FT_MAX, FT_ABS,
1756 FT_HYPOT) [_STANDALONE_]: Define macros.
1757
Werner Lemberg03ccfd02015-02-22 08:25:16 +010017582015-02-22 Werner Lemberg <wl@gnu.org>
1759
Werner Lembergcb13e712015-02-23 06:41:52 +01001760 [smooth] Signedness fixes.
1761
1762 * src/smooth/ftgrays.c, src/smooth/ftsmooth.c: Apply.
1763
17642015-02-22 Werner Lemberg <wl@gnu.org>
1765
Werner Lemberga974e9a2015-02-22 21:02:13 +01001766 * src/raster/ftraster.c: Use the file's typedefs everywhere.
1767
17682015-02-22 Werner Lemberg <wl@gnu.org>
1769
Werner Lembergb0ebcdc2015-02-22 20:42:49 +01001770 * src/sfnt/ttpost.c (load_format_20): Fix error tracing message.
1771
1772 Bug introduced 6 commits earlier.
1773
17742015-02-22 Werner Lemberg <wl@gnu.org>
1775
Werner Lemberg22b1d5c2015-02-22 20:41:03 +01001776 [pshinter] Fix thinko.
1777
1778 * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Correctly
1779 check `count'.
1780 Bug introduced two commits earlier.
1781
17822015-02-22 Werner Lemberg <wl@gnu.org>
1783
Werner Lembergca96fe02015-02-22 20:05:04 +01001784 [raster] Signedness fixes.
1785
1786 * src/raster/ftraster.c, src/raster/ftrend1.c: Apply.
1787
17882015-02-22 Werner Lemberg <wl@gnu.org>
1789
Werner Lemberg452066c2015-02-22 15:59:02 +01001790 [pshinter] Signedness fixes.
1791
1792 * src/pshinter/pshalgo.c, src/pshinter/pshglob.c,
1793 src/pshinter/pshrec.c: Apply.
1794
17952015-02-22 Werner Lemberg <wl@gnu.org>
1796
Werner Lemberg41c2ed82015-02-22 15:57:47 +01001797 [pshinter] Use macros for (unsigned) flags, not enumerations.
1798
1799 * src/pshinter/pshalgo.h (PSH_Hint_Flags): Replace with macros.
1800 Updated.
1801 * src/pshinter/pshrec.h (PS_Hint_Flags): Replace with macros.
1802
18032015-02-22 Werner Lemberg <wl@gnu.org>
1804
Werner Lemberg25c2f882015-02-22 15:54:31 +01001805 * src/pshinter/pshrec.c: Simplify.
1806 (ps_hints_open, ps_hints_stem): Remove switch statement.
1807
18082015-02-22 Werner Lemberg <wl@gnu.org>
1809
Werner Lemberg01f08422015-02-22 12:03:28 +01001810 [sfnt] Signedness fixes.
1811
1812 * src/sfnt/pngshim.c, src/sfnt/sfobjs.c, src/sfnt/ttcmap.c,
1813 src/sfnt/ttkern.c, src/sfnt/ttload.c, src/sfnt/ttpost.c,
1814 src/sfnt/ttsbit.c: Apply.
1815 * src/sfnt/sfdriver.c: Apply.
1816 (sfnt_get_ps_name): Simplify.
1817
18182015-02-22 Werner Lemberg <wl@gnu.org>
1819
Werner Lemberg3c374c82015-02-22 09:16:53 +01001820 [bdf] Signedness fixes.
1821
1822 * src/bdf/bdf.h, src/bdf/bdfdrivr.c, src/bdf/bdfdrivr.h,
1823 src/bdf/bdflib.c: Apply.
1824
18252015-02-22 Werner Lemberg <wl@gnu.org>
1826
Werner Lembergb13945a2015-02-22 09:15:47 +01001827 * src/bdf/bdflib.c (_bdf_atous): New function.
1828 (_bdf_parse_glyphs, _bdf_parse_start): Use it.
1829
18302015-02-22 Werner Lemberg <wl@gnu.org>
1831
Werner Lemberg03ccfd02015-02-22 08:25:16 +01001832 [pcf] Signedness fixes.
1833
1834 * src/pcf/pcf.h, src/pcf/pcfdrivr.c: Apply.
1835 * src/pcf/pcfread.c: Apply.
1836 (pcf_get_encodings): Ignore invalid negative encoding offsets.
1837
Werner Lemberg633a7292015-02-21 07:02:01 +010018382015-02-21 Werner Lemberg <wl@gnu.org>
1839
Werner Lemberg3d7e53f2015-02-21 11:30:54 +01001840 * src/winfonts/winfnt.c: Signedness fixes.
1841
18422015-02-21 Werner Lemberg <wl@gnu.org>
1843
Werner Lemberg7b6b4172015-02-21 10:39:34 +01001844 [type42] Signedness fixes.
1845
1846 * src/type42/t42parse.c, src/type42/t42parse.h,
1847 src/type42/t42types.h: Apply.
1848
18492015-02-21 Werner Lemberg <wl@gnu.org>
1850
Werner Lemberg8bfffb42015-02-21 09:52:29 +01001851 [pfr] Signedness fixes.
1852
1853 * src/pfr/pfrdrivr.c, src/pfr/pfrgload.c, src/pfr/pfrload.c,
1854 src/pfr/pfrload.h, src/pfr/pfrobjs.c, src/pfr/pfrsbit.c,
1855 src/pfr/pfrtypes.h: Apply.
1856
18572015-02-21 Werner Lemberg <wl@gnu.org>
1858
Werner Lemberg633a7292015-02-21 07:02:01 +01001859 [cff] Minor signedness fixes related to last commit.
1860
1861 * src/cff/cf2ft.c, src/cff/cf2intrp.c, src/cff/cffgload.c: Apply.
1862
Werner Lemberg3a8d0532015-02-20 08:35:32 +010018632015-02-20 Werner Lemberg <wl@gnu.org>
1864
Werner Lembergc00b05f2015-02-20 20:42:55 +01001865 [cff] Thinkos in bias handling.
1866
1867 Only the final result is always positive.
1868
1869 Bug introduced three commits earlier.
1870
1871 * src/cff/cffgload.c, src/cff/cffgload.h: Apply.
1872
18732015-02-20 Werner Lemberg <wl@gnu.org>
1874
Werner Lemberg2bf03eb2015-02-20 20:14:11 +01001875 [cid] Fix signedness issues and emit some better error codes.
1876
1877 * src/cid/cidgload.c, src/cid/cidload.h, src/cid/cidobjs.c,
1878 src/cid/cidparse.h: Apply.
1879 * src/cid/cidload.c: Apply.
1880 (parse_fd_array): Reject negative values for number of dictionaries.
1881 * src/cid/cidparse.c: Apply.
1882 (cid_parser_new): Reject negative values for hex data length.
1883
18842015-02-20 Werner Lemberg <wl@gnu.org>
1885
Werner Lembergeb05bfb2015-02-20 08:37:35 +01001886 [cff] Signedness fixes for new engine.
1887
1888 * src/cff/cf2arrst.c, src/cff/cf2fixed.h, src/cff/cf2ft.c,
1889 src/cff/cf2ft.h, src/cff/cf2hints.c, src/cff/cf2intrp.c: Apply.
1890
18912015-02-20 Werner Lemberg <wl@gnu.org>
1892
Werner Lemberg3a8d0532015-02-20 08:35:32 +01001893 [cff] Signedness fixes for basic infrastructure and old engine.
1894
1895 * include/internal/pshints.h, src/cff/cffdrivr.c,
1896 src/cff/cffgload.c, src/cff/cffgload.h, src/cff/cffload.c,
1897 src/cff/cffobjs.c, src/cff/cffparse.c, src/pshinter/pshrec.c: Apply.
1898
Werner Lemberg81e5ff52015-02-19 09:46:48 +010018992015-02-19 Werner Lemberg <wl@gnu.org>
1900
Werner Lemberg3a1df3e2015-02-19 15:42:48 +01001901 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Ignore `countSizePairs'.
1902
1903 This is hard-coded to value 2 in `fvar' version 1.0 (and no newer
1904 version exists), but some fonts set it incorrectly.
1905
1906 Problem reported by Adam Twardoch <adam@fontlab.com>.
1907
19082015-02-19 Werner Lemberg <wl@gnu.org>
1909
Werner Lemberg93a884c2015-02-19 14:11:16 +01001910 [cff] Emit better error code for invalid private dict size.
1911
1912 * src/cff/cffparse.c (cff_parse_private_dict): Reject negative
1913 values for size and offset.
1914
19152015-02-19 Werner Lemberg <wl@gnu.org>
1916
Werner Lembergb57bb112015-02-19 10:44:18 +01001917 [autofit] Fix signedness issues.
1918
1919 * src/autofit/afangles.c, src/autofit/afcjk.c,
1920 src/autofit/afglobal.c, src/autofit/afhints.c,
1921 src/autofit/aflatin.c, src/autofit/aflatin2.c, src/autofit/afwarp.c,
1922 src/autofit/hbshim.c: Apply.
1923
19242015-02-19 Werner Lemberg <wl@gnu.org>
1925
Werner Lemberg81e5ff52015-02-19 09:46:48 +01001926 [autofit] Use macros for (unsigned) flags, not enumerations.
1927
1928 This harmonizes with other code in FreeType (and reduces the number
1929 of necessary casts to avoid compiler warnings).
1930
1931 * src/autofit/afblue.hin: Make flag macros unsigned.
1932 * src/autofit/afblue.h: Regenerated.
1933
1934 * src/autofit/afcjk.h: Replace flag enumeration with macros.
1935 * src/autofit/afcjk.c: Updated.
1936
1937 * src/autofit/afhints.h (AF_Flags, AF_Edge_Flags): Replace with
1938 macros.
1939 * src/autofit/afhints.c: Updated.
1940
1941 * src/autofit/aflatin.h: Replace flag enumerations with macros.
1942 * src/autofit/aflatin.c, src/autofit/aflatin2.c: Updated.
1943
1944 * src/autofit/aftypes.h (AF_ScalerFlags): Replace with macros.
1945
Werner Lemberg6a0ded72015-02-18 08:51:22 +010019462015-02-18 Werner Lemberg <wl@gnu.org>
1947
Werner Lemberg3b5f3322015-02-18 11:45:22 +01001948 [type1] Fix signedness issues.
1949
1950 * include/internal/psaux.h, include/internal/t1types.h,
1951 src/psaux/psobjs.c, src/psaux/psobjs.h, src/psaux/t1decode.c,
1952 src/type1/t1gload.c, src/type1/t1load.c, src/type1/t1parse.c: Apply.
1953
19542015-02-18 Werner Lemberg <wl@gnu.org>
1955
Werner Lemberg272e3cd2015-02-18 11:38:46 +01001956 [psaux, type1] Fix minor AFM issues.
1957
1958 * include/internal/t1types.h (AFM_KernPairRec): Make indices
1959 unsigned.
1960 Update users.
1961 (AFM_FontInfoRec): Make element counters unsigned.
1962 Update users.
1963 * src/psaux/afmparse.h (AFM_ValueRec): Add union member for unsigned
1964 int.
1965
1966 * src/psaux/afmparse.c (afm_parse_track_kern, afm_parse_kern_pairs):
1967 Reject negative values for number of kerning elements.
1968
1969 * src/type1/t1afm.c, src/tools/test_afm.c: Updated.
1970
19712015-02-18 Werner Lemberg <wl@gnu.org>
1972
Werner Lemberg6bd7d282015-02-18 09:22:06 +01001973 Don't use `FT_PtrDist' for lengths.
1974
1975 Use FT_UInt instead.
1976
1977 * include/internal/psaux.h (PS_Table_FuncsRec, PS_TableRec,
1978 T1_DecoderRec): Do it.
1979
1980 * include/internal/t1types.h (T1_FontRec): Ditto.
1981
1982 * src/cid/cidload.c (cid_parse_dict): Updated.
1983 * src/pfr/pfrload.c (pfr_extra_item_load_font_id): Ditto.
1984 * src/psaux/psobjs.c (ps_table_add), src/psaux/psobjs.h: Ditto.
1985 * src/type1/t1load.c (parse_blend_axis_types, parse_encoding,
1986 parse_chharstrings, parse_dict): Ditto.
1987 * src/type42/t42parse.c (t42_parse_encoding, t42_parse_charstrings,
1988 t42_parse_dict): Ditto.
1989
19902015-02-18 Werner Lemberg <wl@gnu.org>
1991
Werner Lemberg6a0ded72015-02-18 08:51:22 +01001992 * src/type1/t1driver.c (t1_ps_get_font_value): Clean up.
1993 This handles negative values better, avoiding many casts.
1994
Werner Lemberg0a33a392015-02-17 08:03:05 +010019952015-02-17 Werner Lemberg <wl@gnu.org>
1996
Werner Lembergd3240c52015-02-17 20:30:36 +01001997 [base] Fix Savannah bug #44284.
1998
1999 * src/base/ftcalc.c (FT_MulFix): Typos.
2000
20012015-02-17 Werner Lemberg <wl@gnu.org>
2002
Werner Lemberg1f7a4e12015-02-17 10:17:56 +01002003 [truetype] Finish compiler warning fixes for signedness issues.
2004
2005 * src/truetype/ttgxvar.c, src/truetype/ttsubpix.c,
2006 src/truetype/ttsubpix.h: Apply.
2007
20082015-02-17 Werner Lemberg <wl@gnu.org>
2009
Werner Lemberg9daea2c2015-02-17 09:27:56 +01002010 * src/truetype/ttsubpix.c: Adding missing `static' keywords.
2011
20122015-02-17 Werner Lemberg <wl@gnu.org>
2013
Werner Lembergd9c3f152015-02-17 09:21:26 +01002014 [truetype] More signedness fixes.
2015
2016 * include/internal/tttypes.h, src/truetype/ttinterp.h,
2017 src/truetype/ttobjs.h, src/truetype/ttinterp.c,
2018 src/truetype/ttobjs.c: Apply.
2019
20202015-02-17 Werner Lemberg <wl@gnu.org>
2021
Werner Lemberg0a33a392015-02-17 08:03:05 +01002022 [truetype] Various signedness fixes.
2023
2024 * include/internal/ftgloadr.h, src/truetype/ttpload.c: Apply.
2025
2026 * src/truetype/ttgload.c: Apply.
2027 (TT_Get_VMetrics): Protect against invalid ascenders and descenders
2028 while constructing advance height.
2029
Werner Lemberg587351b2015-02-16 07:03:22 +010020302015-02-16 Werner Lemberg <wl@gnu.org>
2031
Werner Lemberg76abc752015-02-16 22:00:27 +01002032 [base] Finish compiler warning fixes for signedness issues.
2033
2034 * src/base/ftglyph.c, src/base/ftlcdfil.c, src/base/ftstroke.c:
2035 Apply.
2036
20372015-02-16 Werner Lemberg <wl@gnu.org>
2038
Werner Lemberg10aa8582015-02-16 20:12:54 +01002039 * include/tttables.h (TT_OS2): `fsType' must be FT_UShort.
2040
20412015-02-16 Werner Lemberg <wl@gnu.org>
2042
Werner Lemberg2e814fc2015-02-16 20:05:08 +01002043 More minor signedness warning fixes.
2044
2045 * src/base/ftbbox.c, src/base/ftbitmap.c, src/base/fttrigon.c,
2046 src/base/ftutil.c: Apply.
2047
20482015-02-16 Werner Lemberg <wl@gnu.org>
2049
Werner Lemberg82235d02015-02-16 19:35:16 +01002050 Next round of minor compiler warning fixes.
2051
2052 * include/internal/ftrfork.h (FT_RFork_Ref): Change `offset' member
2053 type to `FT_Long'.
2054 (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Add `static' keyword.
2055
Werner Lemberg3aaebe32015-02-23 08:20:27 +01002056 * include/internal/ftstream.h (FT_Stream_Pos): Return `FT_ULong'.
Werner Lemberg82235d02015-02-16 19:35:16 +01002057
2058 * src/base/ftoutln.c, src/base/ftrfork.c, src/base/ftstream.c:
2059 Signedess fixes.
2060
20612015-02-16 Werner Lemberg <wl@gnu.org>
2062
Werner Lemberg3cfa4d12015-02-16 17:59:06 +01002063 Various minor signedness fixes.
2064
2065 * include/ftadvanc.h, include/internal/ftobjs.h,
2066 src/base/ftgloadr.c, src/base/ftobjs.c: Apply.
2067
20682015-02-16 Werner Lemberg <wl@gnu.org>
2069
Werner Lemberg6f325c22015-02-16 11:31:32 +01002070 New `TYPEOF' macro.
2071
2072 This helps suppress signedness warnings, avoiding issues with
2073 implicit conversion changes.
2074
2075 * include/config/ftconfig.h, builds/unix/ftconfig.in,
2076 builds/vms/ftconfig.h (TYPEOF): Define.
2077
2078 * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
2079 src/autofit/afwarp.h (AF_WARPER_FLOOR): Use it.
2080
20812015-02-16 Werner Lemberg <wl@gnu.org>
2082
Werner Lemberg1f377f02015-02-16 08:37:09 +01002083 * src/base/ftsystem.c: Use casts in standard C function wrappers.
2084 (ft_alloc, ft_realloc, ft_ansi_stream_io, FT_Stream_Open): Do it.
2085
20862015-02-16 Werner Lemberg <wl@gnu.org>
2087
Werner Lemberg0814b802015-02-16 07:29:53 +01002088 Fix Savannah bug #44261.
2089
2090 * builds/unix/detect.mk (setup) [unix]: Set `CONFIG_SHELL' in the
2091 environment also while calling the configure script.
2092
20932015-02-16 Werner Lemberg <wl@gnu.org>
2094
Werner Lemberg587351b2015-02-16 07:03:22 +01002095 * include/internal/ftmemory.h: Add some `FT_Offset' casts.
2096 (FT_MEM_SET, FT_MEM_COPY, FT_MEM_MOVE, FT_ARRAY_ZERO, FT_ARRAY_COPY,
2097 FT_MEM_MOVE): Do it.
2098
Werner Lemberg6d7d6362015-02-15 12:30:42 +010020992015-02-15 Werner Lemberg <wl@gnu.org>
2100
Werner Lemberg48186b82015-02-16 06:37:36 +01002101 [base] Clean up signedness issues in `ftdbgmem.c'.
2102
2103 Also fix other minor issues.
2104
2105 * src/base/ftdbgmem.c (FT_MemTableRec): Replace all FT_ULong types
2106 with FT_Long for consistency.
2107 (ft_mem_primes): Change type to `FT_Int'.
2108 (ft_mem_closest_prime, ft_mem_table_set): Updated.
2109
2110 (ft_mem_debug_panic, ft_mem_debug_alloc, ft_mem_debug_free,
2111 ft_mem_debug_realloc): Use `static' keyword and fix signedness
2112 warnings where necessary.
2113
2114 (ft_mem_table_resize, ft_mem_table_new, ft_mem_table_destroy,
2115 ft_mem_table_get_nodep, ft_mem_debug_init, FT_DumpMemory): Fix types
2116 and add or remove casts to avoid signedness warnings.
2117
21182015-02-15 Werner Lemberg <wl@gnu.org>
2119
Werner Lemberg6d7d6362015-02-15 12:30:42 +01002120 [base] Clean up signedness in arithmetic functions.
2121
2122 This makes the code more readable and reduces compiler warnings.
2123
2124 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round, FT_MulFix,
2125 FT_DivFix): Convert input parameters to unsigned, do the
2126 computation, then convert the result back to signed.
2127 (ft_corner_orientation): Fix casts.
2128
Werner Lemberg92359bd2015-02-07 09:47:23 +010021292015-02-07 Werner Lemberg <wl@gnu.org>
2130
2131 [sfnt] Fix Savannah bug #44184.
2132
2133 * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir): No
2134 longer reject `htmx' and `vmtx' tables with invalid length but
2135 sanitize them.
2136
Jon Anderson416d8792015-02-06 10:16:45 +010021372015-02-06 Jon Anderson <jon@websupergoo.com>
2138
2139 [truetype] Fix regression in the incremental glyph loader.
2140
2141 * src/truetype/ttgload.c (load_truetype_glyph): For incremental
2142 fonts, the glyph index may be greater than the number of glyphs
2143 indicated, so guard the check with a preprocessor conditional.
2144
Werner Lembergb6cb4992015-02-06 08:46:06 +010021452015-02-06 Werner Lemberg <wl@gnu.org>
2146
2147 [autofit] Fix potential memory leak.
2148
2149 While this doesn't show up with FreeType, exactly the same code
2150 leaks with ttfautohint's modified auto-hinter code (which gets used
2151 in a slightly different way).
2152
2153 It certainly doesn't harm since it is similar to already existing
2154 checks in the code for embedded arrays.
2155
2156 * src/autofit/afhints.c (af_glyph_hints_reload): Set `max_contours'
2157 and `max_points' for all cases.
2158
Werner Lemberg19146a52015-01-31 11:01:33 +010021592015-01-31 Werner Lemberg <wl@gnu.org>
2160
2161 [autofit] Add support for Thai script.
2162
2163 Thanks to Ben Mitchell <ben@rosettatype.com> for guidance with blue
2164 zone characters!
2165
2166 * src/autofit/afblue.dat: Add blue zone data for Thai.
2167
2168 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
2169
2170 * src/autofit/afscript.h: Add Thai standard characters.
2171
2172 * src/autofit/afranges.c: Add Thai data.
2173
2174 * src/autofit/afstyles.h: Add Thai data.
2175
Behdad Esfahbod264b5e42015-01-23 21:23:55 +010021762015-01-23 Behdad Esfahbod <behdad@behdad.org>
2177
2178 [raster] Handle `FT_RASTER_FLAG_AA' correctly.
2179
2180 This fixes a breakage caused by the commit `[raster] Remove
2181 5-level gray AA mode from monochrome rasterizer.'.
2182
Werner Lembergd2c531e2015-01-23 22:37:42 +01002183 Problem reported by Markus Trippelsdorf <markus@trippelsdorf.de>.
Behdad Esfahbod264b5e42015-01-23 21:23:55 +01002184
2185 * src/raster/ftraster.c (ft_black_render): Handle
2186 `FT_RASTER_FLAG_AA'.
2187
2188 * src/raster/ftrend1.c (ft_raster1_render): Remove gray AA mode
2189 remnants.
2190
Werner Lemberg79a5ac62015-01-18 07:30:04 +010021912015-01-18 Werner Lemberg <wl@gnu.org>
2192
2193 * src/base/ftobjs.c (FT_New_Library): Fix compiler warning.
2194
Chris Liddell942aa5f2015-01-18 07:29:48 +010021952015-01-18 Chris Liddell <chris.liddell@artifex.com>
2196
2197 [raster] Fix Savannah bug #44022.
2198
2199 Add fallback for glyphs with degenerate bounding boxes.
2200
2201 If a glyph has only one very narrow feature, the bbox can end up
2202 with either the width or height of the bbox being 0, in which case
2203 no raster memory is allocated and no attempt is made to render the
2204 glyph. This is less than ideal when the drop-out compensation in
2205 the rendering code would actually result in the glyph being
2206 rendered.
2207
2208 This problem can be observed with the `I' glyph (gid 47) in the
2209 Autodesk RomanS TrueType font.
2210
2211 * src/raster/ftrend1.c (ft_raster1_render): Add a fallback if either
2212 dimension is zero to explicitly round up/down (instead of simply
2213 round).
2214
Werner Lemberg50be00d2015-01-17 20:38:31 +010022152015-01-17 Werner Lemberg <wl@gnu.org>
2216
2217 Add some tools to handle yearly copyright notice updates.
2218
2219 We are now following the GNU guidelines: A new release automatically
2220 means that the copyright year of all affected files gets updated; it
2221 is no longer used to track years of modification changes.
2222
2223 * src/tools/update-copyright-year: New Perl script.
2224 * src/tools/update-copyright: New shell script that calls
2225 `update-copyright-year' on all files.
2226 * src/tools/no-copyright: Exceptions that should not be handled by
2227 `update-copyright'
2228
Werner Lemberg4eff8542015-01-14 20:06:19 +010022292015-01-14 Werner Lemberg <wl@gnu.org>
2230
2231 * docs/CHANGES: Updated, using a description from Behdad.
2232
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +010022332015-01-14 Behdad Esfahbod <behdad@behdad.org>
2234
Behdad Esfahbod48c86622015-01-14 19:38:36 +01002235 * src/autofit/afmodule.c (af_autofitter_done): Fix compiler warning.
2236
22372015-01-14 Behdad Esfahbod <behdad@behdad.org>
2238
Behdad Esfahbod56ddafa2015-01-14 19:36:02 +01002239 [autofit] Add embedded array of segments and edges.
2240
2241 Avoids multiple mallocs per typical glyphs.
2242
2243 With this and recent changes to avoid mallocs, the thread-safe
2244 stack-based loader is now as fast as the previous model that had one
2245 cached singleton.
2246
2247 * src/autofit/afhints.h (AF_SEGMENTS_EMBEDDED, AF_EDGES_EMBEDDED):
2248 New macros.
2249 (AF_AxisHintsRec): Add two arrays for segments and edges.
2250
2251 * src/autofit/afhints.c (af_axis_hints_new_segment): Only allocate
2252 data if number of segments exceeds given threshold value.
2253 (af_axis_hints_new_edge): Only allocate data if number of edges
2254 exceeds given threshold value.
2255 (af_glyph_hints_done): Updated.
2256
22572015-01-14 Behdad Esfahbod <behdad@behdad.org>
2258
Behdad Esfahbod6f16b102015-01-14 19:26:49 +01002259 [autofit] Add embedded arrays for points and contours.
2260
2261 This avoids at least two malloc calls for typical glyphs.
2262
2263 * src/autofit/afhints.h (AF_POINTS_EMBEDDED, AF_CONTOURS_EMBEDDED):
2264 New macros.
2265 (AF_GlyphHintsRec): Add two arrays for contours and points.
2266
2267 * src/autofit/afhints.c (af_glyph_hints_init, af_glyph_hints_done):
2268 Updated.
2269 (af_glyph_hints_reload): Only allocate data if number of contours or
2270 points exceeds given threshold values.
2271
22722015-01-14 Behdad Esfahbod <behdad@behdad.org>
2273
Behdad Esfahbodc2733652015-01-14 19:16:12 +01002274 [autofit] Allocate hints object on the stack.
2275
2276 This avoids one malloc per load.
2277
2278 * src/autofit/afloader.h (AF_LoaderRec): Change type of `hints' to
2279 `AF_GlyphHints'.
2280 Update prototype.
2281
2282 * src/autofit/afloader.c (af_loader_init): Use `AF_GlyphHints'
2283 parameter instead of `FT_Memory'.
2284 (af_loader_done): Directly reset `load_hints'.
2285 (af_loader_load_g): Updated.
2286
2287 * src/autofit/afmodule.c (af_autofitter_load_glyph): Use local
2288 `hints' object.
2289
22902015-01-14 Behdad Esfahbod <behdad@behdad.org>
2291
Behdad Esfahboda4117fb2015-01-14 19:07:54 +01002292 [autofit] Reuse slot glyph loader.
2293
2294 No need to create a new glyph loader; we can reuse the one from
2295 `slot->internal->loader'. It's hard to tell why it was written that
2296 way originally, but new code looks sound and correct to me, and
2297 avoids lots of allocations.
2298
2299 * src/autofit/afloader.c (af_loader_init): Change return type to
2300 `void'.
2301 Don't call `FT_GlyphLoader_New'.
2302 (af_loader_reset): Don't call `FT_GlyphLoader_Rewind'.
2303 (af_loader_load_g): Update code to use `internal->loader', which
2304 doesn't need copying of data.
2305
2306 * src/autofit/afloader.h (AF_LoaderRec): Remove `gloader' member.
2307 Update prototype.
2308
2309 * src/autofit/afmodule.c (af_autofitter_load_glyph): Updated.
2310
23112015-01-14 Behdad Esfahbod <behdad@behdad.org>
2312
Behdad Esfahbodae6699f2015-01-14 18:55:39 +01002313 [autofit] Remove (unused) support for composite glyphs.
2314
2315 We never have to deal with composite glyphs in the autohinter, as
2316 those will be loaded into FORMAT_OUTLINE by the recursed
2317 `FT_Load_Glyph' function.
2318
2319 In the rare cases that FT_LOAD_NO_RECURSE is set, it will imply
2320 FT_LOAD_NO_SCALE as per `FT_Load_Glyph', which then implies
2321 FT_LOAD_NO_HINTING:
2322
2323 /* resolve load flags dependencies */
2324
2325 if ( load_flags & FT_LOAD_NO_RECURSE )
2326 load_flags |= FT_LOAD_NO_SCALE |
2327 FT_LOAD_IGNORE_TRANSFORM;
2328
2329 if ( load_flags & FT_LOAD_NO_SCALE )
2330 {
2331 load_flags |= FT_LOAD_NO_HINTING |
2332 FT_LOAD_NO_BITMAP;
2333
2334 load_flags &= ~FT_LOAD_RENDER;
2335 }
2336
2337 and as such the auto-hinter is never called. Thus, the recursion in
2338 `af_loader_load_g' never actually happens. So remove the depth
2339 counter as well.
2340
2341 * src/autofit/afloader.c (af_loader_load_g): Remove `depth'
2342 parameter.
2343 <FT_GLYPH_FORMAT_COMPOSITE>: Remove associated code.
2344 (af_loader_load_glyph): Updated.
2345
23462015-01-14 Behdad Esfahbod <behdad@behdad.org>
2347
Behdad Esfahbodc242fe42015-01-14 18:48:14 +01002348 [raster] Fix uninitialized memory access.
2349
2350 Apparently `ras.cProfile' might be uninitialized. This will be the
2351 case if `ras.top == ras.cProfile->offset', as can be seen in
2352 `End_Profile'. The overshoot code introduced in a change `Fix B/W
2353 rasterization of subglyphs with different drop-out modes.' (from
2354 2009-06-18) violated this, accessing `ras.cProfile->flags'
2355 unconditionally just before calling `End_Profile' (which then
2356 detected that `cProfile' is uninitialized and didn't touch it).
2357
2358 This was harmless, and was not detected by valgrind before because
2359 the objects were allocated on the `raster_pool', which was always
2360 initialized. With recent change to allocate raster buffers on the
2361 stack, valgrind now reported this invalid access.
2362
2363 * src/raster/ftraster.c (Convert_Glyph): Don't access an
2364 uninitialized `cProfile'.
2365
23662015-01-14 Behdad Esfahbod <behdad@behdad.org>
2367
Behdad Esfahbodb2ba6862015-01-14 18:43:13 +01002368 [smooth] Fix uninitialized memory access.
2369
2370 Looks like `ras.span_y' could always be used without initialization.
2371 This was never detected by valgrind before because the library-wide
2372 `raster_pool' was used for the worker object and `raster_pool' was
2373 originally zero'ed. But subsequent reuses of it were using `span_y'
2374 uninitialized. With the recent change to not use `render_pool' and
2375 allocate worker and buffer on the stack, valgrind now detects this
2376 uninitialized access.
2377
2378 * src/smooth/ftgrays.c (gray_raster_render): Initialize
2379 `ras.span_y'.
2380
23812015-01-14 Behdad Esfahbod <behdad@behdad.org>
2382
Behdad Esfahbod603292d2015-01-14 18:35:56 +01002383 [base] Don't initialize unused `driver->glyph_loader'.
2384
2385 * src/base/ftobjs.c (Destroy_Driver): Don't call
2386 `FT_GlyphLoader_Done'.
2387 (FT_Add_Module): Don't call `FT_GlyphLoader_New'.
2388
23892015-01-14 Behdad Esfahbod <behdad@behdad.org>
2390
Behdad Esfahbod51634252015-01-14 18:30:59 +01002391 [base] Don't allocate `library->raster_pool' anymore.
2392
2393 It's unused after the following commits:
2394
2395 [raster] Allocate render pool for mono rasterizer on the stack.
2396 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
2397
2398 The value of FT_RENDER_POOL_SIZE still serves the purpose it used to
2399 serve, which is, to adjust the pool size. But the pool is now
2400 allocated on the stack on demand.
2401
2402 * src/base/ftobjs.c (FT_New_Library, FT_Done_Library): Implement.
2403
24042015-01-14 Behdad Esfahbod <behdad@behdad.org>
2405
Behdad Esfahbod6dfdaf42015-01-14 18:21:13 +01002406 [base] Do not reorder library->renderers upon use.
2407
2408 Instead of keeping `library->renderers' in a MRU order, just leave
2409 it as-is. The MRU machinery wasn't thread-safe.
2410
2411 With this patch, rasterizing glyphs from different faces from
2412 different threads doesn't fail choosing rasterizer
2413 (FT_Err_Cannot_Render_Glyph).
2414
2415 Easiest to see that crash was to add a `printf' (or otherwise let
2416 thread yield in FT_Throw with debugging enabled).
2417
2418 * src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c
2419 (FT_Outline_Render): Don't call `FT_Set_Renderer'.
2420
24212015-01-14 Behdad Esfahbod <behdad@behdad.org>
2422
Behdad Esfahboda773c302015-01-14 18:16:20 +01002423 [raster] Allocate render pool for mono rasterizer on the stack.
2424
2425 Instead of using the `render_pool' member of `FT_Library' that is
2426 provided down to the rasterizer, completely ignore that and allocate
2427 needed objects on the stack instead.
2428
2429 With this patch, rasterizing glyphs from different faces from
2430 different threads doesn't crash in the monochrome rasterizer.
2431
2432 * src/raster/ftraster.c (black_TRaster): Remove `buffer',
2433 `buffer_size', and `worker' members.
2434
2435 (ft_black_render): Create `buffer' locally.
2436 (ft_black_reset): Updated.
2437
24382015-01-14 Behdad Esfahbod <behdad@behdad.org>
2439
Behdad Esfahbod8dc86352015-01-14 18:06:22 +01002440 [raster] Remove 5-level gray AA mode from monochrome rasterizer.
2441
2442 It was off by default and couldn't be turned on at runtime. And the
2443 smooth rasterizer superceded it over ten years ago. No point in
2444 keeping. Comments suggested that it was there for compatibility
2445 with FreeType 1.
2446
2447 550 lines down.
2448
2449 * src/raster/ftraster.c (FT_RASTER_OPTION_ANTI_ALIASING,
2450 RASTER_GRAY_LINES): Remove macros and all associated code.
2451
2452 (black_TWorker): Remove `gray_min_x' and `gray_max_x'.
2453 (black_TRaster): Remove `grays' and `gray_width'.
2454
2455 (Vertical_Sweep_Init, Vertical_Sweep_Span, Vertical_Sweep_Drop,
2456 ft_black_render): Updated.
2457
2458 * src/raster/ftrend1.c (ft_raster1_render): Simplify code.
2459 (ft_raster5_renderer_class): Removed.
2460
24612015-01-14 Behdad Esfahbod <behdad@behdad.org>
2462
Behdad Esfahbod747ae2c2015-01-14 17:54:26 +01002463 [smooth] Allocate render pool for smooth rasterizer on the stack.
2464
2465 Instead of using the `render_pool' member of `FT_Library' that is
2466 provided down to the rasterizer, completely ignore that and allocate
2467 needed objects on the stack instead.
2468
2469 With this patch, rasterizing glyphs from different faces from
2470 different threads doesn't crash in the smooth rasterizer.
2471
2472 Bugs:
2473
2474 https://bugzilla.redhat.com/show_bug.cgi?id=678397
2475 https://bugzilla.redhat.com/show_bug.cgi?id=1004315
2476 https://bugzilla.redhat.com/show_bug.cgi?id=1165471
2477 https://bugs.freedesktop.org/show_bug.cgi?id=69034
2478
2479 * src/smooth/ftgrays.c (gray_TRaster): Remove `buffer',
2480 `buffer_size', `band_size', and `worker' members.
2481
2482 (gray_raster_render): Create `buffer', `buffer_size', and
2483 `band_size' locally.
2484 (gray_raster_reset): Updated.
2485
24862015-01-14 Behdad Esfahbod <behdad@behdad.org>
2487
Behdad Esfahbod531d4632015-01-14 17:46:55 +01002488 [truetype] Allocate TT_ExecContext in TT_Size instead of TT_Driver.
2489
2490 Previously the code had stipulation for using a per-TT_Size exec
2491 context if `size->debug' was true. But there was no way that
2492 `size->debug' could *ever* be true. As such, the code was always
2493 using the singleton `TT_ExecContext' that was stored in `TT_Driver'.
2494 This was, clearly, not threadsafe.
2495
2496 With this patch, loading glyphs from different faces from different
2497 threads doesn't crash in the bytecode loader code.
2498
2499 * src/truetype/ttobjs.h (TT_SizeRec): Remove `debug' member.
2500 (TT_DriverRec): Remove `context' member.
2501
2502 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Remove
2503 `TT_ExecContext' code related to a global `TT_Driver' object.
2504
2505 (tt_driver_done): Don't remove `TT_ExecContext' object here but ...
2506 (tt_size_done_bytecode): ... here.
2507
2508 (tt_driver_init): Don't create `TT_ExecContext' object here but ...
2509 (tt_size_init_bytecode): ... here, only on demand.
2510
2511 * src/truetype/ttinterp.c (TT_Run_Context): Remove defunct debug
2512 code.
2513 (TT_New_Context): Remove `TT_ExecContext' code related to a global
2514 `TT_Driver' object.
2515
2516 * src/truetype/ttinterp.h: Updated.
2517
2518 * src/truetype/ttgload.c (TT_Hint_Glyph, tt_loader_init): Updated.
2519
25202015-01-14 Behdad Esfahbod <behdad@behdad.org>
2521
Behdad Esfahbod89bc8d42015-01-14 16:01:19 +01002522 [autofit] Allocate AF_Loader on the stack instead of AF_Module.
2523
2524 Stop sharing a global `AF_Loader'. Allocate one on the stack during
2525 glyph load.
2526
2527 Right now this results in about 25% slowdown, to be fixed in a
2528 following commit.
2529
2530 With this patch loading glyphs from different faces from different
2531 threads doesn't immediately crash in the autohinting loader code.
2532
2533 Bugs:
2534
2535 https://bugzilla.redhat.com/show_bug.cgi?id=1164941
2536
2537 * src/autofit/afloader.c (af_loader_init): Pass
2538 `AF_Loader' and `FT_Memory' instead of `AF_Module' as arguments.
2539 (af_loader_reset, af_loader_load_glyph): Also pass `loader' as
2540 argument.
2541 (af_loader_done): Use `AF_Loader' instead of `AF_Module' as
2542 argument.
2543
2544 * src/autofit/afmodule.c (af_autofitter_init): Don't call
2545 `af_loader_init'.
2546 (af_autofitter_done): Don't call `af_loader_done'.
2547 (af_autofitter_load_glyph): Use a local `AF_Loader' object.
2548
2549 * src/autofit/afloader.h: Include `afmodule.h'.
2550 Update prototypes.
2551 Move typedef for `AF_Module' to...
2552
2553 * src/autofit/afmodule.h: ... this place.
2554 No longer include `afloader.h'.
2555
25562015-01-14 Behdad Esfahbod <behdad@behdad.org>
2557
Behdad Esfahbod3f9b3d82015-01-14 15:48:12 +01002558 * src/type42/t42objs.h (T42_DriverRec): Remove unused member.
2559
Werner Lemberg36d03c92015-01-12 11:26:30 +010025602015-01-12 Werner Lemberg <wl@gnu.org>
2561
2562 Fix Savannah bug #43976.
2563
2564 Assure that FreeType's internal include directories are found before
2565 `CPPFLAGS' (which might be set by the user in the environment), and
2566 `CPPFLAGS' before `CFLAGS'.
2567
2568 * builds/freetype.mk (FT_CFLAGS): Don't add `INCLUDE_FLAGS'.
2569 (FT_COMPILE): Make this a special variable for compiling only the
2570 files handled in `freetype.mk'.
2571 (.c.$O): Removed, unused.
2572
2573 * src/*/rules.mk (*_COMPILE): Fix order of include directories.
2574
Werner Lembergd03a67a2015-01-11 08:39:14 +010025752015-01-11 Werner Lemberg <wl@gnu.org>
2576
Werner Lemberg95b57052015-01-11 09:50:49 +01002577 [truetype] Prettyfing.
2578
2579 * src/truetype/ttinterp.c (project, dualproj, fast_project,
2580 fast_dualproj): Rename to...
2581 (PROJECT, DUALPROJ, FAST_PROJECT, FAST_DUALPROJ): ... this.
2582
25832015-01-11 Werner Lemberg <wl@gnu.org>
2584
Werner Lembergea173c02015-01-11 08:58:54 +01002585 * src/truetype/ttinterp.c (Ins_JROT, Ins_JROF): Simplify.
2586
2587 Based on a patch from Behdad.
2588
25892015-01-11 Werner Lemberg <wl@gnu.org>
2590
Werner Lemberg628578c2015-01-11 08:53:31 +01002591 * src/truetype/ttinterp.c (Ins_SxVTL): Simplify function call.
2592
25932015-01-11 Werner Lemberg <wl@gnu.org>
2594
Werner Lemberg08e79092015-01-11 08:45:50 +01002595 * src/truetype/ttinterp.c (Normalize): Remove unused argument.
2596
25972015-01-11 Werner Lemberg <wl@gnu.org>
2598
Werner Lembergd03a67a2015-01-11 08:39:14 +01002599 [truetype] More macro expansions.
2600
Werner Lemberg4aaadf42015-01-11 08:42:28 +01002601 * src/truetype/ttinterp.c (FT_UNUSED_EXEC): Remove macro by
2602 expansion.
2603
26042015-01-11 Werner Lemberg <wl@gnu.org>
2605
2606 [truetype] More macro expansions.
2607
Werner Lembergd03a67a2015-01-11 08:39:14 +01002608 * src/truetype/ttinterp.c (INS_ARG): Remove macro by expansion,
2609 adjusting funtion calls where necessary.
2610 (FT_UNUSED_ARG): Removed, no longer needed.
2611
Werner Lemberg1b4d68c2015-01-10 19:56:28 +010026122015-01-10 Werner Lemberg <wl@gnu.org>
2613
Werner Lembergeb341362015-01-11 00:23:27 +01002614 [truetype] More macro expansions.
2615
2616 Based on a patch from Behdad.
2617
2618 * src/truetype/ttinterp.c (DO_*): Expand macros into corresponding
2619 `Ins_*' functions.
2620 (TT_RunIns): Replace `DO_*' macros with `Ins_*' function calls.
2621 (ARRAY_BOUND_ERROR): Remove second definition, which is no longer
2622 needed.
2623 (Ins_SVTCA, Ins_SPVTCA, Ins_SFVTCA): Replaced with...
2624 (Ins_SxyTCA): New function.
2625
26262015-01-10 Werner Lemberg <wl@gnu.org>
2627
Werner Lemberg01be1302015-01-10 23:05:37 +01002628 [truetype] Remove TT_CONFIG_OPTION_INTERPRETER_SWITCH.
2629
2630 Behdad suggested this code simplification, and nobody objected...
2631
2632 * include/config/ftoption.h, devel/ftoption.h
2633 (TT_CONFIG_OPTION_INTERPRETER_SWITCH): Remove.
2634
2635 * src/truetype/ttinterp.c [TT_CONFIG_OPTION_INTERPRETER_SWITCH]:
2636 Remove related code.
2637 (ARRAY_BOUND_ERROR): Use do-while loop.
2638
26392015-01-10 Werner Lemberg <wl@gnu.org>
2640
Werner Lembergfae0c812015-01-10 20:23:10 +01002641 [truetype] More macro expansions.
2642
Werner Lemberg6cc1f122015-01-10 21:56:59 +01002643 * src/truetype/ttinterp.c, src/truetype/ttinterp.h (EXEC_ARG_,
2644 EXEC_ARG): Remove by replacing with expansion.
2645
26462015-01-10 Werner Lemberg <wl@gnu.org>
2647
2648 [truetype] More macro expansions.
2649
Werner Lemberg24681452015-01-10 21:53:48 +01002650 Based on a patch from Behdad.
2651
2652 * src/truetype/ttinterp.c (SKIP_Code, GET_ShortIns, NORMalize,
2653 SET_SuperRound, ROUND_None, INS_Goto_CodeRange, CUR_Func_move,
2654 CUR_Func_move_orig, CUR_Func_round, CUR_Func_cur_ppem,
2655 CUR_Func_read_cvt, CUR_Func_write_cvt, CUR_Func_move_cvt,
2656 CURRENT_Ratio, INS_SxVTL, COMPUTE_Funcs, COMPUTE_Round,
2657 COMPUTE_Point_Displacement, MOVE_Zp2_Point): Remove by replacing
2658 with expansion.
2659
2660 (Cur_Func_project, CUR_Func_dualproj, CUR_fast_project,
2661 CUR_fast_dualproj): Replace with macros `project', `dualproj',
2662 `fast_project', `fast_dualproj'.
2663
26642015-01-10 Werner Lemberg <wl@gnu.org>
2665
2666 [truetype] More macro expansions.
2667
Werner Lembergfae0c812015-01-10 20:23:10 +01002668 * src/truetype/ttinterp.c (EXEC_OP_, EXEC_OP): Remove by replacing
2669 with expansion.
2670
26712015-01-10 Werner Lemberg <wl@gnu.org>
2672
Werner Lemberg5a752f32015-01-10 20:08:35 +01002673 [truetype] Remove code for static TrueType interpreter.
2674
2675 This is a follow-up patch.
2676
2677 * src/truetype/ttinterp.c, src/truetype/ttinterp.h
2678 [TT_CONFIG_OPTION_STATIC_INTERPRETER,
2679 TT_CONFIG_OPTION_STATIC_RASTER]: Remove macros and related code.
2680
26812015-01-10 Werner Lemberg <wl@gnu.org>
2682
Werner Lemberg1b4d68c2015-01-10 19:56:28 +01002683 * src/truetype/ttinterp.c (CUR): Remove by replacing with expansion.
2684
2685 This starts a series of patches that simplifies the code of the
2686 bytecode interpreter.
2687
Werner Lemberg232bd942014-12-30 21:44:51 +010026882014-12-30 Werner Lemberg <wl@gnu.org>
2689
2690 * Version 2.5.5 released.
2691 =========================
2692
2693
2694 Tag sources with `VER-2-5-5'.
2695
2696 * docs/VERSION.DLL: Update documentation and bump version number to
2697 2.5.5.
2698
2699 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
2700 builds/windows/vc2005/index.html,
2701 builds/windows/vc2008/freetype.vcproj,
2702 builds/windows/vc2008/index.html,
2703 builds/windows/vc2010/freetype.vcxproj,
2704 builds/windows/vc2010/index.html,
2705 builds/windows/visualc/freetype.dsp,
2706 builds/windows/visualc/freetype.vcproj,
2707 builds/windows/visualc/index.html,
2708 builds/windows/visualce/freetype.dsp,
2709 builds/windows/visualce/freetype.vcproj,
2710 builds/windows/visualce/index.html,
2711 builds/wince/vc2005-ce/freetype.vcproj,
2712 builds/wince/vc2005-ce/index.html,
2713 builds/wince/vc2008-ce/freetype.vcproj,
2714 builds/wince/vc2008-ce/index.html: s/2.5.4/2.5.5/, s/254/255/.
2715
2716 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 5.
2717
2718 * builds/unix/configure.raw (version_info): Set to 17:4:11.
2719 * CMakeLists.txt (VERSION_PATCH): Set to 5.
2720 * docs/CHANGES: Updated.
2721
2722 * builds/toplevel.mk (dist): Fix typos.
2723
Alexei Podtelezhnikov70241552014-12-24 12:11:46 -050027242014-12-24 Alexei Podtelezhnikov <apodtele@gmail.com>
2725
2726 [base] Formatting and nanooptimizations.
2727
2728 * src/base/ftcalc.c,
2729 * src/base/fttrigon.c: Revise sign restoration.
2730
Werner Lemberg06842c72014-12-13 07:42:51 +010027312014-12-13 Werner Lemberg <wl@gnu.org>
2732
2733 * src/pcf/pcfread.c (pcf_read_TOC): Improve fix from 2014-12-08.
2734
Werner Lembergb9438112014-12-11 13:33:14 +010027352014-12-11 Werner Lemberg <wl@gnu.org>
2736
Werner Lemberg82119502014-12-11 22:27:06 +01002737 * builds/toplevel.mk (dist): Use older POSIX standard for `tar'.
2738
2739 Apparently, BSD tar isn't capable yet of handling POSIX-1.2001
2740 (contrary to GNU tar), so force the POSIX-1.1988 format.
2741
2742 Problem reported by Stephen Fisher <sfisher@SDF.ORG>.
2743
27442014-12-11 Werner Lemberg <wl@gnu.org>
2745
Werner Lemberg812ed342014-12-11 14:07:29 +01002746 * src/type42/t42parse.c (t42_parse_sfnts): Reject invalid TTF size.
2747
27482014-12-11 Werner Lemberg <wl@gnu.org>
2749
Werner Lembergc9ca6ff2014-12-11 13:39:39 +01002750 * src/base/ftobjs.c (FT_Get_Glyph_Name): Fix off-by-one check.
2751
2752 Problem reported by Dennis Felsing <dennis@felsin9.de>.
2753
27542014-12-11 Werner Lemberg <wl@gnu.org>
2755
Werner Lembergb9438112014-12-11 13:33:14 +01002756 * src/type42/t42parse.c (t42_parse_sfnts): Check `string_size'.
2757
2758 Problem reported by Dennis Felsing <dennis@felsin9.de>.
2759
suzuki toshiya2b592822014-12-10 00:27:41 +090027602014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
2761
suzuki toshiya9bd1e552014-12-09 14:51:52 +09002762 [gxvalid] Fix a naming convention conflicting with ftvalid.
2763
2764 See previous changeset for otvalid.
2765
2766 * src/gxvalid/{gxvcommn.h, gxvmort.h, gxvmorx.h}: Replace
2767 `valid' by `gxvalid'.
2768 * src/gxvalid/{gxvbsln.c, gxvcommn.c, gxvfeat.c, gxvjust.c,
2769 gxvkern.c, gxvlcar.c, gxvmort.c, gxvmort0.c, gxvmort1.c,
2770 gxvmort2.c, gxvmort4.c, gxvmort5.c, gxvmorx.c, gxvmorx0.c,
2771 gxvmorx1.c, gxvmorx2.c, gxvmorx4.c, gxvmorx5.c, gxvopbd.c,
2772 gxvprop.c, gxvtrak.c}: Replace `valid' by `gxvalid' if
2773 it is typed as GXV_Validator.
2774
27752014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
2776
suzuki toshiya51abdf62014-12-09 00:58:04 +09002777 [otvalid] Fix a naming convention conflicting with ftvalid.
2778
2779 Some prototypes in ftvalid.h use `valid' for the variables
2780 typed as FT_Validator. Their implementations in src/base/
2781 ftobjs.c and utilizations in src/sfnt/ttcmap.c do similar.
2782
2783 Some macros in otvcommn.h assume the exist of the variable
2784 `valid' typed as OTV_Validator in the caller.
2785
2786 Mixing these two conventions cause invalid pointer conversion
2787 and unexpected SEGV in longjmp. To prevent it, all variables
2788 typed as OTV_Validator are renamed to `otvalid'.
2789
2790 * src/otvalid/otvcommn.h: Replace `valid' by `otvalid'.
2791 * src/otvalid/{otvcommn.c, otvbase.c, otvgdef.c, otvgpos.c,
2792 otvgsub.c, otvjstf.c, otvmath.c}: Replace `valid' by `otvalid'
2793 if it is typed as OTV_Validator.
2794
27952014-12-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
2796
suzuki toshiya2b592822014-12-10 00:27:41 +09002797 [ftvalid] Introduce FT_THROW() in FT_INVALID_XXX macros.
2798
2799 Original patch is designed by Werner Lemberg. Extra part
2800 for otvalid and gxvalid are added by suzuki toshiya, see
2801 discussion:
2802 http://lists.nongnu.org/archive/html/freetype-devel/2014-12/msg00002.html
2803 http://lists.nongnu.org/archive/html/freetype-devel/2014-12/msg00007.html
2804
2805 * include/internal/ftvalid.h: Introduce FT_THROW() in FT_INVALID_().
2806 * src/gxvalid/gxvcommn.h: Ditto.
2807 * src/otvalid/otvcommn.h: Ditto.
2808
Werner Lemberg74af85c2014-12-08 16:01:50 +010028092014-12-08 Werner Lemberg <wl@gnu.org>
2810
2811 [pcf] Fix Savannah bug #43774.
2812
2813 Work around `features' of X11's `pcfWriteFont' and `pcfReadFont'
2814 functions. Since the PCF format doesn't have an official
2815 specification, we have to exactly follow these functions' behaviour.
2816
2817 The problem was unveiled with a patch from 2014-11-06, fixing issue
2818 #43547.
2819
2820 * src/pcf/pcfread.c (pcf_read_TOC): Don't check table size for last
2821 element. Instead, assign real size.
2822
Werner Lemberg66883b52014-12-07 09:17:06 +010028232014-12-07 Werner Lemberg <wl@gnu.org>
2824
Werner Lemberg553c9672014-12-07 19:29:52 +01002825 Work around a bug in Borland's C++ compiler.
2826
2827 See
2828
2829 http://qc.embarcadero.com/wc/qcmain.aspx?d=118998
2830
2831 for Borland's bug tracker entry.
2832
2833 Reported by Yuliana Zigangirova <zigangirova@inbox.ru>,
2834 http://lists.gnu.org/archive/html/freetype-devel/2014-04/msg00001.html.
2835
2836 * include/internal/ftvalid.h (FT_ValidatorRec), src/smooth/ftgrays.c
2837 (gray_TWorker_): Move `ft_jmp_buf' field to be the first element.
2838
28392014-12-07 Werner Lemberg <wl@gnu.org>
2840
Werner Lemberg9870d6d2014-12-07 09:40:47 +01002841 */*: Decorate hex constants with `U' and `L' where appropriate.
2842
28432014-12-07 Werner Lemberg <wl@gnu.org>
2844
Werner Lemberg66883b52014-12-07 09:17:06 +01002845 [truetype] Prevent memory leak for buggy fonts.
2846
2847 * src/truetype/ttobjs.c (tt_size_done): Unconditionally call
2848 `tt_size_done_bytecode'.
2849
Werner Lemberg94926682014-12-06 07:11:44 +010028502014-12-06 Werner Lemberg <wl@gnu.org>
2851
2852 * Version 2.5.4 released.
2853 =========================
2854
2855
2856 Tag sources with `VER-2-5-4'.
2857
2858 * docs/VERSION.DLL: Update documentation and bump version number to
2859 2.5.4.
2860
2861 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
2862 builds/windows/vc2005/index.html,
2863 builds/windows/vc2008/freetype.vcproj,
2864 builds/windows/vc2008/index.html,
2865 builds/windows/vc2010/freetype.vcxproj,
2866 builds/windows/vc2010/index.html,
2867 builds/windows/visualc/freetype.dsp,
2868 builds/windows/visualc/freetype.vcproj,
2869 builds/windows/visualc/index.html,
2870 builds/windows/visualce/freetype.dsp,
2871 builds/windows/visualce/freetype.vcproj,
2872 builds/windows/visualce/index.html,
2873 builds/wince/vc2005-ce/freetype.vcproj,
2874 builds/wince/vc2005-ce/index.html,
2875 builds/wince/vc2008-ce/freetype.vcproj,
2876 builds/wince/vc2008-ce/index.html: s/2.5.3/2.5.4/, s/253/254/.
2877
2878 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 4.
2879
2880 * builds/unix/configure.raw (version_info): Set to 17:3:11.
2881 * CMakeLists.txt (VERSION_PATCH): Set to 4.
2882 * docs/CHANGES: Updated.
2883
Werner Lemberg934ef382014-12-04 06:38:51 +010028842014-12-04 Werner Lemberg <wl@gnu.org>
2885
2886 docs/CHANGES: Updated, formatted.
2887
Dave Arnold2cdc4562014-12-04 06:10:16 +010028882014-12-04 Dave Arnold <darnold@adobe.com>
2889
Dave Arnoldf89396c2014-12-04 06:17:26 +01002890 [cff] Modify an FT_ASSERT.
2891
2892 * src/cff/cf2hints.c (cf2_hintmap_map): After the fix for Savannah
2893 bug #43661, the test font `...aspartam.otf' still triggers an
2894 FT_ASSERT. Since hintmap still works with count==0, ...
2895 (cf2_glyphpath_lineTo, cf2_glyphpath_curveTo): ... add that term to
2896 suppress the assert.
2897
28982014-12-04 Dave Arnold <darnold@adobe.com>
2899
Dave Arnold2cdc4562014-12-04 06:10:16 +01002900 [cff] Fix Savannah bug #43661.
2901
2902 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdHSTEM,
2903 cf2_cmdVSTEM, cf2_cmdHINTMASK>: Don't append to stem arrays after
2904 hintmask is constructed.
2905
2906 * src/cff/cf2hints.c (cf2_hintmap_build): Add defensive code to
2907 avoid reading past end of hintmask.
2908
Werner Lemberg16188eb2014-12-03 10:18:34 +010029092014-12-03 Werner Lemberg <wl@gnu.org>
2910
Werner Lemberg8fa69a82014-12-03 20:07:14 +01002911 docs/CHANGES: Updated.
2912
29132014-12-03 Werner Lemberg <wl@gnu.org>
2914
Werner Lemberga632b5f2014-12-03 19:30:44 +01002915 [autofit] Better fix for conversion specifiers in debug messages.
2916
2917 Using `%ld' for pointer differences causes warnings on 32bit
2918 platforms. The correct type would be (the relatively new) `%td',
2919 however, this is missing on some important platforms.
2920
2921 This patch improves the change from 2014-11-28.
2922
2923 * src/autofit/afhints.c (AF_INDEX_NUM): Use `int' typecast. Our
2924 pointer differences are always sufficiently small.
2925 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
2926 af_glyph_hints_dump_edge): Revert to `%d' and use `AF_INDEX_NUM'.
2927
29282014-12-03 Werner Lemberg <wl@gnu.org>
2929
Werner Lemberg16188eb2014-12-03 10:18:34 +01002930 FT_Sfnt_Tag: s/ft_sfnt_xxx/FT_SFNT_XXX/ for orthogonality.
2931
2932 All public FreeType enumeration and flag values are uppercase...
2933
2934 * include/tttables.h (FT_Sfnt_Tag): Implement it. For backwards
2935 compatilibity, retain the old values as macros.
2936
2937 * src/base/ftfstype.c (FT_Get_FSType_Flags), src/sfnt/sfdriver.c
2938 (get_sfnt_table): Updated.
2939
Werner Lemberg2af25ac2014-12-02 08:38:57 +010029402014-12-02 Werner Lemberg <wl@gnu.org>
2941
Werner Lembergde43ace2014-12-02 23:06:04 +01002942 * include/*: Improve structure of documentation.
2943
2944 . Add and update many `<Order>' tags.
2945 . Apply various documentation fixes.
2946 . Remove details to deprecated (or never implemented) data.
2947
29482014-12-02 Werner Lemberg <wl@gnu.org>
2949
Werner Lembergca1f5cc2014-12-02 22:49:25 +01002950 [docmaker] Always handle `<Order>' section elements.
2951
2952 Previously, those elements were handled only for sections present in
2953 a `<Sections>' chapter element.
2954
2955 * src/tools/docmaker/content.py (ContentProcessor::finish):
2956 Implement it.
2957
29582014-12-02 Werner Lemberg <wl@gnu.org>
2959
Werner Lembergef6a3522014-12-02 21:16:59 +01002960 [docmaker] Properly handle empty rows in Synopsis.
2961
2962 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Emit
2963 `&nbsp;' for empty fields.
2964
29652014-12-02 Werner Lemberg <wl@gnu.org>
2966
Werner Lemberg0e96f052014-12-02 11:08:31 +01002967 [docmaker] Thinko.
2968
2969 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
2970 Emit `/empty/' string for first element also.
2971
29722014-12-02 Werner Lemberg <wl@gnu.org>
2973
Werner Lemberg102d4a72014-12-02 10:27:40 +01002974 [docmaker] Honour empty lines in `<Order>' section element.
2975
2976 This greatly improves the readability of the `Synopsis' links.
2977
2978 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
2979 Insert string `/empty/' between items.
2980
2981 * src/tools/docmaker/formatter.py (Formatter::section_dump): Make it
2982 robust against nonexistent keys.
2983
2984 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Emit
2985 empty <td> elements for `/empty/'.
2986
29872014-12-02 Werner Lemberg <wl@gnu.org>
2988
Werner Lemberg2af25ac2014-12-02 08:38:57 +01002989 [docmaker] Ensure Python 3 compatibility.
2990
2991 * src/tools/docmaker/content.py (ContentProcessor::set_section,
2992 ContentProcessor::finish): Replace `has_key' function with `in'
2993 keyword.
2994
2995 * src/tools/docmaker/formatter.py (Formatter::__init__): Replace
2996 sorting function with a key generator.
2997 (Formatter::add_identifier): Replace `has_key' function with `in'
2998 keyword.
2999
3000 * src/tools/docmaker/tohtml.py (HtmlFormatter::html_source_quote):
3001 Replace `has_key' function with `in' keyword.
3002 (HtmlFormatter::index_exit, HtmlFormatter::section_enter): Use
3003 integer division.
3004 s/<>/>/.
3005
3006 * src/tools/docmaker/utils.py: Import `itertools'.
3007 (index_sort): Replaced by...
3008 (index_key): ... this new key generator (doing exactly the same).
3009
Werner Lemberg8f795112014-11-29 06:49:15 +010030102014-11-29 Werner Lemberg <wl@gnu.org>
3011
Werner Lemberg80bfeb12014-12-01 10:07:52 +01003012 [docmaker] Don't output a block multiple times.
3013
3014 This bug was hidden by not processing all lines of `<Order>' blocks.
3015
3016 * src/tools/docmaker/formatter.py (Formatter::section_dump): Filter
3017 out field names.
3018
30192014-11-29 Werner Lemberg <wl@gnu.org>
3020
Werner Lemberg0dbad762014-12-01 08:44:48 +01003021 [docmaker] Use field values as HTML link targets where possible.
3022
3023 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_block_url):
3024 Accept second, optional argument to specify a name.
3025 (HtmlFormatter::html_source_quote): Link to field ID if possible.
3026 (HtmlFormatter::print_html_field_list): Emit `id' attribute.
3027
30282014-11-29 Werner Lemberg <wl@gnu.org>
3029
Werner Lemberg785b1d02014-11-30 22:16:34 +01003030 [docmaker] Allow empty lines in `<Order>' blocks.
3031
3032 Before this patch, the suggested order of entries stopped at the
3033 first empty line.
3034
3035 Obviously, nobody noticed that this problem caused a much reduced
3036 set of links in the `Synopsis' sections; in particular, the
3037 `<Order>' blocks contain a lot of entries that wouldn't be listed
3038 otherwise...
3039
3040 * src/tools/docmaker/content.py (DocBlock::get_markup_words_all):
3041 New function to iterate over all items.
3042 (DocSection::process): Use it.
3043
30442014-11-29 Werner Lemberg <wl@gnu.org>
3045
Werner Lemberg16b3e622014-11-30 20:58:27 +01003046 * src/tools/docmaker/sources.py (column) [Format 2]: Fix regexp.
3047
3048 After the single asterisk there must be no other immediately following
3049 asterisk.
3050
30512014-11-29 Werner Lemberg <wl@gnu.org>
3052
Werner Lemberg434bc692014-11-29 23:12:55 +01003053 * src/tools/docmaker/tohtml.py: Improve CSS for vertical spacing.
Werner Lemberg51987ea2014-11-29 22:19:29 +01003054
Werner Lemberg434bc692014-11-29 23:12:55 +010030552014-11-29 Werner Lemberg <wl@gnu.org>
3056
3057 [docmaker] Improve HTML code for table of contents.
3058
3059 * src/tools/docmaker/tohtml.py: Introduce a new table class `toc',
Werner Lemberg51987ea2014-11-29 22:19:29 +01003060 together with proper CSS.
3061
30622014-11-29 Werner Lemberg <wl@gnu.org>
3063
Werner Lembergaa834ce2014-11-29 20:08:29 +01003064 [docmaker] Provide higher-level markup and simplify HTML.
3065
3066 * src/tools/docmaker/tohtml.py: Instead of using extraneous `<div>'
3067 elements, use CSS descendants (of class `section') to format the
3068 data.
3069
3070 Also remove reduntant <p> and <br> elements, replacing them with
3071 proper CSS.
3072
3073 Globally reduce page width to 75%.
3074
3075 (block_header): Rename <div> class to `section'.
3076
30772014-11-29 Werner Lemberg <wl@gnu.org>
3078
Werner Lemberg3bb97022014-11-29 16:12:37 +01003079 [docmaker] Add `top' links after blocks.
3080
3081 * src/tools/docmaker/tohtml.py (block_footer_middle): Implement it.
3082
30832014-11-29 Werner Lemberg <wl@gnu.org>
3084
Werner Lemberga31f9712014-11-29 07:18:44 +01003085 * src/tools/docmaker/tohtml.py: Improve CSS for fields.
3086
Werner Lemberg3bb97022014-11-29 16:12:37 +01003087 Make fields align horizontally relative to full line width.
Werner Lemberga31f9712014-11-29 07:18:44 +01003088
30892014-11-29 Werner Lemberg <wl@gnu.org>
3090
Werner Lemberg8f795112014-11-29 06:49:15 +01003091 * src/tools/docmaker/tohtml.py: Fix index and TOC templates.
3092
3093 This thinko was introduced 2014-11-27.
3094
Werner Lembergba1ba0c2014-11-28 22:04:14 +010030952014-11-28 Werner Lemberg <wl@gnu.org>
3096
3097 [docmaker] Format field lists with CSS.
3098
3099 This also simplifies the inserted HTML code.
3100
3101 * src/tools/docmaker/tohtml.py
3102 (HtmlFormatter::print_html_field_list): Do it.
3103
suzuki toshiya348fffa2014-11-28 16:05:59 +090031042014-11-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3105
3106 Fix compiler warning to the comparison between signed and
3107 unsigned variable.
3108
3109 * src/pfr/pfrsbit.c (pfr_slot_load_bitmap): Fix the comparison
3110 between `ypos + ysize' and FT_INT_{MAX,MIN}.
3111
Werner Lembergba1ba0c2014-11-28 22:04:14 +010031122014-11-28 Werner Lemberg <wl@gnu.org>
Werner Lemberg984e0712014-11-28 05:33:58 +01003113
Werner Lembergba1ba0c2014-11-28 22:04:14 +01003114 [docmaker] Replace empty `<td>' with CSS.
Werner Lemberg46d4dc82014-11-28 05:49:56 +01003115
3116 * src/tools/docmaker/tohtml.py (HtmlFormatter::section_enter): Do
3117 it.
3118
Werner Lembergba1ba0c2014-11-28 22:04:14 +010031192014-11-28 Werner Lemberg <wl@gnu.org>
Werner Lemberg46d4dc82014-11-28 05:49:56 +01003120
Werner Lemberg984e0712014-11-28 05:33:58 +01003121 [docmaker] Replace some `<table>' tags with `<h4>' and `<div>'.
3122
3123 * src/tools/docmaker/tohtml.py (marker_*): Use `<h4>'.
3124 (source_*): Use `<div>'.
3125 (HtmlFormatter::block_enter): s/<h4>/<h3>/.
3126
suzuki toshiya9ee6a0a2014-11-28 11:14:18 +090031272014-11-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3128
3129 Fix compiler warning to conversion specifiers in debug messages.
3130
3131 * src/autofit/afhints.c (af_glyph_hints_dump_points): Add length
Werner Lemberga632b5f2014-12-03 19:30:44 +01003132 modifier to dump long integers.
3133 (af_glyph_hints_dump_segments, af_glyph_hints_dump_edges): Ditto.
suzuki toshiya9ee6a0a2014-11-28 11:14:18 +09003134
Werner Lemberg26d699e2014-11-27 19:22:52 +010031352014-11-27 Werner Lemberg <wl@gnu.org>
3136
Werner Lemberg984e0712014-11-28 05:33:58 +01003137 * src/tools/docmaker/tohtml.py: Use more CSS for index.
Werner Lemberg7ea36342014-11-27 19:38:31 +01003138
31392014-11-27 Werner Lemberg <wl@gnu.org>
3140
Werner Lembergedcf8172014-11-27 19:28:48 +01003141 [docmaker] Replace `name' attribute of `<a>' with `id'.
3142
3143 * src/tools/docmaker/tohtml.py (HtmlFormatter::block_enter): Do it.
3144
31452014-11-27 Werner Lemberg <wl@gnu.org>
3146
Werner Lemberg26d699e2014-11-27 19:22:52 +01003147 * src/tools/docmaker/tohtml.py: Remove remaining `width' attributes.
3148
3149 For `Index' and `TOC' links, we now simply use the `text-align' CSS
3150 property of `<td>' to enforce flush-left and flush-right,
3151 eliminating the hack with an empty, full-width `<td>' element
3152 inbetween.
3153
3154 The change also enforces the same (smaller) size for all index and
3155 TOC links.
3156
suzuki toshiya2676e072014-11-28 00:58:25 +090031572014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3158
suzuki toshiya1b12f5d2014-11-28 01:22:26 +09003159 * src/cff/cf2font.c: Include `ftcalc.h' to use FT_MSB(),
3160 cf2font.c could not find it under `make multi' build.
3161
31622014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3163
suzuki toshiya2676e072014-11-28 00:58:25 +09003164 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Remove
3165 unrequired negative value check for `width' and `height'.
3166
Werner Lemberg8585cf52014-11-27 10:49:05 +010031672014-11-27 Werner Lemberg <wl@gnu.org>
3168
Werner Lembergdd3fee02014-11-27 13:20:52 +01003169 * src/tools/docmaker/tohtml.py: More HTML table refactoring.
3170
3171 Replace some `<table>' tags with `<div>' to simplify structure.
3172
3173 Move `bgcolor' attribute to CSS.
3174
3175 Replace most `width' attributes with CSS. The remaining instances
3176 (providing a similar effect as LaTeX's `\hfill' command) are removed
3177 in a later patch.
3178
31792014-11-27 Werner Lemberg <wl@gnu.org>
3180
Werner Lemberga5ad26a2014-11-27 10:52:24 +01003181 * src/tools/docmaker/tohtml.py: Replace <font> with CSS.
3182
31832014-11-27 Werner Lemberg <wl@gnu.org>
3184
Werner Lembergba67c612014-11-27 10:51:49 +01003185 * src/tools/docmaker/tohtml.py: Center <table> with CSS.
3186
31872014-11-27 Werner Lemberg <wl@gnu.org>
3188
Werner Lemberg5594fa52014-11-27 10:50:50 +01003189 * src/tools/docmaker/tohtml.py: Replace `<center>' with `<div>'.
3190
31912014-11-27 Werner Lemberg <wl@gnu.org>
3192
Werner Lemberg8585cf52014-11-27 10:49:05 +01003193 * src/tools/docmaker/tohtml.py: Remove redundant `<center>' tags.
3194
3195 This starts a series of commits into the direction of generating
3196 valid HTML 5 code, especially using much more CSS.
3197
suzuki toshiya1b057042014-11-27 17:53:20 +090031982014-11-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3199
3200 Prevent too negative values (< FT_INT_MIN) in bitmap metrics,
3201 suggested by Alexei.
3202
3203 * src/pfr/pfrsbit.c (pfr_slot_load_bitmap): Prevent too
3204 negative values in `xpos' and `ypos + ysize'.
3205 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Prevent
3206 too negative values in `x_left' and `y_top'. Either negative
3207 values in `width' and `height' are checked.
3208
Werner Lemberg3d167cb2014-11-27 05:19:41 +010032092014-11-27 Werner Lemberg <wl@gnu.org>
3210
Werner Lembergc52882a2014-11-27 08:01:25 +01003211 [docmaker] Produce better HTML code.
3212
3213 * src/tools/docmaker/tohtml.py: Always use double quotes for
3214 attribute values.
3215 (source_footer): Close `td' and `tr' groups.
3216
32172014-11-27 Werner Lemberg <wl@gnu.org>
3218
Werner Lembergdbb93152014-11-27 07:20:48 +01003219 Use better way to disable creation of .pyc files for `make refdoc'.
3220
3221 Python 2.6 was released in 2008...
3222
3223 * builds/freetype.mk (refdoc): Use python's `-B' option.
3224
3225 * builds/detect.mk (std_setup, dos_setup): Mention required python
3226 version for `refdoc' target.
3227
32282014-11-27 Werner Lemberg <wl@gnu.org>
3229
Werner Lemberge8a5c332014-11-27 06:48:37 +01003230 * src/tools/docmaker/sources.py (re_bold, re_italic): Use
3231 non-grouping parentheses.
3232 * src/tools/docmaker/tohtml.py (HtmlFormatter::make_html_word):
3233 Updated.
3234
32352014-11-27 Werner Lemberg <wl@gnu.org>
3236
Werner Lemberg3d167cb2014-11-27 05:19:41 +01003237 * src/base/ftobjs.c (FT_Get_Glyph_Name): Fix compiler warning.
3238
3239 Introdruced in previous change. Reported by Alexei.
3240
Werner Lemberga593a042014-11-26 18:42:48 +010032412014-11-26 Werner Lemberg <wl@gnu.org>
3242
Werner Lembergf34f1922014-11-26 21:59:21 +01003243 * src/*: Add checks for parameters of API functions where missing.
3244
3245 `API functions' are functions tagged with `FT_EXPORT_DEF'.
3246
3247 Besides trivial fixes, the following changes are included, too.
3248
3249 * src/base/ftbdf.c (FT_Get_BDF_Charset_ID, FT_Get_BDF_Property): Set
3250 error code if no service is available.
3251
3252 * src/base/ftinit.c (FT_Done_FreeType): Change return value for
3253 invalid `library' parameter to `Invalid_Library_Handle'.
3254
3255 * src/base/ftobjs.c (FT_New_Size): Change return value for invalid
3256 `asize' parameter to `Invalid_Argument'.
3257
3258 * src/base/ftoutln.c (FT_Outline_Copy): Change return value for
3259 invalid `source' and `target' parameters to `Invalid_Outline'.
3260 (FT_Outline_Done_Internal): Change return value for invalid
3261 `outline' parameter to `Invalid_Outline'.
3262
32632014-11-26 Werner Lemberg <wl@gnu.org>
3264
Werner Lemberga593a042014-11-26 18:42:48 +01003265 * src/cache/ftcbasic.c: Use single calls to `FT_TRACE'.
3266
suzuki toshiya5aff8532014-11-26 14:36:12 +090032672014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3268
suzuki toshiyacd4a5a22014-11-27 00:20:48 +09003269 * src/base/ftobj.c (Mac_Read_POST_Resource): Additional
3270 overflow check in the summation of POST fragment lengths,
3271 suggested by Mateusz Jurczyk <mjurczyk@google.com>.
3272
32732014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3274
suzuki toshiya1720e812014-11-26 16:39:00 +09003275 * src/base/ftobjs.c (Mac_Read_POST_Resource): Insert comments
3276 and fold too long tracing messages.
3277
32782014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3279
suzuki toshiya18a8f0d2014-11-26 16:11:38 +09003280 Fix Savannah bug #43540.
3281
3282 * src/base/ftmac.c (parse_fond): Prevent a buffer overrun
3283 caused by a font including too many (> 63) strings to store
3284 names[] table.
3285
32862014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3287
suzuki toshiya45331672014-11-26 16:02:17 +09003288 * src/base/ftobjs.c (Mac_Read_POST_Resource): Use unsigned long
3289 variables to read the lengths in POST fragments. Suggested by
3290 Mateusz Jurczyk <mjurczyk@google.com>.
3291
32922014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3293
suzuki toshiya35252ae2014-11-26 15:52:23 +09003294 Fix Savannah bug #43539.
3295
3296 * src/base/ftobjs.c (Mac_Read_POST_Resource): Fix integer overflow
3297 by a broken POST table in resource-fork.
3298
32992014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3300
suzuki toshiya240c94a2014-11-26 15:43:29 +09003301 Fix Savannah bug #43538.
3302
3303 * src/base/ftobjs.c (Mac_Read_POST_Resource): Fix integer overflow
3304 by a broken POST table in resource-fork.
3305
33062014-11-26 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
3307
suzuki toshiya5aff8532014-11-26 14:36:12 +09003308 * src/base/ftobjs.c (Mac_Read_POST_Resource): Avoid memory leak
3309 by a broken POST table in resource-fork. Return after freeing
3310 the buffered POST table when it is found to be broken.
3311
Werner Lemberg04edbbd2014-11-25 10:21:13 +010033122014-11-25 Werner Lemberg <wl@gnu.org>
3313
Werner Lemberg02b8e7e2014-11-25 11:31:51 +01003314 */*: s/Invalid_Argument/Invalid_Size_Handle/ where appropriate.
3315
33162014-11-25 Werner Lemberg <wl@gnu.org>
3317
Werner Lemberg0d4aa232014-11-25 11:26:14 +01003318 */*: s/Invalid_Argument/Invalid_Stream_Handle/ where appropriate.
3319
33202014-11-25 Werner Lemberg <wl@gnu.org>
3321
Werner Lembergf4f9e682014-11-25 11:11:55 +01003322 */*: s/Invalid_Argument/Invalid_Library_Handle/ where appropriate.
3323
33242014-11-25 Werner Lemberg <wl@gnu.org>
3325
Werner Lemberg04c2aa12014-11-25 10:22:12 +01003326 */*: s/Invalid_Argument/Invalid_Outline/ where appropriate.
3327
33282014-11-25 Werner Lemberg <wl@gnu.org>
3329
Werner Lemberg04edbbd2014-11-25 10:21:13 +01003330 */*: s/Invalid_Argument/Invalid_Face_Handle/ where appropriate.
3331
Werner Lembergeca0f062014-11-24 10:22:08 +010033322014-11-24 Werner Lemberg <wl@gnu.org>
3333
Werner Lemberg3e867112014-11-25 09:01:07 +01003334 [Savannah bug #43682] Adjust some renderer callbacks.
3335
3336 * src/raster/ftraster.c (ft_black_set_mode): Change return type to
3337 `int' to stay in sync with `FT_Renderer_SetModeFunc' prototype.
3338
3339 * src/smooth/ftgrays.c (gray_raster_set_mode): New dummy function
3340 for orthogonality.
3341 (ft_grays_raster): Use it.
3342
Werner Lemberg04edbbd2014-11-25 10:21:13 +010033432014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lemberg3e867112014-11-25 09:01:07 +01003344
Werner Lemberg6689a002014-11-25 08:53:09 +01003345 [Savannah bug #43682] Properly handle missing return errors.
3346
3347 The functions in this patch *do* return non-trivial errors that must
3348 be taken care of.
3349
3350 * src/autofit/afloader.c (af_loader_load_g), src/base/ftobjs.c
3351 (FT_Render_Glyph_Internal), src/base/ftoutln.c (FT_Outline_Render),
3352 src/cff/cffgload.c (cff_decoder_parse_charstrings) <cff_op_endchar>,
3353 src/psaux/psobjs.c (ps_parser_load_field_table), src/psaux/t1decode
3354 (t1_decoder_parse_charstrings) <op_endchar>, src/truetype/ttgload.c
3355 (load_truetype_glyph <subglyph loop>, tt_loader_init,
3356 TT_Load_Glyph), src/truetype/ttgxvar.c (TT_Set_MM_Blend),
3357 src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Do it.
3358
Werner Lemberg04edbbd2014-11-25 10:21:13 +010033592014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lemberg6689a002014-11-25 08:53:09 +01003360
Werner Lembergb24e8ba2014-11-25 08:30:49 +01003361 [Savannah bug #43682] Add/remove `void' casts to some functions.
3362
3363 We use a cast to indicate that we intentionally ignore a function's
3364 return value. However, this doesn't apply to API functions where
3365 errors can only happen for trivially invalid input.
3366
3367 * src/base/ftstroke.c (FT_Glyph_Stroke, FT_Glyph_StrokeBorder),
3368 src/base/ftsynth.c (FT_GlyphSlot_Embolden), src/cff/cffgload.c
3369 (cff_slot_load), src/pfr/pfrdrivr.c (pfr_get_kerning),
3370 src/type1/t1load.c (parse_encoding), src/type42/t42parse.c
3371 (t42_parse_encoding): Do it.
3372
Werner Lemberg04edbbd2014-11-25 10:21:13 +010033732014-11-25 Werner Lemberg <wl@gnu.org>
Werner Lembergb24e8ba2014-11-25 08:30:49 +01003374
Werner Lembergef439fd2014-11-25 08:14:15 +01003375 [Savannah bug #43682] Change some signatures to `void' return type.
3376
3377 * include/internal/pshints.h (PSH_Globals_SetScaleFunc),
3378 include/internal/sfnt.h (TT_Get_Metrics_Func),
3379 src/pshinter/pshglob.c (psh_globals_set_scale),
3380 src/pshinter/pshrec.c (ps_hints_init), src/sfnt/ttmtx.c
3381 (tt_face_get_metrics), src/truetype/ttinterp.c (TT_Goto_CodeRange,
3382 TT_Set_CodeRange, TT_Clear_CodeRange, TT_Done_Context,
3383 TT_Save_Context): Do it.
3384
3385 * src/pshinter/pshglob.h, src/pshinter/pshrec.h, src/sfnt/ttmtx.h,
3386 src/truetype/ttgload.c (TT_Hint_Glyph), src/truetype/ttinterp.c
3387 (TT_Run_Context), src/truetype/ttinterp.h, src/truetype/ttobjs.c
3388 (tt_size_run_fpgm, tt_size_run_prep): Updated.
3389
33902014-11-24 Werner Lemberg <wl@gnu.org>
3391
Werner Lemberg6889f7b2014-11-24 17:16:08 +01003392 Remove all code related to FT_MAX_CHARMAP_CACHEABLE.
3393
3394 This is no longer used.
3395
3396 * src/base/ftobjs.c, src/cache/ftccmap.c, src/cff/cffobjs.c,
3397 src/sfnt/ttcmap.c: Do it.
3398
33992014-11-24 Werner Lemberg <wl@gnu.org>
3400
Werner Lembergf0292bb2014-11-24 10:51:21 +01003401 [sfnt] Fix Savannah bug #43680.
3402
3403 This adds an additional constraint to make the fix from 2013-01-25
3404 really work.
3405
3406 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_image) <index_format==4>:
3407 Check `p' before `num_glyphs'.
3408
34092014-11-24 Werner Lemberg <wl@gnu.org>
3410
Werner Lembergeca0f062014-11-24 10:22:08 +01003411 [truetype] Fix Savannah bug #43679.
3412
3413 * src/truetype/ttpload.c (tt_face_load_hdmx): Check minimum size of
3414 `record_size'.
3415
Jarkko Pöyry96341dc2014-11-24 09:53:07 +010034162014-11-24 Jarkko Pöyry <jarkko.poyry@gmail.com>
3417
3418 [cff, pfr, psaux, winfonts] Fix Savannah bug #43676.
3419
Werner Lemberged6a9df2014-12-06 23:28:58 +01003420 Don't cast cmap init function pointers to an incompatible type.
Jarkko Pöyry96341dc2014-11-24 09:53:07 +01003421
3422 Without this patch, the number of parameters between declaration and
3423 the real signature differs. Calling such a function results in
3424 undefined behavior.
3425
3426 ISO/IEC 9899:TC3 (Committee Draft September 7, 2007)
3427 6.5.2.2 Function calls
3428 9 If the function is defined with a type that is not
3429 compatible with the type (of the expression) pointed to by
3430 the expression that denotes the called function, the
3431 behavior is undefined.
3432
3433 On certain platforms (c -> js with emscripten) this causes
3434 termination of execution or invalid calls because in the emscripten
3435 implementation, function pointers of different types are stored in
3436 different pointer arrays. Incorrect pointer type here results in
3437 indexing of an incorrect array.
3438
3439 * src/cff/cffcmap.c (cff_cmap_encoding_init, cff_cmap_unicode_init),
3440 src/pfr/pfrcmap.c (pfr_cmap_init), src/psaux/t1cmap.c
3441 t1_cmap_standard_init, t1_cmap_expert_init, t1_cmap_custom_init,
3442 t1_cmap_unicode_init), src/winfonts/winfnt.c (fnt_cmap_init): Fix
3443 signature.
3444
Werner Lemberga7a42072014-11-24 06:44:45 +010034452014-11-24 Werner Lemberg <wl@gnu.org>
3446
Werner Lembergf70d9342014-11-24 09:31:32 +01003447 [sfnt] Fix Savannah bug #43672.
3448
3449 * src/sfnt/ttkern.c (tt_face_load_kern): Use correct value for
3450 minimum table length test.
3451
34522014-11-24 Werner Lemberg <wl@gnu.org>
3453
Werner Lemberg73be9f92014-11-24 07:30:05 +01003454 [type1, type42] Another fix for Savannah bug #43655.
3455
3456 * src/type1/t1load.c (parse_charstrings), src/type42/t42parse.c
3457 (t42_parse_charstrings): Add another boundary testing.
3458
34592014-11-24 Werner Lemberg <wl@gnu.org>
3460
Werner Lemberga7a42072014-11-24 06:44:45 +01003461 [docmaker] Formatting, copyright, improved documentation.
3462
3463 * src/tools/docmaker/*: No code changes besides trivial
3464 modifications.
3465
Werner Lemberg9bd20b72014-11-22 06:24:45 +010034662014-11-22 Werner Lemberg <wl@gnu.org>
3467
Werner Lembergaf834612014-11-22 13:29:10 +01003468 [bdf] Fix Savannah bug #43660.
3469
3470 * src/bdf/bdflib.c (_bdf_parse_glyphs) <"ENDFONT">: Check
3471 `_BDF_GLYPH_BITS'.
3472
34732014-11-22 Werner Lemberg <wl@gnu.org>
3474
Werner Lemberg42fcd662014-11-22 12:44:33 +01003475 [type42] Allow only embedded TrueType fonts.
3476
3477 This is a follow-up to Savannah bug #43659.
3478
3479 * src/type42/t42objs.c (T42_Face_Init): Exclusively use the
3480 `truetype' font driver for loading the font contained in the `sfnts'
3481 array.
3482
34832014-11-22 Werner Lemberg <wl@gnu.org>
3484
Werner Lemberg37881872014-11-22 10:46:47 +01003485 [type42] Fix Savannah bug #43659.
3486
3487 * src/type42/t42objs.c (T42_Open_Face): Initialize `face->ttf_size'.
3488
3489 * src/type42/t42parse.c (t42_parse_sfnts): Always set
3490 `face->ttf_size' directly. This ensures a correct stream size in
3491 the call to `FT_Open_Face', which follows after parsing, even for
3492 buggy input data.
3493 Fix error messages.
3494
34952014-11-22 Werner Lemberg <wl@gnu.org>
3496
Werner Lemberg5f201ab2014-11-22 09:16:39 +01003497 [cff] Fix Savannah bug #43658.
3498
3499 * src/cff/cf2ft.c (cf2_builder_lineTo, cf2_builder_cubeTo): Handle
3500 return values of point allocation routines.
3501
35022014-11-22 Werner Lemberg <wl@gnu.org>
3503
Werner Lemberg9bd20b72014-11-22 06:24:45 +01003504 [sfnt] Fix Savannah bug #43656.
3505
3506 * src/sfnt/ttcmap.c (tt_cmap4_validate): Fix order of validity
3507 tests.
3508
Werner Lemberg6de76172014-11-21 06:05:49 +010035092014-11-21 Werner Lemberg <wl@gnu.org>
3510
Werner Lembergdd897102014-11-21 22:19:28 +01003511 [type1, type42] Fix Savannah bug #43655.
3512
3513 * src/type1/t1load.c (parse_charstrings), src/type42/t42parse.c
3514 (t42_parse_charstrings): Fix boundary testing.
3515
35162014-11-21 Werner Lemberg <wl@gnu.org>
3517
Werner Lembergb1fc00d2014-11-21 12:06:40 +01003518 * src/pcf/pcfread.c (pcf_get_metrics): Sanitize invalid metrics.
3519
35202014-11-21 Werner Lemberg <wl@gnu.org>
3521
Werner Lemberg9154dab2014-11-21 08:03:51 +01003522 [ftlcdfil] Obey flow direction.
3523
3524 * src/base/ftlcdfil.c (_ft_lcd_filter_fir, _ft_lcd_filter_legacy):
3525 Handle `up' flow.
3526
35272014-11-21 Werner Lemberg <wl@gnu.org>
3528
Werner Lemberg644d6fa2014-11-21 07:28:50 +01003529 * src/base/ftbitmap.c (FT_Bitmap_Convert): Improve.
3530
3531 This commit completes argument checks and adds support for different
3532 flow directions.
3533
35342014-11-21 Werner Lemberg <wl@gnu.org>
3535
Werner Lemberg6de76172014-11-21 06:05:49 +01003536 * src/base/ftbitmap.c (FT_Bitmap_Copy): Improve.
3537
3538 This commit adds argument checks and support for different flow
3539 directions.
3540
Werner Lemberg1e6e1b82014-11-20 21:07:56 +010035412014-11-20 Werner Lemberg <wl@gnu.org>
3542
3543 * src/base/ftbitmap.c (FT_Bitmap_New): Check argument.
3544
Werner Lembergd6061212014-11-19 21:13:23 +010035452014-11-19 Werner Lemberg <wl@gnu.org>
3546
Werner Lembergb3500af2014-11-19 21:28:21 +01003547 Change some fields in `FT_Bitmap' to unsigned type.
3548
3549 This doesn't break ABI.
3550
3551 * include/ftimage.h (FT_Bitmap): Make `rows', `width', `num_grays',
3552 `pixel_mode', and `palette_mode' unsigned types.
3553
3554 * src/base/ftbitmap.c: Updated.
3555 (FT_Bitmap_Copy): Fix casts.
3556
3557 * src/cache/ftcsbits.c, src/raster/ftraster.c, src/sfnt/pngshim.c:
3558 Updated.
3559
35602014-11-19 Werner Lemberg <wl@gnu.org>
3561
Werner Lembergdf485772014-11-19 21:21:23 +01003562 Make `FT_Bitmap_Convert' correctly handle negative `pitch' values.
3563
3564 * src/base/ftbitmap.c (FT_Bitmap_Convert): Always use positive value
3565 for the pitch while copying data.
3566 Correctly set pitch sign in target bitmap.
3567
35682014-11-19 Werner Lemberg <wl@gnu.org>
3569
Werner Lembergd6061212014-11-19 21:13:23 +01003570 Minor code improvement in `FT_Bitmap_Embolden'.
3571
3572 * src/base/ftbitmap.c (FT_Bitmap_Embolden) <FT_PIXEL_MODE_GRAY[24]>:
3573 Fix thinko.
3574
Alexei Podtelezhnikovf841ad32014-11-19 21:19:06 -050035752014-11-19 Alexei Podtelezhnikov <apodtele@gmail.com>
3576
3577 * src/base/fttrigon.c: Use dedicated `FT_Angle' for arctan table.
3578
Werner Lemberga67c43e2014-11-19 06:46:23 +010035792014-11-19 Behdad Esfahbod <behdad@behdad.org>
3580
3581 Avoid compiler warnings on x86-64 for `FT_MulFix'.
3582
3583 `FT_MulFix' takes `FT_Long' parameters as defined in `freetype.h',
3584 but several inline implementations of it in `ftcalc.h' take
3585 `FT_Int32' arguments. This is causing compiler warnings on x86-64:
3586 If parameters of type `FT_Fixed' (= `FT_Long') are passed to the
3587 inline implementation of this function, integer values are truncated
3588 from 64bit to 32bit.
3589
3590 * include/internal/ftcalc.h (FT_MulFix) [FT_MULFIX_ASSEMBLER]: Add
3591 casts.
3592
Werner Lemberg54abd222014-11-15 09:05:22 +010035932014-11-15 Werner Lemberg <wl@gnu.org>
3594
3595 [sfnt] Fix Savannah bug #43597.
3596
3597 * src/sfnt/pngshim.c (Load_SBit_Png): Protect against too large
3598 bitmaps.
3599
Werner Lemberg602040b2014-11-12 20:51:20 +010036002014-11-12 Werner Lemberg <wl@gnu.org>
3601
Werner Lemberg257c2702014-11-12 21:42:13 +01003602 [sfnt] Fix Savannah bug #43591.
3603
3604 * src/sfnt/ttsbit.c (tt_sbit_decoder_init): Protect against addition
3605 and multiplication overflow.
3606
36072014-11-12 Werner Lemberg <wl@gnu.org>
3608
Werner Lemberg677ddf42014-11-12 21:26:44 +01003609 [sfnt] Fix Savannah bug #43590.
3610
3611 * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir):
3612 Protect against addition overflow.
3613
36142014-11-12 Werner Lemberg <wl@gnu.org>
3615
Werner Lembergf46add12014-11-12 21:06:08 +01003616 [sfnt] Fix Savannah bug #43589.
3617
3618 * src/sfnt/sfobjs.c (woff_open_font): Protect against addition
3619 overflow.
3620
36212014-11-12 Werner Lemberg <wl@gnu.org>
3622
Werner Lemberg602040b2014-11-12 20:51:20 +01003623 [sfnt] Fix Savannah bug #43588.
3624
3625 * src/sfnt/ttcmap.c (tt_cmap8_validate, tt_cmap10_validate,
3626 tt_cmap12_validate, tt_cmap13_validate, tt_cmap14_validate): Protect
3627 against overflow in additions and multiplications.
3628
Alexei Podtelezhnikov2e73a1b2014-11-09 23:22:43 -050036292014-11-10 Alexei Podtelezhnikov <apodtele@gmail.com>
3630
3631 [base] CORDIC improvements.
3632
3633 The scaling between the hypotenuse and its CORDIC approximation is
3634 based on regression analysis. The smaller padding for `theta' is
3635 justifed by its maximum error of less than 6.
3636
3637 * src/base/fttrigon.c (ft_trig_downscale): Borrow code from
3638 ./ftcalc.c (ft_multo64), change linear intercept.
3639 (ft_trig_pseudo_polarize): Decrease `theta' padding.
3640
Werner Lemberg0e73d212014-11-09 01:27:38 +010036412014-11-09 Werner Lemberg <wl@gnu.org>
3642
3643 * src/base/ftstroke.c (ft_stroker_inside): Fix border intersections.
3644
3645 One more place to check whether `radius' is zero.
3646
3647 Problem reported by Marco Wertz <marco.wertz@gmx.de>.
3648
Werner Lemberg2c4832d2014-11-07 07:42:33 +010036492014-11-07 Werner Lemberg <wl@gnu.org>
3650
Werner Lemberg602040b2014-11-12 20:51:20 +01003651 [bdf] Fix Savannah bug #43535.
Werner Lemberg2c4832d2014-11-07 07:42:33 +01003652
3653 * src/bdf/bdflib.c (_bdf_strncmp): New macro that checks one
3654 character more than `strncmp'.
3655 s/ft_strncmp/_bdf_strncmp/ everywhere.
3656
Werner Lembergf49a1002014-11-06 13:30:28 +010036572014-11-06 Werner Lemberg <wl@gnu.org>
3658
Werner Lemberg602040b2014-11-12 20:51:20 +01003659 [pcf] Fix Savannah bug #43548.
Werner Lembergef1eba72014-11-06 23:25:05 +01003660
Werner Lemberg2c4832d2014-11-07 07:42:33 +01003661 * src/pcf/pcfread.c (pcf_get_encodings): Add sanity checks for row
3662 and column values.
Werner Lembergef1eba72014-11-06 23:25:05 +01003663
36642014-11-06 Werner Lemberg <wl@gnu.org>
3665
Werner Lemberg602040b2014-11-12 20:51:20 +01003666 [pcf] Fix Savannah bug #43547.
Werner Lemberg0e2f5d52014-11-06 22:32:46 +01003667
3668 * src/pcf/pcfread.c (pcf_read_TOC): Check `size' and `offset'
3669 values.
3670
36712014-11-06 Werner Lemberg <wl@gnu.org>
3672
Werner Lembergf49a1002014-11-06 13:30:28 +01003673 * src/pcf/pcfread.c (pcf_read_TOC): Avoid memory leak.
3674
Infinalityfacfc792014-11-03 07:24:59 +010036752014-11-03 Infinality <infinality@infinality.net>
3676
3677 * src/truetype/ttsubpix.c (COMPATIBILITY_MODE_Rules): Updated.
3678
3679 The previous commit deteriorates rendering of DejaVu and similar
3680 fonts; this gets compensated with this rule.
3681
Werner Lemberg706f7522014-11-03 07:20:57 +010036822014-11-03 Werner Lemberg <wl@gnu.org>
3683
3684 * src/truetype/ttinterp.c (Ins_DELTAP): Fix subpixel hinting.
3685
3686 Before this patch, it was impossible to ever call DELTAP[123] in
3687 subpixel hinting mode as described in the ClearType whitepaper; it
3688 only worked if in `compatibility mode'. However, compatibility mode
3689 essentially disables SHPIX, completely ruining hinting of
3690 ttfautohint output, for example.
3691
3692 We now follow the whitepaper more closely so that DELTAP[123]
3693 instructions for touched points in the non-subpixel direction are
3694 executed.
3695
Alexei Podtelezhnikove1efe0a2014-10-31 00:07:14 -040036962014-10-31 Alexei Podtelezhnikov <apodtele@gmail.com>
3697
Alexei Podtelezhnikov525d4872014-10-31 22:12:37 -04003698 [smooth] Improve code readability.
3699
3700 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Rearrange code.
3701
37022014-10-31 Alexei Podtelezhnikov <apodtele@gmail.com>
3703
Alexei Podtelezhnikove1efe0a2014-10-31 00:07:14 -04003704 [smooth] Reduce outline translations during rendering.
3705
3706 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Translate origin
3707 virtually by modifying cbox, actually translate outline if cumulative
3708 shift is not zero.
3709
Alexei Podtelezhnikovc7fd9352014-10-30 22:43:01 -040037102014-10-30 Alexei Podtelezhnikov <apodtele@gmail.com>
3711
3712 [smooth] Fix Savannah bug #35604 (cont'd).
3713
3714 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Remove checks and
3715 casts that became unnecessary after the variable type upgrades.
3716
Alexei Podtelezhnikov74916992014-10-29 22:24:24 -040037172014-10-29 Alexei Podtelezhnikov <apodtele@gmail.com>
3718
Alexei Podtelezhnikov465ab992014-10-29 23:45:23 -04003719 [smooth] Improve code readability.
3720
3721 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Rearrange code.
3722
37232014-10-29 Alexei Podtelezhnikov <apodtele@gmail.com>
3724
Alexei Podtelezhnikov74916992014-10-29 22:24:24 -04003725 Unify hypotenuse approximations.
3726
3727 * include/internal/ftcalc.h (FT_HYPOT): Move macro from here...
3728 * include/internal/ftobjs.h: ... to here, next to required `FT_ABS'.
3729 * src/smooth/ftgrays.c (gray_render_cubic): Use it here.
3730
Werner Lembergfe151522014-10-25 05:56:59 +020037312014-10-25 Werner Lemberg <wl@gnu.org>
3732
3733 [cff] Test valid darkening parameter macros in `ftoption.h'.
3734
3735 We no longer need an otherwise unused typedef that can cause a gcc
3736 warning.
3737 Problem reported by Alexei.
3738
3739 * src/cff/cffobjs.c (cff_driver_init): Use
3740 `CFF_CONFIG_OPTION_DARKENING_PARAMETER_XXX' macros directly.
3741 (SET_DARKENING_PARAMETERS): Removed.
3742 Compile time tests are now ...
3743
3744 * devel/ftoption.h, include/config/ftoption.h: ... here.
3745
Alexei Podtelezhnikovaba0f492014-10-24 23:50:57 -040037462014-10-25 Alexei Podtelezhnikov <apodtele@gmail.com>
3747
3748 Improve flat corner definition.
3749
3750 * include/internal/ftcalc.h (FT_HYPOT): Macro to approximate Euclidean
3751 distance with the alpha max plus beta min algorithm.
3752 * src/base/ftcalc.c (ft_corner_is_flat): Use it instead of Taxicab
3753 metric.
3754
David Weißdd8de1a2014-10-23 20:01:48 +020037552014-10-23 David Weiß <David.Weiss@ptvgroup.com>
3756
3757 [build] Improve property file for vc2010.
3758
3759 User-defined properties should be empty by default to prevent linker
3760 failures.
3761
3762 * builds/windows/vc2010/freetype.user.props,
3763 builds/windows/vc2010/freetype.vcxproj:
3764 s/OptionsDirectory/UserOptionDirectory/.
3765 Comment out all user options.
3766
Werner Lembergdd570e92014-10-23 19:57:37 +020037672014-10-23 Werner Lemberg <wl@gnu.org>
3768
3769 [cff] Work around bug in preprocessor of MSVC 2010.
3770
3771 We have been hit by
3772
3773 https://connect.microsoft.com/VisualStudio/feedback/details/718976/msvc-pr
3774
3775 * devel/ftoption.h, include/config/ftoption.h: Replace
3776 `CFF_CONFIG_OPTION_DARKENING_PARAMETERS' with eight macros
3777 `CFF_CONFIG_OPTION_DARKENING_PARAMETER_{X,Y}{1,2,3,4}'.
3778
3779 * src/cff/cffobjs.c (SET_DARKENING_PARAMETERS): Removed. We no
3780 longer need double expansion.
3781 (SET_DARKENING_PARAMETERS_0): Renamed to ...
3782 (SET_DARKENING_PARAMETERS): ... this.
3783 Update call.
3784
Werner Lembergcc7bb802014-10-20 08:35:50 +020037852014-10-20 Werner Lemberg <wl@gnu.org>
3786
3787 [sbit] Minor fixes.
3788
3789 * src/sfnt/ttsbit.c (tt_face_load_sbit) [TT_SBIT_TABLE_TYPE_SBIX]:
3790 Accept overlay format also, but emit warning message in that case.
3791 (tt_sbit_decoder_load_metrics): Add missing newline to error
3792 message.
3793 (tt_sbit_load_sbix_image): Add `rgbl' graphic type (as used on iOS
3794 7.1) to the list of unsupported formats.
3795
Alexei Podtelezhnikov118e6512014-10-19 23:31:08 -040037962014-10-19 Alexei Podtelezhnikov <apodtele@gmail.com>
3797
3798 [truetype] Clean up bytecode rounding.
3799
3800 Zero distance does not have to be treated specially if you follow
3801 specifications and check the sign as the very last step of rounding.
3802
3803 * src/truetype/ttinterp.c (Round_None, Round_To_Grid,
3804 Round_Down_To_Grid, Round_Up_To_Grid, Round_To_Double_Grid): Use
3805 macros when available, do not check for non-zero distance.
3806 (Round_To_Half_Grid, Round_Super, Round_Super_45): Ditto, return phase
3807 if sign changed.
3808
Alexei Podtelezhnikovd4aabda2014-10-18 10:10:04 -040038092014-10-18 Alexei Podtelezhnikov <apodtele@gmail.com>
3810
3811 [truetype] Unwrap engine compensation settings.
3812
3813 * src/truetype/ttobjs.c (tt_size_init_bytecode): Updated.
3814
David Weißfede19e2014-10-18 14:59:20 +020038152014-10-18 David Weiß <David.Weiss@ptvgroup.com>
3816
3817 [build] Add property file to vc2010 project.
3818
3819 This simplifies custom build configurations, especially for
3820 automated build environments.
3821
3822 * builds/windows/vc2010/freetype.user.props: New configuration file.
3823
3824 * builds/windows/vc2010/freetype.vcxproj: Include
3825 `freetype.user.props' and use its data fields.
3826
3827 * builds/windows/vc2010/index.html: Updated.
3828
Werner Lembergc9c33f22014-10-18 11:01:14 +020038292014-10-18 Werner Lemberg <wl@gnu.org>
3830
3831 [autofit] Add blue-zone support for Telugu.
3832
3833 This essentially moves the Telugu script from the `Indic' hinter to
3834 the `Latin' hinter.
3835
3836 Note that this is a first shot and quite certainly needs
3837 refinements.
3838
3839 * src/autofit/afblue.dat: Add blue zone data for Telugu.
3840
3841 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
3842
3843 * src/autofit/afscript.h: Add Telugu standard characters and move
3844 data out of AF_CONFIG_OPTION_INDIC block.
3845
3846 * src/autofit/afranges.c: Move Telugu data out of
3847 AF_CONFIG_OPTION_INDIC block.
3848
3849 * src/autofit/afstyles.h: Update Telugu data; in particular, use
3850 AF_WRITING_SYSTEM_LATIN.
3851
Werner Lemberg54306f52014-10-18 10:42:28 +020038522014-10-18 David Wimsey <david@wimsey.us>
3853
3854 [cmake] Add iOS build support.
Werner Lemberg1050aa92014-10-18 10:45:09 +02003855 From Savannah patch #8497.
Werner Lemberg54306f52014-10-18 10:42:28 +02003856
3857 * builds/cmake/iOS.cmake: New file. Universal binaries are built
3858 with both 32 and 64 bit arm architectures.
3859
3860 * CMakeLists.txt (IOS_PLATFORM): New variable for running the iOS
3861 toolchain. Possible values are `OS' to build on iOS, or
3862 `SIMULATOR' to build on APPLE.
3863
Werner Lemberg1a1750f2014-10-16 22:54:01 +020038642014-10-16 Behdad Esfahbod <behdad@behdad.org>
3865 Werner Lemberg <wl@gnu.org>
3866
3867 [cff] Add `CFF_CONFIG_OPTION_DARKENING_PARAMETERS' config macro.
3868
3869 * devel/ftoption.h, include/config/ftoption.h
3870 (CFF_CONFIG_OPTION_DARKENING_PARAMETERS): New macro.
3871
3872 * src/cff/cffobjs.c (SET_DARKENING_PARAMETERS,
3873 SET_DARKENING_PARAMETERS_0): New macros.
3874 (cff_driver_init): Use new macros.
3875
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -040038762014-10-14 Alexei Podtelezhnikov <apodtele@gmail.com>
3877
3878 [truetype] Limit delta shift range.
3879
Werner Lembergdf3d67e2014-10-16 07:24:44 +02003880 The valid range for delta shift is zero through six. Negative values
3881 are invalid according to
3882
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -04003883 https://developer.apple.com/fonts/TrueType-Reference-Manual/RM04/Chap4.html#delta%20shift
3884
3885 * src/truetype/ttobjs.h (delta_shift, delta_base): Make unsigned.
Werner Lembergdf3d67e2014-10-16 07:24:44 +02003886 * src/truetype/ttinterp.h (DO_SDS): Throw an error if `delta_shift'
3887 is out of range.
3888 (Ins_DELTAP, Ins_DELTAC): Optimize for valid `delta_shift'.
Alexei Podtelezhnikov7e83f062014-10-14 23:03:56 -04003889
Werner Lemberg03987bf2014-10-16 07:19:46 +020038902014-10-16 Werner Lemberg <wl@gnu.org>
3891
3892 A better fix for Savannah bug #43392.
3893 Suggested by Doug Felt <dougfelt@gmail.com>.
3894
Werner Lembergdf3d67e2014-10-16 07:24:44 +02003895 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics): Set
Werner Lemberg03987bf2014-10-16 07:19:46 +02003896 `vertAdvance' to zero...
3897
3898 * src/truetype/ttgload.c (TT_Load_Glyph): ... and set here a default
3899 value for `vertAdvance' based on `linearVertAdvance' in case
3900 `vertAdvance' is zero. Note that the previous computed ad-hoc value
3901 for `linearVertAdvance' was apparently not tested in a real-life
3902 situation.
3903
David Weiß3889cb22014-10-14 11:35:16 +020039042014-10-14 David Weiß <David.Weiss@ptvgroup.com>
3905
3906 [build] Better optimization settings for vc2010 solution file.
3907
3908 * builds/windows/vc2010/freetype.sln,
3909 builds/windows/vc2010/freetype.vcxproj: Updated.
3910
Werner Lemberg8f178092014-10-14 08:28:09 +020039112014-10-14 Werner Lemberg <wl@gnu.org>
3912
3913 [autofit] Adjust Devenagari character range.
3914
3915 * src/autofit/afranges.c (af_deva_uniranges): Omit characters that
3916 are common to all other Indic scripts.
3917
Werner Lemberg1ca5fa12014-10-12 08:31:32 +020039182014-10-12 Werner Lemberg <wl@gnu.org>
3919
3920 [sfnt] Fix Savannah bug #43392.
3921
3922 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics): Don't let
3923 vertical metrics uninitialized.
3924
Alexei Podtelezhnikov673a28e2014-10-11 14:40:51 -040039252014-10-11 Alexei Podtelezhnikov <apodtele@gmail.com>
3926
3927 [base] Small bbox correction.
3928
3929 * src/base/ftbbox.c (FT_Outline_Get_BBox): Start from nonsense bbox
Werner Lembergdf3d67e2014-10-16 07:24:44 +02003930 instead of initial point that could be `off' in conic outlines.
Alexei Podtelezhnikov673a28e2014-10-11 14:40:51 -04003931
Alexei Podtelezhnikov2ffcf172014-10-08 22:01:08 -040039322014-10-08 Alexei Podtelezhnikov <apodtele@gmail.com>
3933
Alexei Podtelezhnikov40dac112014-10-09 00:58:14 -04003934 [base] Fix Savannah bug #43356.
3935
3936 * src/base/ftbbox.c (BBox_Move_To, BBox_Conic_To): Update bbox in case
Werner Lembergdf3d67e2014-10-16 07:24:44 +02003937 of implicit `to'.
Alexei Podtelezhnikov40dac112014-10-09 00:58:14 -04003938 (BBox_Line_To): New emitter that does not update bbox.
3939
39402014-10-08 Alexei Podtelezhnikov <apodtele@gmail.com>
3941
Alexei Podtelezhnikov2ffcf172014-10-08 22:01:08 -04003942 [base] Introduce and use new macro `FT_UPDATE_BBOX'
3943
3944 * src/base/ftbbox.c (FT_UPDATE_BBOX): New macro.
3945 (FT_Outline_Get_BBox): Use it here.
3946
Alexei Podtelezhnikov7abdb8c2014-10-02 23:13:33 -040039472014-10-02 Alexei Podtelezhnikov <apodtele@gmail.com>
3948
3949 [base] Significant optimization of `ft_div64by32'
3950
3951 We shift as many bits as we can into the high register, perform
3952 32-bit division with modulo there, then work through the remaining
3953 bits with long division. This optimization is especially noticeable
3954 for smaller dividends that barely use the high register.
3955
3956 * src/base/ftcalc.c (ft_div64by32): Updated.
3957
Dave Arnold537c55d2014-10-02 06:32:32 +020039582014-10-02 Dave Arnold <darnold@adobe.com>
3959
3960 [cff] Fix Savannah bug #43271.
3961
3962 * src/cff/cf2font.c (cf2_computeDarkening): Change overflow
3963 detection to use logarithms and clamp `scaledStem'.
3964
Alexei Podtelezhnikov418e18f2014-10-01 22:36:40 -040039652014-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
3966
Alexei Podtelezhnikov74d0aad2014-10-01 23:27:15 -04003967 * src/base/ftcalc.c: Remove miscellaneous type casts.
3968
39692014-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
3970
Alexei Podtelezhnikov418e18f2014-10-01 22:36:40 -04003971 [base] Use more common `FT_MSB' implementation with masks.
3972
3973 * src/base/ftcalc.c (FT_MSB): Updated.
3974
Alexei Podtelezhnikov955aff12014-09-30 23:09:39 -040039752014-09-30 Alexei Podtelezhnikov <apodtele@gmail.com>
3976
3977 [base] Clean up.
3978
3979 * src/base/ftcalc.c (FT_MOVE_SIGN): New macro for frequently used
3980 code.
3981
Alexei Podtelezhnikov7f491112014-09-25 22:54:38 -040039822014-09-25 Alexei Podtelezhnikov <apodtele@gmail.com>
3983
3984 [base] Avoid unnecessary long division.
3985
3986 This applies to `FT_MulDiv' but not to `FT_DivFix', where overflows or
3987 lack thereof are predicted accurately.
3988
3989 * src/base/ftcalc.c (ft_div64by32): Improve readability.
3990 (FT_MulDiv, FT_MulDiv_No_Round) [!FT_LONG64]: Use straight division
3991 when multiplication stayed within 32 bits.
3992
Werner Lemberg5b68e4f2014-09-24 19:06:13 +020039932014-09-24 Werner Lemberg <wl@gnu.org>
3994
3995 [autofit] Minor clean-ups.
3996
3997 * src/autofit/afhints.c (AF_FLAGS): Remove obsolete values.
3998
3999 * src/autofit/afhints.c (af_glyph_hints_dump_points,
4000 af_glyph_hints_align_strong_points): Updated.
4001
4002 * src/autofit/aflatin.c (af_latin_hints_link_segments,
4003 af_latin_hints_compute_segments), src/autofit/afcjk.c
4004 (af_cjk_hints_link_segments), src/autofit/aflatin2.c
4005 (af_latin2_hints_link_segments, af_latin2_hints_compute_segments):
4006 There are no longer fake segments since more than 10 years...
4007
Werner Lemberg387a9fe2014-09-22 06:42:24 +020040082014-09-22 Werner Lemberg <wl@gnu.org>
4009
4010 [autofit] Minor code streamlining.
4011
4012 * src/autofit/afhints.c (af_axis_hints_new_edge): Remove redundant
4013 initialization.
4014
Alexei Podtelezhnikov5c894842014-09-19 22:03:15 -040040152014-09-19 Alexei Podtelezhnikov <apodtele@gmail.com>
4016
4017 * src/base/ftcalc.c: Harmonize code.
4018
40192014-09-15 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04004020
Alexei Podtelezhnikovef070d42014-09-15 22:06:19 -04004021 [base] Tighten the overflow check in `FT_MulDiv'.
4022
4023 * src/base/ftcalc.c (FT_MulDiv) [!FT_LONG64]: Updated.
4024
40252014-09-08 Alexei Podtelezhnikov <apodtele@gmail.com>
4026
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04004027 Fix Savannah bug #43153.
4028
4029 * src/psaux/psconv.c (PS_Conv_ToFixed): Add protection against
Alexei Podtelezhnikov7abdb8c2014-10-02 23:13:33 -04004030 overflow in `divider'.
Alexei Podtelezhnikovbc12d9e2014-09-08 21:27:43 -04004031
Alexei Podtelezhnikov32128522014-09-03 21:57:42 -040040322014-09-03 Alexei Podtelezhnikov <apodtele@gmail.com>
4033
Alexei Podtelezhnikov336735d2014-09-03 22:55:26 -04004034 [base] Tighten the overflow check in `FT_DivFix'.
4035
4036 This fixes a 13-year old bug. The original overflow check should have
4037 been updated when rounding was introduced into this function
4038 (c2cd00443b).
4039
4040 * src/base/ftcalc.c (FT_DivFix) [!FT_LONG64]: Updated.
4041 * include/freetype.h (FT_DivFix): Updated documentation.
4042
40432014-09-03 Alexei Podtelezhnikov <apodtele@gmail.com>
4044
Alexei Podtelezhnikov32128522014-09-03 21:57:42 -04004045 [base] Tighten the overflow check in `FT_MulFix'.
4046
4047 * src/base/ftcalc.c (FT_MulFix) [!FT_LONG64]: Updated.
4048
Alexei Podtelezhnikov125c3ca2014-09-02 22:38:59 -040040492014-09-02 Alexei Podtelezhnikov <apodtele@gmail.com>
4050
4051 [truetype] Shortcut ppem calculations for square pixels.
4052
4053 * src/truetype/ttinterp.h (TT_ExecContextRec): New field
4054 `cur_ppem_func' with a function pointer.
4055 * src/truetype/ttinterp.c (TT_RunIns): Initialize `cur_ppem_func'
4056 depending on the pixel geometry to either...
4057 (Current_Ppem_Stretched): ... this for stretched pixels.
4058 (Current_Ppem): ... or this for square pixels.
4059 (DO_MPPEM, DO_MPS, Ins_DELTAP, Ins_DELTAC): Use `cur_ppem_func'.
4060
Behdad Esfahbod1ec98b22014-08-31 08:47:11 +020040612014-08-31 Behdad Esfahbod <behdad@behdad.org>
4062
4063 Don't use `register' keyword. Fixes compiler warnings.
4064
4065 * src/base/ftcalc.c (FT_Add64) [!FT_LONG64]: Do it.
4066 * src/gzip/inftrees.c (huft_build): Ditto.
4067 * src/truetype/ttinterp.c (TT_MulFix14_arm): Ditto.
4068
Alexei Podtelezhnikova8bc49e2014-08-24 22:14:01 -040040692014-08-24 Alexei Podtelezhnikov <apodtele@gmail.com>
4070
Alexei Podtelezhnikov125c3ca2014-09-02 22:38:59 -04004071 [truetype] Optimize DELTAP and DELTAC.
Alexei Podtelezhnikova8bc49e2014-08-24 22:14:01 -04004072
4073 * src/truetype/ttinterp.c (Ins_DELTAP, Ins_DELTAC): Move ppem
4074 calculations outside of the loop.
4075
Alexei Podtelezhnikov98688592014-08-21 23:28:52 -040040762014-08-21 Alexei Podtelezhnikov <apodtele@gmail.com>
4077
4078 Fix Savannah bug #43033.
4079
4080 * include/config/ftconfig.h, builds/unix/ftconfig.in,
4081 builds/vms/ftconfig.h [FT_LONG64]: Do not disable the macro when
4082 64-bit type is `long'.
4083
Alexei Podtelezhnikov8fd87d42014-08-20 00:57:22 -040040842014-08-20 Alexei Podtelezhnikov <apodtele@gmail.com>
4085
4086 [base] Small optimization of `FT_MulFix'.
4087
4088 * src/base/ftcalc.c (FT_MulFix): Loosen up the condition for direct
4089 32-bit calculations.
4090
Alexei Podtelezhnikovf09326a2014-08-20 00:08:38 -040040912014-08-19 Alexei Podtelezhnikov <apodtele@gmail.com>
4092
4093 [base] Use unsigned calculation in `FT_MulDiv'.
4094
4095 * src/base/ftcalc.c (FT_MulDiv): Updated to expand 32-bit range.
4096
Alexei Podtelezhnikov382f3152014-08-18 23:16:15 -040040972014-08-18 Alexei Podtelezhnikov <apodtele@gmail.com>
4098
4099 [base] Remove truncation in `FT_DivFix'.
4100
4101 * src/base/ftcalc.c (FT_DivFix): Updated.
4102
Alexei Podtelezhnikov5ef20232014-08-14 23:21:46 -040041032014-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
4104
4105 Minor refactoring.
4106
4107 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round): Updated.
4108
41092014-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikovc7022462014-08-14 23:01:01 -04004110
4111 Turn FT_MSB into a macro when using gcc builtins.
4112
4113 * src/base/ftcalc.c, include/internal/ftcalc.h: Updated.
4114
Alexei Podtelezhnikovf8efbcf2014-08-12 23:22:17 -040041152014-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
4116
4117 [base] Avoid undefined FT_MSB in `BBox_Cubic_Check'.
4118
4119 * src/base/ftbbox.c (BBox_Cubic_Check): Update.
4120 (update_cubic_max): Repalce with...
4121 (cubic_peak): ... this, which now handles upscaling.
4122
Alexei Podtelezhnikov47289932014-08-11 23:39:34 -040041232014-08-11 Alexei Podtelezhnikov <apodtele@gmail.com>
4124
Alexei Podtelezhnikov28018d42014-08-12 00:26:16 -04004125 [base] Handle collapsed outlines to avoid undefined FT_MSB.
4126
4127 * src/base/ftoutln.c (FT_Outline_Get_Orientation): Update.
4128
41292014-08-11 Alexei Podtelezhnikov <apodtele@gmail.com>
4130
Alexei Podtelezhnikov47289932014-08-11 23:39:34 -04004131 [base] Restore FT_MulFix inlining.
4132
4133 * include/freetype.h (FT_MulFix): Unconditionally defined.
4134
4135 * src/base/ftcalc.c [FT_MULFIX_ASSEMBLER]: Move code from here...
4136
4137 * include/internal/ftcalc.h [FT_MULFIX_ASSEMBLER]: ... to here,
4138 which conditionally replaces the function with an inline version
4139 through the macro.
4140
Alexei Podtelezhnikov90be4b62014-08-08 22:27:10 -040041412014-08-08 Alexei Podtelezhnikov <apodtele@gmail.com>
4142
4143 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Refactor.
4144
Werner Lembergd17cabf2014-07-26 09:53:50 +090041452014-07-26 Werner Lemberg <wl@gnu.org>
4146
4147 [cff] Fix typo.
4148
4149 * src/cff/cf2hints.c (cf2_glyphpath_computeOffset): Use correct
4150 offsets in third quadrant.
4151
4152 Reported by maks <maksqwe1@ukr.net>.
4153
Werner Lemberg4e754132014-07-17 17:34:49 +090041542014-07-17 Werner Lemberg <wl@gnu.org>
4155
4156 Fix Savannah bug #42788.
4157
4158 * src/pfr/pfrobjs.c: Include `ftcalc.h'.
4159
Alexei Podtelezhnikovc0a6f202014-07-16 22:05:56 -040041602014-07-16 Alexei Podtelezhnikov <apodtele@gmail.com>
4161
4162 Replace `ft_highpow2' function.
4163
4164 * src/pfr/pfrobjs.c (pfr_face_get_kerning): Use `FT_MSB' instead of
4165 `ft_highpow2'.
4166
4167 * src/base/ftutil.c, include/internal/ftobjs.h (ft_highpow2): Remove
4168 it.
4169
Alexei Podtelezhnikov71330ce2014-07-15 23:30:45 -040041702014-07-15 Alexei Podtelezhnikov <apodtele@gmail.com>
4171
Werner Lembergcbbf26b2014-07-17 17:27:12 +09004172 * src/base/ftcalc.c (FT_MSB): Utilize gcc builtins.
Alexei Podtelezhnikov177982e2014-07-15 23:54:34 -04004173
41742014-07-15 Alexei Podtelezhnikov <apodtele@gmail.com>
4175
Alexei Podtelezhnikov71330ce2014-07-15 23:30:45 -04004176 [base] Move assembler code back in the source file.
4177
4178 FT_MulFix assembler used to reside in ftcalc.c before f47d263f1b.
4179
4180 * include/config/ftconfig.h, builds/unix/ftconfig.in,
4181 builds/vms/ftconfig.h [FT_MULFIX_ASSEMBLER]: Move code from here...
4182
4183 * src/base/ftcalc.c [FT_MULFIX_ASSEMBLER]: ... to here.
4184
41852014-07-14 Alexei Podtelezhnikov <apodtele@gmail.com>
Alexei Podtelezhnikov1183cd42014-07-14 22:30:55 -04004186
4187 [base] Further clean up color bitmap conversion.
4188
4189 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Stop
4190 using FT_MulFix and FT_DivFix since all calculations fit into 32 bits.
4191
Werner Lemberg441b3f32014-07-13 02:28:14 +090041922014-07-13 Werner Lemberg <wl@gnu.org>
4193
4194 [truetype] Improve handling of buggy `prep' tables.
4195
4196 In case of an error in the `prep' table, no longer try to execute it
4197 again and again. This makes FreeType handle endless loops in buggy
4198 fonts much faster.
4199
4200 * src/truetype/ttobjs.h (TT_SizeRec): The fields `bytecode_ready'
4201 and `cvt_ready' are now negative if not initialized yet, otherwise
4202 they indicate the error code of the last run.
4203
4204 * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep,
4205 tt_size_done_bytecode, tt_size_init_bytecode,
4206 tt_size_ready_bytecode, tt_size_init, tt_size_done, tt_size_reset):
4207 Updated.
4208
4209 * src/truetype/ttgload.c (tt_loader_init): Updated.
4210 * src/truetype/ttinterp.c (TT_RunIns): Force reexecution of `fpgm'
4211 and `prep' only if we are in the `glyf' table.
4212
Werner Lemberge98e2bc2014-07-12 16:37:39 +090042132014-07-12 Werner Lemberg <wl@gnu.org>
4214
4215 * builds/vms/ftconfig.h: Synchronize.
4216 Problem reported by Alexei.
4217
Alexei Podtelezhnikov35576bf2014-07-11 22:40:34 -040042182014-07-11 Alexei Podtelezhnikov <apodtele@gmail.com>
4219
4220 [base] Clean up bitmap conversion.
4221
4222 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
4223 appropriate FT_DivFix and remove superfluous upscaling.
4224
Alexei Podtelezhnikovceab95a2014-07-04 23:01:32 -040042252014-07-04 Alexei Podtelezhnikov <apodtele@gmail.com>
4226
4227 [base] Small optimization of the ancient code.
4228
4229 * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round): Loosen up the
4230 condition for direct 32-bit calculations.
4231
Werner Lemberg38975562014-06-27 06:55:56 +020042322014-06-27 Werner Lemberg <wl@gnu.org>
4233
4234 Fix Apple standard glyph names.
4235
4236 * src/sfnt/ttpost.c (tt_post_default_names): Synchronize with
4237 `tools/glnames.py'
4238
4239 Problem reported by Adam Twardoch <adam@fontlab.com>.
4240
Werner Lembergcf2347c2014-06-17 09:01:04 +020042412014-06-17 Werner Lemberg <wl@gnu.org>
4242
Werner Lemberg231171f2014-06-17 09:14:32 +02004243 Partially revert commit from 2014-06-13.
4244
4245 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Move
4246 declaration of `p_first' and `p_last' out of the loop.
4247
42482014-06-17 Werner Lemberg <wl@gnu.org>
4249
Werner Lembergcf2347c2014-06-17 09:01:04 +02004250 * builds/unix/freetype2.m4: s/AC_PATH_PROG/AC_PATH_TOOL/.
4251
4252 This simplifies cross-compiling.
4253
Werner Lemberg6497b9c2014-06-13 09:28:00 +020042542014-06-13 Werner Lemberg <wl@gnu.org>
4255
Werner Lemberge5c0fff2014-06-13 14:01:20 +02004256 Fix more compiler warnings.
4257 Reported by Wojciech Mamrak <wmamrak@gmail.com>.
4258
4259 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
4260 Make integer constant unsigned.
4261
4262 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
4263 <TT_SBIT_TABLE_TYPE_SBIX>: Fix types.
4264 (tt_sbit_decoder_load_compound, tt_face_load_sbix_image): Add proper
4265 casts.
4266
42672014-06-13 Werner Lemberg <wl@gnu.org>
4268
Werner Lemberg6497b9c2014-06-13 09:28:00 +02004269 Fix compiler warnings.
4270 Reported by Wojciech Mamrak <wmamrak@gmail.com>.
4271
4272 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage),
Werner Lembergcbbf26b2014-07-17 17:27:12 +09004273 src/autofit/afmodule.c (af_property_set): Fix `signed' vs.
Werner Lemberg6497b9c2014-06-13 09:28:00 +02004274 `unsigned' issues.
4275
4276 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Make compiler
4277 happy.
4278
4279 * src/base/ftlcdfil.c (_ft_lcd_filter_fir): Use only four elements
4280 for `fir'.
4281 Fix `signed' vs. `unsigned' issues.
4282
4283 * src/sfnt/sfobjs.c (WRITE_BYTE): Removed, unused.
4284 (WRITE_USHORT, WRITE_ULONG): Add proper casts.
4285
4286 * src/truetype/ttgload.c (TT_Get_VMetrics): Add proper casts.
4287
4288 * src/truetype/ttinterp.c (Ins_DELTAP): Add proper casts for `B1'
4289 and `B2'.
4290
Alexey Petruchik02f21702014-05-16 08:09:43 +020042912014-05-16 Alexey Petruchik <alexey.petruchik@gmail.com>
4292
4293 [cmake] Add option to build OS X framework.
4294
4295 * CMakeLists.txt: Update accordingly.
4296
4297 * builds/mac/freetype-Info.plist: New file.
4298
Pavel Koshevoy15da66a2014-05-13 07:33:48 +020042992014-05-13 Pavel Koshevoy <pkoshevoy@gmail.com>
4300
4301 * CMakeLists.txt (BASE_SRCS): Add missing `ftbdf.c'.
4302
Werner Lemberg07e7b8a2014-05-11 08:00:25 +020043032014-05-11 Werner Lemberg <wl@gnu.org>
4304
Werner Lembergfaa21472014-05-11 12:44:00 +02004305 [autofit] Fix variable initializations.
4306
4307 * src/autofit/afhints.c (af_glyph_hints_reload): Assign default
4308 values to `in_dir' and `out_dir' for all points.
4309
43102014-05-11 Werner Lemberg <wl@gnu.org>
4311
Werner Lemberg07e7b8a2014-05-11 08:00:25 +02004312 [autofit] Fix crash with font `CabinSketch-Bold.ttf'.
4313
4314 Problem reported by Ralf S. Engelschall <rse@engelschall.com>.
4315
4316 * src/autofit/afhints.c (af_glyph_hints_reload): Fix threshold for
4317 finding first non-near point.
4318 Properly initialize non-near point deltas.
4319
Werner Lemberg63bef9a2014-05-01 07:16:05 +020043202014-05-01 Werner Lemberg <wl@gnu.org>
4321
Werner Lembergc576bb02014-05-01 17:24:19 +02004322 [autofit] Add blue-zone support for Devanagari.
4323
4324 This essentially moves the Devanagari script from the `Indic' hinter
4325 to the `Latin' hinter. Thanks to Girish Dalvi
4326 <girish.dalvi@gmail.com> for guidance with blue zone characters!
4327
4328 * src/autofit/afblue.dat: Add blue zone data for Devanagari.
4329
4330 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4331
4332 * src/autofit/afscript.h: Add Devanagari standard characters and
4333 move data out of AF_CONFIG_OPTION_INDIC block.
4334
4335 * src/autofit/afranges.c: Move Devanagari data out of
4336 AF_CONFIG_OPTION_INDIC block.
4337 Move U+20B9, (new) Rupee sign, from Latin to Devanagari.
4338
4339 * src/autofit/afstyles.h: Update Devanagari data; in particular, use
4340 AF_WRITING_SYSTEM_LATIN.
4341
43422014-05-01 Werner Lemberg <wl@gnu.org>
4343
Werner Lemberg63bef9a2014-05-01 07:16:05 +02004344 [autofit] Fix handling of neutral blue zones in stems.
4345
4346 * src/autofit/afhints.h (AF_Edge_Flags): New value
4347 `AF_EDGE_NEUTRAL'.
4348
4349 * src/autofit/aflatin.c (af_latin_hints_compute_blue_edges): Trace
4350 neutral blue zones with AF_EDGE_NEUTRAL.
4351 (af_latin_hint_edges): Skip neutral blue zones if necessary.
4352
Werner Lembergccfc4b42014-04-28 21:13:14 +020043532014-04-28 Werner Lemberg <wl@gnu.org>
4354
4355 [autofit] Introduce neutral blue zones to the latin module.
4356
4357 Such blue zones match either the top or the bottom of a contour. We
4358 need them for scripts where accent-like elements directly touch the
4359 base character (for example, some vowel signs in Devanagari, cf.
4360 U+0913 or U+0914).
4361
4362 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_NEUTRAL): New
4363 property.
4364
4365 * src/autofit/afblue.h: Regenerated.
4366
4367 * src/autofit/aflatin.h (AF_LATIN_IS_NEUTRAL_BLUE): New macro.
4368 (AF_LATIN_BLUE_NEUTRAL): New enumeration value.
4369
4370 * src/autofit/aflatin.c (af_latin_metrics_init_blues,
4371 af_latin_hints_compute_blue_edges): Handle neutral blue zones.
4372
Werner Lembergabb3fca2014-04-25 22:13:32 +020043732014-04-25 Werner Lemberg <wl@gnu.org>
4374
4375 * src/autofit/hbshim.c: Partially revert commit from 2014-04-17.
4376
4377 Using input glyph coverage data is simply wrong.
4378
4379 Problem reported by Nikolaus Waxweiler <madigens@gmail.com> and
4380 Mantas MikulÄ—nas <grawity@gmail.com>.
4381
Werner Lembergf1936372014-04-23 08:22:33 +020043822014-04-23 Werner Lemberg <wl@gnu.org>
4383
4384 * src/raster/ftraster.c (Vertical_Sweep_Span): Use drop-out mode.
4385
4386 This spot has been missed while introducing support for various
4387 drop-out modes years ago (including no drop-out mode, which this
4388 commit fixes).
4389
4390 Problem reported by Patrick Thomas <pthomas505@gmail.com>.
4391
Werner Lembergd9b44702014-04-22 07:33:07 +020043922014-04-22 Werner Lemberg <wl@gnu.org>
4393
4394 * src/sfnt/pngshim.c (error_callback): s/longjmp/ft_longjmp/.
4395
Werner Lemberg98e510e2014-04-20 22:11:27 +020043962014-04-20 Werner Lemberg <wl@gnu.org>
4397
4398 [autofit] Fix Savannah bug #42148.
4399
4400 The adaptation of the cjk auto-hinter module to blue stringsets in
4401 2013-08-25 had three severe bugs. Mea culpa.
4402
4403 1. Contrary to the latin auto-hinter, characters for reference and
4404 overshoot values of a blue zone are specified separately. Due to
4405 the screwed-up change it didn't work at all.
4406
4407 2. A boolean comparison was erroneously replaced with a cast,
4408 causing invalid results with the `^' operator later on. The
4409 visual artifact caused by this problem is the topic of the bug
4410 report.
4411
4412 3. Two flag values were inverted, causing incorrect assignment of
4413 reference and overshoot values.
4414
4415 * src/autofit/afblue.dat: Fix CJK bluestrings, introducing a new
4416 syntax to have both reference and overshoot characters in a single
4417 string. This is error #1.
4418 Add extensive comments.
4419
4420 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_CJK_FILL): Removed, no
4421 longer used.
Werner Lembergccfc4b42014-04-28 21:13:14 +02004422 (AF_BLUE_PROPERTY_CJK_TOP, AF_BLUE_PROPERTY_CJK_HORIZ): Fix values.
Werner Lemberg98e510e2014-04-20 22:11:27 +02004423 This is error #3.
4424
4425 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
4426
4427 * src/autofit/afcjk.c (af_cjk_metrics_init_blues): Correct error #1.
4428 Use character `|' to separate characters for reference and overshoot
4429 values.
4430 Improve tracing messages, synchronizing them with the latin
4431 auto-hinter.
Werner Lembergccfc4b42014-04-28 21:13:14 +02004432 (af_cjk_hints_compute_blue_edges): Fix value of `is_top_right_blue'.
Werner Lemberg98e510e2014-04-20 22:11:27 +02004433 This is error #2.
4434 (af_cjk_align_linked_edge): Add tracing message.
4435
4436 * src/autofit/afcjk.h (AF_CJK_IS_FILLED_BLUE): Removed, no longer
4437 used.
4438
Werner Lembergbbd83132014-04-17 01:24:36 +020044392014-04-17 Werner Lemberg <wl@gnu.org>
4440
Werner Lemberg8c7fb782014-04-17 15:53:25 +02004441 [autofit] More coverage fixes for complex scripts.
4442
4443 * src/autofit/hbshim.c (af_get_coverage): Merge input glyph coverage
4444 of GSUB lookups into output coverage. Otherwise, ligatures are not
4445 handled properly.
4446 Don't check blue zone characters for default coverage.
4447
44482014-04-17 Werner Lemberg <wl@gnu.org>
4449
Werner Lembergbbd83132014-04-17 01:24:36 +02004450 Make `FT_Get_SubGlyph_Info' actually work.
4451
4452 * src/base/ftobjs.c (FT_Get_SubGlyph_Info): Return FT_Err_Ok
4453 if there is no error.
4454
Werner Lemberg181fd072014-04-15 16:47:05 +020044552014-04-15 Werner Lemberg <wl@gnu.org>
4456
4457 [afblue.pl]: Minor improvements.
4458
4459 * src/tools/afblue.pl: Allow whitespace before comments.
4460 Ignore whitespace in strings.
4461
Werner Lemberg8b1f2a62014-04-14 07:58:19 +020044622014-04-14 Werner Lemberg <wl@gnu.org>
4463
4464 [autofit] Improve coverage handling.
4465
4466 * src/autofit/hbshim.c (af_get_coverage): Don't exclude glyphs
4467 appearing in the GPOS table if we are processing the default
4468 coverage.
4469
David Weber76307872014-04-13 15:41:13 +020044702014-04-13 David Weber <weber.aulendorf@googlemail.com>
4471
4472 [smooth] Fix stand-alone compilation.
4473
4474 * src/smooth/ftgrays.c (FT_BEGIN_STMNT, FT_END_STMNT): Define.
4475
Werner Lemberg8a94b1e2014-04-12 20:44:33 +020044762014-04-12 Werner Lemberg <wl@gnu.org>
4477
4478 [autofit] Redesign the recognition algorithm of strong points.
4479
4480 In particular, local extrema without horizontal or vertical segments
4481 are better recognized:
4482
4483 + A + D
4484 \ /
4485 \ /
4486 \ /
4487 \ /
4488 \ + C
4489 \ /
4490 B +/
4491
4492 If the distances AB and CD are large, point B wasn't previously
4493 detected as an extremum since the `ft_corner_is_flat' function
4494 `swallowed' BC regardless of its direction, tagging point B as weak.
4495 The next iteration started at B and made `ft_corner_is_flat' swallow
4496 point C, tagging it as weak also, et voilà.
4497
4498 To improve that, another pass gets now performed before calling
4499 `ft_corner_is_flat' to improve the `topology' of an outline: A
4500 sequence of non-horizontal or non-vertical vectors that point into
4501 the same quadrant are handled as a single, large vector.
4502
4503 Additionally, distances of near points are now accumulated, which
4504 makes the auto-hinter handle them as if they were prepended to the
4505 next non-near vector.
4506
4507 This generally improves the auto-hinter's rendering results.
4508
4509 * src/autofit/afhints.c (af_glyph_hints_reload): Implement it.
4510
4511 * src/autofit/afhints.h (AF_FLAGS): Remove no longer used flag
4512 `AF_FLAG_NEAR'.
4513
Werner Lemberg71f53e12014-04-05 16:27:19 +020045142014-04-05 Werner Lemberg <wl@gnu.org>
4515
4516 [autofit] Improve scoring algorithm for identifying stems.
4517
4518 Problem reported by Karsten Lücke <karsten.luecke@kltf.de>.
4519
4520 The new algorithm takes care of the width of stems: If the distance
4521 between two segments is larger than the largest stem width, the
4522 demerits quickly increase for larger distances. This improves
4523 hinting of slanted fonts (especially if the inner parts of serifs
4524 have non-horizontal `shoulders'), avoiding false stem links.
4525
4526 * src/autofit/aflatin.c (af_latin_hints_link_segments): Use largest
4527 stem width (if available) to compute better demerits for distances
4528 between stems.
4529 (af_latin_hints_detect_features): Pass stem width array and array
4530 size.
4531 (af_latin_metrics_init_widths): Updated to use original algorithm.
4532 (af_latin_hints_apply): Updated to use new algorithm.
4533
4534 * src/autofit/aflatin.h: Updated.
4535 * src/autofit/afcjk.c: Updated.
4536
Werner Lembergf8555b52014-04-03 05:45:38 +020045372014-04-03 Werner Lemberg <wl@gnu.org>
4538
4539 Don't require `gzip' module for `sfnt'.
4540
4541 Reported by Preet <prismatic.project@gmail.com>.
4542
4543 * src/sfnt/sfobjs.c (woff_open_font): Guard use of
4544 FT_Gzip_Uncompress with FT_CONFIG_OPTION_USE_ZLIB.
4545
Werner Lembergf41070f2014-03-27 17:38:23 +010045462014-03-27 Werner Lemberg <wl@gnu.org>
4547
4548 Fix Savannah bug #38235.
4549
4550 Work around a bug in pkg-config version 0.28 and earlier: If a
4551 variable value gets surrounded by doublequotes (in particular values
4552 for the `prefix' variable), the prefix override mechanism fails.
4553
4554 * builds/unix/freetype2.in: Don't use doublequotes.
4555 * builds/unix/unix-def.in (freetype.pc): Escape spaces in directory
4556 names with backslashes.
4557
Werner Lembergab76d972014-03-24 19:45:03 +010045582014-03-24 Werner Lemberg <wl@gnu.org>
4559
4560 Fix Savannah bug #41946.
4561
4562 Based on a patch from Marek Kašík <mkasik@redhat.com>.
4563
4564 * builds/unix/configure.raw (LIBS_CONFIG): Remove.
4565 * builds/unix/freetype-config.in (libs): Hard-code value.
4566 * builds/unix/unix-def.in: Updated.
4567
Werner Lembergd5159922014-03-22 06:20:54 +010045682014-03-22 Werner Lemberg <wl@gnu.org>
4569
4570 Another revert for the change from 2014-03-18.
4571
4572 Problem reported by Nikolaus Waxweiler <madigens@gmail.com>.
4573
4574 * src/base/ftcalc.c (FT_MulFix): Ensure that an `FT_MulFix' symbol
4575 gets always exported.
4576
Werner Lembergf0c471a2014-03-20 07:13:12 +010045772014-03-20 Werner Lemberg <wl@gnu.org>
4578
4579 CMakeLists.txt: Another fix for include directories.
4580
4581 Problem reported by Taylor Holberton <taylorcholberton@gmail.com>.
4582
Werner Lembergcc7cf2c2014-03-19 07:35:35 +010045832014-03-19 Werner Lemberg <wl@gnu.org>
4584
Werner Lemberg606c74f2014-03-19 23:46:42 +01004585 CMakeLists.txt: Fix include directories.
4586
4587 Problem reported by Taylor Holberton <taylorcholberton@gmail.com>.
4588
45892014-03-19 Werner Lemberg <wl@gnu.org>
4590
Werner Lembergcc7cf2c2014-03-19 07:35:35 +01004591 Partially revert last commit.
4592
4593 Found by Alexei.
4594
4595 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Initializing
4596 those variables is plain wrong, since we are in a loop.
4597
Sean McBride87628722014-03-18 08:39:35 +010045982014-03-18 Sean McBride <sean@rogue-research.com>
4599 Werner Lemberg <wl@gnu.org>
4600
4601 Fix clang warnings.
4602
4603 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Initialize
4604 some variables.
4605
4606 * src/base/ftcalc.c (FT_MulFix): Only use code if
4607 `FT_MULFIX_INLINED' is not defined.
4608
4609 * src/bdf/bdfdrivr.c (bdf_cmap_class), src/cache/ftcbasic.c
4610 (ftc_basic_image_family_class, ftc_basic_image_cache_class,
4611 ftc_basic_sbit_family_class, ftc_basic_sbit_cache_class),
4612 src/cache/ftccmap.c (ftc_cmap_cache_class), src/cache/ftcmanag.c
4613 (ftc_size_list_class, ftc_face_list_class), src/pcf/pcfdrivr.c
4614 (pcf_cmap_class), src/pfr/pfrdrivr.c (pfr_metrics_service_rec): Make
4615 function static.
4616
4617 * src/type1/t1driver.c (t1_ps_get_font_value): Remove redundant
4618 code.
4619
Werner Lemberg23367ff2014-03-17 07:33:14 +010046202014-03-17 Werner Lemberg <wl@gnu.org>
4621
4622 Fix Savannah bug #41869.
4623
4624 This works around a problem with HarfBuzz (<= 0.9.26), which doesn't
4625 validate glyph indices returned by
4626 `hb_ot_layout_lookup_collect_glyphs'.
4627
4628 * src/autofit/hbshim.c (af_get_coverage): Guard `idx'.
4629
4630 * docs/CHANGES: Updated.
4631
Werner Lemberg03181682014-03-14 08:06:06 +010046322014-03-14 Werner Lemberg <wl@gnu.org>
4633
4634 * builds/unix/configure.raw: Don't show error messages of `which'.
4635
Alan Coopersmithed372b72014-03-09 06:14:12 +010046362014-03-09 Alan Coopersmith <alan.coopersmith@oracle.com>
4637
4638 Fix cppcheck 1.64 warning.
4639
4640 * src/autofit/afglobal.c (af_face_globals_new): Catch NULL pointer
4641 dereference in case of error.
4642
Werner Lemberg1a69dc72014-03-09 06:06:58 +010046432014-03-09 Sean McBride <sean@rogue-research.com>
4644
4645 * src/sfnt/ttcmap.c (tt_face_build_cmaps): Remove clang warning.
4646
Werner Lemberg05565362014-03-06 18:56:58 +010046472014-03-06 Werner Lemberg <wl@gnu.org>
4648
Werner Lembergec8853c2014-03-06 19:13:45 +01004649 * Version 2.5.3 released.
4650 =========================
4651
4652
4653 Tag sources with `VER-2-5-3'.
4654
4655 * docs/VERSION.DLL: Update documentation and bump version number to
4656 2.5.3.
4657
4658 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
4659 builds/windows/vc2005/index.html,
4660 builds/windows/vc2008/freetype.vcproj,
4661 builds/windows/vc2008/index.html,
4662 builds/windows/vc2010/freetype.vcxproj,
4663 builds/windows/vc2010/index.html,
4664 builds/windows/visualc/freetype.dsp,
4665 builds/windows/visualc/freetype.vcproj,
4666 builds/windows/visualc/index.html,
4667 builds/windows/visualce/freetype.dsp,
4668 builds/windows/visualce/freetype.vcproj,
4669 builds/windows/visualce/index.html,
4670 builds/wince/vc2005-ce/freetype.vcproj,
4671 builds/wince/vc2005-ce/index.html,
4672 builds/wince/vc2008-ce/freetype.vcproj,
4673 builds/wince/vc2008-ce/index.html: s/2.5.2/2.5.3/, s/252/253/.
4674
4675 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 3.
4676
4677 * builds/unix/configure.raw (version_info): Set to 17:2:11.
4678 * CMakeLists.txt (VERSION_PATCH): Set to 3.
4679 * docs/CHANGES: Updated.
4680
46812014-03-06 Werner Lemberg <wl@gnu.org>
4682
Werner Lemberg05565362014-03-06 18:56:58 +01004683 Fixes for compilation with C++.
4684
4685 * src/autofit/hbshim.c (scripts): Change type to `hb_script_t'.
4686 (af_get_coverage): Updated.
4687 (COVERAGE): Add cast.
4688
Sean McBrideb24e8d32014-03-06 14:54:22 +010046892014-03-06 Sean McBride <sean@rogue-research.com>
4690
4691 Remove more clang analyzer warnings.
4692
4693 * src/bdf/bdflib.c (_bdf_readstream), src/truetype/ttgload.c
4694 (TT_Load_Glyph): Remove dead stores.
4695
Werner Lemberga32758f2014-03-05 08:02:46 +010046962014-03-05 Werner Lemberg <wl@gnu.org>
4697
4698 * builds/unix/configure.raw: Simplify.
4699
suzuki toshiya382f3ef2014-03-05 10:19:15 +090047002014-03-05 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4701
4702 Fix a bug in configure in library dependency setting
Werner Lemberga32758f2014-03-05 08:02:46 +01004703 Reported in https://bugs.freedesktop.org/show_bug.cgi?id=75652.
suzuki toshiya382f3ef2014-03-05 10:19:15 +09004704
4705 * builds/unix/configure.raw: Use `x"${xxx}" != xno' style.
4706
Werner Lembergf48f7dc2014-03-04 04:40:07 +010047072014-03-04 Werner Lemberg <wl@gnu.org>
4708
4709 Minor fix for `make devel'.
4710
4711 * builds/freetype.mk (INCLUDE_FLAGS) [DEVEL_DIR]: Don't use
4712 pkg-config for bzip2 since not all GNU/Linux distributions have
4713 `bzip2.pc' (and the header file `bzlib.h' is located in /usr/include
4714 normally).
4715
Werner Lemberg7ac76b52014-03-04 04:29:17 +010047162014-03-04 Sean McBride <sean@rogue-research.com>
4717
4718 Fix several clang static analyzer dead store warnings.
4719
4720 * src/autofit/afhints.c (af_glyph_hints_reload,
4721 af_glyph_hints_align_weak_points): Remove unnecessary assignments.
4722
4723 * src/bdf/bdflib.c (bdf_font_load): Ditto.
4724
4725 * src/pshinter/pshalgo.c (psh_glyph_compute_extrema,
4726 psh_glyph_interpolate_other_points): Ditto.
4727
4728 * src/type1/t1load.c (T1_Set_MM_Blend): Ditto.
4729
Werner Lemberg93ebcbd2014-03-03 07:13:45 +010047302014-03-03 Werner Lemberg <wl@gnu.org>
4731
4732 Rewrite library option handling in `configure'.
4733
4734 o Introduce `auto' value for `--with-XXX' library options; this is
4735 now the default.
4736
4737 o First use `pkg-config' for library detection, then fall back to
4738 other tests.
4739
4740 * builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
4741 --with-harfbuzz): Rewrite.
4742 Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
4743 variables to collect data for `freetype2.pc' and `freetype-config'.
4744 (FT2_EXTRA_LIBS): Renamed to ...
4745 (ft2_extra_libs): This since it gets no longer substituted.
4746 (REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
4747 New output variables, replacing `XXX_PKG' and `LIBXXX'.
4748 Add notice at the end of `configure' showing the library
4749 configuration.
4750
4751 * builds/unix/freetype-config.in (--static): New command line
4752 option.
4753 (libs): Updated.
4754 (staticlibs): New variable, to be used if `--static' is given.
Werner Lemberg8fa69a82014-12-03 20:07:14 +01004755 * docs/freetype-config.1: Document `--static'.
Werner Lemberg93ebcbd2014-03-03 07:13:45 +01004756
4757 * builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
4758
Werner Lemberg86026a42014-03-01 06:57:19 +010047592014-03-01 Werner Lemberg <wl@gnu.org>
4760
Werner Lemberge962a912014-03-01 21:00:02 +01004761 Avoid `long long' warnings with older gcc compilers.
4762 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
4763
4764 * builds/unix/configure.raw: Don't use gcc's `-pedantic' flag for
4765 versions < 4.6. This is especially needed for Max OS X since this
4766 OS runs a gcc variant (or emulation) based on version 4.2.1.
4767
47682014-03-01 Werner Lemberg <wl@gnu.org>
4769
Werner Lemberg6030a9f2014-03-01 14:01:12 +01004770 * docs/INSTALL.CROSS: Revised and updated.
4771
47722014-03-01 Werner Lemberg <wl@gnu.org>
4773
Werner Lemberg646db052014-03-01 12:48:07 +01004774 Make `make clean' remove `freetype2.pc'.
4775
4776 This is a generated file at build time, not configure time.
4777
4778 * builds/unix/unix-def.in (DISTCLEAN): Move `freetype2.pc' to ...
4779 (CLEAN): This variable.
4780
47812014-03-01 Werner Lemberg <wl@gnu.org>
4782
Werner Lemberg00c79ed2014-03-01 12:32:20 +01004783 Use pkg-config for detecting libpng and libbz2 also.
4784
4785 * builds/unix/configure.raw (HAVE_PKG): New variable.
4786 Search for libbz2 using `pkg-config'; s/BZ2/BZIP2/.
4787 Search for libpng using `pkg-config'.
4788 Fix definition of `LIBHARFBUZZ' variable.
4789 * builds/unix/freetype-config.in ($libs): Updated.
4790 * builds/unix/freetype2.in: Add `URL' field.
4791 Update `Requires.private' and `Libs.private'.
4792 * builds/unix/unix-def.in: Updated.
4793
47942014-03-01 Werner Lemberg <wl@gnu.org>
4795
Werner Lemberg86026a42014-03-01 06:57:19 +01004796 Add configure support for HarfBuzz.
4797
4798 * builds/unix/pkg.m4: New file.
4799 * builds/unix/configure.raw: Search for libharfbuzz using
4800 `pkg-config'.
4801 Add `--without-harfbuzz' option.
4802 * builds/unix/freetype-config.in, builds/unix/freetype2.in,
4803 builds/unix/unix-def.in (freetype-config, freetype2.pc): Handle
4804 HarfBuzz.
4805
4806 * docs/INSTALL.UNIX: Document interdependency of Freetype with
4807 HarfBuzz.
4808
Alexei Podtelezhnikov6adda682014-02-28 09:24:26 +010048092014-02-28 Alexei Podtelezhnikov <apodtele@gmail.com>
4810
4811 [cff] Math simplifications.
4812
4813 * src/cf2blues.c (cf2_blues_init): Use `FT_MulDiv'.
4814 * src/cf2ft.c (cf2_getScaleAndHintFlag): Use simple division.
4815
Dave Arnold0eae6eb2014-02-28 07:40:01 +010048162014-02-28 Dave Arnold <darnold@adobe.com>
4817
Dave Arnold135c3fa2014-02-28 07:42:42 +01004818 [cff] Fix Savannah bug #41697, part 2.
4819
4820 * src/cff/cf2ft.c (cf2_initLocalRegionBuffer,
4821 cf2_initGlobalRegionBuffer): It is possible for a charstring to call
4822 a subroutine if no subroutines exist. This is an error but should
4823 not trigger an assert. Split the assert to account for this.
4824
48252014-02-28 Dave Arnold <darnold@adobe.com>
4826
Dave Arnold0eae6eb2014-02-28 07:40:01 +01004827 [cff] Fix Savannah bug #41697, part 1.
4828
4829 * src/cff/cf2hints.c (cf2_hintmap_build): Return when `hintMask' is
4830 invalid. In this case, it is not safe to use the length of
4831 `hStemHintArray'; the exception has already been recorded in
4832 `hintMask'.
4833
Werner Lembergeee4ff82014-02-26 18:12:36 +010048342014-02-26 Werner Lemberg <wl@gnu.org>
4835
Werner Lemberga2b5f662014-02-26 19:50:18 +01004836 [sfnt] Fix Savannah bug #41696.
4837
4838 * src/sfnt/ttcmap.c (tt_cmap0_validate, tt_cmap2_validate,
4839 tt_cmap4_validate, tt_cmap14_validate): Fix limit tests.
4840
48412014-02-26 Werner Lemberg <wl@gnu.org>
4842
Werner Lembergeee4ff82014-02-26 18:12:36 +01004843 [winfnt] Fix Savannah bug #41694.
4844
4845 * src/winfonts/winfnt.c (FNT_Load_Glyph): Check glyph offset.
4846
48472014-02-26 Werner Lemberg <wl@gnu.org>
Werner Lemberg9a567642014-02-26 13:08:07 +01004848
Werner Lemberg08c628d2014-02-26 14:18:03 +01004849 [cff] Fix Savannah bug #41693.
4850
4851 * src/cff/cffload.c (CFF_Load_FD_Select): Reject empty array.
4852
Werner Lembergeee4ff82014-02-26 18:12:36 +010048532014-02-26 Werner Lemberg <wl@gnu.org>
Werner Lemberg08c628d2014-02-26 14:18:03 +01004854
Werner Lemberg9a567642014-02-26 13:08:07 +01004855 [bdf] Fix Savannah bug #41692.
4856
4857 bdflib puts data from the input stream into a buffer in chunks of
4858 1024 bytes. The data itself gets then parsed line by line, simply
4859 increasing the current pointer into the buffer; if the search for
4860 the final newline character exceeds the buffer size, more data gets
4861 read.
4862
4863 However, in case the current line's end is very near to the buffer
4864 end, and the keyword to compare with is longer than the current
4865 line's length, an out-of-bounds read might happen since `memcmp'
4866 doesn't stop properly at the string end.
4867
4868 * src/bdf/bdflib.c: s/ft_memcmp/ft_strncmp/ to make comparisons
4869 stop at string ends.
4870
suzuki toshiya91c7a972014-02-17 16:38:31 +090048712014-02-17 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
4872
4873 [autofit] Fix `make multi' compilation.
4874
suzuki toshiyacc9a0c22014-02-17 16:43:54 +09004875 * src/autofit/hbshim.c: Include `afglobal.h' and `aftypes.h'.
suzuki toshiya91c7a972014-02-17 16:38:31 +09004876
Werner Lemberg6b290fd2014-02-19 09:26:54 +010048772014-02-19 Werner Lemberg <wl@gnu.org>
4878 Simon Bünzli <zeniko@gmail.com>
4879
4880 Fix Savannah bug #32902.
4881
4882 Patch taken from
4883
4884 https://code.google.com/p/sumatrapdf/source/browse/trunk/ext/_patches/freetype2.patch?spec=svn8620&r=8620#87
4885
4886 with slight modifications.
4887
4888 * src/type1/t1parse.c (T1_Get_Private_Dict): Add heuristic test to
4889 handle fonts that incorrectly use \r at the beginning of an eexec
4890 block.
4891
Simon Bünzlidf14e6c2014-02-19 08:42:52 +010048922014-02-19 Simon Bünzli <zeniko@gmail.com>
4893
4894 Fix Savannah bug #41590.
4895
4896 * src/type1/t1load.c (parse_encoding): Protect against invalid
4897 number.
4898
Dave Arnold89a94d42014-02-12 23:45:47 +010048992014-02-12 Dave Arnold <darnold@adobe.com>
4900
4901 [cff] Optimize by using `FT_MulDiv'.
4902 Suggested by Alexei.
4903
4904 * src/cff/cf2font.c (cf2_computeDarkening): Do it.
4905
Werner Lemberg85ee27a2014-02-12 23:27:41 +010049062014-02-12 Werner Lemberg <wl@gnu.org>
4907
4908 Fix Savannah bug #41465.
4909
4910 * builds/unix/unix-def.in (CLEAN): Add `freetype-config'.
4911 (DISTCLEAN): Remove `freetype-config'.
4912
Sean McBride7be2a942014-02-08 13:55:38 +010049132014-02-08 Sean McBride <sean@rogue-research.com>
4914
4915 Fix clang static analyzer and compiler warnings.
4916
4917 * src/autofit/afhints.c (af_glyph_hints_align_weak_points),
4918 src/autofit/afloader (af_loader_load_g) <FT_GLYPH_FORMAT_COMPOSITE>,
4919 src/base/ftcalc.c (FT_MSB), src/base/ftoutln.c
4920 (FT_Outline_Decompose), src/bdf/bdfdrivr.c (bdf_interpret_style),
4921 src/cff/cffparse.c (cff_parse_integer), src/cid/cidparse.c
4922 (cid_parser_new), src/pfr/pfrload.c (pfr_phy_font_load),
4923 src/raster/ftraster.c (Decompose_Curve), src/sfnt/sfdriver.c
4924 (sfnt_get_ps_name), src/sfnt/ttcmap.c (tt_cmap12_next,
4925 tt_cmap13_next), src/smooth/ftgrays.c (gray_hline): Remove dead
4926 code.
4927
4928 * src/autofit/afmodule.c (af_property_get_face_globals,
4929 af_property_set, af_property_get), src/base/ftbitmap.c
4930 (ft_gray_for_premultiplied_srgb_bgra): Make functions static.
4931
4932 * src/base/ftobjs.c (ft_remove_renderer): Protect against
4933 library == NULL.
4934 (ft_property_do): Make function static.
4935
4936 * src/base/ftrfork.c: Include `ftbase.h'.
4937
4938 * src/sfnt/ttsbit.c (tt_face_load_sbix_image)
4939 [!FT_CONFIG_OPTION_USE_PNG], src/type1/t1gload.c
4940 (T1_Compute_Max_Advance): Avoid compiler warning.
4941
4942 * src/truetype/ttinterp.c (TT_New_Context): Reduce scope of
4943 variable.
4944
Werner Lembergab98c5e2014-02-08 11:34:33 +010049452014-02-08 Werner Lemberg <wl@gnu.org>
4946
4947 Fix Windows build directories.
4948
4949 The build target is now `windows' instead of `win32'.
4950
4951 Problem reported by Nickolas George <darknova.clan@gmail.com>.
4952
4953 * builds/modules.mk: Don't use `win32' and `win16' (!) but
4954 `windows'.
4955
4956 * builds/windows/detect.mk, builds/windows/win32-def.mk:
4957 s/win32/windows/.
4958
Eugen Sawina8ceae42014-02-08 06:30:06 +010049592014-02-08 Eugen Sawin <esawin@mozilla.com>
4960
4961 Fix Savannah bug #41507.
4962
4963 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap)
4964 [!FT_CONFIG_OPTION_USE_PNG] <17, 17, 19>: Fix error handling.
4965
Dave Arnold355b3592014-02-08 06:23:04 +010049662014-02-08 Dave Arnold <darnold@adobe.com>
4967
4968 [cff] Fix minor performance bug.
4969
4970 * src/cff/cf2font.c (cf2_font_setup): Darkening amount and blue zone
4971 calculations are now cached and not recomputed on each glyph.
4972
Werner Lemberg6dce1362014-02-05 15:40:47 +010049732014-02-05 Werner Lemberg <wl@gnu.org>
4974
4975 Fix problems with perl 5.8.8 as distributed with current MinGW.
4976
4977 * src/tools/afblue.pl: Work-around for Perl bug #63402.
4978 (string_re): Avoid `possessive quantifiers', which have been
4979 introduced in Perl version 5.10.
4980
Werner Lemberga8772912014-02-04 11:36:08 +010049812014-02-04 Werner Lemberg <wl@gnu.org>
4982
Werner Lembergd87f9a62014-02-04 16:14:09 +01004983 Fix compilation with MinGW.
4984
4985 Right now, compilation out of the box with latest MinGW is broken
4986 due to bugs in header files of mingwrt 4.0.3 in strict ANSI mode,
4987 cf.
4988
4989 https://sourceforge.net/p/mingw/bugs/2024/
4990 https://sourceforge.net/p/mingw/bugs/2046/
4991
4992 * builds/unix/configure.raw: Don't set `-ansi' flag for MinGW.
4993
49942014-02-04 Werner Lemberg <wl@gnu.org>
4995
Werner Lemberga8772912014-02-04 11:36:08 +01004996 [autofit] Minor fix.
4997
4998 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
4999 src/autofit/aflatin.c (af_latin_metrics_init_widths): Fix handling
5000 of alternative standard characters.
5001 This also fixes a compilation warning in non-debug mode.
5002
Werner Lembergee3778d2014-02-03 11:16:47 +010050032014-02-03 Werner Lemberg <wl@gnu.org>
5004
5005 [cff] Fix Savannah bug #41363.
5006
5007 * src/cff/cf2ft.c (cf2_checkTransform): Convert assertion into
5008 parameter check.
5009 (cf2_decoder_parse_charstrings): Call `cf2_checkTransform' only if
5010 we are scaling the outline.
5011 (cf2_getPpemY): Remove problematic assertion.
5012
Werner Lemberga3364002014-01-26 09:45:23 +010050132014-01-26 Werner Lemberg <wl@gnu.org>
5014
5015 [autofit] Introduce two more slots for standard characters.
5016
5017 This is useful for OpenType features like `c2sc' (caps to small
5018 caps) that don't have lowercase letters by definition, or other
5019 features that mainly operate on numerals.
5020
5021 * src/autofit/afscript.h: Add more standard characters.
5022
5023 * src/autofit/aftypes.h: Update use of `SCRIPT' macro.
5024 (AF_ScriptClassRec): Add members to hold two more standard
5025 characters.
5026 (AF_DEFINE_SCRIPT_CLASS): Updated.
5027
5028 * src/autofit/afglobal.c, src/autofit/afglobal.h,
5029 * src/autofit/afpic.c, src/autofit/afranges.h, src/autofit/hbshim.c:
5030 Update use of `SCRIPT' macro.
5031
5032 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
5033 src/autofit/aflatin.c (af_latin_metrics_init_widths): Scan two more
5034 standard characters.
5035
Werner Lembergeb7691c2014-01-24 19:04:22 +010050362014-01-24 Werner Lemberg <wl@gnu.org>
5037
5038 Fix Savannah bug #41320.
5039
5040 * src/autofit/aflatin.c (af_latin_metrics_init_blues)
5041 <AF_LATIN_IS_LONG_BLUE>: Avoid negative index of `last'.
5042
Werner Lemberg8b281f82014-01-23 08:14:53 +010050432014-01-23 Werner Lemberg <wl@gnu.org>
5044
Werner Lemberg752f3912014-01-23 09:14:25 +01005045 Fix Savannah bug #41310.
5046
5047 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap) <glyph_format==5>:
5048 Don't check metrics, which this format doesn't have.
5049 This is another correction to the commit from 2013-11-21.
5050
50512014-01-23 Werner Lemberg <wl@gnu.org>
5052
Werner Lemberg8b281f82014-01-23 08:14:53 +01005053 Fix Savannah bug #41309.
5054
5055 * src/type1/t1load.c (t1_parse_font_matrix): Properly handle result
5056 of `T1_ToFixedArray'.
5057
5058 * src/cid/cidload.c (cid_parse_font_matrix): Synchronize with
5059 `t1_parse_font_matrix'.
5060
5061 * src/type42/t42parse.c (t42_parse_font_matrix): Synchronize with
5062 `t1_parse_font_matrix'.
5063 (t42_parse_encoding): Synchronize with `t1_parse_encoding'.
5064
5065 * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_BBOX>,
5066 <T1_FIELD_TYPE_MMOX>: Properly handle result of `ps_tofixedarray'.
5067
Werner Lembergff8dc312014-01-22 09:19:57 +010050682014-01-22 Werner Lemberg <wl@gnu.org>
5069
5070 * src/autofit/hbshim.c (af_get_coverage): Fix memory leaks.
5071
Werner Lemberg6a700782014-01-16 08:55:40 +010050722014-01-16 Werner Lemberg <wl@gnu.org>
5073
5074 [autofit] Improve tracing of style coverages.
5075
5076 * include/internal/fttrace.h: Add `afglobal' for tracing style
5077 coverages.
5078
5079 * src/autofit/afglobal.c: Include FT_INTERNAL_DEBUG_H.
5080 (FT_COMPONENT): Define.
5081 (af_face_globals_compute_style_coverage): Trace `gstyles' array
5082 data.
5083
Werner Lemberg7cbfdff2014-01-09 07:26:06 +010050842014-01-09 Werner Lemberg <wl@gnu.org>
5085
5086 Fix Savannah bug #41158.
5087
5088 * builds/unix/install.mk (install): Create man page directory.
5089
Chongyu Zhu94c66942014-01-08 08:52:59 +010050902014-01-08 Chongyu Zhu <lembacon@gmail.com>
5091
5092 [arm] Fix Savannah bug #41138, part 2.
5093
5094 * builds/unix/ftconfig.in (FT_MulFix_arm), include/config/ftconfig.h
5095 (FT_MulFix_arm), src/truetype/ttinterp.c (TT_MulFix14_arm): Fix
5096 preprocessor conditionals for `add.w'.
5097
Werner Lembergc46fa862014-01-08 08:45:40 +010050982014-01-08 Werner Lemberg <wl@gnu.org>
5099
5100 [autofit] Fix Savannah bug #41138, part 1.
5101
5102 * src/tools/afblue.pl <Handling #endif>: Produce correct auxiliary
5103 enumeration names for generated `#else'.
5104
5105 * src/autofit/afblue.h: Regenerated.
5106
Werner Lemberg3e5a3742014-01-06 07:53:10 +010051072014-01-06 Werner Lemberg <wl@gnu.org>
5108
5109 Add manual page for `freetype-config'.
5110 Contributed by Nis Martensen <nis.martensen@web.de>.
5111
5112 * docs/freetype-config.1: New file.
5113
5114 * builds/unix/unix-def.in (mandir): Define.
5115 * builds/unix/install.mk (install, uninstall): Handle manpage.
5116
Werner Lemberg991cbcc2014-01-05 13:24:56 +010051172014-01-05 Werner Lemberg <wl@gnu.org>
5118
5119 [autofit] Minor fixes for `afblue.pl'.
5120
5121 * src/tools/afblue.pl (aux_name): Don't use `reverse'.
5122 <Handling #endif>: Use proper indentation for generated `#else'.
5123
5124 * src/autofit/afblue.h: Regenerated.
5125
Werner Lemberg0d977442014-01-04 11:46:34 +010051262014-01-04 Werner Lemberg <wl@gnu.org>
5127
5128 [autofit] Fix Indic scripts.
5129
5130 Split the single, incorrect Indic entry into separate scripts so
5131 that the covered ranges are the same: Bengali, Devanagari, Gujarati,
5132 Gurmukhi, Kannada, Limbu, Malayalam, Oriya, Sinhala, Sundanese,
5133 Syloti Nagri, Tamil, Telugu, and Tibetan. At the same time, remove
5134 entries for Meetai Mayak and Sharada – the Unicode ranges were
5135 incorrect (and nobody has complained about that), fonts are scarce
5136 for those scripts, and the Indic auto-hinter support is rudimentary
5137 anyways.
5138
5139 * src/autofit/afscript.h: Updated, using AF_CONFIG_OPTION_INDIC and
5140 AF_CONFIG_OPTION_CJK.
5141
5142 * src/autofit/afstyles.h (STYLE_DEFAULT_INDIC): New auxiliary macro.
5143 Use it, together with AF_CONFIG_OPTION_INDIC and
5144 AF_CONFIG_OPTION_CJK, to update.
5145
5146 * src/autofit/afranges.c [AF_CONFIG_OPTION_INDIC]: Updated.
5147 [!AF_CONFIG_OPTION_INDIC, !AF_CONFIG_OPTION_CJK]: Removed.
5148 Sort entries by tags.
5149
Werner Lemberg5c7f5502014-01-03 10:48:26 +010051502014-01-03 Werner Lemberg <wl@gnu.org>
5151
Werner Lembergecdb0e32014-01-03 20:49:31 +01005152 [autofit] Thinko.
5153
5154 * src/autofit/hbshim.c (af_get_char_index): Similar to
5155 `af_get_coverage', reject glyphs which are not substituted.
5156
51572014-01-03 Werner Lemberg <wl@gnu.org>
5158
Werner Lemberga42f9182014-01-03 18:29:41 +01005159 [autofit] Fix handling of default coverages.
5160
Werner Lemberg1b5bc892014-01-03 18:33:24 +01005161 With this commit, the implementation of coverage handling is
5162 completed.
5163
5164 * src/autofit/hbshim.c (af_get_coverage): Exit early if nothing to
5165 do.
5166 Reject coverages which don't contain appropriate glyphs for blue
5167 zones.
5168
51692014-01-03 Werner Lemberg <wl@gnu.org>
5170
5171 [autofit] Fix handling of default coverages.
5172
Werner Lemberga42f9182014-01-03 18:29:41 +01005173 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
5174 First handle non-default coverages, then the default coverage of the
5175 default script, and finally the other default coverages.
5176
51772014-01-03 Werner Lemberg <wl@gnu.org>
5178
Werner Lembergf45749b2014-01-03 18:09:36 +01005179 [autofit] Fix scaling of HarfBuzz shaping.
5180
5181 * src/autofit/hbshim.c (af_get_char_index): Scale to units per EM.
5182
51832014-01-03 Werner Lemberg <wl@gnu.org>
5184
Werner Lemberg5c7f5502014-01-03 10:48:26 +01005185 [autofit] Better ftgrid support.
5186
5187 * src/autofit/afhints.c (af_glyph_hints_get_segment_offset): Add
5188 parameters `is_blue' and `blue_offset'.
5189
Werner Lemberg73cc8332014-01-01 07:10:36 +010051902014-01-01 Werner Lemberg <wl@gnu.org>
5191
Werner Lemberg55cd7e02014-01-02 13:07:48 +01005192 [autofit] Remove some styles.
5193
5194 * src/autofit/afcover.h: Remove coverages for alternative fractions,
5195 denominators, numerators, and fractions.
5196
5197 * src/autofit/afstyles.h (META_STYLE_LATIN): Updated.
5198
51992014-01-01 Werner Lemberg <wl@gnu.org>
5200
Werner Lembergc973e672014-01-01 16:34:42 +01005201 [autofit] Add more styles.
5202
5203 * src/autofit/afstyles.h (STYLE_LATIN, META_STYLE_LATIN): New
5204 auxiliary macros; use them to define styles for Cyrillic, Greek, and
5205 Latin.
5206
5207 * src/autofit/afcover.h: Remove coverage for oldstyle figures.
5208 Since those digits are used in combination with ordinary letters, it
5209 makes no sense to handle them separately.
5210
5211 * src/autofit/afglobal.c (af_face_globals_get_metrics): Don't limit
5212 `options' parameter to 4 bits.
5213
52142014-01-01 Werner Lemberg <wl@gnu.org>
5215
Werner Lembergabb2f732014-01-01 08:00:16 +01005216 [autofit] Fix style assignments to glyphs.
5217
5218 * src/autofit/hbshim.c (af_get_coverage)
5219 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Scan GPOS coverage of features also
5220 so that we can skip glyphs that have both GSUB and GPOS data.
5221
52222014-01-01 Werner Lemberg <wl@gnu.org>
5223
Werner Lemberg0950f3a2014-01-01 07:48:20 +01005224 * src/autofit/hbshim.c: s/{lookups,glyphs}/gsub_{lookups,glyphs}/.
5225
52262014-01-01 Werner Lemberg <wl@gnu.org>
5227
Werner Lemberg73cc8332014-01-01 07:10:36 +01005228 [autofit] Implement and use `af_get_char_index' with HarfBuzz.
5229
5230 * src/autofit/hbshim.c (COVERAGE) [FT_CONFIG_OPTION_USE_HARFBUZZ]:
5231 Redefine to construct HarfBuzz features.
5232 (af_get_char_index) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Rewritten.
5233
5234 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Use
5235 `y_offset' to adjust `best_y'.
5236
Werner Lembergc9d99472013-12-31 08:16:57 +010052372013-12-31 Werner Lemberg <wl@gnu.org>
5238
Werner Lemberg785f3852013-12-31 09:45:10 +01005239 [autofit] s/AF_STYLE_...._DEFAULT/AF_STYLE_...._DFLT/i.
5240
52412013-12-31 Werner Lemberg <wl@gnu.org>
5242
Werner Lembergc9d99472013-12-31 08:16:57 +01005243 [autofit] Fix interface of `af_get_char_index'.
5244
5245 * src/autofit/hbshim.c (af_get_char_index): Return error value.
5246 Add argument for y offset (to be used in a yet-to-come patch).
5247
5248 * src/autofit/hbshim.h, src/autofit/afcjk.c,
5249 src/autofit/aflatin.c: Updated.
5250
Werner Lemberg44aa7e02013-12-30 07:41:22 +010052512013-12-30 Werner Lemberg <wl@gnu.org>
5252
5253 [autofit] Don't combine multiple features into one set.
5254
5255 Combining them, as originally envisioned, would lead to much more
5256 complicated code, as investigations have shown meanwhile. The major
5257 drawback is that we run out of available style slots much earlier.
5258 However, this is only a theoretical issue since we don't support a
5259 large number of scripts currently.
5260
5261 * src/autofit/afcover.h: Replace `COVERAGE_{1,2,3}' macros with
5262 a single-element `COVERAGE' macro, sort the elements by the feature
5263 tags, and add entry for `ruby'.
5264
5265 * src/autofit/aftypes.h: Updated.
5266 * src/autofit/hbshim.c: Updated.
5267
Werner Lemberg6af01a02013-12-28 08:55:24 +010052682013-12-28 Werner Lemberg <wl@gnu.org>
5269
Werner Lemberg072dc452013-12-28 12:26:21 +01005270 [autofit] Code shuffling to reduce use of cpp macros.
5271
5272 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
5273 Call `af_get_coverage' unconditionally.
5274
5275 * src/autofit/autofit.c: Include `hbshim.c' unconditionally.
5276
5277 * src/autofit/hbshim.c (af_get_coverage)
5278 [!FT_CONFIG_OPTION_USE_HARFBUZZ]: Provide dummy function.
5279
5280 * src/autofit/hbshim.h: Provide function declarations
5281 unconditionally.
5282
52832013-12-28 Werner Lemberg <wl@gnu.org>
5284
Werner Lemberg17af5862013-12-28 10:33:01 +01005285 [autofit] Add wrapper function for `FT_Get_Char_Index'.
5286
5287 Yet-to-come changes will provide HarfBuzz functionality for the new
5288 function.
5289
5290 * src/autofit/hbshim.c (af_get_char_index): New function.
5291 * src/autofit/hbshim.h: Updated.
5292
5293 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
5294 af_cjk_metrics_init_blues, af_cjk_metrics_check_digits): Updated.
5295
5296 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
5297 af_latin_metrics_init_blues, af_latin_metrics_check_digits):
5298 Updated.
5299
53002013-12-28 Werner Lemberg <wl@gnu.org>
5301
Werner Lemberg6af01a02013-12-28 08:55:24 +01005302 [autofit] Use `global' HarfBuzz font object.
5303
5304 We now use `hb_font' instead of `hb_face' since yet-to-come changes
5305 need this.
5306
5307 * src/autofit/afglobal.h: Include `hbshim.h'.
5308 (AF_FaceGlobalsRec) [FT_CONFIG_OPTION_USE_HARFBUZZ]: New member
5309 `hb_font'.
5310
5311 * src/autofit/afglobal.c (af_face_globals_new)
5312 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Create `hb_font'.
5313 (af_face_globals_free) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Destroy
5314 `hb_font'.
5315
5316 * src/autofit/hbshim.h: Include HarfBuzz headers.
5317
5318 * src/autofit/hbshim.c: Include `hbshim.h' instead of HarfBuzz
5319 headers.
5320 (af_get_coverage): Updated.
5321
Werner Lembergd32a7d32013-12-27 19:26:04 +010053222013-12-27 Werner Lemberg <wl@gnu.org>
5323
5324 [autofit] Handle `DFLT' OpenType script for coverages.
5325
5326 * include/ftautoh.h: Document new `default-script' property.
5327
5328 * src/autofit/hbshim.c (af_get_coverage): Use `AF_FaceGlobals' for
5329 type of first parameter.
5330 (script_tags): Add one more element.
5331 (af_get_coverage): Adjust `script_tags' to handle `DFLT' script tag.
5332
5333 * src/autofit/hbshim.h: Updated.
5334
5335 * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
5336 Updated.
5337
5338 * src/autofit/afglobal.h (AF_SCRIPT_DEFAULT): New macro.
5339
5340 * src/autofit/afmodule.h (AF_ModuleRec): New `default_script'
5341 member.
5342
5343 * src/autofit/afmodule.c (af_property_set, af_property_get): Handle
5344 `default-script' property.
5345 (af_autofitter_init): Updated.
5346
suzuki toshiyae2d2b152013-12-27 16:44:24 +090053472013-12-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
5348
5349 [ftrfork] Fix the face order difference between POSIX and Carbon.
5350
5351 The fragmented resources in Suitcase and .dfont should be reordered
Werner Lemberg00a7b512013-12-27 19:18:49 +01005352 when `POST' resource for Type1 is being restored, but reordering of
suzuki toshiyae2d2b152013-12-27 16:44:24 +09005353 sfnt resources induces the different face order. Now the ordering
Werner Lemberg00a7b512013-12-27 19:18:49 +01005354 is restricted to `POST' resource only, to prevent the different
5355 order issue (e.g. the face index in the fontconfig cache generated
5356 with Carbon framework is incompatible with that by FreeType 2
5357 without Carbon framework.) Found by Khaled Hosny and Hin-Tak Leung.
5358
suzuki toshiyae2d2b152013-12-27 16:44:24 +09005359 http://lists.gnu.org/archive/html/freetype-devel/2013-02/msg00035.html
5360 http://lists.gnu.org/archive/html/freetype-devel/2013-12/msg00027.html
5361
5362 * src/base/ftrfork.c (FT_Raccess_Get_DataOffsets): Add a switch
Werner Lemberg44aa7e02013-12-30 07:41:22 +01005363 `sort_by_res_id' to control the fragmented resource ordering.
Werner Lemberg00a7b512013-12-27 19:18:49 +01005364 * include/internal/ftrfork.h: Declare new switch.
5365 * src/base/ftobjs.c (IsMacResource): Enable the sorting for `POST'
5366 resource, and disable the sorting for `sfnt' resource.
suzuki toshiyae2d2b152013-12-27 16:44:24 +09005367
Werner Lemberg5f577462013-12-25 08:50:50 +010053682013-12-25 Werner Lemberg <wl@gnu.org>
5369
5370 Fix Savannah bug #40997.
5371
5372 * src/bdf/bdfdrivr.c (BDF_Face_Init): Only use OR operator to
5373 adjust face flags since FT_FACE_FLAG_EXTERNAL_STREAM might already
5374 be set.
5375 * src/cff/cffobjs.c (cff_face_init): Ditto.
5376 * src/cid/cidobjs.c (cid_face_init): Ditto.
5377 * src/pcf/pcfread.c (pcf_load_font): Ditto.
5378 * src/pfr/pfrobjs.c (pfr_face_init): Ditto.
5379 * src/type1/t1objs.c (T1_Face_Init): Ditto.
5380 * src/type42/t42objs.c (T42_Face_Init): Ditto.
5381 * src/winfonts/winfnt.c (FNT_Face_Init): Ditto.
5382
Werner Lembergc4e968e2013-12-21 07:23:08 +010053832013-12-21 Werner Lemberg <wl@gnu.org>
5384
Werner Lemberg19241342013-12-21 21:31:38 +01005385 [autofit] Introduce `coverages'.
5386
5387 Coverages are the interface to the HarfBuzz library to acces
5388 OpenType features for handling glyphs not addressable by the cmap.
5389
5390 Right now, compilation of HarfBuzz is only added to the development
5391 build. A solution for standard build mode will be delayed until
5392 HarfBuzz gets split into two libraries to avoid mutual dependencies
5393 between FreeType and HarfBuzz.
5394
5395 Note that this is only a first step in handling coverages, basically
5396 providing the framework only. Code for handling selected OpenType
5397 features (this is, actually using the data in `afcover.h') will
5398 follow.
5399
5400 * devel/ftoption.h, include/config/ftoption.h
5401 (FT_CONFIG_OPTION_USE_HARFBUZZ): New macro.
5402
5403 * src/autofit/hbshim.c, src/autofit/hbshim.h, src/autofit/afcover.h:
5404 New files.
5405
5406 * src/autofit/afscript.h: Add HarfBuzz script name tags.
5407
5408 * src/autofit/afstyles.h: Add default coverage enumeration values.
5409
5410 * src/autofit/aftypes.h: Update use of `SCRIPT' and `STYLE' macros.
5411 (AF_Coverage): New enumeration (generated by `afcover.h').
5412 (AF_StyleClassRec): New member `coverage'.
5413 (AF_DEFINE_STYLE_CLASS): Updated.
5414
5415 * include/internal/fttrace.h: Add `afharfbuzz' for tracing coverage
5416 data.
5417
5418 * src/autofit/afglobal.h: Update use of `SCRIPT' and `STYLE' macros.
5419 (AF_SCRIPT_FALLBACK): Renamed to ...
5420 (AF_STYLE_FALLBACK): ... this.
5421
5422 * src/autofit/afglobal.c: Include `hbshim.c'.
5423 Update use of `SCRIPT' and `STYLE' macros.
5424 (af_face_globals_compute_style_coverage)
5425 [FT_CONFIG_OPTION_USE_HARFBUZZ]: Call `af_get_coverage'.
5426 Update.
5427
5428 * src/autofit/afmodule.h (AF_ModuleRec):
5429 s/fallback_script/fallback_style/.
5430
5431 * src/autofit/afmodule.c (af_property_set): Adapt handling of
5432 `fallback-script' property to set a fallback style.
5433 (af_property_get, af_autofitter_init): Updated.
5434
5435 * src/autofit/afpic.c: Update use of `SCRIPT' and `STYLE' macros.
5436
5437 * src/autofit/afranges.h: Update use of `SCRIPT' macro.
5438
5439 * src/autofit/autofit.c [FT_CONFIG_OPTION_USE_HARFBUZZ]: Include
5440 `hbshim.c'.
5441
5442 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `hbshim.c'.
5443 (AUTOF_DRV_H): Add `afcover.h'.
5444
5445 * builds/freetype.mk (INCLUDE_FLAGS) [DEVEL_DIR]: Use pkg-config for
5446 all libraries needed by FreeType.
5447
54482013-12-21 Werner Lemberg <wl@gnu.org>
5449
Werner Lembergb337fa22013-12-21 19:33:15 +01005450 Fix Savannah bug #40975 (sort of).
5451
5452 * src/truetype/ttinterp.c (Ins_IP): Fix sign typo to make FreeType
5453 behave the same as the Windows TrueType engine for the invalid case.
5454
54552013-12-21 Werner Lemberg <wl@gnu.org>
5456
Werner Lemberg3bf60952013-12-21 08:49:11 +01005457 [autofit] Make PIC mode work actually.
5458
5459 * src/autofit/afpic.h (AFModulePIC): Fix array sizes to fit the
5460 enumeration values automatically generated by including `afscript.h'
5461 and friends.
5462
5463 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
5464
54652013-12-21 Werner Lemberg <wl@gnu.org>
5466
Werner Lembergbd413862013-12-21 08:14:25 +01005467 Fix PIC linking.
5468
5469 * include/internal/ftrfork.h (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Fix
5470 generated function name.
5471
5472 * src/base/basepic.c (FT_Init_Table_raccess_guess_table): Rename
5473 to ...
5474 (FT_Init_Table_ft_raccess_guess_table): ... this so that the
5475 function name correctly corresponds to what the macro framework
5476 expects.
5477
5478 * src/psnames/rules.mk (PSNAMES_DRV_SRC_S): Use correct file name so
5479 that PIC functions are compiled also.
5480
54812013-12-21 Werner Lemberg <wl@gnu.org>
5482
Werner Lembergc4e968e2013-12-21 07:23:08 +01005483 [base] Add missing dependencies to Makefile.
5484
5485 * src/base/rules.mk (BASE_SRC): Add `basepic.c' and `ftpic.c'.
5486 (BASE_H): Add `basepic.h'.
5487
Werner Lemberg974b1932013-12-20 17:26:26 +010054882013-12-20 Werner Lemberg <wl@gnu.org>
5489
Werner Lemberg8a8f3752013-12-20 18:35:35 +01005490 [autofit] Fix PIC compilation.
5491
5492 * src/autofit/afcjk.c (af_cjk_metrics_init_widths),
5493 src/autofit/aflatin.c (af_latin_metrics_init_widths)
5494 [FT_CONFIG_OPTION_PIC]: Declare `globals'.
5495
5496 * src/autofit/afglobal.c: Always call AF_DEFINE_SCRIPT_CLASS, and
5497 AF_DEFINE_STYLE_CLASS.
5498
5499 * src/autofit/afpic.c: Include `afglobal.h'.
5500 (autofit_module_class_pic_init): Typo.
5501
5502 * src/autofit/aftypes.h (AF_DEFINE_SCRIPT_CLASS,
5503 AF_DEFINE_STYLE_CLASS): Don't use the same identifier for macro
5504 parameter and structure member.
5505
55062013-12-20 Werner Lemberg <wl@gnu.org>
5507
Werner Lemberg974b1932013-12-20 17:26:26 +01005508 [autofit] Introduce `styles'.
5509
5510 This is the new top-level structure for handling glyph input data;
5511 scripts are now defined separately.
5512
5513 * src/autofit/aftypes.h (SCRIPT): Updated.
5514 (AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
5515 members to ...
5516 (AF_Style_ClassRec): ... this new structure.
5517 (AF_Style): New enumeration.
5518 (AF_StyleMetricsRec): Replace `script' enumeration with
5519 `style_class' pointer.
5520 (AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
5521 (AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
5522
5523 * src/autofit/afstyles.h: New file, using data from `afscript.h'.
5524 * src/autofit/afscript.h: Updated.
5525
5526 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
5527 af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
5528
5529 * src/autofit/afglobal.c (SCRIPT): Updated.
5530 (STYLE): Redefine macro to load `afstyles.h'.
5531 (af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
5532 (af_style_names): ... this array.
5533 (af_face_globals_compute_script_coverage): Renamed to...
5534 (af_face_globals_compute_style_coverage): ... this.
5535 Updated.
5536 (af_face_globals_new, af_face_globals_free,
5537 af_face_globals_get_metrics): Updated.
5538
5539 * src/autofit/afglobal.h (SCRIPT): Updated.
5540 (STYLE): Redefine macro to load `afstyles.h'.
5541 (AF_SCRIPT_FALLBACK): Update definition. This will get more
5542 refinements with later on.
5543 (AF_SCRIPT_UNASSIGNED): Replace with...
5544 (AF_STYLE_UNASSIGNED): ... this macro.
5545 (AF_FaceGlobalsRec): Updated.
5546
5547 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
5548 af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
5549 af_latin_hint_edges): Updated.
5550
5551 * src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
5552 (af_ltn2_uniranges): Removed.
5553
5554 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
5555 Updated.
5556
5557 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
5558 * src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
5559 (AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
5560 members.
5561
5562 * src/autofit/afranges.h: Updated.
5563
5564 * src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
5565
Werner Lembergd8324572013-12-19 15:45:24 +010055662013-12-19 Werner Lemberg <wl@gnu.org>
5567
5568 [autofit] Factor scripts and uniranges out of writing system files.
5569
5570 * src/autofit/afranges.c, src/autofit/afranges.h: New files.
5571
5572 * src/autofit/afscript.h: Extend `SCRIPT' macro with more
5573 parameters, taking data from the writing system files.
5574
5575 * src/autofit/aftypes.h: Updated.
5576
5577 * src/autofit/afglobal.c: Include `afranges.h'.
5578 Load `afscript.h' to call AF_DEFINE_SCRIPT_CLASS.
5579 * src/autofit/afglobal.c: Include `afranges.h'.
5580 Load `afscript.h' to call AF_DECLARE_SCRIPT_CLASS.
5581
5582 * src/autofit/afcjk.c, src/autofit/afcjk.h: Updated.
5583 * src/autofit/afdummy.c, src/autofit/afdummy.h: Updated.
5584 * src/autofit/afindic.c, src/autofit/afindic.h: Updated.
5585 * src/autofit/aflatin.c, src/autofit/aflatin.h: Updated.
5586 * src/autofit/aflatn2.c, src/autofit/aflatn2.h: Updated.
5587
5588 * src/autofit/afpic.c: Updated.
5589
5590 * src/autofir/autofit.c: Include `afranges.c'.
5591 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afranges.c'.
5592
Werner Lemberg9a354552013-12-18 10:36:06 +010055932013-12-18 Werner Lemberg <wl@gnu.org>
5594
Werner Lemberg73f31982013-12-19 15:24:17 +01005595 [autofit] More code orthogonality.
5596
5597 * src/autofit/aftypes.h (AF_StyleMetrics): Replace `script_class'
5598 pointer to an `AF_ScriptClass' structure with `script' index of type
5599 `AF_Script'.
5600 Move some code around.
5601
5602 * src/autofit/afcjk.c: Include `afpic.h'.
5603 (af_cjk_metrics_init_widths, af_cjk_metrics_init_blues,
5604 af_cjk_hint_edges): Updated.
5605
5606 * src/autofit/aflatin.c: Include `afpic.h'.
5607 (af_latin_metrics_init_widths, af_latin_metrics_init_blues,
5608 af_latin_metrics_scale_dim, af_latin_hint_edges): Updated.
5609
5610 * src/autofit/afglobal.c (af_face_globals_get_metrics): Updated.
5611
5612 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
5613 Updated.
5614
56152013-12-18 Werner Lemberg <wl@gnu.org>
5616
Werner Lemberg3f91cb32013-12-18 12:59:35 +01005617 [autofit] s/ScriptMetrics/StyleMetrics/.
5618
56192013-12-18 Werner Lemberg <wl@gnu.org>
5620
Werner Lemberg4fccc212013-12-18 12:53:01 +01005621 [autofit] s/script_{metrics,hints}/style_{metrics,hints}/
5622
56232013-12-18 Werner Lemberg <wl@gnu.org>
5624
Werner Lembergf4df4072013-12-18 10:39:30 +01005625 [autofit] s/gscripts/gstyles/.
5626
56272013-12-18 Werner Lemberg <wl@gnu.org>
5628
Werner Lemberg9a354552013-12-18 10:36:06 +01005629 [autofit] s/glyph_scripts/glyph_styles/.
5630
5631 This is the first commit of a series to create a new top-level
5632 structure (a `style') for handling scripts, writing_systems, and
5633 soon-to-be-added coverages.
5634
Werner Lemberg7a5fc2f2013-12-17 13:29:53 +010056352013-12-17 Werner Lemberg <wl@gnu.org>
5636
5637 [autofit] s/AF_Script_/AF_WritingSystem_/ where appropriate.
5638
Infinality8bb09b02013-12-11 09:01:13 +010056392013-12-11 Infinality <infinality@infinality.net>
5640
5641 [truetype] Simplify logic of rendering modes.
5642
5643 This patch unifies the subpixel and non-subpixel cases.
5644
5645 * src/truetype/ttinterp.h (TT_ExecContextRec): Remove
5646 `grayscale_hinting'; all code should refer to `grayscale' instead.
5647 Remove unused `native_hinting' member.
5648 Rename `subpixel_hinting' member to `subpixel.
5649
5650 * src/truetype/ttgload.c (TT_LOADER_SET_PP): Updated.
5651 (tt_loader_init): Updated.
5652
5653 * src/truetype/ttinterp.c (Ins_GETINFO): Simplify.
5654 Updated.
5655
Werner Lemberge9d95aa2013-12-11 07:48:51 +010056562013-12-11 Werner Lemberg <wl@gnu.org>
5657
5658 [documentation] Add section how to include FreeType header files.
5659 Problem reported by David Kastrup <dak@gnu.org>.
5660
5661 Surprisingly, a description how to do that was completely missing in
5662 the API reference.
5663
5664 * include/freetype.h, include/ftchapters.h: New documentation
5665 section `header_inclusion'.
5666
Werner Lemberg05c786d2013-12-10 08:38:57 +010056672013-12-10 Werner Lemberg <wl@gnu.org>
5668
Werner Lemberg91932592013-12-10 13:24:07 +01005669 [autofit] s/DFLT/NONE/, s/dflt/none/.
5670
56712013-12-10 Werner Lemberg <wl@gnu.org>
5672
Werner Lemberg45244f82013-12-10 13:18:11 +01005673 [autofit] s/AF_SCRIPT_NONE/AF_SCRIPT_UNASSIGNED/.
5674
56752013-12-10 Werner Lemberg <wl@gnu.org>
5676
Werner Lemberg69d1a362013-12-10 10:12:27 +01005677 [truetype] Fix scaling of vertical phantom points.
5678
5679 * src/truetype/ttgload.c (load_truetype_glyph): Scale pp3.x and
5680 pp4.x also.
5681
56822013-12-10 Werner Lemberg <wl@gnu.org>
5683
Werner Lemberg05c786d2013-12-10 08:38:57 +01005684 [truetype] Fix positioning of composite glyphs.
5685 Problem reported by Nigel Tao <nigeltao@golang.org>.
5686
5687 * src/truetype/ttgload.c (TT_Hint_Glyph): Remove code that shifts
5688 the glyph (component) by a fractional value computed from the LSB
5689 phantom point. This is wrong, since the horizontal phantom points
5690 get rounded horizontally later on.
5691
Werner Lembergdd8050a2013-12-08 23:14:46 +010056922013-12-08 Werner Lemberg <wl@gnu.org>
5693
5694 * Version 2.5.2 released.
5695 =========================
5696
5697
5698 Tag sources with `VER-2-5-2'.
5699
5700 * docs/VERSION.DLL: Update documentation and bump version number to
5701 2.5.2.
5702
5703 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
5704 builds/windows/vc2005/index.html,
5705 builds/windows/vc2008/freetype.vcproj,
5706 builds/windows/vc2008/index.html,
5707 builds/windows/vc2010/freetype.vcxproj,
5708 builds/windows/vc2010/index.html,
5709 builds/windows/visualc/freetype.dsp,
5710 builds/windows/visualc/freetype.vcproj,
5711 builds/windows/visualc/index.html,
5712 builds/windows/visualce/freetype.dsp,
5713 builds/windows/visualce/freetype.vcproj,
5714 builds/windows/visualce/index.html,
5715 builds/wince/vc2005-ce/freetype.vcproj,
5716 builds/wince/vc2005-ce/index.html,
5717 builds/wince/vc2008-ce/freetype.vcproj,
5718 builds/wince/vc2008-ce/index.html: s/2.5.1/2.5.2/, s/251/252/.
5719
Werner Lembergec8853c2014-03-06 19:13:45 +01005720 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
Werner Lembergdd8050a2013-12-08 23:14:46 +01005721
5722 * builds/unix/configure.raw (version_info): Set to 17:1:11.
Werner Lembergec8853c2014-03-06 19:13:45 +01005723 * CMakeLists.txt (VERSION_PATCH): Set to 2.
Werner Lembergdd8050a2013-12-08 23:14:46 +01005724 * docs/CHANGES: Updated.
5725
Werner Lemberg98d185c2013-12-07 09:26:55 +010057262013-12-07 Werner Lemberg <wl@gnu.org>
5727
5728 [truetype] Next round in phantom point handling.
5729
5730 Greg Hitchcock provided very interesting insights into the
5731 complicated history of the horizontal positions of the TSB and BSB
5732 phantom points.
5733
5734 * src/truetype/ttgload.c (TT_LOADER_SET_PP)
5735 [TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Use `subpixel_hinting' and
5736 `grayscale_hinting' flags as conditionals for the x position of TSB
5737 and BSB.
5738
Werner Lembergfcdb7842013-12-05 15:53:27 +010057392013-12-05 Werner Lemberg <wl@gnu.org>
5740
5741 * builds/freetype.mk (FT_CC): Removed. Unused.
5742
Werner Lemberg64b395c2013-12-04 06:18:56 +010057432013-12-04 Werner Lemberg <wl@gnu.org>
5744
5745 [sfnt] Fix handling of embedded bitmap strikes.
5746
5747 This corrects the commit from 2013-11-21. Problem reported by
5748 Andrey Panov <panov@canopus.iacp.dvo.ru>.
5749
5750 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Fix logic to
5751 detect excessive bytes for bit-aligned bitmaps.
5752
Werner Lembergbdd5e752013-12-03 06:57:02 +010057532013-12-03 Werner Lemberg <wl@gnu.org>
5754
Werner Lembergc2b47532013-12-03 07:01:57 +01005755 [truetype] Remove dead code.
5756
5757 Reported by Nigel Tao <nigeltao@golang.org>.
5758
5759 * include/internal/tttypes.h (TT_LoaderRec): Remove unused
5760 `preserve_pps' field.
5761 * src/truetype/ttgload.c (TT_Hint_Glyph): Updated.
5762
57632013-12-03 Werner Lemberg <wl@gnu.org>
5764
Werner Lembergbdd5e752013-12-03 06:57:02 +01005765 [truetype] Fix phantom point handling.
5766
5767 This is a further improvement to the changes from 2013-11-06.
5768
5769 * src/truetype/ttgload.c (TT_Hint_Glyph): Horizontal phantom points
5770 are rounded horizontally, vertical ones are rounded vertically.
5771 (TT_LOADER_SET_PP): The horizontal position of vertical phantom
5772 points in pre-ClearType mode is zero, as shown in the OpenType
5773 specification.
5774
Werner Lemberg64872a52013-12-02 07:51:17 +010057752013-12-02 Werner Lemberg <wl@gnu.org>
5776
5777 [truetype] Fix change from 2013-11-20.
5778
5779 Problem reported by Akira Kakuto <kakuto@fuk.kindai.ac.jp>.
5780
5781 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Protect call to
5782 `Update_Max' with both a TT_USE_BYTECODE_INTERPRETER guard and a
5783 `IS_HINTED' clause.
5784 Also remove redundant check using `maxSizeOfInstructions' – in
5785 simple glyphs, the bytecode data comes before the outline data, and
5786 a validity test for this is already present.
5787
Werner Lemberg52166ab2013-11-27 10:10:16 +010057882013-11-27 Werner Lemberg <wl@gnu.org>
5789
5790 [autofit] Fix use of dumping functions in `ftgrid' demo program.
5791
5792 * src/autofit/afhints.c (AF_DUMP) [FT_DEBUG_AUTOFIT]: New macro.
5793 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
5794 af_glyph_hints_dump_edges) [FT_DEBUG_AUTOFIT]: Add parameter to
5795 handle output to stdout.
5796 Use AF_DUMP.
5797 (af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
5798 af_glyph_hints_dump_edges) [!FT_DEBUG_AUTOFIT]: Removed.
5799
Werner Lemberg3aee4292013-11-25 00:28:11 +010058002013-11-25 Werner Lemberg <wl@gnu.org>
5801
5802 * Version 2.5.1 released.
5803 =========================
5804
5805
5806 Tag sources with `VER-2-5-1'.
5807
5808 * docs/VERSION.DLL: Update documentation and bump version number to
5809 2.5.1.
5810
5811 * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
5812 builds/windows/vc2005/index.html,
5813 builds/windows/vc2008/freetype.vcproj,
5814 builds/windows/vc2008/index.html,
5815 builds/windows/vc2010/freetype.vcxproj,
5816 builds/windows/vc2010/index.html,
5817 builds/windows/visualc/freetype.dsp,
5818 builds/windows/visualc/freetype.vcproj,
5819 builds/windows/visualc/index.html,
5820 builds/windows/visualce/freetype.dsp,
5821 builds/windows/visualce/freetype.vcproj,
5822 builds/windows/visualce/index.html,
5823 builds/wince/vc2005-ce/freetype.vcproj,
5824 builds/wince/vc2005-ce/index.html,
5825 builds/wince/vc2008-ce/freetype.vcproj,
5826 builds/wince/vc2008-ce/index.html: s/2.5.0/2.5.1/, s/250/251/.
5827
5828 * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
5829
5830 * builds/unix/configure.raw (version_info): Set to 17:0:11.
Werner Lembergec8853c2014-03-06 19:13:45 +01005831 * CMakeLists.txt (VERSION_PATCH): Set to 1.
Werner Lemberg3aee4292013-11-25 00:28:11 +01005832 * docs/CHANGES, docs/release: Updated.
5833
Werner Lemberg9326caf2013-11-23 23:59:25 +010058342013-11-23 Werner Lemberg <wl@gnu.org>
5835
Werner Lemberg063ee6b2013-11-24 00:19:17 +01005836 [truetype]: Add tricky font names `hkscsiic.ttf' and `iicore.ttf'.
5837
5838 * src/truetype/ttobjs.c (TRICK_NAMES_MAX_CHARACTERS,
5839 TRICK_NAMES_COUNT): Updated.
5840 (trick_names): Add family name for the two fonts.
5841
58422013-11-23 Werner Lemberg <wl@gnu.org>
5843
Werner Lemberg9326caf2013-11-23 23:59:25 +01005844 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Typo.
5845
Werner Lemberg427b1762013-11-21 13:10:56 +010058462013-11-21 Werner Lemberg <wl@gnu.org>
5847
Werner Lemberg9326caf2013-11-23 23:59:25 +01005848 [sfnt] Typo.
Werner Lemberg8af2a1c2013-11-21 13:13:12 +01005849
5850 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
5851
5852 * src/sfnt/sfobjs.c (sfnt_load_face): Return correct `bsize->width'
5853 value if the font lacks an `OS/2' table.
5854
58552013-11-21 Werner Lemberg <wl@gnu.org>
5856
Werner Lemberg64b395c2013-12-04 06:18:56 +01005857 [sfnt] Improve handling of buggy embedded bitmap strikes.
Werner Lemberg427b1762013-11-21 13:10:56 +01005858
5859 We are now able to successfully load `AppleMyoungJo.ttf'.
5860 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>.
5861
5862 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Don't trust glyph
5863 format.
5864
Werner Lemberg28626862013-11-20 21:06:18 +010058652013-11-20 Werner Lemberg <wl@gnu.org>
5866
5867 [truetype] Don't trust `maxp's `maxSizeOfInstructions'.
5868
5869 Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>; see
5870
5871 http://lists.nongnu.org/archive/html/freetype-devel/2013-08/msg00005.html
5872
5873 for details.
5874
5875 * src/base/ftobjs.c (FT_Load_Glyph): Check size of `fpgm' and `prep'
5876 tables also for setting `autohint'.
5877
5878 * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Use code from
5879 `TT_Process_Composite_Glyph' for handling unreliable values of
5880 `maxSizeOfInstructions'.
5881
Werner Lembergbc25de62013-11-16 07:52:20 +010058822013-11-16 Werner Lemberg <wl@gnu.org>
5883
5884 [sfnt] Fix `OS/2' table version 5 support.
5885
5886 We now follow the `official' announcement from Microsoft (on the
5887 OpenType mailing list, which unfortunately hasn't a public archive).
5888
5889 * include/freetype/tttables.h (TT_OS2):
5890 s/usLowerPointSize/usLowerOpticalPointSize/,
5891 s/usUpperPointSize/usUpperOpticalPointSize/.
5892
5893 * src/sfnt/ttload.c (tt_face_load_os2): Update, and set correct
5894 default values.
5895
Werner Lembergfae38202013-11-13 08:55:46 +010058962013-11-13 Werner Lemberg <wl@gnu.org>
5897
Werner Lembergc52b1292013-11-13 10:06:00 +01005898 * builds/unix/ft2unix.h: Remove. No longer necessary.
5899
5900 * builds/unix/install.mk (install): Updated.
5901
59022013-11-13 Werner Lemberg <wl@gnu.org>
5903
Werner Lembergfae38202013-11-13 08:55:46 +01005904 Simplify header file hierarchy.
5905
5906 This large patch changes the header file directory layout from
5907 `include/freetype/...' to `include/...', effectively removing one
5908 level. Since the file `ft2build.h' is also located in `include'
5909 (and it stays there even after installation), all FreeType header
5910 files are now in a single directory.
5911
5912 Applications that use (a) `freetype-config' or FreeType's
5913 `pkg-config' file to get the include directory for the compiler, and
5914 (b) the documented way for header inclusion like
5915
5916 #include <ft2build.h>
5917 #include FT_FREETYPE_H
5918 ...
5919
5920 don't need any change to the source code.
5921
5922 * include/freetype/*: Move up to...
5923 * include/*: ... this directory.
5924
5925 * builds/amiga/include/freetype/*: Move up to...
5926 * builds/amiga/include/*: ... this directory.
5927
5928 */*: Essentially do `s@/freetype/@/@' where appropriate.
5929
5930 * CMakeList.txt: Simplify.
5931 * builds/unix/freetype-config.in, builds/unix/freetype2.in: For
5932 `--cflags', return a single directory.
5933 * builds/unix/install.mk (install): No longer try to remove `cache'
5934 and `internal' subdirectories; instead, remove the `freetype'
5935 subdirectory.
5936
Werner Lembergea5c7812013-11-12 08:55:26 +010059372013-11-12 Werner Lemberg <wl@gnu.org>
5938
5939 [truetype] Fix last `truetype' commit.
5940
5941 * src/truetype/ttgload.c (tt_get_metrics): Preserve stream position.
5942 Return error value.
5943 (load_truetype_glyph): Updated.
5944
Werner Lemberg78333282013-11-10 06:26:52 +010059452013-11-10 Werner Lemberg <wl@gnu.org>
5946
5947 * docs/CMAKE: New dummy file.
5948
Dave Arnolddd213012013-11-08 10:52:51 +010059492013-11-08 Dave Arnold <darnold@adobe.com>
5950
5951 [cff] Fix for hints that touch.
5952
5953 * src/cff/cf2hints.c (cf2_hintmap_insertHint): Fix condition for
5954 finding index value of insertion point.
5955
Werner Lemberg7e4b0fb2013-11-06 07:14:49 +010059562013-11-06 Werner Lemberg <wl@gnu.org>
5957
Werner Lemberg5e225b72013-11-06 08:41:59 +01005958 [truetype] Fix handling of phantom points in composite glyphs.
5959 Problem reported by Nigel Tao <nigeltao@golang.org>.
5960
5961 This is a follow-up commit to the previous one.
5962
5963 * src/truetype/ttgload.c (load_truetype_glyph): Call
5964 `tt_get_metrics' after loading the glyph header.
5965
59662013-11-06 Werner Lemberg <wl@gnu.org>
5967
Werner Lemberg7e4b0fb2013-11-06 07:14:49 +01005968 [truetype] Improve emulation of vertical metrics.
5969
5970 This commit also improves the start values of vertical phantom
5971 points. Kudos to Greg Hitchcock for help.
5972
5973 * src/truetype/ttgload.c (TT_Get_VMetrics): Add parameter to pass
5974 `yMax' value. Replace code with fixed Microsoft definition.
5975 (tt_get_metrics): Updated.
5976 (TT_LOADER_SET_PP): Add explanation how to initialize phantom
5977 points, taken from both the OpenType specification and private
5978 communication with Greg (which will eventually be added to the
5979 standard).
5980 Fix horizontal position of `pp3' and `pp4'.
5981
5982 * src/truetype/ttgload.h: Updated.
5983
5984 * src/truetype/ttdriver.c (tt_get_advances): Updated.
5985
5986 * docs/CHANGES: Updated.
5987
Werner Lembergc6064282013-11-05 13:29:15 +010059882013-11-05 Werner Lemberg <wl@gnu.org>
5989
Werner Lemberg50740532013-11-05 23:19:18 +01005990 * builds/windows/vc2010/freetype.vcxproj: s/v110/v100/.
5991 PlatformToolSet version 110 is for VC2012.
5992
5993 Problem reported (with solution) by Dave Arnold <darnold@adobe.com>.
5994
59952013-11-05 Werner Lemberg <wl@gnu.org>
5996
Werner Lembergc6064282013-11-05 13:29:15 +01005997 [truetype] Correctly reset point tags for glyph components.
5998 Problem reported by Nigel Tao <nigeltao@golang.org>.
5999
6000 * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Fix loop.
6001
Werner Lemberg35b08182013-11-02 08:28:41 +010060022013-11-02 Werner Lemberg <wl@gnu.org>
6003
Werner Lemberg7d449432013-11-02 11:36:37 +01006004 [truetype] Fix GETINFO opcode handling of subpixel hinting bits.
6005
6006 * src/truetype/ttinterp.c (Ins_GETINFO): Don't request bit 6 set to
6007 get info on subpixel hinting.
6008
6009 * docs/CHANGES: Updated.
6010
60112013-11-02 Werner Lemberg <wl@gnu.org>
6012
Werner Lemberg35b08182013-11-02 08:28:41 +01006013 Fix Savannah bug #40451.
6014
6015 Simply apply the patch from the bug report.
6016
6017 * builds/unix/ftconfig.in, builds/vms/ftconfig.h,
6018 include/freetype/config/ftconfig.h: The used #pragma directives only
6019 work with gcc versions 4.6 and higher.
6020
Werner Lembergebf52d62013-11-01 13:26:28 +010060212013-11-01 Werner Lemberg <wl@gnu.org>
6022
Werner Lembergafa0d592013-11-01 22:27:27 +01006023 * docs/CHANGES: Updated.
6024
60252013-11-01 Werner Lemberg <wl@gnu.org>
6026
Werner Lembergebf52d62013-11-01 13:26:28 +01006027 [truetype] Minor code refactoring.
6028
6029 Two benefits: The allocated FDEF (and IDEF) array gets slightly
6030 smaller, and the `ttdebug' demo program has access to function
6031 numbers without additional costs.
6032
6033 Fortunately, no changes to FontForge are necessary – this is the
6034 only external TrueType debugger I know of, but others may exist and
6035 should check the code accordingly.
6036
6037 * src/truetype/ttinterp.h (TT_CallRec): Replace `Cur_Restart' and
6038 `Cur_End' with a pointer to the corresponding `TT_DefRecord'
6039 structure.
6040
6041 * src/truetype/ttinterp.c (DO_JROT, DO_JMPR, DO_JROF, Ins_ENDF,
6042 Ins_CALL, Ins_LOOPCALL, Ins_UNKNOWN, TT_RunIns <Invalid_Opcode>):
6043 Updated.
6044
Werner Lembergee510512013-10-27 07:25:35 +010060452013-10-27 Werner Lemberg <wl@gnu.org>
6046
6047 [sfnt] Implement support for `OS/2' table version 5.
6048
6049 See
6050
6051 http://typedrawers.com/discussion/470/new-microsoft-size-specific-design-selection-mechanism
6052
6053 for the announcement.
6054
6055 * include/freetype/tttables.h (TT_OS2): Add fields
6056 `usLowerPointSize' and `usUpperPointSize'. Since FreeType returns
6057 this structure only as a pointer through `FT_Get_Sfnt_Table', there
6058 shouldn't be any ABI problems.
6059
6060 * src/sfnt/ttload.c (tt_face_load_os2): Implement it.
6061
6062 * docs/CHANGES: Updated.
6063
Werner Lemberg994a8592013-10-24 08:50:34 +020060642013-10-24 Werner Lemberg <wl@gnu.org>
6065
6066 * README.git, docs/CHANGES, docs/INSTALL: Updated.
6067
John Carya0e4a732013-10-24 08:49:08 +020060682013-10-24 John Cary <cary@txcorp.com>
6069
6070 Provide cmake support.
6071
6072 * CMakeLists.txt: New file.
6073
Kenneth Miller4d87ac82013-10-23 20:10:56 +020060742013-10-23 Kenneth Miller <kennethadammiller@yahoo.com>
6075 Werner Lemberg <wl@gnu.org>
6076
6077 Provide support for x64 builds in Visual C++ project files.
6078
6079 * src/builds/win32: Renamed to...
6080 * src/builds/windows: This.
6081
6082 * src/builds/windows/vc2010/*: Updated to handle x64 target.
6083
6084 * src/builds/windows/*.mk, docs/INSTALL.GNU: s/win32/windows/ where
6085 appropriate.
6086
Werner Lemberg604838d2013-10-22 01:10:10 +020060872013-10-22 Werner Lemberg <wl@gnu.org>
6088
6089 * src/base/md5.c, src/base/md5.h: Updated to recent version.
6090
6091 * src/base/ftobjs.c: Updated; `md5.c' no longer uses `free'.
6092
Werner Lembergdb9159c2013-10-22 10:27:50 +02006093 The canonical URL to get updates for this file is
6094
6095 http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/popa3d/popa3d/md5/
6096
6097 as the author told me in private communication.
6098
Werner Lemberg34efe052013-10-19 21:14:40 +020060992013-10-19 Werner Lemberg <wl@gnu.org>
6100
Werner Lemberg75efc2d2013-10-19 21:46:03 +02006101 [autofit] s/SMALL_TOP/X_HEIGHT/.
6102
6103 * src/autofit/afblue.dat: Updated.
6104
6105 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
6106
6107 * src/autofit/aflatin.c, src/autofit/aflatin.h,
6108 src/autofit/atlatin2.c: Updated.
6109
61102013-10-19 Werner Lemberg <wl@gnu.org>
6111
Werner Lemberg34efe052013-10-19 21:14:40 +02006112 * src/autofit/afblue.dat: s/MINOR/DESCENDER/.
6113
6114 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
6115
Werner Lemberg955f6a82013-10-16 19:47:57 +020061162013-10-16 Werner Lemberg <wl@gnu.org>
6117
Werner Lemberga5f22a92013-10-17 11:08:25 +02006118 [autofit] Add description strings to script entries.
6119
6120 Currently, this is unused.
6121
6122 * src/autofit/afscript.h: Do it.
6123 * src/autofit/afglobal.c, src/autofit/afpic.c,
6124 src/autofit/aftypes.h: Updated.
6125
61262013-10-16 Werner Lemberg <wl@gnu.org>
6127
Werner Lemberg955f6a82013-10-16 19:47:57 +02006128 [autofit] Improve tracing message for extra light flag.
6129
6130 * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Do it.
6131
Chongyu Zhu41632b52013-10-15 11:40:34 +020061322013-10-15 Chongyu Zhu <lembacon@gmail.com>
6133
6134 [arm] Fix thumb2 inline assembly under LLVM.
6135
6136 When using `ADD' with an immediate operand, the instruction is
6137 actually `ADD Rd, Rn, #<imm12>', that is, the maximum of the
6138 immediate operand cannot exceed 4095. It will fail to compile with
6139 LLVM.
6140
6141 However, in GCC, due to some legacy compatibility considerations,
6142 `ADD.W' will be automatically emitted when the immediate operand is
6143 larger than 4095.
6144
6145 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
6146 (FT_MulFix_arm) [__GNUC__]: Support clang compiler.
6147
6148 * src/truetype/ttinterp.c (TT_MulFix14_arm) [__GNUC__]: Ditto.
6149
Werner Lembergb6695242013-10-12 10:33:04 +020061502013-10-12 Werner Lemberg <wl@gnu.org>
6151
6152 [autofit] Improve tracing of `latin' hinter.
6153
6154 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Report blue
6155 zone types.
6156 (af_latin_metrics_scale_dim): Report scaling changes due to x height
6157 alignment.
6158 Report scaled stroke width and blue zone values.
6159
Dave Arnolde845a852013-10-03 23:04:29 +020061602013-10-03 Dave Arnold <darnold@adobe.com>
6161
6162 * src/cff/cf2font.c (cf2_computeDarkening): Avoid division by zero.
6163
Werner Lemberg2c56f2a2013-10-07 22:01:00 +02006164 Note that the old code avoided using a region of the piecewise
6165 linear function where the slope was zero. The recovery was to use a
6166 different section of the function, which produced a different,
6167 incorrect amount of darkening.
6168
Darrell Bellert01af71d2013-10-02 22:04:07 +020061692013-10-02 Darrell Bellert <darrell.bellert@hl.konicaminolta.us>
6170
6171 * src/sfnt/ttload.c (tt_face_load_pclt): Fix `pclt_fields'.
6172
Dave Arnold0b330452013-10-02 11:04:06 +020061732013-10-02 Dave Arnold <darnold@adobe.com>
6174
6175 * src/cff/cf2font.c (cf2_computeDarkening): Initialize darkenAmount.
6176
6177 This line was lost in commit 89ca1fd6 (from 2013-06-25). The effect
6178 is to use a previous darkening amount when producing an unhinted,
6179 unscaled outline. This can cause autohint samples in ftgrid and
6180 ftview to be based on darkened CFF outlines instead of unhinted,
6181 undarkened ones.
6182
Dave Arnold3a2cb0f2013-09-29 16:17:02 +020061832013-09-29 Dave Arnold <darnold@adobe.com>
6184
6185 Fix Savannah bug #39295.
6186
6187 The bug was caused by switching to the initial hintmap (the one in
6188 effect when `moveto' executes) just before drawing the final element
6189 in the charstring. This ensured that the path was closed (in both
6190 Character Space and Device Space). But if the final element was a
6191 curve and if the final hintmap was different enough from the initial
6192 one, then the curve was visibly distorted.
6193
6194 The first part of the fix is to draw the final curve using the final
6195 hintmap as specified by the charstring. This corrects the
6196 distortion but does not ensure closing in Device Space. It may
6197 require the rasterizer to automatically generate an extra closing
6198 line. Depending on the hintmap differences, this line could be from
6199 zero to a couple pixels in length.
6200
6201 The second part of the fix covers the case where the charstring
6202 subpath is closed with an explicit line. We now modify that line's
6203 end point to avoid the distortion.
6204
6205 Some glyphs in the bug report font (TexGyreHeros-Regular) that show
6206 the change are:
6207
6208 25ppem S (98)
6209 24ppem eight (52)
6210 25.5ppem p (85)
6211
6212 Curves at the *end* of a subpath are no longer distorted. However,
6213 some of these glyphs have bad hint substitutions in the middle of a
6214 subpath, and these are not affected.
6215
6216 The patch has been tested with a set of 106 fonts that shipped with
6217 Adobe Creative Suite 4, together with 756 Open Source CFF fonts from
6218 Google Fonts. There are 1.5 million glyphs, of which some 20k are
6219 changed with the fix. A sampling of a few hundred of these changes
6220 have been examined more closely, and the changes look good (or at
6221 least acceptable).
6222
6223 * src/cff/cf2hints.h (CF2_GlyphPathRec): New element `pathIsClosing'
6224 to indicate that we synthesize a closepath line.
6225
6226 * src/cff/cf2hints.c (cf2_glyphpath_init): Updated.
6227 (cf2_glyphpath_pushPrevElem): If closing, use first hint map (for
6228 `lineto' operator) and adjust hint zone.
6229 For synthesized closing lines, use end point in first hint zone.
6230 (cf2_glyphpath_lineTo): Take care of synthesized closing lines. In
6231 particular, shift the detection of zero-length lines from character
6232 space to device space.
6233 (cf2_glyphpath_closeOpenPath): Remove assertion.
6234 Updated.
6235
Werner Lembergb75a8b82013-09-25 09:46:36 +020062362013-09-25 Werner Lemberg <wl@gnu.org>
6237
6238 * src/autofit/aflatin.c (af_{grek,cyrl}_uniranges): Fix arrays.
6239
suzuki toshiyaac0f4452013-09-25 10:57:17 +090062402013-09-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6241
6242 [bdf, pcf] Refuse non-zero face_index.
Werner Lemberg964317e2013-09-25 09:22:40 +02006243
suzuki toshiyaac0f4452013-09-25 10:57:17 +09006244 Suggested by Akira Tagoh, see
6245
6246 http://lists.gnu.org/archive/html/freetype/2013-09/msg00030.html
6247
Werner Lemberg964317e2013-09-25 09:22:40 +02006248 * src/bdf/bdfdrivr.c (BDF_Face_Init): Return `Invalid_Argument'
6249 error if the font could be opened but non-zero `face_index' is
6250 given.
suzuki toshiyaac0f4452013-09-25 10:57:17 +09006251 * src/pcf/pcfdrivr.c (PCF_Face_Init): Ditto.
6252
6253 * src/type42/t42objs.c (T42_Face_Init): Remove unrequired FT_UNUSED
Werner Lemberg964317e2013-09-25 09:22:40 +02006254 macro for `face_index' because it is validated later.
suzuki toshiyaac0f4452013-09-25 10:57:17 +09006255
Werner Lemberg4de77872013-09-23 22:10:08 +020062562013-09-23 Werner Lemberg <wl@gnu.org>
6257
6258 Fix Savannah bug #40090.
6259
6260 * src/autofit/afcjk.c (af_cjk_metrics_scale): Revert commit
6261 306f8c5d (from 2013-08-25) affecting this function.
6262
Werner Lemberg5a4c5a52013-09-22 22:37:26 +020062632013-09-22 Werner Lemberg <wl@gnu.org>
6264
6265 [autofit] Disunify Cyrillic and Greek handling from Latin.
6266
6267 * src/autofit/afscript.h: Add Cyrillic and Greek.
6268
6269 * src/autofit/afblue.dat (AF_BLUE_STRINGSET_GREK,
6270 AF_BLUE_STRINGSET_CYRL): Add blue zones for Greek and Cyrillic.
6271 (AF_BLUE_STRINGSET_LATN): Fix typo.
6272 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
6273
6274 * src/autofit/aflatin.c (af_grek_uniranges, af_cyrl_uniranges): New
6275 arrays.
6276 (af_grek_script_class, af_cyrl_script_class): New scripts.
6277 * src/autofit/aflatin.h: Updated.
6278
Werner Lemberg2cca9662013-09-20 07:23:34 +020062792013-09-20 Werner Lemberg <wl@gnu.org>
6280
6281 * docs/CHANGES: Updated.
6282
Behdad Esfahbod31e726d2013-09-20 07:20:53 +020062832013-09-20 Behdad Esfahbod <behdad@behdad.org>
6284
6285 Fix vertical size of emboldened glyphs.
6286
6287 Cf. https://bugzilla.gnome.org/show_bug.cgi?id=686709
6288
6289 * src/base/ftsynth.c (FT_GlyphSlot_Embolden): Adjust `horiBearingY'
6290 also.
6291
Alexei Podtelezhnikov52381c12013-09-11 23:25:56 -040062922013-09-11 Alexei Podtelezhnikov <apodtele@gmail.com>
6293
6294 * include/freetype/ftoutln.h: Correct FT_Outline_Get_Orientation
6295 algorithm description.
6296
Werner Lemberg3f542492013-09-11 23:08:31 +020062972013-09-11 Werner Lemberg <wl@gnu.org>
6298
6299 [autofit] Improve Hebrew rendering.
6300
6301 This change introduces a new blue zone property
6302 `AF_BLUE_PROPERTY_LATIN_LONG' to make the auto-hinter ignore short
6303 top segments.
6304
6305 * src/autofit/afblue.dat: Fix Hebrew blue strings.
6306 Use AF_BLUE_PROPERTY_LATIN_LONG for AF_BLUE_STRING_HEBREW_TOP.
6307
6308 * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_LONG): New macro.
6309
6310 * src/autofit/afblue.c, src/autofit/afblue.h: Updated.
6311
6312 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Handle
6313 `AF_LATIN_IS_LONG_BLUE'.
6314
6315 * src/autofit/aflatin.h (AF_LATIN_IS_LONG_BLUE): New macro.
6316
Werner Lemberg85a7fdf2013-08-29 21:03:05 +020063172013-08-28 Behdad Esfahbod <behdad@google.com>
6318
6319 [sfnt] Fix frame access while reading WOFF table directory.
6320
6321 * src/sfnt/sfobjs.c (woff_open_font): Using single memory frame
6322 while reading the directory entries for the whole loop.
6323
63242013-08-29 Werner Lemberg <wl@gnu.org>
Werner Lembergd689d1c2013-08-29 17:53:40 +02006325 Behdad Esfahbod <behdad@google.com>
6326
6327 Implement support for WOFF containers.
6328
6329 We simply synthesize a SFNT from the WOFF, create a memory stream
6330 for the new data, and load the SFNT as usual.
6331
6332 Does NOT add any API to access WOFF metadata or private blocks.
6333
6334 * include/freetype/internal/tttypes.h (WOFF_HeaderRec,
6335 WOFF_TableRec): New structures.
6336
6337 * include/freetype/tttags.h (TTAG_wOFF): New macro.
6338
6339 * src/base/ftobjs.c (FT_Open_Face): Set `stream' after calling
6340 `open_face'.
6341
6342 * src/sfnt/sfobjs.c [FT_CONFIG_OPTION_SYSTEM_ZLIB]: Include
6343 `FT_GZIP_H'.
6344 (WRITE_BYTE, WRITE_USHORT, WRITE_ULONG): New temporary macros for
6345 writing to a stream.
6346 (sfnt_stream_close, compare_offsets, woff_open_font): New functions.
6347 (sfnt_open_font): Handle `TTAG_wOFF'.
6348 (sfnt_init_face): Set `stream' after calling `sfnt_open_font'.
6349
6350 * src/truetype/ttobjs.c (tt_face_init): Set `stream' after calling
6351 `sfnt->init_face'.
6352
6353 * src/base/ftobjs.c (open_face): Use a pointer to FT_Stream as an
6354 argument so that a changed stream survives.
6355 Update callers.
6356
63572013-08-28 Werner Lemberg <wl@gnu.org>
Werner Lemberge0f39ae2013-08-28 17:34:01 +02006358
Werner Lembergdc240522013-08-29 17:53:24 +02006359 [gzip] New function `FT_Gzip_Uncompress'.
6360
6361 This is modeled after zlib's `uncompress' function. We need this
6362 for WOFF support.
6363
6364 * include/freetype/ftgzip.h, src/gzip/ftgzip.c (FT_Gzip_Uncompress):
6365 New function.
6366
6367 * src/gzip/rules.mk: Rewrite to better reflect dependencies.
6368
63692013-08-28 Werner Lemberg <wl@gnu.org>
6370
Werner Lemberg5195ecd2013-08-28 17:41:21 +02006371 [autofit] Fix `make multi' compilation.
6372
6373 * src/autofit/afblue.cin, src/autofit/afblue.c: Don't include
6374 `afblue.h' but `aftypes.h'.
6375 * src/autofit/afcjk.c: Don't include `aftypes.h' but `afglobal.h'.
6376
63772013-08-28 Werner Lemberg <wl@gnu.org>
6378
Werner Lemberge0f39ae2013-08-28 17:34:01 +02006379 [autofit] Fix C++ compilation.
6380
6381 * src/autofit/afglobal.c (af_face_globals_get_metrics),
6382 src/autofit/afdummy.c (af_dflt_script_class), src/autofit/afindic.c
6383 (af_deva_script_class): Use proper casts.
6384
Behdad Esfahbodbd3849e2013-08-27 21:43:38 +020063852013-08-27 Behdad Esfahbod <behdad@google.com>
6386
Behdad Esfahbodc799dd62013-08-27 21:46:03 +02006387 * src/sfnt/ttload.c (tt_face_load_font_dir): Fix sign typos.
6388
63892013-08-27 Behdad Esfahbod <behdad@google.com>
6390
Behdad Esfahbodbd3849e2013-08-27 21:43:38 +02006391 FT_Open_Face: Improve external stream handling.
6392
6393 If the font's `clazz->init_face' function wants to swap to new
6394 stream, handling of whether original stream was external could
6395 result to either memory leak or double free. Mark externality into
6396 face flags before calling `init_face' such that the clazz can handle
6397 external streams properly.
6398
6399 * src/base/ftobjs.c (FT_Open_Face): Move code to set
6400 FT_FACE_FLAG_EXTERNAL_STREAM to...
6401 (open_face): This function.
6402
Werner Lemberg5e53db22013-08-27 18:37:39 +020064032013-08-27 Werner Lemberg <wl@gnu.org>
6404
Werner Lembergbcd8c0b2013-08-27 21:36:03 +02006405 Remove `FT_SqrtFixed' function.
6406
6407 It's no longer used.
6408
6409 * include/freetype/internal/ftcalc.h, src/base/ftcalc.c: Do it.
6410
64112013-08-27 Werner Lemberg <wl@gnu.org>
6412
Werner Lemberg5e53db22013-08-27 18:37:39 +02006413 [autofit] While tracing, report script names instead of ID values.
6414
6415 * src/autofit/afglobal.c (af_script_names) [FT_DEBUG_LEVEL_TRACE]:
6416 New array.
6417 * src/autofit/afglobal.h: Updated.
6418
6419 * src/autofit/afcjk.c (af_cjk_metrics_init_widths,
6420 af_cjk_hint_edges): Use `af_script_names'.
6421 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
6422 af_latin_hint_edges): Ditto.
6423
Werner Lemberg92f5a042013-08-26 09:22:27 +020064242013-08-26 Werner Lemberg <wl@gnu.org>
6425
Werner Lemberg278f64b2013-08-26 20:20:03 +02006426 [autofit] Report used script while hinting a glyph.
6427
6428 * src/autofit/afcjk.c (af_cjk_hint_edges), src/autofit/aflatin.c
6429 (af_latin_hint_edges): Implement it.
6430
64312013-08-26 Werner Lemberg <wl@gnu.org>
6432
Werner Lemberg371f5c32013-08-26 20:11:24 +02006433 [autofit] Add support for Hebrew script.
6434
6435 * src/autofit/afblue.dat: Add blue strings for Hebrew.
6436 * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
6437
6438 * src/autofit/aflatin.c (af_hebr_uniranges): New array.
6439 (af_hebr_script_class): New script.
6440 * src/autofit/aflatin.h, src/autofit/afscript.h: Updated.
6441
64422013-08-26 Werner Lemberg <wl@gnu.org>
6443
Werner Lemberg098121d2013-08-26 18:54:05 +02006444 [autofit] Improve tracing messages.
6445
6446 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Mention script
6447 ID in tracing message.
6448 (af_cjk_metrics_init_blues): Initialize `axis' outside of the inner
6449 loop.
6450 Improve tracing messages.
6451 (af_cjk_hint_edges) [FT_DEBUG_LEVEL_TRACE]: New variable
6452 `num_actions' to count hinting actions.
6453 Improve tracing messages.
6454
6455 * src/autofit/aflatin.c (af_latin_metrics_init_widths): Mention
6456 script ID in tracing message.
6457 (af_latin_metrics_init_blues, af_latin_hint_edges): Improve tracing
6458 messages.
6459
64602013-08-26 Werner Lemberg <wl@gnu.org>
6461
Werner Lembergffee64a2013-08-26 12:55:48 +02006462 Better tracing of loaded glyphs.
6463
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006464 Previously, the loading of a glyph was traced at level 4, if at all.
Werner Lembergffee64a2013-08-26 12:55:48 +02006465 With this change, all font loading routines emit a tracing message
6466 at level 1, making it easier to select tracing output (for example
6467 using F2_DEBUG="any:1 afhints:7 aflatin:7").
6468
6469 * src/bdf/bdfdrivr.c (BDF_Glyph_Load): Add tracing message.
6470 * src/cff/cffdrivr.c (cff_glyph_load): Ditto.
6471 * src/cff/cffgload.c (cff_decoder_prepare): Improve tracing
6472 messages.
6473 * src/cid/cidgload.c (cid_load_glyph): Use level 1 for tracing
6474 message.
6475 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Ditto.
6476 * src/pfr/pfrobjs.c (pfr_slot_load): Add tracing message.
6477 * src/truetype/ttgload.c (TT_Load_Glyph): Ditto.
6478 * src/type1/t1gload.c (T1_Load_Glyph): Ditto.
6479 * src/type42/t42objs.c (T42_GlyphSlot_Load): Ditto.
6480 * src/winfonts/winfnt.c (FNT_Load_Glyph): Ditto.
6481
64822013-08-26 Werner Lemberg <wl@gnu.org>
6483
Werner Lemberg33655a92013-08-26 09:58:50 +02006484 [autofit] Fix script selection.
6485
6486 * src/autofit/afglobal.c (af_face_globals_get_metrics): Use
6487 `AF_SCRIPT_DFLT', not value 0.
6488 Simplify code.
6489
6490 * src/autofit/afscript.h: Sort by script name.
6491
64922013-08-26 Werner Lemberg <wl@gnu.org>
6493
Werner Lemberg92f5a042013-08-26 09:22:27 +02006494 [autofit] Make `dummy' hinter work as expected.
6495
6496 * src/autofit/afdummy.c (af_dummy_hints_init): Properly set scaling
6497 information.
6498 (af_dummy_hints_apply): Scale the glyphs.
6499
Werner Lemberg8b8be782013-08-25 08:01:41 +020065002013-08-25 Werner Lemberg <wl@gnu.org>
6501
Werner Lembergc1eb4452013-08-25 19:47:26 +02006502 [autofit] Make `cjk' module use blue stringsets.
6503
6504 * src/autofit/afcjk.c (AF_CJK_MAX_TEST_CHARACTERS): Removed.
6505 (af_cjk_hani_blue_chars): Removed.
6506 (AF_CJK_BLUE_TYPE_*): Removed.
6507 (af_cjk_metrics_init_blues): Replace AF_CJK_MAX_TEST_CHARACTERS with
6508 AF_BLUE_STRING_MAX_LEN.
6509 Change loops to use offsets (in file `afblue.h') into the new arrays
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006510 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
Werner Lembergc1eb4452013-08-25 19:47:26 +02006511 Instead of three dimensions (as used in the old blue string array)
6512 we now use properties to do the same, saving one loop nesting level.
6513
6514 * src/autofit/afcjk.h: Remove old enumeration values superseded by
6515 the new data in `afblue.h'.
6516 (AF_CJK_IS_TOP_BLUE, AF_CJK_IS_HORIZ_BLUE, AF_CJK_IS_FILLED_BLUE,
6517 AF_CJK_IS_RIGHT_BLUE): New macros, to be used in
6518 `af_cjk_metrics_init_blues'.
6519 (AF_CJK_BLUE_IS_RIGHT): Remove this now redundant enum value.
6520 (AF_CJK_BLUE_IS_TOP): Renamed to...
6521 (AF_CJK_BLUE_TOP): This.
6522 (AF_CJK_MAX_BLUES): Remove.
6523 (AF_CJKAxisRec): Updated.
6524
65252013-08-25 Werner Lemberg <wl@gnu.org>
6526
Werner Lemberg5c4a23a2013-08-25 19:29:07 +02006527 [autofit] Typo.
6528
6529 * src/autofit/afblue.hin, src/autofit/afblue.c (GET_UTF8_CHAR): Use
6530 cast.
6531
65322013-08-25 Werner Lemberg <wl@gnu.org>
6533
Werner Lemberg306f8c52013-08-25 13:07:08 +02006534 [autofit] Synchronize `cjk' with `latin' module (and vice versa).
6535
6536 * src/autofit/afcjk.c (af_cjk_metrics_init_widths): Add tracing
6537 messages.
6538 (af_cjk_metrics_init_blues): Don't pass blue string array as
6539 argument but use the global array directly.
6540 Use `outline' directly.
6541 Update and add tracing messages.
6542 (af_cjk_metrics_init): Simplify code.
6543 (af_cjk_metrics_scale_dim): Improve tracing message.
6544 (af_cjk_metrics_scale): Synchronize.
6545
6546 * src/autofit/aflatin.c (af_latin_metrics_init_widths,
6547 af_latin_metrics_init_blues): Improve and add tracing messages.
6548
65492013-08-25 Werner Lemberg <wl@gnu.org>
6550
Werner Lemberg0975d682013-08-25 08:37:47 +02006551 [autofit] Make `latin' module use blue stringsets.
6552
6553 * src/autofit/aflatin.c (AF_LATIN_MAX_TEST_CHARACTERS): Removed.
6554 (af_latin_blue_chars): Removed.
6555 (af_latin_metrics_init_blues): Replace AF_LATIN_MAX_TEST_CHARACTERS
6556 with AF_BLUE_STRING_MAX_LEN.
6557 Change loops to use offsets (in file `afblue.h') into the new arrays
6558 `af_blue_stringsets' and `af_blue_strings' (in file `afblue.c').
6559 Use `AF_LATIN_IS_SMALL_TOP_BLUE' macro.
6560
6561 * src/autofit/aflatin.h: Remove old enumeration values superseded by
6562 the new data in `afblue.h'.
6563 (AF_LATIN_IS_TOP_BLUE): Updated definition.
6564 (AF_LATIN_IS_SMALL_TOP_BLUE): New macro.
6565 (AF_LATIN_MAX_BLUES): Remove.
6566 (AF_LatinAxisRec): Updated.
6567
65682013-08-25 Werner Lemberg <wl@gnu.org>
6569
Werner Lembergdb3e5b92013-08-25 08:23:22 +02006570 [autofit] Add blue stringsets.
6571
6572 * src/autofit/aftypes.h: Include `afblue.h'.
6573 (AF_ScriptClassRec): Add `blue_stringset' field.
6574 (AF_DEFINE_SCRIPT_CLASS): Updated.
6575
6576 * src/autofit/autofit.c: Include `afblue.c'.
6577
6578 * src/autofit/afcjk.c (af_hani_script_class), src/autofit/afdummy.c
6579 (af_dflt_script_class), src/autofit/afindic.c
6580 (af_deva_script_class), src/autofit/aflatin.c
6581 (af_latn_script_class), src/autofit/aflatin2.c
6582 (af_ltn2_script_class): Updated.
6583
6584 * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afblue.c'.
6585
65862013-08-25 Werner Lemberg <wl@gnu.org>
6587
Werner Lemberg8b8be782013-08-25 08:01:41 +02006588 [autofit] Introduce data file for blue strings.
6589
6590 The idea is to have a central file which gets processed by a Perl
6591 script to create proper `.c' and `.h' files using templates. There
6592 are two other reasons to do that:
6593
6594 . The data file should be easily readable. We use UTF-8 encoding
6595 which then gets converted to single bytes.
6596
6597 . Since the number of supported scripts will increase soon, the
6598 current usage of blue string arrays is a waste of space. Using
6599 the Perl script it is possible to imitate jagged arrays,
6600 defining enumeration constants as offsets into the arrays.
6601
6602 This commit only adds files without changing any functionality.
6603
6604 * src/autofit/afblue.dat: New data file.
6605 * src/tools/afblue.pl: New Perl script for processing `afblue.dat'.
6606
6607 * src/autofit/afblue.cin, src/autofit/afblue.hin: New template files
6608 for...
6609 * src/autofit/afblue.c, src/autofit/afblue.c: New source files.
6610 To avoid a dependency on Perl, we add them too.
6611
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -040066122013-08-19 Alexei Podtelezhnikov <apodtele@gmail.com>
6613
Werner Lemberg71c0ad62013-08-27 21:30:09 +02006614 [base] Enable new algorithm for `BBox_Cubic_Check'.
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -04006615
Werner Lemberg71c0ad62013-08-27 21:30:09 +02006616 * src/base/ftbbox.c: Enable new BBox_Cubic_Check algorithm, remove
6617 the old one.
6618 Improve comments.
Alexei Podtelezhnikovfc32e1c2013-08-19 22:57:05 -04006619
Werner Lemberg6bfa2632013-08-18 18:34:05 +020066202013-08-18 Werner Lemberg <wl@gnu.org>
6621
Werner Lemberg4af44442013-08-18 18:46:30 +02006622 * builds/unix/unix-def.in (freetype2.pc): Don't set executable bit.
6623
66242013-08-18 Werner Lemberg <wl@gnu.org>
6625
Werner Lemberg6bfa2632013-08-18 18:34:05 +02006626 Fix Savannah bug #39804.
6627
6628 * builds/unix/configure.raw (LIBPNG): Define and export.
6629 * builds/unix/freetype-config.in, builds/unix/freetype2.in: Handle
6630 libpng.
6631
Alexei Podtelezhnikov32a7d872013-08-17 22:19:21 -040066322013-08-17 Alexei Podtelezhnikov <apodtele@gmail.com>
6633
6634 [base] Clean up BBox_Conic_Check.
6635
6636 * src/base/ftbbox.c (BBox_Conic_Check): Remove redundant checks for
6637 extremum at the segment ends, which are already within the bbox.
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006638 Slightly modify calculations.
Alexei Podtelezhnikov32a7d872013-08-17 22:19:21 -04006639
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -040066402013-08-15 Alexei Podtelezhnikov <apodtele@gmail.com>
6641
6642 [base] Finish experimental (disabled) BBox_Cubic_Check implementation.
6643
6644 * src/base/ftbbox.c (BBox_Cubic_Check): Scale arguments to improve
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006645 accuracy and avoid overflows.
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -04006646
Alexei Podtelezhnikov61a65512013-08-13 22:28:57 -040066472013-08-13 Alexei Podtelezhnikov <apodtele@gmail.com>
6648
6649 [base] Refactor experimental (disabled) BBox_Cubic_Check.
6650
6651 * src/base/ftbbox.c (BBox_Cubic_Check): Implement the minimum search
Alexei Podtelezhnikov1a9c3d12013-08-15 22:51:42 -04006652 as the mirror image of the maximum search implemented here...
6653 (update_max): New function.
Alexei Podtelezhnikov61a65512013-08-13 22:28:57 -04006654
John Tytgat9bcfab82013-08-06 08:55:19 +020066552013-08-06 John Tytgat <John.Tytgat@esko.com>
6656
6657 Fix Savannah bug #39702.
6658
6659 * src/cff/cffload.c (cff_index_get_pointers): Check for `cur_offset
6660 != 0'; this stronger test is mandated by the CFF specification.
6661 Fix test for INDEX structures which have one or more empty entries
6662 at the end.
6663
Werner Lembergcc25e3a2013-08-05 08:46:15 +020066642013-08-05 Werner Lemberg <wl@gnu.org>
6665
Werner Lemberga32682f2013-08-06 00:21:46 +02006666 Fix gcc pragmas, part 2.
6667
6668 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
6669 TT_DotFix14_long_long): `#pragma gcc diagnostic {push,pop}' has been
6670 introduced with gcc version 4.6.
6671
66722013-08-05 Werner Lemberg <wl@gnu.org>
6673
Werner Lemberg69e524d2013-08-05 23:38:32 +02006674 Fix gcc pragmas.
6675
6676 * src/truetype/ttinterp.c (TT_MulFix14_long_long,
6677 TT_DotFix14_long_long): Older gcc versions don't accept diagnostic
6678 pragmas within a function body.
6679
66802013-08-05 Werner Lemberg <wl@gnu.org>
6681
Werner Lemberg9e6de362013-08-05 16:37:21 +02006682 Fix Savannah bug #39700.
6683
6684 * builds/unix/ftconfig.h: Synchronize with
6685 `include/freetype/config/ftconfig.h'.
6686
6687 * builds/vms/ftconfig.h: Ditto.
6688 Make the differences to the master `ftconfig.h' file as small as
6689 possible for easier maintainance.
6690
66912013-08-05 Werner Lemberg <wl@gnu.org>
6692
Werner Lembergcc25e3a2013-08-05 08:46:15 +02006693 [autofit] Improve handling of `near' points.
6694
6695 Points which are very near to each other are now marked as such.
6696 The `weak' flag is then computed by using the `in' vector of the
6697 first and the `out' vector of the last point of a group of near
6698 points.
6699
6700 For example, this fixes the rendering of glyph `Oslash' in
6701 `Roboto-Thin.ttf'.
6702
6703 * src/autofit/afhints.h (AF_Flags): New value `AF_FLAGS_NEAR'.
6704
6705 * src/autofit/afhints.c (af_glyph_hints_reload): Introduce
6706 the heuristic value `near_limit' to decide whether the current point
6707 is near to the previous one, then set `AF_FLAG_NEAR' accordingly.
6708 Store good `in' vector (of last non-near point) in
6709 `last_good_in_{x,y}' and use it as an argument to
6710 `ft_corner_is_flat' if necessary.
6711
Werner Lemberg74a9b672013-08-02 14:53:32 +020067122013-08-02 Werner Lemberg <wl@gnu.org>
6713
Werner Lemberg0d28a7d2013-08-02 22:59:43 +02006714 * include/freetype/ftcffdrv.h: Improve documentation.
6715 This is based on blog entries from David Lemon and Dave Arnold (both
6716 from Adobe) with kind permission. Dave also helped in
6717 proof-reading.
6718
67192013-08-02 Werner Lemberg <wl@gnu.org>
6720
Werner Lemberg456cc442013-08-02 20:25:21 +02006721 [autofit] Move declaration of scripts into separate file.
6722
6723 This has the benefit that we don't need to duplicate the data at
6724 different places.
6725
6726 * src/autofit/afscript.h: New file.
6727
6728 * src/autofit/aftypes.h (AF_Script): Include `afscript.h' to define
6729 the enumeration values.
6730
6731 * src/autofit/afglobal.c: Include `afscript.h' to get the script
6732 specific header files.
6733 (af_script_classes): Include `afscript.h' to fill this array.
6734
6735 * src/autofit/afpic.c: Include `afscript.h' to get the script
6736 specific header files.
6737 (autofit_module_class_pic_init): Include `afscript.h' for
6738 initialization.
6739 * src/autofit/afpic.h (AF_SCRIPT_CLASSES_COUNT,
6740 AF_SCRIPT_CLASSES_REC_COUNT): Removed. Use `AF_SCRIPT_MAX' instead.
6741
6742 * src/autofit/rules.mk (AUTOF_DRV_H): Updated.
6743
67442013-08-02 Werner Lemberg <wl@gnu.org>
6745
Werner Lemberg773601d2013-08-02 19:51:17 +02006746 [autofit] Move declaration of writing systems into separate file.
6747
6748 This has the benefit that we don't need to duplicate the data at
6749 different places.
6750
6751 * src/autofit/afwrtsys.h: New file.
6752
6753 * src/autofit/aftypes.h (AF_WritingSystem): Include `afwrtsys.h' to
6754 define the enumeration values.
6755
6756 * src/autofit/afglobal.c: Include `afwrtsys.h' to get the writing
6757 system specific header files.
6758 Include `afpic.h'.
6759 (af_writing_system_classes): Include `afwrtsys.h' to fill this
6760 array.
6761
6762 * src/autofit/afpic.c: Include `afwrtsys.h' to get the writing
6763 system specific header files.
6764 (autofit_module_class_pic_init): Include `afwrtsys.h' for
6765 initialization.
6766 * src/autofit/afpic.h (AF_WRITING_SYSTEM_CLASSES_COUNT,
6767 AF_WRITING_SYSTEM_CLASSES_REC_COUNT): Removed. Use
6768 `AF_WRITING_SYSTEM_MAX' instead.
6769
67702013-08-02 Werner Lemberg <wl@gnu.org>
6771
Werner Lemberg74a9b672013-08-02 14:53:32 +02006772 [sfnt] Fix compilation with g++.
6773
6774 * src/sfnt/pngshim.c (error_callback, read_data_from_FT_stream): Use
6775 cast.
6776 (Load_SBit_Png): Pacify compiler.
6777
Werner Lemberg89a529f2013-08-02 14:50:23 +020067782013-08-02 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6779 Werner Lemberg <wl@gnu.org>
6780
6781 [autofit] Fix `make multi'.
6782
6783 * include/freetype/config/ftconfig.h (FT_LOCAL_ARRAY,
6784 FT_LOCAL_ARRAY_DEF): New macros.
6785
6786 * src/autofit/afglobal.c (af_writing_system_classes,
6787 af_script_classes): Use FT_LOCAL_ARRAY_DEF.
6788 * src/autofit/afglobal.h: Declare `af_writing_system_classes' and
6789 `af_script_classes'.
6790 * src/autofit/afloader.c: Include `afpic.h'.
6791
Werner Lemberge8ed2d62013-08-01 12:20:20 +020067922013-08-01 Werner Lemberg <wl@gnu.org>
6793
6794 Another round of cppcheck nitpicks.
6795
6796 The call was (from the top-level of the FreeType tree):
6797
6798 cppcheck --force \
6799 --enable=all \
6800 -I /usr/include \
6801 -I /usr/local/include \
6802 -I /usr/lib/gcc/i586-suse-linux/4.7/include \
6803 -I include \
6804 -I include/freetype \
6805 -I include/freetype/config \
6806 -I include/freetype/internal \
6807 -DFT2_BUILD_LIBRARY \
6808 . &> cppcheck.log
6809
6810 using cppcheck git commit f7e93f99.
6811
6812 Note that cppcheck still can't handle `#include FOO' (with `FOO' a
6813 macro).
6814
6815 */* Improve variable scopes.
6816 */* Remove redundant initializations which get overwritten.
6817
6818 * src/gxvalid/*: Comment out redundant code or guard it with
6819 FT_DEBUG_LEVEL_TRACE.
6820
Werner Lemberg5d6a3602013-07-30 23:17:04 +020068212013-07-30 Werner Lemberg <wl@gnu.org>
6822
Werner Lemberg72f5ff52013-07-31 22:49:29 +02006823 [autofit] Introduce `writing systems'.
6824
6825 This patch adds a new top level to the auto-hinter's script class
6826 hierarchy. It defines `writing systems' which can contain multiple
6827 scripts.
6828
6829 For example, the `latin' writing system (in file `aflatin.c') is
6830 able to support scripts like Latin, Cyrillic, Armenian, etc., which
6831 can be handled similarly.
6832
6833 Scripts are now named using four-letter OpenType tags.
6834
6835 * src/autofit/aftypes.h (AF_ScriptClassRec): Move relevant members
6836 to...
6837 (AF_WritingSystemClassRec): This new structure. It holds pointers
6838 to functions which can be shared among related scripts.
6839 (AF_WritingSystem): New enumeration.
6840 (AF_Script): Revised values using four-letter tags.
6841 (AF_DEFINE_WRITING_SYSTEM_CLASS): New macro.
6842 (AF_DEFINE_SCRIPT_CLASS): Updated.
6843
6844 * src/autofit/afglobal.c (af_writing_system_classes): New global,
6845 constant array.
6846 (af_script_classes): Updated.
6847 (af_face_globals_free): Updated.
6848 Remove assertion.
6849 (af_face_globals_get_metrics): Updated.
6850
6851 * src/autofit/afglobal.h (AF_SCRIPT_FALLBACK)
6852 [!AF_CONFIG_OPTION_CJK]: Handle this case.
6853
6854 * src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
6855 Updated.
6856
6857 * src/autofit/afpic.c (autofit_module_class_pic_init): Updated;
6858 initialize structures for both writing systems and scripts.
6859 * src/autofit/afpic.h: Updated.
6860 (AF_WRITING_SYSTEM_CLASSES_GET): New macro.
6861
6862 * src/autofit/afcjk.c (af_cjk_writing_system_class): New writing
6863 system.
6864 (af_cjk_uniranges): Renamed to...
6865 (af_hani_uniranges): This.
6866 (af_cjk_script_class): Reduced and renamed to...
6867 (af_hani_script_class): This.
6868 * src/autofit/afcjk.h: Updated.
6869
6870 * src/autofit/afdummy.c (af_dummy_writing_system_class): New writing
6871 system.
6872 (af_dummy_script_class): Reduced and renamed to...
6873 (af_dflt_script_class): This.
6874 * src/autofit/afdummy.h: Updated.
6875
6876 * src/autofit/afindic.c (af_indic_writing_system_class): New writing
6877 system.
6878 (af_indic_uniranges): Renamed to...
6879 (af_deva_uniranges): This.
6880 (af_indic_script_class): Reduced and renamed to...
6881 (af_deva_script_class): This.
6882 * src/autofit/afcjk.h: Updated.
6883
6884 * src/autofit/aflatin.c (af_latin_writing_system_class): New writing
6885 system.
6886 (af_latin_uniranges): Renamed to...
6887 (af_latn_uniranges): This.
6888 (af_latin_script_class): Reduced and renamed to...
6889 (af_latn_script_class): This.
6890 * src/autofit/aflatin.h: Updated.
6891
6892 * src/autofit/aflatin2.c (af_latin2_writing_system_class): New
6893 writing system.
6894 (af_latin2_uniranges): Renamed to...
6895 (af_ltn2_uniranges): This.
6896 Synchronize ranges with `latin'.
6897 (af_latin2_script_class): Reduced and renamed to...
6898 (af_ltn2_script_class): This.
6899 * src/autofit/aflatin2.h: Updated.
6900
69012013-07-30 Werner Lemberg <wl@gnu.org>
6902
Werner Lemberg5d6a3602013-07-30 23:17:04 +02006903 [autofit] Variable renaming.
6904
6905 * src/autofit/aftypes.h (AF_ScriptMetricsRec):
6906 s/clazz/script_class/.
6907 Update all users.
6908
suzuki toshiya2b29ed62013-07-30 13:55:29 +090069092013-07-30 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6910
6911 Ignore libpng-config under cross-building configuration,
6912 because it will return the flags for the hosting environment.
6913
6914 * builds/unix/configure.raw: Ignore libpng-config when
6915 `cross_compiling' == yes.
6916
suzuki toshiyaf2e7f1e2013-07-30 13:32:57 +090069172013-07-30 Behdad Esfahbod <behdad@google.com>
6918
6919 Prevent division by zero by a transparent color.
6920
6921 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra):
6922 Return 0 immediately, when alpha channel is zero.
6923
Behdad Esfahbod21c32b02013-07-25 21:53:18 +020069242013-07-25 Behdad Esfahbod <behdad@google.com>
6925
6926 Add FT_FACE_FLAG_COLOR and FT_HAS_COLOR.
6927
6928 Also disambiguate Google's color bitmap tables.
6929
6930 * include/freetype/freetype.h (FT_FACE_FLAG_COLOR, FT_HAS_COLOR):
6931 New macros.
6932
6933 * include/freetype/internal/tttypes.h (TT_SbitTableType): Add
6934 TT_SBIT_TABLE_TYPE_CBLC.
6935
6936 * src/sfnt/sfobjs.c (sfnt_load_face): Handle FT_FACE_FLAG_COLOR.
6937
6938 * src/sfnt/ttsbit.c (tt_face_load_sbit,
6939 tt_face_load_strike_metrics, tt_face_load_sbit_image): Handle
6940 TT_SBIT_TABLE_TYPE_CBLC.
6941
suzuki toshiyab4725cb2013-07-24 14:25:39 +090069422013-07-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
6943
6944 [sfnt] Fix for `make multi' target.
6945
6946 * src/sfnt/pngshim.c (Load_SBit_Png): Use FT_LOCAL_DEF().
6947
Werner Lemberg6a7df622013-07-20 10:48:37 +020069482013-07-20 Werner Lemberg <wl@gnu.org>
6949
6950 * docs/INSTALL.GNU: Updated.
6951
Behdad Esfahbodff269522013-07-20 08:02:39 +020069522013-07-20 Behdad Esfahbod <behdad@google.com>
6953
6954 [sfnt] Fix `sbix' table version handling.
6955
6956 * src/sfnt/ttsbit.c (tt_face_load_sbit) [TT_SBIT_TABLE_TYPE_SBIX]:
6957 USHORT version numbers are to be considered as `minor'.
6958
Werner Lemberg05c14212013-07-19 23:11:23 +020069592013-07-19 Werner Lemberg <wl@gnu.org>
6960
6961 [autofit] Fix segment classification for blue zones.
6962
6963 The old code (essentially unchanged since the very beginning)
6964 incorrectly handled this configuration
6965
6966 x -o- x
6967 / \
6968 / \
6969 / \
6970 o o
6971
6972 as flat and this
6973
6974 o o
6975 / /
6976 x| x|
6977 | |
6978 o---------------o
6979
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006980 as round. (`o' and `x' are on and off points, respectively).
Werner Lemberg05c14212013-07-19 23:11:23 +02006981
6982 This is a major change which should improve the rendering results
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02006983 enormously for many TrueType fonts, especially in the range approx.
Werner Lemberg05c14212013-07-19 23:11:23 +02006984 20-40ppem, fixing the appearance of many overshoots.
6985
6986 * src/autofit/aflatin.c (af_latin_metrics_init_blues): Look at the
6987 first and last points of the segment, not the points right before
6988 and after.
6989
69902013-07-19 Behdad Esfahbod <behdad@google.com>
Werner Lemberg01705392013-07-18 13:13:12 +02006991
Behdad Esfahbod778a7e62013-07-19 14:28:28 +02006992 [sfnt] `sbix' fix-ups.
6993
6994 * src/sfnt/sfobjs.c (sfnt_load_face): Apple's `sbix' color bitmaps
6995 are rendered scaled and then the `glyf' outline rendered on top. We
6996 don't support that yet, so just ignore the `glyf' outline and
6997 advertise it as a bitmap-only font.
6998
6999 * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
7000 [TT_SBIT_TABLE_TYPE_SBIX]: Return metrics in 26.6 units.
7001 (tt_face_load_sbix_image): Typo.
7002
70032013-07-18 Behdad Esfahbod <behdad@google.com>
7004
Werner Lemberg01705392013-07-18 13:13:12 +02007005 [sfnt] Add support for Apple's `sbix' color bitmap table.
7006
7007 * include/freetype/internal/tttypes.h (TT_SBit_MetricsRec): Widen
7008 fields to FT_Short and FT_UShort, respectively.
7009 (TT_SBitTableType): New enumeration.
7010 (TT_FaceRec): Add `sbit_table_type' field.
7011
7012 * include/freetype/tttags.h (TTAG_sbix): New macro.
7013
7014 * src/sfnt/pngshim.c (Load_SBit_Png): Pass a more generic
7015 FT_GlyphSlot argument instead FT_Bitmap.
7016 Add flag to control map and metrics handling.
7017 Update all users.
7018
7019 * src/sfnt/ttsbit.c: Include `ttmtx.h'.
7020 (tt_face_load_eblc): Renamed to...
7021 (tt_face_load_sbit): This.
7022 Handlic `sbix' bitmaps.
7023 (tt_face_free_eblc): Renamed to...
7024 (tt_face_load_sbit): This.
7025 Updated.
7026 (tt_face_load_strike_metrics): Handle `sbix' bitmaps.
7027 (tt_face_load_sbix_image): New function.
7028 (tt_sbit_decoder_alloc_bitmap, tt_sbit_decoder_load_image,
7029 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
7030 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
7031 tt_sbit_decoder_load_image, tt_sbit_decoder_load_bitmap): Don't pass
7032 and handle load flags.
7033 (tt_sbit_decoder_load_bitmap) [!FT_CONFIG_OPTION_USE_PNG]: Better
7034 handle formats 17-19.
7035 Move color to grayscale conversion to...
7036 (tt_face_load_sbit_image): Here.
7037 Handle `sbix' bitmaps.
7038
7039 * src/sfnt/pngshim.h: Updated.
7040 * src/sfnt/ttsbit.h: Updated.
7041 * src/sfnt/sfdriver.c: Updated.
7042
Werner Lemberg274207e2013-07-18 12:38:57 +020070432013-07-18 Werner Lemberg <wl@gnu.org>
7044
7045 [sfnt] Ignore invalid magic number in `head' or `bhed'.
7046
7047 Other font engines seem to ignore it also. Problem reported by
7048 Hin-Tak Leung <htl10@users.sourceforge.net>.
7049
7050 * src/sfnt/ttload.c (check_table_dir): Don't abort but warn only if
7051 we have an invalid magic number.
7052
Werner Lemberg9a7951d2013-07-16 15:25:24 +020070532013-07-16 Werner Lemberg <wl@gnu.org>
7054
7055 [smooth] Fix segfault caused by previous commit.
7056
7057 * src/smooth/ftgrays.c (gray_set_cell): Always compute
7058 `ras.invalid'.
7059
David Turnera5f33ee2013-07-16 12:40:03 +020070602013-07-16 David Turner <digit@google.com>
7061
David Turner89929ec2013-07-16 13:36:07 +02007062 [smooth] Improve performance.
7063
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02007064 Provide a work-around for an ARM-specific performance bug in GCC.
David Turner89929ec2013-07-16 13:36:07 +02007065 This speeds up the rasterizer by more than 5%.
7066
7067 Also slightly optimize `set_gray_cell' and `gray_record_cell' (which
7068 also improves performance on other platforms by a tiny bit (<1%).
7069
7070 * src/smooth/ftgrays.c (FT_DIV_MOD): New macro.
7071 Use it where appropriate.
7072
7073 (gray_record_cell, gray_set_cell, gray_move_to,
7074 gray_convert_glyph_inner): Streamline condition handling.
7075
70762013-07-16 David Turner <digit@google.com>
7077
David Turnerf66d48e2013-07-16 13:18:00 +02007078 [truetype] Add assembler code for TT_MulFix14 and TT_DotFix14.
7079
7080 This patch provides slightly optimized versions for ARM, x86, and
7081 x86_64 CPUs if built with GCC.
7082
7083 Also remove some dead code.
7084
7085 * src/truetype/ttinterp.c (TT_MulFix14_arm, TT_MulFix14_long_long,
7086 TT_DotFix14_long_long): New functions.
7087
70882013-07-16 David Turner <digit@google.com>
7089
David Turnerb2890882013-07-16 12:52:18 +02007090 Optimize FT_MulFix for x86_64 GCC builds.
7091
7092 This patch provides an optimized `FT_MulFix' implementation for
7093 x86_64 machines when FreeType is built with GCC, or compatible
7094 compilers like Clang.
7095
7096 Example:
7097 bin/ftbench -p -t 5 -s 14 -f 0008 Arial.ttf
7098
7099 Before:
7100
7101 Load 4.863 us/op
7102 Load_Advances (Normal) 4.816 us/op
7103 Load_Advances (Fast) 0.028 us/op
7104 Render 2.753 us/op
7105 Get_Glyph 0.463 us/op
7106 Get_CBox 0.077 us/op
7107 Get_Char_Index 0.023 us/op
7108 Iterate CMap 13.898 us/op
7109 New_Face 12.368 us/op
7110 Embolden 0.028 us/op
7111 Get_BBox 0.302 us/op
7112
7113 After:
7114
7115 Load 4.617 us/op
7116 Load_Advances (Normal) 4.645 us/op
7117 Load_Advances (Fast) 0.027 us/op
7118 Render 2.789 us/op
7119 Get_Glyph 0.460 us/op
7120 Get_CBox 0.077 us/op
7121 Get_Char_Index 0.024 us/op
7122 Iterate CMap 13.403 us/op
7123 New_Face 12.278 us/op
7124 Embolden 0.028 us/op
7125 Get_BBox 0.301 us/op
7126
7127 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
7128 (FT_MulFix_x86_64): New function.
7129
71302013-07-16 David Turner <digit@google.com>
7131
David Turnera5f33ee2013-07-16 12:40:03 +02007132 Speed up ARMv7 support.
7133
7134 When building for ARMv7 with thumb2 instructions, the optimized
7135 `FT_MulFix_arm' assembly routine was not being used.
7136
7137 The reason for this is in the `ftconfig.h' header, namely:
7138
7139 - The assembly routine uses the `smull' instruction which is not
7140 available when generating Thumb-1 machine code. It is available
7141 in Thumb-2 mode, though.
7142
7143 - The header was written a long time ago before Thumb-2 became
7144 widely popular (e.g. with Android). So it simply doesn't use the
7145 assembly routine if the `__thumb__' built-in macro is defined.
7146
7147 - When compiling in Thumb-2 mode, the compiler will define both
7148 `__thumb__' and `__thumb2__'.
7149
7150 By checking for `(__thumb2__ || !__thumb__)', we ensure that the
7151 assembly routine is only avoided when generating Thumb-1 code.
7152
7153 Given that this is performance-sensitive function, this improves
7154 `ftbench' as follows on a Galaxy Nexus:
7155
7156 Before (us/op) After (us/op)
7157
7158 - loading Arial.ttf glyphs at 14 ppem [1]
7159
7160 Load 34.285 33.098
7161
7162 - same operation with the light auto-hinter [2]
7163
7164 Load 31.317 29.590
7165
7166 - same operation without hinting [3]
7167
7168 Load 6.143 5.376
7169
7170 - loading Arial.ttf advances at 14 ppem [4]
7171
7172 Load_Advances (normal) 34.216 33.016
7173 Load_Advances (fast) 0.176 0.176
7174
7175 [1] ftbench -t 5 -p -s 14 -b a -f 0008 Arial.ttf
7176 [2] ftbench -t 5 -p -s 14 -b a -r 1 -f 0028 Arial.ttf
7177 [3] ftbench -t 5 -p -s 14 -b a -f 000a Arial.ttf
7178 [4] ftbench -t 5 -p -s 14 -b b -f 0008 Arial.ttf
7179
7180 * builds/unix/ftconfig.in, include/freetype/config/ftconfig.h
7181 (FT_MULFIX_ASSEMBLER): Fix handling for ARMv7.
7182
Werner Lemberge12fc772013-06-28 07:57:32 +020071832013-06-28 Werner Lemberg <wl@gnu.org>
7184
7185 * docs/CHANGES: Updated.
7186
Werner Lemberg680c1d42013-06-27 17:21:59 +020071872013-06-27 Werner Lemberg <wl@gnu.org>
7188
7189 * src/winfonts/winfnt.c (FNT_Load_Glyph): Fix bitmap width guard.
7190
Werner Lembergc7cc9eb2013-06-25 07:24:02 +020071912013-06-25 Werner Lemberg <wl@gnu.org>
7192
Werner Lembergb8850fc2013-06-26 12:22:10 +02007193 [cff] Add darkening limit to `darkening-parameters'.
7194
7195 * src/cff/cffdrivr.c (cff_property_set): Add check.
7196
71972013-06-25 Werner Lemberg <wl@gnu.org>
7198
Werner Lemberg89ca1fd2013-06-25 23:28:02 +02007199 [cff] Add `darkening-parameters' property.
7200
7201 * include/freetype/ftcffdrv.h: Document it.
7202
7203 * src/cff/cffdrivr.c (cff_property_set, cff_property_get): Handle
7204 `darkening-parameters' property.
7205
7206 * src/cff/cf2font.h (CF2_FontRec): Add `darkenParams' array.
7207
7208 * src/cff/cf2font.c (cf2_computeDarkening): Add `darkenParams'
7209 argument and use it.
7210 Update all callers.
7211
7212 * src/cff/cf2ft.c (cf2_decoder_parse_charstrings): Copy
7213 `darken_params' values.
7214
7215 * src/cff/cffobjs.h (CFF_DriverRec): Add `darken_params' array.
7216
7217 * src/cff/cffobjs.c (cff_driver_init): Set default values for
7218 `darken_params'.
7219
72202013-06-25 Werner Lemberg <wl@gnu.org>
7221
Werner Lembergfad93262013-06-25 10:41:37 +02007222 [docmaker] Code shuffling.
7223
7224 * src/tools/docmaker/tohtml.py (re_url): Move regexp...
7225 * src/tools/docmaker/sources.py: ... to this file.
7226
72272013-06-25 Werner Lemberg <wl@gnu.org>
7228
Werner Lemberg8bdc4072013-06-25 10:20:53 +02007229 [docmaker] Remove unused functions.
7230
7231 * src/tools/docmaker/content.py (DocMarkup.get_start,
7232 DocBlock.get_markup_name): Removed.
7233 * src/tools/docmaker/tohtml.py (html_quote0, dump_html_code,
7234 HtmlFormatter.make_html_words): Removed.
7235
72362013-06-25 Werner Lemberg <wl@gnu.org>
7237
Werner Lembergffb8b472013-06-25 09:09:30 +02007238 * builds/freetype.mk (dll): Remove target.
7239
7240 Problem reported by Jörg Günnewig <joerg.guennewig@googlemail.com>.
7241
72422013-06-25 Werner Lemberg <wl@gnu.org>
7243
Werner Lembergc7cc9eb2013-06-25 07:24:02 +02007244 [docmaker] Recognise URLs.
7245
7246 * src/tools/docmaker/tohtml.py (re_url): New regular expression.
7247 (make_html_para): Use it.
7248
Werner Lemberg25b7da52013-06-19 10:23:36 +020072492013-06-19 Werner Lemberg <wl@gnu.org>
7250
Werner Lembergfe4f5712013-06-19 23:27:47 +02007251 * Version 2.5.0.1 released.
7252 ===========================
7253
7254
7255 Tag sources with `VER-2-5-0-1'.
7256
7257 * include/freetype/config/ftoption.h: Undefine
7258 CFF_CONFIG_OPTION_OLD_ENGINE.
7259 * devel/ftoption.h: Define CFF_CONFIG_OPTION_OLD_ENGINE.
7260
72612013-06-19 Werner Lemberg <wl@gnu.org>
7262
Werner Lemberg609f0ca2013-06-19 14:41:47 +02007263 * builds/unix/install.mk (install): Don't create `cache' directory.
7264
7265 Found by Peter Breitenlohner <peb@mppmu.mpg.de>.
7266
72672013-06-19 Werner Lemberg <wl@gnu.org>
7268
Werner Lemberg25b7da52013-06-19 10:23:36 +02007269 * Version 2.5.0 released.
7270 =========================
7271
7272
7273 Tag sources with `VER-2-5-0'.
7274
7275 * docs/VERSION.DLL: Update documentation and bump version number to
7276 2.5.0.
7277
7278 * README, Jamfile (RefDoc),
7279 builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
7280 builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
7281 builds/win32/vc2010/freetype.vcxproj, builds/win32/vc2010/index.html,
7282 builds/win32/visualc/freetype.dsp,
7283 builds/win32/visualc/freetype.vcproj,
7284 builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
7285 builds/win32/visualce/freetype.vcproj,
7286 builds/win32/visualce/index.html,
7287 builds/wince/vc2005-ce/freetype.vcproj,
7288 builds/wince/vc2005-ce/index.html,
7289 builds/wince/vc2008-ce/freetype.vcproj,
7290 builds/wince/vc2008-ce/index.html: s/2.4.12/2.5.0/, s/2412/250/.
7291
7292 * include/freetype/freetype.h (FREETYPE_MINOR): Set to 5.
7293 (FREETYPE_PATCH): Set to 0.
7294
7295 * builds/unix/configure.raw (version_info): Set to 16:2:10.
7296
7297 * src/base/ftobjs.c (FT_Open_Face): Pacify compiler.
7298 * src/truetype/ttinterp.c (Ins_MSIRP, Ins_MIRP): Ditto.
7299
Werner Lembergf56691a2013-06-18 10:17:48 +020073002013-06-18 Werner Lemberg <wl@gnu.org>
7301
7302 Fix Savannah bug #39269.
7303
7304 * src/base/ftgloadr.c (FT_GlyphLoader_CheckPoints): Free memory in
7305 case of reacollocation failures.
7306
Andrew Church67cf7a82013-06-18 09:35:34 +020073072013-06-18 Andrew Church <achurch+savannah@achurch.org>
7308
7309 Fix Savannah bug #39266.
7310
7311 If memory allocations fail at certain points while opening a font,
7312 FreeType can either crash due to a NULL dereference or leak memory.
7313
7314 * include/freetype/internal/ftobjs.c (FT_Face_InternalRec,
7315 FT_LibraryRec): Make `refcount' a signed integer. If, for example,
7316 FT_Open_Face() fails in a memory allocation before the face's
7317 reference count is set to 1, a subsequent `FT_Done_Library' call
7318 would otherwise loop over `FT_Done_Face' 2^32 times before freeing
7319 the face.
7320
7321 * src/base/ftobjs.c (open_face): Initialize `stream' and friends
7322 earlier.
7323 (FT_Open_Face) <Fail>: Behave correctly if `node' is NULL.
7324 (FT_Destroy_Module) <Fail>: Check that `renderer_clazz' is valid.
7325
73262013-06-14 Werner Lemberg <wl@gnu.org>
Werner Lembergd7e34442013-06-14 18:33:39 +02007327
7328 * src/smooth/ftgrays.c One final pragma to silence 64-bit MSVC.
7329
Dave Arnoldcb23a622013-06-13 07:46:32 +020073302013-06-06 Dave Arnold <darnold@adobe.com>
7331 Werner Lemberg <wl@gnu.org>
7332
7333 [cff] Add code to Adobe's engine to handle ppem > 2000.
7334
7335 * src/cff/cffgload.c (cff_slot_load): If we get
7336 FT_Err_Glyph_Too_Big, retry unhinted and scale up later on.
7337
Andrew Church67cf7a82013-06-18 09:35:34 +020073382013-06-12 Werner Lemberg <wl@gnu.org>
Werner Lemberg25b6e602013-06-12 11:06:34 +02007339
Werner Lemberg294ce112013-06-12 23:33:11 +02007340 Another try on pragmas.
7341
7342 * include/freetype/internal/ftdebug.h: Move pragmas to...
7343 * include/freetype/internal/internal.h: ... this file since it gets
7344 included by all source files.
7345 * include/freetype/internal/ftserv.h: Remove pragma which has no
7346 effect.
7347
Dave Arnoldcb23a622013-06-13 07:46:32 +020073482013-06-12 Werner Lemberg <wl@gnu.org>
Werner Lemberg294ce112013-06-12 23:33:11 +02007349
Werner Lemberg25b6e602013-06-12 11:06:34 +02007350 * include/freetype/internal/ftdebug.h: Disable MSVC warning C4127.
7351
7352 This partially undoes commit 3f6e0e0c.
7353
Werner Lembergc06889e2013-06-12 10:58:06 +020073542013-06-12 Werner Lemberg <wl@gnu.org>
7355
7356 More compiler warning fixes.
7357
7358 */*: Use cast to `FT_Bool' (or `Bool') where appropriate.
7359
Werner Lemberg99e60d82013-06-10 01:44:37 +020073602013-06-10 Werner Lemberg <wl@gnu.org>
7361
Werner Lemberg5e094c62013-06-10 14:59:21 +02007362 [truetype] Improve handling of broken sbit advance widths.
7363
7364 * src/truetype/ttgload.c (TT_Load_Glyph): Use the glyph's (scaled)
7365 `linearHoriAdvance' if the sbit's `horiAdvance' value is zero.
7366
7367 Cf. font `Fixedsys Excelsior' v3.01 (FSEX300.ttf), glyph A, 16ppem.
7368
73692013-06-10 Werner Lemberg <wl@gnu.org>
7370
Werner Lemberga25ecfd2013-06-10 12:57:16 +02007371 [sfnt] Improve embedded bitmap tracing.
7372
7373 * src/base/ftobjs.c (FT_Request_Size): Move trace message regarding
7374 bitmap strike match to...
7375 (FT_Match_Size): This function.
7376
7377 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_metrics,
7378 tt_sbit_decoder_load_byte_aligned, tt_sbit_decoder_load_bit_aligned,
7379 tt_sbit_decoder_load_compound, tt_sbit_decoder_load_png,
7380 tt_sbit_decoder_load_image): Decorate with tracing messages.
7381
73822013-06-10 Werner Lemberg <wl@gnu.org>
7383
Werner Lemberg99e60d82013-06-10 01:44:37 +02007384 Fix Savannah bug #39160.
7385
7386 * src/truetype/ttinterp.c (Ins_SDPVTL): Set projection vector too
7387 for the degenerate case.
7388
Werner Lemberg2ba871b2013-06-09 08:20:54 +020073892013-06-09 David Turner <digit@google.com>
7390
7391 * src/cache/ftcmanag.c (FTC_Manager_Reset): Add missing cache flush.
7392
7393 This code, present since eight(!) years in the unused `CACHE'
7394 branch, has been forgotten to apply to the master branch. It's
7395 really amazing that noone has ever complained since
7396 `FTC_Manager_Reset' is pretty useless without flushing the cache.
7397
Werner Lemberg85fd84b2013-06-07 17:10:21 +020073982013-06-07 Werner Lemberg <wl@gnu.org>
7399
Werner Lemberg3f6e0e02013-06-07 18:10:40 +02007400 Add and improve pragmas for MSVC compiler.
7401
7402 * include/freetype/internal/ftdebug.h: Remove pragmas.
7403 * include/freetype/internal/ftserv.h: Use push and pop for pragmas.
7404 * include/freetype/internal/ftvalid.h: Handle warning C4324.
7405 * src/base/ftobjs.c: Use push and pop for pragmas.
7406 * src/gzip/ftgzip.c: Handle warning C4244.
7407
74082013-06-07 Werner Lemberg <wl@gnu.org>
7409
Werner Lemberg85fd84b2013-06-07 17:10:21 +02007410 [cff] s/cf2_getGlyphWidth/cf2_getGlyphOutline/.
7411
7412 * src/cff/cf2font.c, src/cff/cf2font.h, src/cff/cf2ft.c: Do it.
7413
Werner Lemberg4447b2c2013-06-06 21:28:36 +020074142013-06-06 Dave Arnold <darnold@adobe.com>
7415
7416 [cff] Add early exit feature for width-only calls.
7417
7418 This is for `FT_Get_Advance'.
7419
7420 There are 7 places where the spec says the width can be defined:
7421
7422 hstem/hstemhm
7423 vstem/vstemhm
7424 cntrmask/hintmask
7425 hmoveto
7426 vmoveto
7427 rmoveto
7428 endchar
7429
7430 * src/cff/cf2intrp.c (cf2_doStems): Exit early for width-only calls,
7431 if possible.
7432
7433 (cf2_interpT2CharString) <cf2_cmdHSTEM>, <cf2_cmdVSTEM>,
7434 <cf2_cmdVMOVETO>, <cf2_cmdENDCHAR>, <cf2_cmdHINTMASK>,
7435 <cf2_cmdRMOVETO>, <cf2_cmdHMOVETO>: Exit early for width-only calls.
7436
Werner Lembergbadf3172013-06-06 09:16:38 +020074372013-06-06 Werner Lemberg <wl@gnu.org>
7438
7439 Next round of compiler fixes.
7440
7441 * builds/win32/ftdebug.c, builds/wince/ftdebug.c (ft_debug_init):
7442 Add proper cast.
7443
7444 * include/freetype/internal/ftserv.h (FT_SERVICE_UNAVAILABLE): Fix
7445 cast.
7446 * include/freetype/internal/ftstream.h: Decorate stream and frame
7447 macros with `FT_Long' and `FT_ULong' as appropriate.
7448
7449 * src/base/ftrfork.c (raccess_guess_darwin_hfsplus,
7450 raccess_guess_darwin_newvfs): Use cast.
7451
7452 * src/bdf/bdflib.c (_bdf_set_default_spacing): Use cast.
7453
7454 * src/cache/ftcmanag.c (FTC_Manager_Check): Fix cast.
7455 * src/cache/ftcmanag.h (FTC_ManagerRec): Ditto.
7456
7457 * src/cff/cf2arrst.c (cf2_arrstack_setNum_Elements): Use cast.
7458 * src/cff/cf2ft.c (cf2_freeSeacComponent): Ditto.
7459 * src/cff/cffobjs.c (remove_subset_prefix, remove_style): Ditto.
7460
7461 * src/cid/cidparse.c (cid_parser_new): Use cast.
7462
7463 * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Use cast.
7464
7465 * src/psaux/psobjs.c (reallocate_t1_table): Fix argument type.
7466
7467 * src/raster/ftraster.c (ft_black_reset): Use cast.
7468
7469 * src/truetype/ttgxvar.c (FT_Stream_FTell): Use cast.
7470 (ALL_POINTS): Fix cast.
7471
7472 * src/type1/t1driver.c (t1_ps_get_font_value): Add casts.
7473 * src/type1/t1parse.c (T1_Get_Private_Dict): Add cast.
7474
Dave Arnoldc3782492013-06-05 19:57:55 +020074752013-06-05 Dave Arnold <darnold@adobe.com>
7476
7477 Fix more MSVC Win32 compiler warnings.
7478
7479 * src/base/ftobjs.c: Fix typo in MS pragma.
7480
7481 * src/base/bdflib.c (_bdf_set_default_spacing, _bdf_add_property):
7482 `lineno' is only used in debug mode.
7483
7484 * src/cff/cf2ft.c (cf2_builder_moveTo): `params' is only used in
7485 debug mode.
7486
Werner Lemberg45392b72013-06-05 13:43:20 +020074872013-06-05 Werner Lemberg <wl@gnu.org>
7488
7489 Fix compiler warnings.
7490
7491 * include/freetype/internal/ftmemory.h: Decorate memory allocation
7492 macros with `FT_Long' where appropriate.
7493 Remove duplicate of FT_MEM_QRENEW_ARRAY definition.
7494
7495 * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use
7496 cast.
7497
7498 * src/base/ftobjs.c: Add warning disabling pragma for MSVC while
7499 including `md5.c'.
7500
7501 * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdESC>: Add
7502 cast.
7503
7504 * src/sfnt/ttsbit.c (tt_sbit_decoder_load_compound): Fix casts.
7505 (tt_sbit_decoder_load_bitmap): Beautification.
7506
7507 * src/smooth/ftsmooth.c (ft_smooth_render_generic): Initialize
7508 variables (earlier).
7509
7510 * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Pacify compiler.
7511
7512 * src/truetype/ttgxvar.c (TT_Get_MM_Var): Use unsigned constants
7513 where appropriate.
7514
7515 * src/type1/t1load.c (T1_Get_MM_Var): Ditto.
7516
Werner Lembergdc624ca2013-06-04 10:30:48 +020075172013-06-04 Werner Lemberg <wl@gnu.org>
7518
Werner Lembergd9634982013-06-04 20:18:57 +02007519 * src/cff/cf2font.c (cf2_getGlyphWidth): Initialize `advWidth'.
7520
7521 Problem reported by Ingmar Sittl <ingmar.sittl@elektrobit.com>.
7522
75232013-06-04 Werner Lemberg <wl@gnu.org>
7524
Werner Lembergdc624ca2013-06-04 10:30:48 +02007525 Apply fixes for cppcheck nitpicks.
7526
7527 http://cppcheck.sourceforge.net/
7528
Werner Lemberg8d8508e2013-06-04 13:09:01 +02007529 The call was (from the top-level of the FreeType tree):
7530
7531 cppcheck --force \
7532 --enable=all \
7533 -I include \
7534 -I include/freetype/ \
7535 -I include/freetype/config/ \
7536 -I include/freetype/internal/ \
7537 . &> cppcheck.log
7538
Werner Lembergdc624ca2013-06-04 10:30:48 +02007539 Note that the current version heavily chokes on FreeType, delivering
Werner Lemberg8d8508e2013-06-04 13:09:01 +02007540 many wrong results. I will report those issues to the cppcheck team
Werner Lembergdc624ca2013-06-04 10:30:48 +02007541 so that a newer version gives improved results hopefully.
7542
7543 */* Improve variable scopes.
7544 */* Remove redundant initializations which get overwritten.
7545
Werner Lemberge8ed2d62013-08-01 12:20:20 +02007546 * src/base/ftmac.c, builds/mac/ftmac.c (count_faces_scalable):
Werner Lembergdc624ca2013-06-04 10:30:48 +02007547 Remove unused variable.
7548
7549 * src/base/ftdbgmem.c (ft_mem_table_destroy): `table' can't be zero.
7550
7551 * src/gxvalid/gxvkern.c (gxv_kern_subtable_fmt1_entry_validate):
7552 Remove functionless code.
7553
7554 * src/tools/ftrandom.c (main): Fix memory leak.
7555
Werner Lemberg2429dc32013-06-03 12:41:58 +020075562013-06-03 Werner Lemberg <wl@gnu.org>
7557
7558 Add CFF_CONFIG_OPTION_OLD_ENGINE configuration option.
7559
7560 This controls whether the old FreeType CFF engine gets compiled into
7561 FreeType. It is now disabled by default.
7562
7563 * devel/ftoption.h, include/freetype/config/ftoption.h
7564 (CFF_CONFIG_OPTION_OLD_ENGINE): New macro.
7565
7566 * src/cff/cffdrivr.c (cff_property_set), src/cff/cffgload.c
7567 (CFF_Operator, cff_argument_counts, cff_builder_add_point,
7568 cff_operator_seac, cff_decoder_parse_charstrings, cff_slot_load),
7569 src/cff/cffgload.h, src/cff/cffobjs.c (cff_driver_init): Use
7570 CFF_CONFIG_OPTION_OLD_ENGINE to guard the affected code.
7571
7572 * docs/CHANGES: Updated.
7573
Werner Lembergf9cceeb2013-06-02 23:38:13 +020075742013-06-02 Werner Lemberg <wl@gnu.org>
7575
7576 Fix PNG library handling.
7577
7578 * builds/unix/configure.raw: Don't use LIBPNG_LIBS but
7579 LIBPNG_LDFLAGS.
7580
Behdad Esfahbod760d3422013-05-29 11:36:18 +020075812013-05-23 Behdad Esfahbod <behdad@google.com>
7582
7583 Add support for color embedded bitmaps (eg. color emoji).
7584
7585 A new load flag, FT_LOAD_COLOR, makes FreeType load color
7586 embedded-bitmaps, following this draft specification
7587
7588 https://color-emoji.googlecode.com/git/specification/v1.html
7589
7590 which defines two new SFNT tables, `CBDT' and `CBLC' (named and
7591 modeled after `EBDT' and `EBLC', respectively). The color bitmaps
7592 are stored in the new FT_PIXEL_MODE_BGRA format to represent BGRA
7593 pre-multiplied sRGB images. If PNG support is available, PNG color
7594 images as defined in the same proposed specification are supported
7595 also.
7596
7597 Note that color bitmaps are converted to grayscale if client didn't
7598 ask for color.
7599
7600 * builds/unix/configure.raw: Search for libpng.
7601 Add `--without-png' option.
7602
7603 * devel/ftoption.h, include/freetype/config/ftoption.h
7604 (FT_CONFIG_OPTION_USE_PNG): New macro.
7605
7606 * include/freetype/freetype.h (FT_LOAD_COLOR): New load flag.
7607
7608 * include/freetype/ftimage.h (FT_Pixel_Mode): Add
7609 `FT_PIXEL_MODE_BGRA'.
7610
7611 * include/freetype/tttags.h (TTAG_CBDT, TTAG_CBLC): New tags.
7612
7613 * src/base/ftbitmap.c (FT_Bitmap_Embolden): Updated.
7614 (ft_gray_for_premultiplied_srgb_bgra): New function.
7615 (FT_Bitmap_Convert): Handle FT_PIXEL_MODE_BGRA.
7616
7617 * src/sfnt/pngshim.c, src/sfnt/pngshim.h: New files.
7618
7619 * src/sfnt/sfnt.c: Include `pngshim.c'.
7620
7621 * src/sfnt/ttsbit.c: Include FT_BITMAP_H and `pngshim.h'
7622 (tt_face_load_eblc): Load `CBLC'.
7623 (tt_sbit_decoder_init): Load `CBDT'.
7624 (tt_sbit_decoder_alloc_bitmap): Pass load flags to select between
7625 color and grayscale bitmaps.
7626 Set `num_grays'. This is used by `ftview' to choose the blending
7627 algorithm.
7628 (tt_sbit_decoder_load_byte_aligned,
7629 tt_sbit_decoder_load_bit_aligned, tt_sbit_decoder_load_compound,
7630 tt_sbit_decoder_load_image): Pass load flag.
7631 s/write/pwrite/.
7632 Don't call `tt_sbit_decoder_alloc_bitmap'.
7633 Updated.
7634 (tt_sbit_decoder_load_png) [FT_CONFIG_OPTION_USE_PNG]: New function.
7635 (tt_sbit_decoder_load_bitmap): Pass load flag.
7636 Handle new glyph formats 17, 18, and 19.
7637 Call `tt_sbit_decoder_alloc_bitmap'.
7638 Flatten color bitmaps if necessary.
7639 (tt_face_load_sbit_image): Updated.
7640
7641 * src/sfnt/rules.mk (SFNT_DRV_SRC): Add `pngshim.c'.
7642
7643 * docs/CHANGES: Updated.
7644
Guenter41e44802013-05-24 11:38:09 +020076452013-05-24 Guenter <info@gknw.net>
7646
7647 Apply Savannah patch #8055.
7648
7649 Make `apinames' create an import file for NetWare.
7650
7651 * src/tools/apinames.c (PROGRAM_VERSION): Set to 0.2.
7652 (OutputFormat): Add `OUTPUT_NETWARE_IMP'.
7653 (names_dump): Handle it.
7654 (usage): Updated.
7655 (main): Handle new command line flag `-wN'.
7656
Behdad Esfahbod2d6e1fb2013-05-23 08:01:20 +020076572013-05-23 Behdad Esfahbod <behdad@behdad.org>
7658
7659 Compilation fix.
7660
7661 * src/truetype/ttinterp.c (TT_RunIns)
7662 [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]: Make it work.
7663
Infinality18f35ed2013-05-21 20:51:15 -050076642013-05-22 Infinality <infinality@infinality.net>
7665
Infinality3c783c12013-05-21 21:03:00 -05007666 [truetype] Formatting and an additional subpixel tweak.
7667
7668 * src/truetype/ttinterp.c (Ins_SHPIX): Formatting fix.
7669 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules):
7670 Revert previous modification for Verdana clones.
7671
76722013-05-22 Infinality <infinality@infinality.net>
7673
Infinality18f35ed2013-05-21 20:51:15 -05007674 [truetype] Adjust subpixel zp2 moves and tweak rules.
7675
7676 These modifications fix thin diagonal stems in some legacy fonts.
7677
7678 * src/truetype/ttinterp.c (Direct_Move_X): Remove unused macro.
7679 (Move_Zp2_Point): Don't always disable x moves for subpixel rendering.
7680 (Ins_SHP): Disable x moves here for subpixel rendering.
7681 (Ins_SHPIX): Only disable x moves in compatibility mode.
7682 Split out zp2 move reversals and reorder conditional respectively.
7683
7684 * src/truetype/ttsubpix.c (SKIP_NONPIXEL_Y_MOVES_Rules): Fix oversight.
7685 Only adjust Verdana clones for 17 ppem.
7686 (SKIP_NONPIXEL_Y_MOVES_Rules_Exceptions): Add Courier New.
7687 (ALWAYS_SKIP_DELTAP_Rules): Found additional cases for Arial `s'.
7688
Infinality63bfa832013-05-20 07:38:21 +020076892013-05-20 Infinality <infinality@infinality.net>
7690
7691 [truetype] Simplify and improve subpixel function detection.
7692
7693 Some small enhancements have allowed the removal of many macros and
7694 the simplification of existing rules in `ttsubpix.c'.
7695
7696 * src/truetype/ttsubpix.h (SPH_TWEAK_ALLOW_X_DMOVEX,
7697 SPH_TWEAK_ALLOW_X_MOVE_ZP2,
7698 SPH_TWEAK_DELTAP_SKIP_EXAGGERATED_VALUES,
7699 SPH_TWEAK_SKIP_INLINE_DELTAS, SPH_TWEAK_MIRP_CVT_ZERO): Removed.
7700 (SPH_TWEAK_SKIP_NONPIXEL_Y_MOVES_DELTAP): New rule macro.
7701
7702 * src/truetype/ttsubpix.c: Updated affected rules.
7703
7704 * src/truetype/ttinterp.c (Direct_Move_X): Updated.
7705 (INS_FDEF): Add additional function detection.
7706 (INS_ENDF): Set runtime flag.
7707 (Ins_CALL): Skip the call under certain conditions.
7708 Remove bad code.
7709 (Ins_LOOPCALL): Skip the call under certain conditions.
7710 Remove bad code.
7711 (Move_Zp2_Point): Updated.
7712 (Ins_SHPIX): Updated.
7713 Skip the move under some situations.
7714 (Ins_MIAP): Improve conditions.
7715 (Ins_MIRP): Updated.
7716 (Ins_DELTAP): Skip move under certain conditions.
7717 Simplify conditions.
7718 (TT_RunIns): Updated.
7719 Add code to handle new function detection.
7720 Trace messages.
7721
Werner Lembergfd664692013-05-17 17:40:27 +020077222013-05-17 Werner Lemberg <wl@gnu.org>
7723
7724 Update more FT_Err_XXX macros using FT_ERR and FT_THROW;
7725
7726 * builds/amiga/src/base/ftsystem.c, builds/mac/ftmac.c,
7727 builds/unix/ftsystem.c, builds/vms/ftsystem.c: Do it.
7728
Werner Lembergf04951a2013-05-17 13:51:07 +020077292013-05-15 Werner Lemberg <wl@gnu.org>
7730
7731 [truetype] Add `interpreter-version' property.
7732
7733 This makes the option TT_CONFIG_OPTION_SUBPIXEL_HINTING controllable
7734 at runtime.
7735
Werner Lemberg27991332013-05-17 14:00:26 +02007736 * include/freetype/ftttdrv.h: New file.
7737
7738 * include/freetype/config/ftheader.h (FT_TRUETYPE_DRIVER_H): New
7739 macro.
7740
Werner Lembergf04951a2013-05-17 13:51:07 +02007741 * src/truetype/ttdriver.c: Include FT_TRUETYPE_DRIVER_H.
7742 (tt_property_set, tt_property_get): Fill templates.
7743
7744 * src/truetype/ttobjs.h (TT_DriverRec): Add `interpreter_version'
7745 member.
7746 Remove unused `extension_component' member.
7747
7748 * src/truetype/ttgload.c: Include FT_TRUETYPE_DRIVER_H.
7749 (tt_get_metrics, TT_Hint_Glyph, TT_Process_Simple_Glyph,
7750 compute_glyph_metrics, tt_loader_init): Use `interpreter_version'.
7751
7752 * src/truetype/ttinterp.c: Include FT_TRUETYPE_DRIVER_H.
7753 (SUBPIXEL_HINTING): New macro to check `interpreter_version' flag.
7754 Update all affected functions to use it.
7755 Use TT_INTERPRETER_VERSION_XXX where appropriate.
7756
7757 * src/truetype/ttobjs.c: Include FT_TRUETYPE_DRIVER_H.
7758 (tt_driver_init): Initialize `interpreter_version'.
7759
7760 * src/truetype/ttsubpix.c: Include FT_TRUETYPE_DRIVER_H.
7761 Use TT_INTERPRETER_VERSION_XXX where appropriate.
7762
Werner Lemberg7441dd82013-05-13 09:12:46 +020077632013-05-13 Werner Lemberg <wl@gnu.org>
7764
Werner Lemberg6650be72013-05-13 10:05:29 +02007765 [truetype] Avoid empty source file.
7766
7767 * src/truetype/ttsubpix.c [!TT_CONFIG_OPTION_SUBPIXEL_HINTING]:
7768 Provide dummy typedef.
7769
77702013-05-13 Werner Lemberg <wl@gnu.org>
7771
Werner Lemberg7441dd82013-05-13 09:12:46 +02007772 * src/cff/cf2font.c (cf2_getGlyphWidth): Fix uninitialized variable.
7773
7774 Fix suggested by Vaibhav Nagarnaik <vnagarnaik@gmail.com>.
7775
Brian Nixon8d6025c2013-05-13 09:06:42 +020077762013-05-13 Brian Nixon <bnixon@yahoo.com>
7777
7778 Fix Savannah bug #38970.
7779
7780 * src/base/ftdebug.c, builds/win32/ftdebug.c,
7781 builds/wince/ftdebug.c, builds/amiga/src/base/ftdebug.c
7782 (ft_debug_init): Don't read past the environment variable FT2_DEBUG.
7783
Werner Lembergd51ac9c2013-05-12 06:00:27 +020077842013-05-12 Werner Lemberg <wl@gnu.org>
7785
Werner Lembergcd888752013-05-12 15:08:57 +02007786 [truetype] Add framework for TrueType properties.
7787
7788 * src/truetype/ttdrivr.c: Include FT_SERVICE_PROPERTIES_H.
7789 (tt_property_set, tt_property_get): New functions, still empty.
7790 Define `tt_service_properties' service.
7791 Update `tt_services'.
7792
7793 * src/truetype/ttpic.h: Include FT_SERVICE_PROPERTIES_H.
7794 (TT_SERVICE_PROPERTIES_GET): New macro.
7795 (TTModulePIC): Add `tt_service_properties'.
7796
77972013-05-12 Werner Lemberg <wl@gnu.org>
7798
Werner Lembergb112fa42013-05-12 07:29:04 +02007799 Fix Savannah bug #38967.
7800
7801 * src/base/ftcalc.c (FT_DivFix) [FT_LONG64]: Fix cast.
7802
78032013-05-12 Werner Lemberg <wl@gnu.org>
7804
Werner Lembergcbcf33d2013-05-12 07:27:48 +02007805 Introduce unsigned 64bit type (if available).
7806
7807 * include/freetype/config/ftconfig.h: Define FT_UINT64 if available.
7808 [FT_LONG64]: Provide FT_UInt64.
7809
7810 * builds/unix/ftconfig.in: Synchronized.
7811
78122013-05-12 Werner Lemberg <wl@gnu.org>
7813
Werner Lembergd51ac9c2013-05-12 06:00:27 +02007814 Fix Savannah bug #38968.
7815
7816 * include/freetype/ftmodapi.h: Add `FT_EXPORT' to
7817 FT_Property_{Set,Get}.
7818 * src/base/ftobjs.c: Add `FT_EXPORT_DEF' to
7819 FT_Property_{Set,Get}.
7820
Werner Lembergf6aa0892013-05-10 07:58:47 +020078212013-05-10 Werner Lemberg <wl@gnu.org>
7822
Werner Lembergea2b4752013-05-10 08:04:33 +02007823 [sfnt] Clean up bitmap code.
7824
7825 * src/sfnt/ttsbit.c: Deleted.
Dave Arnold3a2cb0f2013-09-29 16:17:02 +02007826 * src/sfnt/ttsbit0.c: Renamed to `ttsbit.c'.
Werner Lembergea2b4752013-05-10 08:04:33 +02007827 * rules.mk (SFNT_DRV_H): Updated.
7828
78292013-05-10 Werner Lemberg <wl@gnu.org>
7830
Werner Lembergf6aa0892013-05-10 07:58:47 +02007831 */* [FT_CONFIG_OPTION_OLD_INTERNALS]: Remove macro and guarded code.
7832
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00007833----------------------------------------------------------------------------
7834
Werner Lembergf57fc592015-01-17 20:41:43 +01007835Copyright 2013-2015 by
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00007836David Turner, Robert Wilhelm, and Werner Lemberg.
7837
7838This file is part of the FreeType project, and may only be used, modified,
7839and distributed under the terms of the FreeType project license,
7840LICENSE.TXT. By continuing to use, modify, or distribute this file you
7841indicate that you have read the license and understand and accept it
7842fully.
7843
7844
7845Local Variables:
7846version-control: never
Werner Lemberg4e03fe72006-04-29 06:20:09 +00007847coding: utf-8
Werner Lemberg8e6c56f2005-10-18 06:09:13 +00007848End: