Re: Designs that zoom (was : Why reduce font size)

>  This truly is a user agent problem and not a CSS problem, and may 
> disappear as UAs become more precise.

This is a misunderstanding of the problem. It is not a math error, but 
rather the accuracy of math that is the problem.

Say I have 4 floating divs, all width:25%. The viewport is 800px wide, 
so each is 200px and they fit side by side. I shrink the viewport to 
798px, and each div is now:

	round(798 * 0.25) = round(199.5) = 200px

....totalling 800px, or 2px more than my viewport, causing the last div 
to drop below the others. I shrink it to 797px, and each div is now:

	round(797 * 0.25) = round(199.25) = 199px

....totalling 796px, or 1px short of my viewport, even though they total 
100% of the width.

No matter how precise the UA is, this will be true. The only solution 
is the elimination of pixels (either by pixels so fine the human eye 
cannot discern them or fudging through anti-aliasing vector-based 
drawing).


> Perhaps CSS 2.1 or 3 should include a recommendation on how to handle 
> pixel rounding?

This would be my suggestion. If all rounding was rounded down, and then 
some algorithm was created to distribute whole pixels in some 
deterministic way*, then it is likely we would have to try very hard to 
see the problem. Even then, compliant browsers would at least be 
consistent.


* obviously, I leave the trickiest part to others smarter than I.

-- 

	Ben Curtis : webwright
	bivia : a personal web studio
	http://www.bivia.com
	v: (818) 507-6613

Received on Friday, 4 March 2005 01:46:13 UTC