From d570b0fd56da234c5b1498faf3a85f1da998fa38 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Wed, 5 Nov 2003 10:58:16 +0000 Subject: [PATCH] 2003-11-05 Tim Waugh * src/plugins/FilterEditor.py (ShowResults.__init__): Sort results. svn: r2317 --- gramps2/ChangeLog | 5 +++++ gramps2/src/plugins/FilterEditor.py | 8 +++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index 1ac0356b1..7fd458ce6 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -1,3 +1,8 @@ +2003-11-05 Tim Waugh + + * src/plugins/FilterEditor.py (ShowResults.__init__): Sort + results. + 2003-11-03 Tim Waugh * src/plugins/WriteGedcom.py (GedcomWriter.write_families): Use diff --git a/gramps2/src/plugins/FilterEditor.py b/gramps2/src/plugins/FilterEditor.py index 6155261f8..2e65fc15e 100644 --- a/gramps2/src/plugins/FilterEditor.py +++ b/gramps2/src/plugins/FilterEditor.py @@ -28,6 +28,7 @@ __author__ = "Don Allingham" # #------------------------------------------------------------------------- import os +import string #------------------------------------------------------------------------- # @@ -591,11 +592,12 @@ class ShowResults: self.glade.signal_autoconnect({'on_close_clicked' : self.close}) - n = "" + n = [] for p in plist: - n = n + "%s [%s]\n" % (p.getPrimaryName().getName(),p.getId()) + n.append ("%s [%s]\n" % (p.getPrimaryName().getName(),p.getId())) - text.get_buffer().set_text(n) + n.sort () + text.get_buffer().set_text(string.join (n, '')) def close(self,obj): self.top.destroy()