Bug 76162 - Font selection fails when including external SVG
: Font selection fails when including external SVG
Status: UNCONFIRMED
: WebKit
SVG
: 528+ (Nightly build)
: Macintosh Intel Mac OS X 10.7
: P2 Normal
Assigned To:
:
:
:
:
  Show dependency treegraph
 
Reported: 2012-01-12 02:58 PST by
Modified: 2012-07-05 14:54 PST (History)


Attachments
Left is included SVG, right is inline SVG. Font selection fails in included SVG (472 bytes, text/html)
2012-01-12 02:58 PST, pom@graougraou.com
no flags Details
The included SVG file (identical to the inline content), works as expected when loaded directly (206 bytes, image/svg+xml)
2012-01-12 02:59 PST, pom@graougraou.com
no flags Details


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2012-01-12 02:58:54 PST
Created an attachment (id=122199) [details]
Left is included SVG, right is inline SVG. Font selection fails in included SVG

When including an external SVG file (e.g. with the SVG <image> tag or the HTML <img> tag), font selection fails for the <text> elements with a "font-family" attribute in the included file. Attached are two files: bug_image_font.html is an HTML that shows two SVG images, one included from the file image.svg and the other inline. Both are identical, but in the included case (left), the sans-serif text is rendered with the default, serif font (at least on my machine.) The inline example (or the included SVG file loaded directly) shows the right fonts.
------- Comment #1 From 2012-01-12 02:59:40 PST -------
Created an attachment (id=122200) [details]
The included SVG file (identical to the inline content), works as expected when loaded directly
------- Comment #2 From 2012-01-12 10:13:42 PST -------
See also: bug 68090.
------- Comment #3 From 2012-06-10 13:12:33 PST -------
This bug is probably invalid, Opera and FF do not support this either. Furthermore, having svg embedded inline in a html document is the workaround anyway. If I get svg-as-image correctly, it is just another image format.
------- Comment #4 From 2012-07-05 14:54:42 PST -------
Firefox does not support svg fonts. In order to be an image format, "svg-as-image" should not change when embedded in an html page. This is not the case with any other format : a jpeg looks the same when seen alone in a browser, or in an html page.