From e57f18a698295efdc6e43dd4a2e83750d3661258 Mon Sep 17 00:00:00 2001 From: Benny Malengier Date: Mon, 26 Jan 2009 08:53:29 +0000 Subject: [PATCH] 2586: Add spouses to the Descendant Tree report Avoid crash on no spouse, patch by Craig svn: r11732 --- src/plugins/drawreport/DescendTree.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/plugins/drawreport/DescendTree.py b/src/plugins/drawreport/DescendTree.py index a13f069ae..a29039d24 100644 --- a/src/plugins/drawreport/DescendTree.py +++ b/src/plugins/drawreport/DescendTree.py @@ -173,8 +173,15 @@ class DescendTree(Report): also sets wether the person is: - a direct descendent or a spouse - the max length of the text/box, and number of lines""" - self.genchart.set_xy(col_x, row_y, person_handle) self.genchart.set_sp(col_x, row_y, spouse_level) + if person_handle is not None: + self.genchart.set_xy(col_x, row_y, person_handle) + else: + #make sure that a box prints + self.genchart.set_xy(col_x, row_y, ".") + #make a blank box. + self.text[(col_x, row_y)] = [""] + return style_sheet = self.doc.get_style_sheet() pstyle = style_sheet.get_paragraph_style("DC2-Normal")