Bug 149809 - [Test case] Wrong rendering in Konqueror of some simple CSS image positioned
Summary: [Test case] Wrong rendering in Konqueror of some simple CSS image positioned
Status: RESOLVED FIXED
Alias: None
Product: konqueror
Classification: Applications
Component: khtml (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: Konqueror Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-09-12 20:12 UTC by Albert Astals Cid
Modified: 2007-10-06 00:41 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
The html file (354 bytes, text/html)
2007-09-12 20:14 UTC, Albert Astals Cid
Details
One needed image (2.41 KB, image/gif)
2007-09-12 20:14 UTC, Albert Astals Cid
Details
The other needed image (4.06 KB, image/jpeg)
2007-09-12 20:15 UTC, Albert Astals Cid
Details
online test case (455 bytes, text/html)
2007-09-13 07:56 UTC, Tommi Tervo
Details
patch (1.90 KB, patch)
2007-09-13 19:18 UTC, Germain Garand
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Albert Astals Cid 2007-09-12 20:12:42 UTC
Version:           3.5.7 (using KDE 3.5.7, Kubuntu (feisty) 4:3.5.7-0ubuntu1~feisty2)
Compiler:          Target: x86_64-linux-gnu
OS:                Linux (x86_64) release 2.6.20-16-generic

The html is 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<body>
		<div style="position:relative">
			<img src="a.gif">
			<img style="position:absolute;left:0px;height:183px;width:120px;" src="b.jpg">
			<div>FOO</div>
		</div>
	</body>
</html>

i assume it is a bug because removing the FOO div i get the same rendering than in Firefox and IE so it seems Konqi's fault

I will attach the html and both images later.
Comment 1 Albert Astals Cid 2007-09-12 20:14:18 UTC
Created attachment 21617 [details]
The html file
Comment 2 Albert Astals Cid 2007-09-12 20:14:57 UTC
Created attachment 21618 [details]
One needed image
Comment 3 Albert Astals Cid 2007-09-12 20:15:08 UTC
Created attachment 21619 [details]
The other needed image
Comment 4 Tommi Tervo 2007-09-13 07:56:07 UTC
Created attachment 21622 [details]
online test case
Comment 5 Germain Garand 2007-09-13 19:00:28 UTC
> removing the FOO div i get the same rendering than in Firefox

which means it's a problem with how anonymous blocks are created.
It should include the statically positioned object in the inline.

Comment 6 Germain Garand 2007-09-13 19:18:51 UTC
Created attachment 21623 [details]
patch

here... I can't test at the moment but just syncing getInlineRun with what's in
WebCore should do. The git of it is to skip positioned/floating objects while
scanning for inlines. Anyone may test?
Comment 7 Albert Astals Cid 2007-09-13 20:49:05 UTC
Your patch does not compile, replacing boundary with stop makes it compile and work, you rock :-)

Do you want me to commit or you can do it?
Comment 8 Germain Garand 2007-09-13 23:01:16 UTC
yes, feel free, thanks... I'm not sure I'll be able to fix my build before some days. I'll regression test the patch later.

Please mention the WebCore origin in the commit.
Comment 9 Albert Astals Cid 2007-09-13 23:34:03 UTC
SVN commit 712197 by aacid:

Patch by Germain Garand to fix the bug i reported yesterday, you rock ;-)
In his words "The git of it is to skip positioned/floating objects while scanning for inlines."
"Ported" from WebCore

BUGS: 149809


 M  +21 -15    render_block.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=712197
Comment 10 Albert Astals Cid 2007-09-13 23:55:08 UTC
Germain i did not commit to KDE4 because i'm not able to start konqueror and make it open html with khtmlpart instaed of katepart :-S
I didn't even check the patch applies
That's left for you too besides the regression testing :-)
Comment 11 Germain Garand 2007-10-05 14:26:51 UTC
Albert: the patch was in fact made for trunk. It's most probably OK to apply it to branch, but I won't take blame for it in case it breaks something.
I just don't compile/test much branch those days.

Comment 12 Albert Astals Cid 2007-10-05 20:36:33 UTC
ok, i commited to trunk too, should i revert 3.5 ?
Comment 13 Germain Garand 2007-10-06 00:41:40 UTC
thanks! I finally managed to have a working tree so I'll be able to regression test at last ;-/

As for 3.5, all I say is I won't test it there, so I can hardly take full responsibility for it. But OTOH the patch is really simple...