openstrat
openstrat copied to clipboard
Graphics and Geometry version 5
Make the GraphicElems fully functional or non-imperative. Currently the rendToCanvas method on all GraphicElem's works imperatively, while the active capabilities are not implemented through this imperative method. So the rendToCanvas method will be removed and any output from CompoundGraphics will be expressed in SimpleGraphicElems.
The CanvasPlatform and the various GUIs of the pCanv package will become the interface between the immutable, functional GraphicElems and the imperative implementations of the CanvasPlatform interface.
Sort out the various CurveSeg classes and their associated Graphic classes. The Graphic classes should use composition not inheritance. And then remove the last of the Parent classes.
There will now be 3 types of TextGraphics.
- The old standard TextGraphics that function similarly to the typical Fills and Draw graphics. these can be stand alone or be child graphics of a CompoundGraphic.
- TextFacets whose output and fontSize are determined when sent to the canvas dependant on the space of the shape at that time, not when they are created. If the Shape is too small the text graphic will not be output at all.
- TextCells these are text cells designed for control bars, and tables. By default they contain no formatting data.
I plan to make changes in CircleCompound first.
@mghildiy So I'm planning on breaking this issue into a number of smaller issues. It was useful for a while to have various strands collected into one issue but I feel as the API is stabiising that is no longer the case.
So #131, #132 are the first of these smaller narrower issues.