Go Back   Velocity Reviews > Newsgroups > HTML
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

HTML - font size %

 
Thread Tools Search this Thread
Old 02-10-2005, 11:46 AM   #1
Default font size %


I've read that some people use a font size 100.01% to
prevent a bug from making fonts tiny.

For example here:
http://archivist.incutio.com/viewlist/css-discuss/39971

But I don't see many sites using 100.01%.

I read other people writing: "use % and use 100 of
them" while others say "use % but not exactly 100".

- What's really true?
- Why/when use 100% (or 100.01%) for <body> instead of
'no specified font size' at all?
- Can I use 100.01% for <body> and then em for the rest
(hx, p etc.) without any bug problems (like IE)?

--
chlori


chlori
  Reply With Quote
Old 02-10-2005, 12:11 PM   #2
Steve Pugh
 
Posts: n/a
Default Re: font size %

chlori <chlori@.invalid> wrote:

>I've read that some people use a font size 100.01% to
>prevent a bug from making fonts tiny.


There was a bug in some older versions of Opera. But that's not
relevant now so this hack is no longer needed.

>For example here:
>http://archivist.incutio.com/viewlist/css-discuss/39971


The author of that post states that he doesn't know why 100.1% is
needed.

>But I don't see many sites using 100.01%.


I don't see many using 100% either.

>I read other people writing: "use % and use 100 of
>them" while others say "use % but not exactly 100".
>
>- What's really true?


Well that very much depends on which school of philosophy you belong
to. (He says giving an answer straight out of the sceptic school).

>- Why/when use 100% (or 100.01%) for <body> instead of
>'no specified font size' at all?


Good question. Some people prefer to use em for font sizes but thanks
to a bug in IE need to set 100% initially. Why they don't just use %
throughout is a mystery to me.

>- Can I use 100.01% for <body> and then em for the rest
>(hx, p etc.) without any bug problems (like IE)?


Yes. Or you can use % throughout.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <> <http://steve.pugh.net/>
  Reply With Quote
Old 02-10-2005, 12:22 PM   #3
Dylan Parry
 
Posts: n/a
Default Re: font size %

Steve Pugh wrote:

> Good question. Some people prefer to use em for font sizes but thanks
> to a bug in IE need to set 100% initially. Why they don't just use %
> throughout is a mystery to me.


It's not just for setting font sizes that em can be useful. It can also
be used for setting padding, width, height, margins etc. Using em, the
paddings et al. are set in relation to the size of text that they
contain, whereas if you were to use % then it would be in relation to
the canvas size.

--
Dylan Parry
http://webpageworkshop.co.uk -- FREE Web tutorials and references
  Reply With Quote
Old 02-10-2005, 12:36 PM   #4
Spartanicus
 
Posts: n/a
Default Re: font size %

Dylan Parry <> wrote:

>whereas if you were to use % then it would be in relation to
>the canvas size.


Viewport width.

--
Spartanicus
  Reply With Quote
Old 02-10-2005, 12:47 PM   #5
Steve Pugh
 
Posts: n/a
Default Re: font size %

Dylan Parry <> wrote:
>Steve Pugh wrote:
>
>> Good question. Some people prefer to use em for font sizes but thanks
>> to a bug in IE need to set 100% initially. Why they don't just use %
>> throughout is a mystery to me.

>
>It's not just for setting font sizes that em can be useful.


I know. I was talking solely about the usage for font-size.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <> <http://steve.pugh.net/>
  Reply With Quote
Old 02-10-2005, 12:47 PM   #6
chlori
 
Posts: n/a
Default Re: font size %

Steve Pugh schrieb am 10.02.2005 13:11:
>>I've read that some people use a font size 100.01% to
>>prevent a bug from making fonts tiny.

>
> There was a bug in some older versions of Opera. But that's not
> relevant now so this hack is no longer needed.


Why isn't it relevant now? Why not use that simple and
easy hack just in case 1 visitor comes with an old
opera version. Are there any disadvantages?

>>But I don't see many sites using 100.01%.

>
> I don't see many using 100% either.


Well that's true...

>>- Why/when use 100% (or 100.01%) for <body> instead of
>>'no specified font size' at all?

>
> Good question. Some people prefer to use em for font sizes but thanks
> to a bug in IE need to set 100% initially. Why they don't just use %
> throughout is a mystery to me.


Why they don't just use *nothing* throughout is a
mystery to me...

--
chlori
  Reply With Quote
Old 02-10-2005, 01:00 PM   #7
Steve Pugh
 
Posts: n/a
Default Re: font size %

chlori <chlori@.invalid> wrote:
>Steve Pugh schrieb am 10.02.2005 13:11:
>>>I've read that some people use a font size 100.01% to
>>>prevent a bug from making fonts tiny.

>>
>> There was a bug in some older versions of Opera. But that's not
>> relevant now so this hack is no longer needed.

>
>Why isn't it relevant now?


Opera users tend to upgrade fairly quickly. This bug was in v5 and v6
of Opera and was fixed in the 7.0 betas IIRC.

OTOH there are some Opera users who think that v5 was the best ever
and that everything since is a huge mistake.

>Why not use that simple and
>easy hack just in case 1 visitor comes with an old
>opera version. Are there any disadvantages?


It looks messy?
It requires adding to documentation so future editors know why you've
done such a strange thing?

I don't think there's any technical disadvantage to this method so use
it you like, but please remember why you're using it - don't let it
become another piece of cargo cult nonsense that get's shoved into
every CSS file just because it has been shoved into every CSS file.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <> <http://steve.pugh.net/>
  Reply With Quote
Old 02-10-2005, 01:21 PM   #8
Dylan Parry
 
Posts: n/a
Default Re: font size %

Spartanicus wrote:

>>whereas if you were to use % then it would be in relation to
>>the canvas size.

>
> Viewport width.


Erm, yeah that's what I meant

--
Dylan Parry
http://webpageworkshop.co.uk -- FREE Web tutorials and references
  Reply With Quote
Old 02-10-2005, 02:12 PM   #9
Dylan Parry
 
Posts: n/a
Default Re: font size %

Dylan Parry wrote:
> Spartanicus wrote:
>>> whereas if you were to use % then it would be in relation to the
>>> canvas size.

>>
>> Viewport width.

>
> Erm, yeah that's what I meant


Actually, no, that's not what I meant. What I should have said was "if
you were to use % then it would be in relation to the parent element's
dimensions."


--
Dylan Parry
http://webpageworkshop.co.uk -- FREE Web tutorials and references
  Reply With Quote
Old 02-10-2005, 06:58 PM   #10
Toby Inkster
 
Posts: n/a
Default Re: font size %

Steve Pugh wrote:

> OTOH there are some Opera users who think that v5 was the best ever
> and that everything since is a huge mistake.


O5 was great. After O5, the UI started to get slower. It's still faster
than most other browsers, but not as fast as O5.

OTOH, the rendering engine in O7.x, and particularly in O7.5 is state of
the art. O5's rendering engine was good -- and people seem to forget how
good it was -- but lacked one or two major features -- in particular
reflowing, so some hover effects and dynamic pages could look awful and
overlap.

Would be nice to have an Opera that combined the UI of O5 with the
rendering engine, and customisable toolbars and menus of O7.

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact

  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump