Bug 115883

Summary: Don't trust character widths for internal OS X fonts in form controls
Product: WebKit Reporter: Dean Jackson <dino>
Component: TextAssignee: Dean Jackson <dino>
Status: RESOLVED FIXED    
Severity: Normal CC: enrica, simon.fraser
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch darin: review+

Description Dean Jackson 2013-05-09 17:24:27 PDT
There are a few fonts we mark as having invalid character widths when laying out form controls. Some internal fonts on OS X are not listed, but these all start with a ".", so they should be easy to test for.
Comment 1 Dean Jackson 2013-05-09 17:24:39 PDT
<rdar://problem/13817757>
Comment 2 Dean Jackson 2013-05-09 17:28:05 PDT
Created attachment 201306 [details]
Patch
Comment 3 Darin Adler 2013-05-09 18:26:11 PDT
Comment on attachment 201306 [details]
Patch

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

> Source/WebCore/rendering/RenderTextControl.cpp:234
> +    if (family.startsWith('.'))
> +        return false;

Needs a “why” comment.

Also, I’d put this before the map building code. It seems strange to have this in between the map building and the use of the map.
Comment 4 Dean Jackson 2013-05-10 09:18:06 PDT
Committed r149880: <http://trac.webkit.org/changeset/149880>
Comment 5 Simon Fraser (smfr) 2013-10-23 17:04:34 PDT
This caused bug 123235.