From 2bd053c9c2207a7c0afa2defee10568fde2e7c50 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Thu, 3 May 2018 19:18:31 +0300 Subject: [PATCH] Round kerning values to nearest integer rather than down --- ttf2png.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ttf2png.c b/ttf2png.c index eabe1ca..e890e33 100644 --- a/ttf2png.c +++ b/ttf2png.c @@ -543,7 +543,7 @@ int init_font(Font *font, FT_Face face, const Range *ranges, unsigned n_ranges, kern = &font->kerning[font->n_kerning++]; kern->left_code = font->glyphs[i].code; kern->right_code = font->glyphs[j].code; - kern->distance = kerning.x/64; + kern->distance = (kerning.x+32)/64; } } -- 2.45.2