[gnumeric] GnmItemBar: add debug code.



commit 148a7b0372dc2e939b71b5cb6a51dc6b500d2983
Author: Morten Welinder <terra gnome org>
Date:   Thu Apr 10 20:37:46 2014 -0400

    GnmItemBar: add debug code.

 ChangeLog      |    4 ++++
 src/item-bar.c |   11 +++++++++++
 2 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index d309e49..bace495 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2014-04-10  Morten Welinder  <terra gnome org>
+
+       * src/item-bar.c (ib_reload_style): Add debug code.
+
 2014-04-09  Morten Welinder  <terra gnome org>
 
        * src/number-match.c (format_match_datetime): Plug leak on certain
diff --git a/src/item-bar.c b/src/item-bar.c
index 79f786c..8e549ce 100644
--- a/src/item-bar.c
+++ b/src/item-bar.c
@@ -23,6 +23,7 @@
 #include "gui-util.h"
 #include "parse-util.h"
 #include "commands.h"
+#include "gutils.h"
 
 #include <goffice/goffice.h>
 #include <gsf/gsf-impl-utils.h>
@@ -163,6 +164,16 @@ ib_reload_style (GnmItemBar *ib)
                                          &ib->selection_logical_sizes[ui]);
        }
 
+       if (sheet->index_in_wb == 0 && gnm_debug_flag ("item-bar-style")) {
+               if (ib->selection_colors[0].red == 1 &&
+                   ib->selection_colors[0].green == 1 &&
+                   ib->selection_colors[0].blue == 1) {
+                       g_printerr ("White item bar text\n");
+               } else {
+                       g_printerr ("Non-white item bar text\n");
+               }
+       }
+
        gtk_style_context_get_padding (context, GTK_STATE_FLAG_NORMAL,
                                       &ib->padding);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]