Fixed gedcom read/write for URL and RESI problems
svn: r429
This commit is contained in:
parent
1f52fb5b27
commit
93a0b869a7
@ -752,7 +752,9 @@ class GedcomParser:
|
||||
self.barf(level+1)
|
||||
|
||||
if form == "url":
|
||||
url = Url(file,title)
|
||||
url = Url()
|
||||
url.set_path(file)
|
||||
url.set_description(title)
|
||||
self.person.addUrl(url)
|
||||
elif form in photo_types:
|
||||
path = find_file(file,self.dir_path)
|
||||
|
@ -245,18 +245,21 @@ def sortById(first,second):
|
||||
def write_long_text(g,tag,level,note):
|
||||
prefix = "%d %s" % (level,tag)
|
||||
textlines = string.split(note,'\n')
|
||||
for line in textlines:
|
||||
while len(line) > 0:
|
||||
if len(line) > 70:
|
||||
g.write("%s %s\n" % (prefix,line[0:70]))
|
||||
line = line[70:]
|
||||
else:
|
||||
g.write("%s %s\n" % (prefix,line))
|
||||
line = ""
|
||||
if len(line) > 0:
|
||||
prefix = "%d CONC" % (level + 1)
|
||||
else:
|
||||
prefix = "%d CONT" % (level + 1)
|
||||
if len(note) == 0:
|
||||
g.write("%s\n" % prefix)
|
||||
else:
|
||||
for line in textlines:
|
||||
while len(line) > 0:
|
||||
if len(line) > 70:
|
||||
g.write("%s %s\n" % (prefix,line[0:70]))
|
||||
line = line[70:]
|
||||
else:
|
||||
g.write("%s %s\n" % (prefix,line))
|
||||
line = ""
|
||||
if len(line) > 0:
|
||||
prefix = "%d CONC" % (level + 1)
|
||||
else:
|
||||
prefix = "%d CONT" % (level + 1)
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
|
Loading…
x
Reference in New Issue
Block a user