Extract Mac Font Files (.dfont) into .ttf Files

Have you ever been in a situation where you desperately need a copy of a font for something you're working on, but you can only seem to find a copy in the wrong format? Often this can happen, and you have the font elsewhere, but it's not in the standard .ttf format you expect.

If you're dealing with a font that has originated on a Macintosh, it might be a font packaged in the .dfont format. This format is Mac-specific and it allows multiple variants of the same font (or even different fonts entirely) to be packaged inside one file and therefore transported more easily, along with Mac-specific metadata... between Macs that is.

Thankfully, there is an open source tool called fondu available for Unix systems that allows you to take one of these dfont files and split it into the individual ttf files it contains. Once you have the .ttf, it is then trivial to add this into your ~/.fonts directory on Linux and use it natively.

On my Ubuntu system, I was able to simply sudo apt-get install fondu, but if a package is not available for your operating system, you can get the source code and compile it yourself.

Once fondu is installed, this is how you use it:

$ fondu name_of_dfont_file.dfont

It will extract the font file into its constituent parts. As well as TTF files, you might notice other files which won't probably be of much use. However, the net result is that you'll get what you want - TTF files that you can now make use of in pretty much any operating system you want.

Avatar for peter Peter Upfold - http://peter.upfold.org.uk/

Peter Upfold is a technology enthusiast from the UK. Peter’s interest in Linux stems back to 2003, when curiosity got the better of him and he began using SUSE 9.0. Now he runs Linux Mint 9 on the desktop, runs a CentOS-based web server from home for his personal website and dabbles in all sorts of technology things across the Windows, Mac and open source worlds.

Home » Articles »

Discussion: Extract Mac Font Files (.dfont) into .ttf Files

  1. stefan (guest)

    # Posted on 23 June 2009 at 03:14 PM

    or just simply go to http://onlinefontconverter.com



  2. Guy (guest)

    # Posted on 28 August 2009 at 05:45 PM

    Hey bru, you saved me! With Ubuntu it worked like a charm. The only hastle I had was finding where the files were generated once the script ran - they were generated in my home directory, while I was looking in the source directory & the fonts directories.

    Thanks for the great article.



Home » Articles » Extract Mac Font Files (.dfont) into .ttf Files