W3C home > Mailing lists > Public > www-style@w3.org > November 2010

Re: [css3-gridalign] Named gridlines

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Tue, 2 Nov 2010 04:33:11 -0700
Message-ID: <AANLkTinFvweEc=Tdk3kMfh6yiMLu2uB7iZwxLN9vp8cd@mail.gmail.com>
To: François REMY <fremycompany_pub@yahoo.fr>
Cc: www-style list <www-style@w3.org>
On Tue, Nov 2, 2010 at 2:44 AM, François REMY <fremycompany_pub@yahoo.fr> wrote:
> For elements spanning only one cell, would it be possible to define {
> grid-position: 'myRow' 'myColumn'; } instead of a 4-elements syntax ?
>
> It would be equivalent to {
>   grid-position-top: 'myRow';
>   grid-position-bottom: 'myRow';
>   grid-position-left: 'myColumn';
>   grid-position-right: 'myColumn';
> }

Yes, that would be perfectly fine.  If one of the gridlines isn't
defined, it should be the immediate next/prev gridline.  For example,
saying "grid-position-top: 'myRow'; grid-position-left: 'myColumn';",
and don't define the right or bottom, then the item is only one row
tall and one column wide.


> When you speak about number+name combination, what are you refering to ? Do
> you want to allow something like {
>   grid-position: 'myFirstRow' 'myFirstColumn' 2 3;
> } for an element spanning across 2 rows and 3 columns ?

Not quite - in that example, the 2 and 3 would refer to the 2nd and
3rd gridline by number.

Specifying the span explicitly, rather than specifying the bottom, is
also useful, in a similar way to how specifying top+height is
sometimes better than top+bottom in abspos.


> In such case, what about negative (or null) spans ? Are they allowed ? If
> negative spans are allowed, how are they supported ? (do the anchor edge of
> the element in 'firstRow'/'firstColumn' change, for instance ?)

No, spans should be a minimum of 1.  If they end up being less than
that, they should probably default to 1.

~TJ
Received on Tuesday, 2 November 2010 11:33:59 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:34 GMT