mirror of
https://github.com/storytold/figcraft.git
synced 2026-10-26 03:16:53 -06:00
Each frame checks the active document's names for CJK scripts, to install faces for them. The check was keyed on the revision, which pans and zooms bump too, so every frame of a pan read every layer name. In a 900 000-layer file that was ~70 ms a frame: panning ran at ~14 fps whatever the canvas cost. It now keeps the document version it read: the same version (a pan, a zoom) is skipped, and a new one reads only the layers that changed since (`Document::changed_ids`, sized by the edit), or every name past 10 000 changes. On that file the UI frame while panning went from ~71 ms to ~3 ms. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YQxjkNSUJhTkTfY74aNeki