cd8ab617cef63bd0c925c1f67e9fafe5c086d583 chmalee Mon Feb 26 11:19:13 2024 -0800 Fix condition for whether we should print codon numbers in mouseover, refs #32815 diff --git src/hg/hgTracks/simpleTracks.c src/hg/hgTracks/simpleTracks.c index 722d19f..7e91985 100644 --- src/hg/hgTracks/simpleTracks.c +++ src/hg/hgTracks/simpleTracks.c @@ -2959,31 +2959,31 @@ { if (startPhase==0) exonNote = " → in-frame exon"; safef(buf, sizeof(buf), ", start codon phase %d%s", startPhase, exonNote); } frameText = buf; } } if (w > 0) // draw exon or intron if width is greater than 0 { // draw mapBoxes for the codons if we are zoomed in far enough struct simpleFeature *codon; struct dyString *codonDy = dyStringNew(0); int codonS, codonE; - if (lf->codons && lf->codons->codonIndex > 0 && zoomedToCdsColorLevel) + if (lf->codons && zoomedToCodonNumberLevel) { for (codon = lf->codons; codon != NULL; codon = codon->next) { codonS = codon->start; codonE = codon->end; if (codonS <= winEnd && codonE >= winStart) { int codonSClp = (codonS < winStart) ? winStart : codonS; int codonEClp = (codonE > winEnd) ? winEnd : codonE; int codonsx = round((codonSClp - winStart)*scale) + insideX; int codonex = round((codonEClp - winStart)*scale) + insideX; // skip regions entirely outside available picture // (accounts for space taken by exon arrows buttons) if (codonsx <= picEnd && codonex >= picStart)