Gedcom export, complete_rebuild fix, merge support

svn: r1223
This commit is contained in:
Don Allingham
2002-12-14 05:07:09 +00:00
parent 170394d327
commit a08425ebc8
15 changed files with 194 additions and 149 deletions

View File

@@ -130,7 +130,7 @@ def report(database,person):
top = topDialog.get_widget("summary")
textwindow = topDialog.get_widget("textwindow")
textwindow.show_string(text)
textwindow.get_buffer().set_text(text)
top.show()
#-------------------------------------------------------------------------

View File

@@ -917,7 +917,7 @@ class GedcomWriter:
else:
if surPref:
self.g.write("2 SURN %s %s\n" % (surPref,surName))
else if surName:
elif surName:
self.g.write("2 SURN %s\n" % surName)
if name.getSuffix() != "":

View File

@@ -41,8 +41,7 @@ class CountAncestors:
def __init__(self,database,person):
text = ""
base = os.path.dirname(__file__)
glade_file = base + os.sep + "summary.glade"
glade_file = "%s/summary.glade" % os.path.dirname(__file__)
topDialog = gtk.glade.XML(glade_file,"summary")
topDialog.signal_autoconnect({
"destroy_passed_object" : Utils.destroy_passed_object,
@@ -81,7 +80,7 @@ class CountAncestors:
top = topDialog.get_widget("summary")
textwindow = topDialog.get_widget("textwindow")
topDialog.get_widget("summaryTitle").set_text(title)
textwindow.show_string(text)
textwindow.get_buffer().set_text(text)
top.show()
#-------------------------------------------------------------------------

View File

@@ -1,111 +1,139 @@
<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd" >
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
<glade-interface>
<requires lib="gnome" />
<widget class="GtkDialog" id="summary">
<property name="title" translatable="yes">Database Summary - GRAMPS</property>
<property name="type">GTK_WINDOW_TOPLEVEL</property>
<property name="modal">no</property>
<property name="allow_shrink">yes</property>
<property name="allow_grow">yes</property>
<property name="visible">yes</property>
<property name="window-position">GTK_WIN_POS_NONE</property>
<widget class="GtkDialog" id="summary">
<property name="visible">True</property>
<property name="title" translatable="yes">Database Summary - GRAMPS</property>
<property name="type">GTK_WINDOW_TOPLEVEL</property>
<property name="window_position">GTK_WIN_POS_NONE</property>
<property name="modal">False</property>
<property name="default_width">450</property>
<property name="default_height">400</property>
<property name="resizable">True</property>
<property name="destroy_with_parent">False</property>
<property name="has_separator">True</property>
<child internal-child="vbox">
<widget class="GtkVBox" id="dialog-vbox1">
<property name="homogeneous">no</property>
<property name="spacing">0</property>
<property name="visible">yes</property>
<child internal-child="vbox">
<widget class="GtkVBox" id="dialog-vbox1">
<property name="visible">True</property>
<property name="homogeneous">False</property>
<property name="spacing">0</property>
<child internal-child="action_area">
<widget class="GtkHButtonBox" id="dialog-action_area1">
<property name="border_width">10</property>
<property name="homogeneous">yes</property>
<property name="spacing">5</property>
<property name="visible">yes</property>
<child internal-child="action_area">
<widget class="GtkHButtonBox" id="dialog-action_area1">
<property name="visible">True</property>
<property name="layout_style">GTK_BUTTONBOX_END</property>
<child>
<widget class="GtkHButtonBox" id="hbuttonbox1">
<property name="layout_style">GTK_BUTTONBOX_END</property>
<property name="spacing">30</property>
<property name="visible">yes</property>
<child>
<widget class="GtkHButtonBox" id="hbuttonbox1">
<property name="visible">True</property>
<property name="layout_style">GTK_BUTTONBOX_END</property>
<property name="spacing">30</property>
<child>
<widget class="GtkButton" id="button3">
<property name="can_default">yes</property>
<property name="can_focus">yes</property>
<property name="relief">GTK_RELIEF_NORMAL</property>
<property name="visible">yes</property>
<property name="label">gtk-close</property>
<property name="use_stock">yes</property>
<property name="use_underline">yes</property>
<child>
<widget class="GtkButton" id="button3">
<property name="visible">True</property>
<property name="can_default">True</property>
<property name="can_focus">True</property>
<property name="label">gtk-close</property>
<property name="use_stock">True</property>
<property name="relief">GTK_RELIEF_NORMAL</property>
<signal name="clicked" handler="destroy_passed_object" object="summary"/>
</widget>
</child>
</widget>
</child>
</widget>
<packing>
<property name="padding">0</property>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="pack_type">GTK_PACK_END</property>
</packing>
</child>
<signal name="clicked" handler="destroy_passed_object" object="summary" />
</widget>
</child>
</widget>
<packing>
<property name="padding">0</property>
<property name="expand">yes</property>
<property name="fill">yes</property>
</packing>
</child>
</widget>
<packing>
<property name="padding">0</property>
<property name="expand">no</property>
<property name="fill">yes</property>
<property name="pack_type">GTK_PACK_END</property>
</packing>
</child>
<child>
<widget class="GtkVBox" id="vbox1">
<property name="visible">True</property>
<property name="homogeneous">False</property>
<property name="spacing">0</property>
<child>
<widget class="GtkVBox" id="vbox1">
<property name="homogeneous">no</property>
<property name="spacing">0</property>
<property name="visible">yes</property>
<child>
<widget class="GtkLabel" id="summaryTitle">
<property name="visible">True</property>
<property name="label" translatable="yes">Database Summary</property>
<property name="use_underline">False</property>
<property name="use_markup">False</property>
<property name="justify">GTK_JUSTIFY_CENTER</property>
<property name="wrap">False</property>
<property name="selectable">False</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
<packing>
<property name="padding">8</property>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
<widget class="GtkLabel" id="summaryTitle">
<property name="label" translatable="yes">Database Summary</property>
<property name="justify">GTK_JUSTIFY_CENTER</property>
<property name="wrap">no</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
<property name="width-request">500</property>
<property name="height-request">16</property>
<property name="visible">yes</property>
</widget>
<packing>
<property name="padding">8</property>
<property name="expand">no</property>
<property name="fill">no</property>
</packing>
</child>
<child>
<widget class="GtkHSeparator" id="hseparator1">
<property name="visible">True</property>
</widget>
<packing>
<property name="padding">4</property>
<property name="expand">False</property>
<property name="fill">True</property>
</packing>
</child>
<child>
<widget class="GtkHSeparator" id="hseparator1">
<property name="visible">yes</property>
</widget>
<packing>
<property name="padding">4</property>
<property name="expand">no</property>
<property name="fill">yes</property>
</packing>
</child>
<child>
<widget class="GtkScrolledWindow" id="scrolledwindow1">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
<property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
<property name="shadow_type">GTK_SHADOW_NONE</property>
<property name="window_placement">GTK_CORNER_TOP_LEFT</property>
<child>
<widget class="GtkTextView" id="textwindow">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="editable">True</property>
<property name="justification">GTK_JUSTIFY_LEFT</property>
<property name="wrap_mode">GTK_WRAP_NONE</property>
<property name="cursor_visible">True</property>
<property name="pixels_above_lines">0</property>
<property name="pixels_below_lines">0</property>
<property name="pixels_inside_wrap">0</property>
<property name="left_margin">0</property>
<property name="right_margin">0</property>
<property name="indent">0</property>
<property name="text" translatable="yes"></property>
</widget>
</child>
</widget>
<packing>
<property name="padding">0</property>
<property name="expand">True</property>
<property name="fill">True</property>
</packing>
</child>
</widget>
<packing>
<property name="padding">0</property>
<property name="expand">True</property>
<property name="fill">True</property>
</packing>
</child>
</widget>
</child>
</widget>
</widget>
<packing>
<property name="padding">0</property>
<property name="expand">yes</property>
<property name="fill">yes</property>
</packing>
</child>
</widget>
</child>
</widget>
</glade-interface>