Subject: [PATCH 2/2] term: don't translate undercurl to plain underline

From: Johannes Altmanninger <[email-masked]>
Date: Thu, 17 Apr 2025 20:46:33 +0200

* src/term.c (turn_on_face): given a underline face such as
FACE_UNDERLINE_WAVE, do not automagically translate it
to single underline if terminfo does not declare support
for the desired underline style. Instead, add no underline.

I have not yet figured out how to test this change.  In doubt we
should drop it.  But I included it here anyway, since it tries to
do the same as the previous commit, so it should at least serve to
point out another instance of this problem. I know almost nothing
about Emacs faces; maybe this change would break themes that rely on
this automatic translation.
---
 src/term.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/term.c b/src/term.c
index 8aa47322d19..ef93ccfbef8 100644
--- a/src/term.c
+++ b/src/term.c
@@ -2050,8 +2050,7 @@ turn_on_face (struct frame *f, struct face *face)
 
   if (face->underline && MAY_USE_WITH_COLORS_P (tty, NC_UNDERLINE))
     {
-      if (face->underline == FACE_UNDERLINE_SINGLE
-	  || !tty->TF_set_underline_style)
+      if (face->underline == FACE_UNDERLINE_SINGLE)
 	OUTPUT1_IF (tty, tty->TS_enter_underline_mode);
       else if (tty->TF_set_underline_style)
 	{
-- 
2.49.0