Repository navigation
v0.5.1 — Typing on long docs is fast again
The headline win is keystroke latency on multi-hundred-line docs.
Fixed
- Typing latency:
Walker.utf16Offsetin the syntax highlighter was O(N) per cmark node — pinned by Instruments at 54% of a 672 ms typing-hang window on a 1000-line doc. Replaced with a cachedLineTableso per-node lookups are O(line_length). Typing on long docs is now smooth. - TextKit 1 migration: NSTextView is now forced onto TK1. TK2's lazy viewport layout was forcing fragment re-measurement inside the paint cycle even after sub-ms storage edits, contributing to the perceived lag. TK1's eager layout matches Writ's doc-size targets and removes a class of TK2-specific quirks.
Polish
math: falsein front matter now also suppresses the$auto-pair while you're in the source view (closes #27).- Custom CSS hot-reloads when the file changes on disk — no need to re-pick it.
- Preview pipeline: JSON encoding moved off main thread; parser priority lowered so it can't preempt keystrokes; debounce bumped to 500 ms so parses don't fire after every character at normal typing speed.
- Front-matter info cached in the text view, invalidated on storage edits.
Download: Writ-0.5.1.dmg (7.0 MB, notarized + stapled)