ee8b9b26531c6606398b89ef86aa72469ab92bd5 max Tue Oct 28 09:29:27 2025 -0700 adding new info icon to group and making the hide group button do a refresh, refs #36610 diff --git src/hg/lib/hui.c src/hg/lib/hui.c index 4829a3a7796..013e6b2f524 100644 --- src/hg/lib/hui.c +++ src/hg/lib/hui.c @@ -9478,46 +9478,59 @@ boolean newVal = FALSE; safef(option, sizeof(option),"%s_sel", subtrack->track); newVal = sameString(button, ADD_BUTTON_LABEL); cartSetBoolean(cart, option, newVal); } } } } puts("</TABLE>"); } return TRUE; } static bool mouseOverJsDone = FALSE; -void printInfoIconSvg() -/* Print just info icon (i) as svg tag to stdout */ +void printInfoIconSvg(char *color) +/* Print just info icon (i) as svg tag to stdout, default color is #1C274C */ { puts("<svg style='height:1.1em; vertical-align:top' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'>"); -puts("<circle cx='12' cy='12' r='10' stroke='#1C274C' stroke-width='1.5'/>"); -puts("<path d='M12 17V11' stroke='#1C274C' stroke-width='1.5' stroke-linecap='round'/>"); -puts("<circle cx='1' cy='1' r='1' transform='matrix(1 0 0 -1 11 9)' fill='#1C274C'/>"); +printf("<circle cx='12' cy='12' r='10' stroke='%s' stroke-width='1.5'/>", color); +printf("<path d='M12 17V11' stroke='%s' stroke-width='1.5' stroke-linecap='round'/>", color); +printf("<circle cx='1' cy='1' r='1' transform='matrix(1 0 0 -1 11 9)' fill='%s'/>", color); puts("</svg>"); } +void printInfoIconColor(char *mouseover, char *color) +/* Print info icon (i) with explanatory text on mouseover, with color */ +{ +printf("<span title=\"%s\">", mouseover); +printInfoIconSvg(color); +puts("</span>"); +if (!mouseOverJsDone) + { + jsInline("convertTitleTagsToMouseovers();\n"); + mouseOverJsDone = TRUE; + } +} + void printInfoIcon(char *mouseover) /* Print info icon (i) with explanatory text on mouseover */ { // see https://www.svgrepo.com/svg/524660/info-circle printf("<span title=\"%s\">", mouseover); -printInfoIconSvg(); +printInfoIconSvg("#1C274C"); puts("</span>"); if (!mouseOverJsDone) { jsInline("convertTitleTagsToMouseovers();\n"); mouseOverJsDone = TRUE; } } void hCompositeUi(char *db, struct cart *cart, struct trackDb *tdb, char *primarySubtrack, char *fakeSubmit, char *formName) // UI for composite tracks: subtrack selection. If primarySubtrack is // non-NULL, don't allow it to be cleared and only offer subtracks // that have the same type. If fakeSubmit is non-NULL, add a hidden // var with that name so it looks like it was pressed. {