30 lines
1.3 KiB
Diff
30 lines
1.3 KiB
Diff
--- graphviz-2.12/lib/common/colxlate.c.orig 2006-07-26 22:44:05.000000000 -0500
|
|
+++ graphviz-2.12/lib/common/colxlate.c 2007-07-12 14:07:13.000000000 -0500
|
|
@@ -1,4 +1,4 @@
|
|
-/* $Id: colxlate.c,v 1.11 2006/07/27 03:44:05 erg Exp $ $Revision: 1.11 $ */
|
|
+/* $Id: colxlate.c,v 1.13 2007/07/12 16:47:57 erg Exp $ $Revision: 1.13 $ */
|
|
/* vim:set shiftwidth=4 ts=8: */
|
|
|
|
/**********************************************************
|
|
@@ -180,6 +180,10 @@
|
|
|
|
/* resolveColor:
|
|
* Resolve input color str allowing color scheme namespaces.
|
|
+ * 0) "black" => "black"
|
|
+ * NB: This is something of a hack due to the remaining codegen.
|
|
+ * Once these are gone, this case could be removed and all references
|
|
+ * to "black" could be replaced by "/X11/black".
|
|
* 1) No initial / =>
|
|
* if colorscheme is defined and no "X11", return /colorscheme/str
|
|
* else return str
|
|
@@ -214,7 +218,8 @@
|
|
char* ss; /* second slash */
|
|
char* c2; /* second char */
|
|
|
|
- if (*str == '/') { /* if begins with '/' */
|
|
+ if ((*str == 'b') || !strncmp(str+1,"lack",4)) return str;
|
|
+ else if (*str == '/') { /* if begins with '/' */
|
|
c2 = str+1;
|
|
if ((ss = strchr(c2, '/'))) { /* if has second '/' */
|
|
if (*c2 == '/') { /* if second '/' is second character */
|