7944bbaa4529de04a6b2081196a166b3a5f6eee4
kate
  Mon Oct 21 10:51:27 2019 -0700
Add new setting to customize label on UI page when using hideEMptySubtracks. refs #23365

diff --git src/hg/lib/hui.c src/hg/lib/hui.c
index f053484..19b1548 100644
--- src/hg/lib/hui.c
+++ src/hg/lib/hui.c
@@ -5113,31 +5113,33 @@
     {
     // ignore displaySubtracks setting for large composites with a matrix as
     // matrix effectively shows all
     safef(buffer, SMALLBUF,"%s.displaySubtracks", parentTdb->track);
     displaySubs = cartUsualString(cart, buffer,"some"); // track specific defaults to only selected
     }
 else
     {
     displaySubs = cartUsualString(cart, "displaySubtracks", "all"); // browser wide defaults to all
     }
 boolean displayAll = sameString(displaySubs, "all");
 
 boolean hideSubtracksDefault;
 if (compositeHideEmptySubtracksSetting(parentTdb, &hideSubtracksDefault, NULL, NULL))
     {
-    printf("<BR><B>Hide empty subtracks:</B> &nbsp;");
+    char *hideLabel = "Hide empty subtracks";
+    hideLabel = trackDbSettingOrDefault(parentTdb, SUBTRACK_HIDE_EMPTY_LABEL, hideLabel);
+    printf("<BR><B>%s:</B> &nbsp;", hideLabel);
     char buf[128];
     safef(buf, sizeof buf, "%s.%s", parentTdb->track, SUBTRACK_HIDE_EMPTY);
     boolean doHideEmpties = compositeHideEmptySubtracks(cart, parentTdb, NULL, NULL);
     cgiMakeCheckBox(buf, doHideEmpties);
     }
 
 // Table wraps around entire list so that "Top" link can float to the correct place.
 cgiDown(0.7);
 printf("<table><tr><td class='windowSize'>");
 printf("<A NAME='DISPLAY_SUBTRACKS'></A>");
 if (sortOrder != NULL)
     {
     // First table row contains the display "selected/visible" or "all" radio buttons
     // NOTE: list subtrack radio buttons are inside tracklist table header if
     //       there are no sort columns.  The reason is to ensure spacing of lines