de1be17fa3604710c9e8afaff01c333ef44fd46f
angie
  Wed May 28 10:37:06 2014 -0700
Accidentally removed pgSnp tracks' dense mode left labels in a430d3db1;adding them back now.
refs #13220, fixes #13344

diff --git src/hg/hgTracks/simpleTracks.c src/hg/hgTracks/simpleTracks.c
index 9b9ee4a..724d0aa 100644
--- src/hg/hgTracks/simpleTracks.c
+++ src/hg/hgTracks/simpleTracks.c
@@ -9602,33 +9602,41 @@
 for (i=0; i < el->alleleCount; i++)
     {
     if (sameString(el->alleleFreq, "") || sameString(freq[i], "0"))
         freq[i] = "?";
     dyStringPrintf(ds, "%s:%s ", all[i], freq[i]);
     }
 mapBoxHgcOrHgGene(hvg, start, end, x, y, width, height, tg->track,
                   mapItemName, ds->string, directUrl, withHgsid, NULL);
 freeDyString(&ds);
 }
 
 void pgSnpLeftLabels(struct track *tg, int seqStart, int seqEnd,
 		     struct hvGfx *hvg, int xOff, int yOff, int width, int height,
 		     boolean withCenterLabels, MgFont *font, Color color,
 		     enum trackVisibility vis)
-/* pgSnp draws its own left labels when it draws the item; this is a placeholder so the
- * default full-mode left labels aren't drawn too. */
+/* pgSnp draws its own left labels when it draws the item in pack or full mode.
+ * We don't want the default left labels when in full mode because they can overlap
+ * with the item-drawing labels, but we do still need dense mode left labels. */
 {
+if (tg->visibility == tvDense)
+    {
+    if (isCenterLabelIncluded(tg))
+	yOff += mgFontLineHeight(font);
+    hvGfxTextRight(hvg, leftLabelX, yOff, leftLabelWidth-1, tg->lineHeight,
+		   color, font, tg->shortLabel);
+    }
 }
 
 void pgSnpMethods (struct track *tg)
 /* Personal Genome SNPs: show two alleles with stacked color bars for base alleles and
  * (if available) allele counts in mouseover. */
 {
 bedMethods(tg);
 tg->loadItems = loadPgSnp;
 tg->freeItems = freePgSnp;
 tg->totalHeight = pgSnpHeight;
 tg->itemName = pgSnpName;
 tg->drawItemAt = pgSnpDrawAt;
 tg->mapItem = pgSnpMapItem;
 tg->nextItemButtonable = TRUE;
 tg->nextPrevItem = linkedFeaturesLabelNextPrevItem;