[Xfce4-commits] [apps/xfce4-taskmanager] 04/05: Make CPU and Mem labels use the graph colors
noreply at xfce.org
noreply at xfce.org
Thu Dec 18 22:12:23 CET 2014
This is an automated email from the git hooks/post-receive script.
landry pushed a commit to branch master
in repository apps/xfce4-taskmanager.
commit e97b77ee62c2ac9f0570ab0669d86bda1a65f94a
Author: Simon Steinbeiss <simon.steinbeiss at elfenbeinturm.at>
Date: Thu Dec 18 11:05:16 2014 +0100
Make CPU and Mem labels use the graph colors
---
src/process-statusbar.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/process-statusbar.c b/src/process-statusbar.c
index 0044796..0299d26 100644
--- a/src/process-statusbar.c
+++ b/src/process-statusbar.c
@@ -133,6 +133,7 @@ xtm_process_statusbar_set_property (GObject *object, guint property_id, const GV
XtmProcessStatusbar *statusbar = XTM_PROCESS_STATUSBAR (object);
gchar *text;
gchar *float_value;
+ GdkColor color;
switch (property_id)
{
@@ -141,6 +142,8 @@ xtm_process_statusbar_set_property (GObject *object, guint property_id, const GV
float_value = rounded_float_value (statusbar->cpu, statusbar->settings);
text = g_strdup_printf (_("CPU: %s%%"), float_value);
gtk_label_set_text (GTK_LABEL (statusbar->label_cpu), text);
+ gdk_color_parse ("#ff6e00", &color);
+ gtk_widget_modify_fg (statusbar->label_cpu, GTK_STATE_NORMAL, &color);
g_free (float_value);
g_free (text);
break;
@@ -149,6 +152,8 @@ xtm_process_statusbar_set_property (GObject *object, guint property_id, const GV
g_strlcpy(statusbar->memory, g_value_get_string (value), 64);
text = g_strdup_printf (_("Memory: %s"), statusbar->memory);
gtk_label_set_text (GTK_LABEL (statusbar->label_memory), text);
+ gdk_color_parse ("#ab1852", &color);
+ gtk_widget_modify_fg (statusbar->label_memory, GTK_STATE_NORMAL, &color);
g_free (text);
break;
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list