1
1
mirror of https://github.com/wez/wezterm.git synced 2024-11-30 06:03:39 +03:00
wezterm/deps/freetype
Wez Furlong af815a2e1b fonts: add freetype_pcf_long_family_names option
Freetype has a compile-time feature that, when enabled, rewrites the
font names of PCF fonts to include the foundry and wide status of the
font in order to disambiguate the various versions of fonts all named
"Fixed".

That option is enabled by default in some linux distributions but not
all; it's not enabled in Fedora, for example.

When that feature is enabled it causes problems for the Terminus font as
the PCF version of the fonts are no longer resolvable via the simple
"Terminus" name but via "xos4 Terminus" instead.

wezterm builds its own version of freetype (for consistency and cross
platform support reasons), and is unaware of the choice used by the
distro.

The result of that is that fontconfig may see PCF fonts as having
different font names than how wezterm sees them.

A concrete problem is on such a system, when requesting "xos4 Terminus",
fontconfig will present a match with that name, but when wezterm opens
the font and sees that it has name "Terminus" (because of the difference
in this feature in the freetype libraries in use), wezterm will reject
that match.

This commit enables that option in the freetype library and adds a
wezterm config level option (freetype_pcf_long_family_names) that can be
used to control the underlying pcf font driver configuration.

The upshot of this is that this commit doesn't change any default
behavior, but allows users of those systems to set
`freetype_pcf_long_family_names = true` to turn that behavior on.

My personal opinion on this is that users probably shouldn't use this if
they can avoid it (and PCF fonts in general), and instead install the
OTB version of the Terminus font, which doesn't have this legacy baggage
associated with it!

refs: https://github.com/wez/wezterm/issues/2100
2022-06-09 20:09:47 -07:00
..
freetype2@3f83daeecb upgrade freetype to 2.11.1 2021-12-20 08:22:34 -07:00
libpng@8439534daa Build our own freetype, harfbuzz 2019-03-23 09:28:40 -07:00
src freetype: regenerate ffi bindings 2022-01-31 20:39:05 -07:00
zlib@cacf7f1d4e add zlib dep for windows builds 2019-03-23 11:30:34 -07:00
bindings.h freetype: expose some more constants 2021-10-10 10:18:47 -07:00
build.rs fonts: add freetype_pcf_long_family_names option 2022-06-09 20:09:47 -07:00
Cargo.toml build libz, libpng, freetype, harfbuzz without cmake 2019-11-04 09:40:27 -08:00
regenerate.sh freetype: expose some more constants 2021-10-10 10:18:47 -07:00