diff --git a/gramps/gen/plug/report/_book.py b/gramps/gen/plug/report/_book.py index 4af478680..1497f945a 100644 --- a/gramps/gen/plug/report/_book.py +++ b/gramps/gen/plug/report/_book.py @@ -457,79 +457,98 @@ class BookList(object): """ Saves the current BookList to the associated file. """ - f = open(self.file, "w") - f.write("\n") - f.write('\n') - for name in sorted(self.bookmap): # enable a diff of archived copies - book = self.get_book(name) - dbname = book.get_dbname() - f.write('\n' % (name, dbname) ) - for item in book.get_item_list(): - f.write(' \n' % - (item.get_name(),item.get_translated_name() ) ) - options = item.option_class.handler.options_dict - for option_name in sorted(options.keys()): # enable a diff - option_value = options[option_name] - if isinstance(option_value, (list, tuple)): - f.write(' \n') - else: - option_type = type_name(option_value) - value = escape(str(option_value)) - value = value.replace('"', '"') - f.write('