Fossil SCM

Disable the feature that changes the foreground color of the graph based on the background color of the item, as the item background color no longer extends under the graph.

drh 2018-06-07 00:45 trunk
Commit 7ac88481a69ddb5fd5ac21a3a482741719218031c4e4c34bcfaa8875855876b8
1 file changed +4
--- src/timeline.c
+++ src/timeline.c
@@ -747,10 +747,11 @@
747747
@ </table>
748748
if( fchngQueryInit ) db_finalize(&fchngQuery);
749749
timeline_output_graph_javascript(pGraph, tmFlags, iTableId);
750750
}
751751
752
+#if 0 /* not used */
752753
/*
753754
** Change the RGB background color given in the argument in a foreground
754755
** color with the same hue.
755756
*/
756757
static const char *bg_to_fg(const char *zIn){
@@ -777,10 +778,11 @@
777778
if( mx>t ) for(i=0; i<3; i++) x[i] -= mx - t;
778779
}
779780
sqlite3_snprintf(sizeof(zRes),zRes,"#%02x%02x%02x",x[0],x[1],x[2]);
780781
return zRes;
781782
}
783
+#endif /* not used */
782784
783785
/*
784786
** Generate all of the necessary javascript to generate a timeline
785787
** graph.
786788
*/
@@ -878,13 +880,15 @@
878880
cSep = ',';
879881
}
880882
}
881883
if( cSep=='[' ) cgi_printf("[");
882884
cgi_printf("],");
885
+#if 0
883886
if( colorGraph && pRow->zBgClr[0]=='#' ){
884887
cgi_printf("\"fg\":\"%s\",", bg_to_fg(pRow->zBgClr));
885888
}
889
+#endif
886890
/* mi */
887891
cgi_printf("\"mi\":");
888892
cSep = '[';
889893
for(i=0; i<GR_MAX_RAIL; i++){
890894
if( pRow->mergeIn[i] ){
891895
--- src/timeline.c
+++ src/timeline.c
@@ -747,10 +747,11 @@
747 @ </table>
748 if( fchngQueryInit ) db_finalize(&fchngQuery);
749 timeline_output_graph_javascript(pGraph, tmFlags, iTableId);
750 }
751
 
752 /*
753 ** Change the RGB background color given in the argument in a foreground
754 ** color with the same hue.
755 */
756 static const char *bg_to_fg(const char *zIn){
@@ -777,10 +778,11 @@
777 if( mx>t ) for(i=0; i<3; i++) x[i] -= mx - t;
778 }
779 sqlite3_snprintf(sizeof(zRes),zRes,"#%02x%02x%02x",x[0],x[1],x[2]);
780 return zRes;
781 }
 
782
783 /*
784 ** Generate all of the necessary javascript to generate a timeline
785 ** graph.
786 */
@@ -878,13 +880,15 @@
878 cSep = ',';
879 }
880 }
881 if( cSep=='[' ) cgi_printf("[");
882 cgi_printf("],");
 
883 if( colorGraph && pRow->zBgClr[0]=='#' ){
884 cgi_printf("\"fg\":\"%s\",", bg_to_fg(pRow->zBgClr));
885 }
 
886 /* mi */
887 cgi_printf("\"mi\":");
888 cSep = '[';
889 for(i=0; i<GR_MAX_RAIL; i++){
890 if( pRow->mergeIn[i] ){
891
--- src/timeline.c
+++ src/timeline.c
@@ -747,10 +747,11 @@
747 @ </table>
748 if( fchngQueryInit ) db_finalize(&fchngQuery);
749 timeline_output_graph_javascript(pGraph, tmFlags, iTableId);
750 }
751
752 #if 0 /* not used */
753 /*
754 ** Change the RGB background color given in the argument in a foreground
755 ** color with the same hue.
756 */
757 static const char *bg_to_fg(const char *zIn){
@@ -777,10 +778,11 @@
778 if( mx>t ) for(i=0; i<3; i++) x[i] -= mx - t;
779 }
780 sqlite3_snprintf(sizeof(zRes),zRes,"#%02x%02x%02x",x[0],x[1],x[2]);
781 return zRes;
782 }
783 #endif /* not used */
784
785 /*
786 ** Generate all of the necessary javascript to generate a timeline
787 ** graph.
788 */
@@ -878,13 +880,15 @@
880 cSep = ',';
881 }
882 }
883 if( cSep=='[' ) cgi_printf("[");
884 cgi_printf("],");
885 #if 0
886 if( colorGraph && pRow->zBgClr[0]=='#' ){
887 cgi_printf("\"fg\":\"%s\",", bg_to_fg(pRow->zBgClr));
888 }
889 #endif
890 /* mi */
891 cgi_printf("\"mi\":");
892 cSep = '[';
893 for(i=0; i<GR_MAX_RAIL; i++){
894 if( pRow->mergeIn[i] ){
895

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button