|
7e14994b
|
2025-09-12T12:57:50
|
|
* include/freetype/internal/ftobjs.h (ft_default_raster): Relic removed.
|
|
526ec5c4
|
2025-09-11T13:16:53
|
|
* Version 2.14.1 released.
==========================
Tag sources with `VER-2-14-1'.
* docs/VERSION.TXT: Add entry for version 2.14.1.
* docs/CHANGES: Updated.
* docs/release, docs/README, builds/macs/README: Updated.
* README, src/base/ftver.rc, builds/windows/vc2010/index.html,
builds/windows/visualc/index.html, builds/windows/visualce/index.html,
builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html,
docs/freetype-config.1: s/2.14.0/2.14.1/, s/2140/2141/.
* include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
* builds/unix/configure.raw (version_info): Set to 26:4:20.
* CMakeLists.txt (VERSION_PATCH): Set to 1.
|
|
007c46eb
|
2025-09-06T15:55:12
|
|
* Version 2.14.0 released.
==========================
Tag sources with `VER-2-14-0'.
* docs/VERSION.TXT: Add entry for version 2.14.0.
* docs/CHANGES: Updated.
* docs/release, docs/README, builds/macs/README: Updated.
* README, src/base/ftver.rc, builds/windows/vc2010/index.html,
builds/windows/visualc/index.html, builds/windows/visualce/index.html,
builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html,
docs/freetype-config.1: s/2.13.3/2.14.0/, s/2133/2140/.
* include/freetype/freetype.h (FREETYPE_MINOR): Set to 14.
(FREETYPE_PATCH): Set to 0.
* builds/unix/configure.raw (version_info): Set to 26:3:20.
* CMakeLists.txt (VERSION_MINOR): Set to 14.
(VERSION_PATCH): Set to 0.
|
|
32cb5390
|
2025-09-06T06:14:03
|
|
Update all copyright notices.
|
|
ba7eb5be
|
2025-08-30T20:34:36
|
|
Clean up OpenVMS support.
This avoids cluttering the source code with VMS-specific changes.
* include/freetype/internal/ftcalc.h [__VMS], src/base/ftcalc.c
[vms_auto64_source]: Remove.
* builds/vms/patch_ftcalc.sed: New file.
* vms_make.com: Change macro definitions while this script is running; we
use `GNU sed` to inject the necessary preprocessor code on the fly.
|
|
61a42342
|
2025-08-29T16:59:50
|
|
[base] Use const FT_Module_Class.
This is intended to warn against modifying any fields in the class,
at compile-time and avoid crashes at run-time.
* include/freetype/internal/ftobjs.h (FT_ModuleRec): Do it.
* src/base/ftobjs.c (Destroy_Module, FT_Add_Module): Updated.
|
|
23fa1e35
|
2025-08-21T07:09:15
|
|
Updating `CHANGES` file; minor fixes elsewhere (mostly formatting).
|
|
adc7b855
|
2025-08-11T15:34:27
|
|
* */ftoption.h: Update C99 wording.
|
|
4c77a696
|
2025-08-11T13:20:50
|
|
* */ftoption.h: Note C99 compliance.
|
|
aa2ee67b
|
2025-08-05T17:34:09
|
|
Improvements to OpenVMS support.
* include/freetype/internal/ftcalc.h [__VMS]: Undefine `FT_MulFix`.
* src/base/ftcalc.c [vms_auto64_source]: Define `FT_MulFix`.
* vms_make.com: Also create 32bit version of the FreeType library.
|
|
64a0c64a
|
2025-07-29T22:21:42
|
|
[truetype] Tweak size management.
* include/freetype/internal/services/svmetric.h (FT_Size_Reset_Func):
Update typedef, do not return error.
* src/truetype/ttobjs.c (tt_size_reset_height): Move the PPem error
handling from here...
(tt_size_reset): ... to here to improve readability.
src/truetype/ttobjs.h (tt_size_reset_height): Update prototype.
|
|
b04db387
|
2025-07-04T19:52:53
|
|
[sfnt] Rewrite GPOS kerning support. (2/2)
The previous code had a fundamental flaw: it didn't validate the necessary
parts of the 'GPOS' table before accessing it, causing crashes with
malformed data (since `TT_CONFIG_OPTION_GPOS_KERNING` is off by default,
standard fuzzers don't catch these problems). Additionally, it did a lot of
parsing while accessing kerning data, making it rather slow.
The new implementation fixes this. After validation, offsets to the 'GPOS'
lookup subtables used in the 'kern' feature that correspond to 'simple'
kerning (i.e., similar to 'kern' table kerning) are stored in `TT_Face`;
this greatly simplifies and accelerates access to the kerning data.
Testing with font `SF-Pro.ttf` version '1.00', the validation time for the
'GPOS' table increases the start-up time of `FT_New_Face` by less than 1%,
while calls to `FT_Get_Kerning` become about 3.5 times faster.
* include/freetype/internal (gpos_kerning_available): Replace with...
(gpos_lookups_kerning, num_gpos_lookups_kerning): ... these new fields.
Update callers.
* src/ttgpos.c [TT_CONFIG_OPTION_GPOS_KERNING]: A new implementation.
|
|
d7e640b9
|
2025-06-29T07:45:09
|
|
[doc] Revise font variation API.
|
|
636aede9
|
2025-06-28T20:25:29
|
|
[doc] Use 'Adobe MM', 'TrueType GX', and 'OpenType Font Variations'.
|
|
2ab0357d
|
2025-06-12T23:15:22
|
|
[base] Add no-overwrite hash insert functions.
* src/base/fthash.c (ft_hash_num_insert_no_overwrite,
ft_hash_str_insert_no_overwrite): New functions.
* include/freetype/internal/fthash.h: Updated.
|
|
820df387
|
2025-06-02T16:16:06
|
|
[base] Add iterators for `FT_Hash`.
* src/base/fthash.c (ft_hash_num_iterator, ft_hash_str_iterator): New
functions.
* include/freetype/internal/fthash.h: Updated.
|
|
2041c65c
|
2025-06-20T20:20:54
|
|
[truetype] Simplify twilight zone management.
* include/freetype/internal/tttypes.h (TT_GlyphZone): Remove 'memory'.
* src/truetype/ttobjs.c (tt_glyphzone_done): Use 'memory' as argument.
(tt_glyphzone_new, tt_glyphzone_done): Allocate/free as a single block.
(tt_size_init_bytecode, tt_size_done_bytecode): Updated.
* src/truetype/ttobjs.h (tt_glyphzone_done): Updated signature.
|
|
3c14c525
|
2025-06-11T15:32:11
|
|
[truetype] Clean up TT_GlyphZone.
* include/freetype/internal/tttypes.h (TT_GlyphZone): Delete fields.
* src/truetype/ttobjs.c (tt_glyphzone_new, tt_glyphzone_done,
tt_size_init_bytecode): Updated.
|
|
68c62e19
|
2025-06-07T22:15:18
|
|
[truetype] Relocate the interpreter pointer.
This reduces dereferencing when calling the interpreter.
* include/freetype/internal/tttypes.h (TT_Face): Move it from here...
* src/truetype/ttinterp.h (TT_ExecContext): ... to here.
* src/truetype/ttobjs.c (tt_size_init_bytecode): Move its initialization
* src/truetype/ttinterp.c (TT_New_Context): ... to here.
(TT_Run_Context): Updated.
|
|
ecfefd8c
|
2025-06-07T22:12:45
|
|
[truetype] Clean up the loader initiation.
* include/freetype/internal/tttypes.h (TT_LoaderRec): Remove unused field.
* src/truetype/ttgload.c (tt_loader_init): Refactor.
|
|
d736e741
|
2025-06-10T05:09:58
|
|
Two more link fixes.
|
|
7f559fbe
|
2025-06-10T04:55:43
|
|
Update links.
Found with `linkchecker --check-extern index.html` running locally in the
'freetype-web' repository.
|
|
2adb5361
|
2025-06-03T10:35:16
|
|
Replace 'www.freetype.org' with 'freetype.org'.
|
|
5a07f41d
|
2025-05-28T09:52:44
|
|
[sfnt] `FT_Load_Sfnt_Table` can now also load a font's table directory.
Closes issue #1263.
* src/sfnt/ttload.c (tt_face_load_any): Implement it.
|
|
fa412cf5
|
2025-05-23T15:41:26
|
|
[mm/gxvar] Always detect default instance and use optimized codepath.
Even if it was explicitly set by either design or normalized APIs.
Also update documentation.
* src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design): Use value -2
of `error` to indicate that we have a non-default instance.
(TT_Set_Named_Instance): Updated.
* src/base/ftmm.c (FT_Set_Var_Design_Coordinates,
FT_Set_Var_Blend_Coordinates): Updated.
|
|
e07e56c7
|
2025-05-26T17:20:12
|
|
[gxvar] Speed up handling of deltas in `ItemVariationStore`. (3/3)
* src/base/ftcalc.c (FT_MulAddFix): Removed, no longer needed.
* include/freetype/internal/ftcalc.h: Updated.
|
|
8eae0399
|
2025-05-26T08:16:53
|
|
Lift `FT_Int64` type to global (internal) FreeType use.
* src/base/ftcalc.c (FT_Int64) [!FT_INT64]: Move declaration to...
* include/freetype/config/integer-types.h: ... this file.
(FT_UInt64) [!FT_INT64]: New structure.
(FT_INT64_ZERO): New macro.
|
|
04455084
|
2025-05-08T07:47:23
|
|
* include/freetype/ttnameid.h (TT_UCR_*): Define with unsigned long.
(TT_UCR_PHAGSPA): Fix definition.
Fixes issue #1300.
|
|
c2789e75
|
2025-05-08T07:01:42
|
|
[doc] Mention that there is no rendering support for 'COLR' v1 tables.
Handles issue #1319.
|
|
c26c150c
|
2025-05-04T07:22:46
|
|
Fix Cygwin visibility attributes.
Reported as compilation warnings in #1329.
* include/freetype/config/public-macros.h: Check __CYGWIN__.
* include/freetype/internal/compiler-macros.h: Ditto.
|
|
5d2fd760
|
2025-04-26T13:53:24
|
|
Provide configuration option to dynamically load the HarfBuzz library.
We now request HarfBuzz version 2.6.8 (published in June 2020) or newer to
simplify the setup; this version introduced function
`hb_ot_layout_lookup_get_glyph_alternates`, which we need for the adjustment
database of the auto-hinter.
No CMake support yet for dynamic loading.
* include/freetype/config/ftoption.h, devel/ftoption.h
(FT_CONFIG_OPTION_USE_HARFBUZZ_DYNAMIC): New configuration macro.
* builds/unix/configure.raw: Implement `--with-harfbuzz=dynamic`.
This gets tested automatically if we can't link with `libharfbuzz`.
(ft_option_set, ft_option_unset): Refine.
Require at least HarfBuzz version 2.6.8.
* meson.build: Do the same as `configure.raw`.
* meson_options.txt: Updated.
* CMakeLists.txt: Require at least HarfBuzz version 2.6.8.
|
|
3467c217
|
2025-04-25T08:09:48
|
|
* include/freetype/internal/ftcalc.h (FT_MulFix_64): Silence UBSAN.
|
|
6ed79d5b
|
2025-04-17T22:46:06
|
|
* include/freetype/internal/ftcalc.h: Fix fringe compilation.
|
|
ccabe7ac
|
2025-04-15T18:49:36
|
|
[base, truetype] Silence UBSAN (cont'd).
* src/truetype/ttinterp.c (TT_MulFix14, TT_DotFix14): Use MUL_INT64.
* include/freetype/internal/ftcalc.c (FT_MulFix): Ditto.
|
|
c46ebd76
|
2024-01-28T17:27:39
|
|
[autofit] Add adjustment database.
* src/autofit/afadjust.c, src/autofit/afadjust.h: New files.
* include/freetype/internal/fttrace.h: Add 'afadjust' component.
* src/autofit/autofit.c: Include `afadjust.c`.
* src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afadjust.c`.
|
|
f0660df3
|
2024-01-28T07:38:41
|
|
[base] Make `find_unicode_charmap` a base function.
This is needed for forthcoming changes in the auto-hinter.
* include/freetype/internal/ftobjs.h, src/base/ftobjs.c: Updated.
|
|
5416689d
|
2025-04-12T12:38:01
|
|
* include/freetype/internal/ftcalc.h (FT_MSB) [__CC_ARM]: Added.
|
|
58b3598c
|
2025-04-12T09:18:16
|
|
Typos in macros.
* include/freetype/internal/ftcalc.h: s/_M_X86/_M_IX86/.
* src/truetype/ttinterp.c: s/_M_X86/_M_IX86/.
|
|
c88bf8a2
|
2025-04-11T22:58:26
|
|
[base, truetype] Silence UBSAN.
* src/truetype/ttinterp.c (TT_MulFix14_64): Use unsigned multiplication.
* include/freetype/internal/ftcalc.h (FT_MulFix_64): Ditto.
|
|
fb99fd63
|
2025-04-11T22:57:27
|
|
[base, truetype] Synchronize MulFix assembly.
* include/freetype/internal/ftcalc.h (FT_MulFix_*),
src/truetype/ttinterp.c (TT_MulFix14_*): Synchronize routines.
|
|
8f67545d
|
2025-04-09T13:37:23
|
|
[base] Update FT_MulFix inlining.
Resolves inconsistencies in 64-bit multiplication discussed in !355. Importantly, FT_MulFix arguments and return value is FT_Long, whatever sizeof FT_Long is on 64-bit platforms: 8 bytes on Linux or 4 bytes on Windows. * include/freetype/internal/ftcalc.h (FT_MulFix_x86_64): Removed. (FT_MulFix_64): Generalize and prioritize the inline implementation
for all 64-bit platforms ifdef FT_INT64. * src/base/ftcalc.c (FT_MulFix)[FT_INT64]: Call 'FT_MulFix_64'. * src/base/ftbase.c: Include 'ftcalc.c' after the FT_MulFix callers to enable its inlining.
|
|
fc67794e
|
2025-04-04T19:54:50
|
|
Missing header wrappers.
* include/freetype/config/integer-types.h, src/smooth/ftgrays.h:
Add missing FT_BEGIN_HEADER and FT_END_HEADER.
* src/smooth/ftgrays.c: Cosmetics.
|
|
4f00846d
|
2024-08-25T18:13:10
|
|
* include/freetype/ftimage.h (FT_Bitmap): Describe empty bitmap.
|
|
f92c9655
|
2024-08-13T23:29:13
|
|
Fix various typos.
|
|
42608f77
|
2024-08-11T20:30:23
|
|
* Version 2.13.3 released.
==========================
Tag sources with `VER-2-13-3'.
* docs/VERSION.TXT: Add entry for version 2.13.3.
* docs/CHANGES: Updated.
* docs/release, docs/README, builds/macs/README: Updated.
* README, src/base/ftver.rc, builds/windows/vc2010/index.html,
builds/windows/visualc/index.html, builds/windows/visualce/index.html,
builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html,
docs/freetype-config.1: s/2.13.2/2.13.3/, s/2132/2133/.
* include/freetype/freetype.h (FREETYPE_PATCH): Set to 3.
* builds/unix/configure.raw (version_info): Set to 26:2:20.
* CMakeLists.txt (VERSION_PATCH): Set to 3.
|
|
ed8b82ba
|
2024-08-08T10:28:05
|
|
Various minor documentation or formatting fixes.
|
|
ec378cec
|
2024-08-07T21:23:44
|
|
tttables.h (FT_Get_CMap_Format): Minor documentation improvement.
|
|
24888540
|
2024-07-28T19:42:49
|
|
[bdf,pcf,winfonts,sfnt] Remove barely used marcros.
* include/freetype/internal/ftobjs.h (FT_FACE_SIZE, FT_SIZE_FACE):
Removed.
* src/bdf/bdfdrivr.c (BDF_Glyph_Load): Updated.
* src/pcf/pcfdrivr.c (PCF_Glyph_Load): Ditto.
* src/winfonts/winfnt.c (FNT_Load_Glyph): Ditto
* src/sfnt/ttbdf.c (tt_face_find_bdf_prop): Ditto.
|
|
97069edd
|
2024-07-27T20:41:25
|
|
* include/freetype/internal/ftcalc.h (FT_MSB)[_M_ARM64EC]: Added.
|
|
044d142b
|
2024-06-20T22:16:51
|
|
Use unsigned tags `FT_Outline`.
This change comes along with 2a7bb4596f56 ans is only meant to reduce
pointer casting in the code.
* include/freetype/ftimage.h (FT_Outline): Do it.
* src/*: Update `FT_Outline` users.
|
|
2a7bb459
|
2024-06-20T20:49:56
|
|
Use unsigned point and contour indexing in `FT_Outline`.
This doubles the number or allowed points, see
https://github.com/harfbuzz/harfbuzz/issues/4752
Although it is hardly practical to use more than 32767 points,
other font engines seem to support it.
* docs/CHANGES: Announce it.
* include/freetype/ftimage.h (FT_Outline): Do it and update limits.
* src/*: Update `FT_Outline` users.
|
|
deba7feb
|
2024-06-18T14:01:58
|
|
* include/freetype/ftimage.h: Explain standard types.
|
|
42d406ab
|
2024-05-22T21:08:34
|
|
* include/freetype/internal/ftmemory.h (FT_MEM_DUP): Fix g++ error.
|
|
68399b42
|
2024-05-13T16:57:35
|
|
* include/freetype/ftmm.h: Include `freetype.h`.
Reported by Ben Wagner, see !326.
|
|
4a85db7e
|
2024-05-11T22:19:25
|
|
[type1/MM] Tighten headers.
* include/freetype/internal/t1types.h: Host PS_DesignMap and PS_Blend.
* include/freetype/ftmm.h: Host and document TT_MAX_MM_XXX.
* include/freetype/t1tables.h: Remove them from here.
|
|
a4642422
|
2024-05-08T11:33:47
|
|
[psaux] Fix location and type order in initializer
`T1_FIELD_ZERO` is used to zero initialize a `T1_FieldRec`.
`T1_FIELD_ZERO` is currently initilizing `T1_FieldRec::location` with a
`T1_FieldType` and `T1_FieldRec::type` with a `T1_FieldLocation`. This
was detected with `-Wenum-conversion`.
* include/freetype/internal/psaux.h (T1_FIELD_ZERO): correct order of
initalizers
|
|
1264b84c
|
2024-05-07T23:35:59
|
|
* include/freetype/internal/psaux.h: Fix g++ warning.
Reported by Hin-Tak Leung.
|
|
4e079f63
|
2024-04-27T20:07:36
|
|
Document the SDF spread further.
|
|
e2bcca40
|
2024-04-22T22:43:41
|
|
* include/freetype/ftdriver.h: s/truncated/clamped/.
|
|
ec46a50d
|
2024-04-22T21:21:12
|
|
Improve SDF documentation.
|
|
47574f7e
|
2024-01-27T11:11:22
|
|
Update all copyright notices.
|
|
8f286c86
|
2024-01-19T16:42:48
|
|
Add support for kerning from 'GPOS' tables.
This commit adds support for kerning from 'GPOS' tables, while maintaining
support for basic 'kern' tables. `FT_HAS_KERNING` will be true for a font
with either available and `FT_Get_Kerning` will still use the basic 'kern'
table data if avilable, otherwise check the GPOS 'kern' feature.
This feature is disabled by default; it can be enabled with the
`TT_CONFIG_OPTION_GPOS_KERNING` flag.
Only basic kerning (pair positioning with just an x advance) is supported
from the GPOS layout features; support for that was added to make the
existing `FT_Get_Kerning` API more consistently functional. FreeType does
not intend to extend itself to further GPOS functionality though; a
higher-level library like HarfBuzz can be used instead for that.
* include/freetype/config/ftoption.h, include/devel/ftoption.h
(TT_CONFIG_OPTION_GPOS_KERNING): New configuration option.
* include/freetype/internal/fttrace.h: Add `ttgpos` trace handler.
* include/freetype/internal/sfnt.h (SFNT_Interface): Add `load_gpos` and
`get_gpos_kerning` fields.
(FT_DEFINE_SFNT_INTERFACE): Updated.
* include/freetype/internal/tttypes.h: Include `fttypes.h`.
(TT_FaceRec) [TT_CONFIG_OPTION_GPOS_KERNING]: Add `gpos_table` and
`gpos_kerning_available` fields.
* src/sfnt/ttgpos.c, src/sfnt/ttgpos.h: New files.
* src/sfnt/sfdriver.c [TT_CONFIG_OPTION_GPOS_KERNING]: Include `ttgpos.h`.
(sfnt_interface): Updated.
* src/sfnt/sfnt.c: Include `ttgpos.c`.
* src/sfnt/sfobjs.c [TT_CONFIG_OPTION_GPOS_KERNING]: Include `ttgpos.h`.
(sfnt_load_face) [TT_CONFIG_OPTION_GPOS_KERNING]: Load and free GPOS kerning
data; check GPOS kerning availability.
* src/truetype/ttdriver.c (tt_get_kerning): Use GPOS kerning if there's no
'kern' table.
|
|
8eab5110
|
2023-12-14T06:59:05
|
|
[CFF] Extract `BlueValues` as `Fixed` rather than `Int`.
This is a follow-up to commit 26a7f047,
[cff] Make blend operator work with floats in private dicts.
which addressed the 'party baseline' bug. However, the reporting user
indicated that the default location and some other points in design space
rendered OK, but other points in design space still had problems. The most
obvious issue being that the x-heights of lower-case letters did not align;
see
https://github.com/adobe-fonts/source-serif/issues/121#issuecomment-1773794136
After some analysis we determined that this was due to an interaction
between `BlueValue` rounding and the zone-based algorithm. In short, for a
point to be considered in a zone it must fall within the bounds of the zone.
(There is a slop factor in some cases, but only a very small one.) In the
Adobe-contributed side of the code, point values are not integer-rounded,
instead they're kept as (some form of) fixed. Rounding just the `BlueValues`
means that points that need to be considered within a zone will fall outside
of it at some points in design space.
The majority of this patch changes the storage and parsing of `BlueValues`
to keep them as `FT_Fixed`. No significant code changes were needed because
the values are converted to `Fixed` anyway when stored in `CF_BlueRec`. No
attempt was made to address problems in the older pshinter code beyond
converting the values from `FT_Fixed` to `FT_Short` when copying the private
dictionary. (However, as the point values are also rounded in that code,
the problem is much less likely to occur, although inconsistency between
rounding and truncation could cause an analogous problem.)
* include/freetype/internal/cfftypes.h (CFF_PrivateRec): Use `FT_Fixed` for
`blue_values`, `other_blues`, `family_blues`, and `family_other_blues`.
* src/cff/cffload.c (cff_blend_doBlend): Updated.
* src/cff/cffobjs.c (CFF_fixedToInt): New macro.
(cff_make_private_dict): Use it.
* src/cff/cffparse.h (cff_kind_delta_fixed): New enum value.
* src/cff/cffparse.c (do_fixed): Updated.
(CFF_FIELD_DELTA, CFF_FIELD_DELTA_FIXED, CFF_DELTA_KIND): New set of macros,
replacing `CFF_FIELD_DELTA`.
(cff_parser_run): Updated to handle fixed-float deltas.
* src/cff/cfftoken.h: Updated to use `CFF_FIELD_DELTA_FIXED` for blue
values.
* src/psaux/psblues.c (cf2_blueToFixed): Removed, no longer needed.
(cf2_blues_init): Updated.
* src/pxaux/psft.c, src/pxaux/psft.h (cf2_getBlueValues, cf2_getOtherBlues,
cf2_getFamilyBlues, cf2_getFamilyOtherBlues): Updated signatures.
* src/psaux/psobjs.c (t1_make_subfont): Updated.
|
|
0f98994e
|
2023-11-13T23:15:00
|
|
* include/freetype/ftimage.h: Fix type and link.
|
|
21435f07
|
2023-10-08T23:34:28
|
|
fix typo in FT_Outline_Decompose note
|
|
cc732ec6
|
2023-09-21T02:28:32
|
|
* include/freetype/internal/ftcalc.h (FT_MSB): Define for Solaris 11.
|
|
95b0fe2a
|
2023-09-19T22:26:32
|
|
[base] Reintroduce `FT_SqrtFixed`.
The general square root calculations are not necessary in FreeType.
For vector normalization or length, FreeType uses special functions.
It is, however, required in the legacy CFF specifications.
* src/base/ftcalc.c (FT_SqrtFixed): New function that uses either
Babylonian or bit-wise algorithm, whichever is faster for the given
situation.
* include/freetype/internal/ftcalc.h (FT_SqrtFixed): Declare it.
|
|
6eb5f2be
|
2023-09-13T17:02:31
|
|
Update 2 files
- /src/base/ftcalc.c
- /include/freetype/internal/ftcalc.h
|
|
8d0897b3
|
2023-09-09T22:20:00
|
|
[type1, cid, type42] Post-cleanup.
* include/freetype/internal/psaux.h (T1_FIELD_ZERO): Terminating macro.
* src/cid/cidload.c (cid_parse_dict): Use while-loop.
* src/type1/t1load.c (parse_dict): Ditto.
* src/type42/t42parse.c (t42_parse_dict): Ditto.
|
|
7ad9d57c
|
2023-09-09T15:19:06
|
|
[type1, cid, type42] Streamline dictionary parsing.
When matching the keywords, we avoid calculating their lengths by
checking the stored values. This itself is a sufficient pre-check
before diving into `memcmp`. Therefore, we remove explicit check of
the first characters.
* include/freetype/internal/psaux.h (T1_FieldRec): Store length.
* src/cid/cidload.c (cid_parse_dict): Use `memcmp` and stored length.
* src/type1/t1load.c (parse_dict): Ditto.
* src/type42/t42parse.c (t42_parse_dict): Ditto.
|
|
920c5502
|
2023-08-25T19:51:30
|
|
* Version 2.13.2 released.
==========================
Tag sources with `VER-2-13-2'.
* docs/VERSION.TXT: Add entry for version 2.13.2.
* docs/CHANGES: Updated.
* docs/release, docs/README, builds/macs/README: Updated.
* README, src/base/ftver.rc, builds/windows/vc2010/index.html,
builds/windows/visualc/index.html, builds/windows/visualce/index.html,
builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html,
docs/freetype-config.1: s/2.13.1/2.13.2/, s/2131/2132/.
* include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
* builds/unix/configure.raw (version_info): Set to 26:1:20.
* CMakeLists.txt (VERSION_PATCH): Set to 2.
|
|
97251fd5
|
2023-08-21T23:23:22
|
|
[base] Improve the matrix degeneracy check.
Also fixes #1251.
* src/base/ftcalc.c (FT_Matrix_Check): To avoid overflow, scale by shifting.
* include/freetype/internal/ftcalc.h (FT_Matrix_Check): Update description.
|
|
1ecfd219
|
2023-07-27T16:12:28
|
|
[truetype] Remove Infinality for good (remaining bits).
* src/truetype/ttobjs.h: Remove remaining fields.
* src/truetype/ttinterp.c: Do not initialize them.
* include/freetype/internal/tttypes.h: Remove descriptions.
|
|
5b7e45ac
|
2023-07-27T15:06:38
|
|
[truetype] Remove Infinality for good.
Remove everything `#ifdef TT_SUPPORT_SUBPIXEL_HINTING_INFINALITY`,
which was undefined for a while now.
* include/freetype/internal/tttypes.h: Ditto.
* src/truetype/truetype.c: Ditto.
* src/truetype/ttdriver.c: Ditto.
* src/truetype/ttgload.c: Ditto.
* src/truetype/ttinterp.c: Ditto.
* src/truetype/ttinterp.h: Ditto.
* src/truetype/ttobjs.c: Ditto.
* src/truetype/ttsubpix.[ch]: Remove files.
* src/truetype/rules.mk: Don't mention "ttsubpix.c".
|
|
e4586d96
|
2023-06-24T05:18:54
|
|
* Version 2.13.1 released.
==========================
Tag sources with `VER-2-13-1'.
* docs/VERSION.TXT: Add entry for version 2.13.1.
* docs/CHANGES: Updated.
* docs/release, docs/README, builds/macs/README: Updated.
* README, src/base/ftver.rc, builds/windows/vc2010/index.html,
builds/windows/visualc/index.html, builds/windows/visualce/index.html,
builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html,
docs/freetype-config.1: s/2.13.0/2.13/1/, s/2130/2131/.
* include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
* builds/unix/configure.raw (version_info): Set to 26:0:20.
* CMakeLists.txt (VERSION_PATCH): Set to 1.
* subprojects/libpng.wrap, subprojects/zlib.wrap, subprojects/dlg: Updated.
|
|
4e1c0e8f
|
2023-06-05T11:53:34
|
|
Mark FT_Renderer_Class::raster_class as pointer to const
The `FT_DEFINE_RASTER_FUNCS` macro declares a `const FT_Raster_Funcs`.
The address of the definition is taken and assigned to
`FT_Renderer_Class::raster_class` which is currently `FT_Raster_Funcs*`.
Until recently the `const` was cast away and with the removal of the
cast there are now warnings about dropping this `const`. Instead of
adding back the casts, make `FT_Renderer_Class::raster_class` a pointer
to const, as is done with pointers in other interfaces.
* include/freetype/ftrender.h (FT_Renderer_Class_): mark `raster_class`
as const.
|
|
7bed7a02
|
2023-06-01T21:05:32
|
|
Fix some `FT_Fixed` vs. `FT_Long` confusion.
`FT_Fixed` and `FT_Long` are both typedef'ed to be `signed long`. However,
`FT_Fixed` implies that the lower 16 bits are being used to express
fractional values and so these two types should not be confused.
* include/freetype/internal/services/svmm.h (FT_Set_MM_Blend_Func): Use
`FT_Fixed` for `coords`. Users are passing `FT_Fixed` and implementations
are taking `FT_Fixed`.
(FT_Get_MM_Blend_Func): Ditto.
* src/autofit/afcjk.c (af_cjk_metrics_check_digits): Use `FT_Long` for
`advance` and `old_advance`. `advance`'s address is passed as `FT_Long*` to
`af_shaper_get_elem`, which writes the advance in em units (not fixed). The
exact value is not important here as it is only compared to check whether it
has changed.
* src/autofit/aflatin.c (af_latin_metrics_check_digits): Ditto.
|
|
80a507a6
|
2023-05-23T13:13:56
|
|
Replace `sprintf` with `snprintf`.
Fixes #1233.
* include/freetype/config/ftstdlib.h (ft_sprintf): Replace with...
(ft_snprintf): This new macro.
* src/autofit/afhints.c (af_print_idx): Add argument to pass the buffer
size.
(af_glyph_hints_dump_points, af_glyph_hints_dump_segments,
af_glyph_hints_dump_edges): Updated.
* src/bdf/bdflib.c (BUFSIZE): New macro.
(bdf_parse_properties_, bdf_parse_start_): Use `ft_snprintf`.
* src/tools/ftrandom/ftrandom.c (do_test): Use `snprintf`.
|
|
2342a03a
|
2023-05-19T14:11:57
|
|
Add missing end quote of a string in the example code of FT_Trace_Set_Level
|
|
115e9275
|
2023-05-19T12:11:45
|
|
[truetype] Reduce heap allocation of `deltaSet` variation data.
`deltaSet` is an array of packed integers that can be 32 bits, 16 bits, or
8 bits. Before this change, these values were unpacked to 32-bit integers.
However, this can cause big heap allocations, e.g., around 500 KByte for
'NotoSansCJK'. To reduce this amount, store the packed integers and unpack
them just before passing to the calculation. At calculation time, due to
the variable length of region indices, temporary heap allocations are
necessary. This heap allocation is not negligible and visible in `ftbench`
results. So, use stack-allocated arrays for short array calculations.
Fixes #1230.
* include/freetype/internal/ftmmtypes.h (GX_ItemVarDataRec): New fields
`wordDeltaCount` and `longWords`.
* src/truetype/ttgxvar.c (tt_var_load_item_variation_store): Load packed
data.
(tt_var_get_item_delta): Unpack data before applying.
|
|
416d4c25
|
2023-05-15T15:44:36
|
|
Add new load flag `FT_LOAD_NO_SVG`.
Modern color fonts often contain both an 'SVG' and 'COLR' table. FreeType
always preferred 'SVG' over 'COLR' (this was a design decision), however,
this might not be the right choice for the user. The new flags makes
FreeType ignore the 'SVG' table while loading a glyph.
Fixes #1229.
* include/freetype/freetype.h (FT_LOAD_NO_SVG): New macro.
* src/base/ftobjs.c (FT_Load_Glyph), src/cff/cffgload.c (cff_slot_load),
src/truetype/ttgload.c (TT_Load_Glyph): Use it.
|
|
3af4772d
|
2023-05-12T05:58:43
|
|
* include/freetype/ftcache.h: Typo, punctuation.
|
|
b07ab47b
|
2023-05-11T23:23:52
|
|
* include/freetype/ftcache.h: Formatted and updated.
|
|
7132f5b0
|
2023-05-12T09:49:58
|
|
* include/freetype/internal/t1types.h: Fix the indentation.
|
|
8fe50c2a
|
2023-04-27T23:06:51
|
|
[truetype] Fix style name handling for variation fonts.
* include/freetype/internal/tttypes.h (TT_FaceRec): New field
`non_var_style_name`.
* src/sfnt/sfobjs.c (sfnt_load_face): Initialize `non_var_style_name`.
(sfnt_done_face): Free `non_var_style_name`.
* src/truetype/ttgxvar.c (TT_Set_Named_Instance): Restore non-VF style name
if switching back to non-VF mode.
|
|
c8a24209
|
2023-04-27T11:40:46
|
|
[truetype] Fix PostScript name handling for variation fonts.
A variation font's PostScript name of a named instance is usually different
from the PostScript name of an unnamed instance. However, if a change
between a named instance and an unnamed instance with exactly the same
design axis values happened, it was possible that the PostScript name wasn't
correctly updated.
This commit reorganizes the code to handle this issue within the top-level
API functions, using a new service to trigger recomputation of the
PostScript name.
* include/freetype/internal/services/svmm.h (FT_Construct_PS_Name_Func): New
typedef.
(FT_Service_MultiMasters): New field `construct_ps_name`.
(FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated.
* src/base/ftmm.c (FT_Set_Var_Design_Coordinates,
FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates): Call
`mm->construct_ps_name` to handle `postscript_name`.
(FT_Set_Named_Instance): Call `mm->construct_ps_name` to handle
`postscript_name`.
Use shortcut.
* src/cff/cffdrivr.c (cff_construct_ps_name): New function.
(cff_service_multi_masters): Updated.
* src/truetype/ttgxvar.c (tt_set_mm_blend): Don't handle `postscript_name`.
(TT_Set_MM_Blend): Simplify.
(TT_Set_Named_Instance): Return -1 if axis values haven't changed.
Don't set `face_index`.
(tt_construct_ps_name): New function.
* src/truetype/ttgxvar.h: Updated.
* src/truetype/ttdriver.c (tt_service_gx_multi_masters): Updated.
* src/type1/t1driver.c (t1_service_multi_masters): Updated.
* src/type1/t1load.c (T1_Set_MM_Blend): Simplify.
|
|
7af8fd00
|
2023-04-27T07:37:14
|
|
* include/freetype/internal/services/svmm.h: Minor changes.
|
|
6713b1e4
|
2023-04-26T12:03:04
|
|
[truetype] Fix deactivation of variation font handling.
According to the documentation, the functions `FT_Set_Named_Instance`,
`FT_Set_MM_Design_Coordinates`, `FT_Set_Var_Design_Coordinates`, and
`FT_Set_Var_Blend_Coordinates` can unset the `FT_FACE_FLAG_VARIATION` flag.
(The same is true for `FT_Set_MM_WeightVector` but this information was
accidentally omitted from the documentation.)
However, if a call of these functions didn't change the axis values this
could fail because internal shortcuts exited too early.
This commit reorganizes the code to handle `FT_FACE_FLAG_VARIATION` in the
top-level API functions, also taking care of the issue at hand.
* src/base/ftmm.c (FT_Set_MM_Design_Coordinates, FT_Set_MM_WeightVector,
FT_Set_Var_Design_Coordinates, FT_Set_MM_Blend_Coordinates,
FT_Set_Var_Blend_Coordinates): Handle `FT_FACE_FLAG_VARIATION`.
* src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design,
TT_Set_Named_Instance) Don't handle `FT_FACE_FLAG_VARIATION`.
* src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_WeightVector,
T1_Set_MM_Design): Ditto.
* src/cff/cffobjs.c (cff_face_init): Use `FT_Set_Named_Instance` instead of
low-level functions.
* src/truetype/ttobjs.c (tt_face_init): Ditto.
|
|
fdcb14a2
|
2023-04-27T06:18:38
|
|
s/set_instance/set_named_instance/
* include/freetype/internal/services/svmm.h (FT_Set_Instance_Func): Renamed
to...
(FT_Set_Named_Instance_Func): ...this.
(FT_Service_MultiMasters): Rename `set_instance` to `set_named_instance`.
(FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated.
* src/base/ftmm.c (FT_Set_Named_Instance): Updated.
* src/cff/cffdrivr.c (cff_set_instance): Renamed to...
(cff_set_named_instance): ...this.
(cff_service_multi_masters): Updated.
* src/cff/cffobjs.c (cff_face_init): Updated.
* src/truetype/ttdriver.c (tt_service_gx_multi_masters): Updated.
* src/type1/t1driver.c (t1_service_multi_masters): Updated.
|
|
fb982e78
|
2023-04-26T08:17:17
|
|
New Variation Font function `FT_Get_Default_Named_Instance`.
* include/freetype/ftmm.h, src/base/ftmm.c (FT_Get_Default_Named_Instance):
New function.
* include/freetype/internal/services/svmm.h
(FT_Get_Default_Named_Instance_Func): New typedef.
(FT_Service_MultiMasters): New field `get_default_named_instance`.
(FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated.
* include/freetype/internal/tttypes.h (TT_Face): New field
`var_default_named_instance`.
* src/sfnt/sfobjc.s (sfnt_init_face): Initialize
`var_default_named_instance`.
* src/cff/cffdrivr.c (cff_get_default_named_instance): New function.
(cff_service_multi_masters): Updated.
* src/truetype/ttgxvar.c (TT_Get_MM_Var): Initialize
`var_default_named_instance`.
(TT_Get_Default_Named_Instance): New function.
* src/truetype/ttgxvar.h: Updated.
* src/truetype/ttdriver.c (tt_service_gx_multi_masters): Updated.
* src/type1/t1driver.c (t1_service_multi_masters): Updated.
* docs/CHANGES: Updated.
|
|
b5e57b04
|
2023-05-06T16:41:13
|
|
[cid] Improve tracing messages; formatting.
|
|
77bbfc59
|
2023-04-24T09:48:09
|
|
API documentation: Re-organize chapters and sections
* Split the very long 'Base Interface' section into smaller sections.
* Split the 'Core API' chapter into two chapters.
* Remove single enumeration values from `@order` fields since they have no
effect.
|
|
13df1c7d
|
2023-04-26T13:17:36
|
|
Minor documentation updates.
|
|
cfe54d6a
|
2023-04-26T13:15:57
|
|
s/this is,/that is,/
|
|
0a3836c9
|
2023-04-25T09:54:09
|
|
Improve/add source comments and documentation.
|
|
8154d8e2
|
2023-04-19T13:48:59
|
|
[services] FT_Size_Reset_Func to return FT_Error
The `MetricsVariations` `FT_Size_Reset_Func` is currently defined to
return `void`, but the implementations return `FT_Error`. Even though
the pointers passed will be the same at runtime, calling a function
through a pointer of a different type from the original function pointer
type is undefined behavior. This may be caught at runtime by Control
Flow Integrity with something like clang's `cfi-icall`.
Issue: https://crbug.com/1433651
* include/freetype/internal/services/svmetric.h (FT_Size_Reset_Func):
return `FT_Error` instead of `void`.
|
|
e78e2d29
|
2023-04-06T11:16:29
|
|
[sfnt, truetype] Add `size_reset` to `MetricsVariations`.
This is a generalization of commit
```
commit e6699596af5c5d6f0ae0ea06e19df87dce088df8
Author: Werner Lemberg <wl@gnu.org>
Date: Thu Feb 2 11:38:04 2017 +0100
[truetype] Fix MVAR post-action handling.
```
It is also possible for plain `CFF ` style fonts to contain an `fvar` and
`MVAR` table and use `cff_metrics_adjust`. `tt_size_reset` should only be
called with `TT_Size` and never with `CFF_Size`.
Allow the "metrics-variations" service to specify the correct function (if
any) to reset `FT_Size`s after adjusting metrics.
* src/truetype/ttobjs.c (tt_size_reset): Split off some functionality
into...
(tt_size_reset_height): ... this new function.
* src/truetype/ttdriver.c (tt_service_metrics_variations): Add
`size_reset`.
(tt_size_select, tt_size_request): Updated.
* src/truetype/ttobjs.h: Updated.
* include/freetype/internal/services/svmetric.h (MetricsVariations): Add
`size_reset`.
(FT_DEFINE_SERVICE_METRICSVARIATIONSREC): Updated.
* include/freetype/internal/tttypes.h (TT_FaceRec_): Rename `var` to
`tt_var` and add `face_var`.
* src/cff/cffdrivr.c (cff_service_metrics_variations): Add `size_reset`.
(cff_hadvance_adjust, cff_metrics_adjust): Updated.
* src/cff/cffobjs.c (cff_face_init): Use `face_var`.
* src/sfnt/sfobjs.c (sfnt_init_face): Initialize `face_var`.
* src/sfnt/ttmtx.c (tt_face_get_metrics): Use `tt_var`.
* src/truetype/ttgxvar.c (tt_size_reset_iterator): Renamed to...
(ft_size_reset_iterator): ... this new function.
Call `size_reset`.
(tt_apply_mvar): Pass `size_reset` to `ft_size_reset_iterator`.
Fixes #1211
|
|
1a4c18f7
|
2023-04-10T15:30:43
|
|
Align `char_next` return types.
This is mostly cosmetic because FT_UInt and FT_UInt32 are likely identical.
* src/sfnt/ttcmap.c, src/cff/cffcmap.c, src/psaux/t1cmap.c,
src/psnames/psmodule.c, include/freetype/internal/service/svpcsmap.h,
src/pfr/pfrcmap.c, src/winfonts/winfnt.c (*_char_next): return FT_UInt.
|
|
9597a62b
|
2023-04-01T22:34:30
|
|
[sfnt] Consolidate POST version 2.0 and 2.5 (pt 1).
The deprecated POST version 2.5 can be handled using the data
structures of version 2.0. The goal is to reduce the footprint.
* include/freetype/internal/tttypes.h (TT_Post_Names): Absorb and...
(TT_Post_20, TT_Post_25): ... remove these structures.
src/sfnt/ttpost.c (load_post_names, tt_face_get_ps_name,
tt_face_free_ps_names, load_format_20): Updated accordingly.
(load_format_25): ditto and convert offsets to glyph indices.
|
|
4679fcb6
|
2023-03-29T00:21:00
|
|
[sfnt] Streamline POST format 2.0 handing (cont'd).
* src/sfnt/ttpost.c (load_format_20): Co-allocate the string data and
their pointers, which makes it easier to handle and free them.
(tt_face_free_ps_names): Updated.
* include/freetype/internal/tttypes.h (TT_Post_20): Update type.
|