6fe08e419d9eaf9c40eac041dc9d8d2ba42f3061
braney
  Wed Nov 16 17:12:00 2016 -0800
fix problem with snake track height when there's an error message or no
items in track.

diff --git src/hg/hgTracks/snakeTrack.c src/hg/hgTracks/snakeTrack.c
index 3d8c00a..c88b765 100644
--- src/hg/hgTracks/snakeTrack.c
+++ src/hg/hgTracks/snakeTrack.c
@@ -666,30 +666,32 @@
 if (vis == tvDense)
     return tg->lineHeight;
 
 if (vis == tvSquish)
     return tg->lineHeight/2;
 
 int height = DUP_LINE_HEIGHT; 
 struct slList *item = tg->items;
 
 item = tg->items;
 
 for (item=tg->items;item; item = item->next)
     {
     height += tg->itemHeight(tg, item);
     }
+if (height < DUP_LINE_HEIGHT + tg->lineHeight)
+    height = DUP_LINE_HEIGHT + tg->lineHeight;
 return height;
 }
 
 static void snakeDraw(struct track *tg, int seqStart, int seqEnd,
         struct hvGfx *hvg, int xOff, int yOff, int width, 
         MgFont *font, Color color, enum trackVisibility vis)
 /* Draw linked features items. */
 {
 struct slList *item;
 int y;
 struct linkedFeatures  *lf;
 double scale = scaleForWindow(width, seqStart, seqEnd);
 int height = snakeHeight(tg, vis);
 
 hvGfxSetClip(hvg, xOff, yOff, width, height);