[review]<hr> line-height problem caused by large font size

VERIFIED FIXED in mozilla0.9.8

Status

()

Core
CSS Parsing and Computation
P3
normal
VERIFIED FIXED
17 years ago
15 years ago

People

(Reporter: hsd_43, Assigned: Pierre Saslawsky)

Tracking

({testcase})

Trunk
mozilla0.9.8
x86
Windows 2000
testcase
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(2 attachments)

(Reporter)

Description

17 years ago
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; m18) Gecko/20001114
BuildID:    2000111404

<hr> tag in a table cell is displayed incorrectly
..... there are breakin spaces but above and below the <hr>

Reproducible: Always
Steps to Reproduce:
just go to the page

Comment 1

17 years ago
--> style system... maybe layout issue.
--> marking NEW.
-->Revising summary. Old Summary:"<hr> tag in a table cell is displayed incorrectly"
-->simple testcase

This whitespace around the horizontal rule is caused by the line-height
adjustment of a 400px font-size declaration in <hr>.

Why would someone set a font-size to a <HR>? 
Assignee: clayton → pierre
Status: UNCONFIRMED → NEW
Component: HTML Element → Style System
Ever confirmed: true
Keywords: testcase
QA Contact: lorca → chrisd
Summary: <hr> tag in a table cell is displayed incorrectly → <hr> line-height problem caused by large font size

Comment 2

17 years ago
Created attachment 19324 [details]
testcase-<hr> with a huge 400px font
Netscape's standard compliance QA team reorganised itself once again, so taking 
remaining non-tables style bugs. Sorry about the spam. I tried to get this done 
directly at the database level, but apparently that is "not easy because of the 
shadow db", "plus it screws up the audit trail", so no can do...
QA Contact: chrisd → ian
(Assignee)

Comment 4

16 years ago
It happens because quirk.css defines:
    hr:before { white-space: pre; content: "\A"; }
    hr:after  { white-space: pre; content: "\A"; }

The linefeed characters cause a 400px space on both sides of the HR.  A fix could 
be to add |font-size:-moz-initial !important;| to the HR declaration.  I am 
really not a fan of !important declarations in UA stylesheets but in that case 
it's fine because HRs could not be styled in previous browsers anyhow.

Here is a patch...

Index: mozilla/layout/html/document/src/quirk.css
===================================================================
RCS file: /m/pub/mozilla/layout/html/document/src/quirk.css,v
retrieving revision 1.32
diff -u -2 -r1.32 quirk.css
--- quirk.css	2001/11/05 15:32:25	1.32
+++ quirk.css	2001/11/19 02:17:37
@@ -279,4 +279,5 @@
   -moz-box-sizing: border-box;
   margin: 0 0.1% 0 0.1%; /* Mmm! Hack-on-a-hack for bug 81776 */
+  font-size: -moz-initial !important;
 }
Status: NEW → ASSIGNED
Summary: <hr> line-height problem caused by large font size → [review]<hr> line-height problem caused by large font size
Target Milestone: --- → mozilla0.9.9
(Assignee)

Comment 5

16 years ago
Marc/Daniel: please r/sr
Target Milestone: mozilla0.9.9 → mozilla0.9.8
(Assignee)

Comment 6

16 years ago
Marc/Daniel: I'll copy the above patch into an attachment for your reviewing 
pleasure.
(Assignee)

Comment 7

16 years ago
Created attachment 62348 [details] [diff] [review]
tiny patch
Comment on attachment 62348 [details] [diff] [review]
tiny patch

r=glazman
Attachment #62348 - Flags: review+

Comment 9

16 years ago
Comment on attachment 62348 [details] [diff] [review]
tiny patch

sr=attinasi
Attachment #62348 - Flags: superreview+
(Assignee)

Comment 10

16 years ago
fixed
Status: ASSIGNED → RESOLVED
Last Resolved: 16 years ago
Resolution: --- → FIXED

Comment 11

15 years ago
v
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.