Extracting features from a known Arabic/Urdu font.

aniqa.arif's picture


I am working with a font namely Jameel Noori Nastaleeq. This is a ligature based font with around 20,000 ligatures contained. What I need to do is somehow extract the control points of the outline curves (cubic Bezier Curves) of each ligature. I have tried exporting ligatures to .EPS files from Fontlab and I would like to know is this an accurate approach or is there a more straight forward method?

Secondly I also need to decompose each ligature into its corresponding characters. Now I opened the font in MS VOLT and it won't import any of the font's opentype tables, unless the tables were made in VOLT (which is not the case here). All I can do in VOLT is edit some individual glyph properties, in fact the ligature images are also read in as single component images as in the following, whereas it should have had three:

Also in FontLab I have tried extracting Opentype tables into FontLab's opentype panel. But there is no information on ligature composition or anything close to it.

As a last resort, is there a tool with which I can interpret the binary font file, in order to extract ligature information from it?

I would appreciate any guidance in terms of resources, links, software that I could use to accomplish this.


Khaled Hosny's picture

I use FontForge and never had a problem editing existing OpenType features. With its python scripting, you can even automate converting ligatures into contextual substitution features, but you still have to edit the outlines manually. It can also export layout tables into feature files (as used by AFDKO), but not 100% reliable. FontForge can export glyph outlines to a variety of file formats.

There is also fontttols' ttx, that can decompose the whole font (including OpenType tables) into a xml file, but it is quite low level for the task at hand.

aniqa.arif's picture

Khaled Hosny- Thank you! Fontforge worked for me. It can export to its native .SFD file (Spline Font Database), and in fact its a comprehensive file listing everything, all the lookups, glyph definitions etcetera of the opentype font. Though its a 2 million line file(!), I guess I can write code to extract the relevant information.
I still couldn't export to the Adobe feature file though, can you guide me as to where that option is?

blokland- It sounds like a great tool, but I was hoping for a cheaper alternative :)

Khaled Hosny's picture

Element -> Font Info -> Lookups, right click and Save Feature File.

I forgot to mention FontUtils, which have some interesting tools.

Syndicate content Syndicate content