Re: Relative Font Sizing (Lack of)

>From: James Green <www-style@cyberstorm.demon.co.uk>
>However, I have come across a problem. The disclaimer at the bottom of
>each page makes use of the <SMALL> ... </SMALL> element which is great
>for handling variable size browser text on the user's side.
>Unfortuantely, it has text which links to a legal page and this
>obviously involves a <A> tag. In my stylesheet I have 'A' defined with
>text-size: 10pt (it's the arial font); this means that, through
>inheritance, that the <A> text within the <SMALL> ... </SMALL> bit comes
>up as increased font size. I notice in the CSS2 spec that relative
>sizing isn't permitted. So...
>
>Q1: Why?
>
>Q2: Will it be introduced in CSS3? (Not that anyone will know of
>    course.)

Relative sizing is permitted (since CSS1).  You can use percentage units or em
units (they are basically the same when dealing with font-size,
although support varies).  To have a smaller font, you could use

P { font-size: .8em; }
or
P { font-size: 80%; }

>
>Q3: Other than having an A.small {text-size: 8pt } in the stylesheet, is
(you mean font-size:)
>    there any other way of getting around this inadequacy?

Yes.  You could either
1) use relative font sizes if you want your anchor text smaller.  This
    is the better solution since relative font sizes are almost always
    better (more portable) than absolute ones.
2) declare:
SMALL A {font-size: 8pt; }

It's not entirely clear to me why you want your link text smaller than
your normal text in the first place, but that is your choice, unless
you really have all text (based on P) set to 10pt, in which case there
is no need to set A to 10pt as well.

One final comment.  This list is intended for discussion of the development
of CSS.  Requests for help are probably more approprate in the newsgroup
news:comp.infosystems.www.authoring.stylesheets than on this list.

David Baron

--------------------------------------------------------------------
L. David Baron         | Freshman, Harvard
dbaron@fas.harvard.edu | < http://www.fas.harvard.edu/~dbaron/ >
Webmaster, International Weather Satellite Imagery Center, etc.
--------------------------------------------------------------------

Received on Tuesday, 22 September 1998 17:59:54 UTC