W3C home > Mailing lists > Public > www-style@w3.org > October 2001

Re:RE: How is it possible to devise such a feeble system?

From: Jesse McCarthy <mccarthy36@earthlink.net>
Date: Wed, 24 Oct 2001 13:42:03 -0400
To: www-style@w3.org
Message-ID: <MWMail.bpcicifm@host.none>
"Peter Foti (PeterF)" <PeterF@SystolicNetworks.com> wrote on 10/24/01 1:39:06 
PM: 
>
>Looking at your example, I would think that the correct way to do it
>would be to add this to your whole1 style:
>
>text-align: center;
>vertical-align: middle;
>
>If whole1 has 100% width and 100% height, then you want to center
>horizontally and vertically the item(s) in whole1.  You should be able
>to do this with the styles above.  Of course, it doesn't work.  The
>text-align seems to work, but the vertical-align is still top aligned.

According to the spec, vertical-align would have no bearing on this situation.  
It applies only to "inline-level and 'table-cell' elements".  That's my main 
problem here, that there is no "vertical-align" property that applies to this 
situation.  You are right, of course, that text-align allows for horizontal 
centering. 

>This raises a new question.  Wouldn't "text-align" be more appropriately
>called "horizontal-align"?  I mean, you might have non-text items within
>the element that you are applying the alignment to.
>
>And another question... why does text-align use "center" to mean the
>center, and vertical-align uses "middle" to mean the center.  Could it
>be that at some point there may be a single "align" attribute that will
>take both text-align and vertical-align values?  For example, instead of
>this:
>text-align: left;
>vertical-align: middle;
>
>you could write this:
>align: left middle;
>
>Is that in the works?
>Thanks,
>Pete
 
You raise some good points.  I've always thought it would make more sense to 
call that property something other than text-align, and why not 'horizontal-
align', makes sense to me, but it's not practically significant.  As far as the 
difference in possible values between the two properties you mentioned, there 
is more to vertical-align than there is to text-align.  There's probably a 
precedent for these values, e.g. in typography, that we're not aware of. 
Received on Wednesday, 24 October 2001 13:51:17 GMT

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