1a436460e21282899ff825bab22f137123564e68
braney
  Wed Jul 9 18:08:06 2025 -0700
a fix for quickLift mismatches on the negative strand

diff --git src/hg/hgTracks/quickLift.c src/hg/hgTracks/quickLift.c
index 29bfc2d2765..b36e4f6dbfe 100644
--- src/hg/hgTracks/quickLift.c
+++ src/hg/hgTracks/quickLift.c
@@ -148,32 +148,40 @@
         int qMin, qMax;
         tMin = bl->chromStart;
         tMax = bl->chromEnd;
         qMin = bl->qStart;
         if (seqStart > bl->chromStart) 
             {
             tMin = seqStart;
             qMin = qStart + (seqStart - bl->chromStart);
             }
         if (seqEnd < bl->chromEnd) 
             {
             tMax = seqEnd;
             }
         qMax = qMin + (tMax - tMin);
 
+        if (bc->strand[0] == '-')
+            {
+            qMin = bc->qSize - qMax;
+            qMax = qMin + (tMax - tMin);
+            }
+
         struct dnaSeq *tSeq = hDnaFromSeq(database, chromName, tMin, tMax, dnaUpper);
         struct dnaSeq *qSeq = hDnaFromSeq(liftDb, bc->qName, qMin, qMax, dnaUpper);
+        if (bc->strand[0] == '-')
+            reverseComplement(qSeq->dna, qSeq->size);
 
         unsigned tAddr = tMin;
         unsigned qAddr = qMin;
         int count = 0;
         for(; tAddr < tEnd; tAddr++, qAddr++, count++)
             {
             if (tSeq->dna[count] != qSeq->dna[count])
                 {
                 AllocVar(hr);
                 slAddHead(&hrList, hr);
                 hr->chromStart = tAddr;
                 hr->chromEnd = tAddr + 1;
                 hr->oChromStart = qAddr;
                 hr->oChromEnd = qAddr + 1;
                 hr->otherBase = qSeq->dna[count];