summaryrefslogtreecommitdiff
path: root/src/plugins/irc/irc-color.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/irc/irc-color.c')
-rw-r--r--src/plugins/irc/irc-color.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/plugins/irc/irc-color.c b/src/plugins/irc/irc-color.c
index 96e88986b..369324156 100644
--- a/src/plugins/irc/irc-color.c
+++ b/src/plugins/irc/irc-color.c
@@ -403,3 +403,17 @@ irc_color_modifier_cb (void *data, const char *modifier,
/* unknown modifier */
return NULL;
}
+
+/*
+ * irc_color_for_tags: return color name for tags (replace "," by ":")
+ * Note: result must be freed after use
+ */
+
+char *
+irc_color_for_tags (const char *color)
+{
+ if (!color)
+ return NULL;
+
+ return weechat_string_replace (color, ",", ":");
+}