> -3-
>
> Font-sizing: Hardest to leave behind are my pixel-based fonts. :\ There
> is a large difference between IE and Firefox, which I've slapped a
> band-aid on for now... that Opera isn't happy with.
>
> I've read about many people's preferences on this, but could use a lot
> more. Opinions on the best way to make them relatively the same
> cross-browser?
>

One thing immediately stands out: you are declaring a font-size of 85% on
the body. As the standard browser font size is 16 pixels, and 85% of 16 is
13.6, you're starting from a baseline of 13.6 pixels. As you can't have
fractions of a pixel, you're pretty much bound to run into rounding errors
and so forth later on.

If you want to use a base font size of 14 pixels, which is nearest to what
you have currently, then use a font size of 87.5%. (Alternatively, if you
were going for 13 pixels, use 81.25%.)

I personally find it useful to specify a font size of 62.5% on the body,
giving me a default size for 1em of 10 pixels. If I then want a heading at
14 pixels, I can specify 1.4em.

One thing to bear in mind is that, if you specify things like padding and
margins in ems (to make the page scale correctly when the user increases
their font size), the em-size is that of the element to which said spacing
is applied. So, if you have:

body {
  font-size: 62.5%; /* makes 1em = 10px */
}

h1 {
   font-size: 1.4em; /* sets h1 to 14px */
   margin: 1em;
}

then the h1 will have margins of 14 pixels, not 10. Personally, I find
having the 10px base size so useful in specifying the structure of the
page that I don't mind reaching for the calculator occasionally when
dealing with that kind of case, but YMMV :-)

HTH,

Nick.
-- 
Nick Fitzsimons
http://www.nickfitz.co.uk/

______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to