* src/plugins/WriteGedcom.py: support different end of line characters

* src/GedcomInfo.py: support different end of line characters
* src/data/gedcom.xml: indicate cr-lf for Windows based tools


svn: r1798
This commit is contained in:
Don Allingham
2003-06-28 17:35:00 +00:00
parent 315e2ccf40
commit f3d2163bd9
3 changed files with 147 additions and 124 deletions

View File

@@ -66,6 +66,7 @@ class GedcomDescription:
self.gramps2tag_map = {}
self.tag2gramps_map = {}
self.prefix = PREFIX_YES
self.endl = "\n"
def set_dest(self,val):
self.dest = val
@@ -73,6 +74,12 @@ class GedcomDescription:
def get_dest(self):
return self.dest
def set_endl(self,val):
self.endl = val.replace('\\r','\r').replace('\\n','\n')
def get_endl(self):
return self.endl
def set_adopt(self,val):
self.adopt = val
@@ -194,6 +201,8 @@ class GedInfoParser:
self.parent.add_description(name,self.current)
elif tag == "dest":
self.current.set_dest(attrs['val'])
elif tag == "endl":
self.current.set_endl(attrs['val'])
elif tag == "adopt":
val = attrs['val']
if val == 'none':