Hi,
I would like to know how I can detect if a specific character or range of characters is present inside a .ttf font file, using PHP.
I am familiar with using imagettftext to display text in an image using a specific font, however if some of the characters that I use in my text are missing in the font, they are displayed as rectangles.
I would therefore like to write a script to examine the .ttf before using it, to check that all of the characters that I require are there.
If anyone has any information on this, I would greatly appreciate it if you could please let me know.
Thanks.
Detecting specific character inside TTF file
Moderator: General Moderators
-
torontonian
- Forum Newbie
- Posts: 2
- Joined: Wed Mar 01, 2006 3:22 pm
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
I don't recall seeing any libraries that can get you information about font data, but these may help.
Microsoft Typography group tools: http://www.microsoft.com/typography/tools/tools.aspx
File specification information: http://www.microsoft.com/typography/Spe ... rview.mspx
Microsoft Typography group tools: http://www.microsoft.com/typography/tools/tools.aspx
File specification information: http://www.microsoft.com/typography/Spe ... rview.mspx
-
torontonian
- Forum Newbie
- Posts: 2
- Joined: Wed Mar 01, 2006 3:22 pm