Improve Windows Type Rendering With ttfautohint

In a stroke of genius, Wern­er Lem­berg has start­ed the ttfau­to­hint project, which repur­pos­es FreeType’s auto­hint­ing sys­tem to auto­mat­i­cal­ly hint True­Type fonts for improved Win­dows ren­der­ing. While no auto­hin­ter will be able to match the eye and skills of a man­u­al hin­ter, ttfau­to­hint pro­vides real world improve­ments, some­times dra­mat­i­cal­ly.

For exam­ple, I’m work­ing as a con­trac­tor on a project using the clas­sic VAG Round­ed font. 13px bold looks great in Pho­to­shop comps and Mac browsers, but fails hor­ri­bly under Win­dows. I decid­ed to run VAG Round­ed Bold through ttfau­to­hint 0.2 to see if it would offer improve­ments. In short: wow. In the screen­shots below, ttfau­to­hint goes head-to-head with the Fontsquir­rel gen­er­a­tor’s auto­hint­ing (which I believe is pow­ered by Font­Forge).

Ren­der­ing modes are shown in the cap­tions. Click for full size. (I’m restrict­ed to screen­shots because the font is only licensed for the client site.)

Stan­dard (grayscale)

GDI ClearType

DirectWrite ClearType

As you can see, there’s a dra­mat­ic improve­ment in all 3 Win­dows ren­der­ing envi­ron­ments. 11px-13px sizes move from awful, with com­plete­ly closed coun­ters, to supris­ing­ly read­able. At 14px, the coun­ters open up with stan­dard hint­ing, but clos­er inspec­tion reveals oth­er defects such as no sep­a­ra­tion between the body and dot of the i and j char­ac­ters. The improve­ments are even more dra­mat­ic under Stan­dard (grayscale) antialias­ing, which looks ter­ri­ble below 18px. Even under DirectWrite ClearType, ttfau­to­hint pro­duces supe­ri­or results (although a true test would also pro­vide a com­plete­ly unhint­ed ver­sion to see what the DirectWrite ras­ter­iz­er is capa­ble of on its own).

The only real down­side is a mod­est file size increase. I haven’t test­ed across mul­ti­ple fonts, but in this case our font jumped from 49kb to 63kb. I con­sid­er it an excel­lent trade-off for such improved ren­der­ing.

So, you want to use it? Well, first you should sup­port the project. Cur­rent­ly you need to com­pile ttfau­to­hint, but with our sup­port, Wern­er will build a GUI ver­sion for the com­mand line-pho­bic. If you’re on a Mac and want to com­pile, I put togeth­er an instal­la­tion script.

Edit: In an email exchange, Wern­er point­ed out that Dave Cross­land—who has done much of the ttfau­to­hint promotion—had the actu­al idea to use FreeType for hint­ing, although Wern­er still deserves mas­sive praise for the exe­cu­tion. Wern­er also point­ed out that VAG Round­ed is a good show­case font, and that ttfau­to­hint will not per­form such strik­ing results in all cir­cum­stances.