PDA

View Full Version : Font Size question



Didiusthegreat
December 15th, 2003, 02:16 PM
Hi,

Im using this font code on my site

<font size="2" face="Verdana, Arial, Helvetica, sans-serif">

I now have a lot of pages and I was thinking of switching to css. To make the work more easy.

I use this code

font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 12px;

But if I compare the font size it doesn't seems to be the same.
I think it's because i use px in the second css code.
I'd like to know how much pixels is font size=2 ?

λ
December 15th, 2003, 02:49 PM
I did a quick Google and came up with a few results... it seems there aren't really any definite sizes that are exactly the same.

However, I did find this for you: http://www.motive.co.nz/resources/webfonts.html

Here is the google I used: http://www.google.com/search?q=%3Cfont+size%3D%222%22%3E+CSS+equivalent&sourceid=mozilla-search&start=0&start=0&ie=utf-8&oe=utf-8

UNFLUX
December 15th, 2003, 04:32 PM
no there aren't. actually kind of goofy, but in regular size 8px is
9px in css. and the spacing is different as well...

you just have to play with teh sizes to fit your design needs. soon
you will have it down and it will be easy to do. Like most things,
I guess. =)

eilsoe
December 15th, 2003, 04:40 PM
instead of picels, use points.

I think that refers to the original 12point font size...


(or I could be wrong, I have popcorns waiting for me ;))

senocular
December 15th, 2003, 04:52 PM
yeah I dont think there is a comparison... and it seems css sizes are much more flaky cross-platform/broser than html font sizes. So what could be the same on one browser on one OS may not be the same on another browser on another OS. I try to stick to font tags when possible.

but there are a lot of units you can play with in style sheets too... theres percent, inches, centimeters, em's, ex's, points, picas, and pixels (I think thats most if not all of them). I personally use pixels - just because I know them better in the bitmap world (I don't know how accurately they're represented). But I guess you can just play with them and see for yourself.

eilsoe
December 15th, 2003, 05:50 PM
if you use font tags, you also allow the user to do the ctrl+scroll thing.

CSS locked text will not do this.


It's useful if you use a particular size text on a design, and any other size text will screw it up... :)

I always use CSS... :)

Didiusthegreat
December 16th, 2003, 06:56 AM
Originally posted by njs12345
However, I did find this for you: http://www.motive.co.nz/resources/webfonts.html


Thanks a lot, that was exactly what I needed.

Thanks for the replys ;)