From 8d0ae96b7ddd9cc770285d945733752809dec3d9 Mon Sep 17 00:00:00 2001 From: Paul Franklin Date: Thu, 19 Mar 2015 19:41:51 -0700 Subject: [PATCH] slight tweak to date displayer, for Finnish --- gramps/gen/datehandler/_datedisplay.py | 8 +++++++- gramps/gen/datehandler/_datestrings.py | 6 ++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/gramps/gen/datehandler/_datedisplay.py b/gramps/gen/datehandler/_datedisplay.py index 908b4ae29..4028be35a 100644 --- a/gramps/gen/datehandler/_datedisplay.py +++ b/gramps/gen/datehandler/_datedisplay.py @@ -407,11 +407,17 @@ class DateDisplay(object): else: date_type = "" text = self.display_cal[cal](start, inflect=date_type) + modifier = self._mod_str[mod] + # some languages have a modifier after the date (e.g. Finnish) + # (if so, they are specified in DateParser.modifier_after_to_int) + if modifier.startswith(' '): + text += modifier + modifier = '' scal = self.format_extras(cal, newyear) return _("{date_quality}{noncompound_modifier}{date}" "{nonstd_calendar_and_ny}").format( date_quality=qual_str, - noncompound_modifier=self._mod_str[mod], + noncompound_modifier=modifier, date=text, nonstd_calendar_and_ny=scal) diff --git a/gramps/gen/datehandler/_datestrings.py b/gramps/gen/datehandler/_datestrings.py index 6039bdadb..403e783a9 100644 --- a/gramps/gen/datehandler/_datestrings.py +++ b/gramps/gen/datehandler/_datestrings.py @@ -205,8 +205,14 @@ class DateStrings(object): ) self.modifiers = ("", + # TRANSLATORS: if the modifier is after the date + # put the space ahead of the word instead of after it _("date modifier|before "), + # TRANSLATORS: if the modifier is after the date + # put the space ahead of the word instead of after it _("date modifier|after "), + # TRANSLATORS: if the modifier is after the date + # put the space ahead of the word instead of after it _("date modifier|about "), "", "", "")