Mutability of Path/Layer/Document
abey79 opened this issue · 3 comments
abey79 commented
For operations on Path/Layer/Document structures (e.g. transforms, crop, etc.), I'm using for the moment an immutable pattern (e.g. fn ops(self, ...) -> Self {}
), though clearly the goal is not to have purely immutable structure (e.g. paths addition/removal in layers, layer addition/removal in document, etc.). I'm not sure yet of the implication and if this is a good idea or not.
abey79 commented
Lots of implementation details are getting tedious with this approach, especially around the drawing and mutation from commands such as --translate
& friends.
abey79 commented
There is no going back from mutability, whiskers heavily depends on it.