By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,948 Members | 1,559 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,948 IT Pros & Developers. It's quick & easy.

determine if font-smoothing is in effect

P: n/a
Is it possible to determine with javascript or other means if the user has
any sort of font-smoothing in effect on their os or ua?

Serif'd fonts don't look so nice on non-smoothed systems, so, i'd rather
switch to plain old Arial...

The idea is to detect this fact and then alter the font/s that are used to
display a website via javascript - modifying the dom tree, I guess.

Thanks,

Sep 18 '08 #1
Share this Question
Share on Google+
2 Replies


P: n/a
"Joe Butler" <ff***********@hotmail-spammers-paradise.comwrites:
Is it possible to determine with javascript or other means if the user has
any sort of font-smoothing in effect on their os or ua?
No.
Serif'd fonts don't look so nice on non-smoothed systems, so, i'd rather
switch to plain old Arial...
Or rely on the user's default font? You can probably assume that it works
for his settings.
Or let the user pick the font he prefers.
The idea is to detect this fact and then alter the font/s that are used to
display a website via javascript - modifying the dom tree, I guess.
To change the font, you change the CSS rules, not the DOM tree.

/L
--
Lasse Reichstein Nielsen
DHTML Death Colors: <URL:http://www.infimum.dk/HTML/rasterTriangleDOM.html>
'Faith without judgement merely degrades the spirit divine.'
Sep 18 '08 #2

P: n/a
OK, shame.

The default font on FF3 seems to be Times New Roman. This is not such a
good choice on non-smoothed systems.

I would have thought to change the font via javascript, that a CSS rule for
say body would be inserted into the dom tree that overrode the one specified
in the main css file.

What do you mean by changing the css rules? Can this be done in javascript
outside of the dom tree?

"Lasse Reichstein Nielsen" <lr********@gmail.comwrote in message
news:ab**********@gmail.com...
"Joe Butler" <ff***********@hotmail-spammers-paradise.comwrites:
>Is it possible to determine with javascript or other means if the user
has
any sort of font-smoothing in effect on their os or ua?

No.
>Serif'd fonts don't look so nice on non-smoothed systems, so, i'd rather
switch to plain old Arial...

Or rely on the user's default font? You can probably assume that it works
for his settings.
Or let the user pick the font he prefers.
>The idea is to detect this fact and then alter the font/s that are used
to
display a website via javascript - modifying the dom tree, I guess.

To change the font, you change the CSS rules, not the DOM tree.

/L
--
Lasse Reichstein Nielsen
DHTML Death Colors:
<URL:http://www.infimum.dk/HTML/rasterTriangleDOM.html>
'Faith without judgement merely degrades the spirit divine.'

Sep 18 '08 #3

This discussion thread is closed

Replies have been disabled for this discussion.