--- main_old.c 2008-03-15 23:38:18.000000000 +0100 +++ main.c 2009-09-08 15:05:46.383934639 +0200 @@ -5,6 +5,8 @@ * * Copyright (c) 2006 Julien Devemy * + * Copyright (c) 2009 Jaromir Capik + * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either @@ -187,6 +189,23 @@ gtk_widget_hide (poMonitor->wImage); } + /* Test if the result is a Text Color */ + begin=strstr(p_poPlugin->acValue, ""); + end=strstr(p_poPlugin->acValue, ""); + if ((begin != NULL) && (end != NULL) && (begin < end) && (end-begin < 256*sizeof(char))) + { + char buf[256]; + GdkColor txtcolor; + + /* Get the color */ + strncpy(buf, begin+10*sizeof(char), end-begin-10*sizeof(char)); + buf[end-begin-10*sizeof(char)]='\0'; + gdk_color_parse (buf, &txtcolor); + gtk_widget_modify_fg (poMonitor->wValue, GTK_STATE_NORMAL, &txtcolor); + + newVersion=1; + } + /* Test if the result is a Text */ begin=strstr(p_poPlugin->acValue, ""); end=strstr(p_poPlugin->acValue, "");