Gramplet/birthdays gramplet#974
Conversation
Previously entries were sorted by proximity to today's date (nearest birthdays first). Now they are sorted by month then day, giving a consistent calendar-order listing.
…rth date to Gregorian
|
The latest commit (71261d8) is a hot fix to a 16 year-old bug! It fixes proximity sort for non-Gregorian birth dates Date(y, m, d) always creates a Gregorian date, but the code was extracting month/day directly from birth_date — so a Persian date of Farvardin 1 (~March 21) became January 1 Gregorian, producing wrong proximity values and broken sort order. Fix: convert birth_date to Gregorian via gregorian() before constructing birthday_this_year, so month/day values match the calendar today uses. |
|
String translations are done in Weblate and then pushed to all of the addons. The changes to xx-local.po will be overwritten by Weblate. |
|
Do you want this on gramps60 branch instead of 61? All Addons PRs for gramps60 are being cherry picked to 61 also. |
|
Since I have Gramps 6.0 on my local machine, I would prefer to have it available on both branches. I'm not completely sure, but I have a feeling it should work with earlier versions as well. |
|
Great find with 71261d8 fix! I'm going to make sure we don't make that mistake in other places in gramps core, or other addons. Thanks! |
|
Added a new method in gramps-project/gramps#2459, but it won't be available until gramps 6.2. |
Here's a PR comment for the changes:
BirthdaysGramplet: add sort mode option, set default to proximity