NextExile
Nov 6 2009, 11:22 AM
Where the hell does Offset value come from?
In IE8, when you use their "Developer Tools" you can view the box model of individual items in "Layout" tab. Even if I strip margins from my item, it ends up offset on the screen and with a "Offset" parameter in the box model.
In this case the offset is 77px on the left. I don't even have the number 77 in my stylesheets, I do however have a left margin of 33px applied to some other elements. If I view the wireframe of the site though nothing is pushing this particulat element, it just gets an offset and hangs there by itself.
Example of the box model is attached.
Demonslay
Nov 6 2009, 10:01 PM
Hmm... leave it to IE of course...
I would like to see the page myself, so I could see what styles apply and what might cause that. I know that earlier versions of IE would calculate offsets and the total width of an element different than standards, but I've no clue what they fixed in IE8 (if anything lol).
My best guess would be some kind of positioning, like relative positioning, or even some kind of a float.
rc69
Nov 7 2009, 12:43 PM
Looking at my site in the developer tools for IE8, i would say Offset is just a reference. All it says is where the element lies relative to it's parent element. It doesn't directly affect the position of anything.
So if you were going to be using relative position on an item, and you wanted to position it over a particular element, you could refer to the target element's offset so you know where to put the relative element.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.