From 55e4f1c42e8d1131b01659fad67db5d084780227 Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Tue, 1 Jun 2021 13:31:38 +0100 Subject: Implement support for strikethrough text. https://defs.ircdocs.horse/info/formatting.html --- src/common/outbound.c | 3 +++ src/common/util.c | 1 + 2 files changed, 4 insertions(+) (limited to 'src/common') diff --git a/src/common/outbound.c b/src/common/outbound.c index c39a1d46..70fcd436 100644 --- a/src/common/outbound.c +++ b/src/common/outbound.c @@ -4434,6 +4434,9 @@ check_special_chars (char *cmd, int do_ascii) /* check for %X */ case 'I': buf[i] = '\035'; break; + case 'S': + buf[i] = '\036'; + break; case 'C': buf[i] = '\003'; break; diff --git a/src/common/util.c b/src/common/util.c index 5b5fb23f..fa0783d4 100644 --- a/src/common/util.c +++ b/src/common/util.c @@ -329,6 +329,7 @@ strip_color2 (const char *src, int len, char *dst, int flags) case '\026': /*ATTR_REVERSE: */ case '\002': /*ATTR_BOLD: */ case '\037': /*ATTR_UNDERLINE: */ + case '\036': /*ATTR_STRIKETHROUGH: */ case '\035': /*ATTR_ITALICS: */ if (!(flags & STRIP_ATTRIB)) goto pass_char; break; -- cgit 1.4.1