2 ms·
Apart from maybe simple shapes and fills, I think there is little value in adding a complete object-oriented library of scriptable graphics elements into a UI l
by martin_ky 9y ago
Apart from maybe simple shapes and fills, I think there is little value in adding a complete object-oriented library of scriptable graphics elements into a UI layout / widget language.
For custom drawing needs (charts, data plots, diagrams, etc.), you could use QML Canvas, Context2D and Context3D which offer far greater flexibility with their immediate mode APIs than an object-oriented API could ever provide.
- jancsika 9y ago> QML Canvas Performance scales with size of canvas. I need an API which scales with the number of objects on the canvas. > Context2D Too low level. I don't want to recreate my own subset of SVG-- including handling dirty bboxes and rolling my own viewport. > Context3D These are 2d diagrams so a 3D API is definitely overkill. I'm not making up my functionality needs. My app's frontend is ported from the old Tk canvas interface, and some users end up making diagrams the size of posterboards or billboards. SVG is by no means a sane API but its the only one currently in the entire HTML5 monstrosity that can do everything the old clunky Tk canvas can do.