0846fb5a0028fcdcd90beeec64bc00adafcb9f61 braney Mon Dec 30 14:38:22 2019 -0800 allow specifying colors for lollipops, turn off color in TCGA cancer track, make pack mode draw lollies instead of bed modes #24705 diff --git src/lib/basicBed.c src/lib/basicBed.c index 7a76310..305779f 100644 --- src/lib/basicBed.c +++ src/lib/basicBed.c @@ -328,31 +328,32 @@ struct bed *bedLoad6(char **row) /* Load first six fields of bed. */ { struct bed *ret = bedLoad5(row); safef(ret->strand, sizeof(ret->strand), "%s", row[5]); return ret; } /* it turns out that it isn't just hgLoadBed and custom tracks * that may encounter the r,g,b specification. Any program that * reads bed files may enconter them, so take care of them * at any time. The strchr() function is very fast which will * be a failure in the vast majority of cases parsing integers, * therefore, this shouldn't be too severe a performance hit. */ -static int itemRgbColumn(char *column9) +int itemRgbColumn(char *column9) +/* Convert color specification to internal format. */ { int itemRgb = 0; /* Allow comma separated list of rgb values here */ char *comma = strchr(column9, ','); if (comma) { if (-1 == (itemRgb = bedParseRgb(column9))) errAbort("ERROR: expecting r,g,b specification, " "found: '%s'", column9); } else itemRgb = sqlUnsigned(column9); return itemRgb; }