Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
b1b5a20
Add examples/scripts folder for GrampyScript with Open-dialog previews
dsblank Jul 6, 2026
b4d7801
Move Execute button above the results notebook
dsblank Jul 6, 2026
19b2833
Show the current script's filename in the status area
dsblank Jul 6, 2026
92f3405
Make the filename label bold and borderless, with more spacing
dsblank Jul 6, 2026
64fc471
Prompt to save unsaved changes before New or Open
dsblank Jul 6, 2026
c4cacef
Add update_script_descriptions.py to keep the examples catalog in sync
dsblank Jul 6, 2026
7db2746
Add import support, custom_filter(), and delete() to GrampyScript
dsblank Jul 6, 2026
434f768
Add jedi-based Tab completion to the GrampyScript editor
dsblank Jul 6, 2026
f7e5b92
Fix status label forcing the GrampyScript gramplet wider than its con…
dsblank Jul 6, 2026
6fef538
Add a Help item to the GrampyScript Script menu
dsblank Jul 6, 2026
c24b6fc
Make example script descriptions self-hosted and generated
dsblank Jul 6, 2026
e2640e0
Append () to function completions in GrampyScript editor
dsblank Jul 7, 2026
58bc0a7
Auto-insert single-match completions instead of showing a one-row popup
dsblank Jul 7, 2026
6321511
Give age and back_references proper types in the completion stub
dsblank Jul 7, 2026
d14fd47
Give each record type its own accurate completion fields
dsblank Jul 7, 2026
f2ad0f5
Make completions consistent for callables and drop classes entirely
dsblank Jul 7, 2026
b3d409a
Hint at Tab completion in the status bar and fix New not resetting fi…
dsblank Jul 7, 2026
3a35c8f
Add completion for columns() and other void DSL functions
dsblank Jul 7, 2026
bfe1a75
Close files explicitly instead of relying on GC
dsblank Jul 7, 2026
a01627d
Fix set_*() on nested DataDict2 wrappers silently discarding changes
dsblank Jul 8, 2026
705a9f6
Fix DataList2 re-wrapping already-wrapped items and corrupting root/path
dsblank Jul 8, 2026
e7a0bce
Fix .string on GrampsType-based fields returning raw custom-text, not…
dsblank Jul 8, 2026
e73e334
Fix names property nesting alternate_names and __radd__ reversing order
dsblank Jul 8, 2026
d51fe77
Fix DataList2 fan-out of set_*() methods across all items
dsblank Jul 8, 2026
0966aff
Fix Grampy bulk changes not appearing in Undo/Redo history
dsblank Jul 8, 2026
68bd175
Merge GrampyScript: bundled example scripts, Open-dialog previews, UI…
GaryGriffin Jul 9, 2026
a142b57
GrampsAssistant: document custom_filter() and delete() DSL functions
dsblank Jul 7, 2026
00fb474
Added help URL
dsblank Jul 7, 2026
dd6ee2f
Merge GrampsAssistant: document custom_filter() and delete() DSL func…
GaryGriffin Jul 9, 2026
c9171c9
Add DateOfDeathGramplet - gramplet listing death dates sorted by mont…
javadr Jul 3, 2026
21d1ce4
DateOfDeathGramplet: add proximity sort option, fix cross-calendar so…
javadr Jul 4, 2026
8ddd554
DateOfDeathGramplet: fill translations for updated description string
javadr Jul 4, 2026
3dbc07a
upd: gpr.py
javadr Jul 9, 2026
6eea8bc
Merge DateOfDeathGramplet - gramplet listing death dates sorted by …#973
GaryGriffin Jul 9, 2026
3a58376
lxml: don't pop a blocking dialog at import when gzip/lxml is missing
eduralph Jul 9, 2026
e4f858a
Merge lxml: don't show a blocking dialog at import when lxml/gzip is …
GaryGriffin Jul 9, 2026
a6f2e20
PDFForms: added help URL
dsblank Jul 11, 2026
6cfeb01
Merge PDFForms: added help URL #984
GaryGriffin Jul 13, 2026
80527f1
GrampyScript: fix histogram IndexError, add editor conveniences
dsblank Jul 11, 2026
2f19f7d
Merge GrampyScript: fix histogram IndexError, add editor conveniences
GaryGriffin Jul 13, 2026
c9ae50d
Themes: fix TypeError on preferences_activate(initial_panel=...)
dsblank Jul 15, 2026
0cf9795
Themes: empty tests/__init__.py, GTK pinning now handled repo-wide
dsblank Jul 18, 2026
7466c0b
Merge Themes: fix TypeError on preferences_activate(initial_panel=...…
GaryGriffin Jul 18, 2026
c93d9d9
Form: drop column-size sum-to-100 warning
dsblank Jul 15, 2026
707cfcb
Merge Form: drop column-size sum-to-100 warning#986
GaryGriffin Jul 18, 2026
35ee9ac
Remove WordleGramplet
dsblank Jul 19, 2026
2215697
Fix crash in IsFamilyFilterMatchEvent filter rule
dsblank Jul 19, 2026
6483ea6
Add regression tests for IsFamilyFilterMatchEvent
dsblank Jul 19, 2026
f2344d6
Drop redundant GTK/GDK pinning in filter rule test
dsblank Jul 19, 2026
32b0eeb
Merge Fix crash in IsFamilyFilterMatchEvent filter rule#990
GaryGriffin Jul 19, 2026
7ab6a0d
Sync addons-source@maintenance/gramps61 with upstream/gramps-project …
github-actions[bot] Jul 20, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions DateOfDeathGramplet/DateOfDeathGramplet.gpr.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2026 Javad Razavian <javadr@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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
#

register(
GRAMPLET,
id="DateOfDeath",
name=_("Date of Death"),
description=_("a gramplet that displays death dates in sorted order"),
status=STABLE,
version = '1.1.1',
fname="DateOfDeathGramplet.py",
authors = ["Javad Razavian"],
authors_email = ["javadr@gmail.com"],
height=200,
gramplet="DateOfDeathGramplet",
gramps_target_version="6.1",
gramplet_title=_("Date of Death"),
help_url="Addon:DateOfDeathGramplet",
)
130 changes: 130 additions & 0 deletions DateOfDeathGramplet/DateOfDeathGramplet.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
#
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2026 Javad Razavian <javadr@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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
#

from gramps.gen.plug import Gramplet
from gramps.gen.const import GRAMPS_LOCALE as glocale
from gramps.gen.display.name import displayer as name_displayer
from gramps.gen.lib.date import Today, Date, gregorian
import gramps.gen.datehandler
from gramps.gen.plug.menu import EnumeratedListOption
try:
_trans = glocale.get_addon_translator(__file__)
except ValueError:
_trans = glocale.translation
_ = _trans.gettext


class DateOfDeathGramplet(Gramplet):
def init(self):
self.set_text(_("No Family Tree loaded."))
self.sort_mode = 'proximity'

def build_options(self):
name_sort = _("Sort dates of death by")
self.opt_sort = EnumeratedListOption(name_sort, self.sort_mode)
self.opt_sort.add_item("proximity", _("Proximity to current date"))
self.opt_sort.add_item("month_day", _("Month and day"))

self.add_option(self.opt_sort)

def save_options(self):
self.sort_mode = self.opt_sort.get_value()

def save_update_options(self, obj):
self.save_options()
self.gui.data = [self.sort_mode]
self.update()

def on_load(self):
if len(self.gui.data) >= 1:
self.sort_mode = self.gui.data[0]
else:
self.sort_mode = 'proximity'

def db_changed(self):
self.connect(self.dbstate.db, 'person-add', self.update)
self.connect(self.dbstate.db, 'person-delete', self.update)
self.connect(self.dbstate.db, 'person-update', self.update)

def main(self):
self.set_text(_("Processing..."))
database = self.dbstate.db
self.result = []

for person in database.iter_people():
death_ref = person.get_death_ref()
if not death_ref:
continue
death_event = database.get_event_from_handle(death_ref.ref)
date_of_death = death_event.get_date_object()
if not date_of_death.is_regular():
continue

self.__calculate(database, person)

sort_by = self.opt_sort.get_value()
if sort_by == "proximity":
self.result.sort(key=lambda item: -item[0])
else:
self.result.sort(key=lambda item: (item[1].get_month(),
item[1].get_day()))
self.clear_text()

for diff_days, date, person, age in self.result:
name = person.get_primary_name()
displayer = gramps.gen.datehandler.displayer
self.append_text("{}: ".format(displayer.display(date)))
self.link(name_displayer.display_name(name), "Person",
person.handle)
if age:
self.append_text(" ({})\n".format(age))
else:
self.append_text("\n")
self.append_text("", scroll_to="begin")

def __calculate(self, database, person):
today = Today()
death_ref = person.get_death_ref()
if not death_ref:
return
death_event = database.get_event_from_handle(death_ref.ref)
date_of_death = death_event.get_date_object()
if not date_of_death.is_regular():
return

death_greg = gregorian(date_of_death)
death_this_year = Date(today.get_year(),
death_greg.get_month(),
death_greg.get_day())
diff = today - death_this_year
diff_days = diff[1] * 30 + diff[2]

birth_ref = person.get_birth_ref()
age = ""
if birth_ref:
birth = database.get_event_from_handle(birth_ref.ref)
birth_date = birth.get_date_object()
if birth_date.is_regular():
age = date_of_death - birth_date

if diff_days <= 0:
self.result.append((diff_days, date_of_death, person, age))
else:
self.result.append((diff_days - 365, date_of_death, person, age))
36 changes: 36 additions & 0 deletions DateOfDeathGramplet/po/ca-local.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
msgid ""
msgstr ""
"Project-Id-Version: ca\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-07-04 00:00-0000\n"
"PO-Revision-Date: 2025-09-03 03:01+0000\n"
"Last-Translator: Adolfo Jayme Barrientos <fitojb@ubuntu.com>\n"
"Language-Team: Catalan <https://hosted.weblate.org/projects/gramps-project/"
"addons/ca/>\n"
"Language: ca\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.13.1-dev\n"

msgid "Date of Death"
msgstr "Data de defunció"

msgid "a gramplet that displays death dates in sorted order"
msgstr "un gramplet que mostra les dates de defunció ordenades"

msgid "No Family Tree loaded."
msgstr "No hi ha cap arbre familiar carregat."

msgid "Sort dates of death by"
msgstr "Ordena les dates de mort per"

msgid "Month and day"
msgstr "Mes i dia"

msgid "Proximity to current date"
msgstr "Proximitat a la data actual"

msgid "Processing..."
msgstr "Processant…"
36 changes: 36 additions & 0 deletions DateOfDeathGramplet/po/da-local.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-07-04 00:00-0000\n"
"PO-Revision-Date: 2025-02-25 16:12+0000\n"
"Last-Translator: Kaj Arne Mikkelsen <kmi@vgdata.dk>\n"
"Language-Team: Danish <https://hosted.weblate.org/projects/gramps-project/"
"addons/da/>\n"
"Language: da\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.10.2-dev\n"

msgid "Date of Death"
msgstr "Dødsdato"

msgid "a gramplet that displays death dates in sorted order"
msgstr "en gramplet der viser dødsdatoer sorteret"

msgid "No Family Tree loaded."
msgstr "Ingen stamtræ indlæst."

msgid "Sort dates of death by"
msgstr "Sorter dødsdatoerne efter"

msgid "Month and day"
msgstr "Måned og dag"

msgid "Proximity to current date"
msgstr "Nærhed til nuværende dato"

msgid "Processing..."
msgstr "Behandler…"
36 changes: 36 additions & 0 deletions DateOfDeathGramplet/po/de-local.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
msgid ""
msgstr ""
"Project-Id-Version: de\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-07-04 00:00-0000\n"
"PO-Revision-Date: 2025-05-19 21:02+0000\n"
"Last-Translator: Mirko Leonhäuser <mirko@leonhaeuser.de>\n"
"Language-Team: German <https://hosted.weblate.org/projects/gramps-project/"
"addons/de/>\n"
"Language: de\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.12-dev\n"

msgid "Date of Death"
msgstr "Todesdatum"

msgid "a gramplet that displays death dates in sorted order"
msgstr "ein Gramplet, das die Todesdaten sortiert anzeigt"

msgid "No Family Tree loaded."
msgstr "Kein Stammbaum geladen."

msgid "Sort dates of death by"
msgstr "Sortieren Sie die Sterbedaten nach"

msgid "Month and day"
msgstr "Monat und Tag"

msgid "Proximity to current date"
msgstr "Nähe zum aktuellen Datum"

msgid "Processing..."
msgstr "Verarbeite…"
37 changes: 37 additions & 0 deletions DateOfDeathGramplet/po/es-local.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
msgid ""
msgstr ""
"Project-Id-Version: GRAMPS 3.1\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-07-04 00:00-0000\n"
"PO-Revision-Date: 2026-05-04 21:37+0000\n"
"Last-Translator: Francisco Serrador <fserrador@gmail.com>\n"
"Language-Team: Spanish <https://hosted.weblate.org/projects/gramps-project/"
"addons/es/>\n"
"Language: es\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.17.1\n"

msgid "Date of Death"
msgstr "Fecha de fallecimiento"

msgid "a gramplet that displays death dates in sorted order"
msgstr "un gramplet que muestra las fechas de fallecimiento ordenadas"
"un gramplet que muestra las fechas de fallecimiento ordenadas por mes y día"

msgid "No Family Tree loaded."
msgstr "No hay ningún árbol familiar cargado."

msgid "Sort dates of death by"
msgstr "Ordenar fechas de muerte por"

msgid "Month and day"
msgstr "mes y dia"

msgid "Proximity to current date"
msgstr "Proximidad a la fecha actual"

msgid "Processing..."
msgstr "Procesando…"
39 changes: 39 additions & 0 deletions DateOfDeathGramplet/po/fa-local.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
msgid ""
msgstr ""
"Project-Id-Version: DateOfDeathGramplet\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-07-04 00:00-0000\n"
"PO-Revision-Date: 2026-07-04 12:00+0000\n"
"Last-Translator: Javad Razavian <javadr@gmail.com>\n"
"Language-Team: Persian <https://hosted.weblate.org/projects/gramps-project/"
"addons/fa/>\n"
"Language: fa\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
"X-Generator: Weblate 5.13-dev\n"

msgid "Date of Death"
msgstr "تاریخ فوت"

msgid "a gramplet that displays death dates in sorted order"
msgstr "نموداری که تاریخ‌های مرگ را به ترتیب مرتب‌شده نمایش می‌دهد"

msgid "No Family Tree loaded."
msgstr "هیچ شجره‌نامه‌ای بارگذاری نشده است."

msgid "Sort dates of death by"
msgstr "تاریخ های مرگ را بر اساس مرتب کنید"

msgid "Month and day"
msgstr "ماه و روز"

msgid "Proximity to current date"
msgstr "نزدیکی به تاریخ فعلی"

msgid "Processing..."
msgstr "در حال پردازش..."

#~ msgid "a gramplet that displays death dates sorted by month and day"
#~ msgstr "یک گرمپلت که تاریخ‌های فوت را مرتب بر اساس ماه و روز نمایش می‌دهد"
38 changes: 38 additions & 0 deletions DateOfDeathGramplet/po/fi-local.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
msgid ""
msgstr ""
"Project-Id-Version: fi\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-07-04 00:00-0000\n"
"PO-Revision-Date: 2025-02-20 13:28+0000\n"
"Last-Translator: Matti Niemelä <niememat@gmail.com>\n"
"Language-Team: Finnish <https://hosted.weblate.org/projects/gramps-project/"
"addons/fi/>\n"
"Language: fi\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.10.1-dev\n"
"Generated-By: pygettext.py 1.4\n"

msgid "Date of Death"
msgstr "Kuolinpäivä"

msgid "a gramplet that displays death dates in sorted order"
msgstr "gramplet joka näyttää kuolinpäivät järjestettynä"
"gramplet joka näyttää kuolinpäivät järjestettynä kuukauden ja päivän mukaan"

msgid "No Family Tree loaded."
msgstr "Ei sukupuuta ladattu."

msgid "Sort dates of death by"
msgstr "Lajittele kuolinpäivämäärät"

msgid "Month and day"
msgstr "Kuukausi ja päivä"

msgid "Proximity to current date"
msgstr "Läheisyys nykyiseen päivämäärään"

msgid "Processing..."
msgstr "Käsitellään…"
Loading