W3C home > Mailing lists > Public > www-style@w3.org > February 2015

Re: [css-tables] Missing definition of table row borders if border-collapse: separate?

From: Morten Stenshorne <mstensho@opera.com>
Date: Tue, 10 Feb 2015 18:44:13 +0100
To: "Axel Dahmen" <brille1@hotmail.com>
Cc: www-style@w3.org
Message-ID: <87egpxbr0y.fsf@aeneas.oslo.osa>
"Axel Dahmen" <brille1@hotmail.com> writes:

> Here's my suggestion in answer to your question:
> Please refer to my animated preview images here: http://imgur.com/a/IbYas

There are some nice layouts here, but I don't think that anybody wants
to make such drastic changes to the table layout model. Also, there'd be
a lot more thinking left to do:

Looks like you're imagining a hybrid between collapsed and separate
borders. Borders all normally take up space (unless you're collapsing
them) and affect layout, so I'd think that if you have col, tr {
border:2px solid; } and td { border:3px solid; }, a cell would be
surrounded by its own borders, and then, on the outside, the border of
the row and column? Which of them (rows / columns) should come first,
BTW, and what if they have different style or color? That could
potentially look hideous, on a general basis.

How should the following be rendered?

    <col style="border:3px solid blue;">
    <tr style="border:3px solid pink;">

Column borders on the outside, row borders on the inside? Or the other
way around? Or column borders on the outside on the left and right
sides, and row borders on the outside at the top and bottom?

> Table rows, table columns and table column groups should be able to be
> styled fully, like inline-block elements, including margins, border
> and padding.

Together with border-spacing, you'll end up with a constantly
over-constrained situation here. That could of course be fixed by
introducing an 'auto' value for border-spacing, and require that it
always be 'auto' if the author wants borders, padding and margins.

Also - what about rowspan > 1?

> A border spanning a table row or column is supposed to be continuous
> throughout the row/column element.
> Usually, a table cell's properties would override a table
> row's/column's property. To have the table row/column excel the table
> cell definition, a new table cell property should be introduced:
> table-cell-priority: <table-cell-priority-type>
> having    <table-cell-priority-type> = low | default
> and         default value: default

Then you'd also need something to tell table rows to yield to table row
groups, and so on. And who should win if something is specified both on
the column and on the row? I honestly don't see the point with this
property. Just set the cells' background to transparent if you want that
of the row to shine through. See also

---- Morten Stenshorne, developer, Opera Software ASA ----
------------------ http://www.opera.com/ -----------------
Received on Tuesday, 10 February 2015 17:45:05 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:52:01 UTC