Connecting Tech Pros Worldwide Forums | Help | Site Map

CASCADEand INHERITED properties in Explorer v Firefox

Jim Flack
Guest
 
Posts: n/a
#1: Jul 21 '05
I'm currently trying to set up a webpage where 'visitors' can select their
own size text (over-ride my preferred settings so to speak). I used to use
a fixed font size (11px) but have now tried to set the body element to font
size 70% (see www.flackgenealogy.co.uk/test1.html) and leave all the other
main page element unstated (assuming they inherit the same 70% that the body
gives them).

It all displays fine in FIREFOX (including the (table) TD 'holder' that
displays all the TD content as the same required 70% font value.

HOWEVER - IE6 chooses to ignore the body 70% font size instruction in the
stylesheet and displays the TD content at 100%.

THEN - if I change the stylesheet to TD=70% (see
www.flackgenealogy.co.uk/test2.html) it corrects the IE6 display, but of
course messes up the FIREFOX display.

Has anyone any bright ideas how I can retain the stylesheet with a % size
font (or something similar) rather than revert to my fixed font sizes - so
my pages will be 'viewer adjustable' - and be virtually identical in both
browsers.

Thanks
--
Jim Flack
www.flackgenealogy.co.uk


Spartanicus
Guest
 
Posts: n/a
#2: Jul 21 '05

re: CASCADEand INHERITED properties in Explorer v Firefox


"Jim Flack" <jamesflack@earthlink.net> wrote:
[color=blue]
>I'm currently trying to set up a webpage where 'visitors' can select their
>own size text (over-ride my preferred settings so to speak).[/color]

Your preferred text size needs to be entered in your browser's
configuration, you then enable the user's preferred text size on your
web site by specifying no body font size, or set it to 100%.

--
Spartanicus
jimflack
Guest
 
Posts: n/a
#3: Jul 21 '05

re: CASCADEand INHERITED properties in Explorer v Firefox


Thanks Spartanicus, but I think I didnt explain my problem too well.

I am writing the webpage at fontsize 70% as thats the way I initially
want it to look. But if a viewer disagrees, then because its expressed
as a font %, then they have the opportunity to change it - so far so
good.

My point is that Firefox and IE6 seem to cascade/inherit their values
in a different fashion and stop me displaying the webpage in a
consistent fashion

A Firefox TD data cell acts as an information holder only and displays
the enclosed data at the body font setting - while IE6 seems to decide
itself to go back to 100% fontsize in their TD data cell and
completely ignore the 70% font I set in the CSS body statement.

I realise that the viewer can increase/decrease the font size in both
IE and firefox as long as I use a % fontsize - but the 2 browsers (both
modern I thought) interpret the same CSS and display the output in a
totally different fashion.

Maybe its just best to stick with my static (11px) font sizes until the
browser manufacters can agree on how to consistently display the same
set of CSS commands in their browsers (IE6 not suprisingly is the one
that screws it up). (If you view the intitial posted links I gave in
each browser you will see what I mean)

Jim

Martin Bialasinski
Guest
 
Posts: n/a
#4: Jul 21 '05

re: CASCADEand INHERITED properties in Explorer v Firefox


"Jim Flack" <jamesflack@earthlink.net> wrote:
[color=blue]
> HOWEVER - IE6 chooses to ignore the body 70% font size instruction in the
> stylesheet and displays the TD content at 100%.
>
> THEN - if I change the stylesheet to TD=70% (see
> www.flackgenealogy.co.uk/test2.html) it corrects the IE6 display, but of
> course messes up the FIREFOX display.[/color]

Use conditional comments (->google) to give Internet Explorer an
additional td rule.

BTW: Do you create a site to simulate a visual test? I have to bow
heavily towards the screen to read it.

Your 70% rule results in 6px fonts for me. Anything smaller than 9px is
really illegible. Just set it to 100%, and the Text in <p> will be
displayed in the font size I prefer.

Bye,
Martin
Spartanicus
Guest
 
Posts: n/a
#5: Jul 21 '05

re: CASCADEand INHERITED properties in Explorer v Firefox


"jimflack" <james@jimflack.co.uk> wrote:
[color=blue]
>Thanks Spartanicus[/color]

What are you replying to? Quote a small relevant bit of what you are
replying to, insert a blank line and then put your reply *beneath* it.
[color=blue]
>, but I think I didnt explain my problem too well.[/color]

You explained it very well.
[color=blue]
>I am writing the webpage at fontsize 70% as thats the way I initially
>want it to look.[/color]

And so it will if you follow my instructions.
[color=blue]
>But if a viewer disagrees, then because its expressed
>as a font %, then they have the opportunity to change it[/color]

They shouldn't have to, and quite a few won't change it, they might not
know how to, you'd be surprised how many people simply leave if they
can't read the text.
[color=blue]
>Maybe its just best to stick with my static (11px) font sizes[/color]

That's even worse.

--
Spartanicus
kchayka
Guest
 
Posts: n/a
#6: Jul 21 '05

re: CASCADEand INHERITED properties in Explorer v Firefox


Jim Flack wrote:[color=blue]
>
> I'm currently trying to set up a webpage where 'visitors' can select their
> own size text ... tried to set the body element to font
> size 70% (see www.flackgenealogy.co.uk/test1.html) and leave all the other
> main page element unstated[/color]

Don't set body text to such a ridiculously small size - it will look
like fly droppings to many people. Get rid of Verdana while you're at it
- if you stop using it, you'll be less likely to set such tiny sizes in
the first place. Search google for past discussions on Verdana.

If 100% still looks too large in your particular browser, then you are
the one who should change browser settings, not the visitor. Just reduce
your own default text size until 100% looks good to you.
[color=blue]
> IE6 chooses to ignore the body 70% font size instruction in the
> stylesheet and displays the TD content at 100%.[/color]

This could be because your page is triggering IE6 quirks mode, not
standards mode. Get rid of the xml prolog if you want more predictable
rendering in IE6. Search google for more info on this.

BTW, you should probably be using a Strict DTD, not Transitional.

--
Reply email address is a bottomless spam bucket.
Please reply to the group so everyone can share.
vatore
Guest
 
Posts: n/a
#7: Jul 21 '05

re: CASCADEand INHERITED properties in Explorer v Firefox



Użytkownik "Jim Flack" <jamesflack@earthlink.net> napisał w wiadomości
news:t6oxd.4249$yK.2242@newsread3.news.atl.earthli nk.net...[color=blue]
> I'm currently trying to set up a webpage where 'visitors' can select their
> own size text (over-ride my preferred settings so to speak). I used to[/color]
use[color=blue]
> a fixed font size (11px) but have now tried to set the body element to[/color]
font[color=blue]
> size 70% (see www.flackgenealogy.co.uk/test1.html) and leave all the other
> main page element unstated (assuming they inherit the same 70% that the[/color]
body[color=blue]
> gives them).
>
> It all displays fine in FIREFOX (including the (table) TD 'holder' that
> displays all the TD content as the same required 70% font value.
>
> HOWEVER - IE6 chooses to ignore the body 70% font size instruction in the
> stylesheet and displays the TD content at 100%.
>
> THEN - if I change the stylesheet to TD=70% (see
> www.flackgenealogy.co.uk/test2.html) it corrects the IE6 display, but of
> course messes up the FIREFOX display.
>[/color]

In IE table cells don't inherit font size from body (and AFAIK from any
parent element other than table/tr).
body { font-size: 70%; }
* html td { font-size: 70%;}

It will work fine for you, will do exactly what you want.
I don't think it will be good for your users... other posts in this thread
explain why, my 'solution' is an explanation of why does it happen, not an
advice to set my font-size to 70% of my defult 11px (I would get 7.7px
font).


Rijk van Geijtenbeek
Guest
 
Posts: n/a
#8: Jul 21 '05

re: CASCADEand INHERITED properties in Explorer v Firefox


On Tue, 21 Dec 2004 15:04:04 +0100, vatore <vatore@wp.pl> wrote:
[color=blue]
> In IE table cells don't inherit font size from body (and AFAIK from any
> parent element other than table/tr).[/color]

Unless you are talking about MSIE 6.0 after triggering Standards mode, of
course.

--
Rijk van Geijtenbeek

The Web is a procrastination apparatus:
It can absorb as much time as is required to ensure that you
won't get any real work done. - J.Nielsen

Closed Thread