...

View Full Version : Font Sizing with CSS



gorilla1
10-25-2002, 08:13 PM
I am working with a piece of code where there is a tag specifying font size (font size=2). Is there any way to accomplish precisely the equivalent in CSS?

G

redhead
10-25-2002, 08:20 PM
font-size: 10pt;

:thumbsup:

gorilla1
10-25-2002, 08:46 PM
Thanks, Redhead. I have tried that, but pt gives you a fixed size, so that if you go into your browser and adjust the font size (larger, medium, etc), the font size stays fixed. That is a nice way to go and I prefer it, but I am trying to replicate the size and effect of size=2, which does adjust when the viewer makes the browser text size adjustment.

G

Catman
10-25-2002, 09:49 PM
Maybe using one of these:

xx-small, x-small, small, medium, large, x-large, xx-large

would do what you're looking for.

Roy Sinclair
10-25-2002, 11:30 PM
Don't forget that the css spec also allows the use of percentages as well as larger and smaller for relative sizing.

gorilla1
10-25-2002, 11:32 PM
OK, Catman, and Roy, yes, those are good ideas. I will experiment with them. Thanks.

G

gorilla1
10-27-2002, 02:10 AM
Looks like x-small in the arial typeface is about equivalent to +2, if am looking at this right.

G

Roy Sinclair
10-28-2002, 06:26 PM
You'll see that the list Catman posted has exactly 7 sizes listed which should correspond to the seven sizes used by the font tag.

joh6nn
10-28-2002, 09:29 PM
you can also use percentages, which is what i do. it gives you more control over the size of the font, but allows the user to resize them.

liorean
09-06-2003, 04:25 PM
Well, percentages and ems gives the user control over the font size, and to a lesser extent, so does the keyworded sizes. However, those seven keyworded sizes does not represent the seven sizes of the font tag. That is evident by that medium, being the fourth of the keyworded sizes, is the standard size, while 3 is the standard size of the font tag. Thus, you have to be careful with those.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum