whoohoo I'm doing it
-
I hate specs. I'd rather look at code to determine how something works. To that end I've been working with two SVG parsing codebases in C to determine how SVG works. You know that point where things finally click? I got there. And most of it is just propagating attribute values and bubbling them down tags. The reason for all of this, is I wanted to peephole parse the whole thing, and render top down so I didn't have to keep a representation of the entire document in memory - just enough of a window of it to render the current step. The result should be much more efficient than what I have been doing, but it's state machines all the way down, because peephole parsing. In any event I have much of the core in place, and I'm peephole parsing all the attributes in the document. The elements are easy by comparison. The main thing I have left is storing gradients and matching them up by ID, and then trying to impose viewbox scaling as I'm parsing, which I HOPE is possible. I'm over the hump.
Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix