* src/NameEdit.py (on_help_clicked): Add function.

* src/UrlEdit.py (on_help_clicked): Add function.
* src/gramps.glade: Add hot keys to the family view list labels.


svn: r2348
This commit is contained in:
Alex Roitman 2003-11-19 02:29:41 +00:00
parent 69270a29f8
commit b362afd128
4 changed files with 59 additions and 25 deletions

View File

@ -1,3 +1,8 @@
2003-11-12 Alex Roitman <shura@alex.neuro.umn.edu>
* src/NameEdit.py (on_help_clicked): Add function.
* src/UrlEdit.py (on_help_clicked): Add function.
* src/gramps.glade: Add hot keys to the family view list labels.
2003-11-17 Alex Roitman <shura@alex.neuro.umn.edu> 2003-11-17 Alex Roitman <shura@alex.neuro.umn.edu>
* src/gramps.glade: Add Help buttons to dialogs. * src/gramps.glade: Add Help buttons to dialogs.
* src/AddSpouse.py (on_spouse_help_clicked): Add function. * src/AddSpouse.py (on_spouse_help_clicked): Add function.

View File

@ -26,6 +26,7 @@
# #
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
import gtk.glade import gtk.glade
import gnome
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
# #
@ -97,6 +98,7 @@ class NameEditor:
self.note_buffer = self.note_field.get_buffer() self.note_buffer = self.note_field.get_buffer()
self.top.signal_autoconnect({ self.top.signal_autoconnect({
"on_help_name_clicked" : self.on_help_clicked,
"on_switch_page" : self.on_switch_page "on_switch_page" : self.on_switch_page
}) })
@ -113,11 +115,16 @@ class NameEditor:
if parent_window: if parent_window:
self.window.set_transient_for(parent_window) self.window.set_transient_for(parent_window)
val = self.window.run() self.val = self.window.run()
if val == gtk.RESPONSE_OK: if self.val == gtk.RESPONSE_OK:
self.on_name_edit_ok_clicked() self.on_name_edit_ok_clicked()
self.window.destroy() self.window.destroy()
def on_help_clicked(self,obj):
"""Display the relevant portion of GRAMPS manual"""
gnome.help_display('gramps-manual','adv-an')
self.val = self.window.run()
def on_name_edit_ok_clicked(self): def on_name_edit_ok_clicked(self):
first = self.given_field.get_text() first = self.given_field.get_text()
last = self.surname_field.get_text() last = self.surname_field.get_text()

View File

@ -1,7 +1,7 @@
# #
# Gramps - a GTK+/GNOME based genealogy program # Gramps - a GTK+/GNOME based genealogy program
# #
# Copyright (C) 2000 Donald N. Allingham # Copyright (C) 2000-2003 Donald N. Allingham
# #
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by # it under the terms of the GNU General Public License as published by
@ -18,12 +18,15 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
# #
# $Id$
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
# #
# GTK/Gnome modules # GTK/Gnome modules
# #
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
import gtk.glade import gtk.glade
import gnome
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
# #
@ -66,13 +69,22 @@ class UrlEditor:
self.addr.set_text(url.get_path()) self.addr.set_text(url.get_path())
self.priv.set_active(url.getPrivacy()) self.priv.set_active(url.getPrivacy())
self.top.signal_autoconnect({
"on_help_url_clicked" : self.on_help_clicked,
})
if parent_window: if parent_window:
self.window.set_transient_for(parent_window) self.window.set_transient_for(parent_window)
val = self.window.run() self.val = self.window.run()
if val == gtk.RESPONSE_OK: if self.val == gtk.RESPONSE_OK:
self.on_url_edit_ok_clicked() self.on_url_edit_ok_clicked()
self.window.destroy() self.window.destroy()
def on_help_clicked(self,obj):
"""Display the relevant portion of GRAMPS manual"""
gnome.help_display('gramps-manual','gramps-edit-complete')
self.val = self.window.run()
def on_url_edit_ok_clicked(self): def on_url_edit_ok_clicked(self):
des = self.des.get_text() des = self.des.get_text()
addr = self.addr.get_text() addr = self.addr.get_text()

View File

@ -1870,8 +1870,8 @@
<child> <child>
<widget class="GtkLabel" id="label364"> <widget class="GtkLabel" id="label364">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Children&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;_Children&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -1880,6 +1880,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">chlist</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
@ -1894,8 +1895,8 @@
<child> <child>
<widget class="GtkLabel" id="label360"> <widget class="GtkLabel" id="label360">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Active person&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;_Active person&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -1904,6 +1905,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">ap_data</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
@ -1918,8 +1920,8 @@
<child> <child>
<widget class="GtkLabel" id="label362"> <widget class="GtkLabel" id="label362">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Active person's parents&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;Active person's _parents&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -1928,6 +1930,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">ap_parents</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">3</property> <property name="left_attach">3</property>
@ -1942,8 +1945,8 @@
<child> <child>
<widget class="GtkLabel" id="label361"> <widget class="GtkLabel" id="label361">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Relationship&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;Relati_onship&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -1952,6 +1955,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">sp_list</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
@ -1966,8 +1970,8 @@
<child> <child>
<widget class="GtkLabel" id="label363"> <widget class="GtkLabel" id="label363">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Spouse's parents&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;Spo_use's parents&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -1976,6 +1980,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">sp_parents</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">3</property> <property name="left_attach">3</property>
@ -2295,8 +2300,8 @@
<child> <child>
<widget class="GtkLabel" id="label386"> <widget class="GtkLabel" id="label386">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Children&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;_Children&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -2305,6 +2310,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">chlist2</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
@ -2559,8 +2565,8 @@
<child> <child>
<widget class="GtkLabel" id="label390"> <widget class="GtkLabel" id="label390">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Spouse's parents&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;Spo_use's parents&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -2569,6 +2575,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">sp_parents2</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">3</property> <property name="left_attach">3</property>
@ -2677,8 +2684,8 @@
<child> <child>
<widget class="GtkLabel" id="label389"> <widget class="GtkLabel" id="label389">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Relationship&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;Relati_onship&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -2687,6 +2694,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">sp_list2</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">3</property> <property name="left_attach">3</property>
@ -2795,8 +2803,8 @@
<child> <child>
<widget class="GtkLabel" id="label387"> <widget class="GtkLabel" id="label387">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Active person&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;_Active person&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -2805,6 +2813,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">ap_data2</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
@ -2819,8 +2828,8 @@
<child> <child>
<widget class="GtkLabel" id="label388"> <widget class="GtkLabel" id="label388">
<property name="visible">True</property> <property name="visible">True</property>
<property name="label" translatable="yes">&lt;b&gt;Active person's parents&lt;/b&gt;</property> <property name="label" translatable="yes">&lt;b&gt;Active person's _parents&lt;/b&gt;</property>
<property name="use_underline">False</property> <property name="use_underline">True</property>
<property name="use_markup">True</property> <property name="use_markup">True</property>
<property name="justify">GTK_JUSTIFY_LEFT</property> <property name="justify">GTK_JUSTIFY_LEFT</property>
<property name="wrap">False</property> <property name="wrap">False</property>
@ -2829,6 +2838,7 @@
<property name="yalign">0.5</property> <property name="yalign">0.5</property>
<property name="xpad">0</property> <property name="xpad">0</property>
<property name="ypad">0</property> <property name="ypad">0</property>
<property name="mnemonic_widget">ap_parents2</property>
</widget> </widget>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>