Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Use OS X fonts in OS 9 applications Classic
Want to use a Mac OS X .dfont in your Mac OS 8 or 9 application? Convert it using these simple steps.
  1. Download the utility called HexEdit, version 1.7.4 or later.

  2. Copy the .dfont that you want to your desktop, under OS 9. Copy a regular TrueType suitcase, say Capitals for example, to your desktop as well. Make sure these are copies, not the original.

  3. Using HexEdit, open the OS X .dfont file. Go to the Edit menu and choose Select All. Now use the Edit Menu and choose Copy.

  4. Open the TrueType font from your desktop (in my case Capitals) and do and Edit menu > Select All. Now do an Edit Menu > Paste.

  5. Now go to the File menu and Save. Close both files.

  6. To see if your conversion worked, double-click on the Capitals file on your desktop (there will be one called Capitals~, just ignore it, it is the original). You should see the individual cases now inside the font suitcase for each type of font style, for example, I converted Optima first, so I see Optima ExtraBlack, Optima, Optima (bold), Optima (italic), Optima (bold, italic) inside the suitcase. Double-click on one of the cases to see the preview, if the preview works the font is okay.

  7. Close the preview and font suitcase and rename the suitcase to match what is inside of it. Now place the suitcase in your System Folder, or Font Management folder where it belongs. Now you have the OS X font you wanted in Mac OS 9!
If someone is a programmer I think a utility would be great to do the conversion.

[Editor's note: I have not tried this myself, but it seems like a very useful tip! I would love to have access to a couple of the OS X fonts from Photoshop in Classic...]
  • Currently 4.00 / 5
  You rated: 5 / 5 (3 votes cast)

Use OS X fonts in OS 9 applications | 9 comments | Create New Account
Click here to return to the 'Use OS X fonts in OS 9 applications' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
easier way.
Authored by: charlietuna on Dec 05, '01 11:28:16AM

there's an easier way to do this with SNAX or any other utility that swaps resource and data forks. copy the .dfont file. rename the copy if you wish. get the file info of the copied font in SNAX. on the last tab of the info window, you can swap the resource and data forks. the only difference between OS X truetype fonts and OS 9 truetype fonts is that OS 9 fonts keep their stuff in the resource fork while OS X fonts keep their stuff in the data fork (hence "dfont").

[ Reply to This | # ]
Another, still easier way.
Authored by: gf on Dec 05, '01 06:43:13PM

Or do this (using the dreaded Terminal application), using the "Optima" font as an example:

cd /Library/Fonts
touch Optima
cp Optima.dfont Optima/rsrc
SetFile -t FFIL -c DMOV Optima

then move the resulting "Optima" file to your OS 9 fonts folder.

The explanation:
"cd" just makes the OS X "Fonts" folder the current directory. All this line does is save typing. (Without it, you'd have to keep typing the full name of the font files over and over.)
"touch" creates the new OS 9 font file. (OS 9 won't recognize it yet, though.)
"cp" copies the data fork of the OS X font file to the resource fork of the OS 9 file.
"SetFile" marks the new file as an OS 9 font file. Note that you really do have to type it "SetFile", with a capital S and F. Also, FFIL and DMOV *must* be all caps.

I don't know offhand whether "SetFile" is part of the Developer Tools, since I have them installed. Even if it is, anyone inclined to this sort of hackery really should have the Tools available, especially as they're free.

[ Reply to This | # ]
Another, still easier way.
Authored by: charlietuna on Dec 06, '01 10:15:43AM

excellent! fyi SetFile is part of the developer tools.

[ Reply to This | # ]
Swapping forks from the command lne
Authored by: sabi on Dec 06, '01 12:13:49PM

I wrote a function for zsh that does something similar:

swapforks () {
cp $1/data $
cat $1/rsrc >| $1/data
cat $ >| $1/rsrc
rm $

so you just tell a file to 'swapforks', and it exchanges the data and
resource forks. That works for me until I can afford the upgrade to
Resorcerer 2.4.

Another good one is to clear the type/creator of a file:

ClearHFSMetadata: aliased to SetFile -t '' -c ''

which you sometimes want to do, and File Buddy doesn't (or didn't) let
you do this.

[ Reply to This | # ]
easier way.
Authored by: fenevad on Jan 15, '02 10:35:48AM

I have tried both the HexEdit and SNAX methods described in postings on this topic exactly as described and I end up with font files that are corrupt in every case. ATM Deluxe flags them and font tools like Fontographer and TransType won't open them, saying that they are damaged.

I also tried the command line version and found that the SetFile command is not available to me, despite DeveloperTools being installed.

Does anyone have any comments on why these methods would fail or why someone with DeveloperTools installed wouldn't be able to use the commands it installs?

-Arle Lommel

[ Reply to This | # ]
easier way.
Authored by: fenevad on Jan 16, '02 09:21:19AM

Turns out the problem was that the font I was trying this with was, in fact, corrupted. Funny thing. Still don't know why SetFile won't work on my machine though.

[ Reply to This | # ]
easier way.
Authored by: kholburn on Jan 17, '02 01:18:12AM

If you have the developers tools installed you may not have them on your path. You need to type:

If that doesn't work try locate SetFile to find it or use Sherlock.

Add the directory to your path :

if you use csh or tcsh add add the line to ~/.tcshrc
set path=($path /Developer/Tools)

in sh/bash add this line to ~/.profile or .bashrc

[ Reply to This | # ]
Use OS X fonts in OS 9 applications
Authored by: avideditor on Oct 10, '03 01:49:46AM

This works great, but be warned, on three separate machines I tried I got a not enough memory error when I tried to paste. I have to (very carefully) cut and paste it in 5 or 6 pieces to get it to work.

[ Reply to This | # ]
The easiest way, by far.
Authored by: mdouma46 on Oct 18, '03 08:49:32PM

Download the application I wrote to do this: dfontifier.

Take your .dfont, drop it onto dfontifier, instant TrueType font.

Hope this helps...

[ Reply to This | # ]