mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-01 08:42:13 +00:00
Handle the minimum font size being changed to 0 correctly. Bug 327054, r+sr=roc
This commit is contained in:
parent
c0fca2db20
commit
3c2930f20a
@ -347,13 +347,11 @@ nsPresContext::GetFontPreferences()
|
||||
pref.Append(langGroup);
|
||||
|
||||
PRInt32 size = nsContentUtils::GetIntPref(pref.get());
|
||||
if (size > 0) {
|
||||
if (unit == eUnit_px) {
|
||||
mMinimumFontSize = NSFloatPixelsToTwips((float)size, p2t);
|
||||
}
|
||||
else if (unit == eUnit_pt) {
|
||||
mMinimumFontSize = NSIntPointsToTwips(size);
|
||||
}
|
||||
if (unit == eUnit_px) {
|
||||
mMinimumFontSize = NSFloatPixelsToTwips((float)size, p2t);
|
||||
}
|
||||
else if (unit == eUnit_pt) {
|
||||
mMinimumFontSize = NSIntPointsToTwips(size);
|
||||
}
|
||||
|
||||
// get attributes specific to each generic font
|
||||
|
Loading…
Reference in New Issue
Block a user