94456e195ad86e3da7331bc8f014eceaa35a8ecc braney Fri Oct 18 16:10:47 2024 -0700 fix wigColorBy to work with linkedFeatures and on hubs diff --git src/hg/hgTracks/wigTrack.c src/hg/hgTracks/wigTrack.c index 480bb25..e52cb13 100644 --- src/hg/hgTracks/wigTrack.c +++ src/hg/hgTracks/wigTrack.c @@ -68,31 +68,31 @@ int x1 = 0, x2 = 0; int i = 0; for(lf = lfList; lf != NULL; lf = lf->next) { for (sf = lf->components; sf != NULL; sf = sf->next) { x1 = round((double)((int)sf->start-winStart)*scale); x2 = round((double)((int)sf->end-winStart)*scale); if(x1 < 0) x1 = 0; if(x2 > colSize) x2 = colSize; if(x1 == x2) x2++; for(i = x1; i < x2; i++) - colArray[i] = colorTrack->ixAltColor; + colArray[i] = bedColorToGfxColor(lf->filterColor); } } } static void wigFillInColorBedArray(struct track *wigTrack, Color *colArray, int colSize, struct track *colorTrack, struct hvGfx *hvg) /* Fill in a color array with the simple bed based colorTrack's color where it would normally have an block. */ { struct bed *bed = NULL, *bedList = colorTrack->items; double scale = scaleForPixels(colSize); int x1 = 0, x2 = 0; int i = 0; for (bed = bedList; bed != NULL; bed = bed->next) {