]> Pileus Git - ~andy/gtk/commitdiff
Fix color name (as of rgb.txt) parsing in symbolic colors
authorCarlos Garnacho <carlosg@gnome.org>
Tue, 21 Dec 2010 17:44:53 +0000 (18:44 +0100)
committerCarlos Garnacho <carlosg@gnome.org>
Fri, 24 Dec 2010 18:37:30 +0000 (19:37 +0100)
The end of the substring wasn't being detected properly.

gtk/gtkcssprovider.c

index c318ec9a14a72c84b635173f13e540713d17a613..c8d7624d59f2163efaf24dc8c9579b62d5d1bdd9 100644 (file)
@@ -2116,8 +2116,9 @@ symbolic_color_parse_str (const gchar  *string,
         }
       else
         {
-          /* color name? parse until first whitespace */
-          while (*end != ' ' && *end != '\0')
+          /* Color name */
+          while (*end != '\0' &&
+                 (g_ascii_isalnum (*end) || *end == ' '))
             end++;
         }