summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/fe-common/core/hilight-text.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/fe-common/core/hilight-text.c b/src/fe-common/core/hilight-text.c
index 5c80bd4b..52fcb056 100644
--- a/src/fe-common/core/hilight-text.c
+++ b/src/fe-common/core/hilight-text.c
@@ -313,7 +313,10 @@ char *hilight_get_color(HILIGHT_REC *rec, int activity)
color = number;
}
- return g_strconcat(isdigit(*color) ? "\003" : "", color, NULL);
+ if (is_numeric(color, 0))
+ return g_strdup_printf("\003%02d", atoi(color));
+
+ return g_strdup(color);
}
static void hilight_update_text_dest(TEXT_DEST_REC *dest, HILIGHT_REC *rec)