Note: There are a few cases of duplicates in user autocompletion which are being worked on.

[FIXED]TD Shouldn't have to have a spacer gif for background color to show

VERIFIED FIXED in M16

Status

()

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

People

(Reporter: Johnny Proton, Assigned: Pierre Saslawsky)

Tracking

({testcase})

Trunk
x86
Windows 98
testcase
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

18 years ago
Mozilla forces HTML programmers to put something inside each table cell even in
cases when all we want to display is the background color of a cell.

This is pervasive, as far as I can tell, and applies to both the HTML bgcolor
and the CSS background-color declaration.  It shouldn't be necessary to put a
spacer gif inside each table cell, as it only bloats the code and forces
unnecessary download by the client.

This is, in my opinion, a pretty important bug, and would really help reduce
time for HTML development, while also simplifying the code we have to work with.

- Aaron Buckner
- http://cicadadesign.com/
According to the CSS2 spec the default value for empty-cells should be 'show'.
Mozilla currently has 'hide' which is correct in quirks mode but not in strict mode.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Guess this is more a layout problem since it is just the default css value that
is wrong.

Chaning component and reassigning...
Assignee: karnaze → troy
Component: HTMLTables → Layout
Keywords: testcase
QA Contact: chrisd → petersen
Created attachment 6925 [details]
Testcase in strict mode. Both rows of the table should render equal.

Comment 4

18 years ago
Changing back to tables, because it sounds table specific to me
Assignee: troy → karnaze
Component: Layout → HTMLTables
QA Contact: petersen → chrisd
This actually is a stylesystems bug since it is just the default value 
of 'empty-cells' that is wrong. Should be:

In quirks: 'hide'
In strict: 'show'

(Is now 'hide' in both)

Note to abuckner@cicadadesign.com, the problem of backgrounds not shown even 
when empty-cells are set to 'show' is covered in bug 8113.
Assignee: karnaze → pierre
Component: HTMLTables → Style System
The default value could be 'hide' for the TABLE element in HTML, though...
According to the HTML spec empty cells should show (or rather; there is nothing 
in the spec that says that they should hide) so I still think this has to be 
solved by using a quirks hack.
(Assignee)

Comment 8

18 years ago
I'll check in the fix when the tree opens.
Thanks to sicking@bigfoot.com for the testcase and the investigation.
Status: NEW → ASSIGNED
Summary: TD Shouldn't have to have a spacer gif for background color to show → [FIXED]TD Shouldn't have to have a spacer gif for background color to show
Target Milestone: --- → M16
What fix is being checked in?  Will it affect conformance to section 17.5.1
(rule 6) of CSS2?
(Assignee)

Comment 10

18 years ago
I changed the default value for empty-cells: 'hide' in quirks mode and 'show' in 
strict mode. MacIE5 does the same thing.

The transparency of empty cells (17.5.1#6) was broken and stays so (bug 8113). 
I'm going to attach a small testcase there.
(Assignee)

Comment 11

18 years ago
fix checked in nsStyleContext.cpp
Status: ASSIGNED → RESOLVED
Last Resolved: 18 years ago
Resolution: --- → FIXED

Comment 12

17 years ago
Verified bug fixed. Quirk default is 'hide' and strict default is 'show'
Status: RESOLVED → VERIFIED
Quirks mode / Nav DTD 
A document without a DOCTYPE declaration 

from: http://www.people.fas.harvard.edu/~dbaron/mozilla/modes

I don't agree quirks mode should have a need for a spacer image. There is 
nothing that will get broken by removing the need for the spacer for existing 
pages. If the spacer is placed there, it will not affect anything and will work 
fine whether show is default or not. Therefore, show should always be default.

Anyway, a lot of pages don't have any doctype and should be automatically 
transitional, not quirks.

The quirks mode rendering is incorrect, and fixing it won't have any adverse 
affect.

Netscape 4.x had a bug in this respect, and if someone forgets to put the 
doctype, they will see this bug. I don't think that is correct.
Please see the recent changes to bug 8113.
(Reporter)

Comment 15

17 years ago
Quirks mode shouldn't be the default.  I think the name "Quirks" says it all.
*Please* don't make this into a "what should trigger quirks/standard mode" bug!

However the default value for empty-cells in quirks mode could do with a 
discussion (I'd personally like 'show' to be default). But I'd recommend 
starting that discussion in n.p.m.layout
Quirks mode _isn't_ the default. We only do it for stuff sent over the wire as
text/html, and even some of those get treated in Standard mode.
(Reporter)

Comment 18

17 years ago
I know that by default mozilla renders Empty Cells as "hide".  And that's about 
all I know, except I know I shouldn't have to put a spacer GIF in a TD to assign 
a background color.

Anyone who does HTML often know's this is a major deficiency and that MSIE 
already [correctly] displays empty cells as "show".  I like Mozilla, but this 
should honestly be an easy one!
You need to log in before you can comment on or make changes to this bug.