/pidgin/main: 88ce4f534696: Display IRC MOTD in font-family: mon...

Ethan Blanton <[email protected]>
Newsgroups gmane.comp.gnome.gaim.cvs
Message-ID <[email protected]>
Changeset: 88ce4f5346961b46b62ee6ce549b9e498eba6aa1
Author:	 Ethan Blanton <[email protected]>
Date:	 2014-11-14 11:45 -0500
Branch:	 release-2.x.y
URL: https://hg.pidgin.im/pidgin/main/rev/88ce4f534696

Description:

Display IRC MOTD in font-family: monospace.  Fixes #13727

diffstat:

 libpurple/protocols/irc/irc.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (22 lines):

diff --git a/libpurple/protocols/irc/irc.c b/libpurple/protocols/irc/irc.c
--- a/libpurple/protocols/irc/irc.c
+++ b/libpurple/protocols/irc/irc.c
@@ -66,7 +66,7 @@ static void irc_view_motd(PurplePluginAc
 {
 	PurpleConnection *gc = (PurpleConnection *) action->context;
 	struct irc_conn *irc;
-	char *title;
+	char *title, *body;
 
 	if (gc == NULL || gc->proto_data == NULL) {
 		purple_debug(PURPLE_DEBUG_ERROR, "irc", "got MOTD request for NULL gc\n");
@@ -79,7 +79,8 @@ static void irc_view_motd(PurplePluginAc
 		return;
 	}
 	title = g_strdup_printf(_("MOTD for %s"), irc->server);
-	purple_notify_formatted(gc, title, title, NULL, irc->motd->str, NULL, NULL);
+	body = g_strdup_printf("<span style=\"font-family: monospace;\">%s</span>", irc->motd->str);
+	purple_notify_formatted(gc, title, title, NULL, body, NULL, NULL);
 	g_free(title);
 }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.