# HG changeset patch # User Stu Tomlinson # Date 1132409239 0 # Node ID d4725469b653ed8f7abdbffb4fb2e58e000c65b9 # Parent b105009a60aeedc09afeda9febf70bd5c35a5cec [gaim-migrate @ 14459] I assume it's ok to bring this into HEAD from oldstatus? : "Apparently at some point I wrote italic support for IRC and never committed it" -- Ethan, Aug 26th 2005. committer: Tailor Script diff -r b105009a60ae -r d4725469b653 src/protocols/irc/parse.c --- a/src/protocols/irc/parse.c Sat Nov 19 14:03:54 2005 +0000 +++ b/src/protocols/irc/parse.c Sat Nov 19 14:07:19 2005 +0000 @@ -284,7 +284,7 @@ const char *cur, *end; char fg[3] = "\0\0", bg[3] = "\0\0"; int fgnum, bgnum; - int font = 0, bold = 0, underline = 0; + int font = 0, bold = 0, underline = 0, italic = 0; GString *decoded = g_string_sized_new(strlen(string)); cur = string; @@ -338,6 +338,16 @@ decoded = g_string_append_c(decoded, '>'); } break; + case '\011': + cur++; + if (!italic) { + decoded = g_string_append(decoded, ""); + italic = TRUE; + } else { + decoded = g_string_append(decoded, ""); + italic = FALSE; + } + break; case '\037': cur++; if (!underline) { @@ -358,6 +368,8 @@ case '\000': if (bold) decoded = g_string_append(decoded, ""); + if (italic) + decoded = g_string_append(decoded, ""); if (underline) decoded = g_string_append(decoded, ""); if (font)