mirror of
https://github.com/storytold/photocraft.git
synced 2026-10-14 19:26:51 -04:00
* Type: scan system fonts off the UI thread (#3021) The first `photocraft_text::shared()` call scans every installed font, and nothing made that call before the Type tool's options bar drew its font menu, so the scan ran inside a UI frame (over 60 s on some Macs, #2518). - photocraft-text: `warm_shared()` starts the scan on a background thread; `try_shared()` returns the engine without blocking (None while the scan runs, started there if nobody warmed it; built in place on the web, in tests, if the thread can't start or the worker died). `shared()` keeps its blocking behaviour for engine commands. - The desktop app warms the fonts at start-up. - Font menus that draw every frame (options bar, Character, Glyphs and the Character/Paragraph Styles family menus) show a disabled "Loading fonts…" box and repaint until the scan is done. "Loading fonts…" is in all 16 catalogs. Complements #2644 (CoreText discovery on macOS): this changes where the scan runs, not how fonts are discovered. Co-Authored-By: Claude Opus 5.5 <[email protected]> * Type: axis sliders wait for the background font scan too #2996 (landed on main) added axis_sliders, which called the blocking photocraft_text::shared() every frame; use try_shared() so the Character section doesn't stall while the scan runs. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]> Co-authored-by: Brandon Thomas <[email protected]>