Closed Bug 184008 Opened 22 years ago Closed 20 years ago

z-index randomly ignored when overlaying fixed absolute image over another

Categories

(Core :: Web Painting, defect)

x86
Windows 98
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: deron.meranda, Assigned: roc)

References

()

Details

User-Agent:       Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.2.1) Gecko/20021130
Build Identifier: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.2.1) Gecko/20021130

I have a fixed abolutely positioned image with a z-index attribute to force it
on top.  It partially overlays another image as well as the body background
image.  On random loads, when should be the topmost image is instead layed
underneath the second image.  This incorrect layering happens on about 50% to
70% of the loads, the other times the images are layered correctly.

This problem was introduced after upgrading to Mozilla 1.2.1, it never occured
with 1.1 (using the exact same webpage).  Even if the interpretation of the
z-order is different, it should not be random.

The topmost absolutely positioned image is a color PNG and does have an alpha
transparency channel.  The webpage is XHTML conforming and is drawn in strict
compliance mode.  The image is positioned with the following CSS:

@media screen {
  div#planet {
        background-attachment: fixed;
        position: absolute; top: 0px; left: 0px; width: 100px; height: 100px;
        z-index:10;
  }
  div#planet a img { border:0 }
}


The underlying image (which the topmost image should overlay) is included as the
background image of another <div> section with the following CSS (the body
bacground is also shown):

@media screen {
  body { background: url(../backgrounds/tilebrn.jpg) 0 0 repeat fixed; }
  div#content-title {
        background: #000066 url(../backgrounds/earthcresent.jpg);
  }
}


Reproducible: Sometimes

Steps to Reproduce:
1. Load the webpage
2. On random loads the topmost image will appear underneath the other image

Actual Results:  
Randomly the image layering is either correct or incorrect.  Reload to play again.

Expected Results:  
The absolute positioned image with a specified z-depth of 10 should always be on
top.  Regardless, the layering should be consistent and not random.

This is Windows98 SE.

Screen is 1280x1024 at 32-bit color.  Gfx card is a GeForce 256 (Asus AGP-V6800
DDR driver 6.31c).

DirectX version 8.x (build 881)
I just noticed that scrolling the webpage even by a single pixel will cause the
image layering to instantly correct itself.   Could this be caused by a timing
race condition in HTTP where the underlying image is slower at loading and thus
is not drawn until the top image had already been completely rendered?

I had previously set up my browser to use HTTP 1.1 with keep-alives and without
pipelining.  I changed it to HTTP 1.0 and I have not been able to reproduce the
problem.  This may just be coincidence?   -- Deron
views
Assignee: other → roc+moz
Component: Layout → Views
I can not repeat using the RedHat 8.0 RPMS of 1.2.1 vanilla.  This is on the
same hardware (dual boot).

Must be a Windows 98 thing?  But the behavior did change between 1.1 and 1.2.1.
Awesome effects!

This seems to be fixed, or as was suggested before its a Win98 Issue.  Its also
an  old bug, so if someone with Win98 can retest with a current build that would
help.


Basic Data
Windows XP SP1
navigator.appName Netscape
navigator.userAgent Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6b)
Gecko/20031216 Firebird/0.7+
navigator.appVersion 5.0 (Windows; en-US)

and 

Basic Data
SUSE 8.2
navigator.appName Netscape
navigator.userAgent Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6b)
Gecko/20031216 Firebird/0.7+
navigator.appVersion 5.0 (X11; en-US)
This bug still existed as of Mozilla 1.5 under Windows 98SE.  So all Windows
builds, releases 1.2.1 through 1.5 seem affected.

I just installed Mozilla 1.6b, and it finally appears to be fixed.  I can no
longer reproduce it with 1.6b.  Didn't try 1.6a.
Worksforme too.  Marking so (and per comment 5)
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → WORKSFORME
Component: Layout: View Rendering → Layout: Web Painting
You need to log in before you can comment on or make changes to this bug.