Cargo Features

[dependencies]
fontdb = { version = "0.23.0", default-features = false, features = ["std", "fs", "memmap", "fontconfig"] }
default = fontconfig, fs, memmap, std

These default features are set whenever fontdb is added without default-features = false somewhere in the dependency tree.

std default fs

Enables std of ttf-parser

ttf-parser:

Enables the use of the standard library. When disabled, the no-std-float feature must be enabled instead.

fs default fontconfig memmap = std

Allows local filesystem interactions.

memmap default = fs, memmap2

Allows font files memory mapping, greatly improves performance.

fontconfig default = fontconfig-parser, fs

Enables minimal fontconfig support on Linux.
Must be enabled for NixOS, otherwise no fonts will be loaded.

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

memmap2 memmap
fontconfig-parser unix not mac android fontconfig