以下のような感じでファイルに落とさなくてもできた。
from defcon import Font from fontTools.pens.svgPathPen import SVGPathPen from IPython.display import SVG, display font = Font("font.ufo") glyph_set = font._glyphSet pen = SVGPathPen(glyph_set) font["a"].draw(pen) svg_commands = pen.getCommands() svg = '<svg version="1.1" width="100" height="55" viewBox="0 0 100 55"><g transform="translate(0,50)scale(0.1,-0.1)"><path d="{}" /></g></svg>'.format(svg_commands) display(SVG(svg))