W3C home > Mailing lists > Public > www-style@w3.org > July 2012

[css3-page] vertical-align on page-margin boxes

From: Simon Sapin <simon.sapin@kozea.fr>
Date: Sun, 01 Jul 2012 20:47:20 +0200
Message-ID: <4FF09B38.60705@kozea.fr>
To: www-style@w3.org

I am assuming horizontal writing-mode here. Iím not sure what to do in 
vertical, especially given this:

The current ED says: "On margin boxes, the Ďvertical-aligní property 
behaves as specified for table cells."

This gives a general idea of the behavior, but I think it is not precise 
enough. In particular, some details of table cells do not apply to 
page-margin boxes. In CSS21:17.5.3

   # In CSS 2.1, the height of a cell box is the minimum height required
   # by the content. The table cell's 'height' property can influence
   # the height of the row (see above), but it does not increase the
   # height of the cell box.

   # Cell boxes that are smaller than the height of the row receive
   # extra top or bottom padding.

Table cells are rows that are always high enough to avoid vertical 
overflow, but page-margin boxes are not.

Here is my suggested replacement:


The rules in 6.3 result in used values for the position and size of the 
boxís margin, border, padding and content areas. The content area is 
then adjusted so that its height is what it would have been as described 
in CSS21:10.6.7 on a block formatting context roots with 'height: auto', 
the same used width, and the same content.

For vertical-align 'top', 'bottom or 'middle'; the top, bottom or 
vertical middle of the content area (respectively) stays at its previous 
position. In other words, vertical-align 'top' changes the used bottom 
padding, 'bottom' the top padding, and 'middle' changes both by an equal 

Note: if there is a lot of content, this process will increase rather 
than reduce the height of the content area. In this case, the content 
will overflow on the bottom side for 'vertical-align: top', on the top 
for 'bottom' or on both for 'middle'.


Iím not sure if 'vertical-align: baseline' (or other values) can make 
sense, and how.


Simon Sapin
Received on Sunday, 1 July 2012 18:47:48 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:18 UTC