Font size, px or %?

  powerless 20:13 26 Sep 2005

What, if any are the advantages of using px or % for the font size?




  powerless 20:16 26 Sep 2005

Of which this will be defined in my CSS.

  Forum Editor 23:51 26 Sep 2005

and I could write pages about the pros and cons of the different specifications. The real answer will be determined by the use to which your site will be put - your target audience if you like.

Broadly speaking, if control over the look of your Web page is your biggest concern, then you should use pixels. Pixels are the standard unit of measure for screens and monitors, and fonts will be more precisely the size you want on the screen.

If you are concerned about accessibility, then you should use ems. Ems are sized so that the font size is relative to the parent element. In the case of most Web pages, this is the body element - and so the font is sized relative to the standard size of the browser.

  powerless 21:14 27 Sep 2005

As the font size will be via CSS I can always change it can't I?

Experiment, see what's what etc...

  Forum Editor 01:13 28 Sep 2005

the beta version of which I'm using at the moment.

The build I have is the developer version, so it doesn't include all the eventual features, but it certainly looks better, even though the new interface isn't by any means complete yet, and it seems to run a little faster. Microsoft say that it will have improved support for Cascading Style Sheets, as well as transparent PNG support.It will also have automatic discovery of RSS feeds on pages - something I particularly welcome - and will have an inbuilt RSS reader.

A final word on font sizes in CSS Powerless - don't use absolute sizes in your style sheets. Code font sizes in relative terms, using percentages such as 120% for large text and 90% for small text.

  powerless 19:20 30 Sep 2005

Well I'll see what hapens.

Thanks everyone.

This thread is now locked and can not be replied to.

Elsewhere on IDG sites

Huawei Mate 30 Pro Review: Hands-on

Fred Deakin on creating the artwork for his sci-fi rock opera The Lasters

Best iOS 13 features: What does iOS 13 do

Les meilleures enceintes connectées avec écran tactile (2019)