Closed Bug 83330 Opened 24 years ago Closed 4 years ago

<img> and <input> overlap in <td nowrap> (space next to replaced element creates overflow)

Categories

(Core :: Layout: Floats, defect, P3)

defect

Tracking

()

RESOLVED WORKSFORME
Future

People

(Reporter: awiner, Unassigned)

References

Details

(Keywords: testcase)

Attachments

(4 files, 1 obsolete file)

Build ID: 2001053004 The following HTML generates overlapping text: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <body> <table> <tr> <td align="right" nowrap> <img width="38"> <label>Prompt 2</label> </td> <td>Foo</td> </tr> </table> </body> </html> The "Prompt 2" and "Foo" overlap, when clearly they should not. The "nowrap" is essential, as is the <img>. In my real HTML, I've got a legit "src" attribute on that <img>, but that doesn't matter for this example. This seems very likely related to bug 47149, but neither that bug nor any of its dups or any other <label> bugs specifically mention this issue. This bug pretty completely trashes our layouts.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Changing to HTML Tables
Component: Layout → HTMLTables
QA Contact: petersen → amar
I see this on build 2001072321 on Linux as well. OS -> ALL? but it hasnt't got anything to do with the <label> tag. It's the nowrap that is causing the overlapping effect. See http://www.alphaworks.ibm.com/reg/xmlsecuritysuite.nsf/techuser?OpenForm&lic=57652890813A90F98825670D007F46C5&file=http://apps.alphaworks.ibm.com/technologies/xmlsecuritysuite/xss4j-20010420.zip&tech=xmlsecuritysuite or the attached testcase where the image should be aligned right but isn't and the text is over the checkbox. Removing the 'nowrap=""' solves the problem changing it to 'nowrap' doesn't.
Attached file minimal testcase
dup of bug #45621?
The statement "it hasnt't got anything to do with the <label> tag" is not true. If you remove the <label> tag from my testcase, there's no overlap anymore. Likewise, if you delete the "nowrap", there's no overlap. Hence, I filed this bug against <label> inside <td nowrap>. Replacing the <label> with, for example, <input type="checkbox"> also doesn't result in overlap - there does appear to be something special about <label>. Also, the testcase given by Ronald van Kuijk only uses a single <td>, and seems to describe overlap _within_ a single <td>, but my testcase shows overlap betweeen two <td>'s. All of this isn't to say that these two cases might not be exactly the same bug, just that there doesn't seem to be enough evidence to reach that conclusion.
reassigning to alexsavulov.
Assignee: karnaze → alexsavulov
http://www.winvoice.com/testlabel.htm is another example showing this bug(at least with build 2001080703). I have some radio buttons with labels in a table and noticed it and played around reproducing it. Unfortunately I didn't write down what version of Mozilla I was using earlier, but in older versions it worked fine.
Added some things to http://www.winvoice.com/testlabel.htm and retried with 8-8-01 nightly. Anytime something with a <label> is centered it displays incorrectly. The same <td>'s described in the original, if set for align=left, should work correctly. Hopefuly this narrows down where the problem is.
Keywords: testcase
This bug has been resolved by the fix for bug 47149. I think it's just a side-effect of that fix as opposed to being a duplicate, so I'll leave it to the Mozilla developers to decide how to close this one up.
This still doesn't seem to be working, checking the testcase.
Keywords: html4
The original testcase I provided _is_ fixed. So, the "minimal testcase" attached by rtvkuijk@netscape.net is, as I suggested, an entirely different bug and should be filed as such. The two cases are very different - mine was overlap between two <td>s, his was overlap within a single <td>.
Attached file Original testcase (obsolete) —
I agree... I posted Bug 99259 with my test case. This one seems to be fixed.
Keywords: html4
Summary: [LBL]<label> element in <td nowrap> can lead to overlapping cells → <img> and <input> overlap in <td nowrap>
Attachment #48934 - Attachment is obsolete: true
*** Bug 104362 has been marked as a duplicate of this bug. ***
this is an old and painfull issue setting milestone and dependencies
Depends on: 99097
Target Milestone: --- → mozilla1.1
Summary: <img> and <input> overlap in <td nowrap> → <img> and <input> overlap in <td nowrap>[FLOAT]
Attached file yet another testcase
ok here is a testcase without the <input> checkbox. Notice that the first time the page loads it works fine, but try reloading the page. And then try shift-reloading the page. I suspect that there is something funny going on with the cache/reflow interaction.
the reflow problem gets fixed by the patch to bug 78820. however there is still a remaining issue that has to be solved. will continue the work on bug 78820.
Depends on: 78820
No longer depends on: 99097
With border red and blu we'll see the problem
->Layout:Floats
Assignee: alexsavulov → float
Component: Layout: Tables → Layout: Floats
QA Contact: amar → ian
Target Milestone: mozilla1.1alpha → ---
Priority: -- → P2
Target Milestone: --- → Future
I don't see the bug in the testcases. Isn't this already been fixed by fixing bug 78820?
*** Bug 226921 has been marked as a duplicate of this bug. ***
OS: Windows 2000 → All
Hardware: PC → All
Summary: <img> and <input> overlap in <td nowrap>[FLOAT] → <img> and <input> overlap in <td nowrap> (space next to replaced element creates overflow)
*** Bug 283023 has been marked as a duplicate of this bug. ***
No one is working on this? Wish I had the background to tackle this, been open since 2001 at major severity. It's a pretty big annoyance on some sites I visit, as it always draws a scrollbar due to the overflow. Anyone know someone who can take this?
Assignee: layout.floats → nobody
QA Contact: ian → layout.floats
Moving to p3 because no activity for at least 1 year(s). See https://github.com/mozilla/bug-handling/blob/master/policy/triage-bugzilla.md#how-do-you-triage for more information
Priority: P2 → P3

Tested around all the added testcases of this issue and I could no longer reproduce overlapping elements on the latest Nightly 95.0a1. Closing this as resolved:worksforme. If this issue is still reproducible for you, please do re-open it.

Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: