Closed Bug 269587 Opened 20 years ago Closed 20 years ago

<pre> not respecting defined border

Categories

(Core :: Layout, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 248139

People

(Reporter: chris.roske, Unassigned)

Details

(Keywords: testcase)

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0

When you create a style with a wrap around border and do a <pre> mozilla dosen't
respect the border, whereas Internet explorer does... I'm using a 1024 x 768, if
you have a larger area make the longer pre longer!

Reproducible: Always
Steps to Reproduce:
1. Make a test.html with

<style>
pre {
border: 1pt solid black;
white-space: pre;
}
</style>
<pre>This is kinda interesting
</pre>
<p>Just a test
</p>
<pre>Another interesting, but much longer test Another interesting, but much
longer test Another interesting, but much longer test Another interesting, but
much longer test
</pre>

2. Open it with Firefox 1.0 and Internet Explorer 6.0, Mozilla does not respect
the border, I.E does
Actual Results:  
You get a border that dosen't respect the length of the long text
Attached file This is a test case
Assignee: firefox → nobody
Component: General → Layout
Keywords: testcase
Product: Firefox → Browser
QA Contact: firefox.general → core.layout
Version: unspecified → Trunk
Mozilla's rendering is correct. PRE is a block level element with a default 
width of 'auto', which in this case computes to the width of the viewport. What 
you see to the right of the border is overflow.
If you want to make sure the border contains the whole text, you could use e.g. 
set the PRE to display: inline.

*** This bug has been marked as a duplicate of 248139 ***
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → DUPLICATE
Except display:inline will not do anything remotely like what reporter wants. 
"display:table-cell" will, though.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: