* src/GrampsDbUtils/_GrampsDbWriteXML.py: wrong escape of &, bug 1430
2008-01-03 Benny Malengier <benny.malengier@gramps-project.org> svn: r9702
This commit is contained in:
parent
af1fd6eb0a
commit
71028d3d36
@ -1,3 +1,6 @@
|
||||
2008-01-03 Benny Malengier <benny.malengier@gramps-project.org>
|
||||
* src/GrampsDbUtils/_GrampsDbWriteXML.py: wrong escape of &, bug 1430
|
||||
|
||||
2008-01-03 Benny Malengier <benny.malengier@gramps-project.org>
|
||||
* src/plugins/RelCalc.py: managed window error, bug 1499
|
||||
|
||||
|
@ -767,6 +767,15 @@ class GrampsDbXmlWriter(UpdateCallback):
|
||||
self.g.write('%s<%s>%s</%s>\n' %
|
||||
(' '*indent,tagname,self.fix(value),tagname))
|
||||
|
||||
def write_line_nofix(self,tagname,value,indent=1):
|
||||
'''Writes a line, but does not escape characters.
|
||||
Use this instead of write_line is the value is already fixed,
|
||||
this avoids & becoming &amp;
|
||||
'''
|
||||
if value:
|
||||
self.g.write('%s<%s>%s</%s>\n' %
|
||||
(' '*indent, tagname, value, tagname))
|
||||
|
||||
def get_iso_date(self,date):
|
||||
if date[2] == 0:
|
||||
y = "????"
|
||||
@ -1071,8 +1080,8 @@ class GrampsDbXmlWriter(UpdateCallback):
|
||||
ml_empty = main_loc.is_empty()
|
||||
|
||||
if title == "":
|
||||
title = self.fix(self.build_place_title(place.get_main_location()))
|
||||
self.write_line("ptitle",title,index+1)
|
||||
title = self.build_place_title(place.get_main_location())
|
||||
self.write_line_nofix("ptitle",title,index+1)
|
||||
|
||||
if longitude or lat:
|
||||
self.g.write('%s<coord long="%s" lat="%s"/>\n'
|
||||
|
Loading…
Reference in New Issue
Block a user