From 612705a717b49a536220da70f772968b6330d0bd Mon Sep 17 00:00:00 2001 From: Alex Roitman Date: Mon, 15 Dec 2003 04:18:51 +0000 Subject: [PATCH] * src/docgen/Makefile.am: Remove AbiWordDoc.py from the list. * src/plugins/DetAncestralReport.py (write_person): Call write_note(). * src/plugins/DetDescendantReport.py (write_person): Call write_note(). * src/plugins/FtmStyleAncestors.py (print_notes): Call write_note(). * src/plugins/IndivComplete.py (write_note): Call doc.write_note(). * src/plugins/WebPage.py (write_gallery,write_notes): Call write_note(). svn: r2523 --- gramps2/ChangeLog | 6 ++++++ gramps2/src/docgen/Makefile.am | 1 - gramps2/src/plugins/DetAncestralReport.py | 6 +++--- gramps2/src/plugins/DetDescendantReport.py | 6 +++--- gramps2/src/plugins/FtmStyleAncestors.py | 6 ++---- gramps2/src/plugins/IndivComplete.py | 8 ++++---- gramps2/src/plugins/WebPage.py | 12 +++--------- 7 files changed, 21 insertions(+), 24 deletions(-) diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index ae0bfdb82..f5365e600 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -2,6 +2,12 @@ * src/dialog.glade: Add format controls for notes. * src/marriage.glade: Add format controls for notes. * src/gramps.glade: Add format controls for notes. + * src/docgen/Makefile.am: Remove AbiWordDoc.py from the list. + * src/plugins/DetAncestralReport.py (write_person): Call write_note(). + * src/plugins/DetDescendantReport.py (write_person): Call write_note(). + * src/plugins/FtmStyleAncestors.py (print_notes): Call write_note(). + * src/plugins/IndivComplete.py (write_note): Call doc.write_note(). + * src/plugins/WebPage.py (write_gallery,write_notes): Call write_note(). 2003-12-13 Alex Roitman * src/docgen/KwordDoc.py (write_note): Implement function. diff --git a/gramps2/src/docgen/Makefile.am b/gramps2/src/docgen/Makefile.am index 181218271..262efa714 100644 --- a/gramps2/src/docgen/Makefile.am +++ b/gramps2/src/docgen/Makefile.am @@ -4,7 +4,6 @@ pkgpython_PYTHON = \ AbiWord2Doc.py\ - AbiWordDoc.py\ HtmlDoc.py\ KwordDoc.py\ LaTeXDoc.py\ diff --git a/gramps2/src/plugins/DetAncestralReport.py b/gramps2/src/plugins/DetAncestralReport.py index 5bdaf892c..3e74e680a 100644 --- a/gramps2/src/plugins/DetAncestralReport.py +++ b/gramps2/src/plugins/DetAncestralReport.py @@ -18,6 +18,8 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # +# $Id$ + "Generate files/Detailed Ancestral Report" import RelLib @@ -245,9 +247,7 @@ class DetAncestorReport(Report.Report): self.doc.write_text(_("Notes for %s" % name)) self.doc.end_bold() self.doc.end_paragraph() - self.doc.start_paragraph("DAR-Entry") - self.doc.write_text(person.getNote()) - self.doc.end_paragraph() + self.doc.write_note(person.getNote(),person.getNoteFormat(),"DAR-Entry") return 0 # Not duplicate person diff --git a/gramps2/src/plugins/DetDescendantReport.py b/gramps2/src/plugins/DetDescendantReport.py index 4b764e620..65efc9301 100644 --- a/gramps2/src/plugins/DetDescendantReport.py +++ b/gramps2/src/plugins/DetDescendantReport.py @@ -18,6 +18,8 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # +# $Id$ + "Generate files/Detailed Descendant Report" import RelLib @@ -252,9 +254,7 @@ class DetDescendantReport(Report.Report): self.doc.write_text(_("Notes for %s" % name)) self.doc.end_bold() self.doc.end_paragraph() - self.doc.start_paragraph("DDR-Entry") - self.doc.write_text(person.getNote()) - self.doc.end_paragraph() + self.doc.write_note(person.getNote(),person.getNoteFormat(),"DDR-Entry") return 0 # Not duplicate person diff --git a/gramps2/src/plugins/FtmStyleAncestors.py b/gramps2/src/plugins/FtmStyleAncestors.py index d8efafc40..25e0ec6b8 100644 --- a/gramps2/src/plugins/FtmStyleAncestors.py +++ b/gramps2/src/plugins/FtmStyleAncestors.py @@ -480,10 +480,8 @@ class FtmAncestorReport(Report.Report): self.doc.write_text(_('Notes for %(person)s:') % { 'person' : person.getPrimaryName().getRegularName()} ) self.doc.end_paragraph() - for line in note.split('\n'): - self.doc.start_paragraph('FTA-Details') - self.doc.write_text(line.strip()) - self.doc.end_paragraph() + format = person.getNoteFormat() + self.doc.write_note(note,format,'FTA-Details') def print_more_about(self,person): diff --git a/gramps2/src/plugins/IndivComplete.py b/gramps2/src/plugins/IndivComplete.py index 1314397a3..041aa55f1 100644 --- a/gramps2/src/plugins/IndivComplete.py +++ b/gramps2/src/plugins/IndivComplete.py @@ -18,6 +18,8 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # +# $Id$ + #------------------------------------------------------------------------ # # standard python modules @@ -170,10 +172,8 @@ class IndivComplete(Report.Report): self.d.start_row() self.d.start_cell('IDS-NormalCell',2) - for line in string.split(note,'\n'): - self.d.start_paragraph('IDS-Normal') - self.d.write_text(line) - self.d.end_paragraph() + format = person.getNoteFormat() + self.doc.write_note(note,format,'IDS-Normal') self.d.end_cell() self.d.end_row() diff --git a/gramps2/src/plugins/WebPage.py b/gramps2/src/plugins/WebPage.py index 54a7e1e2e..511de0904 100644 --- a/gramps2/src/plugins/WebPage.py +++ b/gramps2/src/plugins/WebPage.py @@ -443,13 +443,9 @@ class IndividualPage: self.doc.write_text(description) self.doc.end_paragraph() if obj.getNote() != "": - self.doc.start_paragraph("PhotoNote") - self.doc.write_text(obj.getNote()) - self.doc.end_paragraph() + self.doc.write_note(obj.getNote(),obj.getNoteFormat(),"PhotoNote") elif obj.getReference().getNote() != "": - self.doc.start_paragraph("PhotoNote") - self.doc.write_text(obj.getReference().getNote()) - self.doc.end_paragraph() + self.doc.write_note(obj.getReference().getNote(),obj.getReference().getNoteFormat(),"PhotoNote") self.doc.end_cell() self.doc.end_row() except IOError: @@ -521,9 +517,7 @@ class IndividualPage: self.doc.write_text(_("Notes")) self.doc.end_paragraph() - self.doc.start_paragraph("NotesParagraph") - self.doc.write_text(self.person.getNote()) - self.doc.end_paragraph() + self.doc.write_note(self.person.getNote(),self.person.getNoteFormat(),"NotesParagraph") def write_fam_fact(self,event):