PDA

View Full Version : @font-face not rendering in QtWebView 4.8.0, ignore WOFF files



TimShnaider
27th March 2012, 11:48
Any idea why this font would not be working in QWebView?

(Original page: http://solsticeadvertising.com/)

@font-face {
font-family: 'DeliscriptItalic';
src: url('fonts/style_174735.eot');
src: url('fonts/style_174735.eot?#iefix') format('embedded-opentype'),
url('fonts/style_174735.woff') format('woff'),
url('fonts/style_174735.ttf') format('truetype'),
url('fonts/style_174735.svg#DeliscriptItalic') format('svg');
font-weight: normal;
font-style: normal;

}

I see the .SVG and .TTF fonts loaded in the Inspector, but they do not render as expected.
In Chrome and Firefox the WOFF files are downloaded and render correctly.
QTWebKit 4.8.0 seems to completely ignore WOFF files.

Update: It seems QtWebKit 2.2.0 (as far as I'm aware the version included with Qt 4.8.0) does not have WOFF enabled yet.
I might try applying these changes myself. https://bugs.webkit.org/show_bug.cgi?id=70952

TimShnaider
28th March 2012, 02:43
Update #2 (I can't seem to edit my posts anymore):

Followed changes outlined in attachment linked to https://bugs.webkit.org/show_bug.cgi?id=70952 and now WOFF fonts *almost* render properly for the example site.
The diffs are against a newer set of files than what comes with 4.8.0, just add the changes manually and it works.

Will post an update if I figure out why 1/3 of the WOFF fonts are not rendering...