From b7e52bb03cfd2d47249019de9c39cadcad18f547 Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Fri, 19 Sep 2025 11:10:52 +0200 Subject: Underline does not appear in some fonts and scales (Windows,X11-noCairo) (#1308) --- src/Fl_Graphics_Driver.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/Fl_Graphics_Driver.cxx') diff --git a/src/Fl_Graphics_Driver.cxx b/src/Fl_Graphics_Driver.cxx index dcdc25834..95daea936 100644 --- a/src/Fl_Graphics_Driver.cxx +++ b/src/Fl_Graphics_Driver.cxx @@ -970,7 +970,8 @@ int Fl_Scalable_Graphics_Driver::descent() { void Fl_Scalable_Graphics_Driver::draw(const char *str, int n, int x, int y) { if (!size_ || !font_descriptor()) font(FL_HELVETICA, FL_NORMAL_SIZE); Fl_Region r2 = scale_clip(scale()); - draw_unscaled(str, n, floor(x), floor(y)); + int offset = (scale() == 1 ? 0 : -1); // for issue #1308 + draw_unscaled(str, n, floor(x), floor(y + offset)); unscale_clip(r2); } -- cgit v1.2.3