* src/plugins/AncestorChart2.py: Change the tile when changing

the center person.
* src/plugins/SimpleBookTitle.py: Correct window title.


svn: r2734
This commit is contained in:
Alex Roitman 2004-02-01 00:44:31 +00:00
parent 384357988e
commit 586511a63e
3 changed files with 23 additions and 5 deletions

View File

@ -4,6 +4,9 @@
* src/Report.py: Mark translatable string.
* src/Witness.py: Mark translatable string.
* src/plugins/FamilyGroup.py: Mark translatable string.
* src/plugins/AncestorChart2.py: Change the tile when changing
the center person.
* src/plugins/SimpleBookTitle.py: Correct window title.
2004-01-31 Egyeki Gergely <egeri@elte.hu>
* src/po/hu.po: Updating translation for 1.0-RC

View File

@ -558,7 +558,7 @@ class AncestorChartBareDialog(Report.BareReportDialog):
if self.options[4] is not None:
self.the_title = self.options[4]
else:
self.the_title = self.get_the_title()
self.the_title = self.get_the_title(self.person)
self.new_person = None
self.generations_spinbox.set_value(self.max_gen)
@ -576,7 +576,7 @@ class AncestorChartBareDialog(Report.BareReportDialog):
#------------------------------------------------------------------------
def add_user_options(self):
self.title=gtk.Entry()
self.title.set_text(self.get_the_title())
self.title.set_text(self.get_the_title(self.person))
self.title.show()
self.add_option(_('Title'),self.title)
self.compress = gtk.CheckButton(_('Co_mpress chart'))
@ -588,9 +588,9 @@ class AncestorChartBareDialog(Report.BareReportDialog):
"""The window title for this dialog"""
return "%s - GRAMPS Book" % (_("Ancestor Chart"))
def get_the_title(self):
def get_the_title(self,person):
"""The header line at the top of the dialog contents."""
return _("Ancestor Chart for %s") % self.person.getPrimaryName().getName()
return _("Ancestor Chart for %s") % person.getPrimaryName().getName()
def get_header(self,name):
"""The header line at the top of the dialog contents"""
@ -618,6 +618,21 @@ class AncestorChartBareDialog(Report.BareReportDialog):
self.do_compress = self.compress.get_active()
self.the_title = self.title.get_text()
def on_center_person_change_clicked(self,obj):
import SelectPerson
sel_person = SelectPerson.SelectPerson(self.db,_('Select Person'))
new_person = sel_person.run()
if new_person:
self.new_person = new_person
self.the_title = self.get_the_title(self.new_person)
self.title.set_text(self.the_title)
new_name = new_person.getPrimaryName().getRegularName()
if new_name:
self.person_label.set_text( "<i>%s</i>" % new_name )
self.person_label.set_use_markup(gtk.TRUE)
def on_cancel(self, obj):
pass

View File

@ -275,7 +275,7 @@ class SimpleBookTitleDialog(Report.BareReportDialog):
def get_title(self):
"""The window title for this dialog"""
return "%s - GRAMPS Book" % (_("Simple Book Title"))
return "%s - GRAMPS Book" % (_("Title Page"))
def get_header(self, name):
"""The header line at the top of the dialog contents"""