Closed Bug 94563 Opened 23 years ago Closed 23 years ago

IMG tag in relatively-positioned span cuts image short

Categories

(Core :: Web Painting, defect)

defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 79315
mozilla1.1alpha

People

(Reporter: markevanjones, Assigned: kmcclusk)

References

()

Details

From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; rv:0.9.3+) Gecko/20010809
BuildID:    2001080904

The image drawn by the following code has only the bottom portion of the image
visible.  The layout seems to be taking the entire image into account, but only
draws an amount equal to the current line-height.

<span style="position:relative;"><img src="example.gif"></span>

This is more than a rendering problem, because the DOM tells me that the top of
the image is the top of where the image is visible.

If you specify an *incorrect* height on the IMG tag, it often (but not always)
shows properly with the specified height.  Using the height of the actual image
has no effect.

Reproducible: Always

NOTE: The only difference between the Standard and Quirk layout mode is that the
 Standard mode shows the Span to extend a few pixels below the image, but not
above it into the space "reserved" for it.  (As observed with a background color
on the relatively-placed span)
Over to style system.  I see this with linux build 2001-09-07-12
Assignee: jst → dbaron
Status: UNCONFIRMED → NEW
Component: DOM Style → Style System
Ever confirmed: true
OS: Windows NT → All
Hardware: PC → All
This is probably either a problem with the view system itself or a problem with
the way layout is positioning views.
Moving over to views.  This reminds me of bug 13215.
Assignee: dbaron → kmcclusk
Component: Style System → Views
QA Contact: ian → petersen
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla0.9.5
Moving to Mozilla0.9.6
Target Milestone: mozilla0.9.5 → mozilla0.9.6
Specifying an image height of 49 or 51 for the relatively positioned span fixes
the problem. Not specifying a height or using a height of 50 (which is the
actual height of the image) makes the problem appear.

<IMG height=49 src="s_files/example1.gif">
Target Milestone: mozilla0.9.6 → mozilla0.9.9
Target Milestone: mozilla0.9.9 → mozilla1.1
I think bug 79315, bug 86850 and bug 124825 are duplicate (or at least very
close) of this bug.
Copying original report and comment #5 to bug 79315

*** This bug has been marked as a duplicate of 79315 ***
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → DUPLICATE
Component: Layout: View Rendering → Layout: Web Painting
You need to log in before you can comment on or make changes to this bug.