3 ms·
You just spotted an eight year old contextual feature. While the parser will leave a path "open", only signalling an explicit "close" when it sees `z` or `Z`, i
by TheRealPomax 8y ago
You just spotted an eight year old contextual feature. While the parser will leave a path "open", only signalling an explicit "close" when it sees `z` or `Z`, it still signals the start of a new path when it sees an `m` or `M` somewhere mid-path. And that's why you're seeing closed shapes even though there don't appear to be any in the original SVG:
There is no such thing as an "open path" in glyph outlines used in fonts (which was the context of this exploratory), so whenever the parser signals a "new path" signal, even when not preceded by a "close path" signal, that's automatically a closed path and the receiver code I wrote treats it as such.
(The starting SVG string was a straight graphics instruction dump from a OpenType-CFF glyph charstring, although I can't for the life of me remember which typeface it came from... it's been a while)