jrbenson / dynamic-vector-graphics

This project provides a system that uses annotations on provided data and SVG file to create a dynamic vector graphic.
MIT License
4 stars 0 forks source link

Initially Non-rendered Graphics Have Incorrect Transforms When Rendered #1

Open jrbenson opened 3 years ago

jrbenson commented 3 years ago

Any SVG that is not being rendered by the browser at the time it is initialized does not have access to the initial positions and sizes of many elements using the getBBox() method. To combat this and similar issues that happen on resize there is a draw() callback on DVG objects that recalculates positions as needed to correct the errors. However, some issues persist.

To recreate, use the test harness page and first deselect and then re-select the "Display" option to trigger the issue: Kapture 2021-06-16 at 14 00 30