gedcom icon indicating copy to clipboard operation
gedcom copied to clipboard

Feature request: Add localisation support

Open tukusejssirs opened this issue 4 years ago • 3 comments

I’d be nice if we could localise the strings. I could add Slovak, Hungarian, Czech (and possible British English) strings, but for that we need to have some the L10N tool.

tukusejssirs avatar Oct 17 '19 13:10 tukusejssirs

I see you a little bit of French in the code, but it’s rather an exception than a rule.

# `gedcom`, lines 5801 to 5805
if($language eq 'French') {
  $title = ($sex eq 'M') ? 'père' : 'mère';
} else {
  $title = ($sex eq 'M') ? 'father' : 'mother';
}

tukusejssirs avatar Oct 17 '19 13:10 tukusejssirs

I've started with French to be sure. I don't know that adding L10N is enough. Adding other languages would need some work and refactoring to create a parse tree and use that to generate the output.

I am very interested in doing that.

nigelhorne avatar Oct 17 '19 13:10 nigelhorne

Of cource, this feature needs some work and the program refactoring.

As for the tool: we could use gettext (via Locale::gettext) or Locale::maketext, which is more perlish IMO.

tukusejssirs avatar Oct 17 '19 14:10 tukusejssirs