Closed Bug 130637 Opened 23 years ago Closed 21 years ago

Form control system font handling quirks code never used

Categories

(Core :: CSS Parsing and Computation, defect)

defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 131452

People

(Reporter: bzbarsky, Assigned: dbaron)

Details

In bug 53617, comment 53 Rod lists the "current Linux code" and "current Mac code" that maps the field, button, and list system fonts in nsRuleNode.cpp. None of this code is ever executed. All the code is conditioned on "if (eCompatibility_NavQuirks == mode)" and earlier in the file we have: 1828 nsCompatibility mode = eCompatibility_Standard; 1829 1830 if (sysID == eSystemFont_Field || 1831 sysID == eSystemFont_List || 1832 sysID == eSystemFont_Button) { 1833 nsCOMPtr<nsIPref> prefService(do_GetService(NS_PREF_CONTRACTID)); 1834 if (prefService) { 1835 PRBool useEitherMode; 1836 if (NS_SUCCEEDED(prefService->GetBoolPref("layout.forms.use_standard_or_quirks", &useEitherMode))) { 1837 if (useEitherMode) { 1838 aPresContext->GetCompatibilityMode(&mode); 1839 } 1840 } 1841 } 1842 } Now the pref layout.forms.use_standard_or_quirks is not defined anywhere in a default profile. So get GetBoolPref fails and |mode| stays standards mode. As a result, we always use whatever GetSystemFont returned, which is utterly bogus in many cases (see bug 130632 and bug 130635).
See also bug 53524 and bug 131452 (and bug 91602).
Status: NEW → ASSIGNED
Priority: -- → P5
Target Milestone: --- → Future
See also #53360
Assignee: rods → dbaron
Status: ASSIGNED → NEW
Priority: P5 → --
Target Milestone: Future → ---
Duplicate of bug 131452? Or do you think we should have used some of that code?
No, it's better to just fix any issues we have at the system font code level so everything using the system fonts gets the fixes. So removing this code was the right thing to do. *** This bug has been marked as a duplicate of 131452 ***
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.