Convert DetDescendantReport and DetAncestralReport to use MenuOption.

svn: r9606
This commit is contained in:
Brian Matherly 2007-12-28 05:12:30 +00:00
parent c3bda4cb4c
commit 455a481dc6
3 changed files with 177 additions and 401 deletions

View File

@ -1,3 +1,8 @@
2007-12-27 Brian Matherly <brian@gramps-project.org>
* src/plugins/DetDescendantReport.py:
* src/plugins/DetAncestralReport.py:
Convert to use MenuOption
2007-12-27 Douglas S. Blank <dblank@cs.brynmawr.edu> 2007-12-27 Douglas S. Blank <dblank@cs.brynmawr.edu>
* src/PluginUtils/_Options.py: Bug #1486, type error on option read * src/PluginUtils/_Options.py: Bug #1486, type error on option read

View File

@ -44,15 +44,12 @@ import gtk
# #
#------------------------------------------------------------------------ #------------------------------------------------------------------------
import gen.lib import gen.lib
from PluginUtils import register_report from PluginUtils import register_report, NumberOption, BooleanOption
from ReportBase import Report, ReportUtils, ReportOptions, \ from ReportBase import Report, ReportUtils, MenuReportOptions, \
CATEGORY_TEXT, MODE_GUI, MODE_BKI, MODE_CLI CATEGORY_TEXT, MODE_GUI, MODE_BKI, MODE_CLI
from ReportBase import Bibliography, Endnotes from ReportBase import Bibliography, Endnotes
import BaseDoc import BaseDoc
import Utils
import DateHandler import DateHandler
from QuestionDialog import ErrorDialog
from BasicUtils import name_displayer as _nd from BasicUtils import name_displayer as _nd
#------------------------------------------------------------------------ #------------------------------------------------------------------------
@ -653,91 +650,97 @@ class DetAncestorReport(Report):
#------------------------------------------------------------------------ #------------------------------------------------------------------------
# #
# # DetAncestorOptions
# #
#------------------------------------------------------------------------ #------------------------------------------------------------------------
class DetAncestorOptions(ReportOptions): class DetAncestorOptions(MenuReportOptions):
""" """
Defines options and provides handling interface. Defines options and provides handling interface.
""" """
def __init__(self,name,person_id=None): def __init__(self,name,person_id=None):
ReportOptions.__init__(self,name,person_id) MenuReportOptions.__init__(self,name,person_id)
# Options specific for this report def add_menu_options(self,menu):
self.options_dict = { category_name = _("Report Options")
'gen' : 10,
'pagebbg' : 0, gen = NumberOption(_("Generations"),10,1,100)
'fulldates' : 1, gen.set_help(_("The number of generations to include in the report"))
'listc' : 1, menu.add_option(category_name,"gen",gen)
'incnotes' : 1,
'incattrs' : 0, pagebbg = BooleanOption(_("Page break between generations"),False)
'usecall' : 1, pagebbg.set_help(
'repplace' : 0, _("Whether to start a new page after each generation."))
'repdate' : 0, menu.add_option(category_name,"pagebbg",pagebbg)
'computeage' : 1,
'omitda' : 1, category_name = _("Content")
'desref' : 1,
'incphotos' : 0, usecall = BooleanOption(_("Use callname for common name"),False)
'incnames' : 0, usecall.set_help(_("Whether to use the call name as the first name."))
'incevents' : 0, menu.add_option(category_name,"usecall",usecall)
'incaddresses' : 0,
'incsources' : 0, fulldates = BooleanOption(
} _("Use full dates instead of only the year"),True)
self.options_help = { fulldates.set_help(_("Whether to use full dates instead of just year."))
'gen' : ("=int","Generations", menu.add_option(category_name,"fulldates",fulldates)
"The number of generations to include in the report",
True), listc = BooleanOption(_("List children"),True)
'pagebbg' : ("=0/1","Page Break Between Generations", listc.set_help(_("Whether to list children."))
["No line break", "Insert line break"], menu.add_option(category_name,"listc",listc)
False),
'fulldates' : ("=0/1","Whether to use full dates instead of just year.", computeage = BooleanOption(_("Compute age"),True)
["Do not use full dates","Use full dates"], computeage.set_help(_("Whether to compute age."))
True), menu.add_option(category_name,"computeage",computeage)
'listc' : ("=0/1","Whether to list children.",
["Do not list children","List children"], omitda = BooleanOption(_("Omit duplicate ancestors"),True)
True), omitda.set_help(_("Whether to omit duplicate ancestors."))
'incnotes' : ("=0/1","Whether to include notes.", menu.add_option(category_name,"omitda",omitda)
["Do not include notes","Include notes"],
True), desref = BooleanOption(_("Add descendant reference in child list"),True)
'incattrs' : ("=0/1","Whether to include attributes.", desref.set_help(
["Do not include attributes","Include attributes"], _("Whether to add descendant references in child list."))
True), menu.add_option(category_name,"desref",desref)
'usecall' : ("=0/1","Whether to use the call name as the first name.",
["Do not use call name","Use call name"], category_name = _("Include")
True),
'repplace' : ("=0/1","Whether to replace missing Places with blanks.", incnotes = BooleanOption(_("Include notes"),True)
["Do not replace missing Places","Replace missing Places"], incnotes.set_help(_("Whether to include notes."))
True), menu.add_option(category_name,"incnotes",incnotes)
'repdate' : ("=0/1","Whether to replace missing Dates with blanks.",
["Do not replace missing Dates","Replace missing Dates"], incattrs = BooleanOption(_("Include attributes"),False)
True), incattrs.set_help(_("Whether to include attributes."))
'computeage' : ("=0/1","Whether to compute age.", menu.add_option(category_name,"incattrs",incattrs)
["Do not compute age","Compute age"],
True), incphotos = BooleanOption(_("Include Photo/Images from Gallery"),False)
'omitda' : ("=0/1","Whether to omit duplicate ancestors.", incphotos.set_help(_("Whether to include images."))
["Do not omit duplicates","Omit duplicates"], menu.add_option(category_name,"incphotos",incphotos)
True),
'desref' : ("=0/1","Whether to add descendant references in child list.", incnames = BooleanOption(_("Include alternative names"),False)
["Do not add references","Add references"], incnames.set_help(_("Whether to include other names."))
True), menu.add_option(category_name,"incnames",incnames)
'incphotos' : ("=0/1","Whether to include images.",
["Do not include images","Include images"], incevents = BooleanOption(_("Include events"),False)
True), incevents.set_help(_("Whether to include events."))
'incnames' : ("=0/1","Whether to include other names.", menu.add_option(category_name,"incevents",incevents)
["Do not include other names","Include other names"],
True), incaddresses = BooleanOption(_("Include addresses"),False)
'incevents' : ("=0/1","Whether to include events.", incaddresses.set_help(_("Whether to include addresses."))
["Do not include events","Include events"], menu.add_option(category_name,"incaddresses",incaddresses)
True),
'incaddresses': ("=0/1","Whether to include addresses.", incsources = BooleanOption(_("Include sources"),False)
["Do not include addresses","Include addresses"], incsources.set_help(_("Whether to include source references."))
True), menu.add_option(category_name,"incsources",incsources)
'incsources' : ("=0/1","Whether to include source references.",
["Do not include sources","Include sources"], category_name = _("Missing information")
True),
} repplace = BooleanOption(_("Replace missing places with ______"),False)
repplace.set_help(_("Whether to replace missing Places with blanks."))
menu.add_option(category_name,"repplace",repplace)
repdate = BooleanOption(_("Replace missing dates with ______"),False)
repdate.set_help(_("Whether to replace missing Dates with blanks."))
menu.add_option(category_name,"repdate",repdate)
def make_default_style(self,default_style): def make_default_style(self,default_style):
"""Make the default output style for the Detailed Ancestral Report""" """Make the default output style for the Detailed Ancestral Report"""
@ -827,120 +830,6 @@ class DetAncestorOptions(ReportOptions):
Endnotes.add_endnote_styles(default_style) Endnotes.add_endnote_styles(default_style)
def add_user_options(self,dialog):
"""
Override the base class add_user_options task to add a menu that allows
the user to select the sort method.
"""
self.max_gen = gtk.SpinButton(gtk.Adjustment(1,1,100,1))
self.max_gen.set_value(self.options_dict['gen'])
self.cb_pagebreak = gtk.CheckButton (_("Page break between generations"))
self.cb_pagebreak.set_active (self.options_dict['pagebbg'])
# Full date usage
self.full_date_option = gtk.CheckButton(_("Use full dates instead of only the year"))
self.full_date_option.set_active(self.options_dict['fulldates'])
# Children List
self.list_children_option = gtk.CheckButton(_("List children"))
self.list_children_option.set_active(self.options_dict['listc'])
# Print notes
self.include_notes_option = gtk.CheckButton(_("Include notes"))
self.include_notes_option.set_active(self.options_dict['incnotes'])
# Print attributes
self.include_attributes_option = gtk.CheckButton(_("Include attributes"))
self.include_attributes_option.set_active(self.options_dict['incattrs'])
# Print callname
self.usecall = gtk.CheckButton(_("Use callname for common name"))
self.usecall.set_active(self.options_dict['usecall'])
# Replace missing Place with ___________
self.place_option = gtk.CheckButton(_("Replace missing places with ______"))
self.place_option.set_active(self.options_dict['repplace'])
# Replace missing dates with __________
self.date_option = gtk.CheckButton(_("Replace missing dates with ______"))
self.date_option.set_active(self.options_dict['repdate'])
# Add "Died at the age of NN" in text
self.age_option = gtk.CheckButton(_("Compute age"))
self.age_option.set_active(self.options_dict['computeage'])
# Omit duplicate persons, occurs when distant cousins marry
self.dupPersons_option = gtk.CheckButton(_("Omit duplicate ancestors"))
self.dupPersons_option.set_active(self.options_dict['omitda'])
#Add descendant reference in child list
self.childRef_option = gtk.CheckButton(_("Add descendant reference in child list"))
self.childRef_option.set_active(self.options_dict['desref'])
#Add photo/image reference
self.image_option = gtk.CheckButton(_("Include Photo/Images from Gallery"))
self.image_option.set_active(self.options_dict['incphotos'])
# Print alternative names
self.include_names_option = gtk.CheckButton(_("Include alternative names"))
self.include_names_option.set_active(self.options_dict['incnames'])
# Print events
self.include_events_option = gtk.CheckButton(_("Include events"))
self.include_events_option.set_active(self.options_dict['incevents'])
# Print addresses
self.include_addresses_option = gtk.CheckButton(_("Include addresses"))
self.include_addresses_option.set_active(self.options_dict['incaddresses'])
# Print sources
self.include_sources_option = gtk.CheckButton(_("Include sources"))
self.include_sources_option.set_active(self.options_dict['incsources'])
# Add new options. The first argument is the tab name for grouping options.
# if you want to put everyting in the generic "Options" category, use
# self.add_option(text,widget) instead of self.add_frame_option(category,text,widget)
dialog.add_option(_('Generations'),self.max_gen)
dialog.add_option ('', self.cb_pagebreak)
dialog.add_frame_option(_('Content'),'',self.usecall)
dialog.add_frame_option(_('Content'),'',self.full_date_option)
dialog.add_frame_option(_('Content'),'',self.list_children_option)
dialog.add_frame_option(_('Content'),'',self.age_option)
dialog.add_frame_option(_('Content'),'',self.dupPersons_option)
dialog.add_frame_option(_('Content'),'',self.childRef_option)
dialog.add_frame_option(_('Include'),'',self.image_option)
dialog.add_frame_option(_('Include'),'',self.include_notes_option)
dialog.add_frame_option(_('Include'),'',self.include_attributes_option)
dialog.add_frame_option(_('Include'),'',self.include_names_option)
dialog.add_frame_option(_('Include'),'',self.include_events_option)
dialog.add_frame_option(_('Include'),'',self.include_addresses_option)
dialog.add_frame_option(_('Include'),'',self.include_sources_option)
dialog.add_frame_option(_('Missing information'),'',self.place_option)
dialog.add_frame_option(_('Missing information'),'',self.date_option)
def parse_user_options(self,dialog):
"""
Parses the custom options that we have added.
"""
self.options_dict['gen'] = self.max_gen.get_value_as_int()
self.options_dict['pagebbg'] = int(self.cb_pagebreak.get_active ())
self.options_dict['fulldates'] = int(self.full_date_option.get_active())
self.options_dict['listc'] = int(self.list_children_option.get_active())
self.options_dict['incnotes'] = int(self.include_notes_option.get_active())
self.options_dict['incattrs'] = int(self.include_attributes_option.get_active())
self.options_dict['usecall'] = int(self.usecall.get_active())
self.options_dict['repplace'] = int(self.place_option.get_active())
self.options_dict['repdate'] = int(self.date_option.get_active())
self.options_dict['computeage'] = int(self.age_option.get_active())
self.options_dict['omitda'] = int(self.dupPersons_option.get_active())
self.options_dict['desref'] = int(self.childRef_option.get_active())
self.options_dict['incphotos'] = int(self.image_option.get_active())
self.options_dict['incnames'] = int(self.include_names_option.get_active())
self.options_dict['incevents'] = int(self.include_events_option.get_active())
self.options_dict['incaddresses'] = int(self.include_addresses_option.get_active())
self.options_dict['incsources'] = int(self.include_sources_option.get_active())
#------------------------------------------------------------------------ #------------------------------------------------------------------------
# #
# #

View File

@ -45,17 +45,13 @@ import gtk
# #
#------------------------------------------------------------------------ #------------------------------------------------------------------------
import gen.lib import gen.lib
import Utils from PluginUtils import register_report, NumberOption, BooleanOption
import Errors from ReportBase import Report, ReportUtils, MenuReportOptions, \
from PluginUtils import register_report
from ReportBase import Report, ReportUtils, ReportOptions, \
CATEGORY_TEXT, MODE_GUI, MODE_BKI, MODE_CLI CATEGORY_TEXT, MODE_GUI, MODE_BKI, MODE_CLI
from ReportBase import Bibliography, Endnotes from ReportBase import Bibliography, Endnotes
import BaseDoc import BaseDoc
import const
import DateHandler import DateHandler
from BasicUtils import name_displayer as _nd from BasicUtils import name_displayer as _nd
from QuestionDialog import ErrorDialog
#------------------------------------------------------------------------ #------------------------------------------------------------------------
# #
@ -617,95 +613,101 @@ class DetDescendantReport(Report):
#------------------------------------------------------------------------ #------------------------------------------------------------------------
# #
# # DetDescendantOptions
# #
#------------------------------------------------------------------------ #------------------------------------------------------------------------
class DetDescendantOptions(ReportOptions): class DetDescendantOptions(MenuReportOptions):
""" """
Defines options and provides handling interface. Defines options and provides handling interface.
""" """
def __init__(self,name,person_id=None): def __init__(self,name,person_id=None):
ReportOptions.__init__(self,name,person_id) MenuReportOptions.__init__(self,name,person_id)
# Options specific for this report def add_menu_options(self,menu):
self.options_dict = { category_name = _("Report Options")
'gen' : 10,
'pagebbg' : 0, gen = NumberOption(_("Generations"),10,1,100)
'fulldates' : 1, gen.set_help(_("The number of generations to include in the report"))
'listc' : 1, menu.add_option(category_name,"gen",gen)
'incnotes' : 1,
'incattrs' : 0, pagebbg = BooleanOption(_("Page break between generations"),False)
'usecall' : 1, pagebbg.set_help(
'repplace' : 0, _("Whether to start a new page after each generation."))
'repdate' : 0, menu.add_option(category_name,"pagebbg",pagebbg)
'computeage' : 1,
'omitda' : 1, category_name = _("Content")
'desref' : 1,
'incphotos' : 0, usecall = BooleanOption(_("Use callname for common name"),False)
'incnames' : 0, usecall.set_help(_("Whether to use the call name as the first name."))
'incevents' : 0, menu.add_option(category_name,"usecall",usecall)
'incaddresses' : 0,
'incsources' : 0, fulldates = BooleanOption(
'incmates' : 1, _("Use full dates instead of only the year"),True)
} fulldates.set_help(_("Whether to use full dates instead of just year."))
self.options_help = { menu.add_option(category_name,"fulldates",fulldates)
'gen' : ("=int","Generations",
"The number of generations to include in the report", listc = BooleanOption(_("List children"),True)
True), listc.set_help(_("Whether to list children."))
'pagebbg' : ("=0/1","Page Break Between Generations", menu.add_option(category_name,"listc",listc)
["No line break", "Insert line break"],
False), computeage = BooleanOption(_("Compute age"),True)
'fulldates' : ("=0/1","Whether to use full dates instead of just year.", computeage.set_help(_("Whether to compute age."))
["Do not use full dates","Use full dates"], menu.add_option(category_name,"computeage",computeage)
True),
'listc' : ("=0/1","Whether to list children.", omitda = BooleanOption(_("Omit duplicate ancestors"),True)
["Do not list children","List children"], omitda.set_help(_("Whether to omit duplicate ancestors."))
True), menu.add_option(category_name,"omitda",omitda)
'incnotes' : ("=0/1","Whether to include notes.",
["Do not include notes","Include notes"], desref = BooleanOption(_("Add descendant reference in child list"),True)
True), desref.set_help(
'incattrs' : ("=0/1","Whether to include attributes.", _("Whether to add descendant references in child list."))
["Do not include attributes","Include attributes"], menu.add_option(category_name,"desref",desref)
True),
'usecall' : ("=0/1","Whether to use the call name as the first name.", category_name = _("Include")
["Do not use call name","Use call name"],
True), incnotes = BooleanOption(_("Include notes"),True)
'repplace' : ("=0/1","Whether to replace missing Places with blanks.", incnotes.set_help(_("Whether to include notes."))
["Do not replace missing Places","Replace missing Places"], menu.add_option(category_name,"incnotes",incnotes)
True),
'repdate' : ("=0/1","Whether to replace missing Dates with blanks.", incattrs = BooleanOption(_("Include attributes"),False)
["Do not replace missing Dates","Replace missing Dates"], incattrs.set_help(_("Whether to include attributes."))
True), menu.add_option(category_name,"incattrs",incattrs)
'computeage' : ("=0/1","Whether to compute age.",
["Do not compute age","Compute age"], incphotos = BooleanOption(_("Include Photo/Images from Gallery"),False)
True), incphotos.set_help(_("Whether to include images."))
'omitda' : ("=0/1","Whether to omit duplicate ancestors.", menu.add_option(category_name,"incphotos",incphotos)
["Do not omit duplicates","Omit duplicates"],
True), incnames = BooleanOption(_("Include alternative names"),False)
'desref' : ("=0/1","Whether to add descendant references in child list.", incnames.set_help(_("Whether to include other names."))
["Do not add references","Add references"], menu.add_option(category_name,"incnames",incnames)
True),
'incphotos' : ("=0/1","Whether to include images.", incevents = BooleanOption(_("Include events"),False)
["Do not include images","Include images"], incevents.set_help(_("Whether to include events."))
True), menu.add_option(category_name,"incevents",incevents)
'incnames' : ("=0/1","Whether to include other names.",
["Do not include other names","Include other names"], incaddresses = BooleanOption(_("Include addresses"),False)
True), incaddresses.set_help(_("Whether to include addresses."))
'incevents' : ("=0/1","Whether to include events.", menu.add_option(category_name,"incaddresses",incaddresses)
["Do not include events","Include events"],
True), incsources = BooleanOption(_("Include sources"),False)
'incaddresses': ("=0/1","Whether to include addresses.", incsources.set_help(_("Whether to include source references."))
["Do not include addresses","Include addresses"], menu.add_option(category_name,"incsources",incsources)
True),
'incsources' : ("=0/1","Whether to include source references.", incmates = BooleanOption(_("Include spouses"),False)
["Do not include sources","Include sources"], incmates.set_help(_("Whether to include detailed spouse information."))
True), menu.add_option(category_name,"incmates",incmates)
'incmates' : ("=0/1","Whether to include detailed spouse information.",
["Do not include spouse info","Include spouse info"], category_name = _("Missing information")
True),
} repplace = BooleanOption(_("Replace missing places with ______"),False)
repplace.set_help(_("Whether to replace missing Places with blanks."))
menu.add_option(category_name,"repplace",repplace)
repdate = BooleanOption(_("Replace missing dates with ______"),False)
repdate.set_help(_("Whether to replace missing Dates with blanks."))
menu.add_option(category_name,"repdate",repdate)
def make_default_style(self,default_style): def make_default_style(self,default_style):
"""Make the default output style for the Detailed Ancestral Report""" """Make the default output style for the Detailed Ancestral Report"""
@ -795,126 +797,6 @@ class DetDescendantOptions(ReportOptions):
Endnotes.add_endnote_styles(default_style) Endnotes.add_endnote_styles(default_style)
def add_user_options(self,dialog):
"""
Override the base class add_user_options task to add a menu that allows
the user to select the sort method.
"""
self.max_gen = gtk.SpinButton(gtk.Adjustment(1,1,100,1))
self.max_gen.set_value(self.options_dict['gen'])
self.cb_pagebreak = gtk.CheckButton (_("Page break between generations"))
self.cb_pagebreak.set_active (self.options_dict['pagebbg'])
# Full date usage
self.full_date_option = gtk.CheckButton(_("Use full dates instead of only the year"))
self.full_date_option.set_active(self.options_dict['fulldates'])
# Children List
self.list_children_option = gtk.CheckButton(_("List children"))
self.list_children_option.set_active(self.options_dict['listc'])
# Print notes
self.include_notes_option = gtk.CheckButton(_("Include notes"))
self.include_notes_option.set_active(self.options_dict['incnotes'])
# Print attributes
self.include_attributes_option = gtk.CheckButton(_("Include attributes"))
self.include_attributes_option.set_active(self.options_dict['incattrs'])
# Print callname
self.usecall = gtk.CheckButton(_("Use callname for common name"))
self.usecall.set_active(self.options_dict['usecall'])
# Replace missing Place with ___________
self.place_option = gtk.CheckButton(_("Replace missing places with ______"))
self.place_option.set_active(self.options_dict['repplace'])
# Replace missing dates with __________
self.date_option = gtk.CheckButton(_("Replace missing dates with ______"))
self.date_option.set_active(self.options_dict['repdate'])
# Add "Died at the age of NN" in text
self.age_option = gtk.CheckButton(_("Compute age"))
self.age_option.set_active(self.options_dict['computeage'])
# Omit duplicate persons, occurs when distant cousins marry
self.dupPersons_option = gtk.CheckButton(_("Omit duplicate ancestors"))
self.dupPersons_option.set_active(self.options_dict['omitda'])
#Add descendant reference in child list
self.childRef_option = gtk.CheckButton(_("Add descendant reference in child list"))
self.childRef_option.set_active(self.options_dict['desref'])
#Add photo/image reference
self.image_option = gtk.CheckButton(_("Include Photo/Images from Gallery"))
self.image_option.set_active(self.options_dict['incphotos'])
# Print alternative names
self.include_names_option = gtk.CheckButton(_("Include alternative names"))
self.include_names_option.set_active(self.options_dict['incnames'])
# Print events
self.include_events_option = gtk.CheckButton(_("Include events"))
self.include_events_option.set_active(self.options_dict['incevents'])
# Print addresses
self.include_addresses_option = gtk.CheckButton(_("Include addresses"))
self.include_addresses_option.set_active(self.options_dict['incaddresses'])
# Print sources
self.include_sources_option = gtk.CheckButton(_("Include sources"))
self.include_sources_option.set_active(self.options_dict['incsources'])
# Print Spouses
self.include_spouses_option = gtk.CheckButton(_("Include spouses"))
self.include_spouses_option.set_active(self.options_dict['incmates'])
# Add new options. The first argument is the tab name for grouping options.
# if you want to put everyting in the generic "Options" category, use
# self.add_option(text,widget) instead of self.add_frame_option(category,text,widget)
dialog.add_option(_('Generations'),self.max_gen)
dialog.add_option ('', self.cb_pagebreak)
dialog.add_frame_option(_('Content'),'',self.usecall)
dialog.add_frame_option(_('Content'),'',self.full_date_option)
dialog.add_frame_option(_('Content'),'',self.list_children_option)
dialog.add_frame_option(_('Content'),'',self.age_option)
dialog.add_frame_option(_('Content'),'',self.dupPersons_option)
dialog.add_frame_option(_('Content'),'',self.childRef_option)
dialog.add_frame_option(_('Include'),'',self.image_option)
dialog.add_frame_option(_('Include'),'',self.include_notes_option)
dialog.add_frame_option(_('Include'),'',self.include_attributes_option)
dialog.add_frame_option(_('Include'),'',self.include_names_option)
dialog.add_frame_option(_('Include'),'',self.include_events_option)
dialog.add_frame_option(_('Include'),'',self.include_addresses_option)
dialog.add_frame_option(_('Include'),'',self.include_sources_option)
dialog.add_frame_option(_('Include'),'',self.include_spouses_option)
dialog.add_frame_option(_('Missing information'),'',self.place_option)
dialog.add_frame_option(_('Missing information'),'',self.date_option)
def parse_user_options(self,dialog):
"""
Parses the custom options that we have added.
"""
self.options_dict['gen'] = self.max_gen.get_value_as_int()
self.options_dict['pagebbg'] = int(self.cb_pagebreak.get_active ())
self.options_dict['fulldates'] = int(self.full_date_option.get_active())
self.options_dict['listc'] = int(self.list_children_option.get_active())
self.options_dict['usecall'] = int(self.usecall.get_active())
self.options_dict['incnotes'] = int(self.include_notes_option.get_active())
self.options_dict['incattrs'] = int(self.include_attributes_option.get_active())
self.options_dict['repplace'] = int(self.place_option.get_active())
self.options_dict['repdate'] = int(self.date_option.get_active())
self.options_dict['computeage'] = int(self.age_option.get_active())
self.options_dict['omitda'] = int(self.dupPersons_option.get_active())
self.options_dict['desref'] = int(self.childRef_option.get_active())
self.options_dict['incphotos'] = int(self.image_option.get_active())
self.options_dict['incnames'] = int(self.include_names_option.get_active())
self.options_dict['incevents'] = int(self.include_events_option.get_active())
self.options_dict['incaddresses'] = int(self.include_addresses_option.get_active())
self.options_dict['incsources'] = int(self.include_sources_option.get_active())
self.options_dict['incmates'] = int(self.include_spouses_option.get_active())
#------------------------------------------------------------------------ #------------------------------------------------------------------------
# #
# #