[prev in list] [next in list] [prev in thread] [next in thread] 

List:       konq-bugs
Subject:    Bug#44435: css positioning rendering bug with floating div elements
From:       ben () spod ! cx
Date:       2002-06-27 19:29:57
[Download RAW message or body]

Package: khtml
Version: all versions in kde 3.x so far (using KDE 3.0.1 )
Severity: normal
Installed from:    Compiled From Sources
Compiler:          GCC 2.95.4
OS:                Linux
OS/Compiler notes: Also seems to occurr under freebsd. Not tested others.

Page with fairly complex CSS for positioning renders fine on Mozilla, opera, and IE6 \
(IE5 is broken anyway, so not worth  comparing), and Konqueror in KDE2.x

Floating content appears to float too far to the right, as if it's doubling up the \
menu width.

minimal HTML testcase:
-------------------
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" \
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html \
xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">  <head>
    <style type="text/css" media="screen">@import "style.css";</style>
    <title>test</title>
  </head>
  <body>
  	<div id="menu">
		<div class='sidebox'>
			<div class='boxheadleft'>:: menu</div>
			<div class='boxcontent'>menuitem</div>
		</div>

	</div>
	<div id="content">
		<div class='box'>
			<div class='boxheadleft'>permacontent</div>
			<div class='boxcontent'>
				full width content
				</div>
		</div>
		<div id="content-left">
			<div class='box'>
				<div class='boxheadleft'>content</div>
				<div class='boxcontent'>actual content</div>
				<div class='boxfoot'><a href="#">comment (0)</a></div>
			</div>
		</div>
		<div id="content-right">
			<div class='box'>
				<div class='boxheadright'>12:00 00/00/00</div>
				<div class='boxheadleft'>right</div>
				<div class='boxcontent'>right</div>
			</div>
		</div>
	</div>
  </body>
</html>

-------------------------------
CSS that goes with it: (sorry, nearly 100 lines :(
-------------------------------
body {
	margin: 0px 0px 0px 0px;
	font: 11px Tahoma, Arial, Helvetica, sans-serif;
	background:#F5F9FC;
	padding: 0px;
	margin: 0px;
	margin-top: 5px;
}

hr {
	height: 1px;
	border: 0px;
	background: #ACC6DD;
}

.box {
	border-top: 1px solid black;
	border-left: 1px solid black;
	border-right: 1px solid black;
	margin-bottom: 15px;
}

.sidebox {
	border-top: 1px solid black;
	border-left: 1px solid black;
	border-right: 1px solid black;
	width: 140px;
	margin-bottom: 15px;
}

.boxheadleft {
	padding: 2px;
	margin: 0px;
	border-bottom:1px solid black;
	background-color: #ACC6DD;
}

.boxheadright {
	width: 80px;
	padding: 2px;
	margin: 0px;
	border-bottom:1px solid black;
	border-left:1px solid black;
	background-color: #41729E;
	text-align: right;
	float:right;
}

.boxcontent {
	padding: 2px;
	margin: 0px;
	background-color: #FFFFFF;
	float:none;
	border-bottom:1px solid black;
}

.boxfoot {
	padding: 2px;
	margin: 0px;
	background-color: #acc6dd;
	border-bottom:1px solid black;
	text-align: right;
}

#header {
	font: bold 25px Verdana, Geneva, Arial, Helvetica, sans-serif;
	padding: 5px;
}

#content {
	margin-left: 147px;
	padding:4px;
}

#content-left {
	width: 49%;
	float: left;
}

#content-right {
	width: 49%;
	float: right;
}

#menu {
	/*position:absolute;
	top: 95px;*/
	float: left;
	left:0px;
	width:145px;
	padding:4px;
}

(Submitted via bugs.kde.org)


(Complete bug history is available at http://bugs.kde.org/db/44/44435.html)
_______________________________________________
Konq-bugs mailing list
Konq-bugs@mail.kde.org
http://mail.kde.org/mailman/listinfo/konq-bugs


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic