From a23408c7a5ae607209c9ee527a33dc5a34e8e032 Mon Sep 17 00:00:00 2001 From: Benny Malengier Date: Tue, 25 Jun 2013 22:07:43 +0000 Subject: [PATCH] In case of errors with fg_color, enormous amount of error messages. This patch grabs wrong fg_color, and skips action, avoiding the error messages. Error goes to debug. svn: r22608 --- gramps/gui/views/listview.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gramps/gui/views/listview.py b/gramps/gui/views/listview.py index ecbc2e0b3..494e3c568 100644 --- a/gramps/gui/views/listview.py +++ b/gramps/gui/views/listview.py @@ -285,7 +285,11 @@ class ListView(NavigationView): function because we don't want to set the color of untagged rows. ''' fg_color = model.get_value(iter_, model.color_column()) - renderer.set_property('foreground', fg_color) + #for color errors, typically color column is badly set + if fg_color: + renderer.set_property('foreground', fg_color) + else: + _LOG.debug('Bad color set: ' + str(fg_color)) def set_active(self): NavigationView.set_active(self)