DesignCraft: An open-source page and layout design editor written by scratch in pure Rust
Merge #427: Text: Optical kerning spaces pairs from their outlines
aionggf12b3443a06d
diff --cc Cargo.lockindex def60b54f,d636cc933..677b76cd6--- a/Cargo.lock+++ b/Cargo.lock@@@ -946,7 -928,7 +946,8 @@@ dependencies ="regex","unicode-bidi","unicode-bidi-mirroring",+ "unicode-script",+ "unicode-segmentation",][[package]]diff --cc ROADMAP.mdindex 3da74a5a6,b9def8094..77f25a75e--- a/ROADMAP.md+++ b/ROADMAP.md@@@ -2,7 -2,7 +2,7 @@@**Stage: pre-alpha** · next: alpha, ~0% and ~15–25 h away; beta ~28 points and ~420–750 h beyond that (the core-workflow gate, not the percentage: ready for real work is already ~47%)- > **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-11 · **Change:** minor (macOS lists fonts that font services and managers activate) · **Target:** Adobe InDesign 2026-> **Last reviewed:** 2026-10-11 · **Last updated:** 2026-10-11 · **Change:** minor (Optical kerning from outlines (#181); 2026-10-10: stage re-normalized to pre-alpha by the core-workflow gate; earlier today: major, full re-measure against InDesign 2026 21.6; restructured to the craftrules progress-docs standard) · **Target:** Adobe InDesign 2026++> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-11 · **Change:** minor (Optical kerning from outlines (#181); macOS lists fonts that font services and managers activate) · **Target:** Adobe InDesign 2026DesignCraft aims at full Adobe InDesign parity, and to be better: faster, open (documented JSONformat + IDML), scriptable by agents (MCP), and available on the web.@@@ -129,12 -129,8 +129,14 @@@ list) · [roadmap.md](docs/roadmap.md)Newest first.+ - **2026-10-11** · Optical kerning (#181): pairs are spaced from their outlines (ink gap per band,+ pulled towards the font's stem gap, bounded) instead of silently using the font's kern pairs.+- **2026-10-11** · New Document laid out like InDesign's (#325): Recent, Saved, Print, Web and+ Mobile preset tabs beside the preset's details; saved document presets live in the engine+ (`file.savePreset`, `file.deletePreset`, `file.new {preset}`); `file.new` takes intent, units,+ start page and per-edge bleed and slug.+- **2026-10-11** · macOS: fonts that font services and managers activate (Adobe Fonts,+ RightFont) are listed, read from the files CoreText has available (#261, #327).- **2026-10-10** · Version 0.6.0; releases add a Linux riscv64 tar.gz (cross-compiled, CLIsmoke-tested under QEMU).- **2026-10-10** · Readiness per audience: full ~47% (method aligned with the standard, wasdiff --cc crates/compose/Cargo.tomlindex 4e7b270f4,d7359234d..8089e4faf--- a/crates/compose/Cargo.toml+++ b/crates/compose/Cargo.toml@@@ -10,8 -10,8 +10,9 @@@ workspace = tru[dependencies]unicode-bidi = { workspace = true }+unicode-segmentation = { workspace = true }unicode-bidi-mirroring = { workspace = true }+ unicode-script = { workspace = true }designcraft-geom = { workspace = true }designcraft-color = { workspace = true }designcraft-doc = { workspace = true }diff --cc crates/compose/src/lib.rsindex d577e7f4d,b834e61da..a5eca2342--- a/crates/compose/src/lib.rs+++ b/crates/compose/src/lib.rs@@@ -13,17 -13,12 +13,18 @@@mod bidi;pub mod breaker;mod cache;+pub mod grep;+mod grid;pub mod hyphen;+pub mod kenten;+mod mojikumi;mod notes;+ pub mod optical;mod overlay;+mod parabox;mod ruby;pub mod shape;+pub mod shatai;pub mod table;pub mod vars;mod warichu;diff --cc crates/compose/src/shape.rsindex e75da3a6a,54b76b086..f336f503e--- a/crates/compose/src/shape.rs+++ b/crates/compose/src/shape.rs@@@ -719,8 -442,11 +720,11 @@@ fn shape_runout: &mut Vec<Glyph>,) {let start = out.len();- shape_run_raw(db, text, range, p, env, style, sub, out);+ shape_run_raw(db, text, range, p, env, styles, sub, out);let run = &mut out[start..];+ if p.kerning == Kerning::Optical {+ crate::optical::kern_run(db, run, p.tracking / 1000.0 * p.size);+ }let em = p.size * p.h_scale;for g in run.iter_mut().filter(|g| g.adv > 0.0 && !g.ch.is_control()) {let (mut left, mut right) = (0.0, 0.0);diff --cc docs/gaps.mdindex 0d5970b0c,f7129224e..ca82ea732--- a/docs/gaps.md+++ b/docs/gaps.md@@@ -1,6 -1,6 +1,6 @@@# Where DesignCraft falls short of InDesign- > **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-11 · **Change:** minor (gap 6: macOS lists fonts that font services and managers activate) · **Target:** Adobe InDesign 2026 (21.6)-> **Last reviewed:** 2026-10-11 · **Last updated:** 2026-10-11 · **Change:** minor (Optical kerning from outlines (#181); 2026-10-10: stage re-normalized to pre-alpha by the core-workflow gate; earlier today: major, first version: gaps from the full re-measure and the issue tracker) · **Target:** Adobe InDesign 2026 (21.6)++> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-11 · **Change:** minor (Optical kerning from outlines (#181); gap 6: macOS lists fonts that font services and managers activate) · **Target:** Adobe InDesign 2026 (21.6)Every known shortfall against InDesign 2026, one entry each, ranked by how much it stops anInDesign professional from doing real work. This is the work list: agents pick from the top.diff --cc docs/typography-parity.mdindex 26ffef23f,a3afae27a..c4bc2c4c4--- a/docs/typography-parity.md+++ b/docs/typography-parity.md@@@ -1,6 -1,6 +1,6 @@@# Typography and composition parity- > **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-11 · **Change:** minor (macOS lists fonts that font services and managers activate) · **Target:** Adobe InDesign 2026 (21.6)-> **Last reviewed:** 2026-10-11 · **Last updated:** 2026-10-11 · **Change:** minor (Optical kerning from outlines (#181); 2026-10-10: major, first version, from the full re-measure) · **Target:** Adobe InDesign 2026 (21.6)++> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-11 · **Change:** minor (Optical kerning from outlines (#181); macOS lists fonts that font services and managers activate) · **Target:** Adobe InDesign 2026 (21.6)Typesetting is what InDesign is bought for. A feature can exist and still set text differentlyfrom InDesign: different line breaks, different page count, overset where InDesign fits. This