From 199c271edc138931905043a5acdced3c8c995fd8 Mon Sep 17 00:00:00 2001 From: nullchilly Date: Tue, 26 Jul 2022 20:08:04 +0700 Subject: [PATCH] Fix modify_font underline_position 1 --- kitty/fonts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kitty/fonts.c b/kitty/fonts.c index 0d26718a0..5410ee3c5 100644 --- a/kitty/fonts.c +++ b/kitty/fonts.c @@ -392,7 +392,7 @@ calc_cell_metrics(FontGroup *fg) { underline_position = MIN(cell_height - 1, underline_position); // ensure there is at least a couple of pixels available to render styled underlines - while (underline_position > baseline + 1 && cell_height - underline_position < 2) underline_position--; + while (underline_position > baseline + 1 && cell_height - underline_position < 1) underline_position--; if (line_height_adjustment > 1) { baseline += MIN(cell_height - 1, (unsigned)line_height_adjustment / 2); underline_position += MIN(cell_height - 1, (unsigned)line_height_adjustment / 2);