2465: More rules according to User Interface Object tabs
svn: r11209
This commit is contained in:
parent
6243197c54
commit
923c3c7724
44
src/Filters/Rules/Event/_HasGallery.py
Executable file
44
src/Filters/Rules/Event/_HasGallery.py
Executable file
@ -0,0 +1,44 @@
|
|||||||
|
#
|
||||||
|
# Gramps - a GTK+/GNOME based genealogy program
|
||||||
|
#
|
||||||
|
# Copyright (C) 2008 Brian G. Matherly
|
||||||
|
# Copyright (C) 2008 Jerome Rapinat
|
||||||
|
# Copyright (C) 2008 Benny Malengier
|
||||||
|
#
|
||||||
|
# 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
|
||||||
|
#
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# Standard Python modules
|
||||||
|
#
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
from gettext import gettext as _
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# GRAMPS modules
|
||||||
|
#
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
from Filters.Rules._HasGalleryBase import HasGalleryBase
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
# "Events who have images"
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
class HasGallery(HasGalleryBase):
|
||||||
|
"""Rule that checks for events who have Media object reference"""
|
||||||
|
|
||||||
|
name = _('Event with images')
|
||||||
|
description = _("Matches event with image in the gallery")
|
@ -2,7 +2,7 @@
|
|||||||
# Gramps - a GTK+/GNOME based genealogy program
|
# Gramps - a GTK+/GNOME based genealogy program
|
||||||
#
|
#
|
||||||
# Copyright (C) 2002-2006 Donald N. Allingham
|
# Copyright (C) 2002-2006 Donald N. Allingham
|
||||||
# Copyright (C) 2007 Brian G. Matherly
|
# Copyright (C) 2007-2008 Brian G. Matherly
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -30,6 +30,7 @@ from Filters.Rules._HasEventBase import HasEventBase as HasEvent
|
|||||||
from _HasType import HasType
|
from _HasType import HasType
|
||||||
from _HasMarkerOf import HasMarkerOf
|
from _HasMarkerOf import HasMarkerOf
|
||||||
from _AllEvents import AllEvents
|
from _AllEvents import AllEvents
|
||||||
|
from _HasGallery import HasGallery
|
||||||
from _HasIdOf import HasIdOf
|
from _HasIdOf import HasIdOf
|
||||||
from _RegExpIdOf import RegExpIdOf
|
from _RegExpIdOf import RegExpIdOf
|
||||||
from _HasNoteRegexp import HasNoteRegexp
|
from _HasNoteRegexp import HasNoteRegexp
|
||||||
@ -46,7 +47,8 @@ editor_rule_list = [
|
|||||||
AllEvents,
|
AllEvents,
|
||||||
HasType,
|
HasType,
|
||||||
HasIdOf,
|
HasIdOf,
|
||||||
# TODO: At the time of this writing, the GRAMPS UI does not allow setting markers for events.
|
HasGallery
|
||||||
|
# TODO: At the time of this writing, the GRAMPS UI does not allow setting markers for events. 1197 bug-report
|
||||||
# HasMarkerOf,
|
# HasMarkerOf,
|
||||||
RegExpIdOf,
|
RegExpIdOf,
|
||||||
HasNoteRegexp,
|
HasNoteRegexp,
|
||||||
|
@ -57,7 +57,7 @@ from _ChildHasIdOf import ChildHasIdOf
|
|||||||
editor_rule_list = [
|
editor_rule_list = [
|
||||||
AllFamilies,
|
AllFamilies,
|
||||||
HasRelType,
|
HasRelType,
|
||||||
HasGallery
|
HasGallery,
|
||||||
HasIdOf,
|
HasIdOf,
|
||||||
HasLDS,
|
HasLDS,
|
||||||
RegExpIdOf,
|
RegExpIdOf,
|
||||||
|
44
src/Filters/Rules/Place/_HasGallery.py
Executable file
44
src/Filters/Rules/Place/_HasGallery.py
Executable file
@ -0,0 +1,44 @@
|
|||||||
|
#
|
||||||
|
# Gramps - a GTK+/GNOME based genealogy program
|
||||||
|
#
|
||||||
|
# Copyright (C) 2008 Brian G. Matherly
|
||||||
|
# Copyright (C) 2008 Jerome Rapinat
|
||||||
|
# Copyright (C) 2008 Benny Malengier
|
||||||
|
#
|
||||||
|
# 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
|
||||||
|
#
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# Standard Python modules
|
||||||
|
#
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
from gettext import gettext as _
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# GRAMPS modules
|
||||||
|
#
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
from Filters.Rules._HasGalleryBase import HasGalleryBase
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
# "Places who have images"
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
class HasGallery(HasGalleryBase):
|
||||||
|
"""Rule that checks for places who have Media object reference"""
|
||||||
|
|
||||||
|
name = _('Place with images')
|
||||||
|
description = _("Matches place with image in the gallery")
|
@ -1,7 +1,8 @@
|
|||||||
#
|
#
|
||||||
# Gramps - a GTK+/GNOME based genealogy program
|
# Gramps - a GTK+/GNOME based genealogy program
|
||||||
#
|
#
|
||||||
# Copyright (C) 2002-2006 Donald N. Allingham
|
# Copyright (C) 2002-2007 Donald N. Allingham
|
||||||
|
# Copyright (C) 2007-2008 Brian G. Matherly
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -25,6 +26,7 @@ Package providing filter rules for GRAMPS.
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
from _AllPlaces import AllPlaces
|
from _AllPlaces import AllPlaces
|
||||||
|
from _HasGallery import HasGallery
|
||||||
from _HasIdOf import HasIdOf
|
from _HasIdOf import HasIdOf
|
||||||
from _RegExpIdOf import RegExpIdOf
|
from _RegExpIdOf import RegExpIdOf
|
||||||
from _HasNoteRegexp import HasNoteRegexp
|
from _HasNoteRegexp import HasNoteRegexp
|
||||||
@ -39,6 +41,7 @@ from _MatchesEventFilter import MatchesEventFilter
|
|||||||
|
|
||||||
editor_rule_list = [
|
editor_rule_list = [
|
||||||
AllPlaces,
|
AllPlaces,
|
||||||
|
HasGallery,
|
||||||
HasIdOf,
|
HasIdOf,
|
||||||
RegExpIdOf,
|
RegExpIdOf,
|
||||||
HasNoteRegexp,
|
HasNoteRegexp,
|
||||||
|
44
src/Filters/Rules/Source/_HasGallery.py
Executable file
44
src/Filters/Rules/Source/_HasGallery.py
Executable file
@ -0,0 +1,44 @@
|
|||||||
|
#
|
||||||
|
# Gramps - a GTK+/GNOME based genealogy program
|
||||||
|
#
|
||||||
|
# Copyright (C) 2008 Brian G. Matherly
|
||||||
|
# Copyright (C) 2008 Jerome Rapinat
|
||||||
|
# Copyright (C) 2008 Benny Malengier
|
||||||
|
#
|
||||||
|
# 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
|
||||||
|
#
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# Standard Python modules
|
||||||
|
#
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
from gettext import gettext as _
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
#
|
||||||
|
# GRAMPS modules
|
||||||
|
#
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
from Filters.Rules._HasGalleryBase import HasGalleryBase
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
# "Sources who have images"
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
class HasGallery(HasGalleryBase):
|
||||||
|
"""Rule that checks for sources who have Media object reference"""
|
||||||
|
|
||||||
|
name = _('Source with images')
|
||||||
|
description = _("Matches source with image in the gallery")
|
@ -1,7 +1,8 @@
|
|||||||
#
|
#
|
||||||
# Gramps - a GTK+/GNOME based genealogy program
|
# Gramps - a GTK+/GNOME based genealogy program
|
||||||
#
|
#
|
||||||
# Copyright (C) 2002-2006 Donald N. Allingham
|
# Copyright (C) 2002-2007 Donald N. Allingham
|
||||||
|
# Copyright (C) 2007-2008 Brian G. Matherly
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -25,6 +26,7 @@ Package providing filter rules for GRAMPS.
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
from _AllSources import AllSources
|
from _AllSources import AllSources
|
||||||
|
from _HasGallery import HasGallery
|
||||||
from _HasIdOf import HasIdOf
|
from _HasIdOf import HasIdOf
|
||||||
from _RegExpIdOf import RegExpIdOf
|
from _RegExpIdOf import RegExpIdOf
|
||||||
from _HasNoteRegexp import HasNoteRegexp
|
from _HasNoteRegexp import HasNoteRegexp
|
||||||
@ -36,6 +38,7 @@ from _HasSource import HasSource
|
|||||||
|
|
||||||
editor_rule_list = [
|
editor_rule_list = [
|
||||||
AllSources,
|
AllSources,
|
||||||
|
HasGallery,
|
||||||
HasIdOf,
|
HasIdOf,
|
||||||
RegExpIdOf,
|
RegExpIdOf,
|
||||||
HasNoteRegexp,
|
HasNoteRegexp,
|
||||||
|
Loading…
Reference in New Issue
Block a user