Bug 3303 - CSS2: System defined fonts not supported by font property
Summary: CSS2: System defined fonts not supported by font property
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 412
Hardware: Mac OS X 10.4
: P2 Normal
Assignee: Dave Hyatt
URL: http://www.w3.org/TR/REC-CSS2/fonts.h...
Keywords:
Depends on:
Blocks: 5567
  Show dependency treegraph
 
Reported: 2005-06-07 08:44 PDT by Nicholas Shanks
Modified: 2006-08-16 15:00 PDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nicholas Shanks 2005-06-07 08:44:54 PDT
The system-defined fonts caption, icon, menu, message-box, small-caption and status-bar are not 
supported by the shorthand CSS2 'font' property.

Test case at http://web.nickshanks.com/safari/font
Comment 1 Nicholas Shanks 2006-06-02 10:57:52 PDT
Reassigning to webkit-unassigned, to make sure more people see this.
Comment 2 Dave Hyatt 2006-08-15 15:30:03 PDT
Fixed.  Note that I did not agree with the font sizes mentioned in the test case attached to this bug, so the font sizes chosen are a little different.
Comment 3 David Kilzer (:ddkilzer) 2006-08-15 16:15:34 PDT
r15888 with layout tests in r15889
Comment 4 Nicholas Shanks 2006-08-16 10:25:39 PDT
Those font sizes quoted were at the system's 72 dpi setting, so are in px units, not points.
If you set some text to the sizes mentioned using TextEdit, you should get the same (that's how i discovered the sizes given, trial and error, using whatever version of the OS i had installed on the 15th of April 2005), but I assumed it's best to use system functions such as +[NSFont systemFontOfSize:NSSmallSystemFontSize] and its ilk to generate a px size, then divide by 0.75 to get a 96dpi point size (or other value for other dpis).
Comment 5 Nicholas Shanks 2006-08-16 14:05:39 PDT
One problem I noticed: the specified fonts aren't affected by zooming the text size. Is this really a good idea? I think they ought to be the same as the system at 100%, but grow and shrink along with the rest of the text. I am going to re-open this, but if you think that's correct behaviour, just close it again.
Comment 6 Dave Hyatt 2006-08-16 14:39:17 PDT
Ah yes, that was not intentional (and is in fact a regression, since form controls aren't going to swap out to larger sizes as you zoom).
Comment 7 Dave Hyatt 2006-08-16 15:00:46 PDT
Ok, fixed in r15922.