Re: [css-d] height and margin: auto 0

2010-04-28 Thread Paul Novitski
At 4/28/2010 11:06 AM, Climis, Tim wrote: > > Would the block center vertically if the containing block had a declared > > height, or does that not matter either? > >It would not. > > > Thoughts? > >If you're in a position be able to specify height on both the block >and it's container, then this

Re: [css-d] height and margin: auto 0

2010-04-28 Thread David Laakso
Jess Jacobs wrote: > This might be a stupid question, but here goes: > > I have a div. I can set a width on that div and set margin: 0 auto; and have > the thing centered horizontally. > > If I instead set a height on the same div, and then set margin: auto 0; it > does not center horizontally. > >

Re: [css-d] height and margin: auto 0

2010-04-28 Thread Climis, Tim
> If I instead set a height on the same div, and then set margin: auto 0; it > does not center horizontally. I'm going to assume that you really meant vertically. > Why? why why why? Because the definition of "auto" states that if auto is the same for margin-left and margin-right, then they wil

Re: [css-d] height and margin: auto 0

2010-04-28 Thread jeffrey morin
On Wed, Apr 28, 2010 at 1:40 PM, Jess Jacobs wrote: > This might be a stupid question, but here goes: > > I have a div. I can set a width on that div and set margin: 0 auto; and > have > the thing centered horizontally. > > If I instead set a height on the same div, and then set margin: auto 0; it

[css-d] height and margin: auto 0

2010-04-28 Thread Jess Jacobs
This might be a stupid question, but here goes: I have a div. I can set a width on that div and set margin: 0 auto; and have the thing centered horizontally. If I instead set a height on the same div, and then set margin: auto 0; it does not center horizontally. Why? why why why? Would the bloc