piqnt / svgexport

SVG to PNG/JPEG command-line tool and Node.js module
927 stars 85 forks source link

Does not preserve custom fonts #17

Closed goosehub closed 9 years ago

goosehub commented 9 years ago

This does not support fonts, and as I see in the docs, there is no way to link the font to the SVG. This would be an important enhancement. Unfortunately, I have yet to find a project that can handle this.

shakiba commented 9 years ago

What do you mean by "link the font to the SVG"?

goosehub commented 9 years ago

The font for text in an SVG is not (usually) inside of the SVG itself. The SVG instead has a link that points to the font that is used in the SVG. It's definitely not an easy feature; as far as I can see, there is no projects that export SVGs with custom fonts, but I thought I'd bring it up for discussion, since you may have a better idea of what this will involve.

shakiba commented 9 years ago

As far as I know it is supported, see #12.

goosehub commented 9 years ago

I see. My particular case is an SVG without an inline style tag for font faces, where font faces are loaded separately, but doing so is probably more reasonable than passing the font name and url through different means.