Connecting AFDKO & FontForge

typovar's picture

Though I'm not sure if it's nescessary at all, is it possible to connect AFDKO to FontForge?

Miguel Sousa's picture

> Though I’m not sure if it’s nescessary at all

Can you generate OpenType CFF fonts with FontForge?

> is it possible to connect AFDKO to FontForge?

What kind of connection do you have in mind? For example, FontLab uses the AFDKO source code internally so that users can output OT CFF fonts. But one can also only output a Type 1 font from FontLab and build the OT CFF with the standalone AFDKO.

twardoch's picture

Typovar,

if you'd prefer not to use FontForge's output for OpenType PS (CFF), generate a Type 1 font from FontForge and then use AFDKO to convert it to OpenType.

Adam

typovar's picture

Thanks for the respons!

I was indeed thinking about something Miguel said: "Using the AFDKO source code internally". But according to Adam, Fontforge generates OppenType PS (CFF) as well.

Is there any difference (technically) in the fonts generated by the two programms?
And what about "error-checking", does AFDKO has somekind of "quality-check" built-in to check curves and glyphs? Different from FontForge? Better? More industry-standard/compliant?

Before investing time and money in somekind of comparisson of the possibilities, I thought I'd better ask here first.

Arjen

Miguel Sousa's picture

The AFDKO is a kit containing a set of tools for OpenType font development. The most notable of those tools is MakeOTF, which is the one that, provided with the necessary files, generates OpenType CFF fonts (.otf). I believe this is the code that FontLab and FontMaster carry under the hood.
In addition to MakeOTF, there are several other tools for tasks such as hinting, testing, and a few macros for FontLab. Here's a small list of some of the other tools included in the AFDKO:

Autohint — for hinting PFA (Type 1) files. (It is also able to operate on OTF files, but it's not recommended as the resulting font won't be subroutinized, and thus will have a bigger file size)
CheckOutlines — reports outline-construction errors. Can operate in PFA and OTF files.
CompareFamily — reports problems found across a family of fonts (OTFs), and in each font individually. (AFAIK, this is the only font development tool in the world that checks the consistency of a font family).
spot — reports the font’s OpenType data. OT tables can be dumped to a text file, or shown graphically by generating a PostScript file.
tx — for analyzing and converting the glyph-outline data of TrueType fonts and all OpenType font formats. It can output the results in several formats, including PDF.

Brief explanation and usage examples of these tools is provided here:
http://blogs.adobe.com/typblography/typotechnica2007/TypoTechnica2007_Fo...
http://blogs.adobe.com/typblography/typotechnica2007/TypoTechnica2007_St...
http://blogs.adobe.com/typblography/typotechnica2007/QE_Outputs.pdf

dezcom's picture

Thanks for the links, Miguel! I assume these are the ones you mentioned in your session at TypeCon?

ChrisL

Miguel Sousa's picture

> Better? More industry-standard/compliant?

Through the AFDKO, Adobe makes publicly available the exact same tools that are used in-house for building and testing its fonts. What you or other parties eventually do with it won't necessarily be better or worse. The only guarantee is that whoever uses the AFDKO tools has the potential to make fonts as good as Adobe's (technically at least).
Deciding for one tool or another will also depend on your workflow, platform, preferences, computer skills, needs, etc.

Miguel Sousa's picture

Yes, I think so Chris.

Michel Boyer's picture

> Can you generate OpenType CFF fonts with FontForge?

For information on the output formats of fontforge, you can look here.

k.l.'s picture

Is there any difference (technically) in the fonts generated by the two programms?

You could use TTX to convert both FontForge- and AFDKO-generated OTFs into the .ttx format (xml representation of OTFs) and compare the tables' content. Ideally, you would use a FontForge-generated OTF as input for AFDKO, so you can compare what both tools do with 'the same font'.

Karsten

typovar's picture

Enough reading to fill the rest of this weekend; Thanks very much.
There is a particular line in the "ReadMe for AFDKO" which made me wonder about this:

3. AFDKO Installation Guide
< cut something here ...>
If you have previously installed the AFKDO v 2.0, you can simply replace the old FDK directory with new one, and, if you are using the scripts for FontLab, run the script "FDK/Tools/FontLab/installFontLabMacros", and you will not need to do anything else.

If it's possible to install the macro's in FontLab, it should be able to install it in FontForge... Any suggestions in how to do this?

k.l.'s picture

As to your quote from the Installation Guide, the non-bolded and the bolded sections refer to different parts of AFDKO.
The first: to the AFDKO which is an independent set of tools (MakeOTF, compareFamily, etc).
The second: to the (additional) macros for FontLab which must be run from within FontLab Studio and rely on FLS's own Python API and are supposed to modify FLS's font files -- so it is rather unlikely that these will work in FontForge.

blokland's picture

'[...] I believe this is the code that FontLab and FontMaster carry under the hood. [...]'

Yes, the DTL FontMaster OpenType functionality is based on the SDK. A major difference with FontLab (you must correct me if I am wrong) is that the GSUB and GPOS features listed in the used features file(s) don't have to match the glyph set(s) for generating OT fonts. Features that are not covered by the characters in the outputted font are simply removed during generation. This way it is possible to use features files globally, i.e. for a complete library. New features can be added to a central features file and by generating all applicable OT fonts in batch, subsequently all these fonts will contain the new defined features. Or glyphs can be added to the databases and when covered by the features file re-generating the fonts will result in new features also.

The features files can also be used locally, i.e. per font and contain the necessary naming and metrics info for a particular font. When used globally in batch this info is taken from the UFM files belonging to the glyph databases (these are connected by file name). The kern info is taken then from an attached AFM or kern.fea file. Switching between the naming and metrics info in the features file and the information in the UFM and kern files can be done by adding a few lines at the end of the features files and subsequently activating or de-activating these.

mr's picture

"If it’s possible to install the macro’s in FontLab, it should be able to install it in FontForge"

Not without work. FontForge's python interface is not identical to FontLab's (I don't know how different they are, but George Williams generally avoids even looking at FontLab for intellectual property reasons). I've considered porting the AFDKO macros to FontForge, but it isn't particularly interesting work, and I don't need it myself (and I haven't heard of anyone else who would be interested until now).

Another issue for me is that the autohinting module (probably the most interesting part of the AFDKO) is contained in a Windows DLL (presumably the Mac version has the Mac equivalent), which I can't use in Linux, anyway, so the incentive is reduced.

Syndicate content Syndicate content