W3C home > Mailing lists > Public > www-style@w3.org > April 2005

Re: Style confirmation descriptors

From: Laurens Holst <lholst@students.cs.uu.nl>
Date: Sun, 10 Apr 2005 20:33:05 +0200
Message-ID: <42597161.90401@students.cs.uu.nl>
To: www-style@w3.org

Barry wrote:
>> Anti-aliasing is a technique that serves the purpose to reduce the 
>> (ugly) visibility of jagged edges caused by the squareness of pixels. 
>> It doesn’t make lines wider, nor narrower, when applied correctly (at 
>> least to the human eye). A 1-pixel arched line can be anti-aliased 
>> quite well. Especially with sub-pixel anti aliasing.
> One thing I'd avoid making the default is any anti-aliasing that results 
> in the border needing more room. I'd allow anti-aliasing pixels to be in 
> the rounded corners because that wouldn't require the box to have 
> greater width or height or the content to have a smaller margin (except 
> at the rounded corner), but I wouldn't want an extra, lighter side 
> border to be created to blend better with a corner's anti-aliasing 
> pixel, unless the author specifies it.

Aliasing is the concept of having a round corner look like this:


This has jaggy edges because pixels are square, called aliasing. To make 
it look better and more round on the human eye, some pixels of the line 
and surrounding are drawn with certain mixed colours. They are really 
pixels that the vector curve intersects with, and the mix of the colour 
depends on the amount of intersection the vector has with the square 
pixels. That process is called anti-aliasing:


Note that the line halfway its angle (at 45 degrees) is *not* two or 
three pixels wide. It is still 1 pixel wide, except that as Pythagoras 
tought us, that would translate to 0.7 pixels at an angle of zero. Or: 
one pixel with an opacity of 0.7.

However, as straight horizontal and vertical lines fit perfectly well 
within the square pixel model, a 1 pixel line is 1 pixel wide, and will 
have no aliasing to er, anti.


Besides, even when you would have a need for anti-aliased horizontal or 
vertical lines (this could happen when drawing borders on 
non-whole-pixel boundaries, which I don’t think is a good idea), it 
wouldn’t make anything larger, the borders would still be exactly 1 
pixel wide.

In any case, there’s nothing much mysterious about anti-aliasing, and it 
can be entirely handled by the user agent and CSS doesn’t need to worry 
about it.

So, I don’t see the problem.


Ushiko-san! Kimi wa doushite, Ushiko-san!!
Received on Sunday, 10 April 2005 18:33:07 UTC

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