Port rsvg-styles.c to Rust
RsvgState, our CSS state struct. It has a lot of
bool has_foo and
SomeType foo fields to indicate whether a particular property was specified in the SVG or CSS data; those map well to
I am not sure whether we can make the following assertions, but I think we can, and I'd like to ensure that they are true:
Nodeis created and its
set_atts()method is called, the node's
RsvgStateshould be immutable.
The only mutable
RsvgStateis the stack-of-states maintained in
RsvgDrawingCtx, and any temporary states created here and there.
Also, there are functions which look like methods but aren't, like
void rsvg_state_pop (RsvgDrawingCtx * ctx);. Maybe rename it to