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

Length unit relative to media width

From: GS <junkmail.gs@c2i.net>
Date: Wed, 19 Feb 2003 11:13:22 +0100
Message-ID: <008701c2d7ff$9d161e60$0d88d9c1@edda>
To: <www-style@w3.org>
Hi, I am new to this list. I don't know if any proposal similar to this has been discussed before. I have a proposal on a new length unit for use in CSS.

The unit should be relative to the screen (or paper) width.
The unit should be referenced to the preferred screen resolution.

I suggest those units:
   sw8      = (screen.width  /    800 ) px;
   sw12    = (screen.width  /  1200 ) px;
   sw16    = (screen.width  /  1600 ) px;
   sw24    = (screen.width  /  2400 ) px;

example:
H2 {   font-size: 36 sw12;  }

This should give font size 36 pixes in screen  resolution 1200x800. 
When displayed on a 800x600 screen resolution, the same font will be rescaled to 24 px. 
On a 1024 x 768 screen resolution, this font-size would be 31px  (rounded upward)

Gaute Sandvik
Received on Wednesday, 19 February 2003 05:18:16 GMT

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