freetype
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft] freetype+gd with mac fonts?


From: Ryan Schmidt
Subject: Re: [ft] freetype+gd with mac fonts?
Date: Fri, 4 Jul 2008 00:01:42 -0500


On Jul 3, 2008, at 14:32, Aaron Winborn wrote:

i am attempting to create an image in php with gd, using freetype for fonts. i can get it working with a .ttf font, but have the mac version of another font that i want to use, and it doesn't load. i saw the warning at http://us.php.net/imagettftext about .ttf being automatically appended, but i'm prepending the font with a /path/ anyway, so it shouldn't matter. just to make sure, i tried the putenv('GDFONTPATH=' . realpath('.')); trick and also tried manually renaming the font with a .ttf extension, both to no avail.

i don't know mac's file standards, but i did notice there was a font GothBla in one folder, and ._GothBla in Gotham/__MACOSX, so i've tried all of this using both files.

any ideas of what to try next?

Are you doing this on a Macintosh or something else? I assume you need a Mac to do this.

Mac files can have two forks -- data and resource. Most every other OS considers a file to be just data. Old Mac fonts are in the resource fork however. On filesystems that don't support multiple forks, the two forks are broken out into two files -- GothBla is the data fork (probably empty?) and ._GothBla is the resource fork. I assume you need to combine these together so that you have a proper Mac resource file.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]