Bug 37683

Summary: [Qt] WebCore::Font::font() causes a QFont detach
Product: WebKit Reporter: Simon Hausmann <hausmann>
Component: TextAssignee: Simon Hausmann <hausmann>
Status: CLOSED FIXED    
Severity: Normal CC: commit-queue, tonikitoo
Priority: P2 Keywords: Qt
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Bug Depends on:    
Bug Blocks: 35784    
Attachments:
Description Flags
Patch none

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