]> git.tdb.fi Git - libs/gl.git/blobdiff - scripts/makefont.py
Add kerning support to Font
[libs/gl.git] / scripts / makefont.py
index 84e9c6099dedcf5c0d18e2a02c068f110d4cc813..11d83794205cebad76b5526e088aa16d0d022df5 100755 (executable)
@@ -23,6 +23,9 @@ def convert_def(fn):
                        result += "\toffset %.3f %.3f;\n"%(float(ox)/fh, float(oy)/fh)
                        result += "\tadvance %.3f;\n"%(float(a)/fh)
                        result += "};\n"
+               elif parts[0]=="kern":
+                       l, r, d = map(int, parts[1:])
+                       result += "kerning %d %d %.3f;\n"%(l, r, float(d)/fh)
 
        return result