Due to a recent problem with a font on OSX, I found myself investigating OSX’s font validator. It actually ships with one which is accessible through FontBook, OSX’s font management program. Open it up, then go to ‘File’ -> ‘Validate File’ and you’ll get this:
Already this is somewhat useful, but it doesn’t go into much detail. However, Apple provides a suite of font tools on their website for developers, which contains a version which is more helpful.
Unlike the first version, this is a command line tool only. The installer will place it in usr/bin, so it should be usable anywhere.
The documentation might tell you that the command you want is ATSValidator, which has supposedly replaced ftxvalidator, but after installing and being unable to find ATSValidator I snooped around inside the package (with a little help from this useful article) and found that it isn’t there – but an updated version of ftxvalidator is. I’m not sure whether the documentation is ahead or behind the product itself, but it could definitely be more helpful!
So, open up the console, navigate to where your fonts are, and try this:
> ftxvalidator -r -o results.plist YourFont.otf
A file called ‘results.plist’ will be created with the validation report. This is a properties list file, which OSX has a viewer built in for. The results can be a little obtuse, but it does give more detail than just using the Font Book version.
Keep an eye out for properties caled ‘kATSFontTestResultKey’ – these are empty if the test is passed and contain a value which describes the failure if they don’t.
If you don’t need to look at OS X’s font support in particular, I’d recommend Microsoft’s Font Validator, as it seems to test much more and report back in much greater detail, while also being much nicer to use. If you’re stuck with OS X, however, I hope this has been useful.
This post is part of our “Fonts Articles Index” in these articles we explore Fonts.
IDRsolutions develop a Java PDF library, a PDF forms to HTML5 converter, a PDF to HTML5 or SVG converter and a Java Image Library that doubles as an ImageIO replacement. On the blog our team post about anything interesting they learn about.