otFeatures

Simple module to write features to font

class robofab.tools.otFeatures.FeatureWriter(type)

Make properly formatted feature code

add(src, dst)

Add a substitution: change src to dst.

write(group=0)

Write the whole thing to string

class robofab.tools.otFeatures.GlyphName(name)

Simple class that splits a glyphname in handy parts, access the parts as attributes of the name.

robofab.tools.otFeatures.GetAlternates(font, flavor='alt', match=0)

Sort the glyphs of this font by the parts of the name. flavor is the bit to look for, i.e. ‘alt’ in a.alt match = 1 if you want a exact match: alt1 != alt match = 0 if the flavor is a partial match: alt == alt1

robofab.tools.otFeatures.MakeCapsFeature(font)

Build a feature for smallcaps based on .sc glyphnames

robofab.tools.otFeatures.MakeAlternatesFeature(font)

Build a aalt feature based on glyphnames

robofab.tools.otFeatures.MakeSwashFeature(font)

Build a swash feature based on glyphnames

robofab.tools.otFeatures.MakeLigaturesFeature(font)

Build a liga feature based on glyphnames