- result += "glyph %d\n{\n"%c
- result += "\ttexcoords %f %f %f %f;\n"%(float(x)/tw, float(th-y-h)/th, float(x+w)/tw, float(th-y)/th)
- result += "\tsize %.3f %.3f;\n"%(float(w)/fh, float(h)/fh)
- result += "\toffset %.3f %.3f;\n"%(float(ox-b)/fh, float(oy-b)/fh)
- result += "\tadvance %.3f;\n"%(float(a)/fh)
+ result += "glyph {}\n{{\n".format(c)
+ result += "\ttexcoords {} {} {} {};\n".format(float(x)/tw, float(th-y-h)/th, float(x+w)/tw, float(th-y)/th)
+ result += "\tsize {:.3f} {:.3f};\n".format(float(w)/fh, float(h)/fh)
+ result += "\toffset {:.3f} {:.3f};\n".format(float(ox-b)/fh, float(oy-b)/fh)
+ result += "\tadvance {:.3f};\n".format(float(a)/fh)