From 10f57bf04094fb11ca0a9971453daafc07ece115 Mon Sep 17 00:00:00 2001 From: "bzbarsky%mit.edu" Date: Tue, 18 Jun 2002 02:42:40 +0000 Subject: [PATCH] fix rendering of . Bug 150022, r=doron, sr=jst --- content/html/content/src/nsHTMLFontElement.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/content/html/content/src/nsHTMLFontElement.cpp b/content/html/content/src/nsHTMLFontElement.cpp index dba0fd16f32..140d063f923 100644 --- a/content/html/content/src/nsHTMLFontElement.cpp +++ b/content/html/content/src/nsHTMLFontElement.cpp @@ -263,8 +263,9 @@ MapAttributesIntoRule(const nsIHTMLMappedAttributes* aAttributes, if ((value.GetUnit() == eHTMLUnit_Integer) || (value.GetUnit() == eHTMLUnit_Enumerated)) { PRInt32 size = value.GetIntValue(); - if (size) { - if (value.GetUnit() == eHTMLUnit_Integer) // int (+/-) + nsHTMLUnit unit = value.GetUnit(); + if (size || unit == eHTMLUnit_Integer) { // unit is integer if attr was "+0" or "-0" + if (unit == eHTMLUnit_Integer) // int (+/-) size = 3 + size; // XXX should be BASEFONT, not three size = ((0 < size) ? ((size < 8) ? size : 7) : 1);