Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Checking for Font

Status
Not open for further replies.

varnix

Programmer
Jan 7, 2002
94
0
0
US
On one of my pages I'm thinking of using a font that not everyone may have installed.

Is there a way - using java, javascript, smoke signals, anything at all - to detect what fonts are installed on a pc?

I've seen a Java App that lists all of the fonts, but it only appears to work in NS 7.0.

Thanks!
 
sorry but unfortunalty to my knowledge the big problem with the web is that you can't figure out what fonts are installed on the the client's machine.

Even deducing that someone has Tahoma just because he has windows is not a good way to go about it since a user can remove fonts from the system.

Try using many fonts in cascading style sheets. This way if the user doesn't have a font the next one will be used.

.myClass
{
font-family : Verdana, Geneva, Arial, Helvetica, sans-serif;
}

I hope this helps you out! :) Gary Haran
 
In theory, it is possible to embed fonts within a page using css to point to the font file on your server. There are seperate programs for making the file and seperate procedures for linking to it for Netscape and Internet Explorer. I tried it a while back, but never managed to get it working. Try doing a search for those programs and see if it works any better for you.

Here's the way I tried:

Code:
<link rel=&quot;fontdef&quot; src=&quot;chiller.pfr&quot; />
<style type=&quot;text/css&quot;>
@font-face {font-family:Chiller, src:url(CHILLER0.eot);}
</style>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top