From 597b4af2bc0367cb51d201e5f5df7f5bc92d062e Mon Sep 17 00:00:00 2001 From: Alex Roitman Date: Fri, 13 Jun 2003 03:29:15 +0000 Subject: [PATCH] * src/docgen/KwordDoc.py (write_text): Replace & with & in text. Closes gramps-bugs-649228, finally. (start_table): close FRAMESET tag conditionally. This prevents closing it twice (both in end_cell and start_table). Closes 753151. svn: r1715 --- ChangeLog | 6 ++++++ src/docgen/KwordDoc.py | 7 +++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index d867be84c..38c562729 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2003-06-12 Alex Roitman + * src/docgen/KwordDoc.py (write_text): Replace & with & in text. + Closes gramps-bugs-649228, finally. + (start_table): close FRAMESET tag conditionally. This prevents closing + it twice (both in end_cell and start_table). Closes 753151. + 2003-06-12 Tim Waugh * src/docgen/OpenOfficeDoc.py: Fix typo. Prevent images from being copied more than once. diff --git a/src/docgen/KwordDoc.py b/src/docgen/KwordDoc.py index c99b5f9ef..9a4370041 100644 --- a/src/docgen/KwordDoc.py +++ b/src/docgen/KwordDoc.py @@ -1,7 +1,7 @@ # # Gramps - a GTK+/GNOME based genealogy program # -# Copyright (C) 2000 Donald N. Allingham +# Copyright (C) 2000-2003 Donald N. Allingham # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -23,6 +23,7 @@ from latin_utf8 import latin_to_utf8 import time import StringIO +import string import gzip import Errors @@ -363,7 +364,8 @@ class KwordDoc(TextDoc.TextDoc): self.tbl= self.table_styles[style_name] self.cell_left= (self.lmargin * 72)/ 2.54 self.tbl_width= ((self.width - self.lmargin - self.rmargin) * 72 ) / 2.54 - self.f.write(' \n') + if self.frameset_flg == 1: + self.f.write(' \n') self.cell_row= 0 self.cell_col= 0 self.frameset_flg= 0 @@ -435,6 +437,7 @@ class KwordDoc(TextDoc.TextDoc): pass def write_text(self,text): + text = string.replace(text,'&','&'); # Must be first self.text = self.text + text Plugins.register_text_doc(_("KWord"),KwordDoc,1,1,1,".kwd")