W3C home > Mailing lists > Public > www-svg@w3.org > May 2010

Re: Unitless lengths in SVG and CSS

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Wed, 26 May 2010 11:53:52 -0400
Message-ID: <4BFD4410.5060808@mit.edu>
To: Michael Day <mikeday@yeslogic.com>
CC: www-svg@w3.org
On 5/26/10 2:48 AM, Michael Day wrote:
> In SVG 1.1, the font-size property can take unitless lengths, like "50".
> However, CSS has never supported a unitless number value for the
> font-size property, and such a declaration should be ignored.
> How should implementations resolve this dilemma?

SVG 1.1 second edition draft has this to say [1]:

   For properties defined in CSS2 [CSS2], a length unit identifier
   must be provided.

Note that in practice what UAs do is to parse things like @font-size 
without a required unit but to require the unit in actual CSS (inline 
style, linked stylesheets, etc).  I seem to recall there was some draft 
of some svg spec that mentioned this behavior, but can't find it at the 


[1] http://dev.w3.org/SVG/profiles/1.1F2/publish/types.html#DataTypeLength
Received on Wednesday, 26 May 2010 15:54:31 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 March 2017 09:47:21 UTC