2006-10-07 Alex Roitman <shura@gramps-project.org>
* data/grampsxml.dtd: Update DTD for XML 1.1.3. * data/grampsxml.rng: Update schema for XML 1.1.3. * src/GrampsDb/_ReadXML.py (stop_county): Read county. * src/GrampsDb/_WriteXML.py (write_address_list): Write county. svn: r7363
This commit is contained in:
@@ -369,6 +369,7 @@ class GrampsParser(UpdateCallback):
|
||||
"childref" : (self.start_childref,self.stop_childref),
|
||||
"personref" : (self.start_personref,self.stop_personref),
|
||||
"city" : (None, self.stop_city),
|
||||
"county" : (None, self.stop_county),
|
||||
"country" : (None, self.stop_country),
|
||||
"comment" : (None, self.stop_comment),
|
||||
"created" : (self.start_created, None),
|
||||
@@ -1641,6 +1642,9 @@ class GrampsParser(UpdateCallback):
|
||||
def stop_city(self,tag):
|
||||
self.address.city = tag
|
||||
|
||||
def stop_county(self,tag):
|
||||
self.address.county = tag
|
||||
|
||||
def stop_state(self,tag):
|
||||
self.address.state = tag
|
||||
|
||||
|
@@ -70,7 +70,7 @@ except:
|
||||
_gzip_ok = 0
|
||||
|
||||
|
||||
_xml_version = "1.1.2"
|
||||
_xml_version = "1.1.3"
|
||||
|
||||
# table for skipping control chars from XML
|
||||
strip_dict = dict.fromkeys(range(20))
|
||||
@@ -504,6 +504,7 @@ class XmlWriter(UpdateCallback):
|
||||
self.write_date(address.get_date_object(),index+2)
|
||||
self.write_line("street",address.get_street(),index+2)
|
||||
self.write_line("city",address.get_city(),index+2)
|
||||
self.write_line("county",address.get_county(),index+2)
|
||||
self.write_line("state",address.get_state(),index+2)
|
||||
self.write_line("country",address.get_country(),index+2)
|
||||
self.write_line("postal",address.get_postal_code(),index+2)
|
||||
|
Reference in New Issue
Block a user