On 12/27/09 11:04 AM, Felix Miata wrote: > On 2009/12/27 18:06 (GMT) MEM composed: > >> Sorry to bother again with this issue... > >> If we stay with 1em, all fonts size will be equal. However, if we >> do less then 1em, (no matter what value I suppose) we just get >> inconsistent results. I know the browsers should not look exactly >> equal, that's the own nature of browsers but, at I would like them >> to be, at least, similar. Right now, however, the results are >> quite different. > >> Any advice regarding this issue? >> http://www.chequedejeuner.nuvemk.com/educa.infantil/associar > > Look at http://fm.no-ip.com/auth/Font/font-rounding.html in each of > your installed browsers and you may see that more than two > significant digits to em font-sizes are an invitation for > inconsistent results. If you stick to two significant digits and > take what you learn from that URL into account you might get > acceptable results cross-browser. > [...]
Further to Felix's good advice to stick to 2 decimal places in "em" sizes (so no fractions of 1%)... Some time ago, I ran a series of automated tests on font scaling, testing on all the browsers I had at the time. As you discovered, each browser engine has its own way of rounding fractions. Webkit, for example, simply ignores any fraction of 1%, while Gecko not only rounds fractions, but also seems to carry fractions forward, rounding accumulated values. I find I get the most consistent results from using these percentages, which scale quite well. For example, if font-size of 82% gives 13px, then 5em will very likely give 65px in all browsers. 8pt brevier 11px 69% 9pt bourgeois 12px 75% 10pt long primer 13px 82% 11pt small pica 15px 94% 12pt pica 16px 100% 14pt english 19px 119% 16pt columbian 21px 132% 18pt great primer 24px 150% (The pixel sizes will vary according to computer settings.) Hope this helps. Cordially, David -- ______________________________________________________________________ css-discuss [[email protected]] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ List policies -- http://css-discuss.org/policies.html Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
