From e24e67fc7e77731cbd46e6ed1143d87c7d388451 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Thu, 17 Jul 2003 10:54:41 +0000 Subject: [PATCH] 2003-07-17 Tim Waugh * src/plugins/Ancestors.py: Include other names in the notes. Include birth/marriage/death descriptions. svn: r1897 --- gramps2/ChangeLog | 5 +++-- gramps2/src/plugins/Ancestors.py | 24 ++++++++++++++++++++---- 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index 85a47c01d..43c7d945a 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -1,6 +1,7 @@ 2003-07-17 Tim Waugh - * src/plugins/Ancestors.py: Change report name. Include addresses. - Better generation headings. Include nickname. + * src/plugins/Ancestors.py: Include other names in the notes. + Include birth/marriage/death descriptions. Change report name. + Include addresses. Better generation headings. Include nickname. 2003-07-16 Donald Peterson * doc/gramps-manual/C/figures/bookreport.png: diff --git a/gramps2/src/plugins/Ancestors.py b/gramps2/src/plugins/Ancestors.py index 6dc913755..76c8bfd89 100644 --- a/gramps2/src/plugins/Ancestors.py +++ b/gramps2/src/plugins/Ancestors.py @@ -367,11 +367,13 @@ class ComprehensiveAncestorsReport (Report.Report): def event_info (self, event): info = '' name = event.getName () + description = event.getDescription () if name != 'Birth' and name != 'Death' and name != 'Marriage': info += name - description = event.getDescription () if description: info += ': ' + description + description = None + dateobj = event.getDateObj () if dateobj: text = dateobj.getText () @@ -392,8 +394,15 @@ class ComprehensiveAncestorsReport (Report.Report): if placename: info += ' in ' + placename note = event.getNote () - if note: - info += ' (' + note + ')' + if note or description: + info += ' (' + if description: + info += description + if note: + if description: + info += '; ' + info += note + info += ')' info += self.cite_sources (event.getSourceRefList ()) return info @@ -631,9 +640,10 @@ class ComprehensiveAncestorsReport (Report.Report): else: paras = [] + names = person.getAlternateNames () events = person.getEventList () addresses = person.getAddressList () - if (len (events) + len (addresses)) > 0: + if (len (events) + len (addresses) + len (names)) > 0: paras.append ((self.doc.start_paragraph, ['SubEntry'])) paras.append ((self.doc.write_text, ["More about " + @@ -641,6 +651,12 @@ class ComprehensiveAncestorsReport (Report.Report): ":"])) paras.append ((self.doc.end_paragraph, [])) + for name in names: + paras.append ((self.doc.start_paragraph, ['Details'])) + paras.append ((self.doc.write_text, [name.getType () + ': ' + + name.getRegularName ()])) + paras.append ((self.doc.end_paragraph, [])) + for event in events: paras.append ((self.doc.start_paragraph, ['Details'])) paras.append ((self.doc.write_text, [self.event_info (event)]))