Re: positioned elements: center

Brad Kemper wrote:
> 
> 
> On Jan 7, 2008, at 11:36 AM, fantasai wrote:
> 
>> There was a proposal for pretty much exactly this functionality quite 
>> awhile
>> ago, with slightly different syntax
>>   http://lists.w3.org/Archives/Public/www-style/2004Jan/0218.html
> 
> That's pretty different from what I'm proposing. By the definition 
> given, position:center is a whole new positioning scheme, concerned 
> primarily with making sure the item is both vertically centered and 
> horizontally centered.
> 
> What I proposed was a small, simple extension to position:absolute (and 
> position:fixed, and perhaps position:relative), which would continue to 
> work exactly as it did before, except that in addition to setting the 
> position of one or more of the four edges of the object, you could set 
> the position of the center of the object.
> 
> It would not break any fundamental design principals. It would not break 
> incremental rendering, since positioned items are taken out of the flow.

See http://lists.w3.org/Archives/Public/www-style/2008Jan/0168.html on
incremental rendering.

AFAICT your proposal and "position: center" don't have any fundamental
differences aside from the syntax used to get various results and, in
the less common cases, whether some results are possible. They are both
absolute-positioning schemes and share the same layout advantages and
disadvantages.

I think the position: center scheme is less clear on what happens when
e.g. 'left' is 'calc(50% + 5em)'...

~fantasai

Received on Tuesday, 8 January 2008 17:10:51 UTC