Add glade.py with Glade class and use instead of gtk.Builder throughout project
svn: r12528
This commit is contained in:
parent
feb15edc7e
commit
110557c3c7
@ -772,8 +772,8 @@ src/widgets/validatedmaskedentry.py
|
|||||||
#
|
#
|
||||||
# Glade files
|
# Glade files
|
||||||
#
|
#
|
||||||
src/plugins/docgen/gtkprintpreview.glade
|
src/plugins/docgen/gtkprint.glade
|
||||||
src/glade/edit_person.glade
|
src/glade/editperson.glade
|
||||||
src/glade/gramps.glade
|
src/glade/gramps.glade
|
||||||
|
|
||||||
# widgets split off from gramps.glade
|
# widgets split off from gramps.glade
|
||||||
@ -803,16 +803,13 @@ src/glade/editattribute.glade
|
|||||||
src/glade/editaddress.glade
|
src/glade/editaddress.glade
|
||||||
src/glade/editmedia.glade
|
src/glade/editmedia.glade
|
||||||
src/glade/editmediaref.glade
|
src/glade/editmediaref.glade
|
||||||
src/glade/editaddress.glade
|
|
||||||
src/glade/editeventref.glade
|
src/glade/editeventref.glade
|
||||||
src/glade/editldsord.glade
|
src/glade/editldsord.glade
|
||||||
src/glade/editmedia.glade
|
|
||||||
src/glade/editnote.glade
|
src/glade/editnote.glade
|
||||||
src/glade/editplace.glade
|
src/glade/editplace.glade
|
||||||
src/glade/editsourceref.glade
|
src/glade/editsourceref.glade
|
||||||
src/glade/editname.glade
|
src/glade/editname.glade
|
||||||
src/glade/editevent.glade
|
src/glade/editevent.glade
|
||||||
src/glade/editurl.glade
|
|
||||||
|
|
||||||
# end of widgets split off from gramps.glade
|
# end of widgets split off from gramps.glade
|
||||||
|
|
||||||
@ -820,28 +817,29 @@ src/glade/mergedata.glade
|
|||||||
src/glade/plugins.glade
|
src/glade/plugins.glade
|
||||||
src/glade/rule.glade
|
src/glade/rule.glade
|
||||||
src/glade/scratchpad.glade
|
src/glade/scratchpad.glade
|
||||||
src/glade/paper_settings.glade
|
src/glade/papermenu.glade
|
||||||
src/plugins/tool/NotRelated.glade
|
src/plugins/tool/notrelated.glade
|
||||||
src/plugins/book.glade
|
src/plugins/bookreport.glade
|
||||||
src/plugins/tool/changenames.glade
|
src/plugins/tool/changenames.glade
|
||||||
src/plugins/tool/changetype.glade
|
src/plugins/tool/changetypes.glade
|
||||||
src/plugins/tool/desbrowse.glade
|
src/plugins/tool/check.glade
|
||||||
|
src/plugins/tool/desbrowser.glade
|
||||||
src/plugins/tool/eval.glade
|
src/plugins/tool/eval.glade
|
||||||
src/plugins/tool/eventcmp.glade
|
src/plugins/tool/eventcmp.glade
|
||||||
src/plugins/import/ImportGedcom.glade
|
src/plugins/import/importgedcom.glade
|
||||||
src/plugins/tool/leak.glade
|
src/plugins/tool/leak.glade
|
||||||
src/plugins/tool/merge.glade
|
src/plugins/tool/finddupes.glade
|
||||||
src/plugins/tool/ownereditor.glade
|
src/plugins/tool/ownereditor.glade
|
||||||
src/plugins/tool/patchnames.glade
|
src/plugins/tool/patchnames.glade
|
||||||
|
src/plugins/tool/phpgedview.glade
|
||||||
src/plugins/tool/relcalc.glade
|
src/plugins/tool/relcalc.glade
|
||||||
src/plugins/tool/soundex.glade
|
src/plugins/tool/soundgen.glade
|
||||||
src/plugins/tool/summary.glade
|
src/plugins/tool/removeunused.glade
|
||||||
src/plugins/tool/unused.glade
|
src/plugins/export/exportcsv.glade
|
||||||
src/plugins/export/ExportCsv.glade
|
src/plugins/export/exportftree.glade
|
||||||
src/plugins/export/ExportFtree.glade
|
src/plugins/export/exportgeneweb.glade
|
||||||
src/plugins/export/ExportGeneWeb.glade
|
src/plugins/export/exportvcalendar.glade
|
||||||
src/plugins/export/ExportVCard.glade
|
src/plugins/export/exportvcard.glade
|
||||||
src/plugins/export/ExportVCalendar.glade
|
|
||||||
src/plugins/tool/verify.glade
|
src/plugins/tool/verify.glade
|
||||||
#
|
#
|
||||||
# Files to extract from and then merge into
|
# Files to extract from and then merge into
|
||||||
|
@ -29,7 +29,6 @@ Handle the column ordering
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import logging
|
import logging
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -46,6 +45,8 @@ import gobject
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import const
|
import const
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -53,8 +54,6 @@ import ManagedWindow
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
__LOG = logging.getLogger(".ColumnOrder")
|
__LOG = logging.getLogger(".ColumnOrder")
|
||||||
_GLADE_FILE = 'columnorder.glade'
|
|
||||||
|
|
||||||
|
|
||||||
class ColumnOrder(ManagedWindow.ManagedWindow):
|
class ColumnOrder(ManagedWindow.ManagedWindow):
|
||||||
"""
|
"""
|
||||||
@ -67,11 +66,8 @@ class ColumnOrder(ManagedWindow.ManagedWindow):
|
|||||||
"""
|
"""
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade()
|
||||||
self.glade = gtk.Builder()
|
self.set_window(self.glade.toplevel, None, win_name)
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.glade.get_object('columns'), None, win_name)
|
|
||||||
|
|
||||||
self.tree = self.glade.get_object('list')
|
self.tree = self.glade.get_object('list')
|
||||||
self.arglist = arglist
|
self.arglist = arglist
|
||||||
|
@ -52,6 +52,7 @@ import ConfigParser
|
|||||||
import Utils
|
import Utils
|
||||||
from QuickReports import run_quick_report_by_name
|
from QuickReports import run_quick_report_by_name
|
||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -59,7 +60,6 @@ import GrampsDisplay
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
WIKI_HELP_PAGE = const.URL_MANUAL_PAGE + '_-_Gramplets'
|
WIKI_HELP_PAGE = const.URL_MANUAL_PAGE + '_-_Gramplets'
|
||||||
_GLADE_FILE = 'grampletview.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -640,10 +640,8 @@ class GuiGramplet:
|
|||||||
self.tooltips = None # gtk tooltip widget
|
self.tooltips = None # gtk tooltip widget
|
||||||
self.tooltips_text = None
|
self.tooltips_text = None
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade()
|
||||||
self.xml = gtk.Builder()
|
self.gvwin = self.xml.toplevel
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
self.gvwin = self.xml.get_object('gvwin')
|
|
||||||
self.mainframe = self.xml.get_object('gvgramplet')
|
self.mainframe = self.xml.get_object('gvgramplet')
|
||||||
self.gvwin.remove(self.mainframe)
|
self.gvwin.remove(self.mainframe)
|
||||||
|
|
||||||
|
@ -48,7 +48,6 @@ unambiguously built using UI controls such as menus and spin buttons.
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import logging
|
import logging
|
||||||
__LOG = logging.getLogger(".DateEdit")
|
__LOG = logging.getLogger(".DateEdit")
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -69,6 +68,7 @@ import const
|
|||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from Errors import ValidationError
|
from Errors import ValidationError
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -100,7 +100,7 @@ CAL_TO_MONTHS_NAMES = {
|
|||||||
|
|
||||||
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_1' % const.URL_MANUAL_PAGE
|
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_1' % const.URL_MANUAL_PAGE
|
||||||
WIKI_HELP_SEC = _('manual|Editing_Dates')
|
WIKI_HELP_SEC = _('manual|Editing_Dates')
|
||||||
_GLADE_FILE = 'dateedit.glade'
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# DateEdit
|
# DateEdit
|
||||||
@ -192,12 +192,10 @@ class DateEditorDialog(ManagedWindow.ManagedWindow):
|
|||||||
# Create self.date as a copy of the given Date object.
|
# Create self.date as a copy of the given Date object.
|
||||||
self.date = Date(date)
|
self.date = Date(date)
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(
|
self.set_window(
|
||||||
self.top.get_object('date_edit'),
|
self.top.toplevel,
|
||||||
self.top.get_object('title'),
|
self.top.get_object('title'),
|
||||||
_('Date selection'))
|
_('Date selection'))
|
||||||
|
|
||||||
|
@ -76,10 +76,12 @@ import Config
|
|||||||
import Mime
|
import Mime
|
||||||
from DdTargets import DdTargets
|
from DdTargets import DdTargets
|
||||||
import RecentFiles
|
import RecentFiles
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
_RETURN = gtk.gdk.keyval_from_name("Return")
|
_RETURN = gtk.gdk.keyval_from_name("Return")
|
||||||
_KP_ENTER = gtk.gdk.keyval_from_name("KP_Enter")
|
_KP_ENTER = gtk.gdk.keyval_from_name("KP_Enter")
|
||||||
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# constants
|
# constants
|
||||||
@ -90,7 +92,6 @@ NAME_FILE = "name.txt"
|
|||||||
META_NAME = "meta_data.db"
|
META_NAME = "meta_data.db"
|
||||||
ARCHIVE = "rev.gramps"
|
ARCHIVE = "rev.gramps"
|
||||||
ARCHIVE_V = "rev.gramps,v"
|
ARCHIVE_V = "rev.gramps,v"
|
||||||
_GLADE_FILE = "dbmanager.glade"
|
|
||||||
|
|
||||||
NAME_COL = 0
|
NAME_COL = 0
|
||||||
PATH_COL = 1
|
PATH_COL = 1
|
||||||
@ -341,12 +342,9 @@ class DbManager(CLIDbManager):
|
|||||||
the GTK widgets that are needed.
|
the GTK widgets that are needed.
|
||||||
"""
|
"""
|
||||||
CLIDbManager.__init__(self, dbstate)
|
CLIDbManager.__init__(self, dbstate)
|
||||||
|
self.glade = Glade()
|
||||||
|
self.top = self.glade.toplevel
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
|
||||||
self.glade = gtk.Builder()
|
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top = self.glade.get_object('dbmanager')
|
|
||||||
if parent:
|
if parent:
|
||||||
self.top.set_transient_for(parent)
|
self.top.set_transient_for(parent)
|
||||||
|
|
||||||
@ -1119,13 +1117,9 @@ def check_in(dbase, filename, callback, cursor_func = None):
|
|||||||
ci_cmd = [ "ci", '-x,v', "-q", "-f" ]
|
ci_cmd = [ "ci", '-x,v', "-q", "-f" ]
|
||||||
archive_name = filename + ",v"
|
archive_name = filename + ",v"
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade(toplevel='comment')
|
||||||
self.glade = gtk.Builder()
|
self.top = self.glade.toplevel
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
top = self.glade.get_object('comment')
|
|
||||||
text = self.glade.get_object('description')
|
text = self.glade.get_object('description')
|
||||||
|
|
||||||
top.run()
|
top.run()
|
||||||
comment = text.get_text()
|
comment = text.get_text()
|
||||||
top.destroy()
|
top.destroy()
|
||||||
|
@ -57,9 +57,9 @@ from BasicUtils import name_displayer
|
|||||||
import const
|
import const
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from gen.plug import PluginManager
|
from gen.plug import PluginManager
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
DISABLED = -1
|
DISABLED = -1
|
||||||
_GLADE_FILE = 'displaystate.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -83,7 +83,7 @@ class History(gen.utils.Callback):
|
|||||||
|
|
||||||
def clear(self):
|
def clear(self):
|
||||||
"""
|
"""
|
||||||
Cleares the history, resetting the values back to their defaults
|
Clears the history, resetting the values back to their defaults
|
||||||
"""
|
"""
|
||||||
self.history = []
|
self.history = []
|
||||||
self.mhistory = []
|
self.mhistory = []
|
||||||
@ -285,11 +285,9 @@ class WarnHandler(RotateHandler):
|
|||||||
|
|
||||||
def display(self, obj):
|
def display(self, obj):
|
||||||
obj.hide()
|
obj.hide()
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade()
|
||||||
self.xml = gtk.Builder()
|
top = self.toplevel
|
||||||
self.xml.add_from_file(glade_file)
|
msg = self.glade.get_object('msg')
|
||||||
top = xml.get_widget('scrollmsg')
|
|
||||||
msg = xml.get_widget('msg')
|
|
||||||
buf = msg.get_buffer()
|
buf = msg.get_buffer()
|
||||||
for i in self.get_formatted_log():
|
for i in self.get_formatted_log():
|
||||||
buf.insert_at_cursor(i + '\n')
|
buf.insert_at_cursor(i + '\n')
|
||||||
|
@ -57,14 +57,7 @@ import Mime
|
|||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from QuestionDialog import ErrorDialog, WarningDialog
|
from QuestionDialog import ErrorDialog, WarningDialog
|
||||||
|
from glade import Glade
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# global variables
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = 'addmedia.glade'
|
|
||||||
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -94,12 +87,9 @@ class AddMediaObject(ManagedWindow.ManagedWindow):
|
|||||||
self.last_directory = Config.get(Config.ADDMEDIA_IMGDIR)
|
self.last_directory = Config.get(Config.ADDMEDIA_IMGDIR)
|
||||||
self.relative_path = Config.get(Config.ADDMEDIA_RELPATH)
|
self.relative_path = Config.get(Config.ADDMEDIA_RELPATH)
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade()
|
||||||
self.glade = gtk.Builder()
|
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(
|
self.set_window(
|
||||||
self.glade.get_object("imageSelect"),
|
self.glade.toplevel,
|
||||||
self.glade.get_object('title'),
|
self.glade.get_object('title'),
|
||||||
_('Select a media object'))
|
_('Select a media object'))
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ mechanism for the user to edit address information.
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -50,12 +49,10 @@ import const
|
|||||||
import Config
|
import Config
|
||||||
from _EditSecondary import EditSecondary
|
from _EditSecondary import EditSecondary
|
||||||
from gen.lib import NoteType
|
from gen.lib import NoteType
|
||||||
|
from glade import Glade
|
||||||
from DisplayTabs import SourceEmbedList, NoteTab
|
from DisplayTabs import SourceEmbedList, NoteTab
|
||||||
from widgets import MonitoredDate, MonitoredEntry, PrivacyButton
|
from widgets import MonitoredDate, MonitoredEntry, PrivacyButton
|
||||||
|
|
||||||
_GLADE_FILE = 'editaddress.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# EditAddress class
|
# EditAddress class
|
||||||
@ -80,11 +77,8 @@ class EditAddress(EditSecondary):
|
|||||||
self.width_key = Config.ADDRESS_WIDTH
|
self.width_key = Config.ADDRESS_WIDTH
|
||||||
self.height_key = Config.ADDRESS_HEIGHT
|
self.height_key = Config.ADDRESS_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
self.set_window(self.top.toplevel,
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("addr_edit"),
|
|
||||||
self.top.get_object("title"),
|
self.top.get_object("title"),
|
||||||
_('Address Editor'))
|
_('Address Editor'))
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ mechanism for the user to edit attribute information.
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -50,12 +49,10 @@ import const
|
|||||||
import Config
|
import Config
|
||||||
from _EditSecondary import EditSecondary
|
from _EditSecondary import EditSecondary
|
||||||
from gen.lib import NoteType
|
from gen.lib import NoteType
|
||||||
|
from glade import Glade
|
||||||
from DisplayTabs import SourceEmbedList, NoteTab
|
from DisplayTabs import SourceEmbedList, NoteTab
|
||||||
from widgets import MonitoredEntry, PrivacyButton, MonitoredDataType
|
from widgets import MonitoredEntry, PrivacyButton, MonitoredDataType
|
||||||
|
|
||||||
_GLADE_FILE = 'editattribute.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# EditAttribute class
|
# EditAttribute class
|
||||||
@ -81,11 +78,9 @@ class EditAttribute(EditSecondary):
|
|||||||
def _local_init(self):
|
def _local_init(self):
|
||||||
self.width_key = Config.ATTRIBUTE_WIDTH
|
self.width_key = Config.ATTRIBUTE_WIDTH
|
||||||
self.height_key = Config.ATTRIBUTE_HEIGHT
|
self.height_key = Config.ATTRIBUTE_HEIGHT
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("attr_edit"),
|
self.set_window(self.top.toplevel,
|
||||||
self.top.get_object('title'),
|
self.top.get_object('title'),
|
||||||
_('Attribute Editor'))
|
_('Attribute Editor'))
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ mechanism for the user to edit address information.
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -51,7 +50,7 @@ from _EditSecondary import EditSecondary
|
|||||||
from gen.lib import NoteType
|
from gen.lib import NoteType
|
||||||
import Errors
|
import Errors
|
||||||
import Config
|
import Config
|
||||||
|
from glade import Glade
|
||||||
from DisplayTabs import SourceEmbedList, NoteTab
|
from DisplayTabs import SourceEmbedList, NoteTab
|
||||||
from widgets import MonitoredDataType, PrivacyButton
|
from widgets import MonitoredDataType, PrivacyButton
|
||||||
from BasicUtils import name_displayer
|
from BasicUtils import name_displayer
|
||||||
@ -66,7 +65,6 @@ _RETURN = gtk.gdk.keyval_from_name("Return")
|
|||||||
_KP_ENTER = gtk.gdk.keyval_from_name("KP_Enter")
|
_KP_ENTER = gtk.gdk.keyval_from_name("KP_Enter")
|
||||||
_LEFT_BUTTON = 1
|
_LEFT_BUTTON = 1
|
||||||
_RIGHT_BUTTON = 3
|
_RIGHT_BUTTON = 3
|
||||||
_GLADE_FILE = 'editchildref.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -91,11 +89,9 @@ class EditChildRef(EditSecondary):
|
|||||||
def _local_init(self):
|
def _local_init(self):
|
||||||
self.width_key = Config.CHILD_REF_WIDTH
|
self.width_key = Config.CHILD_REF_WIDTH
|
||||||
self.height_key = Config.CHILD_REF_HEIGHT
|
self.height_key = Config.CHILD_REF_HEIGHT
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("cref_edit"),
|
self.top = Glade()
|
||||||
|
self.set_window(self.top.toplevel,
|
||||||
self.top.get_object("title"),
|
self.top.get_object("title"),
|
||||||
self.name,
|
self.name,
|
||||||
_('Child Reference Editor'))
|
_('Child Reference Editor'))
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -47,7 +46,7 @@ import gen.lib
|
|||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
from _EditPrimary import EditPrimary
|
from _EditPrimary import EditPrimary
|
||||||
from ObjectEntries import PlaceEntry
|
from ObjectEntries import PlaceEntry
|
||||||
|
from glade import Glade
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
from DisplayTabs import (SourceEmbedList, NoteTab, GalleryTab,
|
from DisplayTabs import (SourceEmbedList, NoteTab, GalleryTab,
|
||||||
EventBackRefList, AttrEmbedList)
|
EventBackRefList, AttrEmbedList)
|
||||||
@ -61,7 +60,6 @@ from widgets import (MonitoredEntry, PrivacyButton,
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_2' % const.URL_MANUAL_PAGE
|
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_2' % const.URL_MANUAL_PAGE
|
||||||
WIKI_HELP_SEC = _('manual|Editing_Information_About_Events')
|
WIKI_HELP_SEC = _('manual|Editing_Information_About_Events')
|
||||||
_GLADE_FILE = 'editevent.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -102,11 +100,8 @@ class EditEvent(EditPrimary):
|
|||||||
self.width_key = Config.EVENT_WIDTH
|
self.width_key = Config.EVENT_WIDTH
|
||||||
self.height_key = Config.EVENT_HEIGHT
|
self.height_key = Config.EVENT_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
self.set_window(self.top.toplevel, None,
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("event_edit"), None,
|
|
||||||
self.get_menu_title())
|
self.get_menu_title())
|
||||||
|
|
||||||
self.place = self.top.get_object('place')
|
self.place = self.top.get_object('place')
|
||||||
|
@ -27,14 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GTK/Gnome modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -44,7 +36,7 @@ import gtk
|
|||||||
import const
|
import const
|
||||||
import Config
|
import Config
|
||||||
import gen.lib
|
import gen.lib
|
||||||
|
from glade import Glade
|
||||||
from DisplayTabs import (SourceEmbedList, NoteTab, GalleryTab,
|
from DisplayTabs import (SourceEmbedList, NoteTab, GalleryTab,
|
||||||
EventBackRefList, AttrEmbedList)
|
EventBackRefList, AttrEmbedList)
|
||||||
from widgets import (PrivacyButton, MonitoredEntry,
|
from widgets import (PrivacyButton, MonitoredEntry,
|
||||||
@ -53,14 +45,6 @@ from _EditReference import RefTab, EditReference
|
|||||||
|
|
||||||
from ObjectEntries import PlaceEntry
|
from ObjectEntries import PlaceEntry
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# Constants
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
|
|
||||||
_GLADE_FILE = 'editeventref.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# EditEventRef class
|
# EditEventRef class
|
||||||
@ -77,11 +61,8 @@ class EditEventRef(EditReference):
|
|||||||
self.width_key = Config.EVENT_REF_WIDTH
|
self.width_key = Config.EVENT_REF_WIDTH
|
||||||
self.height_key = Config.EVENT_REF_HEIGHT
|
self.height_key = Config.EVENT_REF_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
self.set_window(self.top.toplevel,
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object('event_eref_edit'),
|
|
||||||
self.top.get_object('eer_title'),
|
self.top.get_object('eer_title'),
|
||||||
_('Event Reference Editor'))
|
_('Event Reference Editor'))
|
||||||
self.define_warn_box(self.top.get_object("eer_warning"))
|
self.define_warn_box(self.top.get_object("eer_warning"))
|
||||||
|
@ -30,7 +30,6 @@ from bsddb import db as bsddb_db
|
|||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
from DdTargets import DdTargets
|
from DdTargets import DdTargets
|
||||||
import pickle
|
import pickle
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -61,6 +60,7 @@ from BasicUtils import name_displayer
|
|||||||
import gen.lib
|
import gen.lib
|
||||||
import Errors
|
import Errors
|
||||||
import DateHandler
|
import DateHandler
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
from Editors import EditPrimary
|
from Editors import EditPrimary
|
||||||
from ReportBase import ReportUtils
|
from ReportBase import ReportUtils
|
||||||
@ -80,7 +80,6 @@ _RETURN = gdk.keyval_from_name("Return")
|
|||||||
_KP_ENTER = gdk.keyval_from_name("KP_Enter")
|
_KP_ENTER = gdk.keyval_from_name("KP_Enter")
|
||||||
_LEFT_BUTTON = 1
|
_LEFT_BUTTON = 1
|
||||||
_RIGHT_BUTTON = 3
|
_RIGHT_BUTTON = 3
|
||||||
_GLADE_FILE = 'editfamily.glade'
|
|
||||||
|
|
||||||
class ChildEmbedList(EmbeddedList):
|
class ChildEmbedList(EmbeddedList):
|
||||||
"""
|
"""
|
||||||
@ -518,11 +517,8 @@ class EditFamily(EditPrimary):
|
|||||||
self.width_key = Config.FAMILY_WIDTH
|
self.width_key = Config.FAMILY_WIDTH
|
||||||
self.height_key = Config.FAMILY_HEIGHT
|
self.height_key = Config.FAMILY_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
self.set_window(self.top.toplevel, None, self.get_menu_title())
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("family_editor"), None, self.get_menu_title())
|
|
||||||
|
|
||||||
# HACK: how to prevent hidden items from showing
|
# HACK: how to prevent hidden items from showing
|
||||||
# when you use show_all?
|
# when you use show_all?
|
||||||
|
@ -31,7 +31,6 @@ mechanism for the user to edit personal LDS information.
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -50,10 +49,9 @@ import Config
|
|||||||
import gen.lib
|
import gen.lib
|
||||||
from BasicUtils import name_displayer
|
from BasicUtils import name_displayer
|
||||||
import LdsUtils
|
import LdsUtils
|
||||||
|
from glade import Glade
|
||||||
from _EditSecondary import EditSecondary
|
from _EditSecondary import EditSecondary
|
||||||
from ObjectEntries import PlaceEntry
|
from ObjectEntries import PlaceEntry
|
||||||
|
|
||||||
from DisplayTabs import SourceEmbedList,NoteTab
|
from DisplayTabs import SourceEmbedList,NoteTab
|
||||||
from widgets import (PrivacyButton, MonitoredDate,
|
from widgets import (PrivacyButton, MonitoredDate,
|
||||||
MonitoredMenu, MonitoredStrMenu)
|
MonitoredMenu, MonitoredStrMenu)
|
||||||
@ -121,8 +119,6 @@ _DATA_MAP = {
|
|||||||
],
|
],
|
||||||
}
|
}
|
||||||
|
|
||||||
_GLADE_FILE = 'editldsord.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# EditLdsOrd class
|
# EditLdsOrd class
|
||||||
@ -148,11 +144,8 @@ class EditLdsOrd(EditSecondary):
|
|||||||
self.width_key = Config.LDS_WIDTH
|
self.width_key = Config.LDS_WIDTH
|
||||||
self.height_key = Config.LDS_HEIGHT
|
self.height_key = Config.LDS_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
self.set_window(self.top.toplevel,
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("lds_person_edit"),
|
|
||||||
self.top.get_object('title'),
|
self.top.get_object('title'),
|
||||||
_('LDS Ordinance Editor'))
|
_('LDS Ordinance Editor'))
|
||||||
self.share_btn = self.top.get_object('share_place')
|
self.share_btn = self.top.get_object('share_place')
|
||||||
|
@ -21,14 +21,6 @@
|
|||||||
|
|
||||||
# $Id$
|
# $Id$
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GTK/Gnome modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# gramps modules
|
# gramps modules
|
||||||
@ -37,12 +29,10 @@ import os
|
|||||||
import const
|
import const
|
||||||
import Config
|
import Config
|
||||||
from _EditSecondary import EditSecondary
|
from _EditSecondary import EditSecondary
|
||||||
|
from glade import Glade
|
||||||
from widgets import MonitoredEntry
|
from widgets import MonitoredEntry
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
_GLADE_FILE = 'editlocation.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# LocationEditor class
|
# LocationEditor class
|
||||||
@ -57,11 +47,8 @@ class EditLocation(EditSecondary):
|
|||||||
def _local_init(self):
|
def _local_init(self):
|
||||||
self.width_key = Config.LOCATION_WIDTH
|
self.width_key = Config.LOCATION_WIDTH
|
||||||
self.height_key = Config.LOCATION_HEIGHT
|
self.height_key = Config.LOCATION_HEIGHT
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
self.set_window(self.top.toplevel, None,
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("loc_edit"), None,
|
|
||||||
_('Location Editor'))
|
_('Location Editor'))
|
||||||
|
|
||||||
def _setup_fields(self):
|
def _setup_fields(self):
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -53,8 +52,7 @@ from DisplayTabs import (SourceEmbedList, AttrEmbedList, NoteTab,
|
|||||||
MediaBackRefList)
|
MediaBackRefList)
|
||||||
from Editors.AddMedia import AddMediaObject
|
from Editors.AddMedia import AddMediaObject
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editmedia.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -95,11 +93,8 @@ class EditMedia(EditPrimary):
|
|||||||
self.width_key = Config.MEDIA_WIDTH
|
self.width_key = Config.MEDIA_WIDTH
|
||||||
self.height_key = Config.MEDIA_HEIGHT
|
self.height_key = Config.MEDIA_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade()
|
||||||
self.glade = gtk.Builder()
|
self.set_window(self.glade.toplevel,
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.glade.get_object('change_global'),
|
|
||||||
None, self.get_menu_title())
|
None, self.get_menu_title())
|
||||||
|
|
||||||
def _connect_signals(self):
|
def _connect_signals(self):
|
||||||
|
@ -28,7 +28,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -48,13 +47,12 @@ import Mime
|
|||||||
import ThumbNails
|
import ThumbNails
|
||||||
import Utils
|
import Utils
|
||||||
from gen.lib import NoteType
|
from gen.lib import NoteType
|
||||||
|
from glade import Glade
|
||||||
from DisplayTabs import (SourceEmbedList, AttrEmbedList, MediaBackRefList,
|
from DisplayTabs import (SourceEmbedList, AttrEmbedList, MediaBackRefList,
|
||||||
NoteTab)
|
NoteTab)
|
||||||
from widgets import MonitoredSpinButton, MonitoredEntry, PrivacyButton
|
from widgets import MonitoredSpinButton, MonitoredEntry, PrivacyButton
|
||||||
from _EditReference import RefTab, EditReference
|
from _EditReference import RefTab, EditReference
|
||||||
from AddMedia import AddMediaObject
|
from AddMedia import AddMediaObject
|
||||||
_GLADE_FILE = 'editmediaref.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -74,11 +72,9 @@ class EditMediaRef(EditReference):
|
|||||||
def _local_init(self):
|
def _local_init(self):
|
||||||
self.width_key = Config.MEDIA_REF_WIDTH
|
self.width_key = Config.MEDIA_REF_WIDTH
|
||||||
self.height_key = Config.MEDIA_REF_HEIGHT
|
self.height_key = Config.MEDIA_REF_HEIGHT
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object('change_description'),
|
self.set_window(self.top.toplevel,
|
||||||
self.top.get_object('title'),
|
self.top.get_object('title'),
|
||||||
_('Media Reference Editor'))
|
_('Media Reference Editor'))
|
||||||
self.define_warn_box(self.top.get_object("warn_box"))
|
self.define_warn_box(self.top.get_object("warn_box"))
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -49,8 +48,7 @@ from gen.lib import NoteType
|
|||||||
from DisplayTabs import GrampsTab,SourceEmbedList,NoteTab
|
from DisplayTabs import GrampsTab,SourceEmbedList,NoteTab
|
||||||
from widgets import (MonitoredEntry, MonitoredMenu, MonitoredDate,
|
from widgets import (MonitoredEntry, MonitoredMenu, MonitoredDate,
|
||||||
MonitoredDataType, PrivacyButton)
|
MonitoredDataType, PrivacyButton)
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editname.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -111,11 +109,9 @@ class EditName(EditSecondary):
|
|||||||
self.width_key = Config.NAME_WIDTH
|
self.width_key = Config.NAME_WIDTH
|
||||||
self.height_key = Config.NAME_HEIGHT
|
self.height_key = Config.NAME_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("name_edit"),
|
self.set_window(self.top.toplevel,
|
||||||
self.top.get_object("title"),
|
self.top.get_object("title"),
|
||||||
_("Name Editor"))
|
_("Name Editor"))
|
||||||
|
|
||||||
|
@ -28,8 +28,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
import logging
|
import logging
|
||||||
_LOG = logging.getLogger(".Editors.EditNote")
|
_LOG = logging.getLogger(".Editors.EditNote")
|
||||||
|
|
||||||
@ -56,8 +54,7 @@ from widgets import (MonitoredDataType, MonitoredCheckbox,
|
|||||||
MonitoredEntry, PrivacyButton)
|
MonitoredEntry, PrivacyButton)
|
||||||
from gen.lib import Note
|
from gen.lib import Note
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editnote.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -170,11 +167,9 @@ class EditNote(EditPrimary):
|
|||||||
self.width_key = Config.NOTE_WIDTH
|
self.width_key = Config.NOTE_WIDTH
|
||||||
self.height_key = Config.NOTE_HEIGHT
|
self.height_key = Config.NOTE_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
win = self.top.get_object("edit_note")
|
win = self.top.toplevel
|
||||||
self.set_window(win, None, self.get_menu_title())
|
self.set_window(win, None, self.get_menu_title())
|
||||||
|
|
||||||
|
|
||||||
|
@ -53,7 +53,7 @@ import gen.lib
|
|||||||
import widgets
|
import widgets
|
||||||
from BasicUtils import name_displayer
|
from BasicUtils import name_displayer
|
||||||
import Errors
|
import Errors
|
||||||
|
from glade import Glade
|
||||||
from gen.utils import set_birth_death_index
|
from gen.utils import set_birth_death_index
|
||||||
|
|
||||||
from Editors._EditPrimary import EditPrimary
|
from Editors._EditPrimary import EditPrimary
|
||||||
@ -136,10 +136,9 @@ class EditPerson(EditPrimary):
|
|||||||
|
|
||||||
self.load_obj = None
|
self.load_obj = None
|
||||||
self.load_rect = None
|
self.load_rect = None
|
||||||
self.top = gtk.Builder()
|
self.top = Glade()
|
||||||
self.top.add_from_file(const.PERSON_GLADE)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("edit_person"), None,
|
self.set_window(self.top.toplevel, None,
|
||||||
self.get_menu_title())
|
self.get_menu_title())
|
||||||
|
|
||||||
self.obj_photo = self.top.get_object("personPix")
|
self.obj_photo = self.top.get_object("personPix")
|
||||||
|
@ -32,7 +32,6 @@ mechanism for the user to edit address information.
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -53,8 +52,7 @@ from _EditSecondary import EditSecondary
|
|||||||
from gen.lib import NoteType
|
from gen.lib import NoteType
|
||||||
from widgets import MonitoredEntry, PrivacyButton
|
from widgets import MonitoredEntry, PrivacyButton
|
||||||
from DisplayTabs import SourceEmbedList, NoteTab
|
from DisplayTabs import SourceEmbedList, NoteTab
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editpersonref.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -79,11 +77,9 @@ class EditPersonRef(EditSecondary):
|
|||||||
self.width_key = Config.PERSON_REF_WIDTH
|
self.width_key = Config.PERSON_REF_WIDTH
|
||||||
self.height_key = Config.PERSON_REF_HEIGHT
|
self.height_key = Config.PERSON_REF_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("pref_edit"),
|
self.set_window(self.top.toplevel,
|
||||||
self.top.get_object("title"),
|
self.top.get_object("title"),
|
||||||
_('Person Reference Editor'))
|
_('Person Reference Editor'))
|
||||||
self.person_label = self.top.get_object('person')
|
self.person_label = self.top.get_object('person')
|
||||||
|
@ -27,8 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
import logging
|
import logging
|
||||||
log = logging.getLogger(".")
|
log = logging.getLogger(".")
|
||||||
|
|
||||||
@ -54,8 +52,7 @@ from widgets import MonitoredEntry, PrivacyButton
|
|||||||
from Errors import ValidationError
|
from Errors import ValidationError
|
||||||
from PlaceUtils import conv_lat_lon
|
from PlaceUtils import conv_lat_lon
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editplace.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -119,11 +116,9 @@ class EditPlace(EditPrimary):
|
|||||||
self.width_key = Config.PLACE_WIDTH
|
self.width_key = Config.PLACE_WIDTH
|
||||||
self.height_key = Config.PLACE_HEIGHT
|
self.height_key = Config.PLACE_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object("place_editor"), None,
|
self.set_window(self.top.toplevel, None,
|
||||||
self.get_menu_title())
|
self.get_menu_title())
|
||||||
tblmloc = self.top.get_object('table19')
|
tblmloc = self.top.get_object('table19')
|
||||||
notebook = self.top.get_object('notebook3')
|
notebook = self.top.get_object('notebook3')
|
||||||
|
@ -27,14 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GTK/Gnome modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -49,8 +41,7 @@ from gen.lib import NoteType
|
|||||||
from DisplayTabs import NoteTab,AddrEmbedList,WebEmbedList,SourceBackRefList
|
from DisplayTabs import NoteTab,AddrEmbedList,WebEmbedList,SourceBackRefList
|
||||||
from widgets import MonitoredEntry, PrivacyButton, MonitoredDataType
|
from widgets import MonitoredEntry, PrivacyButton, MonitoredDataType
|
||||||
from _EditReference import RefTab, EditReference
|
from _EditReference import RefTab, EditReference
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editreporef.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -68,12 +59,8 @@ class EditRepoRef(EditReference):
|
|||||||
self.width_key = Config.REPO_REF_WIDTH
|
self.width_key = Config.REPO_REF_WIDTH
|
||||||
self.height_key = Config.REPO_REF_HEIGHT
|
self.height_key = Config.REPO_REF_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
self.set_window(self.top.toplevel,
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object('repository_ref_edit'),
|
|
||||||
self.top.get_object('repo_title'),
|
self.top.get_object('repo_title'),
|
||||||
_('Repository Reference Editor'))
|
_('Repository Reference Editor'))
|
||||||
|
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -49,8 +48,7 @@ from widgets import MonitoredEntry, MonitoredDataType, PrivacyButton
|
|||||||
from DisplayTabs import AddrEmbedList, WebEmbedList, NoteTab, SourceBackRefList
|
from DisplayTabs import AddrEmbedList, WebEmbedList, NoteTab, SourceBackRefList
|
||||||
from Editors._EditPrimary import EditPrimary
|
from Editors._EditPrimary import EditPrimary
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editrepository.glade'
|
|
||||||
|
|
||||||
class EditRepository(EditPrimary):
|
class EditRepository(EditPrimary):
|
||||||
|
|
||||||
@ -78,11 +76,9 @@ class EditRepository(EditPrimary):
|
|||||||
self.width_key = Config.REPO_WIDTH
|
self.width_key = Config.REPO_WIDTH
|
||||||
self.height_key = Config.REPO_HEIGHT
|
self.height_key = Config.REPO_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade()
|
||||||
self.glade = gtk.Builder()
|
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.glade.get_object("repository_editor"), None,
|
self.set_window(self.glade.toplevel, None,
|
||||||
self.get_menu_title())
|
self.get_menu_title())
|
||||||
|
|
||||||
def build_menu_names(self, source):
|
def build_menu_names(self, source):
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
import logging
|
import logging
|
||||||
log = logging.getLogger(".")
|
log = logging.getLogger(".")
|
||||||
|
|
||||||
@ -52,13 +51,13 @@ from DisplayTabs import (NoteTab, GalleryTab, DataEmbedList,
|
|||||||
SourceBackRefList, RepoEmbedList)
|
SourceBackRefList, RepoEmbedList)
|
||||||
from widgets import MonitoredEntry, PrivacyButton
|
from widgets import MonitoredEntry, PrivacyButton
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Constants
|
# EditSource class
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
_GLADE_FILE = "editsource.glade"
|
|
||||||
|
|
||||||
class EditSource(EditPrimary):
|
class EditSource(EditPrimary):
|
||||||
|
|
||||||
@ -84,11 +83,8 @@ class EditSource(EditPrimary):
|
|||||||
self.height_key = Config.SOURCE_HEIGHT
|
self.height_key = Config.SOURCE_HEIGHT
|
||||||
assert(self.obj)
|
assert(self.obj)
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade()
|
||||||
self.glade = gtk.Builder()
|
self.set_window(self.glade.toplevel, None,
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.glade.get_object("source_editor"), None,
|
|
||||||
self.get_menu_title())
|
self.get_menu_title())
|
||||||
|
|
||||||
def _connect_signals(self):
|
def _connect_signals(self):
|
||||||
|
@ -27,14 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GTK/Gnome modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -44,15 +36,13 @@ import gtk
|
|||||||
import const
|
import const
|
||||||
import Config
|
import Config
|
||||||
import gen.lib
|
import gen.lib
|
||||||
|
from glade import Glade
|
||||||
from DisplayTabs import (NoteTab, GalleryTab, SourceBackRefList,
|
from DisplayTabs import (NoteTab, GalleryTab, SourceBackRefList,
|
||||||
DataEmbedList, RepoEmbedList)
|
DataEmbedList, RepoEmbedList)
|
||||||
from widgets import (PrivacyButton, MonitoredEntry, MonitoredMenu,
|
from widgets import (PrivacyButton, MonitoredEntry, MonitoredMenu,
|
||||||
MonitoredDate)
|
MonitoredDate)
|
||||||
from _EditReference import RefTab, EditReference
|
from _EditReference import RefTab, EditReference
|
||||||
|
|
||||||
_GLADE_FILE = 'editsourceref.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# EditSourceRef class
|
# EditSourceRef class
|
||||||
@ -69,11 +59,9 @@ class EditSourceRef(EditReference):
|
|||||||
self.width_key = Config.EVENT_REF_WIDTH
|
self.width_key = Config.EVENT_REF_WIDTH
|
||||||
self.height_key = Config.EVENT_REF_HEIGHT
|
self.height_key = Config.EVENT_REF_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.set_window(self.top.get_object('source_ref_edit'),
|
self.set_window(self.top.toplevel,
|
||||||
self.top.get_object('source_title'),
|
self.top.get_object('source_title'),
|
||||||
_('Source Reference Editor'))
|
_('Source Reference Editor'))
|
||||||
|
|
||||||
|
@ -27,14 +27,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GTK/Gnome modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -45,8 +37,7 @@ import const
|
|||||||
import Config
|
import Config
|
||||||
from _EditSecondary import EditSecondary
|
from _EditSecondary import EditSecondary
|
||||||
from widgets import MonitoredEntry, PrivacyButton, MonitoredDataType
|
from widgets import MonitoredEntry, PrivacyButton, MonitoredDataType
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'editurl.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -64,13 +55,10 @@ class EditUrl(EditSecondary):
|
|||||||
self.width_key = Config.URL_WIDTH
|
self.width_key = Config.URL_WIDTH
|
||||||
self.height_key = Config.URL_HEIGHT
|
self.height_key = Config.URL_HEIGHT
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade()
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.jump = self.top.get_object('jump')
|
self.jump = self.top.get_object('jump')
|
||||||
|
|
||||||
self.set_window(self.top.get_object("url_edit"),
|
self.set_window(self.top.toplevel,
|
||||||
self.top.get_object("title"),
|
self.top.get_object("title"),
|
||||||
_('Internet Address Editor'))
|
_('Internet Address Editor'))
|
||||||
|
|
||||||
|
@ -54,6 +54,7 @@ import ManagedWindow
|
|||||||
from widgets import MarkupLabel, BasicLabel
|
from widgets import MarkupLabel, BasicLabel
|
||||||
from QuestionDialog import ErrorDialog, QuestionDialog2
|
from QuestionDialog import ErrorDialog, QuestionDialog2
|
||||||
from Errors import NameDisplayError
|
from Errors import NameDisplayError
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
geopresent = True
|
geopresent = True
|
||||||
try:
|
try:
|
||||||
@ -69,7 +70,6 @@ if not const.VERSION.find('SVN') == -1:
|
|||||||
# Constants
|
# Constants
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
_GLADE_FILE = 'grampscfg.glade'
|
|
||||||
|
|
||||||
_surname_styles = [
|
_surname_styles = [
|
||||||
_("Father's surname"),
|
_("Father's surname"),
|
||||||
@ -1107,10 +1107,7 @@ class NameFormatEditDlg:
|
|||||||
self.fmt_str = fmt_str
|
self.fmt_str = fmt_str
|
||||||
self.name = name
|
self.name = name
|
||||||
self.valid = True
|
self.valid = True
|
||||||
print "here"
|
self.top = Glade()
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.dlg = self.top.get_object('namefmt_edit')
|
self.dlg = self.top.get_object('namefmt_edit')
|
||||||
ManagedWindow.set_titles(self.dlg, None, _('Name Format Editor'))
|
ManagedWindow.set_titles(self.dlg, None, _('Name Format Editor'))
|
||||||
|
@ -48,6 +48,7 @@ import gtk
|
|||||||
import const
|
import const
|
||||||
import Errors
|
import Errors
|
||||||
import Config
|
import Config
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
|
@ -43,6 +43,7 @@ from QuestionDialog import ErrorDialog
|
|||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
import gen.utils
|
import gen.utils
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -51,6 +52,7 @@ import gen.utils
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_3' % const.URL_MANUAL_PAGE
|
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_3' % const.URL_MANUAL_PAGE
|
||||||
WIKI_HELP_SEC = _('manual|Merge_People')
|
WIKI_HELP_SEC = _('manual|Merge_People')
|
||||||
|
_GLADE_FILE = 'mergedata.glade'
|
||||||
|
|
||||||
sex = ( _("female"), _("male"), _("unknown"))
|
sex = ( _("female"), _("male"), _("unknown"))
|
||||||
|
|
||||||
@ -59,10 +61,9 @@ class PersonCompare(ManagedWindow.ManagedWindow):
|
|||||||
def __init__(self, dbstate, uistate, person1, person2, update=None) :
|
def __init__(self, dbstate, uistate, person1, person2, update=None) :
|
||||||
|
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self.__class__)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self.__class__)
|
||||||
|
self.glade = Glade(_GLADE_FILE, toplevel='mergedata')
|
||||||
|
window = self.glade.toplevel
|
||||||
|
|
||||||
self.glade = gtk.Builder()
|
|
||||||
self.glade.add_from_file(const.MERGE_GLADE)
|
|
||||||
window = self.glade.get_object('merge')
|
|
||||||
window.show()
|
window.show()
|
||||||
self.text1 = self.glade.get_object('text1')
|
self.text1 = self.glade.get_object('text1')
|
||||||
self.text2 = self.glade.get_object('text2')
|
self.text2 = self.glade.get_object('text2')
|
||||||
@ -284,9 +285,9 @@ class MergePeopleUI(ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self.__class__)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self.__class__)
|
||||||
|
|
||||||
glade_xml = gtk.Builder()
|
|
||||||
glade_xml.add_from_file(const.MERGE_GLADE)
|
glade_xml = Glade(_GLADE_FILE, toplevel='mergeperson')
|
||||||
window = glade_xml.get_object('merge_people')
|
window = glade_xml.toplevel
|
||||||
|
|
||||||
self.set_window(window, glade_xml.get_object('people_title'), _("Merge People"))
|
self.set_window(window, glade_xml.get_object('people_title'), _("Merge People"))
|
||||||
|
|
||||||
|
@ -44,6 +44,8 @@ from TransUtils import sgettext as _
|
|||||||
import const
|
import const
|
||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# GRAMPS constants
|
# GRAMPS constants
|
||||||
@ -51,6 +53,7 @@ import ManagedWindow
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_3' % const.URL_MANUAL_PAGE
|
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_3' % const.URL_MANUAL_PAGE
|
||||||
WIKI_HELP_SEC = _('manual|Merge_Places')
|
WIKI_HELP_SEC = _('manual|Merge_Places')
|
||||||
|
_GLADE_FILE = 'mergedata.glade'
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -72,9 +75,8 @@ class MergePlaces(ManagedWindow.ManagedWindow):
|
|||||||
self.p1 = self.db.get_place_from_handle(self.new_handle)
|
self.p1 = self.db.get_place_from_handle(self.new_handle)
|
||||||
self.p2 = self.db.get_place_from_handle(self.old_handle)
|
self.p2 = self.db.get_place_from_handle(self.old_handle)
|
||||||
|
|
||||||
self.glade = gtk.Builder()
|
self.glade = Glade(_GLADE_FILE, toplevel='mergeplace')
|
||||||
self.glade.add_from_file(const.MERGE_GLADE)
|
self.set_window(self.glade.toplevel,
|
||||||
self.set_window(self.glade.get_object('merge_places'),
|
|
||||||
self.glade.get_object('place_title'),
|
self.glade.get_object('place_title'),
|
||||||
_("Merge Places"))
|
_("Merge Places"))
|
||||||
|
|
||||||
|
@ -42,6 +42,7 @@ from TransUtils import sgettext as _
|
|||||||
import const
|
import const
|
||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -50,6 +51,7 @@ import ManagedWindow
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_3' % const.URL_MANUAL_PAGE
|
WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_3' % const.URL_MANUAL_PAGE
|
||||||
WIKI_HELP_SEC = _('manual|Merge_Sources')
|
WIKI_HELP_SEC = _('manual|Merge_Sources')
|
||||||
|
_GLADE_FILE = 'mergedata.glade'
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -72,10 +74,9 @@ class MergeSources(ManagedWindow.ManagedWindow):
|
|||||||
self.s1 = self.db.get_source_from_handle(self.new_handle)
|
self.s1 = self.db.get_source_from_handle(self.new_handle)
|
||||||
self.s2 = self.db.get_source_from_handle(self.old_handle)
|
self.s2 = self.db.get_source_from_handle(self.old_handle)
|
||||||
|
|
||||||
self.glade = gtk.Builder()
|
self.glade = Glade(_GLADE_FILE, toplevel='mergesource')
|
||||||
self.glade.add_from_file(const.MERGE_GLADE)
|
|
||||||
|
|
||||||
self.set_window(self.glade.get_object('merge_sources'),
|
self.set_window(self.glade.toplevel,
|
||||||
self.glade.get_object('source_title'),
|
self.glade.get_object('source_title'),
|
||||||
_("Merge Sources"))
|
_("Merge Sources"))
|
||||||
|
|
||||||
|
@ -43,8 +43,7 @@ from gtk.gdk import pixbuf_new_from_file
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import const
|
import const
|
||||||
import Config
|
import Config
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'questiondialog.glade'
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
ICON = pixbuf_new_from_file(const.ICON)
|
ICON = pixbuf_new_from_file(const.ICON)
|
||||||
@ -53,11 +52,9 @@ except:
|
|||||||
|
|
||||||
class SaveDialog:
|
class SaveDialog:
|
||||||
def __init__(self,msg1,msg2,task1,task2,parent=None):
|
def __init__(self,msg1,msg2,task1,task2,parent=None):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade(toplevel='savedialog')
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top = self.xml.get_object('savedialog')
|
self.top = self.xml.toplevel
|
||||||
self.top.set_icon(ICON)
|
self.top.set_icon(ICON)
|
||||||
self.top.set_title("%s - GRAMPS" % msg1)
|
self.top.set_title("%s - GRAMPS" % msg1)
|
||||||
|
|
||||||
@ -86,11 +83,9 @@ class SaveDialog:
|
|||||||
|
|
||||||
class QuestionDialog:
|
class QuestionDialog:
|
||||||
def __init__(self,msg1,msg2,label,task,parent=None):
|
def __init__(self,msg1,msg2,label,task,parent=None):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade(toplevel='questiondialog')
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top = self.xml.get_object('questiondialog')
|
self.top = self.xml.toplevel
|
||||||
self.top.set_icon(ICON)
|
self.top.set_icon(ICON)
|
||||||
self.top.set_title("%s - GRAMPS" % msg1)
|
self.top.set_title("%s - GRAMPS" % msg1)
|
||||||
|
|
||||||
@ -114,11 +109,9 @@ class QuestionDialog:
|
|||||||
|
|
||||||
class QuestionDialog2:
|
class QuestionDialog2:
|
||||||
def __init__(self,msg1,msg2,label_msg1,label_msg2,parent=None):
|
def __init__(self,msg1,msg2,label_msg1,label_msg2,parent=None):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade(toplevel='questiondialog')
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top = self.xml.get_object('questiondialog')
|
self.top = self.xml.toplevel
|
||||||
self.top.set_icon(ICON)
|
self.top.set_icon(ICON)
|
||||||
self.top.set_title("%s - GRAMPS" % msg1)
|
self.top.set_title("%s - GRAMPS" % msg1)
|
||||||
|
|
||||||
@ -146,11 +139,9 @@ class QuestionDialog2:
|
|||||||
|
|
||||||
class OptionDialog:
|
class OptionDialog:
|
||||||
def __init__(self,msg1,msg2,btnmsg1,task1,btnmsg2,task2,parent=None):
|
def __init__(self,msg1,msg2,btnmsg1,task1,btnmsg2,task2,parent=None):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade(toplevel='optiondialog')
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top = self.xml.get_object('optiondialog')
|
self.top = self.xml.toplevel
|
||||||
self.top.set_icon(ICON)
|
self.top.set_icon(ICON)
|
||||||
self.top.set_title("%s - GRAMPS" % msg1)
|
self.top.set_title("%s - GRAMPS" % msg1)
|
||||||
|
|
||||||
@ -250,11 +241,9 @@ class InfoDialog:
|
|||||||
Dialog to show selectable info in a scrolled window
|
Dialog to show selectable info in a scrolled window
|
||||||
"""
|
"""
|
||||||
def __init__(self, msg1, infotext, parent=None):
|
def __init__(self, msg1, infotext, parent=None):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade(toplevel='infodialog')
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top = self.xml.get_object('infodialog')
|
self.top = self.xml.toplevel
|
||||||
self.top.set_icon(ICON)
|
self.top.set_icon(ICON)
|
||||||
self.top.set_title("%s - GRAMPS" % msg1)
|
self.top.set_title("%s - GRAMPS" % msg1)
|
||||||
|
|
||||||
@ -279,11 +268,9 @@ class InfoDialog:
|
|||||||
|
|
||||||
class MissingMediaDialog:
|
class MissingMediaDialog:
|
||||||
def __init__(self,msg1,msg2,task1,task2,task3,parent=None):
|
def __init__(self,msg1,msg2,task1,task2,task3,parent=None):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade(toplevel='missmediadialog')
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top = self.xml.get_object('missmediadialog')
|
self.top = self.xml.toplevel
|
||||||
self.top.set_icon(ICON)
|
self.top.set_icon(ICON)
|
||||||
self.top.set_title("%s - GRAMPS" % msg1)
|
self.top.set_title("%s - GRAMPS" % msg1)
|
||||||
|
|
||||||
@ -336,11 +323,9 @@ class MissingMediaDialog:
|
|||||||
class MessageHideDialog:
|
class MessageHideDialog:
|
||||||
|
|
||||||
def __init__(self, title, message, key, parent=None):
|
def __init__(self, title, message, key, parent=None):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.xml = Glade(toplevel='hidedialog')
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
top = self.xml.get_object('hide_dialog')
|
self.top = self.xml.toplevel
|
||||||
top.set_icon(ICON)
|
top.set_icon(ICON)
|
||||||
top.set_title("%s - GRAMPS" % title)
|
top.set_title("%s - GRAMPS" % title)
|
||||||
|
|
||||||
|
@ -20,26 +20,20 @@
|
|||||||
|
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
import gtk
|
|
||||||
import os
|
|
||||||
|
|
||||||
import const
|
import const
|
||||||
|
|
||||||
from BasicUtils import name_displayer
|
from BasicUtils import name_displayer
|
||||||
import ListModel
|
import ListModel
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
PARENT_TITLES = [(_('Father'), -1, 200), (_('Mother'), -1, 200), ('', -1, 0)]
|
PARENT_TITLES = [(_('Father'), -1, 200), (_('Mother'), -1, 200), ('', -1, 0)]
|
||||||
FAMILY_TITLES = [(_('Spouse'), -1, 200), (_('Relationship'), -1, 200), ('', -1, 0)]
|
FAMILY_TITLES = [(_('Spouse'), -1, 200), (_('Relationship'), -1, 200), ('', -1, 0)]
|
||||||
_GLADE_FILE = 'reorder.glade'
|
|
||||||
|
|
||||||
class Reorder(ManagedWindow.ManagedWindow):
|
class Reorder(ManagedWindow.ManagedWindow):
|
||||||
|
|
||||||
def __init__(self, state, uistate, track, handle):
|
def __init__(self, state, uistate, track, handle):
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
xml = Glade()
|
||||||
xml = gtk.Builder()
|
top = xml.toplevel
|
||||||
xml.add_from_file(glade_file)
|
|
||||||
top = xml.get_object('reorder')
|
|
||||||
|
|
||||||
self.dbstate = state
|
self.dbstate = state
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, track, self)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, track, self)
|
||||||
|
@ -26,7 +26,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -44,6 +43,7 @@ import gobject
|
|||||||
import BaseDoc
|
import BaseDoc
|
||||||
import const
|
import const
|
||||||
import Utils
|
import Utils
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -61,7 +61,7 @@ except:
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
paper_sizes = []
|
paper_sizes = []
|
||||||
_GLADE_FILE = "paper_settings.glade"
|
_GLADE_FILE = "papermenu.glade"
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -147,9 +147,7 @@ class PaperFrame(gtk.HBox):
|
|||||||
def __init__(self,default_metric,default_name,default_orientation,
|
def __init__(self,default_metric,default_name,default_orientation,
|
||||||
margins=[2.54,2.54,2.54,2.54], custom=[29.7,21.0]):
|
margins=[2.54,2.54,2.54,2.54], custom=[29.7,21.0]):
|
||||||
gtk.HBox.__init__(self)
|
gtk.HBox.__init__(self)
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
glade_xml = Glade()
|
||||||
glade_xml = gtk.Builder()
|
|
||||||
glade_xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.paper_table = glade_xml.get_object('paper_table')
|
self.paper_table = glade_xml.get_object('paper_table')
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ Paragraph/Font style editor
|
|||||||
#
|
#
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
import os
|
|
||||||
import logging
|
import logging
|
||||||
log = logging.getLogger(".")
|
log = logging.getLogger(".")
|
||||||
|
|
||||||
@ -54,6 +53,7 @@ import const
|
|||||||
import BaseDoc
|
import BaseDoc
|
||||||
import ListModel
|
import ListModel
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -85,11 +85,8 @@ class StyleListDisplay:
|
|||||||
|
|
||||||
self.sheetlist = stylesheetlist
|
self.sheetlist = stylesheetlist
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade(toplevel='styles')
|
||||||
self.top = gtk.Builder()
|
self.window = self.top.toplevel
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.window = self.top.get_object('styles')
|
|
||||||
|
|
||||||
ManagedWindow.set_titles( self.window,
|
ManagedWindow.set_titles( self.window,
|
||||||
self.top.get_object('title'),
|
self.top.get_object('title'),
|
||||||
@ -201,16 +198,14 @@ class StyleEditor:
|
|||||||
|
|
||||||
self.style = BaseDoc.StyleSheet(style)
|
self.style = BaseDoc.StyleSheet(style)
|
||||||
self.parent = parent
|
self.parent = parent
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.top = Glade(toplevel='editor')
|
||||||
self.top = gtk.Builder()
|
self.window = self.top.toplevel
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.top.connect_signals({
|
self.top.connect_signals({
|
||||||
"on_save_style_clicked" : self.on_save_style_clicked,
|
"on_save_style_clicked" : self.on_save_style_clicked,
|
||||||
"destroy_passed_object" : self.__close,
|
"destroy_passed_object" : self.__close,
|
||||||
})
|
})
|
||||||
|
|
||||||
self.window = self.top.get_object("editor")
|
|
||||||
self.pname = self.top.get_object('pname')
|
self.pname = self.top.get_object('pname')
|
||||||
self.pdescription = self.top.get_object('pdescription')
|
self.pdescription = self.top.get_object('pdescription')
|
||||||
|
|
||||||
|
@ -57,7 +57,7 @@ import DateHandler
|
|||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
|
from glade import Glade
|
||||||
from DdTargets import DdTargets
|
from DdTargets import DdTargets
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
@ -1200,11 +1200,9 @@ class ScratchPadWindow(ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
self.width_key = Config.CLIPBOARD_WIDTH
|
self.width_key = Config.CLIPBOARD_WIDTH
|
||||||
self.height_key = Config.CLIPBOARD_HEIGHT
|
self.height_key = Config.CLIPBOARD_HEIGHT
|
||||||
self.glade_file = os.path.join(const.GLADE_DIR, "scratchpad.glade")
|
|
||||||
self.top = gtk.Builder()
|
self.top = Glade()
|
||||||
self.top.add_from_file(self.glade_file)
|
self.set_window(self.top.toplevel, None, None, msg=_("Clipboard"))
|
||||||
self.set_window(self.top.get_object("scratch_pad"),
|
|
||||||
None, None, msg=_("Clipboard"))
|
|
||||||
self._set_size()
|
self._set_size()
|
||||||
|
|
||||||
self.clear_all_btn = self.top.get_object("btn_clear_all")
|
self.clear_all_btn = self.top.get_object("btn_clear_all")
|
||||||
|
@ -28,7 +28,6 @@
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import gtk
|
import gtk
|
||||||
import pango
|
import pango
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -39,8 +38,7 @@ import const
|
|||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from Filters import SearchBar
|
from Filters import SearchBar
|
||||||
from DisplayModels import PeopleModel
|
from DisplayModels import PeopleModel
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'baseselector.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -77,11 +75,9 @@ class BaseSelector(ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
self.db = dbstate.db
|
self.db = dbstate.db
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
self.glade = Glade()
|
||||||
self.glade = gtk.Builder()
|
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
window = self.glade.get_object('select_person')
|
window = self.glade.toplevel
|
||||||
self.showall = self.glade.get_object('showall')
|
self.showall = self.glade.get_object('showall')
|
||||||
title_label = self.glade.get_object('title')
|
title_label = self.glade.get_object('title')
|
||||||
vbox = self.glade.get_object('select_person_vbox')
|
vbox = self.glade.get_object('select_person_vbox')
|
||||||
|
@ -39,7 +39,6 @@ import os
|
|||||||
# GTK/GNOME modules
|
# GTK/GNOME modules
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import gtk
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -50,8 +49,7 @@ import const
|
|||||||
import Config
|
import Config
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
|
from glade import Glade
|
||||||
_GLADE_FILE = 'tipofday.glade'
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -63,11 +61,8 @@ class TipOfDay(ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
||||||
|
|
||||||
glade_file = os.path.join(const.GLADE_DIR, _GLADE_FILE)
|
xml = Glade()
|
||||||
xml = gtk.Builder()
|
window = xml.toplevel
|
||||||
xml.add_from_file(glade_file)
|
|
||||||
|
|
||||||
window = xml.get_object("tod_window")
|
|
||||||
self.set_window(window,
|
self.set_window(window,
|
||||||
xml.get_object("title"),
|
xml.get_object("title"),
|
||||||
_("Tip of the Day"),
|
_("Tip of the Day"),
|
||||||
|
221
src/glade.py
Normal file
221
src/glade.py
Normal file
@ -0,0 +1,221 @@
|
|||||||
|
#
|
||||||
|
# Gramps - a GTK+/GNOME based genealogy program
|
||||||
|
#
|
||||||
|
# Copyright (C) 2009 Gerald Britton <gerald.britton@gmail.com>
|
||||||
|
#
|
||||||
|
# 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
|
||||||
|
# the Free Software Foundation; either version 2 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program; if not, write to the Free Software
|
||||||
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
#
|
||||||
|
|
||||||
|
# $Id: glade.py 10874 2009-03-03 18:00:00Z gbritton $
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# Glade
|
||||||
|
#
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
|
||||||
|
"""
|
||||||
|
Glade file operations
|
||||||
|
|
||||||
|
This module exports the Glade class.
|
||||||
|
|
||||||
|
"""
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# Python modules
|
||||||
|
#
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
import sys
|
||||||
|
import os
|
||||||
|
import gtk
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# gramps modules
|
||||||
|
#
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
import const
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# Glade class. Derived from gtk.Builder
|
||||||
|
#
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
|
||||||
|
class Glade(gtk.Builder):
|
||||||
|
"""
|
||||||
|
Glade class: Manage glade files as gtk.Builder objects
|
||||||
|
"""
|
||||||
|
__slots__ = ['__toplevel', '__filename', '__dirname']
|
||||||
|
|
||||||
|
def __init__(self, filename=None, dirname=None, toplevel=None):
|
||||||
|
"""
|
||||||
|
Class Constructor: Returns a new instance of the Glade class
|
||||||
|
|
||||||
|
@type filename: string
|
||||||
|
@param filename: The name of the glade file to be used. Defaults to None
|
||||||
|
@type dirname: string
|
||||||
|
@param dirname: The directory to search for the glade file. Defaults to
|
||||||
|
None which will cause a search for the file in the default
|
||||||
|
directory followed by the directory of the calling module.
|
||||||
|
@type toplevel: toplevel
|
||||||
|
@param toplevel: The toplevel object to search for in the glade file.
|
||||||
|
Defaults to None, which will cause a search for a toplevel
|
||||||
|
matching the file name.
|
||||||
|
@rtype: object reference
|
||||||
|
@return: reference to the newly-created Glade instance
|
||||||
|
"""
|
||||||
|
gtk.Builder.__init__(self)
|
||||||
|
|
||||||
|
if isinstance(toplevel, gtk.Container): # if we have a Gtk object
|
||||||
|
self.__toplevel = toplevel # just remember it
|
||||||
|
return # and we're done
|
||||||
|
|
||||||
|
filename_given = filename is not None
|
||||||
|
dirname_given = dirname is not None
|
||||||
|
|
||||||
|
# if filename not given, use module name to derive it
|
||||||
|
|
||||||
|
if not filename:
|
||||||
|
filename = sys._getframe(1).f_code.co_filename
|
||||||
|
filename = os.path.basename(filename)
|
||||||
|
filename = filename.rpartition('.')[0] + '.glade'
|
||||||
|
filename = filename.lstrip('_').lower()
|
||||||
|
|
||||||
|
# if dirname not given, use current directory
|
||||||
|
|
||||||
|
if not dirname:
|
||||||
|
dirname = sys._getframe(1).f_code.co_filename
|
||||||
|
dirname = os.path.dirname(dirname)
|
||||||
|
|
||||||
|
# try to find the glade file
|
||||||
|
|
||||||
|
if filename_given and dirname_given: # both given -- use them
|
||||||
|
path = os.path.join(dirname, filename)
|
||||||
|
|
||||||
|
elif filename_given: # try default directory first
|
||||||
|
path = os.path.join(const.GLADE_DIR, filename)
|
||||||
|
if not os.path.exists(path): # then module directory
|
||||||
|
path = os.path.join(dirname, filename)
|
||||||
|
|
||||||
|
elif dirname_given: # dirname given -- use it
|
||||||
|
path = os.path.join(dirname, filename)
|
||||||
|
|
||||||
|
# neither filename nor dirname given. Try:
|
||||||
|
# 1. derived filename in default directory
|
||||||
|
# 2. derived filename in module directory
|
||||||
|
|
||||||
|
else:
|
||||||
|
path = os.path.join(const.GLADE_DIR, filename)
|
||||||
|
if not os.path.exists(path):
|
||||||
|
path = os.path.join(dirname, filename)
|
||||||
|
|
||||||
|
# try to build Gtk objects from glade file. Let exceptions happen
|
||||||
|
|
||||||
|
self.add_from_file(path)
|
||||||
|
self.__filename, self.__dirname = os.path.split(path)
|
||||||
|
|
||||||
|
# try to find the toplevel widget
|
||||||
|
|
||||||
|
if toplevel: # toplevel is given
|
||||||
|
self.__toplevel = self.get_object(toplevel)
|
||||||
|
else: # toplevel not given
|
||||||
|
# first, use filename as possible toplevel widget name
|
||||||
|
self.__toplevel = self.get_object(filename.rpartition('.')[0])
|
||||||
|
|
||||||
|
# next try lowercase filename as possible widget name
|
||||||
|
if not self.__toplevel:
|
||||||
|
self.__toplevel = self.get_object(
|
||||||
|
filename.rpartition('.')[0].lower())
|
||||||
|
|
||||||
|
if not self.__toplevel:
|
||||||
|
# if no match found, search for first toplevel widget
|
||||||
|
for obj in self.get_objects():
|
||||||
|
if hasattr(obj, 'get_toplevel'):
|
||||||
|
self.__toplevel = obj.get_toplevel()
|
||||||
|
break
|
||||||
|
else:
|
||||||
|
self.__toplevel = None
|
||||||
|
|
||||||
|
def __get_filename(self):
|
||||||
|
"""
|
||||||
|
__get_filename: return filename of glade file
|
||||||
|
@rtype: string
|
||||||
|
@return: filename of glade file
|
||||||
|
"""
|
||||||
|
return self.__filename
|
||||||
|
|
||||||
|
filename = property(__get_filename)
|
||||||
|
|
||||||
|
def __get_dirname(self):
|
||||||
|
"""
|
||||||
|
__get_dirname: return directory where glade file found
|
||||||
|
@rtype: string
|
||||||
|
@return: directory where glade file found
|
||||||
|
"""
|
||||||
|
return self.__dirname
|
||||||
|
|
||||||
|
dirname = property(__get_dirname)
|
||||||
|
|
||||||
|
def __get_toplevel(self):
|
||||||
|
"""
|
||||||
|
__get_toplevel: return toplevel object
|
||||||
|
@rtype: object
|
||||||
|
@return: toplevel object
|
||||||
|
"""
|
||||||
|
return self.__toplevel
|
||||||
|
|
||||||
|
def __set_toplevel(self, toplevel):
|
||||||
|
"""
|
||||||
|
__set_toplevel: set toplevel object
|
||||||
|
|
||||||
|
@type toplevel: string
|
||||||
|
@param toplevel: The name of the toplevel object to use
|
||||||
|
"""
|
||||||
|
self.__toplevel = self.get_object(toplevel)
|
||||||
|
|
||||||
|
toplevel = property(__get_toplevel, __set_toplevel)
|
||||||
|
|
||||||
|
def get_child_object(self, value, toplevel=None):
|
||||||
|
"""
|
||||||
|
get_child_object: search for a child object, by name, within a given
|
||||||
|
toplevel. If no toplevel argument is supplied, use
|
||||||
|
the toplevel attribute for this instance
|
||||||
|
@type value: string
|
||||||
|
@param value: The name of the child object to find
|
||||||
|
@type toplevel: string
|
||||||
|
@param toplevel: The name of the toplevel object to us
|
||||||
|
@rtype: object
|
||||||
|
@return: child object
|
||||||
|
"""
|
||||||
|
|
||||||
|
if not toplevel:
|
||||||
|
toplevel = self.__toplevel
|
||||||
|
if not toplevel:
|
||||||
|
raise ValueError, "Top level object required"
|
||||||
|
|
||||||
|
if isinstance(toplevel, basestring):
|
||||||
|
toplevel = self.get_object(toplevel)
|
||||||
|
|
||||||
|
queue = [toplevel]
|
||||||
|
while queue:
|
||||||
|
obj = queue.pop(0)
|
||||||
|
if obj.get_name() == value:
|
||||||
|
return obj
|
||||||
|
if hasattr(obj, 'get_children'):
|
||||||
|
queue += obj.get_children()
|
||||||
|
else:
|
||||||
|
return None
|
@ -5,14 +5,13 @@ pkgdatadir = $(datadir)/@PACKAGE@/glade
|
|||||||
|
|
||||||
dist_pkgdata_DATA = \
|
dist_pkgdata_DATA = \
|
||||||
gramps.glade\
|
gramps.glade\
|
||||||
edit_person.glade\
|
editperson.glade\
|
||||||
mergedata.glade\
|
mergedata.glade\
|
||||||
plugins.glade\
|
plugins.glade\
|
||||||
rule.glade\
|
rule.glade\
|
||||||
scratchpad.glade\
|
scratchpad.glade\
|
||||||
paper_settings.glade \
|
papermenu.glade \
|
||||||
grampletview.glade \
|
grampletview.glade \
|
||||||
gramps.glade \
|
|
||||||
baseselector.glade \
|
baseselector.glade \
|
||||||
reorder.glade \
|
reorder.glade \
|
||||||
tipofday.glade \
|
tipofday.glade \
|
||||||
@ -36,13 +35,10 @@ dist_pkgdata_DATA = \
|
|||||||
editaddress.glade \
|
editaddress.glade \
|
||||||
editmedia.glade \
|
editmedia.glade \
|
||||||
editmediaref.glade \
|
editmediaref.glade \
|
||||||
editaddress.glade \
|
|
||||||
editeventref.glade \
|
editeventref.glade \
|
||||||
editldsord.glade \
|
editldsord.glade \
|
||||||
editmedia.glade \
|
|
||||||
editnote.glade \
|
editnote.glade \
|
||||||
editplace.glade \
|
editplace.glade \
|
||||||
editsourceref.glade \
|
editsourceref.glade \
|
||||||
editname.glade \
|
editname.glade \
|
||||||
editevent.glade \
|
editevent.glade
|
||||||
editurl.glade
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="imageSelect">
|
<object class="GtkDialog" id="addmedia">
|
||||||
<property name="default_width">650</property>
|
<property name="default_width">650</property>
|
||||||
<property name="default_height">450</property>
|
<property name="default_height">450</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="select_person">
|
<object class="GtkDialog" id="baseselector">
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="window_position">center-on-parent</property>
|
<property name="window_position">center-on-parent</property>
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="columns">
|
<object class="GtkDialog" id="columnorder">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
<property name="step_increment">1</property>
|
<property name="step_increment">1</property>
|
||||||
<property name="page_increment">10</property>
|
<property name="page_increment">10</property>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="date_edit">
|
<object class="GtkDialog" id="dateedit">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -287,7 +287,6 @@
|
|||||||
</action-widgets>
|
</action-widgets>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="comment">
|
<object class="GtkDialog" id="comment">
|
||||||
<property name="visible">False</property>
|
|
||||||
<property name="title" translatable="yes">Revision comment - GRAMPS</property>
|
<property name="title" translatable="yes">Revision comment - GRAMPS</property>
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="window_position">center-on-parent</property>
|
<property name="window_position">center-on-parent</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="scrollmsg">
|
<object class="GtkDialog" id="displaystate">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="title" translatable="yes">GRAMPS</property>
|
<property name="title" translatable="yes">GRAMPS</property>
|
||||||
<property name="window_position">center-always</property>
|
<property name="window_position">center-always</property>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="addr_edit">
|
<object class="GtkDialog" id="editaddress">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="attr_edit">
|
<object class="GtkDialog" id="editattribute">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="cref_edit">
|
<object class="GtkDialog" id="editchildref">
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
<property name="default_height">400</property>
|
<property name="default_height">400</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="event_edit">
|
<object class="GtkDialog" id="editevent">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="event_eref_edit">
|
<object class="GtkDialog" id="editeventref">
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="family_editor">
|
<object class="GtkDialog" id="editfamily">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="lds_person_edit">
|
<object class="GtkDialog" id="editldsord">
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
<property name="default_height">450</property>
|
<property name="default_height">450</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
@ -403,19 +403,19 @@
|
|||||||
</object>
|
</object>
|
||||||
<object class="GtkListStore" id="liststore1">
|
<object class="GtkListStore" id="liststore1">
|
||||||
<columns>
|
<columns>
|
||||||
<!-- column-name item text -->
|
<!-- column-name item -->
|
||||||
<column type="gchararray"/>
|
<column type="gchararray"/>
|
||||||
</columns>
|
</columns>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkListStore" id="liststore2">
|
<object class="GtkListStore" id="liststore2">
|
||||||
<columns>
|
<columns>
|
||||||
<!-- column-name item text -->
|
<!-- column-name item -->
|
||||||
<column type="gchararray"/>
|
<column type="gchararray"/>
|
||||||
</columns>
|
</columns>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkListStore" id="liststore3">
|
<object class="GtkListStore" id="liststore3">
|
||||||
<columns>
|
<columns>
|
||||||
<!-- column-name item text -->
|
<!-- column-name item -->
|
||||||
<column type="gchararray"/>
|
<column type="gchararray"/>
|
||||||
</columns>
|
</columns>
|
||||||
</object>
|
</object>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="loc_edit">
|
<object class="GtkDialog" id="editlocation">
|
||||||
<property name="default_width">550</property>
|
<property name="default_width">550</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="change_global">
|
<object class="GtkDialog" id="editmedia">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="change_description">
|
<object class="GtkDialog" id="editmediaref">
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
<property name="default_height">450</property>
|
<property name="default_height">450</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="name_edit">
|
<object class="GtkDialog" id="editname">
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
@ -636,13 +636,13 @@
|
|||||||
</object>
|
</object>
|
||||||
<object class="GtkListStore" id="liststore1">
|
<object class="GtkListStore" id="liststore1">
|
||||||
<columns>
|
<columns>
|
||||||
<!-- column-name item text -->
|
<!-- column-name item -->
|
||||||
<column type="gchararray"/>
|
<column type="gchararray"/>
|
||||||
</columns>
|
</columns>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkListStore" id="liststore2">
|
<object class="GtkListStore" id="liststore2">
|
||||||
<columns>
|
<columns>
|
||||||
<!-- column-name item text -->
|
<!-- column-name item -->
|
||||||
<column type="gchararray"/>
|
<column type="gchararray"/>
|
||||||
</columns>
|
</columns>
|
||||||
</object>
|
</object>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="edit_note">
|
<object class="GtkDialog" id="editnote">
|
||||||
<property name="default_width">500</property>
|
<property name="default_width">500</property>
|
||||||
<property name="default_height">400</property>
|
<property name="default_height">400</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="edit_person">
|
<object class="GtkDialog" id="editperson">
|
||||||
<property name="has_focus">True</property>
|
<property name="has_focus">True</property>
|
||||||
<property name="default_height">500</property>
|
<property name="default_height">500</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
@ -114,7 +114,6 @@
|
|||||||
<object class="GtkImage" id="image2261">
|
<object class="GtkImage" id="image2261">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-edit</property>
|
<property name="stock">gtk-edit</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -330,7 +329,6 @@
|
|||||||
<object class="GtkImage" id="image2262">
|
<object class="GtkImage" id="image2262">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="icon_name">gramps-unlock</property>
|
<property name="icon_name">gramps-unlock</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -595,13 +593,13 @@ Title: A title used to refer to the person, such as 'Dr.' or 'Rev.'</property>
|
|||||||
</object>
|
</object>
|
||||||
<object class="GtkListStore" id="liststore1">
|
<object class="GtkListStore" id="liststore1">
|
||||||
<columns>
|
<columns>
|
||||||
<!-- column-name item text -->
|
<!-- column-name item -->
|
||||||
<column type="gchararray"/>
|
<column type="gchararray"/>
|
||||||
</columns>
|
</columns>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkListStore" id="liststore2">
|
<object class="GtkListStore" id="liststore2">
|
||||||
<columns>
|
<columns>
|
||||||
<!-- column-name item text -->
|
<!-- column-name item -->
|
||||||
<column type="gchararray"/>
|
<column type="gchararray"/>
|
||||||
</columns>
|
</columns>
|
||||||
<data>
|
<data>
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="place_editor">
|
<object class="GtkDialog" id="editplace">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="repository_ref_edit">
|
<object class="GtkDialog" id="editreporef">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="repository_editor">
|
<object class="GtkDialog" id="editrepository">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.10 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="source_editor">
|
<object class="GtkDialog" id="editsource">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<signal handler="on_sourceEditor_delete_event" name="delete_event"/>
|
<signal name="delete_event" handler="on_sourceEditor_delete_event"/>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
<object class="GtkVBox" id="dialog-vbox11">
|
<object class="GtkVBox" id="dialog-vbox11">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
@ -32,7 +32,7 @@
|
|||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="x_options">GTK_FILL</property>
|
<property name="x_options">GTK_FILL</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -48,7 +48,7 @@
|
|||||||
<property name="top_attach">1</property>
|
<property name="top_attach">1</property>
|
||||||
<property name="bottom_attach">2</property>
|
<property name="bottom_attach">2</property>
|
||||||
<property name="x_options">GTK_FILL</property>
|
<property name="x_options">GTK_FILL</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -60,7 +60,7 @@
|
|||||||
<packing>
|
<packing>
|
||||||
<property name="left_attach">1</property>
|
<property name="left_attach">1</property>
|
||||||
<property name="right_attach">2</property>
|
<property name="right_attach">2</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -73,7 +73,7 @@
|
|||||||
<property name="right_attach">2</property>
|
<property name="right_attach">2</property>
|
||||||
<property name="top_attach">1</property>
|
<property name="top_attach">1</property>
|
||||||
<property name="bottom_attach">2</property>
|
<property name="bottom_attach">2</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -89,7 +89,7 @@
|
|||||||
<property name="top_attach">4</property>
|
<property name="top_attach">4</property>
|
||||||
<property name="bottom_attach">5</property>
|
<property name="bottom_attach">5</property>
|
||||||
<property name="x_options">GTK_FILL</property>
|
<property name="x_options">GTK_FILL</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -102,7 +102,7 @@
|
|||||||
<property name="right_attach">2</property>
|
<property name="right_attach">2</property>
|
||||||
<property name="top_attach">4</property>
|
<property name="top_attach">4</property>
|
||||||
<property name="bottom_attach">5</property>
|
<property name="bottom_attach">5</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -115,7 +115,7 @@
|
|||||||
<property name="right_attach">2</property>
|
<property name="right_attach">2</property>
|
||||||
<property name="top_attach">3</property>
|
<property name="top_attach">3</property>
|
||||||
<property name="bottom_attach">4</property>
|
<property name="bottom_attach">4</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -131,7 +131,7 @@
|
|||||||
<property name="top_attach">3</property>
|
<property name="top_attach">3</property>
|
||||||
<property name="bottom_attach">4</property>
|
<property name="bottom_attach">4</property>
|
||||||
<property name="x_options">GTK_FILL</property>
|
<property name="x_options">GTK_FILL</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -146,7 +146,7 @@
|
|||||||
<property name="top_attach">2</property>
|
<property name="top_attach">2</property>
|
||||||
<property name="bottom_attach">3</property>
|
<property name="bottom_attach">3</property>
|
||||||
<property name="x_options">GTK_FILL</property>
|
<property name="x_options">GTK_FILL</property>
|
||||||
<property name="y_options"/>
|
<property name="y_options"></property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
@ -168,7 +168,7 @@
|
|||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can_focus">True</property>
|
<property name="can_focus">True</property>
|
||||||
<property name="receives_default">False</property>
|
<property name="receives_default">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Indicates if the record is private</property>
|
<property name="tooltip_text" translatable="yes">Indicates if the record is private</property>
|
||||||
<property name="relief">none</property>
|
<property name="relief">none</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkImage" id="image2706">
|
<object class="GtkImage" id="image2706">
|
||||||
@ -216,9 +216,9 @@
|
|||||||
<property name="can_focus">True</property>
|
<property name="can_focus">True</property>
|
||||||
<property name="can_default">True</property>
|
<property name="can_default">True</property>
|
||||||
<property name="receives_default">False</property>
|
<property name="receives_default">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Abandon changes and close window</property>
|
<property name="tooltip_text" translatable="yes">Abandon changes and close window</property>
|
||||||
<property name="use_stock">True</property>
|
<property name="use_stock">True</property>
|
||||||
<signal handler="on_sourceEditor_cancel_clicked" name="clicked"/>
|
<signal name="clicked" handler="on_sourceEditor_cancel_clicked"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -234,9 +234,9 @@
|
|||||||
<property name="can_default">True</property>
|
<property name="can_default">True</property>
|
||||||
<property name="has_default">True</property>
|
<property name="has_default">True</property>
|
||||||
<property name="receives_default">False</property>
|
<property name="receives_default">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Accept changes and close window</property>
|
<property name="tooltip_text" translatable="yes">Accept changes and close window</property>
|
||||||
<property name="use_stock">True</property>
|
<property name="use_stock">True</property>
|
||||||
<signal handler="on_sourceEditor_ok_clicked" name="clicked"/>
|
<signal name="clicked" handler="on_sourceEditor_ok_clicked"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -252,7 +252,7 @@
|
|||||||
<property name="can_default">True</property>
|
<property name="can_default">True</property>
|
||||||
<property name="receives_default">False</property>
|
<property name="receives_default">False</property>
|
||||||
<property name="use_stock">True</property>
|
<property name="use_stock">True</property>
|
||||||
<signal handler="on_sourceEditor_help_clicked" name="clicked"/>
|
<signal name="clicked" handler="on_sourceEditor_help_clicked"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-requires grampswidgets 0.0 -->
|
<!-- interface-requires grampswidgets 0.0 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="source_ref_edit">
|
<object class="GtkDialog" id="editsourceref">
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="url_edit">
|
<object class="GtkDialog" id="editurl">
|
||||||
<property name="default_width">600</property>
|
<property name="default_width">600</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkWindow" id="gvwin">
|
<object class="GtkWindow" id="grampletview">
|
||||||
<property name="title" translatable="yes">window2</property>
|
<property name="title" translatable="yes">window2</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkVBox" id="gvgramplet">
|
<object class="GtkVBox" id="gvgramplet">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="namefmt_edit">
|
<object class="GtkDialog" id="grampscfg">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">400</property>
|
<property name="default_width">400</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="merge_places">
|
<object class="GtkDialog" id="mergeplace">
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">450</property>
|
<property name="default_width">450</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
@ -233,7 +233,7 @@
|
|||||||
<action-widget response="-11">place_help</action-widget>
|
<action-widget response="-11">place_help</action-widget>
|
||||||
</action-widgets>
|
</action-widgets>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="merge">
|
<object class="GtkDialog" id="mergedata">
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">700</property>
|
<property name="default_width">700</property>
|
||||||
<property name="default_height">500</property>
|
<property name="default_height">500</property>
|
||||||
@ -440,7 +440,7 @@
|
|||||||
<action-widget response="-11">merge_help</action-widget>
|
<action-widget response="-11">merge_help</action-widget>
|
||||||
</action-widgets>
|
</action-widgets>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="merge_sources">
|
<object class="GtkDialog" id="mergesource">
|
||||||
<property name="default_width">500</property>
|
<property name="default_width">500</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
@ -948,7 +948,7 @@
|
|||||||
<action-widget response="-11">source_help</action-widget>
|
<action-widget response="-11">source_help</action-widget>
|
||||||
</action-widgets>
|
</action-widgets>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="merge_people">
|
<object class="GtkDialog" id="mergeperson">
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">300</property>
|
<property name="default_width">300</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkWindow" id="paper_settings">
|
<object class="GtkWindow" id="papermenu">
|
||||||
<property name="title" translatable="yes">Paper Settings</property>
|
<property name="title" translatable="yes">Paper Settings</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkHBox" id="paper_table">
|
<object class="GtkHBox" id="paper_table">
|
@ -728,7 +728,7 @@
|
|||||||
<action-widget response="3">button11</action-widget>
|
<action-widget response="3">button11</action-widget>
|
||||||
</action-widgets>
|
</action-widgets>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="hide_dialog">
|
<object class="GtkDialog" id="hidedialog">
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
||||||
<child internal-child="vbox">
|
<child internal-child="vbox">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="scratch_pad">
|
<object class="GtkDialog" id="scratchpad">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="title" translatable="yes">Clipboard</property>
|
<property name="title" translatable="yes">Clipboard</property>
|
||||||
<property name="default_width">500</property>
|
<property name="default_width">500</property>
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkDialog" id="styles">
|
<object class="GtkDialog" id="styles">
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="default_width">400</property>
|
<property name="default_width">400</property>
|
||||||
<property name="default_height">300</property>
|
<property name="default_height">300</property>
|
||||||
<property name="type_hint">dialog</property>
|
<property name="type_hint">dialog</property>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy project-wide -->
|
<!-- interface-naming-policy project-wide -->
|
||||||
<object class="GtkWindow" id="tod_window">
|
<object class="GtkWindow" id="tipofday">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="border_width">8</property>
|
<property name="border_width">8</property>
|
||||||
<property name="title" translatable="yes">window1</property>
|
<property name="title" translatable="yes">window1</property>
|
||||||
|
@ -29,7 +29,6 @@
|
|||||||
# Standard Python modules
|
# Standard Python modules
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import os
|
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
@ -39,6 +38,7 @@ from gettext import gettext as _
|
|||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
import logging
|
import logging
|
||||||
log = logging.getLogger(".BookReport")
|
log = logging.getLogger(".BookReport")
|
||||||
|
import os
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -59,7 +59,6 @@ except:
|
|||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import gtk
|
import gtk
|
||||||
import gobject
|
import gobject
|
||||||
from gtk import RESPONSE_OK
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -75,6 +74,7 @@ from QuestionDialog import WarningDialog, ErrorDialog
|
|||||||
from gen.plug import PluginManager
|
from gen.plug import PluginManager
|
||||||
from gen.plug.menu import PersonOption, FilterOption, FamilyOption
|
from gen.plug.menu import PersonOption, FilterOption, FamilyOption
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
# Import from specific modules in ReportBase
|
# Import from specific modules in ReportBase
|
||||||
from ReportBase import CATEGORY_BOOK, book_categories
|
from ReportBase import CATEGORY_BOOK, book_categories
|
||||||
@ -570,11 +570,8 @@ class BookListDisplay:
|
|||||||
|
|
||||||
self.booklist = booklist
|
self.booklist = booklist
|
||||||
self.dosave = dosave
|
self.dosave = dosave
|
||||||
base = os.path.dirname(__file__)
|
self.xml = Glade()
|
||||||
glade_file = os.path.join(base,"book.glade")
|
self.top = self.xml.toplevel
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_source(glade_file)
|
|
||||||
self.top = self.xml.get_object('booklist')
|
|
||||||
|
|
||||||
ManagedWindow.set_titles(self.top,
|
ManagedWindow.set_titles(self.top,
|
||||||
self.xml.get_object('title'),_('Available Books'))
|
self.xml.get_object('title'),_('Available Books'))
|
||||||
@ -683,12 +680,9 @@ class BookReportSelector(ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self.__class__)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self.__class__)
|
||||||
|
|
||||||
base = os.path.dirname(__file__)
|
self.xml = Glade(toplevel="top")
|
||||||
glade_file = os.path.join(base,"book.glade")
|
window = self.xml.toplevel
|
||||||
|
|
||||||
self.xml = gtk.Builder()
|
|
||||||
self.xml.add_from_file(glade_file)
|
|
||||||
window = self.xml.get_object("top")
|
|
||||||
title_label = self.xml.get_object('title')
|
title_label = self.xml.get_object('title')
|
||||||
self.set_window(window, title_label, self.title)
|
self.set_window(window, title_label, self.title)
|
||||||
window.show()
|
window.show()
|
||||||
@ -884,7 +878,7 @@ class BookReportSelector(ManagedWindow.ManagedWindow):
|
|||||||
item.get_translated_name(),
|
item.get_translated_name(),
|
||||||
self.track)
|
self.track)
|
||||||
response = item_dialog.window.run()
|
response = item_dialog.window.run()
|
||||||
if response == RESPONSE_OK:
|
if response == gtk.RESPONSE_OK:
|
||||||
subject = _get_subject(option_class, self.db)
|
subject = _get_subject(option_class, self.db)
|
||||||
self.bk_model.model.set_value(the_iter, 2, subject)
|
self.bk_model.model.set_value(the_iter, 2, subject)
|
||||||
self.book.set_item(row, item)
|
self.book.set_item(row, item)
|
||||||
@ -1134,7 +1128,7 @@ class BookReportDialog(DocReportDialog):
|
|||||||
this_style_name,style_sheet.get_cell_style(this_style_name))
|
this_style_name,style_sheet.get_cell_style(this_style_name))
|
||||||
|
|
||||||
response = self.window.run()
|
response = self.window.run()
|
||||||
if response == RESPONSE_OK:
|
if response == gtk.RESPONSE_OK:
|
||||||
try:
|
try:
|
||||||
self.make_report()
|
self.make_report()
|
||||||
except (IOError,OSError),msg:
|
except (IOError,OSError),msg:
|
||||||
|
@ -28,7 +28,7 @@ pkgpyexecdir = @pkgpyexecdir@/plugins
|
|||||||
pkgpythondir = @pkgpythondir@/plugins
|
pkgpythondir = @pkgpythondir@/plugins
|
||||||
|
|
||||||
GLADEFILES = \
|
GLADEFILES = \
|
||||||
book.glade
|
bookreport.glade
|
||||||
|
|
||||||
GRAPHICS =
|
GRAPHICS =
|
||||||
|
|
||||||
|
@ -77,7 +77,6 @@
|
|||||||
<object class="GtkImage" id="image33">
|
<object class="GtkImage" id="image33">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-clear</property>
|
<property name="stock">gtk-clear</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -99,7 +98,6 @@
|
|||||||
<object class="GtkImage" id="image34">
|
<object class="GtkImage" id="image34">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-save</property>
|
<property name="stock">gtk-save</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -121,7 +119,6 @@
|
|||||||
<object class="GtkImage" id="image35">
|
<object class="GtkImage" id="image35">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-open</property>
|
<property name="stock">gtk-open</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -143,7 +140,6 @@
|
|||||||
<object class="GtkImage" id="image36">
|
<object class="GtkImage" id="image36">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-index</property>
|
<property name="stock">gtk-index</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -288,7 +284,6 @@
|
|||||||
<object class="GtkImage" id="image24">
|
<object class="GtkImage" id="image24">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-add</property>
|
<property name="stock">gtk-add</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -310,7 +305,6 @@
|
|||||||
<object class="GtkImage" id="image25">
|
<object class="GtkImage" id="image25">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-remove</property>
|
<property name="stock">gtk-remove</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -332,7 +326,6 @@
|
|||||||
<object class="GtkImage" id="image26">
|
<object class="GtkImage" id="image26">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-go-up</property>
|
<property name="stock">gtk-go-up</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -354,7 +347,6 @@
|
|||||||
<object class="GtkImage" id="image27">
|
<object class="GtkImage" id="image27">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-go-down</property>
|
<property name="stock">gtk-go-down</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -376,7 +368,6 @@
|
|||||||
<object class="GtkImage" id="image28">
|
<object class="GtkImage" id="image28">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="stock">gtk-preferences</property>
|
<property name="stock">gtk-preferences</property>
|
||||||
<property name="icon-size">4</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -456,7 +447,7 @@
|
|||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="booklist">
|
<object class="GtkDialog" id="bookreport">
|
||||||
<property name="height_request">300</property>
|
<property name="height_request">300</property>
|
||||||
<property name="type_hint">normal</property>
|
<property name="type_hint">normal</property>
|
||||||
<property name="has_separator">False</property>
|
<property name="has_separator">False</property>
|
@ -31,7 +31,7 @@
|
|||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
from math import radians
|
from math import radians
|
||||||
import os
|
|
||||||
##try:
|
##try:
|
||||||
##from cStringIO import StringIO
|
##from cStringIO import StringIO
|
||||||
##except:
|
##except:
|
||||||
@ -46,6 +46,7 @@ import BaseDoc
|
|||||||
import libcairodoc
|
import libcairodoc
|
||||||
from gen.plug import PluginManager, DocGenPlugin
|
from gen.plug import PluginManager, DocGenPlugin
|
||||||
import Errors
|
import Errors
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -87,9 +88,6 @@ MARGIN = 6
|
|||||||
ZOOM_FIT_WIDTH,
|
ZOOM_FIT_WIDTH,
|
||||||
ZOOM_FREE,) = range(3)
|
ZOOM_FREE,) = range(3)
|
||||||
|
|
||||||
# glade file
|
|
||||||
_GLADE_FILE = 'gtkprintpreview.glade'
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Converter functions
|
# Converter functions
|
||||||
@ -201,13 +199,9 @@ class PrintPreview:
|
|||||||
def __build_window(self):
|
def __build_window(self):
|
||||||
"""Build the window from Glade.
|
"""Build the window from Glade.
|
||||||
"""
|
"""
|
||||||
glade_file = os.path.join(
|
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
glade_xml = gtk.Builder()
|
glade_xml = Glade()
|
||||||
glade_xml.add_from_file(glade_file)
|
self._window = glade_xml.toplevel
|
||||||
self._window = glade_xml.get_object('window')
|
|
||||||
#self._window.set_transient_for(parent)
|
#self._window.set_transient_for(parent)
|
||||||
|
|
||||||
# remember active widgets for future use
|
# remember active widgets for future use
|
||||||
|
@ -1,44 +1,27 @@
|
|||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<!--*- mode: xml -*-->
|
|
||||||
<interface>
|
<interface>
|
||||||
<object class="GtkWindow" id="window">
|
<requires lib="gtk+" version="2.16"/>
|
||||||
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
|
<object class="GtkWindow" id="gtkprint">
|
||||||
<property name="title" translatable="yes">Print Preview</property>
|
<property name="title" translatable="yes">Print Preview</property>
|
||||||
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
|
||||||
<property name="window_position">GTK_WIN_POS_CENTER</property>
|
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
|
<property name="window_position">center</property>
|
||||||
<property name="default_width">800</property>
|
<property name="default_width">800</property>
|
||||||
<property name="default_height">600</property>
|
<property name="default_height">600</property>
|
||||||
<property name="resizable">True</property>
|
<signal name="delete_event" handler="on_window_delete_event"/>
|
||||||
<property name="destroy_with_parent">False</property>
|
|
||||||
<property name="decorated">True</property>
|
|
||||||
<property name="skip_taskbar_hint">False</property>
|
|
||||||
<property name="skip_pager_hint">False</property>
|
|
||||||
<property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
|
|
||||||
<property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
|
|
||||||
<property name="focus_on_map">True</property>
|
|
||||||
<property name="urgency_hint">False</property>
|
|
||||||
<signal handler="on_window_delete_event" last_modification_time="Wed, 22 Aug 2007 10:36:14 GMT" name="delete_event"/>
|
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkVBox" id="vbox1">
|
<object class="GtkVBox" id="vbox1">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="homogeneous">False</property>
|
|
||||||
<property name="spacing">0</property>
|
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkToolbar" id="toolbar">
|
<object class="GtkToolbar" id="toolbar">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="orientation">GTK_ORIENTATION_HORIZONTAL</property>
|
<property name="toolbar_style">icons</property>
|
||||||
<property name="toolbar_style">GTK_TOOLBAR_ICONS</property>
|
|
||||||
<property name="tooltips">True</property>
|
|
||||||
<property name="show_arrow">True</property>
|
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkToolButton" id="quit">
|
<object class="GtkToolButton" id="quit">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="tooltip-text" translatable="yes">Closes print preview window</property>
|
<property name="tooltip_text" translatable="yes">Closes print preview window</property>
|
||||||
<property name="stock_id">gtk-quit</property>
|
<property name="stock_id">gtk-quit</property>
|
||||||
<property name="visible_horizontal">True</property>
|
<signal name="clicked" handler="on_quit_clicked"/>
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">False</property>
|
|
||||||
<signal handler="on_quit_clicked" last_modification_time="Wed, 22 Aug 2007 09:49:21 GMT" name="clicked"/>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -48,12 +31,9 @@
|
|||||||
<child>
|
<child>
|
||||||
<object class="GtkToolButton" id="print">
|
<object class="GtkToolButton" id="print">
|
||||||
<property name="sensitive">False</property>
|
<property name="sensitive">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Prints the current file</property>
|
<property name="tooltip_text" translatable="yes">Prints the current file</property>
|
||||||
<property name="stock_id">gtk-print</property>
|
<property name="stock_id">gtk-print</property>
|
||||||
<property name="visible_horizontal">True</property>
|
<signal name="clicked" handler="on_print_clicked"/>
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">False</property>
|
|
||||||
<signal handler="on_print_clicked" last_modification_time="Wed, 22 Aug 2007 09:49:31 GMT" name="clicked"/>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -63,25 +43,19 @@
|
|||||||
<child>
|
<child>
|
||||||
<object class="GtkSeparatorToolItem" id="separatortoolitem3">
|
<object class="GtkSeparatorToolItem" id="separatortoolitem3">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="draw">True</property>
|
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="homogeneous">False</property>
|
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkToolButton" id="first">
|
<object class="GtkToolButton" id="first">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="sensitive">False</property>
|
<property name="sensitive">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Shows the first page</property>
|
<property name="tooltip_text" translatable="yes">Shows the first page</property>
|
||||||
<property name="stock_id">gtk-goto-first</property>
|
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">True</property>
|
<property name="is_important">True</property>
|
||||||
<signal handler="on_first_clicked" last_modification_time="Wed, 22 Aug 2007 09:49:38 GMT" name="clicked"/>
|
<property name="stock_id">gtk-goto-first</property>
|
||||||
|
<signal name="clicked" handler="on_first_clicked"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -92,12 +66,10 @@
|
|||||||
<object class="GtkToolButton" id="prev">
|
<object class="GtkToolButton" id="prev">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="sensitive">False</property>
|
<property name="sensitive">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Shows previous page</property>
|
<property name="tooltip_text" translatable="yes">Shows previous page</property>
|
||||||
<property name="stock_id">gtk-go-back</property>
|
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">True</property>
|
<property name="is_important">True</property>
|
||||||
<signal handler="on_prev_clicked" last_modification_time="Wed, 22 Aug 2007 09:49:46 GMT" name="clicked"/>
|
<property name="stock_id">gtk-go-back</property>
|
||||||
|
<signal name="clicked" handler="on_prev_clicked"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -108,12 +80,10 @@
|
|||||||
<object class="GtkToolButton" id="next">
|
<object class="GtkToolButton" id="next">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="sensitive">False</property>
|
<property name="sensitive">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Shows the next page</property>
|
<property name="tooltip_text" translatable="yes">Shows the next page</property>
|
||||||
<property name="stock_id">gtk-go-forward</property>
|
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">True</property>
|
<property name="is_important">True</property>
|
||||||
<signal handler="on_next_clicked" last_modification_time="Wed, 22 Aug 2007 09:52:22 GMT" name="clicked"/>
|
<property name="stock_id">gtk-go-forward</property>
|
||||||
|
<signal name="clicked" handler="on_next_clicked"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -124,12 +94,10 @@
|
|||||||
<object class="GtkToolButton" id="last">
|
<object class="GtkToolButton" id="last">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="sensitive">False</property>
|
<property name="sensitive">False</property>
|
||||||
<property name="tooltip-text" translatable="yes">Shows the last page</property>
|
<property name="tooltip_text" translatable="yes">Shows the last page</property>
|
||||||
<property name="stock_id">gtk-goto-last</property>
|
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">True</property>
|
<property name="is_important">True</property>
|
||||||
<signal handler="on_last_clicked" last_modification_time="Wed, 22 Aug 2007 09:52:27 GMT" name="clicked"/>
|
<property name="stock_id">gtk-goto-last</property>
|
||||||
|
<signal name="clicked" handler="on_last_clicked"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -139,67 +107,38 @@
|
|||||||
<child>
|
<child>
|
||||||
<object class="GtkSeparatorToolItem" id="separatortoolitem1">
|
<object class="GtkSeparatorToolItem" id="separatortoolitem1">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="draw">True</property>
|
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="homogeneous">False</property>
|
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkToolItem" id="toolitem1">
|
<object class="GtkToolItem" id="toolitem1">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">False</property>
|
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkHBox" id="hbox1">
|
<object class="GtkHBox" id="hbox1">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="homogeneous">False</property>
|
|
||||||
<property name="spacing">6</property>
|
<property name="spacing">6</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkEntry" id="entry">
|
<object class="GtkEntry" id="entry">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="editable">True</property>
|
|
||||||
<property name="visibility">True</property>
|
|
||||||
<property name="max_length">0</property>
|
|
||||||
<property name="text" translatable="yes"/>
|
|
||||||
<property name="has_frame">True</property>
|
|
||||||
<property name="invisible_char">•</property>
|
<property name="invisible_char">•</property>
|
||||||
<property name="activates_default">False</property>
|
|
||||||
<property name="width_chars">6</property>
|
<property name="width_chars">6</property>
|
||||||
<signal handler="on_entry_activate" last_modification_time="Wed, 22 Aug 2007 13:47:47 GMT" name="activate"/>
|
<signal name="activate" handler="on_entry_activate"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="padding">0</property>
|
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="fill">True</property>
|
<property name="position">0</property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkLabel" id="label">
|
<object class="GtkLabel" id="label">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="label">of 8</property>
|
<property name="label">of 8</property>
|
||||||
<property name="use_underline">False</property>
|
|
||||||
<property name="use_markup">False</property>
|
|
||||||
<property name="justify">GTK_JUSTIFY_LEFT</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>
|
|
||||||
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
|
||||||
<property name="width_chars">-1</property>
|
|
||||||
<property name="single_line_mode">False</property>
|
|
||||||
<property name="angle">0</property>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="padding">0</property>
|
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="fill">True</property>
|
<property name="position">1</property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
@ -207,32 +146,22 @@
|
|||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="homogeneous">False</property>
|
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkSeparatorToolItem" id="separatortoolitem2">
|
<object class="GtkSeparatorToolItem" id="separatortoolitem2">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="draw">True</property>
|
|
||||||
<property name="visible_horizontal">True</property>
|
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="homogeneous">False</property>
|
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkToggleToolButton" id="zoom_fit_width">
|
<object class="GtkToggleToolButton" id="zoom_fit_width">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="tooltip-text" translatable="yes">Zooms to fit the page width</property>
|
<property name="tooltip_text" translatable="yes">Zooms to fit the page width</property>
|
||||||
<property name="label" translatable="yes"/>
|
|
||||||
<property name="use_underline">True</property>
|
<property name="use_underline">True</property>
|
||||||
<property name="visible_horizontal">True</property>
|
<signal name="toggled" handler="on_zoom_fit_width_toggled"/>
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">False</property>
|
|
||||||
<property name="active">False</property>
|
|
||||||
<signal handler="on_zoom_fit_width_toggled" last_modification_time="Tue, 28 Aug 2007 18:53:35 GMT" name="toggled"/>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -242,13 +171,9 @@
|
|||||||
<child>
|
<child>
|
||||||
<object class="GtkToggleToolButton" id="zoom_best_fit">
|
<object class="GtkToggleToolButton" id="zoom_best_fit">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="tooltip-text" translatable="yes">Zooms to fit the whole page</property>
|
<property name="tooltip_text" translatable="yes">Zooms to fit the whole page</property>
|
||||||
<property name="stock_id">gtk-zoom-fit</property>
|
<property name="stock_id">gtk-zoom-fit</property>
|
||||||
<property name="visible_horizontal">True</property>
|
<signal name="toggled" handler="on_zoom_best_fit_toggled"/>
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">False</property>
|
|
||||||
<property name="active">False</property>
|
|
||||||
<signal handler="on_zoom_best_fit_toggled" last_modification_time="Tue, 28 Aug 2007 18:53:55 GMT" name="toggled"/>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -258,12 +183,9 @@
|
|||||||
<child>
|
<child>
|
||||||
<object class="GtkToolButton" id="zoom_in">
|
<object class="GtkToolButton" id="zoom_in">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="tooltip-text" translatable="yes">Zooms the page in</property>
|
<property name="tooltip_text" translatable="yes">Zooms the page in</property>
|
||||||
<property name="stock_id">gtk-zoom-in</property>
|
<property name="stock_id">gtk-zoom-in</property>
|
||||||
<property name="visible_horizontal">True</property>
|
<signal name="clicked" handler="on_zoom_in_clicked"/>
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">False</property>
|
|
||||||
<signal handler="on_zoom_in_clicked" last_modification_time="Wed, 22 Aug 2007 09:52:48 GMT" name="clicked"/>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -273,12 +195,9 @@
|
|||||||
<child>
|
<child>
|
||||||
<object class="GtkToolButton" id="zoom_out">
|
<object class="GtkToolButton" id="zoom_out">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="tooltip-text" translatable="yes">Zooms the page out</property>
|
<property name="tooltip_text" translatable="yes">Zooms the page out</property>
|
||||||
<property name="stock_id">gtk-zoom-out</property>
|
<property name="stock_id">gtk-zoom-out</property>
|
||||||
<property name="visible_horizontal">True</property>
|
<signal name="clicked" handler="on_zoom_out_clicked"/>
|
||||||
<property name="visible_vertical">True</property>
|
|
||||||
<property name="is_important">False</property>
|
|
||||||
<signal handler="on_zoom_out_clicked" last_modification_time="Wed, 22 Aug 2007 09:52:55 GMT" name="clicked"/>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -287,36 +206,34 @@
|
|||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="padding">0</property>
|
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
<property name="fill">False</property>
|
<property name="fill">False</property>
|
||||||
|
<property name="position">0</property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkScrolledWindow" id="swin">
|
<object class="GtkScrolledWindow" id="swin">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
|
<property name="can_focus">False</property>
|
||||||
<property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
|
<property name="hscrollbar_policy">automatic</property>
|
||||||
<property name="shadow_type">GTK_SHADOW_IN</property>
|
<property name="vscrollbar_policy">automatic</property>
|
||||||
<property name="window_placement">GTK_CORNER_TOP_LEFT</property>
|
<property name="shadow_type">in</property>
|
||||||
<signal handler="on_swin_size_allocate" last_modification_time="Tue, 28 Aug 2007 21:17:25 GMT" name="size_allocate"/>
|
<signal name="size_allocate" handler="on_swin_size_allocate"/>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkViewport" id="viewport1">
|
<object class="GtkViewport" id="viewport1">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="shadow_type">GTK_SHADOW_NONE</property>
|
<property name="shadow_type">none</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkDrawingArea" id="drawingarea">
|
<object class="GtkDrawingArea" id="drawingarea">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<signal handler="on_drawingarea_expose_event" last_modification_time="Wed, 22 Aug 2007 13:46:23 GMT" name="expose_event"/>
|
<signal name="expose_event" handler="on_drawingarea_expose_event"/>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="padding">0</property>
|
<property name="position">1</property>
|
||||||
<property name="expand">True</property>
|
|
||||||
<property name="fill">True</property>
|
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
@ -34,13 +34,6 @@ import csv
|
|||||||
import cStringIO
|
import cStringIO
|
||||||
import codecs
|
import codecs
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GNOME/GTK modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Set up logging
|
# Set up logging
|
||||||
@ -61,13 +54,7 @@ from QuestionDialog import ErrorDialog
|
|||||||
from gen.plug import PluginManager, ExportPlugin
|
from gen.plug import PluginManager, ExportPlugin
|
||||||
import gen.proxy
|
import gen.proxy
|
||||||
import DateHandler
|
import DateHandler
|
||||||
|
from glade import Glade
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# Constants
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = "ExportCsv.glade"
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -179,12 +166,7 @@ class CSVWriterOptionBox:
|
|||||||
self.translate_headers = 1
|
self.translate_headers = 1
|
||||||
|
|
||||||
def get_option_box(self):
|
def get_option_box(self):
|
||||||
glade_file = os.path.join(
|
self.topDialog = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.topDialog = gtk.Builder()
|
|
||||||
self.topDialog.add_from_file(glade_file)
|
|
||||||
self.filters = self.topDialog.get_object("filter")
|
self.filters = self.topDialog.get_object("filter")
|
||||||
|
|
||||||
all = GenericFilter()
|
all = GenericFilter()
|
||||||
@ -223,7 +205,7 @@ class CSVWriterOptionBox:
|
|||||||
the_box = self.topDialog.get_object('vbox1')
|
the_box = self.topDialog.get_object('vbox1')
|
||||||
the_parent = self.topDialog.get_object('dialog-vbox1')
|
the_parent = self.topDialog.get_object('dialog-vbox1')
|
||||||
the_parent.remove(the_box)
|
the_parent.remove(the_box)
|
||||||
self.topDialog.get_object("csvExport").destroy()
|
self.topDialog.toplevel.destroy()
|
||||||
return the_box
|
return the_box
|
||||||
|
|
||||||
def parse_options(self):
|
def parse_options(self):
|
||||||
|
@ -39,13 +39,6 @@ from gettext import gettext as _
|
|||||||
import logging
|
import logging
|
||||||
log = logging.getLogger(".WriteFtree")
|
log = logging.getLogger(".WriteFtree")
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GNOME/GTK modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# GRAMPS modules
|
# GRAMPS modules
|
||||||
@ -56,13 +49,7 @@ from Filters import GenericFilter, Rules, build_filter_model
|
|||||||
import Errors
|
import Errors
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
from gen.plug import PluginManager, ExportPlugin
|
from gen.plug import PluginManager, ExportPlugin
|
||||||
|
from glade import Glade
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# Constants
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = "ExportFtree.glade"
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -83,12 +70,7 @@ class FtreeWriterOptionBox:
|
|||||||
self.restrict = True
|
self.restrict = True
|
||||||
|
|
||||||
def get_option_box(self):
|
def get_option_box(self):
|
||||||
glade_file = os.path.join(
|
self.top = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.filters = self.top.get_object("filter")
|
self.filters = self.top.get_object("filter")
|
||||||
|
|
||||||
@ -128,7 +110,7 @@ class FtreeWriterOptionBox:
|
|||||||
the_box = self.top.get_object("vbox1")
|
the_box = self.top.get_object("vbox1")
|
||||||
the_parent = self.top.get_object('dialog-vbox1')
|
the_parent = self.top.get_object('dialog-vbox1')
|
||||||
the_parent.remove(the_box)
|
the_parent.remove(the_box)
|
||||||
self.top.get_object("top").destroy()
|
self.top.toplevel.destroy()
|
||||||
return the_box
|
return the_box
|
||||||
|
|
||||||
def parse_options(self):
|
def parse_options(self):
|
||||||
|
@ -32,13 +32,6 @@
|
|||||||
import os
|
import os
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GNOME/GTK modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Set up logging
|
# Set up logging
|
||||||
@ -58,17 +51,11 @@ from Filters import GenericFilter, Rules, build_filter_model
|
|||||||
import Utils
|
import Utils
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
from gen.plug import PluginManager, ExportPlugin
|
from gen.plug import PluginManager, ExportPlugin
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Constants
|
# GeneWebWriterOptionBox class
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = "ExportGeneWeb.glade"
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
#
|
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
class GeneWebWriterOptionBox:
|
class GeneWebWriterOptionBox:
|
||||||
@ -83,12 +70,7 @@ class GeneWebWriterOptionBox:
|
|||||||
def get_option_box(self):
|
def get_option_box(self):
|
||||||
self.restrict = 1
|
self.restrict = 1
|
||||||
|
|
||||||
glade_file = os.path.join(
|
self.topDialog = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.topDialog = gtk.Builder()
|
|
||||||
self.topDialog.add_from_file(glade_file)
|
|
||||||
self.topDialog.connect_signals({
|
self.topDialog.connect_signals({
|
||||||
"on_restrict_toggled": self.on_restrict_toggled
|
"on_restrict_toggled": self.on_restrict_toggled
|
||||||
})
|
})
|
||||||
@ -132,7 +114,7 @@ class GeneWebWriterOptionBox:
|
|||||||
the_box = self.topDialog.get_object('vbox1')
|
the_box = self.topDialog.get_object('vbox1')
|
||||||
the_parent = self.topDialog.get_object('dialog-vbox1')
|
the_parent = self.topDialog.get_object('dialog-vbox1')
|
||||||
the_parent.remove(the_box)
|
the_parent.remove(the_box)
|
||||||
self.topDialog.get_object("genewebExport").destroy()
|
self.topDialog.toplevel.destroy()
|
||||||
return the_box
|
return the_box
|
||||||
|
|
||||||
def on_restrict_toggled(self, restrict):
|
def on_restrict_toggled(self, restrict):
|
||||||
|
@ -33,13 +33,6 @@ import sys
|
|||||||
from time import localtime
|
from time import localtime
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GNOME/GTK modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Set up logging
|
# Set up logging
|
||||||
@ -59,17 +52,11 @@ from gen.lib import Date, EventType
|
|||||||
import Errors
|
import Errors
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
from gen.plug import PluginManager, ExportPlugin
|
from gen.plug import PluginManager, ExportPlugin
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Constants
|
# CalendarWriterOptionBox class
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = "ExportVCalendar.glade"
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
#
|
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
class CalendarWriterOptionBox:
|
class CalendarWriterOptionBox:
|
||||||
@ -81,12 +68,7 @@ class CalendarWriterOptionBox:
|
|||||||
def __init__(self, person):
|
def __init__(self, person):
|
||||||
self.person = person
|
self.person = person
|
||||||
|
|
||||||
glade_file = os.path.join(
|
self.topDialog = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.topDialog = gtk.Builder()
|
|
||||||
self.topDialog.add_from_file(glade_file)
|
|
||||||
self.copy = 0
|
self.copy = 0
|
||||||
|
|
||||||
def get_option_box(self):
|
def get_option_box(self):
|
||||||
@ -128,7 +110,7 @@ class CalendarWriterOptionBox:
|
|||||||
the_box = self.topDialog.get_object('vbox1')
|
the_box = self.topDialog.get_object('vbox1')
|
||||||
the_parent = self.topDialog.get_object('dialog-vbox1')
|
the_parent = self.topDialog.get_object('dialog-vbox1')
|
||||||
the_parent.remove(the_box)
|
the_parent.remove(the_box)
|
||||||
self.topDialog.get_object("calendarExport").destroy()
|
self.topDialog.toplevel.destroy()
|
||||||
return the_box
|
return the_box
|
||||||
|
|
||||||
def parse_options(self):
|
def parse_options(self):
|
||||||
|
@ -28,8 +28,8 @@
|
|||||||
# Standard Python Modules
|
# Standard Python Modules
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import os
|
|
||||||
import sys
|
import sys
|
||||||
|
import os
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
@ -40,13 +40,6 @@ from gettext import gettext as _
|
|||||||
import logging
|
import logging
|
||||||
log = logging.getLogger(".ExportVCard")
|
log = logging.getLogger(".ExportVCard")
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GNOME/GTK modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# GRAMPS modules
|
# GRAMPS modules
|
||||||
@ -57,17 +50,11 @@ from gen.lib import Date
|
|||||||
import Errors
|
import Errors
|
||||||
from QuestionDialog import ErrorDialog
|
from QuestionDialog import ErrorDialog
|
||||||
from gen.plug import PluginManager, ExportPlugin
|
from gen.plug import PluginManager, ExportPlugin
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Constants
|
# CardWriterOptionBox class
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = "ExportVCard.glade"
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
#
|
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
class CardWriterOptionBox:
|
class CardWriterOptionBox:
|
||||||
@ -81,12 +68,7 @@ class CardWriterOptionBox:
|
|||||||
|
|
||||||
def get_option_box(self):
|
def get_option_box(self):
|
||||||
|
|
||||||
glade_file = os.path.join(
|
self.topDialog = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.topDialog = gtk.Builder()
|
|
||||||
self.topDialog.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.filters = self.topDialog.get_object("filter")
|
self.filters = self.topDialog.get_object("filter")
|
||||||
self.copy = 0
|
self.copy = 0
|
||||||
@ -127,7 +109,7 @@ class CardWriterOptionBox:
|
|||||||
the_box = self.topDialog.get_object('vbox1')
|
the_box = self.topDialog.get_object('vbox1')
|
||||||
the_parent = self.topDialog.get_object('dialog-vbox1')
|
the_parent = self.topDialog.get_object('dialog-vbox1')
|
||||||
the_parent.remove(the_box)
|
the_parent.remove(the_box)
|
||||||
self.topDialog.get_object("vcardExport").destroy()
|
self.topDialog.toplevel.destroy()
|
||||||
return the_box
|
return the_box
|
||||||
|
|
||||||
def parse_options(self):
|
def parse_options(self):
|
||||||
|
@ -20,11 +20,12 @@ pkgpyexecdir = @pkgpyexecdir@/plugins/export
|
|||||||
pkgpythondir = @pkgpythondir@/plugins/export
|
pkgpythondir = @pkgpythondir@/plugins/export
|
||||||
|
|
||||||
GLADEFILES = \
|
GLADEFILES = \
|
||||||
ExportCsv.glade \
|
exportcsv.glade \
|
||||||
ExportFtree.glade \
|
exportftree.glade \
|
||||||
ExportGeneWeb.glade \
|
exportgeneweb.glade \
|
||||||
ExportVCalendar.glade \
|
exportvcalendar.glade \
|
||||||
ExportVCard.glade
|
exportvcard.glade
|
||||||
|
|
||||||
|
|
||||||
GRAPHICS =
|
GRAPHICS =
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="csvExport">
|
<object class="GtkDialog" id="exportcsv">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">400</property>
|
<property name="default_width">400</property>
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="top">
|
<object class="GtkDialog" id="exportftree">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">480</property>
|
<property name="default_width">480</property>
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="genewebExport">
|
<object class="GtkDialog" id="exportgeneweb">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">400</property>
|
<property name="default_width">400</property>
|
||||||
@ -131,6 +131,9 @@
|
|||||||
<child>
|
<child>
|
||||||
<placeholder/>
|
<placeholder/>
|
||||||
</child>
|
</child>
|
||||||
|
<child>
|
||||||
|
<placeholder/>
|
||||||
|
</child>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="left_attach">1</property>
|
<property name="left_attach">1</property>
|
||||||
@ -210,6 +213,12 @@
|
|||||||
<child>
|
<child>
|
||||||
<placeholder/>
|
<placeholder/>
|
||||||
</child>
|
</child>
|
||||||
|
<child>
|
||||||
|
<placeholder/>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<placeholder/>
|
||||||
|
</child>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
@ -235,7 +244,7 @@
|
|||||||
<property name="can_default">True</property>
|
<property name="can_default">True</property>
|
||||||
<property name="receives_default">False</property>
|
<property name="receives_default">False</property>
|
||||||
<property name="use_stock">True</property>
|
<property name="use_stock">True</property>
|
||||||
<signal name="clicked" handler="destroy_passed_object" object="gedcomExport"/>
|
<signal name="clicked" handler="destroy_passed_object" object="exportgeneweb"/>
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="calendarExport">
|
<object class="GtkDialog" id="exportvcalendar">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">400</property>
|
<property name="default_width">400</property>
|
@ -2,7 +2,7 @@
|
|||||||
<interface>
|
<interface>
|
||||||
<!-- interface-requires gtk+ 2.12 -->
|
<!-- interface-requires gtk+ 2.12 -->
|
||||||
<!-- interface-naming-policy toplevel-contextual -->
|
<!-- interface-naming-policy toplevel-contextual -->
|
||||||
<object class="GtkDialog" id="vcardExport">
|
<object class="GtkDialog" id="exportvcard">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="modal">True</property>
|
<property name="modal">True</property>
|
||||||
<property name="default_width">400</property>
|
<property name="default_width">400</property>
|
@ -27,9 +27,7 @@
|
|||||||
# python modules
|
# python modules
|
||||||
#
|
#
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
import os
|
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import gtk
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -49,6 +47,7 @@ from GrampsDbUtils._GedcomParse import GedcomParser
|
|||||||
from GrampsDbUtils._GedcomStageOne import StageOne
|
from GrampsDbUtils._GedcomStageOne import StageOne
|
||||||
from QuestionDialog import ErrorDialog, DBErrorDialog
|
from QuestionDialog import ErrorDialog, DBErrorDialog
|
||||||
from gen.plug import PluginManager, ImportPlugin
|
from gen.plug import PluginManager, ImportPlugin
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import Config
|
import Config
|
||||||
@ -57,13 +56,6 @@ except ImportError:
|
|||||||
LOG.warn("No Config module available using defaults.")
|
LOG.warn("No Config module available using defaults.")
|
||||||
DEFAULT_SOURCE = False
|
DEFAULT_SOURCE = False
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# Constants
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = "ImportGedcom.glade"
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# importData
|
# importData
|
||||||
@ -91,14 +83,10 @@ def importData(database, filename, callback=None):
|
|||||||
ifile.close()
|
ifile.close()
|
||||||
|
|
||||||
if not gramps and ansel:
|
if not gramps and ansel:
|
||||||
glade_file = os.path.join(
|
top = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
top = gtk.Builder()
|
|
||||||
top.add_from_file(glade_file)
|
|
||||||
code = top.get_object('codeset')
|
code = top.get_object('codeset')
|
||||||
code.set_active(0)
|
code.set_active(0)
|
||||||
dialog = top.get_object('encoding')
|
dialog = top.toplevel
|
||||||
dialog.run()
|
dialog.run()
|
||||||
enc = ['ANSEL', 'ANSEL', 'ANSI', 'ASCII', 'UTF-8']
|
enc = ['ANSEL', 'ANSEL', 'ANSI', 'ASCII', 'UTF-8']
|
||||||
code_set = enc[ code.get_active()]
|
code_set = enc[ code.get_active()]
|
||||||
|
@ -19,7 +19,7 @@ pkgpyexecdir = @pkgpyexecdir@/plugins/import
|
|||||||
pkgpythondir = @pkgpythondir@/plugins/import
|
pkgpythondir = @pkgpythondir@/plugins/import
|
||||||
|
|
||||||
GLADEFILES = \
|
GLADEFILES = \
|
||||||
ImportGedcom.glade
|
importgedcom.glade
|
||||||
|
|
||||||
GRAPHICS =
|
GRAPHICS =
|
||||||
|
|
||||||
|
@ -375,7 +375,7 @@
|
|||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
<object class="GtkDialog" id="encoding">
|
<object class="GtkDialog" id="importgedcom">
|
||||||
<property name="width_request">400</property>
|
<property name="width_request">400</property>
|
||||||
<property name="title" translatable="yes">GRAMPS - GEDCOM Encoding</property>
|
<property name="title" translatable="yes">GRAMPS - GEDCOM Encoding</property>
|
||||||
<property name="window_position">center-on-parent</property>
|
<property name="window_position">center-on-parent</property>
|
@ -23,13 +23,6 @@
|
|||||||
|
|
||||||
"""Tools/Database Processing/Fix Capitalization of Family Names"""
|
"""Tools/Database Processing/Fix Capitalization of Family Names"""
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# python modules
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
import os
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# gnome/gtk
|
# gnome/gtk
|
||||||
@ -52,6 +45,8 @@ from QuestionDialog import OkDialog
|
|||||||
from PluginUtils import Tool
|
from PluginUtils import Tool
|
||||||
from gen.plug import PluginManager
|
from gen.plug import PluginManager
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# constants
|
# constants
|
||||||
@ -177,11 +172,8 @@ class ChangeNames(Tool.BatchTool, ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
def display(self):
|
def display(self):
|
||||||
|
|
||||||
base = os.path.dirname(__file__)
|
self.top = Glade()
|
||||||
glade_file = os.path.join(base,"changenames.glade")
|
window = self.top.toplevel
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
window = self.top.get_object('top')
|
|
||||||
self.top.connect_signals({
|
self.top.connect_signals({
|
||||||
"destroy_passed_object" : self.close,
|
"destroy_passed_object" : self.close,
|
||||||
"on_ok_clicked" : self.on_ok_clicked,
|
"on_ok_clicked" : self.on_ok_clicked,
|
||||||
|
@ -28,17 +28,9 @@
|
|||||||
# standard python modules
|
# standard python modules
|
||||||
#
|
#
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
import os
|
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
from gettext import ngettext
|
from gettext import ngettext
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GNOME/GTK modules
|
|
||||||
#
|
|
||||||
#------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# GRAMPS modules
|
# GRAMPS modules
|
||||||
@ -52,6 +44,7 @@ from gen.lib import EventType
|
|||||||
from QuestionDialog import OkDialog
|
from QuestionDialog import OkDialog
|
||||||
from PluginUtils import Tool
|
from PluginUtils import Tool
|
||||||
from gen.plug import PluginManager
|
from gen.plug import PluginManager
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -84,12 +77,7 @@ class ChangeTypes(Tool.BatchTool, ManagedWindow.ManagedWindow):
|
|||||||
def init_gui(self):
|
def init_gui(self):
|
||||||
# Draw dialog and make it handle everything
|
# Draw dialog and make it handle everything
|
||||||
|
|
||||||
glade_file = os.path.join(
|
self.glade = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.glade = gtk.Builder()
|
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
self.auto1 = self.glade.get_object("original")
|
self.auto1 = self.glade.get_object("original")
|
||||||
self.auto2 = self.glade.get_object("new")
|
self.auto2 = self.glade.get_object("new")
|
||||||
@ -108,7 +96,7 @@ class ChangeTypes(Tool.BatchTool, ManagedWindow.ManagedWindow):
|
|||||||
etype.set_from_xml_str(self.options.handler.options_dict['totype'])
|
etype.set_from_xml_str(self.options.handler.options_dict['totype'])
|
||||||
self.auto2.child.set_text(str(etype))
|
self.auto2.child.set_text(str(etype))
|
||||||
|
|
||||||
window = self.glade.get_object('top')
|
window = self.glade.toplevel
|
||||||
self.set_window(window,self.glade.get_object('title'),self.title)
|
self.set_window(window,self.glade.get_object('title'),self.title)
|
||||||
|
|
||||||
self.glade.connect_signals({
|
self.glade.connect_signals({
|
||||||
|
@ -64,6 +64,7 @@ from PluginUtils import Tool
|
|||||||
from gen.plug import PluginManager
|
from gen.plug import PluginManager
|
||||||
from QuestionDialog import OkDialog, MissingMediaDialog
|
from QuestionDialog import OkDialog, MissingMediaDialog
|
||||||
from BasicUtils import name_displayer as _nd
|
from BasicUtils import name_displayer as _nd
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -1628,14 +1629,9 @@ class Report(ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
||||||
|
|
||||||
glade_file = os.path.join(
|
topDialog = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
topDialog = gtk.Builder()
|
|
||||||
topDialog.add_from_file(glade_file)
|
|
||||||
topDialog.get_object("close").connect('clicked',self.close)
|
topDialog.get_object("close").connect('clicked',self.close)
|
||||||
window = topDialog.get_object ("summary")
|
window = topDialog.toplevel
|
||||||
textwindow = topDialog.get_object("textwindow")
|
textwindow = topDialog.get_object("textwindow")
|
||||||
textwindow.get_buffer().set_text(text)
|
textwindow.get_buffer().set_text(text)
|
||||||
|
|
||||||
|
@ -23,13 +23,6 @@
|
|||||||
|
|
||||||
"""Tools/Analysis and Exploration/Interactive Descendant Browser"""
|
"""Tools/Analysis and Exploration/Interactive Descendant Browser"""
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# standard python modules
|
|
||||||
#
|
|
||||||
#------------------------------------------------------------------------
|
|
||||||
import os
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# GTK/GNOME modules
|
# GTK/GNOME modules
|
||||||
@ -49,6 +42,8 @@ from gen.plug import PluginManager
|
|||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# Constants
|
# Constants
|
||||||
@ -56,7 +51,6 @@ from TransUtils import sgettext as _
|
|||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
WIKI_HELP_PAGE = '%s_-_Tools' % const.URL_MANUAL_PAGE
|
WIKI_HELP_PAGE = '%s_-_Tools' % const.URL_MANUAL_PAGE
|
||||||
WIKI_HELP_SEC = _('manual|Interactive_Descendant_Browser...')
|
WIKI_HELP_SEC = _('manual|Interactive_Descendant_Browser...')
|
||||||
_GLADE_FILE = "desbrowse.glade"
|
|
||||||
|
|
||||||
class DesBrowse(Tool.ActivePersonTool, ManagedWindow.ManagedWindow):
|
class DesBrowse(Tool.ActivePersonTool, ManagedWindow.ManagedWindow):
|
||||||
|
|
||||||
@ -74,18 +68,13 @@ class DesBrowse(Tool.ActivePersonTool, ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
||||||
|
|
||||||
glade_file = os.path.join(
|
self.glade = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.glade = gtk.Builder()
|
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
self.glade.connect_signals({
|
self.glade.connect_signals({
|
||||||
"destroy_passed_object" : self.close,
|
"destroy_passed_object" : self.close,
|
||||||
"on_help_clicked" : self.on_help_clicked,
|
"on_help_clicked" : self.on_help_clicked,
|
||||||
})
|
})
|
||||||
|
|
||||||
window = self.glade.get_object("top")
|
window = self.glade.toplevel
|
||||||
self.set_window(window,self.glade.get_object('title'),
|
self.set_window(window,self.glade.get_object('title'),
|
||||||
self.active_name)
|
self.active_name)
|
||||||
|
|
||||||
|
@ -29,18 +29,10 @@ Provide a python evaluation window
|
|||||||
# standard python modules
|
# standard python modules
|
||||||
#
|
#
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
import os
|
|
||||||
import cStringIO
|
import cStringIO
|
||||||
import sys
|
import sys
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# GNOME/GTK modules
|
|
||||||
#
|
|
||||||
#------------------------------------------------------------------------
|
|
||||||
import gtk
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
# GRAMPS modules
|
# GRAMPS modules
|
||||||
@ -49,13 +41,7 @@ import gtk
|
|||||||
from PluginUtils import Tool
|
from PluginUtils import Tool
|
||||||
from gen.plug import PluginManager
|
from gen.plug import PluginManager
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
|
from glade import Glade
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# Constants
|
|
||||||
#
|
|
||||||
#-------------------------------------------------------------------------
|
|
||||||
_GLADE_FILE = "eval.glade"
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -69,16 +55,11 @@ class Eval(Tool.Tool,ManagedWindow.ManagedWindow):
|
|||||||
Tool.Tool.__init__(self,dbstate, options_class, name)
|
Tool.Tool.__init__(self,dbstate, options_class, name)
|
||||||
ManagedWindow.ManagedWindow.__init__(self,uistate,[],self.__class__)
|
ManagedWindow.ManagedWindow.__init__(self,uistate,[],self.__class__)
|
||||||
|
|
||||||
glade_file = os.path.join(
|
self.glade = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.glade = gtk.Builder()
|
window = self.glade.toplevel
|
||||||
self.glade.add_from_file(glade_file)
|
|
||||||
|
|
||||||
window = self.glade.get_object("top")
|
|
||||||
self.dbuf = self.glade.get_object("display").get_buffer()
|
self.dbuf = self.glade.get_object("display").get_buffer()
|
||||||
self.ebuf = self.glade.get_object("eval").get_buffer()
|
self.ebuf = self.glade.get_object("ebuf").get_buffer()
|
||||||
self.error = self.glade.get_object("error").get_buffer()
|
self.error = self.glade.get_object("error").get_buffer()
|
||||||
|
|
||||||
self.glade.connect_signals({
|
self.glade.connect_signals({
|
||||||
|
@ -29,7 +29,6 @@
|
|||||||
#
|
#
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
import os
|
import os
|
||||||
import sys
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -57,6 +56,7 @@ from ReportBase import ReportUtils
|
|||||||
import GrampsDisplay
|
import GrampsDisplay
|
||||||
import ManagedWindow
|
import ManagedWindow
|
||||||
from TransUtils import sgettext as _
|
from TransUtils import sgettext as _
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
@ -121,14 +121,9 @@ class EventComparison(Tool.Tool,ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
Tool.Tool.__init__(self,dbstate, options_class, name)
|
Tool.Tool.__init__(self,dbstate, options_class, name)
|
||||||
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
ManagedWindow.ManagedWindow.__init__(self, uistate, [], self)
|
||||||
|
|
||||||
glade_file = os.path.join(
|
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
self.qual = 0
|
self.qual = 0
|
||||||
|
|
||||||
self.filterDialog = gtk.Builder()
|
self.filterDialog = Glade(toplevel="filters")
|
||||||
self.filterDialog.add_from_file(glade_file)
|
|
||||||
self.filterDialog.connect_signals({
|
self.filterDialog.connect_signals({
|
||||||
"on_apply_clicked" : self.on_apply_clicked,
|
"on_apply_clicked" : self.on_apply_clicked,
|
||||||
"on_editor_clicked" : self.filter_editor_clicked,
|
"on_editor_clicked" : self.filter_editor_clicked,
|
||||||
@ -137,7 +132,7 @@ class EventComparison(Tool.Tool,ManagedWindow.ManagedWindow):
|
|||||||
"destroy_passed_object" : self.close
|
"destroy_passed_object" : self.close
|
||||||
})
|
})
|
||||||
|
|
||||||
window = self.filterDialog.get_object("filters")
|
window = self.filterDialog.toplevel
|
||||||
window.show()
|
window.show()
|
||||||
self.filters = self.filterDialog.get_object("filter_list")
|
self.filters = self.filterDialog.get_object("filter_list")
|
||||||
self.label = _('Event comparison filter selection')
|
self.label = _('Event comparison filter selection')
|
||||||
@ -228,19 +223,14 @@ class DisplayChart(ManagedWindow.ManagedWindow):
|
|||||||
self.row_data = []
|
self.row_data = []
|
||||||
self.save_form = None
|
self.save_form = None
|
||||||
|
|
||||||
glade_file = os.path.join(
|
self.topDialog = Glade()
|
||||||
os.path.split(__file__)[0],
|
|
||||||
_GLADE_FILE)
|
|
||||||
|
|
||||||
self.topDialog = gtk.Builder()
|
|
||||||
self.topDialog.add_from_file(glade_file)
|
|
||||||
self.topDialog.connect_signals({
|
self.topDialog.connect_signals({
|
||||||
"on_write_table" : self.on_write_table,
|
"on_write_table" : self.on_write_table,
|
||||||
"destroy_passed_object" : self.close,
|
"destroy_passed_object" : self.close,
|
||||||
"on_help_clicked" : self.on_help_clicked,
|
"on_help_clicked" : self.on_help_clicked,
|
||||||
})
|
})
|
||||||
|
|
||||||
window = self.topDialog.get_object("view")
|
window = self.topDialog.toplevel
|
||||||
window.show()
|
window.show()
|
||||||
self.set_window(window, self.topDialog.get_object('title'),
|
self.set_window(window, self.topDialog.get_object('title'),
|
||||||
_('Event Comparison Results'))
|
_('Event Comparison Results'))
|
||||||
|
@ -30,7 +30,6 @@
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
import re
|
import re
|
||||||
import os
|
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
@ -52,6 +51,7 @@ import GrampsDisplay
|
|||||||
from PluginUtils import Tool
|
from PluginUtils import Tool
|
||||||
from gen.plug import PluginManager
|
from gen.plug import PluginManager
|
||||||
import Utils
|
import Utils
|
||||||
|
from glade import Glade
|
||||||
|
|
||||||
CITY_STATE_ZIP = re.compile("((\w|\s)+)\s*,\s*((\w|\s)+)\s*(,\s*((\d|-)+))", re.UNICODE)
|
CITY_STATE_ZIP = re.compile("((\w|\s)+)\s*,\s*((\w|\s)+)\s*(,\s*((\d|-)+))", re.UNICODE)
|
||||||
CITY_STATE = re.compile("((?:\w|\s)+(?:-(?:\w|\s)+)*),((?:\w|\s)+)", re.UNICODE)
|
CITY_STATE = re.compile("((?:\w|\s)+(?:-(?:\w|\s)+)*),((?:\w|\s)+)", re.UNICODE)
|
||||||
@ -512,11 +512,8 @@ class ExtractCity(Tool.BatchTool, ManagedWindow.ManagedWindow):
|
|||||||
|
|
||||||
def display(self):
|
def display(self):
|
||||||
|
|
||||||
base = os.path.dirname(__file__)
|
self.top = Glade("changenames.glade")
|
||||||
glade_file = os.path.join(base, "changenames.glade")
|
window = self.top.toplevel
|
||||||
self.top = gtk.Builder()
|
|
||||||
self.top.add_from_file(glade_file)
|
|
||||||
window = self.top.get_object('top')
|
|
||||||
self.top.connect_signals({
|
self.top.connect_signals({
|
||||||
"destroy_passed_object" : self.close,
|
"destroy_passed_object" : self.close,
|
||||||
"on_ok_clicked" : self.on_ok_clicked,
|
"on_ok_clicked" : self.on_ok_clicked,
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user