André, On Dec 8, 2005, at 4:35 AM, medial | André Huf wrote:
> Hello, > > can anyone explain why there is a horizontal scrollbar for a div in > Firefox if there is a ul with “padding: 0;” inside it? > > And why the padding disappeares if I set the padding to at least 8px > for > example? > > The ul’s have list-style-type:none; - but it does happen without that > rule – only takes larger values > > I set up an example page: > http://dev.electroschore.de/uloverflowautotest.htm I may be confused here, (haven't had my first cup of coffee) but in your example, the div displaying the scroll bar has a ul with 20px padding on it. It looks like the browser is doing what you asked. Every browser has default margin and padding on <ul> and <li> elements. When working with lists I always set both margin and padding to remove the variation caused by these differing defaults. hth Roger, Roger Roelofs "Remember, if you’re headed in the wrong direction, God allows U-turns!" ~Allison Gappa Bottke ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/