W3C home > Mailing lists > Public > www-style@w3.org > August 2003

CSS3 box height %

From: Bryan C. Mills <bmills@andrew.cmu.edu>
Date: Tue, 12 Aug 2003 12:27:16 -0400 (EDT)
To: www-style@w3.org
Message-ID: <Pine.LNX.4.55L-032.0308121134030.6803@unix47.andrew.cmu.edu>

The current working draft of the box model says (section 8.1):

A <percentage> is relative to the computed value of the width or height of
the containing block, but if that value is 'auto' the computed value for
the percentage is also 'auto'.


This is consistent with the CSS2 specification; however, it is not
consistent with the intuition of the document-writing public.

Most people would expect "height: 100%" to cause a box to extend from the
top of the containing block to the bottom of the containing block; this is
also how Internet Explorer 6 renders it in CSS2 (in violation of the

Rather than defining percentages to be 'auto' for blocks whose parents
have height 'auto', I think percentages should be treated as the
percentage of the 'auto' height of the containing block or 100% of the
intrinsic height of the block, whichever is greater.

It would even warrant consideration to establish that if the intrinsic
height of the block is used, the parent block should be resized so that
the proportions are still correct.  This option, however, deserves extreme
caution -- it may cause severe performance degradation with some
Received on Tuesday, 12 August 2003 12:27:17 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:08 UTC