|
8cd31eb7
|
2017-05-03T23:54:29
|
|
*/*: s/backwards compatibility/backward compatibility/.
|
|
ba40054c
|
2017-05-02T12:32:19
|
|
[autofit] Remove `slight' auto-hint mode again.
A poll on freetype-devel favoured changes directly applied to
`light'.
* include/freetype/freetype.h (FT_LOAD_TARGET_SLIGHT,
FT_RENDER_MODE_SLIGHT): Removed.
* src/autofit/afcjk.c (af_cjk_hints_init), src/autofit/aflatin.c
(af_latin_hints_init), src/autofit/aflatin2.c
(af_latin2_hints_init): Revert change from 2017-04-22.
* src/autofit/afloader.c (af_loader_load_glyph) Remove references to
FT_RENDER_MODE_SLIGHT.
[AF_CONFIG_OPTION_TT_SIZE_METRICS]: Enable TrueType-like metrics
unconditionally.
* src/base/ftadvanc.c (LOAD_ADVANCE_FAST_CHECK): Revert change from
2017-04-22.
* src/base/ftobjs.c (FT_Load_Glyph): Revert change from 2017-04-22.
* src/pshinter/pshalgo.c (ps_hints_apply): Revert change from
2017-04-22.
* src/smooth/ftsmooth.c (ft_smooth_render): Revert change from
2017-04-22.
* docs/CHANGES: Updated.
|
|
7abf0cb7
|
2017-04-30T17:25:11
|
|
[autofit] Fix metrics computation.
Problem reported by Markus Trippelsdorf <markus@trippelsdorf.de> and
Nikolaus Waxweiler <madigens@gmail.com>.
* src/base/ftobjs.c (FT_Request_Size): Trigger recomputation of
auto-hinter metrics. Without this change, multiple size changing
calls for a single face fail.
|
|
5aa6716a
|
2017-04-22T13:27:21
|
|
Add new `slight' auto-hinting mode.
This mode uses fractional advance widths and doesn't scale glyphs
horizontally, only applying vertical scaling and hinting.
At the same time, the behaviour of the `light' auto-hinter gets
restored for backwards compatibility: Both vertical and horizontal
scaling is again based on rounded metrics values (this was changed
in a commit from 2017-03-30 as a side effect). To be more precise,
the behaviour is restored for TrueType fonts only; for other font
formats like Type 1, this is a new feature of the `light' hinting
mode.
* include/freetype/freetype.h (FT_LOAD_TARGET_SLIGHT): New macro.
(FT_RENDER_MODE_SLIGHT): New render mode.
* include/freetype/internal/ftobjs.h (FT_Size_InternalRec): Add
`autohint_mode' and `autohint_metrics' fields.
* src/autofit/afcjk.c (af_cjk_hints_init), src/autofit/aflatin.c
(af_latin_hints_init), src/autofit/aflatin2 (af_latin2_hints_init):
Updated.
* src/autofit/afloader.c (af_loader_embolden_glyph_in_slot): Use
`autohint_metrics'.
(af_loader_load_glyph): s/internal/slot_internal/.
Initialize `autohint_metrics' and `autohint_mode' depending on
current auto-hint mode.
Use `autohint_metrics'.
Updated.
* src/base/ftadvanc.c (LOAD_ADVANCE_FAST_CHECK): Updated.
* src/base/ftobjs.c (FT_Load_Glyph): Updated.
(FT_New_Size): Allocate `internal' object.
* src/pshinter/pshalgo.c (ps_hints_apply): Updated.
* src/smooth/ftsmooth.c (ft_smooth_render): Updated.
|
|
5412d886
|
2017-04-22T12:48:50
|
|
Introduce `FT_Size_InternalRec' structure.
We are going to extend this later on.
* include/freetype/internal/ftobjs.h (FT_Size_InternalRec): New
structure with a single field `module_data'.
* src/base/ftobjs.c (FT_New_Size): Allocate `internal' field of
`FT_Size' structure.
* src/cff/cffgload.c (cff_builder_init, cff_decoder_prepare): Use
`size->internal->module_data' instead of `size->internal'.
* src/cff/cffobjs.c (cff_size_done): Deallocate `module_data'.
(cff_size_init, cff_size_select, cff_size_request): Use
`size->internal->module_data' instead of `size->internal'.
* src/cif/cidobjs.c (cid_size_done, cid_size_init,
cid_size_request): Use `size->internal->module_data' instead of
`size->internal'.
* src/psaux/psobjs.c (t1_builder_ini): Use
`size->internal->module_data' instead of `size->internal'.
* src/type1/t1objs.c (T1_Size_Done, T1_Size_Init, T1_Size_Request):
Use `size->internal->module_data' instead of `size->internal'.
|
|
5efba4c4
|
2017-04-16T07:23:24
|
|
Fix tracing messages.
* src/base/ftobjs.c (FT_Face_GetCharVariantIndex,
FT_Face_GetCharVariantIsDefault, FT_Face_GetVariantsOfChar): Print
correct function name.
|
|
67ff7664
|
2017-03-23T12:41:30
|
|
Make MM fonts work (again).
* src/base/ftmm.c (FT_Set_Var_Design_Coordinates,
FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates): Ignore
return value of `ft_face_get_mvar_service'; instead, check whether a
service is actually returned.
|
|
9931175d
|
2017-03-18T07:06:49
|
|
Improve `make multi'.
* src/autofit/aflatin2.c: Guard file with FT_OPTION_AUTOFIT2.
* src/base/ftmac.c: Guard more parts of the file with FT_MACINTOSH.
* src/psaux/afmparse.c: Guard file with T1_CONFIG_OPTION_NO_AFM.
* src/sfnt/pngshim.c: Guard file with
TT_CONFIG_OPTION_EMBEDDED_BITMAPS also.
* src/sfnt/ttbdf.c: Avoid empty source file.
* src/sfnt/ttpost.c: Guard file with
TT_CONFIG_OPTION_POSTSCRIPT_NAMES.
* src/sfnt/ttsbit.c: Guard file with
TT_CONFIG_OPTION_EMBEDDED_BITMAPS.
* src/truetype/ttgxvar.c, src/truetype/ttinterp.c: Avoid empty
source file.
* src/truetype/ttsubpix.c: Guard file with
TT_USE_BYTECODE_INTERPRETER also.
* src/type1/t1afm.c: Guard file with T1_CONFIG_OPTION_NO_AFM.
* src/autofit/autofit.c, src/base/ftbase.c, src/cache/ftcache.c,
src/cff/cff.c, src/cid/type1cid.c, src/gxvalid/gxvalid.c,
src/pcf/pcf.c, src/pfr/pfr.c, src/psaux/psaux.c,
src/pshinter/pshinter.c, src/psnames/psnames.c, src/raster/raster.c,
src/sfnt/sfnt.c, src/smooth/smooth.c, src/truetype/truetype.c,
src/type1/type1.c, src/type42/type42.c: Remove conditionals; sort
entries.
|
|
bffb7fe9
|
2017-03-17T07:52:30
|
|
`make multi' fixes; compiler warnings.
* src/base/ftsnames.c: Include FT_INTERNAL_DEBUG_H.
* src/cff/cffobjs.c [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Include
FT_MULTIPLE_MASTERS_H and FT_SERVICE_MULTIPLE_MASTERS_H.
* src/sfnt/sfdriver.c [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Include
FT_MULTIPLE_MASTERS_H and FT_SERVICE_MULTIPLE_MASTERS_H.
(get_win_string, get_apple_string): Initialize `result'.
|
|
9357ef80
|
2017-03-15T07:56:22
|
|
Typo: s/stroke/strike/.
|
|
753e1131
|
2017-02-20T09:01:14
|
|
[cff] Introduce `random-seed' property (2/2).
* src/base/ftobjs.c: Include `FT_CFF_DRIVER_H'.
(open_face): Initialize `face->internal->random_seed'.
(FT_Face_Properties): Handle `FT_PARAM_TAG_RANDOM_SEED'.
* src/cff/cffdrivr.c (cff_property_set): Handle `random-seed'
property.
|
|
467b026c
|
2017-02-18T10:42:48
|
|
Remove clang warnings.
* src/autofit/aflatin.c (af_latin_sort_blue): Add missing `static'
keyword.
* src/base/ftmm.c (FT_Set_Var_Design_Coordinates,
FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates):
Initialize some variables.
|
|
2b0ac189
|
2017-02-18T10:42:23
|
|
Add face property for stem darkening.
* include/freetype/ftautoh.h (FT_PARAM_TAG_STEM_DARKENING): New
macro.
* include/freetype/internal/ftobjs.h (FT_Face_InternalRec): Add
`no_stem_darkening' field.
* src/autofit/afloader.c (af_loader_load_glyph),
src/autofit/afmodule.c (af_property_set): Updated.
* src/base/ftobjs.c: Include FT_AUTOHINTER_H.
(ft_open_face_internal): Updated.
(FT_Face_Properties): Handle FT_PARAM_TAG_STEM_DARKENING.
* src/cff/cf2ft.c (cf2_decoder_parse_charstrings): Updated.
* src/cff/cffdrivr.c (cff_property_set): Updated.
|
|
2e951988
|
2017-02-16T20:45:45
|
|
Add face property for LCD filter weights.
* include/freetype/ftlcdfil.h (FT_PARAM_TAG_LCD_FILTER_WEIGHTS,
FT_LCD_FILTER_FIVE_TAPS): New macros.
(FT_LcdFiveTapFilter): New typedef.
* include/freetype/ftobjs.h (FT_Face_InternalRec)
[FT_CONFIG_OPTION_SUBPIXEL_RENDERING]: Add `lcd_weights' field.
(FT_Bitmap_LcdFilterFunc): Change third argument to weights array.
(ft_lcd_filter_fir): New prototype.
(FT_LibraryRec): Updated.
* src/base/ftlcdfil.c (_ft_lcd_filter_fir): Renamed to...
(ft_lcd_filter_dir): ... this base function.
Updated.
(_ft_lcd_filter_legacy): Updated.
(FT_Library_SetLcdFilterWeights, FT_Library_SetLcdFilter): Updated.
* src/base/ftobjs.c (ft_open_face_internal): Updated.
(FT_Face_Properties): Handle FT_PARAM_TAG_LCD_FILTER_WEIGHTS.
* src/smooth/ftsmooth.c (ft_smooth_render_generic)
[FT_CONFIG_OPTION_SUBPIXEL_RENDERING: Handle LCD weights from
`FT_Face_Internal'.
|
|
64cdee73
|
2017-02-15T08:06:35
|
|
Add new function `FT_Face_Properties'.
This commit provides the framework, to be filled with something
useful in the next commits.
* include/freetype/freetype.h (FT_Face_Properties): Declare.
* src/base/ftobjs.c (FT_Face_Properties): New function.
|
|
1e550601
|
2017-01-31T18:47:10
|
|
[base] Fix error handing in MM functions.
* src/base/ftmm.c (FT_Set_Var_Design_Coordinates,
FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates):
Implement it.
|
|
f4253366
|
2017-01-27T00:06:52
|
|
[base] Add `FT_Get_Sfnt_LangTag' function.
* include/freetype/ftsnames.h (FT_SfntLangTag): New structure.
(FT_Get_Sfnt_LangTag): New declaration.
* src/base/ftsnames.c (FT_Get_Sfnt_LangTag): New funtion.
* docs/CHANGES: Updated.
|
|
f4e56966
|
2017-01-25T15:08:41
|
|
[sfnt] s/TT_NameEntry/TT_Name/.
* include/freetype/internal/tttypes.h (TT_NameEntryRec): Renamed
to...
(TT_NameRec): This.
(TT_NameTableRec): Updated.
* src/base/ftsnames.c (FT_Get_Sfnt_Name): Updated.
* src/sfnt/sfdriver.c (sfnt_get_ps_name): Updated.
* src/sfnt/sfobjs.c (tt_name_entry_ascii_from_utf16,
tt_name_entry_ascii_from_other): Renamed to...
(tt_name_ascii_from_utf16, tt_name_entry_ascii_from_other): This,
respectively.
(TT_NameEntry_ConvertFunc): Renamed to...
(TT_Name_ConvertFunc): This.
(tt_face_get_name): Updated.
* src/sfnt/ttload.c (tt_face_load_name, tt_face_free_names):
Updated.
|
|
983fb0df
|
2017-01-24T23:56:59
|
|
Typos.
|
|
693f56ff
|
2017-01-23T12:53:18
|
|
[base] Add `FT_Set_Default_Properties' (#49187).
* include/freetype/ftmodapi.h: Add declaration.
* src/base/ftinit.c (ft_set_default_properties): Renamed to...
(FT_Set_Default_Properties): ... this.
(FT_Init_FreeType): Updated.
* docs/CHANGES: Updated.
|
|
a32270ae
|
2017-01-19T23:01:44
|
|
Typos.
|
|
c529885b
|
2017-01-12T08:42:55
|
|
* src/base/ftobjs.c (ft_open_face_internal): Improve tracing.
|
|
723aafb5
|
2017-01-11T14:21:26
|
|
[truetype] Actually use metrics variation service.
* src/base/ftmm.c: Include FT_SERVICE_METRICS_VARIATIONS_H.
(ft_face_get_mvar_service): New auxiliary function to look up
metrics variation service.
(FT_Set_Var_Design_Coordinates, FT_Set_MM_Blend_Coordinates,
FT_Set_Var_Blend_Coordinates): Call metrics variation service.
* src/truetype/ttobjs.c (tt_face_init): Use metrics variations for
named instances.
|
|
563ae780
|
2017-01-04T20:16:34
|
|
Update copyright year.
|
|
24be60b5
|
2017-01-01T08:20:38
|
|
*/*: Use hex numbers for errors in tracing messages.
|
|
f80c4473
|
2016-12-26T23:57:45
|
|
Replace `++foo' and `--foo' with `foo++' and `foo--', resp.
|
|
4441f7b2
|
2016-12-26T17:08:17
|
|
Replace `foo == NULL' and `foo != NULL' with `!foo' and `foo', resp.
Other minor formatting.
|
|
37c72f66
|
2016-12-25T22:55:25
|
|
Minor formatting.
|
|
7f733399
|
2016-12-22T10:12:17
|
|
* src/base/ftrfork.c (FT_Raccess_Get_DataOffsets): Check `count'.
Reported as
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=308
|
|
d44daf9e
|
2016-12-21T23:03:48
|
|
* src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Thinko.
Don't apply deltas twice for non-phantom points.
Spotted by Ben Wagner.
|
|
57a6733d
|
2016-12-21T06:52:23
|
|
[base] Improve sanity check for Mac resources (#49888).
* src/base/ftobjs.c (Mac_Read_sfnt_Resource): Abort if `rlen' is not
positive.
|
|
ded4bdb5
|
2016-12-20T23:26:38
|
|
[base] More sanity checks for Mac resources.
We use
https://github.com/kreativekorp/ksfl/wiki/Macintosh-Resource-File-Format
and
https://developer.apple.com/legacy/library/documentation/mac/pdf/MoreMacintoshToolbox.pdf#page=151
as references.
* include/freetype/internal/ftrfork.h (FT_RFork_Ref): Use FT_Short
for `res_id'.
* src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Extract map length
and use it to improve sanity checks.
Follow the specification more closely;in particular, all data types
are signed, not unsigned.
(FT_Raccess_Get_DataOffsets): Follow the specification more closely;
in particular, all data types are signed, not unsigned.
Add some sanity checks.
|
|
b5573032
|
2016-12-20T23:22:06
|
|
ftobjs.c: Formatting.
|
|
d5fe8da7
|
2016-12-20T22:03:40
|
|
Spelling.
|
|
a1e85f11
|
2016-12-20T10:52:26
|
|
[cff, truetype] Fast advance width retrieval for fonts with HVAR.
Everything is guarded with TT_CONFIG_OPTION_GX_VAR_SUPPORT.
* src/base/ftadvanc.c (LOAD_ADVANCE_FAST_CHECK): Don't handle MM.
* src/cff/cffdrivr.c: Include FT_SERVICE_METRICS_VARIATIONS_H.
(cff_get_advances): Test for HVAR and VVAR.
* src/truetype/ttdriver.c (tt_get_advances): Test for HVAR and VVAR.
|
|
5743df77
|
2016-12-18T21:01:03
|
|
[base] Fix invalid mac font recursion.
Reported as
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=304
* src/base/ftobjs.c (FT_Open_Face): Code moved to...
(ft_open_face_internal): ... this function.
Add a parameter to control whether we try special Mac font handling
in case of failure.
(FT_Open_Face, FT_New_Face, FT_New_Memory_Face,
open_face_from_buffer): Use `ft_open_face_internal'.
|
|
6949797d
|
2016-12-17T21:05:54
|
|
More code formatting.
|
|
5d664b6d
|
2016-12-17T20:47:42
|
|
Use FT_SET_ERROR where useful. Other minor code formatting.
|
|
3b125e95
|
2016-12-17T10:02:19
|
|
Improve tracing of `FT_Open_Face'.
* src/base/ftobjs.c (FT_Open_Face): Return info on number of
available faces and numbered instances, or the indices of the
requested face and numbered instance.
* src/sfnt/sfobjs. (sfnt_open_font): Trace number of subfonts.
|
|
a7dc0c35
|
2016-12-14T18:54:21
|
|
Extend functionality of `ft_module_get_service'.
It can now differentiate between local and global searches.
* src/base/ftobjs.c (ft_module_get_service): Add `global' argument.
(FT_Get_TrueType_Engine_Type): Updated.
* src/cff/cffdrivr.c (cff_get_ps_name, cff_get_cmap_info): Updated.
* include/freetype/internal/ftobjs.h: Updated.
* include/freetype/internal/ftserv.h (FT_FACE_FIND_GLOBAL_SERVICE):
Updated.
|
|
bcae6574
|
2016-12-05T22:08:15
|
|
Add `FT_Get_Var_Design_Coordinates' function.
Note that the low-level functions aren't implemented yet.
* include/freetype/ftmm.h: Declare.
* include/freetype/internal/services/svmm.h
(FT_Get_Var_Design_Func): New typedef.
(MultiMasters): New MM service function `get_var_design'.
(FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated.
Update all callers.
* src/base/ftmm.c (FT_Get_Var_Design_Coordinates): Implement.
* src/truetype/ttdriver.c: Updated.
* src/truetype/ttgxvar.c (TT_Get_Var_Design): New dummy function to
handle `get_var_design' service.
* src/truetype/ttgxvar.h: Updated.
* src/type1/t1driver.c: Updated.
* src/type1/t1load.c (T1_Get_Var_Design): New dummp function to
handle `get_var_design' service.
* src/type1/t1load.h: Updated.
|
|
e1ee5476
|
2016-11-06T12:39:05
|
|
* src/base/ftobjs.c (FT_Render_Glyph_Internal): Fix tracing.
|
|
37e193e9
|
2016-11-06T12:32:51
|
|
Introduce a way of quickly retrieving (embedded) bitmap metrics.
`FT_Load_Glyph' doesn't generate a bitmap for a non-bitmap glyph
until the user calls `FT_Render_Glyph'. However, it always
allocates memory for bitmaps and copies or decodes the contents of a
bitmap glyph, which can be quite slow for PNG data.
* include/freetype/freetype.h (FT_LOAD_BITMAP_METRICS_ONLY): New
macro.
* src/base/ftobjs.c (FT_Load_Glyph): Unset FT_LOAD_RENDER if
FT_LOAD_BITMAP_METRICS_ONLY is used.
* src/sfnt/ttsbit.c (tt_sbit_decoder_alloc_bitmap,
tt_sbit_decoder_load_bitmap): Add argument to control allocation of
the glyph slot.
(tt_sbit_decoder_load_image, tt_sbit_decoder_load_compound,
tt_face_load_sbit_image): Updated.
* src/pcf/pcfdrivr.c (PCF_Glyph_Load): Quickly exit if
`FT_LOAD_BITMAP_METRICS_ONLY' is set.
* src/pfr/pfrsbit.c, src/pfr/pfrsbit.h (pfr_slot_load_bitmap): Add
argument to control allocation of the glyph slot.
* src/pfr/pfrobjs (pfr_slot_load): Updated.
* src/winfonts/winfnt.c (FNT_Load_Glyph): Ditto.
* docs/CHANGES: Updated.
|
|
9c45ac39
|
2016-10-26T16:00:00
|
|
Add `FT_Get_{MM,Var}_Blend_Coordinates' functions.
* include/freetype/ftmm.h: Declare.
* include/freetype/internal/services/svmm.h (FT_Get_MM_Blend_Func):
New typedef.
(MultiMasters): New MM service function `get_mm_blend'.
(FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated.
Update all callers.
* src/base/ftmm.c (FT_Get_MM_Blend_Coordinates,
FT_Get_Var_Blend_Coordinates): Implement.
* src/truetype/ttdriver.c: Updated.
* src/truetype/ttgxvar.c (TT_Get_MM_Blend): New function to handle
`get_mm_blend' service.
* src/truetype/ttgxvar.h: Updated.
* src/type1/t1driver.c: Updated.
* src/type1/t1load.c (T1_Get_MM_Blend): New function to handle
`get_mm_blend' service.
* src/type1/t1load.h: Updated.
* docs/CHANGES: Document.
|
|
2ecf89b4
|
2016-09-28T19:06:21
|
|
*/*: s/FT_MEM_ZERO/FT_ZERO/ where appropriate.
|
|
c95b7652
|
2016-09-17T17:12:50
|
|
s/0/NULL/ for function pointers; comments, formatting.
|
|
d609b7c1
|
2016-09-09T22:11:07
|
|
[sfnt] Don't provide (completely) broken strike data.
FreeType tries to sanitize strike header data; we now reject
completely broken ones.
* include/freetype/internal/tttypes.h (TT_FaceRec): New
`sbit_strike_map' array pointer.
* src/base/ftobjs.c (FT_Match_Size): Reject matches where either
width or height would be zero.
Add tracing message in case of error.
* src/sfnt/sfobjs.c (sfnt_load_face): Populate `sbit_strike_map',
only using (more or less) valid strike header data for
FT_Face's `available_sizes' array.
(sfnt_done_face): Updated.
* src/sfnt/ttsbit.c (tt_face_set_sbit_strike): Use
`sbit_strike_map'.
(tt_face_load_strike_metrics): Improve tracing.
* src/truetype/ttdriver.c (tt_size_select): Use `sbit_strike_map'.
|
|
b98dfda3
|
2016-09-03T08:20:31
|
|
[base] Avoid negative bitmap stroke dimensions (#48985).
* src/base/ftobjs.c (FT_Open_Face): Check whether negation was
actually successful. For example, this can fail for value
-32768 if the type is `signed short'. If there are problems,
disable the stroke.
|
|
605946af
|
2016-07-11T16:14:36
|
|
Conditionally compile environment support.
* include/freetype/internal/ftobjs.h, src/autofit/afmodule.c,
src/base/ftobjs.c, src/cff/cffdrivr.c, src/truetype/ttdriver.c:
Decorate with `FT_CONFIG_OPTION_ENVIRONMENT_PROPERTIES' where
necessary.
|
|
c3e83b46
|
2016-07-11T05:56:26
|
|
Replace calls to `atol' with `strtol'.
We later on need strtol's `endptr' feature.
* include/freetype/config/ftstdlib.h (ft_atol): Replace with...
(ft_strtol): ... this.
* src/base/ftdbgmem.c (ft_mem_debug_init): Updated.
* src/cid/cidparse.c (cid_parser_new): Ditto.
* src/type42/t42drivr.c (t42_get_name_index), src/type42/t42objs.c
(T42_GlyphSlot_Load): Ditto.
|
|
84d3df75
|
2016-07-11T00:12:11
|
|
Implement handling of `FREETYPE_PROPERTIES' environment variable.
Recognizing properties follows in another commit.
* devel/ftoption.h, include/freetype/config/ftoption.h
(FT_CONFIG_OPTION_ENVIRONMENT_PROPERTIES): New macro.
* include/freetype/config/ftstdlib.h (ft_getenv): New macro.
* src/base/ftinit.c (ft_set_default_properties): New function to
parse `FREETYPE_PROPERTIES' and calling `ft_property_string_set'.
(FT_Init_FreeType): Updated.
|
|
c3beb30a
|
2016-07-10T07:11:45
|
|
Add function `ft_property_string_set'.
This is a preparation for handling an `FREETYPE_PROPERTIES'
environment variable to control (some) driver properties.
No change in functionality.
* src/base/ftobjs.c (ft_property_do): Add `value_is_string'
parameter.
(ft_property_string_set): New function.
(FT_Property_Set, FT_Property_Get): Updated.
* include/freetype/internal/ftobjs.h: Updated.
* include/freetype/internal/services/svprop.h
(FT_Properties_SetFunc): Add `value_is_string' parameter.
* src/autofit/afmodule.c (af_property_set), src/cff/cffdrivr.c
(cff_property_set), src/truetype/ttdriver.c (tt_property_set):
Updated, emitting an error currently if `value_is_string' is set.
|
|
109d1662
|
2016-07-08T06:58:46
|
|
Revert "Formatting."
This reverts commit a0f3a1f25a69a7c5268e87ee6e7a9238c26e6242.
|
|
a0f3a1f2
|
2016-07-08T06:53:46
|
|
Formatting.
|
|
1e36c2e2
|
2016-06-16T06:17:54
|
|
* src/base/md5.c: Updated to recent version.
|
|
5485a34c
|
2016-06-04T06:57:32
|
|
[truetype] Fix missed test for named instances (#48122).
* src/truetype/ftobjs.c (Mac_Read_sfnt_Resource): Implement.
|
|
d583561e
|
2016-05-21T11:20:42
|
|
Minor clang++ fixes.
* src/base/ftobjs.c (FT_Add_Module), src/psaux/psobjs.c
(ps_parser_load_field), src/type1/t1load.c (parse_subrs): Add
initializer.
* src/cache/ftccache.h (FTC_CACHE_TRYLOOP_END): Avoid implicit
conversion from NULL to boolean.
|
|
bebac3cf
|
2016-05-16T20:16:35
|
|
[base] Reject invalid sfnt Mac resource (#47891).
* src/base/ftobjs.c (open_face_PS_from_sfnt_stream): Check validity
of `CID ' and `TYPE1' table offset and length.
|
|
432e00db
|
2016-04-24T08:14:07
|
|
[truetype] Fix deallocation in case of error (#47726).
* src/truetype/ttgload.c (load_truetype_glyph): Initialize fields in
`outline' that are going to be deallocated in case of error.
|
|
e8542260
|
2016-04-08T23:21:34
|
|
Typos.
|
|
ff82747e
|
2016-03-29T09:19:22
|
|
* src/base/ftadvance.c (FT_Get_Advances): Fix invalid left shift.
|
|
31f2dc19
|
2016-03-23T07:31:59
|
|
[raster, smooth] Directly test outline size (#47500).
This improves stand-alone compilation.
* src/base/ftoutln.c (FT_Outline_Render): Move cbox size test to...
* src/raster/ftraster.c (ft_black_render), src/smooth/ftgrays.c
(gray_raster_render): ...these functions.
|
|
495de6cc
|
2016-03-06T23:54:34
|
|
[base] Refuse to render enormous outlines (#47114).
The goal is to avoid integer overflows in the rendering algorithms.
The limit is chosen arbitrarily at some 2^18 pixels, which should be
enough for modern devices including printers.
* src/base/ftoutln.c (FT_Outline_Render): Check CBox and reject
enormous outlines.
|
|
32950391
|
2016-02-15T12:54:40
|
|
Whitespace.
|
|
e411d38e
|
2016-02-14T20:48:59
|
|
* src/base/fthash.c: Include FT_INTERNAL_MEMORY_H.
|
|
78371bd6
|
2016-02-07T21:06:59
|
|
Fix another runtime error found by clang's sanitizer (#47082).
* src/base/ftstroke.c (ft_stroke_border_export): Properly handle
empty input buffer.
|
|
0d053bac
|
2016-02-07T19:25:56
|
|
Fix runtime errors found by clang's sanitizer (#47082).
* src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c
(FT_Outline_Copy), src/cache/ftcsbits.c (ftc_sbit_copy_bitmap):
Properly handle empty input buffer.
|
|
710ac3dd
|
2016-02-05T12:47:29
|
|
[base] Fix advance width loading for MM and GX fonts (#47064).
* src/base/ftadvanc.c (LOAD_ADVANCE_FAST_CHECK): Return false for
MM and GX fonts.
Update callers.
|
|
1d8d0b4e
|
2016-01-28T14:11:14
|
|
Remove unpatented hinter (3/3).
* include/freetype/config/ftoption.h
(TT_CONFIG_OPTION_UNPATENTED_HINTING): Remove.
* include/freetype/internal/ftobjs.h (FT_Face_InternalRec): Remove
`ignore_unpatented_hinter' field.
Update users.
(FT_DEBUG_HOOK_UNPATENTED_HINTING): Remove.
Update users.
* include/freetype/internal/tttypes.h (TT_FaceRec): Remove
`unpatented_hinting' field.
Update users.
* src/base/ftpatent.c (_tt_check_patents_in_range,
_tt_check_patents_in_table, _tt_face_check_patents): Remove.
(FT_Face_CheckTrueTypePatents, FT_Face_SetUnpatentedHinting):
Replace code with dummies.
* src/truetype/ttobjs.c (tt_face_init): Remove now defunct code.
* src/truetype/ttobjs.h (TT_GraphicsState): Remove `both_x_axis'
field.
|
|
fc11af1e
|
2016-01-19T19:15:54
|
|
Various minor clang fixes.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths),
src/autofit/aflatin.c (af_latin_metrics_init_widths): Initialize
`ch'.
* src/base/ftcalc.c (FT_MulFix) [FT_LONG64]: Add cast.
* src/base/ftdbgmem.c (ft_mem_table_destroy): Add cast.
* src/base/fthash.c (hash_num_lookup): Add cast.
* src/base/fttrigon.c (ft_trig_downscale) [FT_LONG64]: Fix cast.
* src/gxvalid/gxvcommn.c (gxv_EntryTable_validate): Comment out
redundant code.
* src/type1/t1driver.c (t1_get_ps_font_value) <PS_DICT_SUBR>: Add
cast.
* src/type1/t1load.c (parse_subrs): Fix type of `count'.
|
|
32760d33
|
2016-01-14T23:31:08
|
|
[base] Empower `FT_Library_SetLcdFilterWeights'.
* src/base/ftlcdfil.c (FT_Library_SetLcdFilterWeights): Enable filter
in addition to setting weights.
(FT_Library_SetLcdFilter): Clean out FT_FORCE_LIGHT_LCD_FILTER and
FT_FORCE_LEGACY_LCD_FILTER.
* include/freetype/ftlcdfil.h: Documentation update.
|
|
9adeab64
|
2016-01-13T11:54:10
|
|
Update copyright year.
|
|
37412ff9
|
2016-01-12T21:37:13
|
|
Don't use macro names that contain `__' [1/2].
Such macro names are reserved for both C and C++.
*/*: Replace macros of the form `__XXX_H__' with `XXX_H_'.
|
|
7ce6c43c
|
2015-12-22T05:39:58
|
|
[base] Make hash interface symmetric.
Use `num' and `str' infixes everywhere.
* src/base/fthash.c (ft_hash_init): Renamed to...
(hash_init): ... This.
(ft_hash_str_init, ft_hash_num_init): New functions.
(ft_hash_free): Renamed to...
(ft_hash_str_free): ... This.
* include/freetype/internal/fthash.h: Updated.
* src/bdf/bdflib.c, src/type1/t1load.c, src/type1/t1objs.c: Updated.
|
|
1caf629e
|
2015-12-20T19:00:35
|
|
[base] Thinko: Remove free function pointer.
We don't copy keys or values while hashing.
* include/freetype/internal/fthash.h (FT_Hash_FreeFunc): Removed.
(FT_HashRec): Remove `free' field.
* src/base/fthash.c (hash_str_free): Removed.
(ft_hash_init, ft_hash_free): Updated.
|
|
76e79ec9
|
2015-12-20T09:03:15
|
|
[base, bdf] Don't expose `FT_Hashnode' in hash functions.
* src/base/fthash.c (hash_lookup, ft_hash_str_lookup,
ft_hash_num_lookup): Return pointer to `size_t' instead of
`FT_Hashnode'.
* include/freetype/internal/fthash.h: Updated.
* src/bdf/bdflib.c (bdf_get_property, _bdf_add_property,
bdf_get_font_property): Updated.
|
|
ad306eaa
|
2015-12-20T08:33:21
|
|
[base, bdf] Add number hashing.
* src/base/fthash.c (hash_num_lookup, hash_num_compare): New
functions.
(ft_hash_init): Add argument to select between number and string
hashing.
(ft_hash_num_insert, ft_hash_num_lookup): New functions.
* include/freetype/internal/fthash.h: Updated.
* src/bdf/bdflib.c (_bdf_parse_start): Updated.
|
|
1b7549cc
|
2015-12-20T08:00:33
|
|
[base] Introduce hash lookup, compare, and free function pointers.
* include/freetype/internal/fthash.c (FT_Hash_LookupFunc,
FT_Hash_CompareFunc, FT_Hash_FreeFunc): New typedefs.
(FT_HashRec): Add `lookup', `compare', and `free' fields.
* src/base/fthash.c (hash_str_lookup, hash_str_compare,
hash_str_free): New functions.
(ft_hash_init): Set function pointers.
(hash_bucket, ft_hash_free): Use them.
|
|
609546c4
|
2015-12-20T07:17:29
|
|
[base, bdf] Use a union as a hash key.
We want to support both an integer and a string key later on.
* include/freetype/internal/fthash.h (FT_Hashkey): New union.
(FT_HashnodeRec): Updated.
(ft_hash_insert, ft_hash_lookup): Renamed to ...
(ft_hash_str_insert, ft_hash_str_lookup): ... this.
* src/base/fthash.c (hash_bucket): Updated.
(ft_hash_insert, ft_hash_lookup): Renamed to ...
(hash_insert, hash_lookup): ... this.
(ft_hash_str_insert, ft_hash_str_lookup): New wrapper functions.
* src/bdf/bdflib.c: Updated.
|
|
c98a40f9
|
2015-12-19T16:59:40
|
|
[bdf, base] Lift hash functions from bdf driver to base module.
* src/base/fthash.c, include/freetype/internal/fthash.h: New files,
containing (massaged) code from `bdflib.c' and `bdf.h'.
* include/freetype/internal/internal.h (FT_INTERNAL_HASH_H): New
macro.
* src/base/ftbase.c: Include `fthash.c'.
* src/base/Jamfile (_sources): Add `fthash'.
* src/base/rules.mk (BASE_SRC): Add `fthash.c'.
* docs/LICENSE.TXT: Updated.
|
|
4099281f
|
2015-12-14T07:51:25
|
|
[base] Fix calls to `FT_Stream_Seek'.
* src/base/ftobjs.c (Mac_Read_sfnt_Resource, FT_Open_Face): Set
`error'.
|
|
f0cc1738
|
2015-12-14T07:00:41
|
|
[base] Check error when seeking to data supplied offset (#46635).
* src/base/ftobjs.c (open_face_PS_from_sfnt_stream):
`ft_lookup_PS_in_sfnt_stream' returns offset and and length from
user supplied data. Use of this these values must be checked.
|
|
01ce1c6a
|
2015-11-28T12:04:28
|
|
Change default LCD filter to be normalized and color-balanced.
Update documentation.
* src/base/ftlcdfil.c (FT_Library_SetLcdFilter): Update
`default_filter'.
|
|
b96af12e
|
2015-11-20T16:03:09
|
|
Add `FT_LCD_FILTER_LEGACY1' enum value.
This does the same as `FT_LCD_FILTER_LEGACY'.
See
https://bugs.freedesktop.org/show_bug.cgi?id=92981
for the reasoning.
* include/freetype/ftlcdfil.h (FT_LcdFilter): New value
`FT_LCD_FILTER_LEGACY1'.
* src/base/ftlcdfil.c (FT_Library_SetLcdFilter): Use it.
|
|
ccd3188a
|
2015-11-10T22:33:45
|
|
Allow native CFF hinter in FT_RENDER_MODE_LIGHT.
Both the native CFF hinter and the auto-hinter now have a very
similar rendering style.
* include/freetype/freetype.h: Mention that FT_LOAD_TARGET_LIGHT no
longer implies FT_LOAD_FORCE_AUTOHINT.
* include/freetype/ftmodapi.h (FT_MODULE_DRIVER_HINTS_LIGHTLY): New
macro.
* include/freetype/internal/ftobjs.h (FT_DRIVER_HINTS_LIGHTLY): New
macro.
* src/cff/cffdrivr.c (cff_driver_class): Use it.
* src/base/ftobjs.c (FT_Load_Glyph): Update auto-hinter selection
logic.
|
|
40cb1dc3
|
2015-10-31T19:08:27
|
|
Formatting.
|
|
e484d36b
|
2015-10-21T20:48:27
|
|
[base] Pacify compiler (#46266).
* src/base/ftoutln.c (FT_Outline_EmboldenXY): Initialize `in' and
`anchor'.
|
|
e03214e1
|
2015-10-15T16:58:13
|
|
[base] Compute MD5 checksums only if explicitly requested.
This improves profiling accuracy.
* src/base/ftobjs.c (FT_Render_Glyph_Internal): Implement it.
|
|
2a20c92c
|
2015-10-14T15:23:15
|
|
[base] Use `FT_' namespace for MD5 functions (#42366).
* src/base/ftobjs.c (MD5_*): Define as `FT_MD5_*'.
Undefine HAVE_OPENSSL.
|
|
c14ae9c5
|
2015-10-10T22:28:26
|
|
* src/base/ftoutln.c (FT_Outline_Get_Orientation): Fix overflow (#46149).
|
|
30fe5e76
|
2015-10-04T13:08:08
|
|
[base] Replace left shifts with multiplication (#46118).
* src/base/ftglyph.c (ft_bitmap_glyph_bbox, FT_Get_Glyph): Do it.
|
|
fb5268cf
|
2015-09-28T02:01:43
|
|
[base] Fix a leak by broken sfnt-PS or resource fork (#46028).
open_face_from_buffer() frees passed buffer if valid font
is not found. But if copying to the buffer is failed,
the allocated buffer should be freed within the caller.
* src/base/ftobjs.c (open_face_PS_from_sfnt_stream): Free
the buffer `sfnt_ps' if an error caused before calling
open_face_from_buffer().
(Mac_Read_sfnt_Resource): Free the buffer `sfnt_data' if
an error caused before calling open_face_from_buffer();
|
|
8a05d250
|
2015-09-28T01:40:21
|
|
[mac] Fix buffer size calculation for LWFN font.
* src/base/ftmac.c (read_lwfn): Cast post_size to FT_ULong
to prevent confused copy by too large chunk size.
|
|
d57f2271
|
2015-09-26T08:44:26
|
|
* src/base/ftobjs.c (Mac_Read_sfnt_Resource): Add cast.
|
|
d7f456ee
|
2015-09-26T08:37:14
|
|
Formatting, minor comment corrections.
|
|
c409eb18
|
2015-09-24T12:39:38
|
|
[base, sfnt] Better checks for invalid cmaps (1/2).
* src/base/ftobjs.c (FT_Get_Char_Index): Don't return out-of-bounds
glyph indices.
(FT_Get_First_Char): Updated.
* src/sfnt/ttcmap.c (tt_cmap6_char_next): Don't return character
codes greater than 0xFFFF.
(tt_cmap8_char_index): Avoid integer overflow in computation of
glyph index.
(tt_cmap8_char_next): Avoid integer overflows in computation of
both next character code and glyph index.
(tt_cmap10_char_index): Fix unsigned integer logic.
(tt_cmap10_char_next): Avoid integer overflow in computation of
next character code.
(tt_cmap12_next): Avoid integer overflows in computation of both
next character code and glyph index.
(tt_cmap12_char_map_binary): Ditto.
(tt_cmap12_char_next): Simplify.
(tt_cmap13_char_map_binary): Avoid integer overflow in computation
of next character code.
(tt_cmap13_char_next): Simplify.
|
|
e982f5b7
|
2015-09-21T23:07:22
|
|
[base] Check too long POST and sfnt resource (#45919).
* src/base/ftbase.h (FT_MAC_RFORK_MAX_LEN): Maximum length
of the resource fork for Mac OS. The resource fork larger
than 16 MB can be written but could not be handled
correctly, at least in Carbon routine.
See https://support.microsoft.com/en-us/kb/130437
* src/base/ftobjs.c (Mac_Read_POST_Resource): No need `0x'
for `%p' formatter.
* src/base/ftbase.c (Mac_Read_POST_Resource): Check the
fragment and total size of the concatenated POST resource
before buffer allocation.
(Mac_Read_sfnt_Resource): Check the declared size of
sfnt resource before buffer allocation.
* src/base/ftmac.c (read_lwfn, FT_New_Face_From_SFNT):
Check the total resource size before buffer allocation.
|
|
bd0438a4
|
2015-09-16T18:05:43
|
|
Minor fixes for some clang warnings.
* src/base/ftoutln.c (FT_Outline_EmboldenXY): Cast, possible missing
initialization.
* src/truetype/ttgload.c (TT_Process_Composite_Component): Cast.
|
|
3ea0d2c6
|
2015-09-13T23:19:34
|
|
* src/base/ftcalc.c (FT_MulFix) [FT_LONG64]: Improve.
|
|
19b82cfb
|
2015-09-11T20:25:32
|
|
[base] Avoid crash while tracing `load_mac_face'.
Reported in Savannah bug #45919.
* src/base/ftobjs.c (load_mac_face): Honour FT_OPEN_MEMORY while
tracing.
|