From dc810fc4831e8f38ae1e367bdebcab5b1be6a410 Mon Sep 17 00:00:00 2001 From: Paul Franklin Date: Wed, 26 Feb 2014 10:22:13 -0800 Subject: [PATCH] 7276: translate some punctuation marks -- partial --- gramps/gen/lib/date.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gramps/gen/lib/date.py b/gramps/gen/lib/date.py index 8e9aa5ccb..411462247 100644 --- a/gramps/gen/lib/date.py +++ b/gramps/gen/lib/date.py @@ -291,7 +291,7 @@ class Span(object): trans_text = dlocale.translation.sgettext # trans_text is a defined keyword (see po/update_po.py, po/genpot.sh) _repr = trans_text("unknown") - # FIXME all this concatenation will fail for RTL languages + # FIXME all this concatenation will fail for RTL languages -- really?? if self.valid: fdate12 = self._format(self._diff(self.date1, self.date2), dlocale) fdate12p1 = self._format(self._diff(self.date1, self.date2), @@ -413,6 +413,7 @@ class Span(object): @type dlocale: a GrampsLocale instance """ trans_text = dlocale.translation.sgettext + # trans_text is a defined keyword (see po/update_po.py, po/genpot.sh) ngettext = dlocale.translation.ngettext if diff_tuple == (-1, -1, -1): return trans_text("unknown") retval = "" @@ -424,14 +425,16 @@ class Span(object): return retval if diff_tuple[1] != 0: if retval != "": - retval += ", " + # translators: needed for Arabic, ignore otherwise + retval += trans_text(", ") retval += ngettext("%d month", "%d months", diff_tuple[1]) % diff_tuple[1] detail += 1 if self.precision == detail: return retval if diff_tuple[2] != 0: if retval != "": - retval += ", " + # translators: needed for Arabic, ignore otherwise + retval += trans_text(", ") retval += ngettext("%d day", "%d days", diff_tuple[2]) % diff_tuple[2] detail += 1 if self.precision == detail: