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

[CSS21] visibility: collapse on non-table elements

From: fantasai <fantasai.lists@inkedblade.net>
Date: Thu, 14 Feb 2008 02:03:14 -0800
Message-ID: <47B411E2.9050007@inkedblade.net>
To: www-style@w3.org

I'd like to raise the comments posted by Markus Jonsson and Andrew Fedoniouk
about the behavior of "visibility: collapse" as a CSS2.1 issue.
   http://lists.w3.org/Archives/Public/www-style/2007Jul/0153.html

Currently for internal table elements it collapses them to take up no room
but to still participate in width/height calculations. The goal is to make
dynamic show/hide operations smooth and efficient. This makes sense.

However, for non-internal-table-elements, it's currently defined to behave
as "visibility: hidden", which is not very useful. It just makes the element
invisible. I think smooth and efficient dynamic collapsing behavior makes
sense outside of tables as well, and that the definition should be changed
to be consistent with this use case.

Specifically, block-level elements with "visibility: collapse" should behave as
if their box was zero height with zero vertical padding, border width, and margins,
and inline-level elements with "visibility: collapse" should behave as if their
box was zero width with zero horizontal padding, border width, and margins.
Furthermore all descendants of a non-internal-table-element with "visibility:
collapse"--including descendants that are anonymous boxes--are also treated as
if they had "visibility: collapse".

~fantasai
Received on Thursday, 14 February 2008 10:03:19 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:55:01 GMT