From 090ac50d79fbba9c6587dfeb3c1ca8264f90c8eb Mon Sep 17 00:00:00 2001 From: Po Lu Date: Tue, 31 Oct 2023 21:04:11 +0800 Subject: [PATCH] Don't round underline metrics * src/sfntfont.c (sfntfont_open): Don't round underline position or thickness, much as the other font drivers don't either. --- src/sfntfont.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/sfntfont.c b/src/sfntfont.c index 822e4b20ee7..80fbde9772c 100644 --- a/src/sfntfont.c +++ b/src/sfntfont.c @@ -3286,11 +3286,11 @@ sfntfont_open (struct frame *f, Lisp_Object font_entity, else { font_info->font.underline_position - = sfnt_coerce_fixed (SFNT_CEIL_FIXED (-desc->underline_position - * font_info->scale)); + = sfnt_coerce_fixed (-desc->underline_position + * font_info->scale); font_info->font.underline_thickness - = sfnt_coerce_fixed (SFNT_CEIL_FIXED (desc->underline_thickness - * font_info->scale)); + = sfnt_coerce_fixed (desc->underline_thickness + * font_info->scale); } /* Now try to set up grid fitting for this font. */ -- 2.39.2