Bug 37683 - [Qt] WebCore::Font::font() causes a QFont detach
Summary: [Qt] WebCore::Font::font() causes a QFont detach
Status: CLOSED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Text (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Simon Hausmann
URL:
Keywords: Qt
Depends on:
Blocks: 35784
  Show dependency treegraph
 
Reported: 2010-04-15 16:47 PDT by Simon Hausmann
Modified: 2010-04-20 12:05 PDT (History)
2 users (show)

See Also:


Attachments
Patch (2.00 KB, patch)
2010-04-15 17:03 PDT, Simon Hausmann
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Hausmann 2010-04-15 16:47:10 PDT
WebCore::Font::font() in platform/graphics/qt/FontQt.cpp calls

    f.setStyleStrategy(QFont::ForceIntegerMetrics);

This causes the QFont object that is owned in FontPlatformData to get detached.

Since the value is always the same, the setStyleStrategy call should be moved to FontPlatformData.
Comment 1 Simon Hausmann 2010-04-15 17:03:34 PDT
Created attachment 53491 [details]
Patch
Comment 2 WebKit Commit Bot 2010-04-16 00:14:28 PDT
Comment on attachment 53491 [details]
Patch

Clearing flags on attachment: 53491

Committed r57717: <http://trac.webkit.org/changeset/57717>
Comment 3 WebKit Commit Bot 2010-04-16 00:14:34 PDT
All reviewed patches have been landed.  Closing bug.
Comment 4 Antonio Gomes 2010-04-16 07:12:43 PDT
(build fix):

Committed r57721: <http://trac.webkit.org/changeset/57721>
Comment 5 Simon Hausmann 2010-04-16 08:08:50 PDT
Thanks Antonio!

I don't know how that happened ;( I built with 4.7. Thanks for the fix!
Comment 6 Simon Hausmann 2010-04-20 12:05:39 PDT
Revision r57717 cherry-picked into qtwebkit-2.0 with commit bed19437e88439572670da41126d0dc463be3298Revision r57721 cherry-picked into qtwebkit-2.0 with commit a4221d7729d4f1ea2a89982f23148c0c59fb9d41