Bug 67387

Summary: [Chromium] Webfonts display bold in Windows
Product: WebKit Reporter: Kenichi Ishibashi <bashi>
Component: PlatformAssignee: Kenichi Ishibashi <bashi>
Status: RESOLVED FIXED    
Severity: Normal CC: evan, tony, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
URL: http://crbug.com/94903
Attachments:
Description Flags
Patch none

Description Kenichi Ishibashi 2011-09-01 04:46:23 PDT
Chromium bug entry: http://crbug.com/94903

Chromium win port uses CreateFontIndirect() to create FontCustomPlatformData object for webfonts.  A webfont could be wider (or narrower) than expected when the font's weight class isn't normal(400) because CreateFontIndirect() adjusts font weight according to LOGFONT.lfWeight. For webfonts, we should set LOGFONT.lfWeight to FW_DONTCARE, which means using a default weight.
Comment 1 Kenichi Ishibashi 2011-09-01 04:55:38 PDT
Created attachment 105942 [details]
Patch
Comment 2 Kenichi Ishibashi 2011-09-01 05:01:59 PDT
I didn't come up with how to test for this patch because testing this patch requires a non-local font whose weight class isn't normal..
Comment 3 Kent Tamura 2011-09-02 02:35:27 PDT
Comment on attachment 105942 [details]
Patch

ok
Comment 4 Kenichi Ishibashi 2011-09-02 02:36:40 PDT
Comment on attachment 105942 [details]
Patch

Kent-san,

Thank you for review!
Comment 5 WebKit Review Bot 2011-09-02 03:38:04 PDT
Comment on attachment 105942 [details]
Patch

Clearing flags on attachment: 105942

Committed r94400: <http://trac.webkit.org/changeset/94400>
Comment 6 WebKit Review Bot 2011-09-02 03:38:08 PDT
All reviewed patches have been landed.  Closing bug.