Closed Bug 97726 Opened 23 years ago Closed 23 years ago

line-height&font-size (W3C CSS1 test suite failure)

Categories

(Core :: CSS Parsing and Computation, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla0.9.6

People

(Reporter: ldeller, Assigned: dbaron)

References

()

Details

(Keywords: regression, testcase, Whiteboard: [Hixie-P1][PDT-])

Attachments

(1 file)

The given URL is part of W3C's CSS1 test suite.  Look for the paragraph which reads:
<quote>
This sentence should have a line-height of twice the DIV's font size, or 28px;
this should not cause extra spacing between the lines, since the line-height and
font-size should have the same value.
</quote>

In Mozilla 0.9.3, the sentence *does* have extra spacing between lines.  (I
noticed it by comparing with IE6 which has no extra spacing between lines).
Is this because we are in quirks mode for that page?

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">

The Doctype is 4.0, not 4.01
I tried with a standard 4.01 doctype and that's wasn't different :/
Yeah, I noticed this too, and meant to file a bug.  Any ideas what happened? 
This is a pretty serious regression.
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Target Milestone: --- → mozilla0.9.4
Is this a lurker all the way from my 6/1 landing?  If so, wow.  We need to put
this page in the layout regression tests.
(Just to confirm, a 06/01 build shows this testcase with excessive line-height,
while a 5/29 build does not).
Are we inheriting the specified percentage values instead of the computed values?

For the record:

 if the specified value is...  the computed value of line-height should be...
 -------------------------------------------------------------------------------
 a number                      the number
 a percentage                  the computed length resulting from the percentage
 an absolute or pixel length   the length in internal units (twips or pixels)
 an 'em' or 'ex' length        the length in internal units (twips or pixels)
 'normal'                      'normal'
I'm sure this is a very recent regression. I'm sure I would have spotted it if
this was broken when the new rule system landed. It's clear on:

   http://www.bath.ac.uk/%7Epy8ieh/internet/eviltests/lineheight1.html

If it's not a new regression then I am very embarassed. :-|
Keywords: regression, testcase
Whiteboard: [Hixie-P1]
eek, it was broken in N6.1. I am soooo sorry. I suck.
Bug 91054 described another problem of inheritance with percentage values.
Blocks: 91672
I *think* this one is different.
dbaron, let me know if you want me to take this, since it seems to be a ruletree
regression.  Also, we should get this page into the layout regression tests, so
that it will contain a case like this in the future.
Moving to 0.9.5 per PDT, and adding PDT. Please try and make the 0.9.4 train.
Whiteboard: [Hixie-P1] → PDT,[Hixie-P1]
Target Milestone: mozilla0.9.4 → mozilla0.9.5
Target Milestone: mozilla0.9.5 → mozilla0.9.6
Tested on:
Linux with 10_10_04_0.9.4 build
Mac OS10 with 10_10_04_0.9.4 build

Same problem. Changing 'Platform' and 'OS' to 'all' 
OS: Windows 2000 → All
Hardware: PC → All
is this something we should consider a ull it off the wire for the 094 release?
pls advise ...
No.
ok ... PDT-, because this is not a stopper for this release.
Whiteboard: PDT,[Hixie-P1] → [PDT-],[Hixie-P1]
Whiteboard: [PDT-],[Hixie-P1] → [Hixie-P1][PDT-]
See also http://bugzilla.mozilla.org/attachment.cgi?id=54852&action=view
from bug 91054 -- we do inherit properly if it's explicitly requested.
Attached patch proposed fix (deleted) — Splinter Review
sr=hyatt
Comment on attachment 56352 [details] [diff] [review]
proposed fix

r=pierre
Blocks: 93865
Fix checked in 2001-11-05 23:48 PDT.
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
This fix (appearing in Mozilla 0.9.6) had a strange effect on my homepage:
"line-height: 105%;" stopped working like I expected (and like it did on Mozilla
0.9.5): for example, when using View->Text Zoom->200%, the lines go all over
each other (I guess 105% of the original default size is used). "line-height:
1.05em;" never worked properly.

Anyway, now only "line-height: 1.05;" works like I want it to.

Is that intentional? Is that what the CSS standard dictates?
Well, 105% should work just like 1.05em -- yes, that's what the standard
dictates.  However, Text Zoom is known to be broken in many ways.  I also messed
up this fix -- see bug 111405.
The issue of overlapping lines with text zoom is bug 95267.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: