This GUI hack is for Gramps 5.2, 6.0 and 6.1 versions. It needs some field testing.
I am hoping that slide-out Date Calculator will get some layout tweaking suggestions. Since this will be submitted as a core enhancement, the turnaround time for tweaks is measured in years! So let’s field test it early so it will be right when introduced in the 6.2 version. (Or will that be 7.0?)
In version 6.1, @SNoiraud created a nice upgrade to the calendar gramplets with Pull 2209. And kindly extended the enhancement to the Date Selection dialog. This expands the Daily Calendar from the original to include dual calendar selectors: (if not a Span or a Range, the right panel is preset to today())
So that helps with one of the features that was helpful during data entry but never where you needed it when you needed it.
But there is another date feature that always sends you scrambling to find it: the Date Calculator.
So here’s a hack that brings both together in a way that is easily accessible for every date field.
The Date Calculator slideout:
This new slide-out Date Calculator is useful for those obits and headstone that say: “Aged 87y 6m 5d” but don’t have a birthdate. Just use the date of death and paste in the “Aged 87y 6m 5d” as the offset. It will calculate the “Aged” as a negative offset.
I did not want to wait for 6.1… so this version is tested in 5.2 and 6.0 version. It is a simple 2 GUI file drop-in patch (a new widget and a replacement editor) to the core, with Gramps not running.
Date Calculator slide-out for the Edit Date dialog
- Slide-out panel. A narrow triangle tab on the dialog’s right edge (▸ closed, ◂ open) opens the calculator. The window grows by the panel’s width and shrinks back exactly on collapse; while open, resizing changes only the panel.
- Reference date. Prefilled from the dialog when the panel opens (unless you typed something). Blank shows the Result hint.
- Date or offset. A date, years (
5), or years/months/days as-2, 3, 10or-2y, 3m, 10d. A leading minus subtracts the whole offset. - Result to Date loads the result into the Date fields (a Range or Span keeps its type and second date).
- Result to Second Date copies the result into the Second date; the Type becomes Span unless it is already a Range or Span.
- Calculate, Copy, Clear. Clear empties all three fields.
- Drag and drop. Text (or a drag from a calendar) dropped on the panel, outside a text box, replaces the Reference date. Text boxes take drops as usual.
- Errors name the field:
Error: invalid Reference date,Error: invalid Date or offset. - Runs on stock 5.2/6.x.
markdown_renderis optional (built-in fallback).
Files: gramps/gui/editors/editdate.py (replace), gramps/gui/widgets/datecalculator.py (new).
Discourse does not allow attaching a .py or .zip here. So PM if you would like a copy of the patch files. Or manually download and install the 2 modules in the DateEditorPatch20260928.zip archive found in the Emyoulation GitHub repo .



