mirror of
https://github.com/hanzoai/font.git
synced 2026-11-02 23:42:52 +00:00
The page said "set ss09 for the slashed zero", and in Zen Mono ss09 does the opposite: the default zero is drawn WITH the slash — three contours, the first a four-point diagonal — and the set takes it out. Sans is the other way round, because a sans sets prose and a mono sets code, so each ships the zero its reader wants. ss08 was described as flatter accents; it swaps square umlaut dots for round ones. So a form carries a sentence per family rather than one for all three, and the presence of a sentence is what says the set exists there — which is also how Mono's missing ss05 and Pixel's missing ss07/ss08 disappear from the row. The Zen Mono section now states what was measured rather than what was assumed: 0.6 em to a glyph, the zero slashed out of the box, and 1, l and I each on a foot so none is a bare stroke. zen cut reaches the instancer from the command line, so the same cut is available from the CLI, the library and the page.
46 lines
1.6 KiB
TOML
46 lines
1.6 KiB
TOML
[package]
|
|
name = "zen"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
description = "Zen type tooling: optical kerning, parameter fitting and identity, from the outlines."
|
|
license = "MIT OR Apache-2.0"
|
|
repository = "https://git.hanzo.ai/hanzoai/font"
|
|
|
|
[lib]
|
|
crate-type = ["cdylib", "rlib"]
|
|
|
|
# skrifa reads outlines and applies a variation instance; write-fonts serialises a
|
|
# modified table back. Both are pure Rust with no C, which is what makes the same
|
|
# source compile to a native binary and to wasm32 with nothing swapped out.
|
|
#
|
|
# Nothing else is pulled in. Flattening and rasterising are ~150 lines here rather
|
|
# than a rasteriser dependency, because the scanline machinery the kerner already
|
|
# needs IS a rasteriser — taking tiny-skia for the fitter would mean two ways to
|
|
# ask the same question, and several hundred KB of wasm for the privilege.
|
|
[dependencies]
|
|
skrifa = { version = "0.37", default-features = false, features = ["std"] }
|
|
write-fonts = { version = "0.52", default-features = false, features = ["tables", "read"], optional = true }
|
|
wasm-bindgen = { version = "0.2", optional = true }
|
|
serde = { version = "1", features = ["derive"], optional = true }
|
|
serde_json = { version = "1", optional = true }
|
|
|
|
[features]
|
|
default = ["cli"]
|
|
# The identity rewrite needs a serialiser; the measurements do not, so a wasm
|
|
# build that only fits and kerns does not carry one.
|
|
name = ["dep:write-fonts"]
|
|
wasm = ["dep:wasm-bindgen", "dep:serde", "dep:serde_json", "name"]
|
|
cli = ["name"]
|
|
|
|
[[bin]]
|
|
name = "zen"
|
|
path = "src/main.rs"
|
|
required-features = ["cli"]
|
|
|
|
[profile.release]
|
|
opt-level = 3
|
|
lto = true
|
|
codegen-units = 1
|
|
panic = "abort"
|
|
strip = true
|