Bug 50539 - [Qt] Report zero width for zero size fonts
Summary: [Qt] Report zero width for zero size fonts
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Qt (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: QtWebKit Unassigned
Keywords: Qt, QtTriaged
Depends on:
Reported: 2010-12-05 09:45 PST by Robert Hogan
Modified: 2010-12-06 11:26 PST (History)
2 users (show)

See Also:

Patch (1.80 KB, patch)
2010-12-05 09:55 PST, Robert Hogan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Hogan 2010-12-05 09:45:15 PST
Comment 1 Robert Hogan 2010-12-05 09:55:25 PST
Created attachment 75632 [details]
Comment 2 Kenneth Rohde Christiansen 2010-12-05 14:03:34 PST
Comment on attachment 75632 [details]

View in context: https://bugs.webkit.org/attachment.cgi?id=75632&action=review

pls fix before landing

> WebCore/platform/graphics/qt/FontQt.cpp:266
> +        return 0.0f;

this should be 0 according to the style guide

> WebCore/platform/graphics/qt/FontQt.cpp:291
> +        return 0.0f;

here as well
Comment 3 Csaba Osztrogonác 2010-12-06 02:26:28 PST
Comment on attachment 75632 [details]

Fixed patch landed in http://trac.webkit.org/changeset/73352
Comment 4 Robert Hogan 2010-12-06 11:26:36 PST

Is there a bit of a disconnect between Font::drawTextCommon and the actual size of the font (according to webkit)? It uses FontMetrics which may not be appropriate in the case of zero-sized fonts. I suspect QtWebKit is rendering the font full-sized rather than 'no-sized' because of this. What do you think?