mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-14 19:26:56 -04:00
Lock › All Artwork Above and Hide › All Artwork Above went through the objects above each selected object in its top-level layer, one selected object at a time. For each object they looked up in a list whether it was selected or already found, and they computed its bounds again for each selected object below it until one overlapped it. With 100 tiles selected under 25,000 rectangles, a release build of vectorcraft-cli took 6.4 s for Lock, and with all of 5,001 objects selected it took 8.8 s and locked nothing. The commands now go through each top-level layer that holds a selected object once, and check each object that is not selected against the bounds of the selected objects below it. The selected objects and the objects found are kept in sets, and each object's bounds are computed once. The objects they lock or hide, the count, the selection and the undo step are the same as before. On the same documents Lock now takes under 0.1 s. Docs: docs/target-app-parity.md.