[cairo] Write ups on Microsoft Avalon
Carl Worth
cworth at east.isi.edu
Tue May 18 06:50:35 PDT 2004
On Mon, 17 May 2004 15:44:32 -0400, Owen Taylor wrote:
> The default Cairo line-width is 2 to try and keep people from having to
> add that 0.5 pixel in most cases, but I'm pretty much skeptical about
> the whole idea of scaling a user interface by changing the
> transformation. You either add tons of fuzz or have a huge discrete
> jump when a unit switches from 1 pixels to 2 pixels.
Doing pixel-adjusted geometry for graphics in general just gets us to
the same situation we are already at with font glyphs. It seems that the
discrete jumps are only objectionable if you are smoothly animating. And
fortunately, smooth animation is also the situation in which the fuzz is
least objectionable. So, doing this well takes care, but I think we can
do it just fine.
One key aspect is that cairo stays away from these issues. It just draws
precisely what you tell it to draw. It won't try adjusting your stroke
widths to hit pixel boundaries, for example. (This avoids problems like
those Bill has recalled.)
The adjustment for pixel boundaries needs to happen in higher layers
than cairo. For example, font raterizers than can be told whether or not
to hint, SVG implementations that can be told to prefer crispEdges or
geometricPrecision, etc.
-Carl
More information about the cairo
mailing list