Skip to content

Instantly share code, notes, and snippets.

@santhoshtr
Created February 8, 2013 09:24
Show Gist options
  • Save santhoshtr/4737656 to your computer and use it in GitHub Desktop.
Save santhoshtr/4737656 to your computer and use it in GitHub Desktop.
Generates an adobe feature file for the current font. If a lookup-name is specified then only data for that lookup will be generated.
#!/usr/bin/python
import sys
import fontforge
if __name__ == "__main__":
if len(sys.argv) < 3:
print "USAGE: python generate_featurefile.py <font/sfd file> <featurefile>"
else:
font = fontforge.open(sys.argv[1])
font.generateFeatureFile(sys.argv[2])
font.close()
print "[OK] Font featurefile generated"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment