RoboFab Font Extras

class RFont(path=None, showUI=True)

Create a new font object has an optional showUI. ShowUI will toggle the creating of all interface objects around a font.


returns the related NSDocument

renameGlyph(oldName, newName, renameComponents=True, renameGroups=True, renameKerning=True)

Rename a glyph in the font. Optionally the glyph can be renamed in all component references, groups and kerning.

generate(path, format, decompose=False, checkOutlines=False, autohint=False, releaseMode=False, glyphOrder=None, progressBar=None)

Generate a font binary to the given path with the given format (“otf”, “ttf”, “pfa”)

Adding a progressBar object will show you the progress during compiling the font.


removes all overlaps in every glyphs


adds extremes points for every glyph


test instals the font, it returns the ID of the installed font on the os.


removes a complete layer, to create a layer just ask any glyph.getLayer(“myLayerName”)

addGuide((x, y), angle, name="")

adds a guide at point x, y with angle and name returning the created guide


Will remove the guide from the font


tell the UI that a font has changed directly


This marks to glyph to be ready that a action begins and it should be recorded to create an undo item when its done


creates the undo item

setLayerDisplay(layerName, option, value)

set display options for layers option: Fill, Stroke, Points, Coordinates

addObserver(observer, methodName, notification)

adds an observer to the font that notifies the methodName of the observer for a given notification

removeObserver(observer, notification)

removes the observer for the font for a given notification


returns a list of glyph names in a specific order, it is possible to set the a list with a specific order in a font


returns a list of layernames


a list of all the guides in the font


next to the font.selection, which only contains glyphs in the font there is also a selection of template glyphs