Bug 172693 - Elements with opacity can be rendered incorrectly in Konqueror
Summary: Elements with opacity can be rendered incorrectly in Konqueror
Alias: None
Product: konqueror
Classification: Unclassified
Component: general (show other bugs)
Version: 4.1.2
Platform: Gentoo Packages Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: Konqueror Developers
Depends on:
Reported: 2008-10-13 02:08 UTC by Neil Skrypuch
Modified: 2009-07-06 02:20 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:

The test case (2.73 KB, text/html)
2008-10-13 02:11 UTC, Neil Skrypuch
A screenshot of the above test case with Konqueror 4.1.2 (50.33 KB, image/png)
2008-10-13 02:13 UTC, Neil Skrypuch

Note You need to log in before you can comment on or make changes to this bug.
Description Neil Skrypuch 2008-10-13 02:08:36 UTC
Version:            (using KDE 4.1.2)
Compiler:          gcc version 4.1.2 (Gentoo 4.1.2 p1.1) 
OS:                Linux
Installed from:    Gentoo Packages

As Konqueror now supports CSS opacity, I started playing around with it, and it seems that in some cases, the opacity won't be rendered correctly. In particular, elements that contain floated fieldsets never seem to take an opacity other than 1 or 0.

I also ran into similar issues with absolutely positioned elements inside of other absolutely positioned elements where the outer element has an 0 < opacity < 1, but only in conjunction with a floated fieldset. In this case, the inner absolutely positioned element would display with the correct opacity, but the rest of the element would display with an opacity of 1 or 0.

This might apply to elements other than fieldsets being floated too, I didn't run into any explicit examples though.

I'll attach a self contained test case plus a screenshot of what it looks like for me in a moment...
Comment 1 Neil Skrypuch 2008-10-13 02:11:58 UTC
Created attachment 27840 [details]
The test case

The 2nd, 3rd, and 4th divs should all transition in opacity smoothly and simultaneously. This works (at least) in Firefox 2, Firefox 3, and (shockingly) even IE6.
Comment 2 Neil Skrypuch 2008-10-13 02:13:45 UTC
Created attachment 27841 [details]
A screenshot of the above test case with Konqueror 4.1.2

Note that the 2nd div never changes, even though it should.

The 3rd and 4th divs change, but render with terrible graphical corruption.
Comment 3 Paweł Prażak 2008-10-15 18:36:37 UTC
I confirm this bug on openSuSE 11, KDE 4.1.2
Thanks for testcase :)
Comment 4 Ralph Moenchmeyer 2008-10-26 14:04:18 UTC
In case you need an additional example which is handled correctly by Firefox v2, v3 and Opera v9.x (both Linux and Windows versions) and MS IE7 see the page 

The first menu item on each page reacts to mousover events and produces a partially transparent submenu on the right side. The css directives include both filter directives for MS IE7 and moz-opacity and opacity rules for FF and Opera. 

The submenu consists of several DIV layers above each other (z-index). Each layer itself contains of lists with semitransparant DIV-elements. 

In this case there are no "float" directives involved. 

The semitransparent menus are initialy displayed correctly but some mouse movement across the menus will eventually lead to severe distortions of the semi transparent meu items.  
Comment 5 Christian Fontana 2008-11-05 16:43:52 UTC
I found other simple and test pages that works wrongly:


And also on the site I developed: 

http://www.aicocolars.com/it/camere/friuli-venezia-giulia/camere-appartamenti.html  --> click on "foto delle camere".

In the latest case there is a div the overlap all the page and becomes opaque. With konqueror 4.1.2 this background has an undefined "color design".

Comment 6 Christian Fontana 2008-11-13 16:18:09 UTC
I can confirm this behavior is already present in 4.1.3
Comment 7 Maksim Orlovich 2008-11-30 18:47:47 UTC
Weird: not seeing the corruption here, but I am pretty sure I've seen it before.
Comment 8 Maksim Orlovich 2008-11-30 18:53:15 UTC
... but reproducible on my other machine. 
Comment 9 Maksim Orlovich 2008-11-30 19:03:11 UTC
...And can confirm on an another machine. Reporter, confirmers, what video drivers are you using?
Comment 10 Neil Skrypuch 2008-11-30 19:36:53 UTC
A Geforce 7950 GT with version 177.70 of the nvidia-drivers here.
Comment 11 Ralph Moenchmeyer 2008-11-30 19:55:49 UTC
I have a Nvidia 7800 GTX with driver 177.82 for x86_64. 
Comment 12 Ralph Moenchmeyer 2008-11-30 20:05:29 UTC
I should add that the corruption does not appear at once; in my test case (www.anracom.com) you have to play around a little bit (with the mouse and the menus). Its the rerendering of the semitransparent DIVs during the interaction that leads to the distortion. 
Comment 13 Christian Fontana 2008-11-30 22:40:54 UTC
nvidia drivers version 173 on kubuntu 8.10
I tried also with version 177 (both for 32 bit) but there are other issues with KDE + other applications
Comment 14 Ralph Moenchmeyer 2008-12-11 20:42:32 UTC
The problems disappeared in my case (7800 GTX, KDE 4.2 beta, Opensuse 11.0) with the new 180.06 beta driver of Nvidia. This new driver also solved the problems of  artefacts on the KDE taskbars which appeared for GTK applications (see bug  157017 and related bugs).   
So there is hope ! Seemingly, Nvidia eventually has removed some bugs in their drivers.  
Anybody else who can confirm this ?

Comment 15 Neil Skrypuch 2009-02-01 21:40:10 UTC
With KDE 4.2 and Nvidia drivers v180.27, the corruption appears to be all gone, but the second div still doesn't change opacity (even though it should).
Comment 16 Germain Garand 2009-05-18 07:01:01 UTC
SVN commit 969354 by ggarand:

include floats in computation of visible flow Region.

BUG: 172693

 M  +25 -0     render_block.cpp  
 M  +1 -0      render_block.h  
 M  +4 -2      render_object.cpp  

WebSVN link: http://websvn.kde.org/?view=rev&revision=969354
Comment 17 Germain Garand 2009-05-23 04:50:52 UTC
SVN commit 971650 by ggarand:

automatically merged revision 969354:
include floats in computation of visible flow Region.

BUG: 172693

 M  +25 -0     render_block.cpp  
 M  +1 -0      render_block.h  
 M  +4 -2      render_object.cpp  

WebSVN link: http://websvn.kde.org/?view=rev&revision=971650
Comment 18 Neil Skrypuch 2009-07-06 02:20:11 UTC
Yep, it's fixed for me in 4.2.4. Closing.