d3875e2d3ebe45f89214d98a2c766a3771e7b057 braney Sun Apr 7 15:05:54 2019 -0700 add manual view limits to lolly diff --git src/hg/lib/hui.c src/hg/lib/hui.c index 5db16af..b539f92 100644 --- src/hg/lib/hui.c +++ src/hg/lib/hui.c @@ -4201,30 +4201,54 @@ char option[256]; int defaultHeight; /* pixels per item */ int settingsDefault; cartTdbFetchMinMaxPixels(cart, tdb, MIN_HEIGHT_PER, atoi(DEFAULT_HEIGHT_PER), atoi(DEFAULT_HEIGHT_PER), &minHeightPixels, &maxHeightPixels, &settingsDefault, &defaultHeight); boxed = cfgBeginBoxAndTitle(tdb, boxed, title); printf("<TABLE BORDER=0>"); printf("<TR valign=center><th align=right>Track height:</th><td align=left colspan=3>"); safef(option, sizeof(option), "%s.%s", name, HEIGHTPER ); cgiMakeIntVarWithLimits(option, defaultHeight, "Track height",0, minHeightPixels, maxHeightPixels); printf("pixels (range: %d to %d)", minHeightPixels, maxHeightPixels); +char *autoScale; +wigFetchAutoScaleWithCart(cart,tdb,name, &autoScale); + +printf("<TR valign=center><th align=right>Data view scaling:</th><td align=left colspan=3>"); +safef(option, sizeof(option), "%s.%s", name, AUTOSCALE ); +wiggleScaleDropDown(option, autoScale); +void wiggleScaleDropDownJavascript(char *name); +wiggleScaleDropDownJavascript(name); +puts("</TD></TR>"); + +double minY; /* from trackDb or cart */ +double maxY; /* from trackDb or cart */ +double tDbMinY; /* data range limits from trackDb type line */ +double tDbMaxY; /* data range limits from trackDb type line */ +char *words[8]; /* to parse the trackDb type line */ +int wordCount = 0; /* to parse the trackDb type line */ +wigFetchMinMaxYWithCart(cart, tdb, name, &minY, &maxY, &tDbMinY, &tDbMaxY, wordCount, words); +printf("<TR class=\"%sAutoScaleDesc\" valign=center><th align=right>Vertical viewing range:</th>" + "<td align=left> min: ", name); +safef(option, sizeof(option), "%s.%s", name, MIN_Y ); +cgiMakeDoubleVarWithLimits(option, minY, "Range min", 0, NO_VALUE, NO_VALUE); +printf("</td><td align=leftv colspan=2>max: "); +safef(option, sizeof(option), "%s.%s", name, MAX_Y ); +cgiMakeDoubleVarWithLimits(option, maxY, "Range max", 0, NO_VALUE, NO_VALUE); /* printf("<TR valign=center><th align=right>Drawing method:</th><td align=left>"); safef(option, sizeof(option), "%s.%s", name, POPMETHOD); char *popMethodVal = cartOrTdbString(cart, tdb, "popMethod", NULL); cgiMakeDropListFull(option, popMethodLabels, popMethodValues, ArraySize(popMethodValues), popMethodVal, NULL, NULL); */ puts("</td></TR>"); printf("</TABLE>"); cfgEndBox(boxed); }