Ewald Hew | 0589e3c | 2017-09-25 06:10:20 +0200 | [diff] [blame] | 1 | 2017-09-25 Ewald Hew <ewaldhew@gmail.com> |
| 2 | |
Ewald Hew | cb3f4c6 | 2017-09-25 06:44:51 +0200 | [diff] [blame^] | 3 | [psaux] Add missing objects for Type 1 (1/2). |
| 4 | |
| 5 | Move `CF2_Font' instance to `PS_Decoder'. This is the context for |
| 6 | the interpreter and since it is currently stored in `CFF_Font', is |
| 7 | unavailable in Type 1 mode. |
| 8 | |
| 9 | * include/freetype/internal/psaux.h (T1_Decoder, PS_Decoder): New |
| 10 | `cf2_instance' field. |
| 11 | |
| 12 | * src/psaux/psdecode.c (ps_decoder_init): Copy `cf2_instance' to |
| 13 | `PS_Decoder'. |
| 14 | |
| 15 | * src/psaux/t1decode.c (t1_decoder_done): Add finalization code. |
| 16 | |
| 17 | * src/psaux/psft.c (cf2_decoder_parse_charstrings): Update accesses. |
| 18 | |
| 19 | 2017-09-25 Ewald Hew <ewaldhew@gmail.com> |
| 20 | |
Ewald Hew | 7e185dc | 2017-09-25 06:40:32 +0200 | [diff] [blame] | 21 | Allow `type1' module to use the Adobe engine. |
| 22 | |
| 23 | Add the callback and some conditionals to switch between the two |
| 24 | engines. |
| 25 | |
| 26 | * include/freetype/internal/psaux.h (T1_Decoder_FuncsRec): Change |
| 27 | function declarations. |
| 28 | * src/psaux/psauxmod.c (T1_Decoder_FuncsRec): Register the |
| 29 | callbacks. |
| 30 | |
| 31 | * src/psaux/psobjs.c (ps_builder_add_point): Add conditionals for |
| 32 | number conversion. |
| 33 | |
| 34 | * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Add code |
| 35 | to choose which renderer to use. |
| 36 | |
| 37 | * src/cid/cidgload.c (cid_load_glyph): Update call. |
| 38 | * src/base/ftobjs.c, src/psaux/psobjs.c, src/type1/t1gload.c: Update |
| 39 | includes. |
| 40 | |
| 41 | 2017-09-25 Ewald Hew <ewaldhew@gmail.com> |
| 42 | |
Ewald Hew | 97704b1 | 2017-09-25 06:33:28 +0200 | [diff] [blame] | 43 | [type1] Add Adobe engine configuration. |
| 44 | |
| 45 | Use the previously changed PS_Driver in type1 module to store |
| 46 | hinting engine configuration. |
| 47 | |
| 48 | * include/freetype/ftt1drv.h: New file. |
| 49 | Duplicate and rename config options from CFF. |
| 50 | * include/freetype/config/ftheader.h (FT_TYPE1_DRIVER_H): New macro. |
| 51 | |
| 52 | * src/type1/t1driver.c (t1_driver_class): Update declaration. |
| 53 | * src/type1/t1objs.c: Include FT_TYPE1_DRIVER_H. |
| 54 | (T1_Driver_Init): Update code. |
| 55 | |
| 56 | 2017-09-25 Ewald Hew <ewaldhew@gmail.com> |
| 57 | |
Ewald Hew | 645d1b8 | 2017-09-25 06:28:25 +0200 | [diff] [blame] | 58 | [cff] Move and rename `CFF_Driver'. |
| 59 | |
| 60 | This is so that we can use the same hinting engine parameters for |
| 61 | Type 1. |
| 62 | |
| 63 | * include/freetype/internal/cffotypes.h (CFF_Driver): Rename and |
| 64 | move to... |
| 65 | * include/freetype/internal/psaux.h (PS_Driver): ...here. |
| 66 | |
| 67 | * src/cff/cffdrivr.c, src/cff/cffgload.c, src/cff/cffload.c, |
| 68 | src/cff/cffobjs.c, src/cff/cffobjs.h, src/psaux/psft.c, |
| 69 | src/psaux/psobjs.c: Update references. |
| 70 | |
| 71 | 2017-09-25 Ewald Hew <ewaldhew@gmail.com> |
| 72 | |
Ewald Hew | d23affe | 2017-09-25 06:22:52 +0200 | [diff] [blame] | 73 | [psaux, type1] Reorganize object fields. |
| 74 | |
| 75 | Make some fields more generic, so that we can access them the same |
| 76 | way regardless of Type 1 or CFF. |
| 77 | |
| 78 | * include/freetype/internal/psaux.h (PS_Builder): Change `TT_Face' |
| 79 | to `FT_Face'. |
| 80 | Remove unused fields. |
| 81 | |
| 82 | * src/psaux/psft.c: Update all accesses of `PS_Builder.face'. |
| 83 | Add some asserts to guard against casting `T1_Face' as `TT_Face'. |
| 84 | |
| 85 | * src/type1/t1objs.h (T1_GlyphSlot): Reorder fields to follow |
| 86 | `CFF_GlyphSlot', so that we can pretend they are the same in the |
| 87 | interpreter. |
| 88 | |
| 89 | * src/psaux/psobjs.c (ps_builder_init, ps_builder_add_point): |
| 90 | Updated with above changes. |
| 91 | |
| 92 | 2017-09-25 Ewald Hew <ewaldhew@gmail.com> |
| 93 | |
Ewald Hew | 9428ee4 | 2017-09-25 06:15:46 +0200 | [diff] [blame] | 94 | [psaux] Prepare for Type 1 mode. |
| 95 | |
| 96 | Add some checks for Type 1 data passing through. |
| 97 | |
| 98 | * src/psaux/psfont.h (CF2_Font): Add `isT1' flag. |
| 99 | * src/psaux/psfont.c (cf2_font_setup): Skip the variations and blend |
| 100 | code which is not applicable for Type 1. |
| 101 | |
| 102 | * src/psaux/psft.c (cf2_decoder_parse_charstrings): Avoid accessing |
| 103 | `decoder->cff' in Type 1 mode. |
| 104 | Copy `is_t1' flag to `CF2_Font'. |
| 105 | |
| 106 | 2017-09-25 Ewald Hew <ewaldhew@gmail.com> |
| 107 | |
Ewald Hew | 0589e3c | 2017-09-25 06:10:20 +0200 | [diff] [blame] | 108 | [psaux, cff] Use the new objects. |
| 109 | |
| 110 | * include/freetype/internal/psaux.h, src/psaux/psauxmod.c: Fix |
| 111 | switching between new and old engines. |
| 112 | |
| 113 | * src/cff/cffgload.c, src/cff/cffparse.c: Update calls. |
| 114 | |
| 115 | * src/psaux/psblues.c, src/psaux/psfont.c, src/psaux/psfont.h, |
| 116 | src/psaux/psft.c, src/psaux/psft.h, src/psaux/psintrp.c: Update all |
| 117 | to use new objects. |
| 118 | |
Ewald Hew | 62f095f | 2017-09-25 09:25:55 +0200 | [diff] [blame] | 119 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 120 | |
Ewald Hew | 43c0158 | 2017-09-24 23:00:36 +0200 | [diff] [blame] | 121 | [psaux] Objects for new interpreter (part 2). |
| 122 | |
| 123 | Make the new objects copy over values. They are essentially wrapper |
| 124 | types for the different decoders/builders. |
| 125 | |
| 126 | * include/freetype/internal/psaux.h: Update declarations. |
| 127 | (PS_Builder): Add `is_t1' flag. |
| 128 | (PS_Decoder_{Get,Free}_Glyph_Callback): Renamed to... |
| 129 | (CFF_Decoder_{Get,Free}_Glyph_Callback: ... this. |
| 130 | (PS_Decoder): Updated. |
| 131 | Add `t1_parse_callback' member. |
| 132 | (PSAux_ServiceRec): Add `ps_decoder_init' member. |
| 133 | |
| 134 | * src/psaux/psdecode.h, src/psaux/psobjs.h: Update declarations. |
| 135 | |
| 136 | * src/psaux/psdecode.c, src/psaux/psobjs.c: Implement copy with two |
| 137 | modes. |
| 138 | |
| 139 | * src/psaux/psauxmod.c: Add builder and decoder functions to `PSAux' |
| 140 | service. |
| 141 | |
| 142 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 143 | |
Ewald Hew | eba54c2 | 2017-09-24 22:49:56 +0200 | [diff] [blame] | 144 | [psaux] Add objects for new interpreter. |
| 145 | |
| 146 | Introduce `PS_Decoder' and `PS_Builder' which include all fields |
| 147 | from either Type 1 or CFF decoders/builders. |
| 148 | |
| 149 | * include/freetype/internal/psaux.h (PS_Builder, PS_Decoder): New |
| 150 | structs. |
| 151 | |
| 152 | * src/psaux/psobjs.c, src/psaux/psobjs.h: Add `PS_Builder' |
| 153 | functions. |
| 154 | |
| 155 | * src/psaux/psdecode.c, src/psaux/psdecode.h: New files to hold |
| 156 | `PS_Decoder' initialization functions. |
| 157 | |
| 158 | * src/psaux/psaux.c, src/psaux/Jamfile (_sources), |
| 159 | src/psaux/rules.mk (PSAUX_DRV_SRC): Updated. |
| 160 | |
| 161 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 162 | |
Ewald Hew | 766f529 | 2017-09-24 22:40:07 +0200 | [diff] [blame] | 163 | [psaux] Rename files. |
| 164 | |
| 165 | Replace the `cf2' file name prefix with `ps' as the Adobe engine |
| 166 | will be used for both PostScript Types 1 and 2 (CFF) instead of just |
| 167 | CFF. |
| 168 | |
| 169 | s/cf2/ps/ for all following. |
| 170 | |
| 171 | * src/psaux/cf2*: Rename files. |
| 172 | * src/psaux/*: Update includes. |
| 173 | |
| 174 | * src/psaux/Jamfile (_sources), src/psaux/rules.mk (PSAUX_DRC_SRC, |
| 175 | PSAUX_DRV_H): Update file references. |
| 176 | |
| 177 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 178 | |
Ewald Hew | 8a1b5c0 | 2017-09-24 22:35:47 +0200 | [diff] [blame] | 179 | [psaux] Minor fix. |
| 180 | |
| 181 | Use `MultiMasters' service in `psaux' instead of a call to `cff'. |
| 182 | The project builds if CFF_CONFIG_OPTION_OLD_ENGINE is not defined. |
| 183 | |
| 184 | * src/psaux/cf2ft.c: Update includes. |
| 185 | (cf2_getNormalizedVector): Use `mm->get_var_blend' instead of |
| 186 | `cff_get_var_blend'. |
| 187 | |
| 188 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 189 | |
Ewald Hew | b624868 | 2017-09-24 22:32:40 +0200 | [diff] [blame] | 190 | [psaux, cff] Move `cff_random' into `psaux' service. |
| 191 | |
| 192 | NOTE: Does not compile! |
| 193 | |
| 194 | Minor fix to allow both `cff' and `psaux' to use `cff_random'. |
| 195 | |
| 196 | * src/cff/cffload.c (cff_random): Move to... |
| 197 | * src/psaux/psobjs.c: Here. |
| 198 | * src/cff/cffload.h: Move corresponding declaration to |
| 199 | `src/psaux/psobjs.h'. |
| 200 | |
| 201 | * include/freetype/internal/psaux.h (PSAux_ServiceRec): Register the |
| 202 | function here... |
| 203 | * src/psaux/psauxmod.c: And here. |
| 204 | |
| 205 | * src/cff/cffload.c, src/psaux/cf2intrp.c: Update code. |
| 206 | |
| 207 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 208 | |
Ewald Hew | df11628 | 2017-09-24 22:28:07 +0200 | [diff] [blame] | 209 | [cff] Move struct declarations to `freetype/internal'. |
| 210 | |
| 211 | NOTE: Does not compile! |
| 212 | |
| 213 | This is so that the CFF functions moved to `psaux' can access the |
| 214 | same structs that they need. |
| 215 | |
| 216 | * src/cff/cfftypes.h: Moved to... |
| 217 | * include/freetype/internal/cfftypes.h: ...Here. |
| 218 | |
| 219 | * src/cff/cffobjs.h: Moved the struct declarations to... |
| 220 | * include/freetype/internal/cffotypes.h: ... this new file. |
| 221 | |
| 222 | * include/freetype/internal/internal.h (FT_INTERNAL_CFF_TYPES_H, |
| 223 | FT_INTERNAL_CFF_OBJECT_TYPES_H): New macros. |
| 224 | |
| 225 | * src/cff/cffcmap.h, src/cff/cffdrivr.c, src/cff/cffgload.c, |
| 226 | src/cff/cffgload.h, src/cff/cffload.h, src/cff/cffobjs.c, |
| 227 | src/cff/cffobjs.h, src/cff/cffparse.h, src/psaux/psobjs.h, |
| 228 | include/freetype/internal/psaux.h, |
| 229 | include/freetype/internal/services/svcfftl.h: Update includes. |
| 230 | |
| 231 | * src/cff/rules.mk (CFF_DRV_H): Updated. |
| 232 | |
| 233 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 234 | |
Ewald Hew | edacde6 | 2017-09-24 22:20:38 +0200 | [diff] [blame] | 235 | [psaux, cff] Add new service for inter-module calls. |
| 236 | |
| 237 | NOTE: Does not compile! |
| 238 | |
| 239 | This is to allow CFF functions moved to `psaux' to call functions |
| 240 | declared in `src/cff/cffload.h'. |
| 241 | |
| 242 | * include/freetype/internal/services/svcfftl.h: New file, setting up |
| 243 | a `CFFLoad' service. |
| 244 | |
| 245 | * include/freetype/internal/ftserv.h (FT_DEFINE_SERVICEDESCREC10, |
| 246 | FT_DEFINE_SERVICEDESCREC): New macros. |
| 247 | (FT_SERVICE_CFF_TABLE_LOAD_H): New macro. |
| 248 | |
| 249 | * src/cff/cffdrivr.c, src/cff/cffpic.h: Register the new service. |
| 250 | |
| 251 | * src/cff/cfftypes.h (CFF_FontRec), src/psaux/cf2font.h |
| 252 | (CF2_FontRec): Add service interface. |
| 253 | |
| 254 | * src/cff/cffobjs.c, src/psaux/cf2font.c, src/psaux/cf2ft.c, |
| 255 | src/psaux/cf2intrp.c, src/psaux/cffdecode.c: Use the new service. |
| 256 | |
| 257 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 258 | |
Ewald Hew | 9578e07 | 2017-09-24 22:05:32 +0200 | [diff] [blame] | 259 | [psaux, cff] Add callbacks for inter-module calls. |
| 260 | |
| 261 | NOTE: Does not compile! |
| 262 | |
| 263 | * include/freetype/internal/psaux.h: Add function pointer |
| 264 | declarations. |
| 265 | |
| 266 | * src/psaux/cffdecode.c (cff_decoder_init): Update to take in |
| 267 | callbacks. |
| 268 | * src/psaux/cffdecode.h: Ditto. |
| 269 | |
| 270 | * src/cff/cffgload.c (cff_compute_max_advance, cff_slot_load): |
| 271 | Update calls to pass in callbacks. |
| 272 | * src/psaux/cf2ft.c, src/psaux/cffdecode.c: Use them. |
| 273 | |
| 274 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 275 | |
Ewald Hew | 1487be5 | 2017-09-24 21:56:54 +0200 | [diff] [blame] | 276 | [psaux, cff] Create new `PSAux' service interface entries. |
| 277 | |
| 278 | NOTE: Does not compile! |
| 279 | |
| 280 | * include/freetype/internal/psaux.h: Include |
| 281 | FT_INTERNAL_TRUETYPE_TYPES_H. |
| 282 | (CFF_Builder_FuncsRec, CFF_Decocer_FuncsRec): New function tables. |
| 283 | (CFF_Builder): Updated. |
| 284 | Fix for forward declaration. |
| 285 | (PSAux_ServiceRec): New field `cff_decoder_funcs'. |
| 286 | |
| 287 | * src/psaux/psauxmod.c (cff_builder_funcs, cff_decoder_funcs): New |
| 288 | function tables. |
| 289 | (PSAux_Interface): Updated. |
| 290 | |
| 291 | * include/freetype/internal/tttypes.h (TT_FaceRec): Add `psaux' |
| 292 | service interface. |
| 293 | |
| 294 | * src/cff/cffgload.c, src/cff/cffobjs.c, src/cff/cffparse.c: Update |
| 295 | function calls to use psaux service. |
| 296 | |
| 297 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 298 | |
Ewald Hew | 816c9c1 | 2017-09-24 21:43:05 +0200 | [diff] [blame] | 299 | [psaux, cff] Move CFF builder components into `psaux' module. |
| 300 | |
| 301 | NOTE: Does not compile! |
| 302 | |
| 303 | * src/cff/cffgload.c |
| 304 | (cff_builder_{init,done,add_point,add_point1,add_contour,start_point,close_contour}, |
| 305 | cff_check_points): Move to... |
| 306 | * src/psaux/psobjs.c: Here. |
| 307 | |
| 308 | * src/cff/cffgload.h: Move corresponding declarations to |
| 309 | `src/psaux/psobjs.h'. |
| 310 | |
| 311 | * src/cff/cffgload.h (CFF_Builder): Move struct declaration to... |
| 312 | * include/freetype/internal/psaux.h: Here. |
| 313 | |
| 314 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 315 | |
Ewald Hew | 705bbe7 | 2017-09-24 21:39:20 +0200 | [diff] [blame] | 316 | [psaux, cff] Move CFF decoder components into `psaux' module. |
| 317 | |
| 318 | NOTE: Does not compile! |
| 319 | |
| 320 | * src/cff/cffgload.c (CFF_Operator, |
| 321 | CFF_COUNT_{CHECK_WIDTH,EXACT,CLEAR_STACK}, cff_argument_counts, |
| 322 | cff_operator_seac, cff_compute_bias, |
| 323 | cff_lookup_glyph_by_stdcharcode, |
| 324 | cff_decoder_{parse_charstrings,init,prepare}): Move to... |
| 325 | * src/psaux/cffdecode.c: This new file. |
| 326 | |
| 327 | * src/cff/cffgload.h: Move corresponding declarations to... |
| 328 | * src/psaux/cffdecode.h: This new file. |
| 329 | |
| 330 | * src/cff/cffgload.h (CFF_MAX_{OPERANDS,SUBRS_CALLS,TRANS_ELEMENTS}, |
| 331 | CFF_Decoder_Zone, CFF_Decoder): Move declarations to... |
| 332 | * include/freetype/internal/psaux.h: Here. |
| 333 | |
| 334 | * src/psaux/cf2ft.h: Update include. |
| 335 | |
| 336 | * src/psaux/psaux.c, src/psaux/rules.mk (PSAUX_DRV_SRC): Update with |
| 337 | the new file. |
| 338 | |
| 339 | 2017-09-24 Ewald Hew <ewaldhew@gmail.com> |
| 340 | |
Ewald Hew | 62f095f | 2017-09-25 09:25:55 +0200 | [diff] [blame] | 341 | [psaux, cff] Move Adobe's engine components into `psaux' module. |
| 342 | |
| 343 | This is the first patch of a sequence to move the Type 2 charstring |
| 344 | processing capability from the `cff' module to the `psaux' module. |
| 345 | |
| 346 | NOTE: Does not compile! |
| 347 | |
| 348 | * src/cff/cf2*: Move these files to... |
| 349 | * src/psaux/cf2*: Here. |
| 350 | |
| 351 | * src/cff/Jamfile (_sources), src/cff/rules.mk (CFF_DRV_SRC, |
| 352 | CFF_DRV_H), src/cff/cff.c, src/cff/cffgload.c: Remove file |
| 353 | references. |
| 354 | |
| 355 | * src/psaux/Jamfile (_sources), src/psaux/rules.mk, src/psaux/psaux.c |
| 356 | (PSAUX_DRV_SRC, PSAUX_DRV_H): Add file references. |
| 357 | |
Alexei Podtelezhnikov | 02e80da | 2017-09-24 22:18:34 -0400 | [diff] [blame] | 358 | 2017-09-24 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 359 | |
| 360 | Tweak per-face LCD filtering controls. |
| 361 | |
| 362 | Thing are simpler with a NULL-function pointer. |
| 363 | |
| 364 | * include/freetype/internal/ftobjs.h (FT_Face_InternalRec): New |
| 365 | pointer to the filter function. |
| 366 | (FT_LibraryRec): Remove unused `lcd_filter'. |
| 367 | (FT_Bitmap_LcdFilterFunc, ft_lcd_filter_fir): Move from here... |
| 368 | * include/freetype/ftlcdfil.h (FT_Bitmap_LcdFilterFunc, |
| 369 | ft_lcd_filter_fir): ... to here. |
| 370 | |
| 371 | * src/base/ftobjs.c (ft_open_face_internal): NULL-initialize the |
| 372 | per-face filter. |
| 373 | (FT_Face_Properties): Set it. |
| 374 | * src/smooth/ftsmooth.c (ft_smooth_render_generic): Simplify. |
| 375 | |
| 376 | * src/base/ftlcdfil.c (ft_lcd_filter_fir, FT_Libary_SetLcdFilter): |
| 377 | Minor. |
| 378 | |
Jonathan Kew | 0d1262a | 2017-09-24 17:36:47 +0200 | [diff] [blame] | 379 | 2017-09-24 Jonathan Kew <jfkthame@gmail.com> |
| 380 | |
| 381 | [sfnt] Fix `premultiply_data' (#52092). |
| 382 | |
| 383 | * src/sfnt/pngshim.c (premultiply_data): Don't use vector extension |
| 384 | if we have less than 16 bytes of data. |
| 385 | |
Werner Lemberg | 6d403d0 | 2017-09-24 09:06:01 +0200 | [diff] [blame] | 386 | 2017-09-24 Werner Lemberg <wl@gnu.org> |
| 387 | |
| 388 | [otvalid] Fix handling of ValueRecords. |
| 389 | |
| 390 | For GPOS pair positioning format 1 the description of ValueRecords |
| 391 | in the OpenType specification (1.8.2, from today) is wrong – the |
| 392 | offset has to be taken from the parent structure; in this case the |
| 393 | `PairSet' table. |
| 394 | |
| 395 | * src/otvalid/otvgpos.c (otv_PairSet_validate): Set `extra3'. |
| 396 | (otv_PairPos_validate): Adjust. |
| 397 | |
Werner Lemberg | 2b79d25 | 2017-09-23 10:29:26 +0200 | [diff] [blame] | 398 | 2017-09-23 Werner Lemberg <wl@gnu.org> |
| 399 | |
Werner Lemberg | 0da0faf | 2017-09-24 09:13:41 +0200 | [diff] [blame] | 400 | [otvalid] Handle `GSUB' and `GPOS' v1.1 tables. |
| 401 | |
| 402 | * src/otvalid/otvgsub.c (otv_GSUB_validate), src/otvalid/otvgpos.c |
| 403 | (otv_GPOS_validate): Implement it. |
| 404 | |
| 405 | 2017-09-23 Werner Lemberg <wl@gnu.org> |
| 406 | |
Werner Lemberg | 2b79d25 | 2017-09-23 10:29:26 +0200 | [diff] [blame] | 407 | [otvalid] Update common table handling to OpenType 1.8.2. |
| 408 | |
| 409 | * src/otvalid/otvcommn.c (otv_Device_validate): Handle |
| 410 | VariationIndex subtable. |
| 411 | (otv_Lookup_validate): Handle MarkFilteringSet. |
| 412 | |
Alexei Podtelezhnikov | 02e80da | 2017-09-24 22:18:34 -0400 | [diff] [blame] | 413 | 2017-09-23 Alexei Podtelezhnikov <apodtele@gmail.com> |
Werner Lemberg | e720206 | 2017-09-24 09:16:39 +0200 | [diff] [blame] | 414 | |
| 415 | [build] Windows-style DLL versioning. |
| 416 | |
| 417 | * build/windows/ftver.rc: New VERSIONINFO resource. |
| 418 | * build/windows/vc2010/freetype.vcxproj: Further improvements. |
| 419 | |
Ben Wagner | 63be40b | 2017-09-23 00:44:59 +0200 | [diff] [blame] | 420 | 2017-09-23 Ben Wagner <bungeman@google.com> |
| 421 | |
| 422 | [truetype] Really fix #52082. |
| 423 | |
| 424 | * src/truetype/ttinterp.c (Ins_MDRP): Correct conditional. |
| 425 | |
Werner Lemberg | b010367 | 2017-09-23 00:40:28 +0200 | [diff] [blame] | 426 | 2017-09-23 Werner Lemberg <wl@gnu.org> |
| 427 | |
| 428 | [otvalid] Handle `GDEF' v1.2 and v1.3 tables. |
| 429 | |
| 430 | No validation of variation stuff yet. |
| 431 | |
| 432 | * src/otvalid/otvgdef.c (otv_MarkGlyphSets_validate): New function. |
| 433 | (otv_GDEF_validate): Implement it. |
| 434 | |
Werner Lemberg | 3645982 | 2017-09-22 07:53:25 +0200 | [diff] [blame] | 435 | 2017-09-22 Werner Lemberg <wl@gnu.org> |
| 436 | |
Werner Lemberg | 6756a18 | 2017-09-23 00:36:49 +0200 | [diff] [blame] | 437 | [otvalid] Handle `BASE' v1.1 table. |
| 438 | |
| 439 | No validation of variation stuff yet. |
| 440 | |
| 441 | * src/otvalid/otvbase.c (otv_BASE_validate): Implement it. |
| 442 | |
| 443 | 2017-09-22 Werner Lemberg <wl@gnu.org> |
| 444 | |
Werner Lemberg | 3645982 | 2017-09-22 07:53:25 +0200 | [diff] [blame] | 445 | [otvalid] Macros for 32bit offset support. |
| 446 | |
| 447 | * src/otvalid/otvcommn.h (OTV_OPTIONAL_TABLE32, |
| 448 | OTV_OPTIONAL_OFFSET32, OTV_SIZE_CHECK32): New macros. |
| 449 | |
Alexei Podtelezhnikov | 3be8e34 | 2017-09-21 23:12:59 -0400 | [diff] [blame] | 450 | 2017-09-21 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 451 | |
| 452 | [build] Simplify Visual C++ 2010 project. |
| 453 | |
| 454 | * build/windows/vc2010/freetype.vcxproj: Remove fake singlethreaded |
| 455 | configurations and tweak. |
| 456 | |
Werner Lemberg | 3b3cb32 | 2017-09-21 09:03:20 +0200 | [diff] [blame] | 457 | 2017-09-21 Werner Lemberg <wl@gnu.org> |
| 458 | |
Werner Lemberg | 6d04bd9 | 2017-09-21 21:22:51 +0200 | [diff] [blame] | 459 | [truetype] Integer overflow (#52082). |
| 460 | |
| 461 | * src/truetype/ttinterp.c (Ins_MDRP): Avoid FT_ABS. |
| 462 | |
| 463 | 2017-09-21 Werner Lemberg <wl@gnu.org> |
| 464 | |
Werner Lemberg | cf64e33 | 2017-09-21 11:42:48 +0200 | [diff] [blame] | 465 | [sfnt] Fix postscript name for default instance of variation fonts. |
| 466 | |
| 467 | Problem reported by Behdad. |
| 468 | |
| 469 | * src/sfnt/sfdriver.c (sfnt_get_ps_name): Test |
| 470 | `is_default_instance'. |
| 471 | |
| 472 | 2017-09-21 Werner Lemberg <wl@gnu.org> |
| 473 | |
Werner Lemberg | b19cdc9 | 2017-09-21 11:02:35 +0200 | [diff] [blame] | 474 | [truetype] Fix `mmvar' array pointers, part 2. |
| 475 | |
| 476 | The previous commit was incomplete. |
| 477 | |
| 478 | * src/truetype/ttgxvar.c: Properly initialize sub-array offsets for |
| 479 | `master' also. |
| 480 | |
| 481 | 2017-09-21 Werner Lemberg <wl@gnu.org> |
| 482 | |
Werner Lemberg | 3b3cb32 | 2017-09-21 09:03:20 +0200 | [diff] [blame] | 483 | [truetype] Fix `mmvar' array pointers. |
| 484 | |
| 485 | Without this change, clang's AddressSanitizer reports many runtime |
| 486 | errors due to misaligned addresses. |
| 487 | |
| 488 | * src/truetype/ttgxvar.c (TT_Get_MM_Var): Use multiples of pointer |
| 489 | size for sub-array offsets into `mmvar'. |
| 490 | |
Werner Lemberg | eaa9adf | 2017-09-20 08:00:05 +0200 | [diff] [blame] | 491 | 2017-09-20 Werner Lemberg <wl@gnu.org> |
| 492 | |
| 493 | [truetype] Integer overflows. |
| 494 | |
| 495 | Changes triggered by |
| 496 | |
| 497 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3429 |
| 498 | |
| 499 | * src/truetype/ttinterp.c (Ins_SHPIX, Ins_DELTAP): Use NEG_LONG. |
| 500 | (Ins_MIAP): Use SUB_LONG. |
| 501 | |
Alexei Podtelezhnikov | 74f4423 | 2017-09-19 23:41:27 -0400 | [diff] [blame] | 502 | 2017-09-19 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 503 | |
| 504 | [build] Fix DLL builds in Visual C++ project. |
| 505 | |
| 506 | * build/windows/vc2010/freetype.vcxproj: Use DynamicLibrary in Debug |
| 507 | and Release configurations. |
| 508 | * include/freetype/config/ftconfig.h (FT_EXPORT, FT_EXPORT_DEF) |
| 509 | [_DLL]: Use Visual C++ extensions. |
| 510 | |
John Tytgat | b00be9f | 2017-09-19 07:12:03 +0200 | [diff] [blame] | 511 | 2017-09-19 John Tytgat <John.Tytgat@esko.com> |
| 512 | |
| 513 | [cff] Fix family name logic of pure CFF fontdata (#52056). |
| 514 | |
| 515 | 1. If `FamilyName' is present in the CFF font, use this for |
| 516 | FT_Face's `family_name'. |
| 517 | 2. Otherwise, use the face name and chop off any subset prefix. |
| 518 | 3. If at this point FT_Face's `family_name' is set, use this |
| 519 | together with the full name to determine the style. |
| 520 | 4. Otherwise, use `CIDFontName' as FT_Face's `family_name'. |
| 521 | 5. If we don't have a valid style, use "Regular". |
| 522 | |
| 523 | Previously, FT_Face's `family_name' entry for pure CFF fontdata |
| 524 | nearly always was the fontname itself, instead of the `FamilyName' |
| 525 | entry in the CFF font (assuming there is one). |
| 526 | |
| 527 | * src/cff/cffobjs.c (cff_face_init) [pure_cff]: Implement it. |
| 528 | |
Alexei Podtelezhnikov | 8b0d2e9 | 2017-09-18 22:54:49 -0400 | [diff] [blame] | 529 | 2017-09-18 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 530 | |
| 531 | [build] Declutter Visual C++ 2010-2017 project. |
| 532 | |
| 533 | * build/windows/vc2010/freetype.vcxproj: Use MaxSpeed (/02) |
| 534 | optimization for Release configuration throughout the project. |
| 535 | |
Werner Lemberg | 39ce3ac | 2017-09-16 19:08:17 +0200 | [diff] [blame] | 536 | 2017-09-16 Werner Lemberg <wl@gnu.org> |
| 537 | |
| 538 | * Version 2.8.1 released. |
| 539 | ========================= |
| 540 | |
| 541 | |
| 542 | Tag sources with `VER-2-8-1'. |
| 543 | |
| 544 | * docs/VERSION.TXT: Add entry for version 2.8.1. |
| 545 | * docs/CHANGES: Updated. |
| 546 | |
| 547 | * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj, |
| 548 | builds/windows/vc2005/index.html, |
| 549 | builds/windows/vc2008/freetype.vcproj, |
| 550 | builds/windows/vc2008/index.html, |
| 551 | builds/windows/vc2010/freetype.vcxproj, |
| 552 | builds/windows/vc2010/index.html, |
| 553 | builds/windows/visualc/freetype.dsp, |
| 554 | builds/windows/visualc/freetype.vcproj, |
| 555 | builds/windows/visualc/index.html, |
| 556 | builds/windows/visualce/freetype.dsp, |
| 557 | builds/windows/visualce/freetype.vcproj, |
| 558 | builds/windows/visualce/index.html, |
| 559 | builds/wince/vc2005-ce/freetype.vcproj, |
| 560 | builds/wince/vc2005-ce/index.html, |
| 561 | builds/wince/vc2008-ce/freetype.vcproj, |
| 562 | builds/wince/vc2008-ce/index.html: s/2.8/2.8.1/, s/28/281/. |
| 563 | |
| 564 | * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1. |
| 565 | |
| 566 | * builds/unix/configure.raw (version_info): Set to 21:0:15. |
| 567 | * CMakeLists.txt (VERSION_PATCH): Set to 1. |
| 568 | |
suzuki toshiya | 5ad8457 | 2017-09-13 15:49:15 +0900 | [diff] [blame] | 569 | 2017-09-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp> |
| 570 | |
Werner Lemberg | 39ce3ac | 2017-09-16 19:08:17 +0200 | [diff] [blame] | 571 | [sfnt] lowest gcc for vectors (e1d0249e) is changed to 4.7. |
suzuki toshiya | b757ddb | 2017-09-13 22:17:03 +0900 | [diff] [blame] | 572 | |
| 573 | __builtin_shuffle() was introduced in gcc-4.7. The lowest |
| 574 | gcc to enable vector operation is delayed from 4.6 to 4.7. |
| 575 | |
| 576 | * src/sfnt/pngshim.c (premultiply_data): Fix cpp-macro to |
| 577 | enable the vector operation, to change the lowest gcc version |
| 578 | from 4.6 to 4.7. |
| 579 | |
| 580 | 2017-09-13 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp> |
| 581 | |
suzuki toshiya | 5ad8457 | 2017-09-13 15:49:15 +0900 | [diff] [blame] | 582 | [cache] Fix a possible overflow by signed integer comparison. |
| 583 | |
| 584 | Improve the code by 5d3ff05615dda6d1325ed612381a17a0df04c975 , |
| 585 | issues are found by Behdad Esfahbod and Werner Lemberg. |
| 586 | |
| 587 | * src/cache/ftcbasic.c (FTC_ImageCache_Lookup): Replace |
| 588 | a subtraction to check higher bit by a bit operation, |
| 589 | and cpp-conditionalize for appropriate systems. Add better |
| 590 | documentation to the comment. |
| 591 | (FTC_ImageCache_LookupScaler): Ditto. |
| 592 | (FTC_SBitCache_Lookup): Ditto. |
| 593 | (FTC_SBitCache_LookupScaler): Ditto. |
| 594 | |
Werner Lemberg | 96dcc8a | 2017-09-13 08:16:23 +0200 | [diff] [blame] | 595 | 2017-09-13 Werner Lemberg <wl@gnu.org> |
| 596 | |
| 597 | [autofit] Really fix #41334 (#52000). |
| 598 | |
| 599 | * src/autofit/aflatin.c (af_latin_hints_compute_segments): Set |
| 600 | `segment->delta' everywhere. |
| 601 | |
suzuki toshiya | 21658c3 | 2017-09-12 15:59:18 +0900 | [diff] [blame] | 602 | 2017-09-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp> |
| 603 | |
| 604 | [autofit, sfnt] Fix for `make multi'. |
| 605 | |
| 606 | * src/autofit/afshaper.c: Include FT_ADVANCE_H, to use |
| 607 | FT_Get_Advance() in it. |
| 608 | * src/sfnt/ttcmap.c: Include FT_SERVICE_POSTSCRIPT_CMAPS_H |
| 609 | to use PS_Unicodes in it, also include `ttpost.h' to use |
| 610 | tt_face_get_ps_name() in it. |
| 611 | |
Azzuro | babe13e | 2017-09-11 10:47:29 +0200 | [diff] [blame] | 612 | 2017-09-11 Azzuro <azzuro@team-mediaportal.com> |
| 613 | |
| 614 | [build] Improve builds with different MS Visual Studio versions. |
| 615 | |
| 616 | * builds/windows/vc2010/freetype.vcxproj: Switch platform toolset |
| 617 | according to the Visual Studio version. |
| 618 | |
Werner Lemberg | 3e4b799 | 2017-09-11 08:51:44 +0200 | [diff] [blame] | 619 | 2017-09-11 Werner Lemberg <wl@gnu.org> |
| 620 | |
| 621 | * src/sfnt/ttkern.c (tt_face_load_kern): Reject format 2 tables. |
| 622 | |
| 623 | Reported by Behdad. |
| 624 | |
Werner Lemberg | 0ab2b62 | 2017-09-09 08:08:47 +0200 | [diff] [blame] | 625 | 2017-09-09 Werner Lemberg <wl@gnu.org> |
| 626 | |
| 627 | [autofit] Improve communication with ftgrid. |
| 628 | |
| 629 | * src/autofit/afhints.c (af_glyph_hints_get_segment_offset): |
| 630 | Provide values in font units. |
| 631 | |
suzuki toshiya | 71f6618 | 2017-09-09 01:05:44 +0900 | [diff] [blame] | 632 | 2017-09-08 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp> |
| 633 | |
suzuki toshiya | 3ef59e5 | 2017-09-09 01:28:24 +0900 | [diff] [blame] | 634 | [base] Remove a check for resource ID in the resource fork driver. |
| 635 | |
| 636 | LastResort.dfont has a marginal resource ID 0xFFFF for sfnt |
| 637 | resource. Inside Macintosh: More Macintosh Toolbox, `Resource IDs' |
| 638 | (1-46), tells that some IDs are reserved and should not be used. |
| 639 | FreeType2 just uses resource ID to sort the fragmented resource. |
| 640 | To accept the marginal fonts, the checking is removed. |
| 641 | |
| 642 | * src/base/ftrfork.c (FT_Raccess_Get_DataOffsets): Remove res_id |
| 643 | validity check, fix a trace message format. |
| 644 | |
| 645 | 2017-09-08 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp> |
| 646 | |
suzuki toshiya | 71f6618 | 2017-09-09 01:05:44 +0900 | [diff] [blame] | 647 | [sfnt, truetype] Register the tags for marginal fonts. |
| 648 | |
| 649 | The first 32bit of standard TrueType variants is 0x00010000, |
| 650 | `OTTO', `ttcf', `true' or `typ1'. 2 marginal dfonts on legacy Mac |
| 651 | OS X, Keyboard.dfont and LastResort.dfont, have the sfnt resources |
| 652 | starting 0xA5 followed by `kbd' or `lst'. Considering the following |
| 653 | data could be parsed as conventional TrueType fonts, the header |
| 654 | checking is updated to allow these tags. It seems that recent Mac |
| 655 | OS X has already switched to normal TTF for these fonts. |
| 656 | |
| 657 | See the discussion at |
| 658 | http://u88.n24.queensu.ca/exiftool/forum/index.php?topic=3931.0 |
| 659 | |
| 660 | * include/freetype/tttags.h (TTAG_0xA5kbd, TTAG_0xA5lst): New header |
| 661 | tags for Keyboard.dfont and LastResort.dfont. |
| 662 | * src/sfnt/sfobjs.c (sfnt_open_font): Accept the sfnt resource |
| 663 | starts with TTAG_0xA5kbd or TTAG_0xA5lst. |
| 664 | * src/truetype/ttobjs.c (tt_face_init): Accept the face with the |
| 665 | format tag is TTAG_0xA5kbd or TTAG_0xA5lst. |
| 666 | |
Werner Lemberg | 7d017ba | 2017-09-05 15:28:21 +0200 | [diff] [blame] | 667 | 2017-09-05 Werner Lemberg <wl@gnu.org> |
| 668 | |
Werner Lemberg | a3dd6d9 | 2017-09-05 23:02:04 +0200 | [diff] [blame] | 669 | Fix multiple calls of `FT_Bitmap_Convert'. |
| 670 | |
| 671 | The documentation of `FT_Bitmap_Convert' says that multiple calls do |
| 672 | proper reallocation of the target FT_Bitmap object. However, this |
| 673 | failed for the sequence |
| 674 | |
| 675 | non-empty bitmap |
| 676 | empty bitmap |
| 677 | non-empty bitmap |
| 678 | |
| 679 | Reason was that `FT_Bitmap_Convert' only reallocated the bitmap |
| 680 | buffer if it became too small; it didn't make the buffer smaller. |
| 681 | For an empty bitmap following a non-empty one, only the buffer |
| 682 | dimension got set to zero, without deallocation. If the next call |
| 683 | was a non-empty buffer again, an assertion in `ft_mem_qrealloc' was |
| 684 | triggered. |
| 685 | |
| 686 | * src/base/ftbitmap.c (FT_Bitmap_Convert): Always reallocate target |
| 687 | buffer to the correct size. |
| 688 | |
| 689 | * docs/CHANGES: Document it. |
| 690 | |
| 691 | 2017-09-05 Werner Lemberg <wl@gnu.org> |
| 692 | |
Werner Lemberg | 7d017ba | 2017-09-05 15:28:21 +0200 | [diff] [blame] | 693 | [bdf] Fix size and resolution handling. |
| 694 | |
| 695 | * src/bdf/bdfdrivr.c (BDF_Face_Init): Use `SIZE' values if |
| 696 | `POINT_SIZE', `RESOLUTION_X', or `RESOLUTION_Y' properties are |
| 697 | missing. |
| 698 | |
| 699 | * docs/CHANGES: Document it. |
| 700 | |
Alexei Podtelezhnikov | f0898b9 | 2017-08-25 21:40:01 -0400 | [diff] [blame] | 701 | 2017-08-25 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 702 | |
| 703 | Swap `ALLOC_MULT' arguments (#51833). |
| 704 | |
| 705 | * src/base/ftbitmap.c (ft_bitmap_assure_buffer): Updated. |
| 706 | * src/winfonts/winfnt.c (FNT_Load_Glyph): Updated. |
| 707 | * src/raster/ftrend1.c (ft_raster1_render): Updated. |
| 708 | |
Werner Lemberg | e1d0249 | 2017-08-23 08:18:22 +0200 | [diff] [blame] | 709 | 2017-08-23 Werner Lemberg <wl@gnu.org> |
| 710 | |
| 711 | [sfnt] Fix clang compilation (#51788). |
| 712 | |
| 713 | * src/sfnt/pngshim.c (premultiply_data): Use vectors instead of |
| 714 | scalars. |
Werner Lemberg | 587264c | 2017-08-23 09:14:14 +0200 | [diff] [blame] | 715 | (vector_shuffle): New macro to take care of a different built-in |
| 716 | function name on clang. |
Werner Lemberg | e1d0249 | 2017-08-23 08:18:22 +0200 | [diff] [blame] | 717 | |
Werner Lemberg | 0aca17c | 2017-08-22 08:25:14 +0200 | [diff] [blame] | 718 | 2017-08-22 Werner Lemberg <wl@gnu.org> |
| 719 | |
Werner Lemberg | bd28952 | 2017-08-22 08:41:03 +0200 | [diff] [blame] | 720 | [base] Don't zero out allocated memory twice (#51816). |
| 721 | |
| 722 | Patch applied from bug report. |
| 723 | |
| 724 | * src/base/ftutil.c (ft_mem_qrealloc): Use low-level allocation to |
| 725 | avoid unnecessary overhead. |
| 726 | |
| 727 | 2017-08-22 Werner Lemberg <wl@gnu.org> |
| 728 | |
Werner Lemberg | 0aca17c | 2017-08-22 08:25:14 +0200 | [diff] [blame] | 729 | [truetype] Integer overflow. |
| 730 | |
| 731 | Changes triggered by |
| 732 | |
| 733 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3107 |
| 734 | |
| 735 | * src/truetype/ttinterp.c (Ins_MDRP, Ins_MIRP, Ins_ALIGNPTS): Use |
| 736 | NEG_LONG. |
| 737 | |
Alexei Podtelezhnikov | 7653c76 | 2017-08-17 21:28:32 -0400 | [diff] [blame] | 738 | 2017-08-17 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 739 | |
| 740 | [sfnt] Avoid synthetic unicode for symbol fonts with PUA. |
| 741 | |
| 742 | Reported as |
| 743 | |
| 744 | https://bugs.chromium.org/p/chromium/issues/detail?id=754574 |
| 745 | |
| 746 | * src/sfnt/sfobjs.c (sfnt_load_face): Check for FT_ENCODING_MS_SYMBOL. |
| 747 | |
Werner Lemberg | cadd29d | 2017-08-16 13:32:17 +0200 | [diff] [blame] | 748 | 2017-08-16 Werner Lemberg <wl@gnu.org> |
| 749 | |
| 750 | * src/sfnt/pngshim.c (premultiply_data): Fix compiler warnings. |
| 751 | |
Behdad Esfahbod | c9d7c03 | 2017-08-15 08:48:17 +0200 | [diff] [blame] | 752 | 2017-08-15 Behdad Esfahbod <behdad@behdad.org> |
| 753 | |
| 754 | [sfnt] Speed up PNG image loading. |
| 755 | |
| 756 | This reduces the overhead of `premultiply_data' by 60%. |
| 757 | |
| 758 | * src/sfnt/pngshim.c (premultiply_data): Provide code which uses |
| 759 | gcc's (and clang's) `vector_byte' attribute to process 4 pixels at a |
| 760 | time. |
| 761 | |
Werner Lemberg | b45043c | 2017-08-11 09:34:20 +0200 | [diff] [blame] | 762 | 2017-08-11 Werner Lemberg <wl@gnu.org> |
| 763 | |
| 764 | [sfnt, truetype] Improve handling of missing sbits. |
| 765 | |
| 766 | Requested by Behdad. |
| 767 | |
| 768 | Modern bitmap-only SFNTs like `NotoColorEmoji.ttf' don't contain |
| 769 | entries in the bitmap strike(s) for empty glyphs. Instead, they |
| 770 | rely that a space glyph gets created from the font's metrics data. |
| 771 | This commit makes FreeType behave accordingly. |
| 772 | |
| 773 | * include/freetype/fterrdef.h (FT_Err_Missing_Bitmap): New error |
| 774 | code. |
| 775 | |
| 776 | * src/sfnt/ttsbit.c (tt_sbit_decoder_load_image): Change error codes |
| 777 | to make a distinction between a missing bitmap in a composite and a |
| 778 | simple missing bitmap. |
| 779 | |
| 780 | * src/truetype/ttgload.c (TT_Load_Glyph): For a missing bitmap (in a |
| 781 | bitmap-only font), synthesize an empty bitmap glyph if metrics are |
| 782 | available. |
| 783 | |
Werner Lemberg | f2e121a | 2017-08-10 12:56:50 +0200 | [diff] [blame] | 784 | 2017-08-10 Werner Lemberg <wl@gnu.org> |
| 785 | |
| 786 | [base] Minor API improvement for default variation axis setting. |
| 787 | |
| 788 | * src/base/ftmm.c (FT_Set_MM_Design_Coordinates, |
| 789 | FT_Set_Var_Design_Coordinates, FT_Set_MM_Blend_Coordinates, |
| 790 | FT_Set_Var_Blend_Coordinates): Allow coords==NULL if num_coords==0. |
| 791 | |
| 792 | * docs/CHANGES: Updated. |
| 793 | |
Werner Lemberg | c87fec0 | 2017-08-09 07:45:12 +0200 | [diff] [blame] | 794 | 2017-08-08 Werner Lemberg <wl@gnu.org> |
| 795 | |
| 796 | [psnames] Really fix issue #49949. |
| 797 | |
| 798 | We now use a separate preprocessor macro to handle both definition |
| 799 | and declaration of the glyph name arrays. |
| 800 | |
| 801 | * src/psnames/psmodule.c (DEFINE_PS_TABLE_DATA): New macro. |
| 802 | |
| 803 | * src/tools/glnames.py (StringTable::dump, |
| 804 | StringTable::dump_sublist): Use `DEFINE_PS_TABLE_DATA'. |
| 805 | (dump_encoding): Ditto. |
| 806 | (main): Use `wb' mode for writing the output file, which works on |
| 807 | Windows also. |
| 808 | |
| 809 | * src/psnames/pstables.h: Regenerated. |
| 810 | |
Alexei Podtelezhnikov | a9d8e90 | 2017-08-08 21:42:37 -0400 | [diff] [blame] | 811 | 2017-08-08 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 812 | |
Alexei Podtelezhnikov | 410f379 | 2017-03-09 00:08:38 -0500 | [diff] [blame] | 813 | [smooth] Harmony LCD rendering. |
| 814 | |
| 815 | This is a new technology for LCD-optimized rendering. It capitalizes |
| 816 | on the fact that each color channel grid is shifted by a third of a |
| 817 | pixel. Therefore it is logical to render 3 separate monochrome |
| 818 | bitmaps shifting the outline by 1/3 pixel, and then combine them. |
| 819 | Importantly, the resulting output does not require additional LCD |
| 820 | filtering. |
| 821 | |
| 822 | * src/smooth/ftsmooth.c (ft_smooth_render_generic) |
| 823 | [!FT_CONFIG_OPTION_SUBPIXEL_RENDERING]: Implement new LCD-optimized |
| 824 | rendering. |
| 825 | |
| 826 | * include/freetype/ftlcdfil.h, include/freetype/freetype.h, |
| 827 | include/freetype/config/ftoption.h, devel/ftoption.h: Updated |
| 828 | documentation. |
| 829 | |
| 830 | 2017-08-08 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 831 | |
Alexei Podtelezhnikov | 5710ef9 | 2017-08-08 22:00:35 -0400 | [diff] [blame] | 832 | * src/smooth/ftsmooth.c (ft_smooth_render_generic): Clean up. |
| 833 | |
| 834 | 2017-08-08 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 835 | |
Alexei Podtelezhnikov | c28e9c9 | 2017-09-15 22:23:01 -0400 | [diff] [blame] | 836 | * src/sfnt/ttpost.c (format): Use otspec-compliant versions. |
Alexei Podtelezhnikov | a9d8e90 | 2017-08-08 21:42:37 -0400 | [diff] [blame] | 837 | |
Werner Lemberg | c87fec0 | 2017-08-09 07:45:12 +0200 | [diff] [blame] | 838 | 2017-08-05 Werner Lemberg <wl@gnu.org> |
Werner Lemberg | 17196b7 | 2017-08-05 18:58:34 +0200 | [diff] [blame] | 839 | |
| 840 | [truetype] Integer overflow. |
| 841 | |
| 842 | Reported as |
| 843 | |
| 844 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2868 |
| 845 | |
| 846 | * src/truetype/ttinterp.c (Ins_ALIGNRP): Use NEG_LONG. |
| 847 | |
Werner Lemberg | f43b309 | 2017-08-05 18:22:17 +0200 | [diff] [blame] | 848 | 2017-08-05 Werner Lemberg <wl@gnu.org> |
| 849 | |
| 850 | [base, truetype] New function `FT_Get_Var_Axis_Flags'. |
| 851 | |
| 852 | The reserved `flags' field got a value in OpenType version 1.8.2; |
| 853 | unfortunately, the public `FT_Var_Axis' structure misses the |
| 854 | corresponding element. Since we can't add a new field, we add an |
| 855 | access function. |
| 856 | |
| 857 | * src/base/ftmm.c (FT_Get_Var_Axis_Flags): New function. |
| 858 | |
| 859 | * include/freetype/ftmm.h (FT_VAR_AXIS_FLAG_HIDDEN): New macro. |
| 860 | Updated. |
| 861 | |
| 862 | * src/truetype/ttgxvar.c (TT_Get_MM_Var): Increase allocated memory |
| 863 | of `mmvar' to hold axis flags. |
| 864 | Fill the axis flags array. |
| 865 | |
| 866 | * docs/CHANGES: Updated. |
| 867 | |
Nikolaus Waxweiler | 7f44c2d | 2017-08-03 06:15:30 +0200 | [diff] [blame] | 868 | 2017-08-03 Nikolaus Waxweiler <madigens@gmail.com> |
| 869 | |
Nikolaus Waxweiler | 24e256a | 2017-08-04 08:25:31 +0200 | [diff] [blame] | 870 | [truetype] Fix metrics of B/W hinting in v40 mode. |
| 871 | |
| 872 | Phantom points are now saved outside v40 backwards compatibility |
| 873 | mode. This fixes the jumping glyphs when switching between v35 and |
| 874 | v40 monochrome mode. |
| 875 | |
| 876 | * src/truetype/ttgload.c (TT_Hint_Glyph): Fix inversed bool logic. |
| 877 | |
| 878 | 2017-08-03 Nikolaus Waxweiler <madigens@gmail.com> |
| 879 | |
Nikolaus Waxweiler | 7f44c2d | 2017-08-03 06:15:30 +0200 | [diff] [blame] | 880 | [truetype] Do not set any ClearType flags in v40 monochrome mode. |
| 881 | |
| 882 | This fixes weird behavior of instructions that resulted in rendering |
| 883 | differences between v35 and v40 in monochrome mode, e.g., in |
| 884 | `timesbi.ttf'. |
| 885 | |
| 886 | * src/truetype/ttinterp.c (Ins_GETINFO) |
| 887 | [TT_SUPPORT_SUBPIXEL_HINTING_MINIMAL]: Check |
| 888 | `subpixel_hinting_lean'. |
| 889 | |
Werner Lemberg | 7e50824 | 2017-08-01 12:44:35 +0200 | [diff] [blame] | 890 | 2017-08-01 Werner Lemberg <wl@gnu.org> |
| 891 | |
| 892 | * src/truetype/ttgxvar.c (TT_Get_MM_Var): Fix thinko. |
| 893 | |
Behdad Esfahbod | 55bbb98 | 2017-08-01 09:17:02 +0200 | [diff] [blame] | 894 | 2017-08-01 Behdad Esfahbod <behdad@behdad.org> |
| 895 | |
| 896 | [truetype] Fix loading of named instances. |
| 897 | |
| 898 | * src/truetype/ttgxvar.c (TT_Get_MM_Var): Preserve file position |
| 899 | while loading the `avar' table. |
| 900 | |
Werner Lemberg | ce36777 | 2017-08-01 08:24:51 +0200 | [diff] [blame] | 901 | 2017-08-01 Werner Lemberg <wl@gnu.org> |
| 902 | |
| 903 | [sfnt, truetype] Minor adjustments for OpenType 1.8.2. |
| 904 | |
| 905 | * src/sfnt/sfobjs.c (sfnt_load_face): The units per EM value has now |
| 906 | (tighter) limits. |
| 907 | |
| 908 | * src/truetype/ttgload.c (load_truetype_glyph): The new OpenType |
| 909 | version explicitly allows all negative values for the number of |
| 910 | contours if we have a composite glyph (this is for better backwards |
| 911 | compatibility I guess), but it still recommends value -1. |
| 912 | |
Werner Lemberg | 933f4cb | 2017-07-26 23:32:32 +0200 | [diff] [blame] | 913 | 2017-07-26 Werner Lemberg <wl@gnu.org> |
| 914 | |
| 915 | [cff] Integer overflow. |
| 916 | |
| 917 | Reported as |
| 918 | |
| 919 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2738 |
| 920 | |
| 921 | * src/cff/cf2hints.c (cf2_glyphpath_computeOffset, |
| 922 | cf2_glyphpath_curveTo): Use ADD_INT32. |
| 923 | |
Werner Lemberg | fe0a7d9 | 2017-07-13 10:25:42 +0200 | [diff] [blame] | 924 | 2017-07-13 Werner Lemberg <wl@gnu.org> |
| 925 | |
| 926 | [base] Fix memory leak. |
| 927 | |
| 928 | Reported as |
| 929 | |
| 930 | https://bugs.chromium.org/p/chromium/issues/detail?id=738362 |
| 931 | |
| 932 | * src/base/ftglyph.c (FT_Get_Glyph): Do proper deallocation in case |
| 933 | of error. |
| 934 | |
Werner Lemberg | 3d083fc | 2017-07-12 00:24:48 +0200 | [diff] [blame] | 935 | 2017-07-12 Werner Lemberg <wl@gnu.org> |
| 936 | |
Werner Lemberg | 134de09 | 2017-07-12 22:16:37 +0200 | [diff] [blame] | 937 | [base] Integer overflow. |
| 938 | |
| 939 | Reported as |
| 940 | |
| 941 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2573 |
| 942 | |
| 943 | * src/base/ftobjs.c (ft_glyphslot_grid_fit_metrics): Use |
| 944 | FT_PIX_CEIL_LONG and FT_PIX_ROUND_LONG. |
| 945 | |
| 946 | 2017-07-12 Werner Lemberg <wl@gnu.org> |
| 947 | |
Werner Lemberg | 3d083fc | 2017-07-12 00:24:48 +0200 | [diff] [blame] | 948 | * src/truetype/ttpload.c (tt_face_get_location): Off-by-one typo. |
| 949 | |
| 950 | Also improve tracing message. |
| 951 | |
| 952 | Problem reported as |
| 953 | |
| 954 | https://bugs.chromium.org/p/chromium/issues/detail?id=738919 |
| 955 | |
Werner Lemberg | 9ea83c7 | 2017-07-07 17:09:43 +0200 | [diff] [blame] | 956 | 2017-07-07 Werner Lemberg <wl@gnu.org> |
| 957 | |
| 958 | [cff] Integer overflow. |
| 959 | |
| 960 | Reported as |
| 961 | |
| 962 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2517 |
| 963 | |
| 964 | * src/cff/cf2blues.c (cf2_blues_capture): Use SUB_INT32. |
| 965 | |
Werner Lemberg | 4261e49 | 2017-07-05 23:00:23 +0200 | [diff] [blame] | 966 | 2017-07-05 Werner Lemberg <wl@gnu.org> |
| 967 | |
Werner Lemberg | cf8d9b4 | 2017-07-05 23:07:01 +0200 | [diff] [blame] | 968 | * src/sfnt/ttcmap.c (tt_cmap_unicode_class_rec): Fix warning. |
| 969 | |
| 970 | 2017-07-05 Werner Lemberg <wl@gnu.org> |
| 971 | |
Werner Lemberg | 4261e49 | 2017-07-05 23:00:23 +0200 | [diff] [blame] | 972 | * src/truetype/ttgxvar.c (FT_Stream_SeekSet): Fix warning (#51395). |
| 973 | |
Werner Lemberg | 1c85479 | 2017-07-04 08:08:54 +0200 | [diff] [blame] | 974 | 2017-07-04 Werner Lemberg <wl@gnu.org> |
| 975 | |
| 976 | [truetype] Prevent address overflow (#51365). |
| 977 | |
| 978 | * src/truetype/ttgxvar.c (FT_Stream_SeekSet): Add guard. |
| 979 | |
Alexei Podtelezhnikov | c56d885 | 2017-07-03 22:49:07 -0400 | [diff] [blame] | 980 | 2017-07-03 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 981 | |
| 982 | * src/base/ftlcdfil.c (ft_lcd_filter_fir): Improve code. |
| 983 | |
Werner Lemberg | ca799e9 | 2017-07-03 06:27:52 +0200 | [diff] [blame] | 984 | 2017-07-03 Werner Lemberg <wl@gnu.org> |
| 985 | |
| 986 | [truetype] Integer overflow. |
| 987 | |
| 988 | Reported as |
| 989 | |
| 990 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2455 |
| 991 | |
| 992 | * src/truetype/ttinterp.c (Ins_SCFS): Use SUB_LONG. |
| 993 | |
Alexei Podtelezhnikov | abeb28f | 2017-07-01 16:48:32 -0400 | [diff] [blame] | 994 | 2017-07-01 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 995 | |
| 996 | * src/sfnt/sfobjs.c (sfnt_load_face): Ignore No_Unicode_Glyph_Name. |
| 997 | |
Ben Wagner | 7819aeb | 2017-06-28 22:57:41 +0200 | [diff] [blame] | 998 | 2017-06-28 Ben Wagner <bungeman@google.com> |
| 999 | |
| 1000 | Avoid Microsoft compiler warnings (#51331). |
| 1001 | |
| 1002 | While clang's sanitizer recommends a cast to unsigned for safe |
| 1003 | negation (to handle -INT_MIN), both MSVC and Visualc emit warning |
| 1004 | C4146 if an unsigned value gets negated. |
| 1005 | |
| 1006 | * include/freetype/internal/ftcalc.h (NEG_LONG, NEG_INT32), |
| 1007 | src/base/ftcalc.c (FT_MOVE_SIGN): Replace negation with a |
| 1008 | subtraction. |
| 1009 | |
Werner Lemberg | dde8f5a | 2017-06-27 06:16:04 +0200 | [diff] [blame] | 1010 | 2017-06-27 Werner Lemberg <wl@gnu.org> |
| 1011 | |
Werner Lemberg | 2e7bb5e | 2017-06-27 16:56:38 +0200 | [diff] [blame] | 1012 | * src/cff/cffparse.c (do_fixed): Fix typo. |
| 1013 | |
| 1014 | Spotted by chris <chris@gcjd.org>. |
| 1015 | |
| 1016 | 2017-06-27 Werner Lemberg <wl@gnu.org> |
| 1017 | |
Werner Lemberg | dde8f5a | 2017-06-27 06:16:04 +0200 | [diff] [blame] | 1018 | [truetype] Integer overflows. |
| 1019 | |
| 1020 | Reported as |
| 1021 | |
| 1022 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2384 |
| 1023 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2391 |
| 1024 | |
| 1025 | * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round, FT_DivFix): Use |
| 1026 | NEG_LONG. |
| 1027 | |
| 1028 | * src/truetype/ttinterp.c (Ins_SxVTL): Use NEG_LONG. |
| 1029 | |
Werner Lemberg | b27cef2 | 2017-06-24 20:17:46 +0200 | [diff] [blame] | 1030 | 2017-06-24 Werner Lemberg <wl@gnu.org> |
| 1031 | |
| 1032 | [truetype] Integer overflows. |
| 1033 | |
| 1034 | Reported as |
| 1035 | |
| 1036 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2364 |
| 1037 | |
| 1038 | * src/truetype/ttinterp.c (Ins_ISECT): Use NEG_LONG. |
| 1039 | |
Werner Lemberg | 298e2ea | 2017-06-22 11:52:43 +0200 | [diff] [blame] | 1040 | 2017-06-22 Werner Lemberg <wl@gnu.org> |
| 1041 | |
| 1042 | [cff, truetype] Integer overflows. |
| 1043 | |
| 1044 | Reported as |
| 1045 | |
| 1046 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2323 |
| 1047 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2328 |
| 1048 | |
| 1049 | * src/cff/cf2blues.c (cf2_blues_capture): Use ADD_INT32 and |
| 1050 | SUB_INT32. |
| 1051 | |
| 1052 | * src/truetype/ttinterp.c (Ins_SDPVTL): Use SUB_LONG and NEG_LONG. |
| 1053 | |
Alexei Podtelezhnikov | 75cb071 | 2017-06-21 22:52:37 -0400 | [diff] [blame] | 1054 | 2017-06-21 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 1055 | |
| 1056 | [sfnt] Synthesize a Unicode charmap if one is missing. |
| 1057 | |
| 1058 | * src/sfnt/ttcmap.h (tt_cmap_unicode_class_rec): Declare it. |
| 1059 | * src/sfnt/ttcmap.c (tt_get_glyph_name, tt_cmap_unicode_init, |
| 1060 | tt_cmap_unicode_done, tt_cmap_unicode_char_index, |
| 1061 | tt_cmap_unicode_char_next, tt_cmap_unicode_class_rec): Implement |
| 1062 | synthetic Unicode charmap class. |
| 1063 | (tt_get_cmap_info): Make sure the callback is available. |
| 1064 | |
| 1065 | * src/sfnt/sfobjs.c (sfnt_load_face) |
| 1066 | [FT_CONFIG_OPTION_POSTSCRIPT_NAMES]: If Unicode charmap is missing, |
| 1067 | synthesize one. |
| 1068 | |
| 1069 | * include/freetype/config/ftoption.h: Document it. |
| 1070 | * devel/ftoption.h: Ditto. |
| 1071 | |
Tony Theodore | c8829e4 | 2017-06-20 12:24:05 +0200 | [diff] [blame] | 1072 | 2017-06-20 Tony Theodore <tonyt@logyst.com> |
| 1073 | |
| 1074 | Fix pkg-config in freetype-config for cross-compiling (#51274). |
| 1075 | |
| 1076 | * builds/unix/unix-def.in (PKG_CONFIG): New variable. |
| 1077 | (freetype-config): Use it in sed expression. |
| 1078 | |
| 1079 | * builds/unix/freetype-config.in: s/pkg-config/%PKG_CONFIG%/. |
| 1080 | |
| 1081 | 2017-06-20 Werner Lemberg <wl@gnu.org> |
Werner Lemberg | 8c763fb | 2017-06-20 07:49:52 +0200 | [diff] [blame] | 1082 | |
| 1083 | [cff, truetype] Integer overflows. |
| 1084 | |
| 1085 | Reported as |
| 1086 | |
| 1087 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2300 |
| 1088 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2313 |
| 1089 | |
| 1090 | * src/cff/cf2hints.c (cf2_hintmap_adjustHints): Use ADD_INT32. |
| 1091 | |
| 1092 | * src/truetype/ttinterp.c (Ins_ABS): Avoid FT_ABS. |
| 1093 | |
Alexei Podtelezhnikov | 7b72783 | 2017-06-17 23:28:14 -0400 | [diff] [blame] | 1094 | 2017-06-17 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 1095 | |
| 1096 | [base, smooth] LCD filtering cleanups. |
| 1097 | |
Alexei Podtelezhnikov | c56d885 | 2017-07-03 22:49:07 -0400 | [diff] [blame] | 1098 | * src/base/ftlcdfil.c (ft_lcd_filter_fir, _ft_lcd_filter_legacy): |
Alexei Podtelezhnikov | 7b72783 | 2017-06-17 23:28:14 -0400 | [diff] [blame] | 1099 | Clean up, start filtering from the bottom-left origin. |
| 1100 | |
| 1101 | * src/smooth/ftsmooth.c (ft_smooth_render_generic): Updated. |
| 1102 | |
Werner Lemberg | 4dc00cf | 2017-06-16 13:33:09 +0200 | [diff] [blame] | 1103 | 2017-06-16 Werner Lemberg <wl@gnu.org> |
| 1104 | |
| 1105 | [truetype] Integer overflows. |
| 1106 | |
| 1107 | Reported as |
| 1108 | |
| 1109 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2270 |
Hin-Tak Leung | 39af82e | 2017-07-11 01:53:01 +0100 | [diff] [blame] | 1110 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2276 |
Werner Lemberg | 4dc00cf | 2017-06-16 13:33:09 +0200 | [diff] [blame] | 1111 | |
| 1112 | * src/truetype/ttinterp.c (Ins_MDRP, _iup_worker_interpolate): Use |
| 1113 | ADD_LONG and SUB_LONG. |
| 1114 | |
Werner Lemberg | dbeb7bc | 2017-06-15 19:39:50 +0200 | [diff] [blame] | 1115 | 2017-06-15 Werner Lemberg <wl@gnu.org> |
| 1116 | |
| 1117 | [bdf, cff] Integer overflows. |
| 1118 | |
| 1119 | Reported as |
| 1120 | |
| 1121 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2244 |
| 1122 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2261 |
| 1123 | |
| 1124 | * src/bdf/bdfdrivr.c (BDF_Face_Init): Replace calls to FT_ABS with |
| 1125 | direct code to avoid value negation. |
| 1126 | |
| 1127 | * src/cff/cf2blues.c (cf2_blues_capture): Use SUB_INT32 and |
| 1128 | ADD_INT32. |
| 1129 | |
Werner Lemberg | 5c402d9 | 2017-06-13 06:56:48 +0200 | [diff] [blame] | 1130 | 2017-06-13 Werner Lemberg <wl@gnu.org> |
| 1131 | |
Werner Lemberg | 79e3789 | 2017-06-14 07:51:04 +0200 | [diff] [blame] | 1132 | * src/winfonts/winfnt.c (FNT_Face_Init): Don't set active encoding. |
| 1133 | |
| 1134 | FreeType only sets a default active encoding for Unicode. |
| 1135 | |
| 1136 | 2017-06-13 Werner Lemberg <wl@gnu.org> |
| 1137 | |
Werner Lemberg | 5c402d9 | 2017-06-13 06:56:48 +0200 | [diff] [blame] | 1138 | [cff, truetype] Integer overflows. |
| 1139 | |
| 1140 | Reported as |
| 1141 | |
| 1142 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2216 |
| 1143 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2218 |
| 1144 | |
| 1145 | * src/cff/cf2fixed.h (cf2_fixedAbs): Use NEG_INT32. |
| 1146 | |
| 1147 | * src/truetype/ttinterp.c (Ins_IP): Use SUB_LONG. |
| 1148 | |
Werner Lemberg | 3ed3a96 | 2017-06-11 13:50:37 +0200 | [diff] [blame] | 1149 | 2017-06-11 Werner Lemberg <wl@gnu.org> |
| 1150 | |
| 1151 | [cff] Integer overflows. |
| 1152 | |
| 1153 | Reported as |
| 1154 | |
| 1155 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2200 |
| 1156 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2210 |
| 1157 | |
| 1158 | * src/cff/cf2hints.c (cf2_hintmap_insertHint): Use SUB_INT32 and |
| 1159 | ADD_INT32. |
| 1160 | |
| 1161 | * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdVMOVETO>: Use |
| 1162 | ADD_INT32. |
| 1163 | |
Werner Lemberg | 2c4fba9 | 2017-06-10 11:03:41 +0200 | [diff] [blame] | 1164 | 2017-06-10 Werner Lemberg <wl@gnu.org> |
| 1165 | |
Werner Lemberg | 5f2a72c | 2017-06-10 11:29:24 +0200 | [diff] [blame] | 1166 | [truetype] Fix TT_Set_Var_Design. |
| 1167 | |
| 1168 | Reported by Nikolaus Waxweiler <madigens@gmail.com>. |
| 1169 | |
| 1170 | * src/truetype/ttgxvar.c (TT_Set_Var_Design): Correctly handle the |
| 1171 | case where we have less input coordinates than axes. |
| 1172 | |
| 1173 | 2017-06-10 Werner Lemberg <wl@gnu.org> |
| 1174 | |
Werner Lemberg | 2c4fba9 | 2017-06-10 11:03:41 +0200 | [diff] [blame] | 1175 | * src/base/ftcalc.c (FT_DivFix): Fix embarrassing typo. |
| 1176 | |
| 1177 | Bug introduced 2017-05-28. |
| 1178 | |
Werner Lemberg | dcd8de2 | 2017-06-09 11:21:58 +0200 | [diff] [blame] | 1179 | 2017-06-09 Werner Lemberg <wl@gnu.org> |
| 1180 | |
Werner Lemberg | 9038837 | 2017-06-09 20:42:46 +0200 | [diff] [blame] | 1181 | [cff, truetype] Integer overflows. |
| 1182 | |
| 1183 | Reported as |
| 1184 | |
| 1185 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2144 |
| 1186 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2151 |
| 1187 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2153 |
| 1188 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2173 |
| 1189 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2186 |
| 1190 | |
| 1191 | * src/cff/cf2blues.c (cf2_blues_init): Use SUB_INT32. |
| 1192 | |
| 1193 | * src/truetype/ttinterp.c (Round_None, Round_To_Grid, |
| 1194 | Round_To_Half_Grid, Round_Down_To_Grid, Round_Up_To_Grid, |
| 1195 | Round_To_Double_Grid, Round_Super, Round_Super_45): Use ADD_LONG, |
| 1196 | SUB_LONG, NEG_LONG, FT_PIX_ROUND_LONG, FT_PIX_CEIL_LONG, |
| 1197 | FT_PAD_ROUND_LONG |
| 1198 | (Ins_SxVTL, Ins_MIRP): Use SUB_LONG. |
| 1199 | (_iup_worker_shift): Use SUB_LONG and ADD_LONG. |
| 1200 | |
| 1201 | 2017-06-09 Werner Lemberg <wl@gnu.org> |
| 1202 | |
Werner Lemberg | 96d2692 | 2017-06-09 20:34:28 +0200 | [diff] [blame] | 1203 | Provide more macros for flooring, ceiling, and rounding. |
| 1204 | |
| 1205 | These versions don't produce run-time errors due to integer |
| 1206 | overflow. |
| 1207 | |
| 1208 | * include/freetype/internal/ftobjs.h: Include FT_INTERNAL_CALC_H. |
| 1209 | (FT_PAD_ROUND_LONG, FT_PAD_CEIL_LONG, FT_PIX_ROUND_LONG, |
| 1210 | FT_PIX_CEIL_LONG): New macros. |
| 1211 | (FT_PAD_ROUND_INT32, FT_PAD_CEIL_INT32, FT_PIX_ROUND_INT32, |
| 1212 | FT_PIX_CEIL_INT32): New macros. |
| 1213 | |
| 1214 | 2017-06-09 Werner Lemberg <wl@gnu.org> |
| 1215 | |
Werner Lemberg | faf34d2 | 2017-06-09 20:31:24 +0200 | [diff] [blame] | 1216 | Remove unused macros. |
| 1217 | |
| 1218 | * include/freetype/internal/ftcalc.h (ADD_INT, SUB_INT, MUL_INT, |
| 1219 | NEG_INT): Deleted. |
| 1220 | |
| 1221 | 2017-06-09 Werner Lemberg <wl@gnu.org> |
| 1222 | |
Werner Lemberg | dcd8de2 | 2017-06-09 11:21:58 +0200 | [diff] [blame] | 1223 | */*: Remove `OVERFLOW_' prefix. |
| 1224 | |
| 1225 | This increases readability. |
| 1226 | |
Werner Lemberg | 7bffeac | 2017-06-07 17:08:01 +0200 | [diff] [blame] | 1227 | 2017-06-07 Werner Lemberg <wl@gnu.org> |
| 1228 | |
| 1229 | [cff, truetype] Integer overflows. |
| 1230 | |
| 1231 | Reported as |
| 1232 | |
| 1233 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2133 |
| 1234 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2137 |
| 1235 | |
| 1236 | * src/cff/cf2hints.c (cf2_hint_init): Use OVERFLOW_SUB_INT32. |
| 1237 | |
| 1238 | * src/truetype/ttinterp.c (PROJECT, DUALPROJ): Use |
| 1239 | OVERFLOW_SUB_LONG. |
| 1240 | |
Werner Lemberg | 24848a3 | 2017-06-06 12:05:04 +0200 | [diff] [blame] | 1241 | 2017-06-06 Werner Lemberg <wl@gnu.org> |
| 1242 | |
Werner Lemberg | 7bffeac | 2017-06-07 17:08:01 +0200 | [diff] [blame] | 1243 | [cff] Integer overflows. |
Werner Lemberg | 24848a3 | 2017-06-06 12:05:04 +0200 | [diff] [blame] | 1244 | |
| 1245 | Reported as |
| 1246 | |
| 1247 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2109 |
| 1248 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2110 |
| 1249 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2122 |
| 1250 | |
| 1251 | * src/cff/cf2blues.c (cf2_blues_init): Use OVERFLOW_SUB_INT32. |
| 1252 | |
| 1253 | * src/cff/cf2hints.c (cf2_hintmap_map): Synchronize if-else |
| 1254 | branches. |
| 1255 | |
Werner Lemberg | 8667042 | 2017-06-05 06:20:53 +0200 | [diff] [blame] | 1256 | 2017-06-05 Werner Lemberg <wl@gnu.org> |
| 1257 | |
| 1258 | [cff] Integer overflow. |
| 1259 | |
| 1260 | Reported as |
| 1261 | |
| 1262 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2089 |
| 1263 | |
| 1264 | * src/cff/cffload.c (cff_blend_doBlend): User OVERFLOW_ADD_INT32. |
| 1265 | |
Werner Lemberg | 9fa8a29 | 2017-06-04 20:43:08 +0200 | [diff] [blame] | 1266 | 2017-06-04 Werner Lemberg <wl@gnu.org> |
| 1267 | |
| 1268 | [cff, truetype] Integer overflows. |
| 1269 | |
| 1270 | Reported as |
| 1271 | |
| 1272 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2075 |
| 1273 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2088 |
| 1274 | |
| 1275 | * src/cff/cf2font.c (cf2_font_setup): Use OVERFLOW_MUL_INT32. |
| 1276 | |
| 1277 | * src/truetype/ttinterp.c (Ins_ISECT): Use OVERFLOW_MUL_LONG, |
| 1278 | OVERFLOW_ADD_LONG, and OVERFLOW_SUB_LONG. |
| 1279 | |
Werner Lemberg | c5a2254 | 2017-06-03 06:13:10 +0200 | [diff] [blame] | 1280 | 2017-06-03 Werner Lemberg <wl@gnu.org> |
| 1281 | |
Werner Lemberg | addb2dd | 2017-06-03 21:05:42 +0200 | [diff] [blame] | 1282 | [base, cff, truetype] Integer overflows. |
| 1283 | |
| 1284 | Reported as |
| 1285 | |
| 1286 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2060 |
| 1287 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2062 |
| 1288 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2063 |
| 1289 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2068 |
| 1290 | |
| 1291 | * src/base/ftobjs.c (ft_glyphslot_grid_fit_metrics): Use |
| 1292 | OVERFLOW_ADD_LONG and OVERFLOW_SUB_LONG. |
| 1293 | |
| 1294 | * src/cff/cf2blues.c (cf2_blues_capture), src/cff/cf2hints.c |
| 1295 | (cf2_hintmap_adjustHints): Use OVERFLOW_SUB_INT32. |
| 1296 | |
| 1297 | * src/truetype/ttgload.c (compute_glyph_metrics): User |
| 1298 | OVERFLOW_SUB_LONG. |
| 1299 | |
| 1300 | * src/truetype/ttinterp.c (Direct_Move, Direct_Move_Orig, |
| 1301 | Direct_Move_X, Direct_Move_Y, Direct_Move_Orig_X, |
| 1302 | Direct_Move_Orig_Y, Move_Zp2_Point, Ins_MSIRP): Use |
| 1303 | OVERFLOW_ADD_LONG and OVERFLOW_SUB_LONG. |
| 1304 | |
| 1305 | 2017-06-03 Werner Lemberg <wl@gnu.org> |
| 1306 | |
Werner Lemberg | c9a9cf5 | 2017-06-03 09:41:50 +0200 | [diff] [blame] | 1307 | * builds/unix/freetype-config.in: Fix pkg-config test (#51162). |
| 1308 | |
| 1309 | Patch directly taken from bug report. |
| 1310 | |
| 1311 | 2017-06-03 Werner Lemberg <wl@gnu.org> |
| 1312 | |
Werner Lemberg | 2c2e640 | 2017-06-03 07:38:11 +0200 | [diff] [blame] | 1313 | [bdf] Synchronize sanity checks with pcf driver. |
| 1314 | |
| 1315 | Reported as |
| 1316 | |
| 1317 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2054 |
| 1318 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2058 |
| 1319 | |
| 1320 | * src/bdf/bdfdrivr.c (BDF_Face_Init): Check font ascent and descent. |
| 1321 | Check AVERAGE_WIDTH, POINT_SIZE, PIXEL_SIZE, RESOLUTION_X, and |
| 1322 | RESOLUTION_Y properties. |
| 1323 | |
| 1324 | 2017-06-03 Werner Lemberg <wl@gnu.org> |
| 1325 | |
Werner Lemberg | 1ea3432 | 2017-06-03 06:52:13 +0200 | [diff] [blame] | 1326 | [cff, truetype] Integer overflows. |
| 1327 | |
| 1328 | Reported as |
| 1329 | |
| 1330 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2047 |
| 1331 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2057 |
| 1332 | |
| 1333 | * src/cff/cf2hints.c (cf2_hintmap_map): Use OVERFLOW_SUB_INT32. |
| 1334 | |
| 1335 | * src/truetype/ttinterp.c (Ins_ADD): Use OVERFLOW_ADD_LONG. |
| 1336 | (Ins_SUB): Use OVERFLOW_SUB_LONG. |
| 1337 | (Ins_NEG): Use NEG_LONG. |
| 1338 | |
| 1339 | 2017-06-03 Werner Lemberg <wl@gnu.org> |
| 1340 | |
Werner Lemberg | c5a2254 | 2017-06-03 06:13:10 +0200 | [diff] [blame] | 1341 | ftcalc.h: Avoid left-shift of negative numbers. |
| 1342 | |
| 1343 | Reported as |
| 1344 | |
| 1345 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2055 |
| 1346 | |
| 1347 | * include/freetype/internal/ftcalc.h (INT_TO_F26DOT6, |
| 1348 | INT_TO_F2DOT14, INT_TO_FIXED, F2DOT14_TO_FIXED): Use multiplication. |
| 1349 | |
Werner Lemberg | 3802ca8 | 2017-06-02 08:44:20 +0200 | [diff] [blame] | 1350 | 2017-06-02 Werner Lemberg <wl@gnu.org> |
| 1351 | |
Werner Lemberg | 0716c6a | 2017-06-02 19:24:03 +0200 | [diff] [blame] | 1352 | [cff] Even more integer overflows. |
| 1353 | |
| 1354 | Reported as |
| 1355 | |
| 1356 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2046 |
| 1357 | |
| 1358 | * src/cff/cf2intrp.c (cf2_doStems, cf2_interpT2CharString): Use |
| 1359 | OVERFLOW_ADD_INT32. |
| 1360 | |
| 1361 | 2017-06-02 Werner Lemberg <wl@gnu.org> |
| 1362 | |
Werner Lemberg | 7a4276f | 2017-06-02 09:21:37 +0200 | [diff] [blame] | 1363 | [cff] More integer overflows. |
| 1364 | |
| 1365 | Reported as |
| 1366 | |
| 1367 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2032 |
| 1368 | |
| 1369 | * src/cff/cf2blues.c (cf2_blues_init): Use OVERFLOW_SUB_INT32. |
| 1370 | |
| 1371 | 2017-06-02 Werner Lemberg <wl@gnu.org> |
| 1372 | |
Werner Lemberg | 03b0cc2 | 2017-06-02 09:16:52 +0200 | [diff] [blame] | 1373 | [bdf] Don't left-shift negative numbers. |
| 1374 | |
| 1375 | Reported as |
| 1376 | |
| 1377 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2031 |
| 1378 | |
| 1379 | * src/bdf/bdfdrivr.c (BDF_Face_Init): Use multiplication. |
| 1380 | |
| 1381 | 2017-06-02 Werner Lemberg <wl@gnu.org> |
| 1382 | |
Werner Lemberg | 47a03e9 | 2017-06-02 09:06:36 +0200 | [diff] [blame] | 1383 | [bdf] Fix integer scanning routines. |
| 1384 | |
| 1385 | Reported as |
| 1386 | |
| 1387 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2029 |
| 1388 | |
| 1389 | * src/bdf/bdflib.c (_bdf_atoul, _bdf_atol, _bdf_atous, _bdf_atos): |
| 1390 | Stop scanning if result would overflow. |
| 1391 | |
| 1392 | 2017-06-02 Werner Lemberg <wl@gnu.org> |
| 1393 | |
Werner Lemberg | 3802ca8 | 2017-06-02 08:44:20 +0200 | [diff] [blame] | 1394 | [cff] Fix integer overflows. |
| 1395 | |
| 1396 | Reported as |
| 1397 | |
| 1398 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2027 |
| 1399 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2028 |
| 1400 | |
| 1401 | * src/cff/cf2hints.c (cf2_hintmap_insertHint), src/cff/cf2intrp.c |
| 1402 | (cf2_doFlex): Use OVERFLOW_ADD_INT32 and OVERFLOW_SUB_INT32. |
| 1403 | |
Werner Lemberg | 8d435c4 | 2017-06-01 07:09:44 +0200 | [diff] [blame] | 1404 | 2017-06-01 Werner Lemberg <wl@gnu.org> |
| 1405 | |
Werner Lemberg | cd02d35 | 2017-06-01 17:05:39 +0200 | [diff] [blame] | 1406 | [smooth] Some 32bit integer overflow run-time errors. |
| 1407 | |
| 1408 | * src/smooth/ftgrays.c [STANDALONE] (OVERFLOW_ADD_LONG, |
| 1409 | OVERFLOW_SUB_LONG, OVERFLOW_MUL_LONG, NEG_LONG): New macros. |
| 1410 | [!STANDALONE]: Include FT_INTERNAL_CALC_H. |
| 1411 | (gray_render_cubic): Use those macros where appropriate. |
| 1412 | |
| 1413 | 2017-06-01 Werner Lemberg <wl@gnu.org> |
| 1414 | |
Werner Lemberg | 0ad3262 | 2017-06-01 17:00:37 +0200 | [diff] [blame] | 1415 | * src/base/ftglyph.c (FT_Get_Glyph): Check `slot->advance'. |
| 1416 | |
| 1417 | 2017-06-01 Werner Lemberg <wl@gnu.org> |
| 1418 | |
Werner Lemberg | 4a1f1a6 | 2017-06-01 13:15:54 +0200 | [diff] [blame] | 1419 | [psaux] 32bit integer overflow tun-time errors (#46149). |
| 1420 | |
| 1421 | * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Use |
| 1422 | OVERFLOW_ADD_LONG and OVERFLOW_SUB_LONG where appropriate. |
| 1423 | |
| 1424 | 2017-06-01 Werner Lemberg <wl@gnu.org> |
| 1425 | |
Werner Lemberg | 8d435c4 | 2017-06-01 07:09:44 +0200 | [diff] [blame] | 1426 | * src/truetype/ttinterp.c (TT_RunIns): Adjust loop counter again. |
| 1427 | |
| 1428 | Problem reported by Marek Kašík <mkasik@redhat.com>. |
| 1429 | |
| 1430 | The problematic font that exceeds the old limit is Padauk-Bold, |
| 1431 | version 3.002, containing bytecode generated by a buggy version of |
| 1432 | ttfautohint. |
| 1433 | |
Werner Lemberg | e66d730 | 2017-05-31 16:16:50 +0200 | [diff] [blame] | 1434 | 2017-05-31 Werner Lemberg <wl@gnu.org> |
| 1435 | |
| 1436 | [cff] 32bit integer overflow run-time errors 2/2 (#46149). |
| 1437 | |
| 1438 | This commit handles the new engine. |
| 1439 | |
| 1440 | * include/freetype/internal/ftcalc.h (OVERFLOW_ADD_INT32, |
| 1441 | OVERFLOW_SUB_INT32, OVERFLOW_MUL_INT32, NEG_INT, NEG_LONG, |
| 1442 | NEG_INT32): New macros. |
| 1443 | |
| 1444 | * src/cff/cf2ft.c (cf2_getScaleAndHintFlag): Use OVERFLOW_ADD_INT32. |
| 1445 | |
| 1446 | * src/cff/cf2hints.c (cf2_getWindingMomentum, cf2_hint_init, |
| 1447 | cf2_hintmap_map, cf2_glyphpath_hintPoint, |
| 1448 | cf2_glyphpath_computeIntersection, cf2_glyphpath_computeOffset, |
| 1449 | cf2_glyphpath_lineTo, cf2_glyphpath_curveTo): Use |
| 1450 | OVERFLOW_ADD_INT32, OVERFLOW_SUB_INT32, OVERFLOW_MUL_INT32, and |
| 1451 | NEG_INT32 where appropriate. |
| 1452 | |
| 1453 | * src/cff/cf2intrp.c (cf2_doFlex, cf2_doBlend, |
| 1454 | cf2_interpT2CharString): Ditto. |
| 1455 | Also add some other code where needed to avoid overflow. |
| 1456 | |
Werner Lemberg | 0e7b9f8 | 2017-05-30 22:22:19 +0200 | [diff] [blame] | 1457 | 2017-05-30 Werner Lemberg <wl@gnu.org> |
| 1458 | |
Werner Lemberg | 9b710cd | 2017-05-30 22:35:41 +0200 | [diff] [blame] | 1459 | [cff] 32bit integer overflow run-time errors 1/2 (#46149). |
| 1460 | |
| 1461 | This commit handles the old engine. |
| 1462 | |
| 1463 | * src/cff/cffgload.c: Include FT_INTERNAL_CALC_H. |
| 1464 | (cff_decoder_parse_charstrings): Use OVERFLOW_ADD_LONG and |
| 1465 | OVERFLOW_SUB_LONG where needed. |
| 1466 | |
| 1467 | * src/cff/cffparse.c: Include FT_INTERNAL_CALC_H. |
| 1468 | (power_ten_limits): New static array. |
| 1469 | (do_fixed): Use it to prevent multiplication overflow. |
| 1470 | (cff_parser_run): Use OVERFLOW_ADD_LONG. |
| 1471 | |
| 1472 | 2017-05-30 Werner Lemberg <wl@gnu.org> |
| 1473 | |
Werner Lemberg | 0e7b9f8 | 2017-05-30 22:22:19 +0200 | [diff] [blame] | 1474 | [psaux] Correctly handle sequences of multiple number signs. |
| 1475 | |
| 1476 | * src/psaux/psconv.c (PS_Conv_Strtol, PS_Conv_ToFixed): Return zero |
| 1477 | if we encounter more than a single sign. |
| 1478 | |
Werner Lemberg | fbe2fe4 | 2017-05-29 13:29:28 +0200 | [diff] [blame] | 1479 | 2017-05-29 Werner Lemberg <wl@gnu.org> |
| 1480 | |
Werner Lemberg | f014632 | 2017-05-29 21:04:27 +0200 | [diff] [blame] | 1481 | [pcf] 32bit integer overflow run-time errors (#46149). |
| 1482 | |
| 1483 | * src/pcf/pcfread.c (pcf_get_accel): Add sanity checks for |
| 1484 | `fontAscent' and `fontDescent'. |
| 1485 | (pcf_load_font): Add sanity checks for global height. |
| 1486 | Add sanity checks for AVERAGE_WIDTH, POINT_SIZE, PIXEL_SIZE, |
| 1487 | RESOLUTION_X, and RESOLUTION_Y properties. |
| 1488 | |
| 1489 | 2017-05-29 Werner Lemberg <wl@gnu.org> |
| 1490 | |
Werner Lemberg | fbe2fe4 | 2017-05-29 13:29:28 +0200 | [diff] [blame] | 1491 | Handle some integer overflow run-time errors (#46149, #48979). |
| 1492 | |
| 1493 | This commit (mainly for 32bit CPUs) is the first of a series of |
| 1494 | similar commits to handle known integer overflows. Basically, all |
| 1495 | of them are harmless, since they affect rendering of glyphs only, |
| 1496 | not posing security threats. It is expected that fuzzying will show |
| 1497 | up more overflows, to be fixed in due course. |
| 1498 | |
| 1499 | The idea is to mark places where overflows can occur, using macros |
| 1500 | that simply cast to unsigned integers, because overflow arithmetic |
| 1501 | is well defined in this case. Doing so suppresses run-time errors |
| 1502 | of sanitizers without adding computational overhead. |
| 1503 | |
| 1504 | * include/freetype/internal/ftcalc.h (OVERFLOW_ADD_INT, |
| 1505 | OVERFLOW_SUB_INT, OVERFLOW_MUL_INT, OVERFLOW_ADD_LONG, |
| 1506 | OVERFLOW_SUB_LONG, OVERFLOW_MUL_LONG): New macros. |
| 1507 | |
| 1508 | * src/base/ftcalc.c (FT_RoundFix, FT_CeilFix, FT_Matrix_Multiply, |
| 1509 | FT_Matrix_Multiply_Scaled, FT_Vector_Transform_Scaled, |
| 1510 | ft_corner_orientation): Use new macros. |
| 1511 | |
| 1512 | * src/base/ftoutln.c (FT_Outline_Get_Orientation): Use new macros. |
| 1513 | |
Werner Lemberg | 9357219 | 2017-05-28 07:20:09 +0200 | [diff] [blame] | 1514 | 2017-05-28 Werner Lemberg <wl@gnu.org> |
| 1515 | |
Werner Lemberg | 9d04fa7 | 2017-05-28 07:57:24 +0200 | [diff] [blame] | 1516 | * include/freetype/internal/ftcalc.h (FLOAT_TO_FIXED): Remove. |
| 1517 | |
| 1518 | This macro is not used. |
| 1519 | |
| 1520 | 2017-05-28 Werner Lemberg <wl@gnu.org> |
| 1521 | |
Werner Lemberg | 2e4188d | 2017-05-28 07:46:22 +0200 | [diff] [blame] | 1522 | [cff] s/cf2_floatToFixed/cf2_doubleToFixed/. |
| 1523 | |
| 1524 | The new name better describes what the macro actually does; |
| 1525 | additionally, we don't need a trailing `f' for literals (there was |
| 1526 | only a single such instance in the code, but this caused a clang |
| 1527 | warning because the macro itself uses `double' literals). |
| 1528 | |
| 1529 | * src/cff/cf2blues.c, src/cff/cf2blues.h, src/cff/cf2fixed.h, |
| 1530 | src/cff/cf2font.c, src/cff/cf2hints.c: Updated. |
| 1531 | |
| 1532 | 2017-05-28 Werner Lemberg <wl@gnu.org> |
| 1533 | |
Werner Lemberg | 9357219 | 2017-05-28 07:20:09 +0200 | [diff] [blame] | 1534 | Fix negation of INT_MIN and LONG_MIN (#46149). |
| 1535 | |
| 1536 | * src/base/ftcalc.c (FT_MOVE_SIGN): Add argument to pass unsigned |
| 1537 | value, to be used as the result. |
| 1538 | (FT_MulDiv, FT_MulDiv_No_Round, FT_DivFix, FT_MulFix, |
| 1539 | FT_Vector_NormLen): Updated. |
| 1540 | |
Werner Lemberg | a9331c0 | 2017-05-27 15:50:25 +0200 | [diff] [blame] | 1541 | 2017-05-27 Werner Lemberg <wl@gnu.org> |
| 1542 | |
| 1543 | [truetype] Fix handling of design coordinates (#51127). |
| 1544 | |
| 1545 | * src/truetype/ttgxvar.c (tt_set_mm_blend): Compute all design |
| 1546 | coordinates if we have to create the `blends->coord' array. |
| 1547 | (TT_Get_MM_Blend, TT_Get_Var_Design): Select default instance |
| 1548 | coordinates if no instance is selected yet. |
| 1549 | |
Werner Lemberg | 082f2fa | 2017-05-24 07:40:46 +0200 | [diff] [blame] | 1550 | 2017-05-24 Werner Lemberg <wl@gnu.org> |
| 1551 | |
| 1552 | [bdf, pcf] Support ISO646.1991-IRV character encoding (aka ASCII). |
| 1553 | |
| 1554 | Problem reported by Marek Kašík <mkasik@redhat.com>, cf. |
| 1555 | |
| 1556 | https://bugzilla.redhat.com/show_bug.cgi?id=1451795 |
| 1557 | |
| 1558 | * src/bdf/bdfdrivr.c (BDF_Face_Init), src/pcf/pcfdrivr.c |
| 1559 | (PCF_Face_Init): Implement it. |
| 1560 | |
Nikolaus Waxweiler | a045546 | 2017-05-20 07:28:46 +0200 | [diff] [blame] | 1561 | 2017-05-20 Nikolaus Waxweiler <madigens@gmail.com> |
| 1562 | |
| 1563 | [truetype] Always use interpreter v35 for B/W rendering (#51051). |
| 1564 | |
| 1565 | * src/truetype/ttgload.c (tt_loader_init) |
| 1566 | [TT_SUPPORT_SUBPIXEL_HINTING_MINIMAL]: Adjust |
| 1567 | `subpixel_hinting_lean', `grayscale_cleartype', and |
| 1568 | `vertical_lcd_lean' accordingly. |
| 1569 | |
| 1570 | * src/truetype/ttinterp.c (Ins_GETINFO): Updated. |
| 1571 | (TT_RunIns): Update `backward_compatibility' flag. |
| 1572 | |
Alexei Podtelezhnikov | ab2599e | 2017-05-20 00:35:21 -0400 | [diff] [blame] | 1573 | 2017-05-20 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 1574 | |
| 1575 | [smooth] Implement minimal dynamic padding for LCD filtering. |
| 1576 | |
| 1577 | Extra bitmap padding for LCD filtering depends on the filter. The |
| 1578 | default 5-tap filter needs 2 extra subpixels. The light 3-tap filter |
| 1579 | needs only 1 extra subpixel. This space could be already available |
| 1580 | due to rounding. In order to optimize the padding, we now expand |
| 1581 | CBox for the given filter weights before rounding. |
| 1582 | |
Alexei Podtelezhnikov | c28e9c9 | 2017-09-15 22:23:01 -0400 | [diff] [blame] | 1583 | This change breaks current Skia (and Firefox). |
Alexei Podtelezhnikov | ab2599e | 2017-05-20 00:35:21 -0400 | [diff] [blame] | 1584 | |
| 1585 | * include/freetype/internal/ftobjs.h (FT_LibraryRec) |
| 1586 | [FT_CONFIG_OPTION_SUBPIXEL_RENDERING]: Remove `lcd_extra' field. |
| 1587 | |
| 1588 | * src/base/ftlcdfil.c (FT_Library_SetLcdFilterWeights, |
| 1589 | FT_Library_SetLcdFilter): Remove `lcd_extra' initializations. |
| 1590 | |
| 1591 | * src/smooth/ftsmooth.c (ft_smooth_render_generic): Implement dymanic |
| 1592 | LCD padding. |
| 1593 | |
Werner Lemberg | 6e5445a | 2017-05-15 21:24:04 +0200 | [diff] [blame] | 1594 | 2017-05-15 Werner Lemberg <wl@gnu.org> |
| 1595 | |
Werner Lemberg | 5efda13 | 2017-05-15 21:26:01 +0200 | [diff] [blame] | 1596 | [sfnt] Return proper scaling values for SBIX bitmaps. |
| 1597 | |
| 1598 | Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>. |
| 1599 | |
| 1600 | * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Implement it. |
| 1601 | |
| 1602 | 2017-05-15 Werner Lemberg <wl@gnu.org> |
| 1603 | |
Werner Lemberg | 6e5445a | 2017-05-15 21:24:04 +0200 | [diff] [blame] | 1604 | [truetype] Fix error handling for embedded bitmaps. |
| 1605 | |
| 1606 | Problem reported by Hin-Tak Leung <htl10@users.sourceforge.net>. |
| 1607 | |
| 1608 | * src/truetype/ttgload.c (TT_Load_Glyph) |
| 1609 | [TT_CONFIG_OPTION_EMBEDDED_BITMAPS]: Handle error if font is not |
| 1610 | scalable. |
| 1611 | |
Alexei Podtelezhnikov | a7f276a | 2017-05-15 00:25:37 -0400 | [diff] [blame] | 1612 | 2017-05-15 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 1613 | |
| 1614 | [autofit] Make autohint warping NORMAL option. |
| 1615 | |
| 1616 | This moves warping option from LIGHT to NORMAL mode. This makes LIGHT |
| 1617 | truly void of hinting in x-direction, with left side bearing never |
| 1618 | changed and right side bearing only altered by advance rounding. |
| 1619 | Therefore, LIGHT is now ready to return fractional advance. As a |
| 1620 | NORMAL option, warping substitutes normal hinting. |
| 1621 | |
| 1622 | * src/autofit/afcjk.c (af_cjk_hints_apply): Updated. |
| 1623 | * src/autofit/aflatin.c (af_latin_hints_apply): Updated. |
| 1624 | * src/autofit/aflatin2.c (af_latin2_hints_apply): Updated. |
| 1625 | |
| 1626 | * src/autofit/afloader.c (af_loader_load_glyph): Handle warping |
| 1627 | phantom points as normal. |
| 1628 | |
Werner Lemberg | e99b26a | 2017-05-14 21:57:27 +0200 | [diff] [blame] | 1629 | 2017-05-14 Werner Lemberg <wl@gnu.org> |
| 1630 | |
| 1631 | Remove remnants of raster pool. |
| 1632 | |
| 1633 | * include/freetype/internal/ftobjs.h (FT_LibraryRec): Remove |
| 1634 | `raster_pool' and `raster_pool_size' fields. |
| 1635 | |
| 1636 | * src/base/ftobjs.c (FT_New_Library), src/raster/ftrend1.c |
| 1637 | (ft_raster1_init), src/smooth/ftsmooth.c (ft_smooth_init): Updated. |
| 1638 | |
Werner Lemberg | a12a344 | 2017-05-13 06:29:04 +0200 | [diff] [blame] | 1639 | 2017-05-13 Werner Lemberg <wl@gnu.org> |
| 1640 | |
| 1641 | * Version 2.8 released. |
| 1642 | ======================= |
| 1643 | |
| 1644 | |
| 1645 | Tag sources with `VER-2-8'. |
| 1646 | |
| 1647 | * docs/VERSION.TXT: Add entry for version 2.8. |
| 1648 | * docs/CHANGES: Updated. |
| 1649 | |
| 1650 | * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj, |
| 1651 | builds/windows/vc2005/index.html, |
| 1652 | builds/windows/vc2008/freetype.vcproj, |
| 1653 | builds/windows/vc2008/index.html, |
| 1654 | builds/windows/vc2010/freetype.vcxproj, |
| 1655 | builds/windows/vc2010/index.html, |
| 1656 | builds/windows/visualc/freetype.dsp, |
| 1657 | builds/windows/visualc/freetype.vcproj, |
| 1658 | builds/windows/visualc/index.html, |
| 1659 | builds/windows/visualce/freetype.dsp, |
| 1660 | builds/windows/visualce/freetype.vcproj, |
| 1661 | builds/windows/visualce/index.html, |
| 1662 | builds/wince/vc2005-ce/freetype.vcproj, |
| 1663 | builds/wince/vc2005-ce/index.html, |
| 1664 | builds/wince/vc2008-ce/freetype.vcproj, |
| 1665 | builds/wince/vc2008-ce/index.html: s/2.7.1/2.8/, s/271/28/. |
| 1666 | |
| 1667 | * include/freetype/freetype.h (FREETYPE_MINOR): Set to 8. |
| 1668 | (FREETYPE_PATCH): Set to 0. |
| 1669 | |
| 1670 | * builds/unix/configure.raw (version_info): Set to 20:0:14. |
| 1671 | * CMakeLists.txt (VERSION_MINOR): Set to 8. |
| 1672 | (VERSION_PATCH): Set to 0. |
| 1673 | |
Hin-Tak Leung | 603121c | 2017-05-12 07:52:36 +0200 | [diff] [blame] | 1674 | 2017-05-12 Hin-Tak Leung <htl10@users.sourceforge.net> |
| 1675 | |
| 1676 | Fix `FT_UINT_TO_POINTER' macro for Windows. |
| 1677 | |
| 1678 | * builds/unix/ftconfig.in, builds/vms/ftconfig.h, |
| 1679 | include/freetype/config/ftconfig.h (FT_UINT_TO_POINTER) [_WIN64]: |
| 1680 | Fix definition. |
| 1681 | |
Sascha Brawer | ac0eed8 | 2017-05-11 00:06:37 +0200 | [diff] [blame] | 1682 | 2017-05-11 Sascha Brawer <sascha@google.com> |
| 1683 | Werner Lemberg <wl@gnu.org |
| 1684 | |
| 1685 | [autofit] Add support for Chakma script. |
| 1686 | |
| 1687 | * src/autofit/afblue.dat: Add blue zone data for Chakma. |
| 1688 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1689 | |
| 1690 | * src/autofit/afscript.h: Add Chakma standard character. |
| 1691 | |
| 1692 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Chakma data. |
| 1693 | |
Werner Lemberg | 53f3824 | 2017-05-10 09:13:20 +0200 | [diff] [blame] | 1694 | 2017-05-10 Sascha Brawer <sascha@google.com> |
| 1695 | Werner Lemberg <wl@gnu.org |
| 1696 | |
Sascha Brawer | d19859f | 2017-05-10 23:38:05 +0200 | [diff] [blame] | 1697 | [autofit] Add support for Kayah Li script. |
| 1698 | |
| 1699 | * src/autofit/afblue.dat: Add blue zone data for Kayah Li. |
| 1700 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1701 | |
| 1702 | * src/autofit/afscript.h: Add Kayah Li standard character. |
| 1703 | |
| 1704 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Kayah Li data. |
| 1705 | |
| 1706 | 2017-05-10 Sascha Brawer <sascha@google.com> |
| 1707 | Werner Lemberg <wl@gnu.org |
| 1708 | |
Sascha Brawer | 87218c9 | 2017-05-10 12:39:33 +0200 | [diff] [blame] | 1709 | [autofit] Add support for Bamum script. |
| 1710 | |
| 1711 | * src/autofit/afblue.dat: Add blue zone data for Bamum. |
| 1712 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1713 | |
| 1714 | * src/autofit/afscript.h: Add Bamum standard character. |
| 1715 | |
| 1716 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Bamum data. |
| 1717 | |
| 1718 | 2017-05-10 Sascha Brawer <sascha@google.com> |
| 1719 | Werner Lemberg <wl@gnu.org |
| 1720 | |
Sascha Brawer | 4aa1aec | 2017-05-10 09:36:13 +0200 | [diff] [blame] | 1721 | [autofit] Add support for Saurashtra script. |
| 1722 | |
| 1723 | * src/autofit/afblue.dat: Add blue zone data for Saurashtra. |
| 1724 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1725 | |
| 1726 | * src/autofit/afscript.h: Add Saurashtra standard character. |
| 1727 | |
| 1728 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Saurashtra |
| 1729 | data. |
| 1730 | |
| 1731 | 2017-05-10 Sascha Brawer <sascha@google.com> |
| 1732 | Werner Lemberg <wl@gnu.org |
| 1733 | |
Werner Lemberg | 53f3824 | 2017-05-10 09:13:20 +0200 | [diff] [blame] | 1734 | [autofit] Add support for Buhid script. |
| 1735 | |
| 1736 | * src/autofit/afblue.dat: Add blue zone data for Buhid. |
| 1737 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1738 | |
| 1739 | * src/autofit/afscript.h: Add Buhid standard character. |
| 1740 | |
| 1741 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Buhid data. |
| 1742 | |
Sascha Brawer | db0fe73 | 2017-05-08 10:00:16 +0200 | [diff] [blame] | 1743 | 2017-05-08 Sascha Brawer <sascha@google.com> |
| 1744 | Werner Lemberg <wl@gnu.org |
| 1745 | |
Sascha Brawer | 44c6117 | 2017-05-08 20:31:52 +0200 | [diff] [blame] | 1746 | [autofit] Add support for Shavian script. |
| 1747 | |
| 1748 | * src/autofit/afblue.dat: Add blue zone data for Shavian. |
| 1749 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1750 | |
| 1751 | * src/autofit/afscript.h: Add Shavian standard character. |
| 1752 | |
| 1753 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Shavian data. |
| 1754 | |
| 1755 | 2017-05-08 Sascha Brawer <sascha@google.com> |
| 1756 | Werner Lemberg <wl@gnu.org |
| 1757 | |
Sascha Brawer | a9e5e6e | 2017-05-08 19:57:16 +0200 | [diff] [blame] | 1758 | [autofit] Add support for Vai script. |
| 1759 | |
| 1760 | * src/autofit/afblue.dat: Add blue zone data for Vai. |
| 1761 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1762 | |
| 1763 | * src/autofit/afscript.h: Add Vai standard character. |
| 1764 | |
| 1765 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Vai data. |
| 1766 | |
| 1767 | 2017-05-08 Sascha Brawer <sascha@google.com> |
| 1768 | Werner Lemberg <wl@gnu.org |
| 1769 | |
Sascha Brawer | acc6b6d | 2017-05-08 15:08:46 +0200 | [diff] [blame] | 1770 | [autofit] Add support for Osmanya script. |
| 1771 | |
| 1772 | * src/autofit/afblue.dat: Add blue zone data for Osmanya. |
| 1773 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1774 | |
| 1775 | * src/autofit/afscript.h: Add Osmanya standard character. |
| 1776 | |
| 1777 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Osmanya data. |
| 1778 | |
| 1779 | 2017-05-08 Sascha Brawer <sascha@google.com> |
| 1780 | Werner Lemberg <wl@gnu.org |
| 1781 | |
Sascha Brawer | f27ebb1 | 2017-05-08 10:22:26 +0200 | [diff] [blame] | 1782 | [autofit] Add support for Coptic script. |
| 1783 | |
| 1784 | * src/autofit/afblue.dat: Add blue zone data for Coptic. |
| 1785 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1786 | |
| 1787 | * src/autofit/afscript.h: Add Coptic standard character. |
| 1788 | |
| 1789 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Coptic data. |
| 1790 | |
| 1791 | 2017-05-08 Sascha Brawer <sascha@google.com> |
| 1792 | Werner Lemberg <wl@gnu.org |
| 1793 | |
Sascha Brawer | db0fe73 | 2017-05-08 10:00:16 +0200 | [diff] [blame] | 1794 | [autofit] Add support for Carian script. |
| 1795 | |
| 1796 | * src/autofit/afblue.dat: Add blue zone data for Carian. |
| 1797 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1798 | |
| 1799 | * src/autofit/afscript.h: Add Carian standard character. |
| 1800 | |
| 1801 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Carian data. |
| 1802 | |
Werner Lemberg | ec4cb04 | 2017-05-07 13:06:36 +0200 | [diff] [blame] | 1803 | 2017-05-07 Werner Lemberg <wl@gnu.org> |
| 1804 | |
| 1805 | [truetype] Add tricky font `DFGirl-W6-WIN-BF' (from Dynalab). |
| 1806 | |
| 1807 | Reported by Roy Tam <roytam@gmail.com>. |
| 1808 | |
| 1809 | * src/truetype/ttobjs.c (tt_check_trickyness_family): Implement it. |
| 1810 | |
Roy Tam | 0ed9fef | 2017-05-07 08:32:58 +0200 | [diff] [blame] | 1811 | 2017-05-07 Roy Tam <roytam@gmail.com> |
| 1812 | Werner Lemberg <wl@gnu.org> |
| 1813 | |
| 1814 | [truetype] More tricky fonts (mainly from Dynalab). |
| 1815 | |
| 1816 | * src/truetype/ttobjs.c (tt_check_trickyness_family, |
| 1817 | tt_check_trickyness_sfnt_ids): Add them. |
| 1818 | |
Werner Lemberg | f784a56 | 2017-05-07 00:45:05 +0200 | [diff] [blame] | 1819 | 2017-05-07 Werner Lemberg <wl@gnu.org> |
| 1820 | |
| 1821 | [truetype] Add tricky font `DLCHayMedium' (from Dynalab). |
| 1822 | |
| 1823 | Reported by Roy Tam <roytam@gmail.com>. |
| 1824 | |
| 1825 | * src/truetype/ttobjs.c (tt_check_trickyness_family): Implement it. |
| 1826 | |
Werner Lemberg | 8cd31eb | 2017-05-03 23:54:29 +0200 | [diff] [blame] | 1827 | 2017-05-03 Werner Lemberg <wl@gnu.org> |
| 1828 | |
| 1829 | */*: s/backwards compatibility/backward compatibility/. |
| 1830 | |
Sascha Brawer | 14ae17a | 2017-05-03 18:35:13 +0200 | [diff] [blame] | 1831 | 2017-05-03 Sascha Brawer <sascha@google.com> |
Sascha Brawer | c9e7063 | 2017-05-03 23:21:13 +0200 | [diff] [blame] | 1832 | Werner Lemberg <wl@gnu.org |
| 1833 | |
| 1834 | [autofit] Add support for Unified Canadian Syllabics script. |
| 1835 | |
| 1836 | * src/autofit/afblue.dat: Add blue zone data for Unified Canadian |
| 1837 | Syllabics. |
| 1838 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1839 | |
| 1840 | * src/autofit/afscript.h: Add Unified Canadian Syllabics standard |
| 1841 | character. |
| 1842 | |
| 1843 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Unified |
| 1844 | Canadian Syllabics data. |
| 1845 | |
| 1846 | 2017-05-03 Sascha Brawer <sascha@google.com> |
Sascha Brawer | 0483fb3 | 2017-05-03 20:16:24 +0200 | [diff] [blame] | 1847 | Werner Lemberg <wl@gnu.org> |
| 1848 | |
| 1849 | [autofit] Add blue-zone support for Sundanese script. |
| 1850 | |
| 1851 | This essentially moves the Sundanese script from the `Indic' hinter |
| 1852 | to the `Latin' hinter. |
| 1853 | |
| 1854 | * src/autofit/afblue.dat: Add blue zone data for Sundanese. |
| 1855 | |
| 1856 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1857 | |
| 1858 | * src/autofit/afscript.h: Add Sundanese standard character and move |
| 1859 | data out of AF_CONFIG_OPTION_INDIC block. |
| 1860 | |
| 1861 | * src/autofit/afranges.c: Move Sundanese data out of |
| 1862 | AF_CONFIG_OPTION_INDIC block. |
| 1863 | |
| 1864 | * src/autofit/afstyles.h: Update Sundanese data; in particular, use |
| 1865 | AF_WRITING_SYSTEM_LATIN. |
| 1866 | |
| 1867 | 2017-05-03 Sascha Brawer <sascha@google.com> |
Sascha Brawer | 14ae17a | 2017-05-03 18:35:13 +0200 | [diff] [blame] | 1868 | Werner Lemberg <wl@gnu.org |
| 1869 | |
| 1870 | [autofit] Add support for Avestan script. |
| 1871 | |
| 1872 | * src/autofit/afblue.dat: Add blue zone data for Avestan. |
| 1873 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 1874 | |
| 1875 | * src/autofit/afscript.h: Add Avestan standard character. |
| 1876 | |
| 1877 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Avestan data. |
| 1878 | |
Behdad Esfahbod | 60bf264 | 2017-05-02 14:38:54 +0200 | [diff] [blame] | 1879 | 2017-05-02 Behdad Esfahbod <behdad@behdad.org> |
| 1880 | |
| 1881 | [truetype] Make `IUP' gvar deltas do the same as Apple (#50832). |
| 1882 | |
| 1883 | When points are not touched by gvar interpolation deltas, FreeType |
| 1884 | gave a slightly different result than Apple's CoreText. |
| 1885 | |
| 1886 | The OpenType working group will update the specification to document |
| 1887 | the following behaviour: If the two points with deltas to the `left' |
| 1888 | and `right' of the untouched point have the same coordinate, then |
| 1889 | the inferred delta for the untouched point should be zero. |
| 1890 | |
| 1891 | * src/truetype/ttgxvar.c (tt_delta_interpolate): Implement new |
| 1892 | behaviour. |
| 1893 | |
Werner Lemberg | ba40054 | 2017-05-02 12:32:19 +0200 | [diff] [blame] | 1894 | 2017-05-02 Werner Lemberg <wl@gnu.org> |
| 1895 | |
| 1896 | [autofit] Remove `slight' auto-hint mode again. |
| 1897 | |
| 1898 | A poll on freetype-devel favoured changes directly applied to |
| 1899 | `light'. |
| 1900 | |
| 1901 | * include/freetype/freetype.h (FT_LOAD_TARGET_SLIGHT, |
| 1902 | FT_RENDER_MODE_SLIGHT): Removed. |
| 1903 | |
| 1904 | * src/autofit/afcjk.c (af_cjk_hints_init), src/autofit/aflatin.c |
| 1905 | (af_latin_hints_init), src/autofit/aflatin2.c |
| 1906 | (af_latin2_hints_init): Revert change from 2017-04-22. |
| 1907 | |
| 1908 | * src/autofit/afloader.c (af_loader_load_glyph) Remove references to |
| 1909 | FT_RENDER_MODE_SLIGHT. |
| 1910 | [AF_CONFIG_OPTION_TT_SIZE_METRICS]: Enable TrueType-like metrics |
| 1911 | unconditionally. |
| 1912 | |
| 1913 | * src/base/ftadvanc.c (LOAD_ADVANCE_FAST_CHECK): Revert change from |
| 1914 | 2017-04-22. |
| 1915 | |
| 1916 | * src/base/ftobjs.c (FT_Load_Glyph): Revert change from 2017-04-22. |
| 1917 | |
| 1918 | * src/pshinter/pshalgo.c (ps_hints_apply): Revert change from |
| 1919 | 2017-04-22. |
| 1920 | |
| 1921 | * src/smooth/ftsmooth.c (ft_smooth_render): Revert change from |
| 1922 | 2017-04-22. |
| 1923 | |
| 1924 | * docs/CHANGES: Updated. |
| 1925 | |
Werner Lemberg | 7abf0cb | 2017-04-30 17:25:11 +0200 | [diff] [blame] | 1926 | 2017-04-30 Werner Lemberg <wl@gnu.org> |
| 1927 | |
| 1928 | [autofit] Fix metrics computation. |
| 1929 | |
| 1930 | Problem reported by Markus Trippelsdorf <markus@trippelsdorf.de> and |
| 1931 | Nikolaus Waxweiler <madigens@gmail.com>. |
| 1932 | |
| 1933 | * src/base/ftobjs.c (FT_Request_Size): Trigger recomputation of |
| 1934 | auto-hinter metrics. Without this change, multiple size changing |
| 1935 | calls for a single face fail. |
| 1936 | |
Werner Lemberg | 785833d | 2017-04-29 06:47:14 +0200 | [diff] [blame] | 1937 | 2017-04-29 Werner Lemberg <wl@gnu.org> |
| 1938 | |
| 1939 | * src/truetype/ttdriver.c (tt_size_request): Properly check `error'. |
| 1940 | |
| 1941 | Reported by Earnestly <zibeon@googlemail.com> in |
| 1942 | |
| 1943 | http://lists.nongnu.org/archive/html/freetype/2017-04/msg00031.html |
| 1944 | |
Werner Lemberg | 0a5315d | 2017-04-27 13:02:24 +0200 | [diff] [blame] | 1945 | 2017-04-27 Werner Lemberg <wl@gnu.org> |
| 1946 | |
| 1947 | Introduce AF_CONFIG_OPTION_TT_SIZE_METRICS configuration option. |
| 1948 | |
| 1949 | * include/freetype/config/ftoption.h |
| 1950 | (AF_CONFIG_OPTION_TT_SIZE_METRICS): New option, commented out by |
| 1951 | default. |
| 1952 | |
| 1953 | * src/autofit/afloader.c (af_loader_load_glyph): Use |
| 1954 | AF_CONFIG_OPTION_TT_SIZE_METRICS to guard the corresponding code. |
| 1955 | |
Werner Lemberg | ab10ffc | 2017-04-26 13:41:40 +0200 | [diff] [blame] | 1956 | 2017-04-26 Werner Lemberg <wl@gnu.org> |
| 1957 | |
| 1958 | * include/freetype/freetype.h (FT_Render_Mode): Fix order. |
| 1959 | |
Werner Lemberg | 8cd31eb | 2017-05-03 23:54:29 +0200 | [diff] [blame] | 1960 | This retains backward compatibility. |
Werner Lemberg | ab10ffc | 2017-04-26 13:41:40 +0200 | [diff] [blame] | 1961 | |
| 1962 | Noted by Alexei. |
| 1963 | |
Werner Lemberg | 5412d88 | 2017-04-22 12:48:50 +0200 | [diff] [blame] | 1964 | 2017-04-22 Werner Lemberg <wl@gnu.org> |
| 1965 | |
Werner Lemberg | 5f18d86 | 2017-04-22 23:02:21 +0200 | [diff] [blame] | 1966 | [truetype] Do linear scaling for FT_LOAD_NO_HINTING (#50470). |
| 1967 | |
Alexei Podtelezhnikov | c28e9c9 | 2017-09-15 22:23:01 -0400 | [diff] [blame] | 1968 | * src/truetype/ttobjs.h (TT_SizeRec): Add field `hinted_metrics' to |
Werner Lemberg | 5f18d86 | 2017-04-22 23:02:21 +0200 | [diff] [blame] | 1969 | hold hinted metrics. |
| 1970 | Make `metrics' a pointer so that `tt_glyph_load' can easily switch |
| 1971 | between metrics. |
| 1972 | |
| 1973 | * src/truetype/ttdriver.c (tt_size_request): Updated. |
| 1974 | (tt_glyph_load): Use top-level metrics if FT_LOAD_NO_HINTING is |
| 1975 | used. |
| 1976 | |
| 1977 | * src/truetype/ttgload.c (TT_Hint_Glyph, TT_Process_Simple_Glyph, |
| 1978 | TT_Process_Composite_Component, load_truetype_glyph, |
| 1979 | compute_glyph_metrics, TT_Load_Glyph): Updated. |
| 1980 | |
| 1981 | * src/truetype/ttinterp.c (TT_Load_Context): Updated. |
| 1982 | |
| 1983 | * src/truetype/ttobjs.c (tt_size_reset): Updated. |
| 1984 | |
| 1985 | * src/truetype/ttsubpix.c (sph_set_tweaks): Updated. |
| 1986 | |
| 1987 | 2017-04-22 Werner Lemberg <wl@gnu.org> |
| 1988 | |
Werner Lemberg | 5aa6716 | 2017-04-22 13:27:21 +0200 | [diff] [blame] | 1989 | Add new `slight' auto-hinting mode. |
| 1990 | |
| 1991 | This mode uses fractional advance widths and doesn't scale glyphs |
| 1992 | horizontally, only applying vertical scaling and hinting. |
| 1993 | |
| 1994 | At the same time, the behaviour of the `light' auto-hinter gets |
Werner Lemberg | 8cd31eb | 2017-05-03 23:54:29 +0200 | [diff] [blame] | 1995 | restored for backward compatibility: Both vertical and horizontal |
Werner Lemberg | 5aa6716 | 2017-04-22 13:27:21 +0200 | [diff] [blame] | 1996 | scaling is again based on rounded metrics values (this was changed |
| 1997 | in a commit from 2017-03-30 as a side effect). To be more precise, |
| 1998 | the behaviour is restored for TrueType fonts only; for other font |
| 1999 | formats like Type 1, this is a new feature of the `light' hinting |
| 2000 | mode. |
| 2001 | |
| 2002 | * include/freetype/freetype.h (FT_LOAD_TARGET_SLIGHT): New macro. |
| 2003 | (FT_RENDER_MODE_SLIGHT): New render mode. |
| 2004 | |
| 2005 | * include/freetype/internal/ftobjs.h (FT_Size_InternalRec): Add |
| 2006 | `autohint_mode' and `autohint_metrics' fields. |
| 2007 | |
| 2008 | * src/autofit/afcjk.c (af_cjk_hints_init), src/autofit/aflatin.c |
| 2009 | (af_latin_hints_init), src/autofit/aflatin2 (af_latin2_hints_init): |
| 2010 | Updated. |
| 2011 | |
| 2012 | * src/autofit/afloader.c (af_loader_embolden_glyph_in_slot): Use |
| 2013 | `autohint_metrics'. |
| 2014 | (af_loader_load_glyph): s/internal/slot_internal/. |
| 2015 | Initialize `autohint_metrics' and `autohint_mode' depending on |
| 2016 | current auto-hint mode. |
| 2017 | Use `autohint_metrics'. |
| 2018 | Updated. |
| 2019 | |
| 2020 | * src/base/ftadvanc.c (LOAD_ADVANCE_FAST_CHECK): Updated. |
| 2021 | |
| 2022 | * src/base/ftobjs.c (FT_Load_Glyph): Updated. |
| 2023 | (FT_New_Size): Allocate `internal' object. |
| 2024 | |
| 2025 | * src/pshinter/pshalgo.c (ps_hints_apply): Updated. |
| 2026 | |
| 2027 | * src/smooth/ftsmooth.c (ft_smooth_render): Updated. |
| 2028 | |
| 2029 | 2017-04-22 Werner Lemberg <wl@gnu.org> |
| 2030 | |
Werner Lemberg | 5412d88 | 2017-04-22 12:48:50 +0200 | [diff] [blame] | 2031 | Introduce `FT_Size_InternalRec' structure. |
| 2032 | |
| 2033 | We are going to extend this later on. |
| 2034 | |
| 2035 | * include/freetype/internal/ftobjs.h (FT_Size_InternalRec): New |
| 2036 | structure with a single field `module_data'. |
| 2037 | |
| 2038 | * src/base/ftobjs.c (FT_New_Size): Allocate `internal' field of |
| 2039 | `FT_Size' structure. |
| 2040 | |
| 2041 | * src/cff/cffgload.c (cff_builder_init, cff_decoder_prepare): Use |
| 2042 | `size->internal->module_data' instead of `size->internal'. |
| 2043 | |
| 2044 | * src/cff/cffobjs.c (cff_size_done): Deallocate `module_data'. |
| 2045 | (cff_size_init, cff_size_select, cff_size_request): Use |
| 2046 | `size->internal->module_data' instead of `size->internal'. |
| 2047 | |
| 2048 | * src/cif/cidobjs.c (cid_size_done, cid_size_init, |
| 2049 | cid_size_request): Use `size->internal->module_data' instead of |
| 2050 | `size->internal'. |
| 2051 | |
| 2052 | * src/psaux/psobjs.c (t1_builder_ini): Use |
| 2053 | `size->internal->module_data' instead of `size->internal'. |
| 2054 | |
| 2055 | * src/type1/t1objs.c (T1_Size_Done, T1_Size_Init, T1_Size_Request): |
| 2056 | Use `size->internal->module_data' instead of `size->internal'. |
| 2057 | |
Alexei Podtelezhnikov | eb5e0fb | 2017-04-21 22:53:39 -0400 | [diff] [blame] | 2058 | 2017-04-21 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 2059 | |
| 2060 | * src/smooth/ftsmooth.h: Remove unused guards and declaration. |
| 2061 | |
Hin-Tak Leung | 5efba4c | 2017-04-16 07:23:24 +0200 | [diff] [blame] | 2062 | 2017-04-16 Hin-Tak Leung <htl10@users.sourceforge.net> |
| 2063 | |
| 2064 | Fix tracing messages. |
| 2065 | |
| 2066 | * src/base/ftobjs.c (FT_Face_GetCharVariantIndex, |
| 2067 | FT_Face_GetCharVariantIsDefault, FT_Face_GetVariantsOfChar): Print |
| 2068 | correct function name. |
| 2069 | |
Sascha Brawer | d79fc79 | 2017-04-08 07:06:24 +0200 | [diff] [blame] | 2070 | 2017-04-08 Sascha Brawer <sascha@google.com> |
| 2071 | Werner Lemberg <wl@gnu.org |
| 2072 | |
Werner Lemberg | 90ccab3 | 2017-04-08 17:58:57 +0200 | [diff] [blame] | 2073 | [autofit] Add support for Old Turkic script. |
| 2074 | |
| 2075 | * src/autofit/afblue.dat: Add blue zone data for Old Turkic. |
| 2076 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2077 | |
| 2078 | * src/autofit/afscript.h: Add Old Turkic standard characters. |
| 2079 | |
| 2080 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Old Turkic data. |
| 2081 | |
| 2082 | 2017-04-08 Sascha Brawer <sascha@google.com> |
| 2083 | Werner Lemberg <wl@gnu.org |
| 2084 | |
Sascha Brawer | df2a7cd | 2017-04-08 16:11:44 +0200 | [diff] [blame] | 2085 | [autofit] Add support for Gothic script. |
| 2086 | |
| 2087 | * src/autofit/afblue.dat: Add blue zone data for Gothic. |
| 2088 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2089 | |
| 2090 | * src/autofit/afscript.h: Add Gothic standard characters. |
| 2091 | |
| 2092 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Gothic data. |
| 2093 | |
| 2094 | 2017-04-08 Sascha Brawer <sascha@google.com> |
| 2095 | Werner Lemberg <wl@gnu.org |
| 2096 | |
Sascha Brawer | 5bf4b1a | 2017-04-08 11:38:52 +0200 | [diff] [blame] | 2097 | [autofit] Add support for Cypriot script. |
| 2098 | |
| 2099 | * src/autofit/afblue.dat: Add blue zone data for Cypriot. |
| 2100 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2101 | |
| 2102 | * src/autofit/afscript.h: Add Cypriot standard characters. |
| 2103 | |
| 2104 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Cypriot data. |
| 2105 | |
| 2106 | 2017-04-08 Sascha Brawer <sascha@google.com> |
| 2107 | Werner Lemberg <wl@gnu.org |
| 2108 | |
Sascha Brawer | d79fc79 | 2017-04-08 07:06:24 +0200 | [diff] [blame] | 2109 | [autofit] Add support for Deseret script. |
| 2110 | |
| 2111 | * src/autofit/afblue.dat: Add blue zone data for Deseret. |
| 2112 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2113 | |
| 2114 | * src/autofit/afscript.h: Add Deseret standard characters. |
| 2115 | |
| 2116 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Deseret data. |
| 2117 | |
Werner Lemberg | 04e00b8 | 2017-04-07 17:13:38 +0200 | [diff] [blame] | 2118 | 2017-04-07 Werner Lemberg <wl@gnu.org> |
| 2119 | |
Werner Lemberg | 32efd8c | 2017-04-07 17:22:59 +0200 | [diff] [blame] | 2120 | [autofit] Fix invalid character range description (#50745). |
| 2121 | |
| 2122 | Also reported as |
| 2123 | |
| 2124 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=1034 |
| 2125 | |
| 2126 | * src/autofit/afranges.c (af_glag_nonbase_uniranges): Fix typo in |
| 2127 | recent commit. |
| 2128 | |
| 2129 | 2017-04-07 Werner Lemberg <wl@gnu.org> |
| 2130 | |
Werner Lemberg | 04e00b8 | 2017-04-07 17:13:38 +0200 | [diff] [blame] | 2131 | [ftfuzzer] Fix clang warnings. |
| 2132 | |
| 2133 | * src/tools/ftfuzzer/ftfuzzer.cc (LLVMFuzzerTestOneInput): Add |
| 2134 | casts. |
| 2135 | |
Sascha Brawer | 8210ee4 | 2017-04-06 05:39:51 +0200 | [diff] [blame] | 2136 | 2017-04-06 Sascha Brawer <sascha@google.com> |
Sascha Brawer | 134246b | 2017-04-06 07:06:32 +0200 | [diff] [blame] | 2137 | Werner Lemberg <wl@gnu.org |
| 2138 | |
Sascha Brawer | 2c256e6 | 2017-04-06 17:05:47 +0200 | [diff] [blame] | 2139 | [autofit] Add support for Lisu script. |
| 2140 | |
| 2141 | * src/autofit/afblue.dat: Add blue zone data for Lisu. |
| 2142 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2143 | |
| 2144 | * src/autofit/afscript.h: Add Lisu standard characters. |
| 2145 | |
| 2146 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Lisu data. |
| 2147 | |
| 2148 | 2017-04-06 Sascha Brawer <sascha@google.com> |
| 2149 | Werner Lemberg <wl@gnu.org |
| 2150 | |
Sascha Brawer | 2b91147 | 2017-04-06 16:49:39 +0200 | [diff] [blame] | 2151 | [autofit] Add support for Osage script. |
| 2152 | |
| 2153 | * src/autofit/afblue.dat: Add blue zone data for Osage. |
| 2154 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2155 | |
| 2156 | * src/autofit/afscript.h: Add Osage standard characters. |
| 2157 | |
| 2158 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Osage data. |
| 2159 | |
| 2160 | 2017-04-06 Sascha Brawer <sascha@google.com> |
| 2161 | Werner Lemberg <wl@gnu.org |
| 2162 | |
Sascha Brawer | 628e285 | 2017-04-06 12:47:27 +0200 | [diff] [blame] | 2163 | [autofit] Add support for Glagolitic script. |
| 2164 | |
| 2165 | * src/autofit/afblue.dat: Add blue zone data for Glagolitic. |
| 2166 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2167 | |
| 2168 | * src/autofit/afscript.h: Add Glagolitic standard characters. |
| 2169 | |
| 2170 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Glagolitic data. |
| 2171 | |
| 2172 | 2017-04-06 Sascha Brawer <sascha@google.com> |
| 2173 | Werner Lemberg <wl@gnu.org |
| 2174 | |
Sascha Brawer | 6967eb9 | 2017-04-06 11:35:07 +0200 | [diff] [blame] | 2175 | [autofit] Add support for Tai Viet script. |
| 2176 | |
| 2177 | * src/autofit/afblue.dat: Add blue zone data for Tai Viet. |
| 2178 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2179 | |
| 2180 | * src/autofit/afscript.h: Add Tai Viet standard characters. |
| 2181 | |
| 2182 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Tai Viet data. |
| 2183 | |
| 2184 | 2017-04-06 Sascha Brawer <sascha@google.com> |
| 2185 | Werner Lemberg <wl@gnu.org |
| 2186 | |
Sascha Brawer | 837f112 | 2017-04-06 08:44:08 +0200 | [diff] [blame] | 2187 | [autofit] Add support for Tifinagh script. |
| 2188 | |
| 2189 | * src/autofit/afblue.dat: Add blue zone data for Tifinagh. |
| 2190 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2191 | |
| 2192 | * src/autofit/afscript.h: Add Tifinagh standard characters. |
| 2193 | |
| 2194 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Tifinagh data. |
| 2195 | |
| 2196 | 2017-04-06 Sascha Brawer <sascha@google.com> |
| 2197 | Werner Lemberg <wl@gnu.org |
| 2198 | |
Sascha Brawer | 134246b | 2017-04-06 07:06:32 +0200 | [diff] [blame] | 2199 | [autofit] Add support for N'Ko script. |
| 2200 | |
| 2201 | * src/autofit/afblue.dat: Add blue zone data for N'Ko. |
| 2202 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2203 | |
| 2204 | * src/autofit/afscript.h: Add N'Ko standard characters. |
| 2205 | |
| 2206 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add N'Ko data. |
| 2207 | |
| 2208 | 2017-04-06 Sascha Brawer <sascha@google.com> |
Sascha Brawer | 8210ee4 | 2017-04-06 05:39:51 +0200 | [diff] [blame] | 2209 | |
Sascha Brawer | ba9cee4 | 2017-04-06 05:50:44 +0200 | [diff] [blame] | 2210 | [autofit] Add support for Adlam script. |
| 2211 | |
| 2212 | * src/autofit/afblue.dat: Add blue zone data for Adlam. |
| 2213 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2214 | |
| 2215 | * src/autofit/afscript.h: Add Adlam standard characters. |
| 2216 | |
| 2217 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Adlam data. |
| 2218 | |
| 2219 | 2017-04-06 Sascha Brawer <sascha@google.com> |
| 2220 | |
Sascha Brawer | 8210ee4 | 2017-04-06 05:39:51 +0200 | [diff] [blame] | 2221 | [autofit] Add support for Ol Chiki script. |
| 2222 | |
| 2223 | * src/autofit/afblue.dat: Add blue zone data for Ol Chiki. |
| 2224 | * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated. |
| 2225 | |
| 2226 | * src/autofit/afscript.h: Add Ol Chiki standard character. |
| 2227 | |
| 2228 | * src/autofit/afranges.c, src/autofit/afstyles.h: Add Ol Chiki data. |
| 2229 | |
Werner Lemberg | 093c182 | 2017-04-03 11:37:33 +0200 | [diff] [blame] | 2230 | 2017-04-03 Werner Lemberg <wl@gnu.org> |
| 2231 | |
| 2232 | [truetype] Avoid reexecution of `fpgm' and `prep' in case of error. |
| 2233 | |
| 2234 | Reported as |
| 2235 | |
| 2236 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=981 |
| 2237 | |
| 2238 | * include/freetype/fterrdef.h (FT_Err_DEF_In_Glyf_Bytecode): New |
| 2239 | error code. |
| 2240 | |
| 2241 | * src/truetype/ttinterp.c (Ins_FDEF, Ins_IDEF): Prohibit execution |
| 2242 | of these two opcodes in `glyf' bytecode. |
| 2243 | (TT_RunIns): Don't enforce reexecution of `fpgm' and `prep' bytecode |
| 2244 | in case of error since function tables can no longer be modified |
| 2245 | (due to the changes in `Ins_FDEF' and `Ins_IDEF'). This change can |
| 2246 | enormously speed up handling of broken fonts. |
| 2247 | |
Alexei Podtelezhnikov | e7b0130 | 2017-04-02 22:01:47 -0400 | [diff] [blame] | 2248 | 2017-04-02 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 2249 | |
| 2250 | [autofit] Disable metrics adjustment for `FT_LOAD_TARGET_LCD'. |
| 2251 | |
| 2252 | * src/autofit/aflatin.c (af_latin_hints_init): Updated. |
| 2253 | * src/autofit/aflatin2.c (af_latin2_hints_init): Ditto. |
| 2254 | |
Werner Lemberg | bb6c037 | 2017-04-01 09:49:11 +0200 | [diff] [blame] | 2255 | 2017-04-01 Werner Lemberg <wl@gnu.org> |
| 2256 | |
| 2257 | * src/truetype/ttgload.c: Include FT_CONFIG_CONFIG_H. |
| 2258 | |
| 2259 | Otherwise FT_UINT_TO_POINTER might not be defined. |
| 2260 | |
| 2261 | Problem reported by Alexei. |
| 2262 | |
Alexei Podtelezhnikov | 54b5809 | 2017-03-31 22:41:53 -0400 | [diff] [blame] | 2263 | 2017-03-31 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 2264 | |
| 2265 | [autofit] Disable stem adjustment for `FT_LOAD_TARGET_LCD'. |
| 2266 | |
| 2267 | * include/freetype/freetype.h (FT_LOAD_TARGET_LCD): Document it. |
| 2268 | * src/autofit/afcjk.c (af_cjk_hints_init): Updated. |
| 2269 | * src/autofit/aflatin.c (af_latin_hints_init): Ditto. |
| 2270 | * src/autofit/aflatin2.c (af_latin2_hints_init): Ditto. |
| 2271 | |
Werner Lemberg | 5a3490e | 2017-03-31 09:35:58 +0200 | [diff] [blame] | 2272 | 2017-03-31 Werner Lemberg <wl@gnu.org> |
| 2273 | |
| 2274 | * src/cff/cffload.c (cff_font_load): Improve fix from 2017-01-04. |
| 2275 | |
| 2276 | Allow CFFs containing a single font to have an empty font name. |
| 2277 | |
| 2278 | Problem reported by 張俊芝 <418092625@qq.com> in |
| 2279 | |
| 2280 | http://lists.nongnu.org/archive/html/freetype-devel/2017-03/msg00074.html |
| 2281 | |
Werner Lemberg | bcc74f4 | 2017-03-30 13:14:43 +0200 | [diff] [blame] | 2282 | 2017-03-30 Werner Lemberg <wl@gnu.org> |
| 2283 | |
Werner Lemberg | c8c6763 | 2017-03-30 21:07:17 +0200 | [diff] [blame] | 2284 | * src/cff/cffparse.h (CFF2_DEFAULT_STACK): Set to 513 also. |
| 2285 | |
| 2286 | Requested by Dave Arnold. |
| 2287 | |
| 2288 | 2017-03-30 Werner Lemberg <wl@gnu.org> |
| 2289 | |
Werner Lemberg | da38be8 | 2017-03-30 13:24:03 +0200 | [diff] [blame] | 2290 | [truetype] Fix HVAR and VVAR handling (#50678). |
| 2291 | |
| 2292 | * src/truetype/ttgxvar.c (tt_hvadvance_adjust): Handle |
| 2293 | glyph indices larger than `mapCount' as described in the |
| 2294 | specification. |
| 2295 | |
| 2296 | 2017-03-30 Werner Lemberg <wl@gnu.org> |
| 2297 | |
Werner Lemberg | bcc74f4 | 2017-03-30 13:14:43 +0200 | [diff] [blame] | 2298 | [truetype] Allow linear scaling for unhinted rendering (#50470). |
| 2299 | |
| 2300 | * src/truetype/ttdriver.c (tt_size_request): Revert change from |
| 2301 | 2011-07-16; the intended metrics fix seems now to be implemented in |
| 2302 | a different way, making the patch unnecessary. Note that this |
| 2303 | change was usually patched out by all major GNU/Linux distributions |
| 2304 | due to heavy side effects. |
| 2305 | |
| 2306 | * src/truetype/ttgload.c (compute_glyph_metrics, TT_Load_Glyph): |
| 2307 | Refer to the metrics of the `TT_Size' object. |
| 2308 | |
Werner Lemberg | 1ede367 | 2017-03-30 00:26:31 +0200 | [diff] [blame] | 2309 | 2017-03-29 Werner Lemberg <wl@gnu.org> |
| 2310 | |
| 2311 | [truetype] Fix thinko related to PS name of default named instance. |
| 2312 | |
| 2313 | * src/truetype/ttgxvar.c (TT_Get_MM_Var): `strid' and `psid' are |
| 2314 | name ID values, not indices into the array of name entries. |
| 2315 | |
Werner Lemberg | 208e712 | 2017-03-27 20:56:23 +0200 | [diff] [blame] | 2316 | 2017-03-27 Werner Lemberg <wl@gnu.org> |
| 2317 | |
| 2318 | [cid, truetype] Don't use `index' as a variable name. |
| 2319 | |
| 2320 | At least on FreeBSD there is a global declaration of `index' in file |
| 2321 | `/usr/include/strings.h'. |
| 2322 | |
| 2323 | * src/cff/cf2intrp.c, src/truetype/ttgload.c: s/index/idx/ where |
| 2324 | appropriate. |
| 2325 | |
Wojciech Mamrak | 565f5a7 | 2017-03-27 09:19:14 +0200 | [diff] [blame] | 2326 | 2017-03-27 Wojciech Mamrak <wmamrak@gmail.com> |
| 2327 | |
| 2328 | [sfnt] Minor improvement for handling kern tables. |
| 2329 | |
| 2330 | * src/sfnt/ttkern.c (tt_face_load_kern): Don't check for |
| 2331 | cross-stream kerning tables since we reject format 2 tables later |
| 2332 | on anyways. |
| 2333 | Modify code for limit test... |
| 2334 | (tt_face_get_kerning): ... to avoid a limit test here. |
| 2335 | |
Werner Lemberg | c22a9aa | 2017-03-27 07:57:24 +0200 | [diff] [blame] | 2336 | 2017-03-27 Werner Lemberg <wl@gnu.org> |
| 2337 | |
| 2338 | [pcf] Fix compiler warnings. |
| 2339 | |
| 2340 | Reported by Alexander Hedges <ahedges@student.ethz.ch>. |
| 2341 | |
| 2342 | * src/pcf/pcfdrivr.c (pcf_property_set, pcf_property_get): Tag |
| 2343 | `property_name' with `FT_UNUSED' where necessary. |
| 2344 | |
Werner Lemberg | 3774fc0 | 2017-03-26 08:32:09 +0200 | [diff] [blame] | 2345 | 2017-03-26 Werner Lemberg <wl@gnu.org> |
| 2346 | |
| 2347 | * src/psaux/psobjs.c (t1_builder_close_contour): Add safety guard. |
| 2348 | |
| 2349 | Reported as |
| 2350 | |
| 2351 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=941 |
| 2352 | |
Werner Lemberg | 67ff766 | 2017-03-23 12:41:30 +0100 | [diff] [blame] | 2353 | 2017-03-23 Werner Lemberg <wl@gnu.org> |
| 2354 | |
Werner Lemberg | f958c48 | 2017-03-24 09:15:10 +0100 | [diff] [blame] | 2355 | [psaux] Better protect `flex' handling. |
| 2356 | |
| 2357 | Reported as |
| 2358 | |
| 2359 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=935 |
| 2360 | |
| 2361 | * src/psaux/t1decode.c (t1_decoder_parse_charstrings) |
| 2362 | <callothersubr>: Since there is not a single flex operator but a |
| 2363 | series of subroutine calls, malformed fonts can call arbitrary other |
| 2364 | operators after the start of a flex, possibly adding points. For |
| 2365 | this reason we have to check the available number of points before |
| 2366 | inserting a point. |
| 2367 | |
| 2368 | 2017-03-23 Werner Lemberg <wl@gnu.org> |
| 2369 | |
Werner Lemberg | 913f436 | 2017-03-23 18:37:06 +0100 | [diff] [blame] | 2370 | [sfnt] Fix check for default named instance. |
| 2371 | |
| 2372 | * src/sfnt/sfobjs.c (sfnt_init_face): A `fixed' number needs four |
| 2373 | bytes, not two... |
| 2374 | |
| 2375 | 2017-03-23 Werner Lemberg <wl@gnu.org> |
| 2376 | |
Werner Lemberg | 67ff766 | 2017-03-23 12:41:30 +0100 | [diff] [blame] | 2377 | Make MM fonts work (again). |
| 2378 | |
| 2379 | * src/base/ftmm.c (FT_Set_Var_Design_Coordinates, |
| 2380 | FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates): Ignore |
| 2381 | return value of `ft_face_get_mvar_service'; instead, check whether a |
| 2382 | service is actually returned. |
| 2383 | |
Werner Lemberg | dd64a62 | 2017-03-20 05:34:02 +0100 | [diff] [blame] | 2384 | 2017-03-20 Werner Lemberg <wl@gnu.org> |
| 2385 | |
Werner Lemberg | 683e3ad | 2017-03-21 19:49:11 +0100 | [diff] [blame] | 2386 | [truetype] Some variable renamings. |
| 2387 | |
| 2388 | Too much local variables holding different structures were called |
| 2389 | `metrics'. |
| 2390 | |
| 2391 | * src/truetype/ttdriver.c (tt_size_select): s/metrics/size_metrics/. |
| 2392 | |
Alexei Podtelezhnikov | 71d289d | 2017-04-19 23:50:29 -0400 | [diff] [blame] | 2393 | * src/truetype/ttgload.c (tt_get_metrics_incr_overrides, |
Werner Lemberg | 683e3ad | 2017-03-21 19:49:11 +0100 | [diff] [blame] | 2394 | compute_glyph_metrics): s/metrics/incr_metrics/. |
| 2395 | (load_sbit_image): s/metrics/sbit_metrics/. |
| 2396 | |
| 2397 | * src/truetype/ttobjs.c (tt_size_run_fpgm): s/metrics/size_metrics/. |
| 2398 | (tt_size_init_bytecode): s/metrics/tt_metrics/. |
| 2399 | (tt_size_reset): s/metrics/size_metrics/. |
| 2400 | |
| 2401 | 2017-03-20 Werner Lemberg <wl@gnu.org> |
| 2402 | |
Werner Lemberg | 6342da9 | 2017-03-20 05:36:41 +0100 | [diff] [blame] | 2403 | [sfnt] Don't add instances to non-variation fonts. |
| 2404 | |
| 2405 | * src/sfnt/sfobjs.c (sfnt_init_face): Fix it. |
| 2406 | |
| 2407 | 2017-03-20 Werner Lemberg <wl@gnu.org> |
| 2408 | |
Werner Lemberg | dd64a62 | 2017-03-20 05:34:02 +0100 | [diff] [blame] | 2409 | * src/cff/cffgload.c (cff_builder_init): Add safety guard (#50578). |
| 2410 | |
Werner Lemberg | ab840e6 | 2017-03-18 08:50:42 +0100 | [diff] [blame] | 2411 | 2017-03-18 Werner Lemberg <wl@gnu.org> |
| 2412 | |
Werner Lemberg | 7aeee3c | 2017-03-18 17:30:42 +0100 | [diff] [blame] | 2413 | Introduce FT_UINT_TO_POINTER macro (#50560). |
| 2414 | |
| 2415 | We have to make a separate case for Windows 64's LLP64 data model. |
| 2416 | |
| 2417 | * builds/unix/ftconfig.in, builds/vms/ftconfig.h, |
| 2418 | include/freetype/config/ftconfig.h (FT_UINT_TO_POINTER): New macro. |
| 2419 | |
| 2420 | * src/truetype/ttgload.c (load_truetype_glyph): Use it. |
| 2421 | |
| 2422 | 2017-03-18 Werner Lemberg <wl@gnu.org> |
| 2423 | |
Werner Lemberg | 3e79254 | 2017-03-18 10:06:15 +0100 | [diff] [blame] | 2424 | * src/truetype/ttinterp.c (TT_RunIns): Adjust loop counter (#50573). |
| 2425 | |
| 2426 | The problematic font that exceeds the old limit is Lato-Regular, |
| 2427 | version 2.007, containing bytecode generated by a buggy version of |
| 2428 | ttfautohint. |
| 2429 | |
| 2430 | 2017-03-18 Werner Lemberg <wl@gnu.org> |
| 2431 | |
Werner Lemberg | 13fa85a | 2017-03-18 09:42:58 +0100 | [diff] [blame] | 2432 | [truetype] Another limitation for bytecode loop count maximum. |
| 2433 | |
| 2434 | Reported as |
| 2435 | |
| 2436 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=900 |
| 2437 | |
| 2438 | * src/truetype/ttinterp.c (TT_RunIns): Limit `loopcall_counter_max' |
| 2439 | by number of glyphs also. |
| 2440 | |
| 2441 | 2017-03-18 Werner Lemberg <wl@gnu.org> |
| 2442 | |
Werner Lemberg | ab840e6 | 2017-03-18 08:50:42 +0100 | [diff] [blame] | 2443 | [ftfuzzer] Minor improvement. |
| 2444 | |
| 2445 | * src/tools/ftfuzzer/ftfuzzer.cc: Don't set intermediate axis if |
| 2446 | bitmap strikes are active. |
| 2447 | |
| 2448 | 2017-03-18 Werner Lemberg <wl@gnu.org> |
Werner Lemberg | bffb7fe | 2017-03-17 07:52:30 +0100 | [diff] [blame] | 2449 | |
Werner Lemberg | 9931175 | 2017-03-18 07:06:49 +0100 | [diff] [blame] | 2450 | Improve `make multi'. |
| 2451 | |
| 2452 | * src/autofit/aflatin2.c: Guard file with FT_OPTION_AUTOFIT2. |
| 2453 | |
| 2454 | * src/base/ftmac.c: Guard more parts of the file with FT_MACINTOSH. |
| 2455 | |
| 2456 | * src/psaux/afmparse.c: Guard file with T1_CONFIG_OPTION_NO_AFM. |
| 2457 | |
| 2458 | * src/sfnt/pngshim.c: Guard file with |
| 2459 | TT_CONFIG_OPTION_EMBEDDED_BITMAPS also. |
| 2460 | |
| 2461 | * src/sfnt/ttbdf.c: Avoid empty source file. |
| 2462 | * src/sfnt/ttpost.c: Guard file with |
| 2463 | TT_CONFIG_OPTION_POSTSCRIPT_NAMES. |
| 2464 | * src/sfnt/ttsbit.c: Guard file with |
| 2465 | TT_CONFIG_OPTION_EMBEDDED_BITMAPS. |
| 2466 | |
| 2467 | * src/truetype/ttgxvar.c, src/truetype/ttinterp.c: Avoid empty |
| 2468 | source file. |
| 2469 | |
| 2470 | * src/truetype/ttsubpix.c: Guard file with |
| 2471 | TT_USE_BYTECODE_INTERPRETER also. |
| 2472 | |
| 2473 | * src/type1/t1afm.c: Guard file with T1_CONFIG_OPTION_NO_AFM. |
| 2474 | |
| 2475 | * src/autofit/autofit.c, src/base/ftbase.c, src/cache/ftcache.c, |
| 2476 | src/cff/cff.c, src/cid/type1cid.c, src/gxvalid/gxvalid.c, |
| 2477 | src/pcf/pcf.c, src/pfr/pfr.c, src/psaux/psaux.c, |
| 2478 | src/pshinter/pshinter.c, src/psnames/psnames.c, src/raster/raster.c, |
| 2479 | src/sfnt/sfnt.c, src/smooth/smooth.c, src/truetype/truetype.c, |
| 2480 | src/type1/type1.c, src/type42/type42.c: Remove conditionals; sort |
| 2481 | entries. |
| 2482 | |
| 2483 | 2017-03-17 Werner Lemberg <wl@gnu.org> |
| 2484 | |
Werner Lemberg | d5bfa05 | 2017-03-17 21:47:54 +0100 | [diff] [blame] | 2485 | Fixes for conditional compilation. |
| 2486 | |
| 2487 | * src/autofit/afcjk.c, src/autofit/afindic.c: Include `afcjk.h' |
| 2488 | earlier. |
| 2489 | |
| 2490 | * src/sfnt/sfobjs.c (sfnt_init_face): Put `memory' variable into |
| 2491 | TT_CONFIG_OPTION_GX_VAR_SUPPORT block. |
| 2492 | (sfnt_done_face): Protect some code with |
| 2493 | TT_CONFIG_OPTION_GX_VAR_SUPPORT. |
| 2494 | |
| 2495 | * src/sfnt/ttsbit.c (tt_face_load_sbix_image): Remove compiler |
| 2496 | warning. |
| 2497 | |
| 2498 | * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Put `tmp' variable |
| 2499 | into TT_USE_BYTECODE_INTERPRETER block. |
| 2500 | |
| 2501 | (tt_loader_init): Put `error' variable into |
| 2502 | TT_USE_BYTECODE_INTERPRETER block. |
| 2503 | |
| 2504 | 2017-03-17 Werner Lemberg <wl@gnu.org> |
| 2505 | |
Werner Lemberg | e559578 | 2017-03-17 21:34:08 +0100 | [diff] [blame] | 2506 | Fix preprocessor warning. |
| 2507 | |
| 2508 | * devel/ftoption.h, include/freetype/config/ftoption.h: Test whether |
| 2509 | TT_CONFIG_OPTION_SUBPIXEL_HINTING is defined before checking its |
| 2510 | value. |
| 2511 | |
| 2512 | 2017-03-17 Werner Lemberg <wl@gnu.org> |
| 2513 | |
Werner Lemberg | bffb7fe | 2017-03-17 07:52:30 +0100 | [diff] [blame] | 2514 | `make multi' fixes; compiler warnings. |
| 2515 | |
| 2516 | * src/base/ftsnames.c: Include FT_INTERNAL_DEBUG_H. |
| 2517 | |
| 2518 | * src/cff/cffobjs.c [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Include |
| 2519 | FT_MULTIPLE_MASTERS_H and FT_SERVICE_MULTIPLE_MASTERS_H. |
| 2520 | |
| 2521 | * src/sfnt/sfdriver.c [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Include |
| 2522 | FT_MULTIPLE_MASTERS_H and FT_SERVICE_MULTIPLE_MASTERS_H. |
| 2523 | (get_win_string, get_apple_string): Initialize `result'. |
| 2524 | |
Dave Arnold | 0bf95b5 | 2017-03-17 07:22:55 +0100 | [diff] [blame] | 2525 | 2017-03-17 Dave Arnold <darnold@adobe.com> |
| 2526 | |
Dave Arnold | fdbef53 | 2017-03-17 07:28:11 +0100 | [diff] [blame] | 2527 | [cff] Fix potential bugs in default NDV for CFF2. |
| 2528 | |
| 2529 | * src/cff/cffload.c (cff_blend_build_vector): Explicitly build blend |
| 2530 | vector when `lenNDV' is zero; don't rely on zero-init. |
| 2531 | Save `lenNDV' as part of cache key even when `lenNDV' is zero. |
| 2532 | |
| 2533 | 2017-03-17 Dave Arnold <darnold@adobe.com> |
| 2534 | |
Dave Arnold | 0bf95b5 | 2017-03-17 07:22:55 +0100 | [diff] [blame] | 2535 | [cff] Fix CFF2 stack allocation. |
| 2536 | |
| 2537 | * src/cff/cffparse.c (cff_parser_init) add 1 for operator. |
| 2538 | |
Werner Lemberg | d9ff6f2 | 2017-03-16 20:20:51 +0100 | [diff] [blame] | 2539 | 2017-03-16 Werner Lemberg <wl@gnu.org> |
| 2540 | |
| 2541 | * src/truetype/ttgxvar.c (tt_done_blend): Free `vvar_table'. |
| 2542 | |
| 2543 | Reported as |
| 2544 | |
| 2545 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=883 |
| 2546 | |
Werner Lemberg | f87269c | 2017-03-15 08:03:16 +0100 | [diff] [blame] | 2547 | 2017-03-15 Werner Lemberg <wl@gnu.org> |
| 2548 | |
Werner Lemberg | 981c23b | 2017-03-15 11:35:26 +0100 | [diff] [blame] | 2549 | Remove clang compiler warnings (#50548). |
| 2550 | |
| 2551 | * include/freetype/internal/tttypes.h (TT_FaceRec): Make |
| 2552 | `var_postscript_prefix_len' unsigned. |
| 2553 | |
| 2554 | * src/autofit/afwarp.c (af_warper_compute_line_best): Remove |
| 2555 | redundant assignment. |
| 2556 | |
| 2557 | * src/cff/cffload.c (cff_subfont_load): Add casts. |
| 2558 | |
| 2559 | * src/cff/cffparse.c (cff_parse_blend): Remove redundant assignment. |
| 2560 | |
| 2561 | * src/sfnt/sfdriver.c (fmix32, murmur_hash_3_128): Add `static' |
| 2562 | keyword. |
| 2563 | Add casts. |
| 2564 | (fixed2float): Add cast. |
| 2565 | (sfnt_get_var_ps_name): Make `p' always initialized. |
| 2566 | Add casts. |
| 2567 | |
| 2568 | * src/truetype/ttgxvar.c (TT_Get_MM_Var): Add casts. |
| 2569 | |
| 2570 | 2017-03-15 Werner Lemberg <wl@gnu.org> |
| 2571 | |
Werner Lemberg | 3f92048 | 2017-03-15 09:18:22 +0100 | [diff] [blame] | 2572 | [ftfuzzer] Limit number of tested faces and instances. |
| 2573 | |
| 2574 | This is inspired by the discussion in and analysis of |
| 2575 | |
| 2576 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=859 |
| 2577 | |
| 2578 | * src/tools/ftfuzzer/ftfuzzer.cc (LLVMFuzzerTestOneInput): Use only |
| 2579 | up to 20 face indices. |
| 2580 | Use only up to 20 instance indices. |
| 2581 | |
| 2582 | 2017-03-15 Werner Lemberg <wl@gnu.org> |
| 2583 | |
Werner Lemberg | f87269c | 2017-03-15 08:03:16 +0100 | [diff] [blame] | 2584 | * src/tools/ftfuzzer/ftfuzzer.cc: Improve readability; formatting. |
| 2585 | |
Werner Lemberg | 4a32dce | 2017-03-14 19:32:12 +0100 | [diff] [blame] | 2586 | 2017-03-14 Werner Lemberg <wl@gnu.org> |
| 2587 | |
Werner Lemberg | 34010f7 | 2017-03-14 21:50:22 +0100 | [diff] [blame] | 2588 | [sfnt] Implement PS names for font instances [3/3]. |
| 2589 | |
| 2590 | Everything is guarded with TT_CONFIG_OPTION_GX_VAR_SUPPORT. |
| 2591 | |
| 2592 | * include/freetype/internal/tttypes.h (TT_FaceRec): New fields |
| 2593 | `var_postscript_prefix' and `var_postscript_prefix_len'. |
| 2594 | |
| 2595 | * src/sfnt/sfdriver.c: Include FT_TRUETYPE_IDS_H. |
| 2596 | (sfnt_is_alphanumeric): New wrapperfunction for `ft_isalnum'. |
| 2597 | (get_win_string, get_apple_string): Remove `const' from return |
| 2598 | value. |
| 2599 | (MAX_VALUE_DESCRIPTOR_LEN, MAX_PS_NAME_LEN): New macros. |
| 2600 | (hexdigits): New array. |
| 2601 | (sfnt_get_var_ps_name): New function, implementing Adobe TechNote |
| 2602 | 5902 to construct a PS name for a variation font instance. |
| 2603 | (sfnt_get_ps_name): Call `sfnt_get_var_ps_name' for font instances. |
| 2604 | |
| 2605 | * src/sfnt/sfobjs.c (sfnt_done_face): Updated. |
| 2606 | |
| 2607 | * src/truetype/ttgxvar.c (tt_set_mm_blend): Reset |
| 2608 | `face->postscript_name' to trigger recalculation for new instance |
| 2609 | parameters. |
| 2610 | |
| 2611 | 2017-03-14 Werner Lemberg <wl@gnu.org> |
| 2612 | |
Werner Lemberg | 4fd9cc7 | 2017-03-14 19:40:50 +0100 | [diff] [blame] | 2613 | [sfnt] Implement PS names for font instances [2/3]. |
| 2614 | |
| 2615 | * src/sfnt/sfdriver.c (fix2float) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: |
| 2616 | New function to find the shortest representation of a 16.16 |
| 2617 | fractional number. |
| 2618 | |
| 2619 | 2017-03-14 Werner Lemberg <wl@gnu.org> |
| 2620 | |
Werner Lemberg | 4a32dce | 2017-03-14 19:32:12 +0100 | [diff] [blame] | 2621 | [sfnt] Implement PS names for font instances [1/3]. |
| 2622 | |
| 2623 | Add 128bit MurmurHash 3 function. |
| 2624 | |
| 2625 | Everything is guarded with TT_CONFIG_OPTION_GX_VAR_SUPPORT. |
| 2626 | |
| 2627 | * src/sfnt/sfdriver.c (ROTL32): New macro. |
| 2628 | (fmix32, murmur_hash_3_128): New functions. |
| 2629 | |
Werner Lemberg | 447a0b6 | 2017-03-13 07:42:34 +0100 | [diff] [blame] | 2630 | 2017-03-13 Werner Lemberg <wl@gnu.org> |
| 2631 | |
| 2632 | [truetype] Ignore invalid MVAR tags. |
| 2633 | |
| 2634 | Reported as |
| 2635 | |
| 2636 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=838 |
| 2637 | |
| 2638 | * src/truetype/ttgxvar.c (ft_var_load_mvar): Ignore value and emit |
| 2639 | warning for invalid tags. |
| 2640 | (tt_apply_mvar): Ignore invalid tags. |
| 2641 | |
Werner Lemberg | 4a62922 | 2017-03-12 10:19:53 +0100 | [diff] [blame] | 2642 | 2017-03-12 Werner Lemberg <wl@gnu.org> |
| 2643 | |
Werner Lemberg | 5eb0fd5 | 2017-03-12 20:46:56 +0100 | [diff] [blame] | 2644 | [truetype] Store and use design coordinates also. |
| 2645 | |
| 2646 | * include/freetype/internal/services/svmm.h (FT_Get_Var_Blend_Func): |
| 2647 | Add `normalizedcoords' argument. |
| 2648 | |
| 2649 | * src/truetype/ttgxvar.h (GX_BlendRec): Add `coords' field to store |
| 2650 | the design coordinates of the current instance. |
| 2651 | Updated. |
| 2652 | |
| 2653 | * src/truetype/ttgxvar.c (TT_Set_MM_Blend): Move functionality to... |
| 2654 | (tt_set_mm_blend): ... New function. |
| 2655 | Convert data in `normalizedcoords' array to `coords' array on |
| 2656 | demand. |
| 2657 | (TT_Set_Var_Design): Store argument data in `coords' array. |
| 2658 | (TT_Get_Var_Design): Get data from `coords' array. |
| 2659 | (tt_get_var_blend): Updated. |
| 2660 | (tt_done_blend): Updated. |
| 2661 | |
| 2662 | * src/cff/cffload.c, src/cff/cffload.h (cff_get_var_blend): Updated. |
| 2663 | |
| 2664 | * src/cff/cf2ft.c (cf2_getNormalizedVector): Updated. |
| 2665 | |
| 2666 | * src/cff/cffobjs.c (cff_face_init): Updated. |
| 2667 | |
| 2668 | 2017-03-12 Werner Lemberg <wl@gnu.org> |
| 2669 | |
Werner Lemberg | 4a62922 | 2017-03-12 10:19:53 +0100 | [diff] [blame] | 2670 | src/truetype/ttgxvar.[ch]: s/avar_checked/avar_loaded/. |
| 2671 | |
Werner Lemberg | 7bbb91f | 2017-03-08 15:09:41 +0100 | [diff] [blame] | 2672 | 2017-03-08 Werner Lemberg <wl@gnu.org> |
| 2673 | |
| 2674 | [sfnt] Another fix for buggy variation fonts. |
| 2675 | |
| 2676 | Reported as |
| 2677 | |
| 2678 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=759 |
| 2679 | |
| 2680 | * src/sfnt/sfobjs.c (sfnt_init_face): While setting number of |
| 2681 | instances to zero for `CFF' fonts table, ensure that there is no |
| 2682 | `CFF2' present also (which gets priority). |
| 2683 | |
Werner Lemberg | 7793097 | 2017-03-07 17:27:58 +0100 | [diff] [blame] | 2684 | 2017-03-07 Werner Lemberg <wl@gnu.org> |
| 2685 | |
| 2686 | [sfnt] Improve handling for buggy variation fonts. |
| 2687 | |
| 2688 | Reported as |
| 2689 | |
| 2690 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=738 |
| 2691 | |
| 2692 | * src/sfnt/sfobjs.c (sfnt_init_face): While setting number of |
Werner Lemberg | 34010f7 | 2017-03-14 21:50:22 +0100 | [diff] [blame] | 2693 | instances to zero for `CFF' fonts table, ensure that there is no |
| 2694 | `glyf' table present also (which gets priority). |
Werner Lemberg | 7793097 | 2017-03-07 17:27:58 +0100 | [diff] [blame] | 2695 | |
Werner Lemberg | 27fee7f | 2017-03-06 20:45:44 +0100 | [diff] [blame] | 2696 | 2017-03-06 Werner Lemberg <wl@gnu.org> |
| 2697 | |
| 2698 | [sfnt, truetype] Always provide default instance. |
| 2699 | |
| 2700 | As documented in the OpenType specification, an entry for the |
| 2701 | default instance may be omitted in the named instance table. In |
| 2702 | particular this means that even if there is no named instance table |
| 2703 | in the font we actually do have a named instance, namely the default |
| 2704 | instance. |
| 2705 | |
| 2706 | For consistency, we always want the default instance in our list of |
| 2707 | named instances. If it is missing, we try to synthesize it. |
| 2708 | |
| 2709 | * src/sfnt/sfobjs.c (sfnt_init_face): Check whether the default |
| 2710 | instance is in the table of named instances. Otherwise adjust |
| 2711 | number of instances. |
| 2712 | |
| 2713 | * src/truetype/ttgxvar.c: Include FT_TRUETYPE_IDS_H. |
| 2714 | (TT_Get_MM_Var): Use `face->root.style_flags' as the number of named |
| 2715 | instances. |
| 2716 | Sythesize a named instance entry if necessary. |
| 2717 | (tt_done_blend): Free `normalized_stylecoords'. |
| 2718 | |
Werner Lemberg | c1b000d | 2017-03-05 20:23:35 +0100 | [diff] [blame] | 2719 | 2017-03-05 Werner Lemberg <wl@gnu.org> |
| 2720 | |
| 2721 | [sfnt] Remove redundant code. |
| 2722 | |
| 2723 | * src/sfnt/sfobjs.c (sfnt_init_face): Remove second test for |
| 2724 | `num_instances', which will always succeed. |
| 2725 | |
Werner Lemberg | 588e38e | 2017-03-04 11:04:24 +0100 | [diff] [blame] | 2726 | 2017-03-04 Werner Lemberg <wl@gnu.org> |
| 2727 | |
Werner Lemberg | 0c7fb43 | 2017-03-05 19:06:41 +0100 | [diff] [blame] | 2728 | [sfnt] Add `get_name_id' service. |
| 2729 | |
| 2730 | * include/freetype/internal/sfnt.h (TT_Get_Name_ID_Func): New |
| 2731 | typedef. |
| 2732 | (SFNT_Interface): Add `get_name_id' field. |
| 2733 | (FT_DEFINE_SFNT_INTERFACE): Updated. |
| 2734 | |
| 2735 | * src/sfnt/sfdriver.c (search_name_id): Rename to... |
| 2736 | (sfnt_get_name_id): ... this. |
Alexei Podtelezhnikov | c28e9c9 | 2017-09-15 22:23:01 -0400 | [diff] [blame] | 2737 | (sfnt_get_ps_name, sfnt_interface): Updated. |
Werner Lemberg | 0c7fb43 | 2017-03-05 19:06:41 +0100 | [diff] [blame] | 2738 | |
| 2739 | 2017-03-04 Werner Lemberg <wl@gnu.org> |
| 2740 | |
Werner Lemberg | 588e38e | 2017-03-04 11:04:24 +0100 | [diff] [blame] | 2741 | [truetype] Make `TT_Set_MM_Blend' set named instance index. |
| 2742 | |
| 2743 | * src/truetype/ttgxvar.h (GX_Blend): New array |
| 2744 | `normalized_stylecoords'. |
| 2745 | |
| 2746 | * src/truetype/ttgxvar.c (TT_Get_MM_Var): Allocate and fill |
| 2747 | `normalized_stylecoords'. |
| 2748 | (TT_Set_MM_Blend): Check instance tuple and adjust `face_index' |
| 2749 | accordingly. |
| 2750 | |
Werner Lemberg | 4717696 | 2017-03-02 21:42:14 +0100 | [diff] [blame] | 2751 | 2017-03-02 Werner Lemberg <wl@gnu.org> |
| 2752 | |
| 2753 | [truetype] Split off designer/normalized conversion routines. |
| 2754 | |
| 2755 | * src/truetype/ttgxvar.c (TT_Set_Var_Design): Split off conversion |
| 2756 | code designer->normalized coordinates to... |
| 2757 | (ft_var_to_normalized): ... New function. |
| 2758 | (TT_Get_Var_Design): Split off conversion code normalized->designer |
| 2759 | coordinates to... |
| 2760 | (ft_var_to_design): ... New function. |
| 2761 | |
| 2762 | 2017-02-28 Werner Lemberg <wl@gnu.org> |
Werner Lemberg | f0cee1a | 2017-02-23 08:23:39 +0100 | [diff] [blame] | 2763 | |
Werner Lemberg | b553fcb | 2017-02-28 15:11:21 +0100 | [diff] [blame] | 2764 | [sfnt] Further generalize `sfnt_get_ps_name'; report invalid data. |
| 2765 | |
| 2766 | * src/sfnt/sfdriver.c (sfnt_ps_map): New array. |
| 2767 | (sfnt_is_postscript): New function. |
| 2768 | (char_type_func): New typedef. |
| 2769 | (get_win_string, get_apple_string): Add argument to specify |
| 2770 | character checking function. |
| 2771 | Add argument whether argument checking failures should be reported. |
| 2772 | Update callers. |
| 2773 | (search_name_id): Fix return value. |
| 2774 | |
| 2775 | 2017-02-23 Werner Lemberg <wl@gnu.org> |
| 2776 | |
Werner Lemberg | b653a23 | 2017-02-26 11:23:07 +0100 | [diff] [blame] | 2777 | [sfnt] Split off another bit of `sfnt_get_ps_name'. |
| 2778 | |
| 2779 | * src/sfnt/sfdriver.c (sfnt_get_ps_name): Split off some |
| 2780 | functionality into... |
| 2781 | (search_name_id): ... New function. |
| 2782 | |
| 2783 | 2017-02-23 Werner Lemberg <wl@gnu.org> |
| 2784 | |
Werner Lemberg | c1abd6a | 2017-02-23 22:58:14 +0100 | [diff] [blame] | 2785 | [sfnt] Modularize `sfnt_get_ps_name'. |
| 2786 | |
| 2787 | * src/sfnt/sfdriver.c (sfnt_get_ps_name): Split off some |
| 2788 | functionality into... |
| 2789 | (IS_WIN, IS_APPLE): ... New macros. |
| 2790 | (get_win_string, get_apple_string): ... New functions. |
| 2791 | |
| 2792 | 2017-02-23 Werner Lemberg <wl@gnu.org> |
| 2793 | |
Werner Lemberg | 01f315f | 2017-02-23 14:24:01 +0100 | [diff] [blame] | 2794 | [truetype] Minor improvement. |
| 2795 | |
| 2796 | * src/truetype/ttgload.c (TT_Process_Simple_Glyph, |
| 2797 | load_truetype_glyph): Remove unnecessary tests. |
| 2798 | |
| 2799 | 2017-02-23 Werner Lemberg <wl@gnu.org> |
| 2800 | |
Werner Lemberg | f0cee1a | 2017-02-23 08:23:39 +0100 | [diff] [blame] | 2801 | * include/freetype/internal/tttypes.h (TT_Face): s/isCFF2/is_cff2/. |
| 2802 | |
| 2803 | For orthogonality with other structure field names. |
| 2804 | |
| 2805 | Update all users. |
| 2806 | |
Alexei Podtelezhnikov | 761d9e4 | 2017-02-22 22:41:36 -0500 | [diff] [blame] | 2807 | 2017-02-22 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 2808 | |
| 2809 | * src/smooth/ftgrays.c (gray_hline): Improve code. |
| 2810 | |
Dominik Röttsches | b310534 | 2017-02-20 12:29:59 +0100 | [diff] [blame] | 2811 | 2017-02-20 Dominik Röttsches <drott@google.com> |
| 2812 | |
| 2813 | Fix some `ttnameid.h' entries (#50313). |
| 2814 | |
| 2815 | * include/freetype/ttnameid.h: |
| 2816 | s/TT_MS_LANGID_SPANISH_INTERNATIONAL_SORT/TT_MS_LANGID_SPANISH_SPAIN_INTERNATIONAL_SORT/, |
| 2817 | s/TT_MS_LANGID_MONGOLIAN_MONGOLIA_MONGOLIA/TT_MS_LANGID_MONGOLIAN_MONGOLIA_MONGOLIAN/. |
| 2818 | |
Werner Lemberg | ca1486c | 2017-02-20 08:55:26 +0100 | [diff] [blame] | 2819 | 2017-02-20 Werner Lemberg <wl@gnu.org> |
| 2820 | |
Werner Lemberg | e706798 | 2017-02-20 09:15:13 +0100 | [diff] [blame] | 2821 | [cff] Finish support for `random' operator. |
| 2822 | |
| 2823 | * src/cff/cfftypes.h (CFF_SubFontRec): Add `random' field. |
| 2824 | |
| 2825 | * src/cff/cffobjs.c: Updated. |
| 2826 | (cff_driver_init): Initialize random seed value. |
| 2827 | |
| 2828 | * src/cff/cffload.c (cff_random): New function. |
| 2829 | (cff_subfont_load): Add `face' argument. |
| 2830 | Update all callers. |
| 2831 | Initialize random number generator with a proper seed value. |
| 2832 | (cff_font_load): Add `face' argument. |
| 2833 | Update all callers. |
| 2834 | |
| 2835 | * src/cff/cffload.h: Updated. |
| 2836 | |
| 2837 | * src/cff/cf2intrp.c (CF2_FIXME): Removed. |
| 2838 | (cf2_interpT2CharString) <cf2_escRANDOM>: Implement opcode. |
| 2839 | |
| 2840 | * src/cff/cffgload.c (cff_decoder_parse_charstrings): Don't |
| 2841 | initialize random seed value. |
| 2842 | <cff_op_random>: Use new random seed framework. |
| 2843 | |
| 2844 | 2017-02-20 Werner Lemberg <wl@gnu.org> |
| 2845 | |
Werner Lemberg | 156b30b | 2017-02-20 09:06:22 +0100 | [diff] [blame] | 2846 | [cff] Sanitize `initialRandomSeed'. |
| 2847 | |
| 2848 | * src/cff/cffload.c (cff_load_private_dict): Make |
| 2849 | `initial_random_seed' value always positive. |
| 2850 | |
| 2851 | 2017-02-20 Werner Lemberg <wl@gnu.org> |
| 2852 | |
Werner Lemberg | 753e113 | 2017-02-20 09:01:14 +0100 | [diff] [blame] | 2853 | [cff] Introduce `random-seed' property (2/2). |
| 2854 | |
| 2855 | * src/base/ftobjs.c: Include `FT_CFF_DRIVER_H'. |
| 2856 | (open_face): Initialize `face->internal->random_seed'. |
| 2857 | (FT_Face_Properties): Handle `FT_PARAM_TAG_RANDOM_SEED'. |
| 2858 | |
| 2859 | * src/cff/cffdrivr.c (cff_property_set): Handle `random-seed' |
| 2860 | property. |
| 2861 | |
| 2862 | 2017-02-20 Werner Lemberg <wl@gnu.org> |
| 2863 | |
Werner Lemberg | ca1486c | 2017-02-20 08:55:26 +0100 | [diff] [blame] | 2864 | [cff] Introduce `random-seed' property (1/2). |
| 2865 | |
| 2866 | We need this for support of the `random' operator. |
| 2867 | |
| 2868 | * include/freetype/ftcffdrv.h (FT_PARAM_TAG_RANDOM_SEED): New macro. |
| 2869 | |
| 2870 | * include/freetype/internal/ftobjs.h (FT_Face_InternalRec): New |
| 2871 | field `random_seed'. |
| 2872 | |
| 2873 | * src/cff/cffobjs.h (CFF_DriverRec): New field `random_seed'. |
| 2874 | |
Werner Lemberg | 467b026 | 2017-02-18 10:42:48 +0100 | [diff] [blame] | 2875 | 2017-02-17 Werner Lemberg <wl@gnu.org> |
| 2876 | |
| 2877 | Remove clang warnings. |
| 2878 | |
| 2879 | * src/autofit/aflatin.c (af_latin_sort_blue): Add missing `static' |
| 2880 | keyword. |
| 2881 | |
| 2882 | * src/base/ftmm.c (FT_Set_Var_Design_Coordinates, |
| 2883 | FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates): |
| 2884 | Initialize some variables. |
| 2885 | |
Nikolaus Waxweiler | 2e95198 | 2017-02-16 20:45:45 +0100 | [diff] [blame] | 2886 | 2017-02-16 Nikolaus Waxweiler <madigens@gmail.com> |
| 2887 | Werner Lemberg <wl@gnu.org> |
| 2888 | |
Nikolaus Waxweiler | 2b0ac18 | 2017-02-18 10:42:23 +0100 | [diff] [blame] | 2889 | Add face property for stem darkening. |
| 2890 | |
| 2891 | * include/freetype/ftautoh.h (FT_PARAM_TAG_STEM_DARKENING): New |
| 2892 | macro. |
| 2893 | |
| 2894 | * include/freetype/internal/ftobjs.h (FT_Face_InternalRec): Add |
| 2895 | `no_stem_darkening' field. |
| 2896 | |
| 2897 | * src/autofit/afloader.c (af_loader_load_glyph), |
| 2898 | src/autofit/afmodule.c (af_property_set): Updated. |
| 2899 | |
| 2900 | * src/base/ftobjs.c: Include FT_AUTOHINTER_H. |
| 2901 | (ft_open_face_internal): Updated. |
| 2902 | (FT_Face_Properties): Handle FT_PARAM_TAG_STEM_DARKENING. |
| 2903 | |
| 2904 | * src/cff/cf2ft.c (cf2_decoder_parse_charstrings): Updated. |
| 2905 | |
| 2906 | * src/cff/cffdrivr.c (cff_property_set): Updated. |
| 2907 | |
| 2908 | 2017-02-16 Nikolaus Waxweiler <madigens@gmail.com> |
| 2909 | Werner Lemberg <wl@gnu.org> |
| 2910 | |
Nikolaus Waxweiler | 2e95198 | 2017-02-16 20:45:45 +0100 | [diff] [blame] | 2911 | Add face property for LCD filter weights. |
| 2912 | |
| 2913 | * include/freetype/ftlcdfil.h (FT_PARAM_TAG_LCD_FILTER_WEIGHTS, |
| 2914 | FT_LCD_FILTER_FIVE_TAPS): New macros. |
| 2915 | (FT_LcdFiveTapFilter): New typedef. |
| 2916 | |
| 2917 | * include/freetype/ftobjs.h (FT_Face_InternalRec) |
| 2918 | [FT_CONFIG_OPTION_SUBPIXEL_RENDERING]: Add `lcd_weights' field. |
| 2919 | (FT_Bitmap_LcdFilterFunc): Change third argument to weights array. |
| 2920 | (ft_lcd_filter_fir): New prototype. |
| 2921 | (FT_LibraryRec): Updated. |
| 2922 | |
| 2923 | * src/base/ftlcdfil.c (_ft_lcd_filter_fir): Renamed to... |
Alexei Podtelezhnikov | 71d289d | 2017-04-19 23:50:29 -0400 | [diff] [blame] | 2924 | (ft_lcd_filter_fir): ... this base function. |
Nikolaus Waxweiler | 2e95198 | 2017-02-16 20:45:45 +0100 | [diff] [blame] | 2925 | Updated. |
| 2926 | (_ft_lcd_filter_legacy): Updated. |
| 2927 | (FT_Library_SetLcdFilterWeights, FT_Library_SetLcdFilter): Updated. |
| 2928 | |
| 2929 | * src/base/ftobjs.c (ft_open_face_internal): Updated. |
| 2930 | (FT_Face_Properties): Handle FT_PARAM_TAG_LCD_FILTER_WEIGHTS. |
| 2931 | |
| 2932 | * src/smooth/ftsmooth.c (ft_smooth_render_generic) |
Alexei Podtelezhnikov | 7d7aae1 | 2017-03-07 22:21:26 -0500 | [diff] [blame] | 2933 | [FT_CONFIG_OPTION_SUBPIXEL_RENDERING]: Handle LCD weights from |
Nikolaus Waxweiler | 2e95198 | 2017-02-16 20:45:45 +0100 | [diff] [blame] | 2934 | `FT_Face_Internal'. |
| 2935 | |
Nikolaus Waxweiler | 64cdee7 | 2017-02-15 08:06:35 +0100 | [diff] [blame] | 2936 | 2017-02-14 Nikolaus Waxweiler <madigens@gmail.com> |
| 2937 | Werner Lemberg <wl@gnu.org> |
| 2938 | |
| 2939 | Add new function `FT_Face_Properties'. |
| 2940 | |
| 2941 | This commit provides the framework, to be filled with something |
| 2942 | useful in the next commits. |
| 2943 | |
| 2944 | * include/freetype/freetype.h (FT_Face_Properties): Declare. |
| 2945 | |
| 2946 | * src/base/ftobjs.c (FT_Face_Properties): New function. |
| 2947 | |
Werner Lemberg | 319125d | 2017-02-13 09:34:17 +0100 | [diff] [blame] | 2948 | 2017-02-13 Werner Lemberg <wl@gnu.org> |
| 2949 | |
| 2950 | [autofit] Prevent overlapping blue zones. |
| 2951 | |
| 2952 | Problem reported as |
| 2953 | |
| 2954 | https://github.com/google/fonts/issues/632 |
| 2955 | |
| 2956 | The font in question (Nunito) has values 705 and 713 for the |
| 2957 | reference and overshoot values, respectively, of the first blue |
| 2958 | zone. Blue zone 2, however, has value 710 for both the reference |
| 2959 | and overshoot. At 12ppem, reference and overshoot of blue zone 0 |
| 2960 | becomes 8px, while blue zone 2 becomes 9px. |
| 2961 | |
| 2962 | A peculiarity of this font is that the tops of isolated vertical |
| 2963 | stems like `N' have a slight overshoot also. The auto-hinter tries |
| 2964 | to find the nearest blue zone using the *original* coordinates. For |
| 2965 | vertical stems, this is value 713. For normal horizontal tops like |
| 2966 | in character `E', this is value 710. Since value 713 is mapped to |
| 2967 | 8px but value 710 to 9px, `N' and similar characters are one pixel |
| 2968 | higher than `E', which looks very bad. |
| 2969 | |
| 2970 | This commit sanitizes blue zones to avoid such a behaviour. |
| 2971 | |
| 2972 | * src/autofit/aflatin.c (af_latin_sort_blue): New function. |
| 2973 | (af_latin_metrics_init_blues): Sort blue values and remove overlaps. |
| 2974 | |
Alexei Podtelezhnikov | fcd47b3 | 2017-02-12 23:07:29 -0500 | [diff] [blame] | 2975 | 2017-02-12 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 2976 | |
| 2977 | * src/smooth/ftgrays.c (gray_sweep): Improve code. |
| 2978 | |
Werner Lemberg | faa3c88 | 2017-02-06 13:13:02 +0100 | [diff] [blame] | 2979 | 2017-02-06 Werner Lemberg <wl@gnu.org> |
| 2980 | |
| 2981 | [truetype] Implement `VVAR' table support. |
| 2982 | |
| 2983 | * src/truetype/ttgxvar.h (GX_HVarTable): Renamed to... |
| 2984 | (GX_HVVarTable): ...This. |
| 2985 | (GX_Blend): Add fields for `VVAR' table handling. |
| 2986 | Other minor updates. |
| 2987 | |
| 2988 | * src/truetype/ttgxvar.c (ft_var_load_hvar): Renamed to... |
| 2989 | (ft_var_load_hvvar): ...This. |
| 2990 | Handle VVAR loading also (controlled by an additional parameter). |
| 2991 | (tt_hadvance_adjust): Renamed to... |
| 2992 | (tt_hvadvance_adjust): ...This. |
| 2993 | Handle application of advance height also (controlled by an |
| 2994 | additional parameter). |
| 2995 | (tt_hadvance_adjust, tt_vadvance_adjust): Wrappers for |
| 2996 | `tt_hvadvance_adjust'. |
| 2997 | |
| 2998 | * src/truetype/ttdriver.c (tt_service_metrics_variations): Updated. |
| 2999 | |
Werner Lemberg | 1dee4bf | 2017-02-05 08:33:10 +0100 | [diff] [blame] | 3000 | 2017-02-05 Werner Lemberg <wl@gnu.org> |
| 3001 | |
| 3002 | [autofit] Use better blue zone characters for lowercase latin. |
| 3003 | |
| 3004 | The number of lowercase characters for computing the top flat blue |
| 3005 | zone value was too small (in most cases only `x' and `z'). If one |
| 3006 | of the two characters has a large serif, say, it can happen that |
| 3007 | FreeType must select between two different values, having a 50% |
| 3008 | chance to use the wrong one. As a result, rendering at larger PPEM |
| 3009 | values could yield uneven lowercase glyph heights. |
| 3010 | |
| 3011 | Problem reported by Christoph Koeberlin <christoph@koe.berlin>. |
| 3012 | |
| 3013 | * src/autofit/afblue.dat (AF_BLUE_STRING_LATIN_SMALL): Replaced |
| 3014 | with... |
| 3015 | (AF_BLUE_STRING_LATIN_SMALL_TOP, AF_BLUE_STRING_LATIN_SMALL_BOTTOM): |
| 3016 | ... New, extended sets. |
| 3017 | (AF_BLUE_STRINGSET_LATN): Updated. |
| 3018 | |
| 3019 | * src/autofit/afblue.c, scr/autofit/afblue.h: Regenerated. |
| 3020 | |
Werner Lemberg | 7904289 | 2017-02-04 16:08:08 +0100 | [diff] [blame] | 3021 | 2017-02-04 Werner Lemberg <wl@gnu.org> |
| 3022 | |
Werner Lemberg | 1c513fb | 2017-02-04 20:30:40 +0100 | [diff] [blame] | 3023 | Make `freetype-config' a wrapper of `pkg-config' if possible. |
| 3024 | |
| 3025 | Based on ideas taken from |
| 3026 | |
| 3027 | http://pkgs.fedoraproject.org/cgit/rpms/freetype.git/tree/freetype-multilib.patch |
| 3028 | http://pkgs.fedoraproject.org/cgit/rpms/freetype.git/tree/freetype-2.5.3-freetype-config-prefix.patch |
| 3029 | |
| 3030 | * builds/unix/freetype-config.in: Rewritten. Use `pkg-config' to |
| 3031 | set output variables if program is available. |
| 3032 | |
| 3033 | * docs/CHANGES, docs/freetype-config.1: Updated. |
| 3034 | |
| 3035 | 2017-02-04 Werner Lemberg <wl@gnu.org> |
| 3036 | |
Werner Lemberg | 7904289 | 2017-02-04 16:08:08 +0100 | [diff] [blame] | 3037 | * builds/unix/unix-def.in (freetype-config): Fix permissions. |
| 3038 | |
Werner Lemberg | 5a7f2ff | 2017-02-03 08:31:18 +0100 | [diff] [blame] | 3039 | 2017-02-03 Werner Lemberg <wl@gnu.org> |
| 3040 | |
Werner Lemberg | 0a1169f | 2017-02-03 19:38:20 +0100 | [diff] [blame] | 3041 | * src/autofit/afglobal.c (af_face_globals_free): Erase useless code. |
| 3042 | |
| 3043 | 2017-02-03 Werner Lemberg <wl@gnu.org> |
| 3044 | |
Werner Lemberg | 5a7f2ff | 2017-02-03 08:31:18 +0100 | [diff] [blame] | 3045 | * include/freetype/ftgasp.h (FT_GASP_SYMMETRIC_GRIDFIT): Fix value. |
| 3046 | |
| 3047 | Reported by Behdad. |
| 3048 | |
Werner Lemberg | dadc50a | 2017-02-02 07:13:29 +0100 | [diff] [blame] | 3049 | 2017-02-02 Werner Lemberg <wl@gnu.org> |
| 3050 | |
Werner Lemberg | e669959 | 2017-02-02 11:38:04 +0100 | [diff] [blame] | 3051 | [truetype] Fix MVAR post-action handling. |
| 3052 | |
| 3053 | Reported as |
| 3054 | |
| 3055 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=509 |
| 3056 | |
| 3057 | * src/truetype/ttobjs.c (tt_size_reset): Do nothing for CFF2. This |
| 3058 | is important to make `tt_size_reset_iterator' (called in |
| 3059 | `tt_apply_mvar') always work. |
| 3060 | |
| 3061 | 2017-02-02 Werner Lemberg <wl@gnu.org> |
| 3062 | |
Werner Lemberg | dadc50a | 2017-02-02 07:13:29 +0100 | [diff] [blame] | 3063 | Make compilation with FT_CONFIG_OPTION_PIC work again. |
| 3064 | |
| 3065 | All code committed here is guarded with `FT_CONFIG_OPTION_PIC'. |
| 3066 | |
| 3067 | * include/freetype/internal/services/svmetric.h |
| 3068 | (FT_DEFINE_SERVICE_METRICSVARIATIONSREC): Remove trailing semicolon. |
| 3069 | |
| 3070 | * src/autofit/aflatin.c (af_latin_hints_compute_edges, |
| 3071 | af_latin_hint_edges): Provide `globals' variable. |
| 3072 | |
| 3073 | * src/autofit/afloader.c (af_loader_load_glyph): Remove shadowing |
| 3074 | variable. |
| 3075 | |
| 3076 | * src/autofit/afmodule.c (AF_SCRIPT_CLASSES_GET, |
| 3077 | AF_STYLE_CLASSES_GET): Redefine. |
| 3078 | |
| 3079 | * src/autofit/aftypes.h (AF_DEFINE_WRITING_SYSTEM_CLASS): Fix typo. |
| 3080 | |
| 3081 | * src/cff/cffparse.c (CFF_FIELD_BLEND): Provide it. |
| 3082 | |
| 3083 | * src/cff/cffpic.h (CffModulePIC): Fix typo. |
| 3084 | |
Alexei Podtelezhnikov | 2ca5b07 | 2017-01-31 23:13:50 -0500 | [diff] [blame] | 3085 | 2017-01-31 Alexei Podtelezhnikov <apodtele@gmail.com> |
| 3086 | |
| 3087 | * src/smooth/ftgrays.c (gray_render_scanline): Improve code. |
| 3088 | |
Werner Lemberg | 31f8055 | 2017-01-31 08:10:04 +0100 | [diff] [blame] | 3089 | 2017-01-31 Werner Lemberg <wl@gnu.org> |
| 3090 | |
Werner Lemberg | fa437d8 | 2017-01-31 23:06:38 +0100 | [diff] [blame] | 3091 | [cff] Provide metrics variation service interface (#50196). |
| 3092 | |
| 3093 | Only now I've got an OTF with an HVAR table for testing... |
| 3094 | |
| 3095 | The code in `ftmm.c' uses `FT_FACE_LOOKUP_SERVICE' to get the |
| 3096 | metrics variations interface. However, this didn't work with |
| 3097 | `FT_FACE_FIND_GLOBAL_SERVICE' used in `sfnt_init_face'. |
| 3098 | |
| 3099 | * src/cff/cffdrivr.c: Include FT_SERVICE_METRICS_VARIATIONS_H. |
| 3100 | (cff_hadvance_adjust, cff_metrics_adjust): Wrapper functions for |
| 3101 | metric service functions from the `truetype' module. |
| 3102 | (cff_service_metrics_variations): New service. |
| 3103 | (cff_services): Updated. |
| 3104 | |
| 3105 | * src/cff/cffpic.h (CFF_SERVICE_METRICS_VAR_GET): New macro. |
| 3106 | [FT_CONFIG_OPTION_PIC]: Synchronize code. |
| 3107 | |
| 3108 | * src/sfnt/sfobjs.c (sfnt_init_face): Replace call to |
| 3109 | FT_FACE_FIND_GLOBAL_SERVICE with `ft_module_get_service' to always |
| 3110 | load the service from the `truetype' module. |
| 3111 | |
| 3112 | 2017-01-31 Werner Lemberg <wl@gnu.org> |
| 3113 | |
Werner Lemberg | 4058939 | 2017-01-31 19:11:56 +0100 | [diff] [blame] | 3114 | Add framework to support services with 9 functions. |
| 3115 | |
| 3116 | * include/freetype/internal/ftserv.h (FT_DEFINE_SERVICEDESCREC9): |
| 3117 | New macro. |
| 3118 | |
| 3119 | 2017-01-31 Werner Lemberg <wl@gnu.org> |
| 3120 | |
Werner Lemberg | 1e55060 | 2017-01-31 18:47:10 +0100 | [diff] [blame] | 3121 | [base] Fix error handing in MM functions. |
| 3122 | |
| 3123 | * src/base/ftmm.c (FT_Set_Var_Design_Coordinates, |
| 3124 | FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates): |
| 3125 | Implement it. |
| 3126 | |
| 3127 | 2017-01-31 Werner Lemberg <wl@gnu.org> |
| 3128 | |
Werner Lemberg | e80e4d8 | 2017-01-31 08:32:07 +0100 | [diff] [blame] | 3129 | [truetype] Fix sanity check for `gvar' table (#50184). |
| 3130 | |
| 3131 | * src/truetype/ttgxvar.c (ft_var_load_gvar): There might be missing |
| 3132 | variation data for some glyphs. |
| 3133 | |
| 3134 | 2017-01-31 Werner Lemberg <wl@gnu.org> |
| 3135 | |
Werner Lemberg | 31f8055 | 2017-01-31 08:10:04 +0100 | [diff] [blame] | 3136 | [autofit] Avoid uninitialized jumps (#50191). |
| 3137 | |
| 3138 | * src/autofit/afcjk.c (af_cjk_metrics_check_digits), |
| 3139 | src/autofit/aflatin.c (af_latin_metrics_check_digits): Initialize |
| 3140 | `advance'. |
| 3141 | |
Werner Lemberg | 464b16b | 2017-01-27 08:45:46 +0100 | [diff] [blame] | 3142 | 2017-01-27 Werner Lemberg <wl@gnu.org> |
| 3143 | |
| 3144 | s/GB2312/PRC/. |
| 3145 | |
| 3146 | * include/freetype/freetype.h (FT_ENCODING_PRC): New enum value. |
| 3147 | (FT_ENCODING_GB2312): Deprecated. |
| 3148 | |
| 3149 | * include/freetype/ttnameid.h (TT_MS_ID_PRC): New macro. |
| 3150 | (TT_MS_ID_GB2312): Deprecated. |
| 3151 | |
| 3152 | * src/sfnt/sfobjs.c (sfnt_find_encoding): Updated. |
| 3153 | |
| 3154 | * docs/CHANGES: Updated. |
| 3155 | |
Werner Lemberg | 939df42 | 2017-01-26 21:41:38 +0100 | [diff] [blame] | 3156 | 2017-01-26 Werner Lemberg <wl@gnu.org> |
| 3157 | |
Werner Lemberg | f425336 | 2017-01-27 00:06:52 +0100 | [diff] [blame] | 3158 | [base] Add `FT_Get_Sfnt_LangTag' function. |
| 3159 | |
| 3160 | * include/freetype/ftsnames.h (FT_SfntLangTag): New structure. |
| 3161 | (FT_Get_Sfnt_LangTag): New declaration. |
| 3162 | |
Alexei Podtelezhnikov | c28e9c9 | 2017-09-15 22:23:01 -0400 | [diff] [blame] | 3163 | * src/base/ftsnames.c (FT_Get_Sfnt_LangTag): New function. |
Werner Lemberg | f425336 | 2017-01-27 00:06:52 +0100 | [diff] [blame] | 3164 | |
| 3165 | * docs/CHANGES: Updated. |
| 3166 | |
| 3167 | 2017-01-26 Werner Lemberg <wl@gnu.org> |
| 3168 | |
Werner Lemberg | 939df42 | 2017-01-26 21:41:38 +0100 | [diff] [blame] | 3169 | [sfnt] Support `name' table format 1. |
| 3170 | |
| 3171 | * include/freetype/internal/tttypes.h (TT_LangTagRec): New |
| 3172 | structure. |
| 3173 | (TT_NameTableRec): Add fields `numLangTagRecords' and `langTags'. |
| 3174 | |
| 3175 | * src/sfnt/ttload.c (tt_face_load_name): Add support for language |
| 3176 | tags. |
| 3177 | Reduce array size of name strings in case of invalid entries. |
| 3178 | (tt_face_free_name): Updated. |
| 3179 | |
| 3180 | * docs/CHANGES: Updated. |
| 3181 | |
Werner Lemberg | f4e5696 | 2017-01-25 15:08:41 +0100 | [diff] [blame] | 3182 | 2017-01-25 Werner Lemberg <wl@gnu.org> |
| 3183 | |
| 3184 | [sfnt] s/TT_NameEntry/TT_Name/. |
| 3185 | |
| 3186 | * include/freetype/internal/tttypes.h (TT_NameEntryRec): Renamed |
| 3187 | to... |
| 3188 | (TT_NameRec): This. |
| 3189 | (TT_NameTableRec): Updated. |
| 3190 | |
| 3191 | * src/base/ftsnames.c (FT_Get_Sfnt_Name): Updated. |
| 3192 | |
| 3193 | * src/sfnt/sfdriver.c (sfnt_get_ps_name): Updated. |
| 3194 | |
| 3195 | * src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16, |
| 3196 | tt_name_entry_ascii_from_other): Renamed to... |
| 3197 | (tt_name_ascii_from_utf16, tt_name_entry_ascii_from_other): This, |
| 3198 | respectively. |
| 3199 | (TT_NameEntry_ConvertFunc): Renamed to... |
| 3200 | (TT_Name_ConvertFunc): This. |
| 3201 | (tt_face_get_name): Updated. |
| 3202 | |
Alexei Podtelezhnikov | 71d289d | 2017-04-19 23:50:29 -0400 | [diff] [blame] | 3203 | * src/sfnt/ttload.c (tt_face_load_name, tt_face_free_name): |
Werner Lemberg | f4e5696 | 2017-01-25 15:08:41 +0100 | [diff] [blame] | 3204 | Updated. |
| 3205 | |
Werner Lemberg | 141f0ea | 2017-01-24 17:00:36 +0100 | [diff] [blame] | 3206 | 2017-01-24 Werner Lemberg <wl@gnu.org> |
| 3207 | |
Werner Lemberg | 1439712 | 2017-01-24 20:48:50 +0100 | [diff] [blame] | 3208 | [sfnt] Fix Postscript name service for symbol fonts. |
| 3209 | |
| 3210 | * src/sfnt/sfdriver.c (sfnt_get_ps_name): Accept PID/EID=3/0 |
| 3211 | entries also. |
| 3212 | |
| 3213 | 2017-01-24 Werner Lemberg <wl@gnu.org> |
| 3214 | |
Werner Lemberg | 141f0ea | 2017-01-24 17:00:36 +0100 | [diff] [blame] | 3215 | [truetype] For OpenType 1.7: s/preferred/typographic/ (sub)family. |
| 3216 | |
| 3217 | * include/freetype/ftsnames.h |
| 3218 | (FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_FAMILY, |
| 3219 | FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_SUBFAMILY): New macros. |
| 3220 | (FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY, |
| 3221 | FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY): Deprecated. |
| 3222 | |
| 3223 | * include/freetype/ttnameid.h (TT_NAME_ID_TYPOGRAPHIC_FAMILY, |
| 3224 | TT_NAME_ID_TYPOGRAPHIC_SUBFAMILY): New macros. |
| 3225 | (TT_NAME_ID_PREFERRED_FAMILY, TT_NAME_ID_PREFERRED_SUBFAMILY): |
| 3226 | Deprecated. |
| 3227 | |
| 3228 | * src/sfnt/sfobjs.c (sfnt_load_face): Updated. |
| 3229 | |
| 3230 | * docs/CHANGES: Updated. |
| 3231 | |
Werner Lemberg | 79d52b9 | 2017-01-23 07:43:56 +0100 | [diff] [blame] | 3232 | 2017-01-23 Werner Lemberg <wl@gnu.org> |
| 3233 | |
Werner Lemberg | 693f56f | 2017-01-23 12:53:18 +0100 | [diff] [blame] | 3234 | [base] Add `FT_Set_Default_Properties' (#49187). |
| 3235 | |
| 3236 | * include/freetype/ftmodapi.h: Add declaration. |
| 3237 | |
| 3238 | * src/base/ftinit.c (ft_set_default_properties): Renamed to... |
| 3239 | (FT_Set_Default_Properties): ... this. |
| 3240 | (FT_Init_FreeType): Updated. |
| 3241 | |
| 3242 | * docs/CHANGES: Updated. |
| 3243 | |
| 3244 | 2017-01-23 Werner Lemberg <wl@gnu.org> |
| 3245 | |
Werner Lemberg | f502092 | 2017-01-23 11:47:40 +0100 | [diff] [blame] | 3246 | [truetype] Minor updates for OpenType 1.8.1. |
| 3247 | |
| 3248 | * src/truetype/ttgxvar.h (GX_MVarTable): `axisCount' has been |
Alexei Podtelezhnikov | 983fb0d | 2017-01-24 23:56:59 -0500 | [diff] [blame] | 3249 | removed from the specification; it is now reserved. |
Werner Lemberg | f502092 | 2017-01-23 11:47:40 +0100 | [diff] [blame] | 3250 | |
| 3251 | * src/truetype/ttgxvar.c (ft_var_load_mvar): Updated. |
| 3252 | (GX_FVar_Head): Remove `countSizePairs'; the corresponding data |
| 3253 | field in the `MVAR' table is now reserved. |
| 3254 | (fvar_fields): Updated. |
| 3255 | |
| 3256 | 2017-01-23 Werner Lemberg <wl@gnu.org> |
| 3257 | |
Werner Lemberg | 79d52b9 | 2017-01-23 07:43:56 +0100 | [diff] [blame] | 3258 | [truetype] Avoid segfault for invalid variation data. |
| 3259 | |
| 3260 | * src/truetype/ttgxvar.c (ft_var_load_item_variation_store): Assure |
| 3261 | `itemCount' is not zero. |
| 3262 | |
| 3263 | Reported as |
| 3264 | |
| 3265 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=441 |
| 3266 | |
Werner Lemberg | 43061d6 | 2017-01-20 10:16:38 +0100 | [diff] [blame] | 3267 | 2017-01-20 Werner Lemberg <wl@gnu.org> |
| 3268 | |
| 3269 | * src/truetype/ttinterp.c (TT_RunIns): Adjust loop detector limits. |
| 3270 | |
Werner Lemberg | ba6f3e1 | 2017-01-17 11:50:09 +0100 | [diff] [blame] | 3271 | 2017-01-17 Werner Lemberg <wl@gnu.org> |
| 3272 | |
| 3273 | * include/freetype/ttnameid.h: Updated to OpenType 1.8.1. |
| 3274 | |
| 3275 | (TT_APPLE_ID_FULL_UNICODE): New macro. |
| 3276 | |
| 3277 | (TT_MS_LANGID_BOSNIAN_BOSNIA_HERZ_CYRILLIC, |
| 3278 | TT_MS_LANGID_UPPER_SORBIAN_GERMANY, |
| 3279 | TT_MS_LANGID_LOWER_SORBIAN_GERMANY, TT_MS_LANGID_IRISH_IRELAND, |
| 3280 | TT_MS_LANGID_INUKTITUT_CANADA_LATIN, TT_MS_LANGID_BASHKIR_RUSSIA, |
| 3281 | TT_MS_LANGID_LUXEMBOURGISH_LUXEMBOURG, |
| 3282 | TT_MS_LANGID_GREENLANDIC_GREENLAND, TT_MS_LANGID_MAPUDUNGUN_CHILE, |
| 3283 | TT_MS_LANGID_MOHAWK_MOHAWK, TT_MS_LANGID_BRETON_FRANCE, |
| 3284 | TT_MS_LANGID_OCCITAN_FRANCE, TT_MS_LANGID_CORSICAN_FRANCE, |
| 3285 | TT_MS_LANGID_ALSATIAN_FRANCE, TT_MS_LANGID_YAKUT_RUSSIA, |
| 3286 | TT_MS_LANGID_KICHE_GUATEMALA, TT_MS_LANGID_KINYARWANDA_RWANDA, |
| 3287 | TT_MS_LANGID_WOLOF_SENEGAL, TT_MS_LANGID_DARI_AFGHANISTAN): New |
| 3288 | macros. |
| 3289 | |
| 3290 | (TT_MS_LANGID_SERBIAN_BOSNIA_HERZ_CYRILLIC): Fix value. |
| 3291 | |
| 3292 | (TT_MS_LANGID_GERMAN_LIECHTENSTEIN, TT_MS_LANGID_CATALAN_CATALAN, |
| 3293 | TT_MS_LANGID_CHINESE_MACAO, TT_MS_LANGID_SPANISH_SPAIN_MODERN_SORT, |
| 3294 | TT_MS_LANGID_KOREAN_KOREA, TT_MS_LANGID_ROMANSH_SWITZERLAND, |
| 3295 | TT_MS_LANGID_SLOVENIAN_SLOVENIA, TT_MS_LANGID_BASQUE_BASQUE, |
| 3296 | TT_MS_LANGID_SETSWANA_SOUTH_AFRICA, |
| 3297 | TT_MS_LANGID_ISIXHOSA_SOUTH_AFRICA, |
| 3298 | TT_MS_LANGID_ISIZULU_SOUTH_AFRICA, TT_MS_LANGID_KAZAKH_KAZAKHSTAN, |
| 3299 | TT_MS_LANGID_KYRGYZ_KYRGYZSTAN, TT_MS_LANGID_KISWAHILI_KENYA, |
| 3300 | TT_MS_LANGID_TATAR_RUSSIA, TT_MS_LANGID_ODIA_INDIA, |
| 3301 | TT_MS_LANGID_MONGOLIAN_PRC, TT_MS_LANGID_TIBETAN_PRC, |
| 3302 | TT_MS_LANGID_WELSH_UNITED_KINGDOM, TT_MS_LANGID_GALICIAN_GALICIAN, |
| 3303 | TT_MS_LANGID_SINHALA_SRI_LANKA, TT_MS_LANGID_TAMAZIGHT_ALGERIA, |
| 3304 | TT_MS_LANGID_SESOTHO_SA_LEBOA_SOUTH_AFRICA, TT_MS_LANGID_YI_PRC, |
| 3305 | TT_MS_LANGID_UIGHUR_PRC): New aliases. |
| 3306 | |
| 3307 | Remove commented out code. |
| 3308 | |
| 3309 | (TT_NAME_ID_LIGHT_BACKGROUND, TT_NAME_ID_DARK_BACKGROUND, |
| 3310 | TT_NAME_ID_VARIATIONS_PREFIX): New macros. |
| 3311 | |
| 3312 | (HAVE_LIMIT_ON_IDENTS): Remove macro (which was useless since many |
| 3313 | years), use guarded long macros by default and define short versions |
| 3314 | as aliases for the long ones. |
| 3315 | |
Werner Lemberg | 322b3be | 2017-01-15 13:57:25 +0100 | [diff] [blame] | 3316 | 2017-01-15 Werner Lemberg <wl@gnu.org> |
| 3317 | |
| 3318 | * src/truetype/ttgxvar.c (tt_apply_var): Handle underline parameters |
| 3319 | also. |
| 3320 | |
Werner Lemberg | 8ab08cf | 2017-01-11 10:05:27 +0100 | [diff] [blame] | 3321 | 2017-01-11 Werner Lemberg <wl@gnu.org> |
| 3322 | |
Werner Lemberg | c529885 | 2017-01-12 08:42:55 +0100 | [diff] [blame] | 3323 | * src/base/ftobjs.c (ft_open_face_internal): Improve tracing. |
| 3324 | |
| 3325 | 2017-01-11 Werner Lemberg <wl@gnu.org> |
| 3326 | |
Werner Lemberg | 723aafb | 2017-01-11 14:21:26 +0100 | [diff] [blame] | 3327 | [truetype] Actually use metrics variation service. |
| 3328 | |
| 3329 | * src/base/ftmm.c: Include FT_SERVICE_METRICS_VARIATIONS_H. |
| 3330 | (ft_face_get_mvar_service): New auxiliary function to look up |
| 3331 | metrics variation service. |
| 3332 | (FT_Set_Var_Design_Coordinates, FT_Set_MM_Blend_Coordinates, |
| 3333 | FT_Set_Var_Blend_Coordinates): Call metrics variation service. |
| 3334 | |
| 3335 | * src/truetype/ttobjs.c (tt_face_init): Use metrics variations for |
| 3336 | named instances. |
| 3337 | |
| 3338 | 2017-01-11 Werner Lemberg <wl@gnu.org> |
| 3339 | |
Werner Lemberg | d718ac4 | 2017-01-11 14:12:34 +0100 | [diff] [blame] | 3340 | [truetype] Provide metrics variation service. |
| 3341 | |
| 3342 | * include/freetype/internal/services/svmetric.h |
| 3343 | (FT_Metrics_Adjust_Func): Reduce number of necessary parameters. |
| 3344 | |
| 3345 | * src/truetype/ttgxvar.c: Include FT_LIST_H. |
| 3346 | (tt_size_reset_iterator): New auxiliary function for... |
| 3347 | (tt_apply_var): New function. |
| 3348 | |
| 3349 | * src/truetype/ttgxvar.h: Updated. |
| 3350 | |
| 3351 | * src/truetype/ttdriver.c (tt_service_metrics_variations): Add |
| 3352 | `tt_apply_mvar'. |
| 3353 | |
| 3354 | * include/freetype/internal/ftserv.h (FT_ServiceCache): Add metrics |
| 3355 | variation service. |
| 3356 | |
| 3357 | 2017-01-11 Werner Lemberg <wl@gnu.org> |
| 3358 | |
Werner Lemberg | 07ee1d2 | 2017-01-11 12:50:51 +0100 | [diff] [blame] | 3359 | [truetype] Parse `MVAR' table. |
| 3360 | |
| 3361 | * src/truetype/ttgxvar.h (MVAR_TAG_XXX): New macros for MVAR tags. |
| 3362 | (GX_Value, GX_MVarTable): New structures. |
| 3363 | (GX_Blend): Add it. |
| 3364 | |
| 3365 | * src/truetype/ttgxvar.c (GX_VALUE_SIZE, GX_VALUE_CASE, |
| 3366 | GX_GASP_CASE): New macros. |
| 3367 | (ft_var_get_value_pointer): New auxiliary function to get a pointer |
| 3368 | to a value from various SFNT tables already stored in `TT_Face'. |
| 3369 | (ft_var_load_mvar): New function. |
| 3370 | (TT_Get_MM_Var): Call it. |
| 3371 | (tt_done_blend): Updated. |
| 3372 | |
| 3373 | 2017-01-11 Werner Lemberg <wl@gnu.org> |
| 3374 | |
Werner Lemberg | 8ab08cf | 2017-01-11 10:05:27 +0100 | [diff] [blame] | 3375 | [truetype] More preparations for MVAR support. |
| 3376 | |
| 3377 | * src/truetype/ttobjs.c (tt_size_reset): Add argument to make |
| 3378 | function only recompute ascender, descender, and height. |
| 3379 | |
| 3380 | * src/truetype/ttobjs.h: Updated. |
| 3381 | |
| 3382 | * src/truetype/ttdriver.c (tt_size_select, tt_size_request): |
| 3383 | Updated. |
| 3384 | |
Werner Lemberg | f837a50 | 2017-01-09 10:49:03 +0100 | [diff] [blame] | 3385 | 2017-01-09 Werner Lemberg <wl@gnu.org> |
| 3386 | |
Werner Lemberg | 7ccca6a | 2017-01-09 19:54:44 +0100 | [diff] [blame] | 3387 | [pcf] Disable long family names by default. |
| 3388 | |
| 3389 | * include/freetype/config/ftoption.h |
| 3390 | (PCF_CONFIG_OPTION_LONG_FAMILY_NAMES): Comment out. |
| 3391 | |
| 3392 | 2017-01-09 Werner Lemberg <wl@gnu.org> |
| 3393 | |
Werner Lemberg | 08fd250 | 2017-01-09 11:30:32 +0100 | [diff] [blame] | 3394 | [pcf] Make long family names configurable. |
| 3395 | |
| 3396 | The change from 2016-09-29 was too radical (except for people using |
| 3397 | the openSuSE GNU/Linux distribution). To ameliorate the situation, |
| 3398 | PCF_CONFIG_OPTION_LONG_FAMILY_NAMES gets introduced which controls |
| 3399 | the feature; if set, a new PCF property option |
| 3400 | `no-long-family-names' can be used to switch this feature off. |
| 3401 | |
| 3402 | * include/freetype/config/ftoption.h, devel/ftoption.h |
| 3403 | (PCF_CONFIG_OPTION_LONG_FAMILY_NAMES): New option. |
| 3404 | |
| 3405 | * include/freetype/ftpcfdrv.h: New header file (only containing |
| 3406 | comments currently, used for building the documentation). |
| 3407 | |
| 3408 | * include/freetype/config/ftheader.h (FT_PCF_DRIVER_H): New macro. |
| 3409 | |
| 3410 | * src/pcf/pcf.h (PCF_Driver): Add `no_long_family_names' field. |
| 3411 | |
| 3412 | * src/pcf/pcfdrivr.c: Include FT_SERVICE_PROPERTIES_H and |
| 3413 | FT_PCF_DRIVER_H. |
| 3414 | (pcf_property_set, pcf_property_get): New functions. |
| 3415 | (pcf_service_properties): New service. |
Alexei Podtelezhnikov | 236bbdb | 2017-01-18 23:12:31 -0500 | [diff] [blame] | 3416 | (pcf_services): Updated. |
Werner Lemberg | 08fd250 | 2017-01-09 11:30:32 +0100 | [diff] [blame] | 3417 | (pcf_driver_init) [PCF_CONFIG_OPTION_LONG_FAMILY_NAMES]: Handle |
| 3418 | `no_long_family_names'. |
| 3419 | |
| 3420 | * src/pcf/pcfread.c (pcf_load_font): Handle `no_long_family_names' |
| 3421 | and PCF_CONFIG_OPTION_LONG_FAMILY_NAMES. |
| 3422 | |
| 3423 | * docs/CHANGES: Updated. |
| 3424 | |
| 3425 | 2017-01-09 Werner Lemberg <wl@gnu.org> |
| 3426 | |
Werner Lemberg | f837a50 | 2017-01-09 10:49:03 +0100 | [diff] [blame] | 3427 | [pcf] Introduce a driver structure. |
| 3428 | |
| 3429 | To be filled later on with something useful. |
| 3430 | |
| 3431 | * src/pcf/pcf.h (PCF_Driver): New structure. |
| 3432 | |
| 3433 | * src/pcf/pcfdrivr.c (pcf_driver_init, pcf_driver_done): New dummy |
| 3434 | functions. |
| 3435 | (pcf_driver_class): Updated. |
| 3436 | |
Werner Lemberg | 6812f17 | 2017-01-08 07:33:05 +0100 | [diff] [blame] | 3437 | 2017-01-08 Werner Lemberg <wl@gnu.org> |
| 3438 | |
Werner Lemberg | 469ced7 | 2017-01-08 09:28:34 +0100 | [diff] [blame] | 3439 | [truetype] Again some GX code shuffling. |
| 3440 | |
| 3441 | We need this later on for MVAR also. |
| 3442 | |
| 3443 | * src/truetype/ttgxvar.c (tt_hadvance_adjust): Split off computing |
| 3444 | an item store variation delta into... |
| 3445 | (ft_var_get_item_delta): ...new function. |
| 3446 | |
| 3447 | 2017-01-08 Werner Lemberg <wl@gnu.org> |
| 3448 | |
Werner Lemberg | 6812f17 | 2017-01-08 07:33:05 +0100 | [diff] [blame] | 3449 | [truetype] Adjust font variation flags for MVAR. |
| 3450 | |
| 3451 | * include/freetype/internal/tttypes.h (TT_FACE_FLAG_VAR_XXX): |
| 3452 | Remove all flags related to MVAR; replace it with... |
| 3453 | (TT_FACE_FLAG_VAR_MVAR): ...this new macro. |
| 3454 | (TT_Face): Remove `mvar_support' field (which was still unused). |
| 3455 | |
Werner Lemberg | 8b75544 | 2017-01-06 11:47:55 +0100 | [diff] [blame] | 3456 | 2017-01-06 Werner Lemberg <wl@gnu.org> |
| 3457 | |
Werner Lemberg | 0291913 | 2017-01-07 07:45:28 +0100 | [diff] [blame] | 3458 | [truetype] More GX code shuffling. |
| 3459 | |
| 3460 | We need this later on for MVAR also. |
| 3461 | |
| 3462 | * src/truetype/ttgxvar.c (tt_done_blend): Split off handling of item |
| 3463 | variation store into... |
| 3464 | (ft_var_done_item_variation_store): ...new function. |
| 3465 | |
| 3466 | 2017-01-06 Werner Lemberg <wl@gnu.org> |
| 3467 | |
Werner Lemberg | fb90f00 | 2017-01-06 22:23:52 +0100 | [diff] [blame] | 3468 | [truetype] More generalization of GX stuff. |
| 3469 | |
| 3470 | We need this later on for MVAR also. |
| 3471 | |
| 3472 | * src/truetype/ttgxvar.c (ft_var_load_delta_set_index_mapping): Add |
| 3473 | parameters for delta-set index mapping and item variation store. |
| 3474 | (ft_var_load_item_variation_store): Add parameter for item variation |
| 3475 | store. |
| 3476 | s/hvarData/varData/. |
| 3477 | Move allocation of `hvar_table' to... |
| 3478 | (ft_var_load_hvar): ...this function. |
| 3479 | Updated. |
| 3480 | |
| 3481 | 2017-01-06 Werner Lemberg <wl@gnu.org> |
| 3482 | |
Werner Lemberg | 0bd0112 | 2017-01-06 21:32:49 +0100 | [diff] [blame] | 3483 | [truetype] Some GX structure renames for generalization. |
| 3484 | |
| 3485 | We need this later on for MVAR also. |
| 3486 | |
| 3487 | * src/truetype/ttgxvar.h (GX_HVarData): Renamed to... |
| 3488 | (GX_ItemVarData): ...this. |
| 3489 | (GX_HVarRegion): Renamed to... |
| 3490 | (GX_VarRegion): ...this. |
| 3491 | (GX_HVStore): Renamed to... |
| 3492 | (GX_ItemVarStore): ...this. |
| 3493 | (GX_WidthMap): Renamed to... |
| 3494 | (GX_DeltaSetIdxMap): ...this. |
| 3495 | |
| 3496 | (GX_HVarTable): Updated. |
| 3497 | |
| 3498 | * src/truetype/ttgxvar.c: Updated. |
| 3499 | |
| 3500 | 2017-01-06 Werner Lemberg <wl@gnu.org> |
| 3501 | |
Werner Lemberg | 9c81470 | 2017-01-06 21:13:36 +0100 | [diff] [blame] | 3502 | [truetype] Code shuffling. |
| 3503 | |
Werner Lemberg | 0291913 | 2017-01-07 07:45:28 +0100 | [diff] [blame] | 3504 | * src/truetype/ttgxvar.c (ft_var_load_hvar): Split off loading of |
| 3505 | item variation store and delta set index mapping into... |
Werner Lemberg | 9c81470 | 2017-01-06 21:13:36 +0100 | [diff] [blame] | 3506 | (ft_var_load_item_variation_store, |
Werner Lemberg | 0291913 | 2017-01-07 07:45:28 +0100 | [diff] [blame] | 3507 | ft_var_load_delta_set_index_mapping): ...new functions. |
Werner Lemberg | 9c81470 | 2017-01-06 21:13:36 +0100 | [diff] [blame] | 3508 | |
| 3509 | 2017-01-06 Werner Lemberg <wl@gnu.org> |
| 3510 | |
Werner Lemberg | 7e1cce5 | 2017-01-06 20:31:22 +0100 | [diff] [blame] | 3511 | [truetype] Add HVAR access without advance width map. |
| 3512 | |
| 3513 | * src/truetype/ttgxvar.c (ft_var_load_hvar): Handle case where |
| 3514 | `offsetToAdvanceWidthMapping' is zero. |
| 3515 | (tt_hadvance_adjust): Implement direct deltaSet access by glyph |
| 3516 | index. |
| 3517 | |
| 3518 | 2017-01-06 Werner Lemberg <wl@gnu.org> |
| 3519 | |
Werner Lemberg | 8b75544 | 2017-01-06 11:47:55 +0100 | [diff] [blame] | 3520 | [pcf] Revise driver. |
| 3521 | |
| 3522 | This commit improves tracing and handling of malformed fonts. In |
| 3523 | particular, the changes to `pcf_get_properties' fix |
| 3524 | |
| 3525 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=379 |
| 3526 | |
| 3527 | * src/pcf/pcfread.c (tableNames): Use long names for better |
| 3528 | readability. |
| 3529 | (pcf_read_TOC): Allow at most 9 tables. |
| 3530 | (pcf_get_properties): Allow at most 256 properties. |
| 3531 | Limit strings array length to 256 * (65536 + 1) bytes. |
| 3532 | Better tracing. |
| 3533 | (pcf_get_metric): Trace metric data. |
| 3534 | (pcf_get_metrics): Allow at most 65536 metrics. |
| 3535 | Fix comparison of `metrics->ascent' and `metrics->descent' to avoid |
| 3536 | potential overflow. |
| 3537 | Better tracing. |
| 3538 | (pcf_get_bitmaps): Allow at most 65536 bitmaps. |
| 3539 | Better tracing. |
| 3540 | (pcf_get_encodings, pcf_get_accel): Better tracing. |
| 3541 | |
| 3542 | * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Don't trace `format' details. |
| 3543 | These are now shown by `pcf_get_bitmaps'. |
| 3544 | |
Werner Lemberg | 025226a | 2017-01-04 07:45:44 +0100 | [diff] [blame] | 3545 | 2017-01-04 Werner Lemberg <wl@gnu.org> |
| 3546 | |
Werner Lemberg | a7c2f44 | 2017-01-04 13:12:03 +0100 | [diff] [blame] | 3547 | * src/pcf/pcfdrivr.c (PCF_Face_Init): Trace compression format. |
| 3548 | |
| 3549 | 2017-01-04 Werner Lemberg <wl@gnu.org> |
| 3550 | |
Werner Lemberg | c9d4772 | 2017-01-04 10:00:49 +0100 | [diff] [blame] | 3551 | [cff] More consistency checks for pure CFFs. |
| 3552 | |
| 3553 | Reported as |
| 3554 | |
| 3555 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=378 |
| 3556 | |
| 3557 | * src/cff/cffload.c (cff_font_load): Check element number and size |
| 3558 | of Name and Top DICT indices. |
| 3559 | |
| 3560 | 2017-01-04 Werner Lemberg <wl@gnu.org> |
| 3561 | |
Werner Lemberg | 025226a | 2017-01-04 07:45:44 +0100 | [diff] [blame] | 3562 | [cff, truetype] Minor tracing improvement. |
| 3563 | |
| 3564 | * src/cff/cffobjs.c (cff_face_init), src/truetype/ttobjs.c |
| 3565 | (tt_face_init): Indent first tracing message from SFNT driver. |
| 3566 | |
Werner Lemberg | 248eaa4 | 2017-01-03 00:27:07 +0100 | [diff] [blame] | 3567 | 2017-01-03 Werner Lemberg <wl@gnu.org> |
| 3568 | |
Werner Lemberg | 8982405 | 2017-01-03 09:46:19 +0100 | [diff] [blame] | 3569 | [truetype] Various minor fixes. |
| 3570 | |
| 3571 | * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Check instruction |
| 3572 | size only if we do native hinting. |
| 3573 | (TT_Load_Glyph): Trace returned error code. |
| 3574 | |
| 3575 | * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Trace |
| 3576 | returned error code. |
| 3577 | (tt_size_ready_bytecode): Don't run `prep' table if `fpgm' table is |
| 3578 | invalid. |
| 3579 | |
| 3580 | 2017-01-03 Werner Lemberg <wl@gnu.org> |
| 3581 | |
Werner Lemberg | 624b680 | 2017-01-03 09:42:41 +0100 | [diff] [blame] | 3582 | [sfnt] Don't fail if PCLT, EBLC (and similar tables) are invalid. |
| 3583 | |
| 3584 | These tables are optional. |
| 3585 | |
| 3586 | * src/sfnt/sfobjs.c (sfnt_load_face): Implement it. |
| 3587 | |
| 3588 | 2017-01-03 Werner Lemberg <wl@gnu.org> |
| 3589 | |
Werner Lemberg | 69414e7 | 2017-01-03 06:53:13 +0100 | [diff] [blame] | 3590 | * src/cff/cffparse.c (cff_parse_num): Simplify. |
| 3591 | |
| 3592 | 2017-01-03 Werner Lemberg <wl@gnu.org> |
| 3593 | |
Werner Lemberg | 248eaa4 | 2017-01-03 00:27:07 +0100 | [diff] [blame] | 3594 | Various fixes for clang's undefined behaviour sanitizer. |
| 3595 | |
| 3596 | * src/cff/cffload.c (FT_fdot14ToFixed): Fix casting. |
| 3597 | (cff_blend_doBlend): Don't left-shift negative numbers. |
| 3598 | Handle 5-byte numbers byte by byte to avoid alignment issues. |
| 3599 | |
Werner Lemberg | 69414e7 | 2017-01-03 06:53:13 +0100 | [diff] [blame] | 3600 | * src/cff/cffparse.c (cff_parse_num): Handle 5-byte numbers byte by |
| 3601 | byte to avoid alignment issues. |
Werner Lemberg | 248eaa4 | 2017-01-03 00:27:07 +0100 | [diff] [blame] | 3602 | |
| 3603 | * src/cid/cidload (cid_read_subrs): Do nothing if we don't have any |
| 3604 | subrs. |
| 3605 | |
| 3606 | * src/psaux/t1decode.c (t1_decode_parse_charstring): Fix tracing. |
| 3607 | |
| 3608 | * src/tools/glnames.py (main): Put `DEFINE_PSTABLES' guard around |
| 3609 | definition of `ft_get_adobe_glyph_index'. |
| 3610 | |
| 3611 | * src/psnames/pstables.h: Regenerated. |
| 3612 | |
Alexei Podtelezhnikov | 236bbdb | 2017-01-18 23:12:31 -0500 | [diff] [blame] | 3613 | * src/psnames/psmodule.c: Include `pstables.h' twice to get both |
Werner Lemberg | 248eaa4 | 2017-01-03 00:27:07 +0100 | [diff] [blame] | 3614 | declaration and definition. |
| 3615 | |
| 3616 | * src/truetype/ttgxvar.c (FT_fdot14ToFixed, FT_intToFixed): Fix |
| 3617 | casting. |
| 3618 | |
Werner Lemberg | 63765a8 | 2017-01-01 10:43:41 +0100 | [diff] [blame] | 3619 | 2017-01-01 Werner Lemberg <wl@gnu.org> |
| 3620 | |
Werner Lemberg | bdec162 | 2017-01-01 20:51:55 +0100 | [diff] [blame] | 3621 | [cff] Handle multiple `blend' operators in a row correctly. |
| 3622 | |
| 3623 | Reported as |
| 3624 | |
| 3625 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=368 |
| 3626 | |
| 3627 | * src/cff/cffload.c (cff_blend_doBlend): Adjust `parser->stack' |
| 3628 | pointers into `subFont->blend_stack' after reallocation. |
| 3629 | |
| 3630 | 2017-01-01 Werner Lemberg <wl@gnu.org> |
| 3631 | |
Werner Lemberg | 63765a8 | 2017-01-01 10:43:41 +0100 | [diff] [blame] | 3632 | [sfnt] Return correct number of named instances for TTCs. |
| 3633 | |
| 3634 | Without this patch, requesting information for face index N returned |
| 3635 | the data for face index N+1 (or index 0). |
| 3636 | |
| 3637 | * src/sfnt/sfobjs.c (sfnt_init_face): Correctly adjust `face_index' |
| 3638 | for negative `face_instance_index' values. |
| 3639 | |
Werner Lemberg | e9a154e | 2016-12-31 21:41:08 +0100 | [diff] [blame] | 3640 | 2016-12-31 Werner Lemberg <wl@gnu.org> |
| 3641 | |
Werner Lemberg | 24be60b | 2017-01-01 08:20:38 +0100 | [diff] [blame] | 3642 | */*: Use hex numbers for errors in tracing messages. |
| 3643 | |
| 3644 | 2016-12-31 Werner Lemberg <wl@gnu.org> |
| 3645 | |
Werner Lemberg | e9a154e | 2016-12-31 21:41:08 +0100 | [diff] [blame] | 3646 | [truetype] Check axis count in HVAR table. |
| 3647 | |
| 3648 | Reported as |
| 3649 | |
| 3650 | https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=362 |
| 3651 | |
| 3652 | * src/truetype/ttgxvar.c (ft_var_load_hvar): Check axis count. |
| 3653 | (ft_var_load_avar): Fix tracing message. |
| 3654 | |
Werner Lemberg | f6aa089 | 2013-05-10 07:58:47 +0200 | [diff] [blame] | 3655 | |
Werner Lemberg | 8e6c56f | 2005-10-18 06:09:13 +0000 | [diff] [blame] | 3656 | ---------------------------------------------------------------------------- |
| 3657 | |
Werner Lemberg | 563ae78 | 2017-01-04 20:16:34 +0100 | [diff] [blame] | 3658 | Copyright 2016-2017 by |
Werner Lemberg | 8e6c56f | 2005-10-18 06:09:13 +0000 | [diff] [blame] | 3659 | David Turner, Robert Wilhelm, and Werner Lemberg. |
| 3660 | |
| 3661 | This file is part of the FreeType project, and may only be used, modified, |
| 3662 | and distributed under the terms of the FreeType project license, |
| 3663 | LICENSE.TXT. By continuing to use, modify, or distribute this file you |
| 3664 | indicate that you have read the license and understand and accept it |
| 3665 | fully. |
| 3666 | |
| 3667 | |
| 3668 | Local Variables: |
| 3669 | version-control: never |
Werner Lemberg | 4e03fe7 | 2006-04-29 06:20:09 +0000 | [diff] [blame] | 3670 | coding: utf-8 |
Werner Lemberg | 8e6c56f | 2005-10-18 06:09:13 +0000 | [diff] [blame] | 3671 | End: |