[strict]  in white-space: normal cell causes image width to be omitted from cell width

RESOLVED DUPLICATE of bug 42495

Status

()

Core
Layout: Tables
P3
normal
RESOLVED DUPLICATE of bug 42495
17 years ago
15 years ago

People

(Reporter: jsp, Unassigned)

Tracking

({testcase})

Trunk
Future
x86
Windows 2000
testcase
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [awd:tbl][p3][CSS1-5.6.2])

Attachments

(1 attachment)

(Reporter)

Description

17 years ago
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.6+)
Gecko/20011203
BuildID:    2001120303

If a table cell with white-space: normal includes text and an image but no white
space other than non-breaking spaces, the minimum cell width calculation appears
incorrect.

Reproducible: Always
Steps to Reproduce:
1. Load the attachment.
2. Narrow the window until it's no longer wide enough for the text in the first
table.

Actual Results:  When the window gets too narrow, the right border of the first
table overdraws the text.

Expected Results:  The border should stay outside the cell content, as in the
second and third tables in the attachment.

This has features similar to a number of table layout bugs, but I didn't find
any others that were clearly identical.
(Reporter)

Comment 1

17 years ago
For some reason, I can't create an attachment. Bugzilla keeps telling me the
file is empty. (I tried several flavors of Mozilla and IE 6.) Herewith the HTML:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
  <head>
    <title>&amp;nbsp; in white-space: normal cell causes image width to be
omitted from cell width</title>
    <style type="text/css">
      td
      {
        color:               black;
        background-color:    white;
        border:              1px solid;
      }
    </style>
  </head>
  <body>
    <table>
      <tr>
        <td><img
src="http://tinderbox.mozilla.org/star.gif"/>&nbsp;The&nbsp;quick&nbsp;brown&nbsp;fox&nbsp;jumps&nbsp;over&nbsp;the&nbsp;lazy&nbsp;dog.</td>
      </tr>
    </table>
    <p>
      The above table includes an image and several words in a single cell.
      The only whitespace is non-breaking spaces (&amp;nbsp;). When the browser
      window is made too narrow to fit the text, the text overflows the cell.
      I'm not entirely certain that this is a bug, but neither IE nor Opera
      behaves this way.
    </p>
    <table>
      <tr>
       
<td>The&nbsp;quick&nbsp;brown&nbsp;fox&nbsp;jumps&nbsp;over&nbsp;the&nbsp;lazy&nbsp;dog.</td>
      </tr>
    </table>
    <p>
      The above table is similar to the first but omits the image. It behaves
      reasonably when the window is narrowed. That is, the cell never becomes
      too small for its contents.
    </p>
    <table>
      <tr>
        <td style="white-space: nowrap;"><img
src="http://tinderbox.mozilla.org/star.gif"/>&nbsp;The&nbsp;quick&nbsp;brown&nbsp;fox&nbsp;jumps&nbsp;over&nbsp;the&nbsp;lazy&nbsp;dog.</td>
      </tr>
    </table>
    <p>
      The above table is also similar to the first, but specifies
      "white-space: nowrap". It behaves reasonably when the window is narrowed.
    </p>
  </body>
</html>
This happens in standards mode only.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: &nbsp; in white-space: normal cell causes image width to be omitted from cell width → [strict]&nbsp; in white-space: normal cell causes image width to be omitted from cell width

Comment 4

16 years ago
Temporarily moving to future until a milestone can be assigned. 
Status: NEW → ASSIGNED
Target Milestone: --- → Future

Comment 5

16 years ago
if by standards mode, you mean strict.dtd, this happens in both transitional 
(the given testcase) and in strict mode.

the bug I mean (the text overflowing the table border with a narrow window).

removing [strict]
Whiteboard: [awd:tbl][p3]
Keywords: testcase
Whiteboard: [awd:tbl][p3] → [awd:tbl][p3][CSS1-5.6.2]

Updated

16 years ago
Priority: -- → P2

Comment 6

15 years ago
mass reassign to default owner
Assignee: karnaze → table
Status: ASSIGNED → NEW
QA Contact: amar → madhur
Target Milestone: Future → ---

Updated

15 years ago
Target Milestone: --- → Future
-> P3:Future
Priority: P2 → P3

Comment 8

15 years ago

*** This bug has been marked as a duplicate of 42495 ***
Status: NEW → RESOLVED
Last Resolved: 15 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.