d191a06ac8b6ff4318ca67c8e3947a0e9694e81f max Fri Jun 21 05:07:05 2024 -0700 removing the dink left right buttons under image, but adding a configuration option to get them back, refs #26325 diff --git src/hg/hgTracks/hgTracks.c src/hg/hgTracks/hgTracks.c index a4b65f3..8f45298 100644 --- src/hg/hgTracks/hgTracks.c +++ src/hg/hgTracks/hgTracks.c @@ -9363,66 +9363,55 @@ { // bail out b/c we are done if (measureTiming) { printTrackTiming(); } return; } if (!hideControls) { struct controlGrid *cg = NULL; /* note a trick of WIDTH=27 going on here. The 6,15,6 widths following * go along with this trick */ + if (cartUsualBoolean(cart, "showDinkButtons", FALSE)) + { hPrintf("<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=1 WIDTH=%d COLS=%d><TR>\n", tl.picWidth, 27); -#ifndef USE_NAVIGATION_LINKS + hPrintf("<TD COLSPAN=6 ALIGN=left NOWRAP>"); hPrintf("<span class='moveButtonText'>Move start</span><br>"); hButtonWithOnClick("hgt.dinkLL", " < ", "Move start position to the left", "return imageV2.navigateButtonClick(this);"); hTextVar("dinkL", cartUsualString(cart, "dinkL", "2.0"), 3); hButtonWithOnClick("hgt.dinkLR", " > ", "Move start position to the right", "return imageV2.navigateButtonClick(this);"); hPrintf("</TD>"); hPrintf("<td width='30'> </td>\n"); -#endif//ndef USE_NAVIGATION_LINKS - hPrintf("<TD class='infoText' COLSPAN=15 style=\"white-space:normal\">"); // allow this text to wrap - hWrites("Click on a feature for details. "); - hWrites("Shift+click+drag to zoom in. "); - hWrites("Click grey side bars for track options. "); - hWrites("Drag side bars or labels up or down to reorder tracks. "); - hWrites("Drag tracks left or right to new position. "); - hWrites("Press \"?\" for keyboard shortcuts. "); - hWrites("Use drop-down controls below and press refresh to alter tracks displayed. "); - hPrintf("</TD>"); -#ifndef USE_NAVIGATION_LINKS - hPrintf("<td width='30'> </td>\n"); hPrintf("<TD COLSPAN=6 ALIGN=right NOWRAP>"); hPrintf("<span class='moveButtonText'>Move end</span><br>"); hButtonWithOnClick("hgt.dinkRL", " < ", "Move end position to the left", "return imageV2.navigateButtonClick(this);"); hTextVar("dinkR", cartUsualString(cart, "dinkR", "2.0"), 3); hButtonWithOnClick("hgt.dinkRR", " > ", "Move end position to the right", "return imageV2.navigateButtonClick(this);"); hPrintf("</TD>"); -#endif//ndef USE_NAVIGATION_LINKS hPrintf("</TR></TABLE>\n"); - + } if( chromosomeColorsMade ) { hPrintf("<B>Chromosome Color Key:</B><BR> "); hPrintf("<IMG SRC = \"../images/new_colorchrom.gif\" BORDER=1 WIDTH=596 HEIGHT=18 ><BR>\n"); } if (doPliColors) { hPrintf("<B>gnomAD Loss-of-Function Constraint (LOEUF) Color Key:</B><BR> "); hPrintf("<table style=\"border: 1px solid black\"><tr>\n"); hPrintf("<td style=\"background-color:rgb(244,0,2)\">< 0.1</td>\n"); hPrintf("<td style=\"background-color:rgb(240,74,3)\">< 0.2</td>\n"); hPrintf("<td style=\"background-color:rgb(233,127,5)\">< 0.3</td>\n"); hPrintf("<td style=\"background-color:rgb(224,165,8)\">< 0.4</td>\n"); hPrintf("<td style=\"background-color:rgb(210,191,13)\">< 0.5</td>\n"); @@ -9445,30 +9434,34 @@ hButtonWithOnClick("hgt.collapseGroups", "Collapse all", "Collapse all track groups", "return vis.expandAllGroups(false)"); hPrintf("</td>"); hPrintf("<td colspan='%d' class='controlButtons' align='CENTER' nowrap>\n", MAX_CONTROL_COLUMNS - 2); printShortcutButtons(cart, hasCustomTracks, revCmplDisp, multiRegionButtonTop); hPrintf("</td>\n"); hPrintf("<td align='right'>"); hButtonWithOnClick("hgt.expandGroups", "Expand all", "Expand all track groups", "return vis.expandAllGroups(true)"); hPrintf("</td></tr>"); + // since this is all a huge table (which it shouldn't be), the only way to add whitespace between two rows is to add an empty row + // since padding and margin are not allowed on table rows. (One day, we will remove this table) + hPrintf("<tr style='height:4px'><td></td></tr>\n"); + cg = startControlGrid(MAX_CONTROL_COLUMNS, "left"); struct hash *superHash = hashNew(8); for (group = groupList; group != NULL; group = group->next) { if ((group->trackList == NULL) && (group->errMessage == NULL)) continue; struct trackRef *tr; /* check if group section should be displayed */ char *otherState; char *indicator; char *indicatorImg; boolean isOpen = !isCollapsedGroup(group); collapseGroupGoodies(isOpen, TRUE, &indicatorImg,