fix translation of children count to use ngettext

This commit is contained in:
Paul Franklin 2014-03-18 18:24:58 -07:00
parent 4d8b2bb7bc
commit 93f724bc47

View File

@ -35,6 +35,7 @@ Family Lines, a GraphViz-based plugin for Gramps.
# #
#------------------------------------------------------------------------ #------------------------------------------------------------------------
from gen.ggettext import gettext as _ from gen.ggettext import gettext as _
from gen.ggettext import ngettext
from functools import partial from functools import partial
#------------------------------------------------------------------------ #------------------------------------------------------------------------
@ -915,10 +916,9 @@ class FamilyLinesReport(Report):
childrenStr = None childrenStr = None
if self._incchildcount: if self._incchildcount:
child_count = len(family.get_child_ref_list()) child_count = len(family.get_child_ref_list())
# if child_count == 1: if child_count >= 1:
# childrenStr = _('1 child') childrenStr = ngettext(
if child_count > 1: "%d child", "%d children", child_count) % child_count
childrenStr = _('%d children') % child_count
label = '' label = ''
if weddingDate: if weddingDate: