diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index 28077c22b..d08624e8e 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -1,3 +1,18 @@ +2003-08-06 Alex Roitman + * src/FamilyView.py (load_family): Enable translation for family + relation. + * src/const.py.in: Add new functions: display_event(), save_event(), + display_attr(), and save_attr() which work for either personal or + family events/attributes. Correct silly typo. + * src/WriteXML.py (dump_my_event): Call const.save_event() before + saving; (write_family_id): Call const.save_frel() before saving; + (write_attribute_list): Call const.save_attr() before saving. + * src/Marriage.py (redraw_event_list): Call const.display_fevent() + before saving; (on_add_clicked): change const.save_fevent() to + const.display_fevent(); (on_event_update_clicked): Likewise. + * src/EventEdit.py (EventEditor.__init__): Call self.trans() before + displaying event name. + 2003-08-05 Tim Waugh * src/Report.py, src/TextDoc.py, src/DrawDoc.py: Adjusted the way that 'Print Report' is handled. diff --git a/gramps2/src/EventEdit.py b/gramps2/src/EventEdit.py index 07b0673dc..de215bede 100644 --- a/gramps2/src/EventEdit.py +++ b/gramps2/src/EventEdit.py @@ -130,7 +130,7 @@ class EventEditor: AutoComp.AutoEntry(self.place_field,self.pmap.keys()) if event != None: - self.name_field.set_text(event.getName()) + self.name_field.set_text(self.trans(event.getName())) if (def_placename): self.place_field.set_text(def_placename) else: diff --git a/gramps2/src/FamilyView.py b/gramps2/src/FamilyView.py index ba3e2c242..b997508e1 100644 --- a/gramps2/src/FamilyView.py +++ b/gramps2/src/FamilyView.py @@ -520,7 +520,8 @@ class FamilyView: else: mdate = "" v = "%s\n\t%s%s" % (GrampsCfg.nameof(sp), - f.getRelationship(),mdate) + const.display_frel(f.getRelationship()), + mdate) self.spouse_model.set(iter,0,v) else: self.spouse_model.set(iter,0,"unknown\n") diff --git a/gramps2/src/Marriage.py b/gramps2/src/Marriage.py index 6b37237b2..dac2dd11d 100644 --- a/gramps2/src/Marriage.py +++ b/gramps2/src/Marriage.py @@ -357,7 +357,7 @@ class Marriage: self.etree.clear() self.emap = {} for data in self.elist: - iter = self.etree.add([data.getName(),data.getQuoteDate(),data.getPlaceName()],data) + iter = self.etree.add([const.display_fevent(data.getName()),data.getQuoteDate(),data.getPlaceName()],data) self.emap[str(data)] = iter if self.elist: self.etree.select_row(0) @@ -522,7 +522,7 @@ class Marriage: import EventEdit name = Utils.family_name(self.family) EventEdit.EventEditor(self,name,const.marriageEvents, - const.save_pevent,None,None,0,self.event_edit_callback, + const.display_fevent,None,None,0,self.event_edit_callback, const.defaultMarriageEvent) def on_event_update_clicked(self,obj): @@ -533,7 +533,7 @@ class Marriage: event = self.etree.get_object(iter) name = Utils.family_name(self.family) EventEdit.EventEditor(self,name,const.marriageEvents, - const.save_pevent,event,None,0,self.event_edit_callback) + const.display_fevent,event,None,0,self.event_edit_callback) def on_delete_clicked(self,obj): if Utils.delete_selected(obj,self.elist): diff --git a/gramps2/src/WriteXML.py b/gramps2/src/WriteXML.py index 1ef9a1281..db66f5c68 100644 --- a/gramps2/src/WriteXML.py +++ b/gramps2/src/WriteXML.py @@ -396,6 +396,7 @@ class XmlWriter: return sp = " " * index + name = const.save_event(name) self.g.write('%s\n' % (sp,self.fix(name),conf_priv(event))) self.write_date(event.getDateObj(),index+1) @@ -469,7 +470,7 @@ class XmlWriter: sp = " " * index self.g.write('%s\n' % rel) + self.g.write(' type="%s">\n' % const.save_frel(rel)) else: self.g.write('>\n') @@ -596,7 +597,8 @@ class XmlWriter: sp = ' ' * indent for attr in list: self.g.write('%s