Closed jpretired closed 3 years ago
And I thought that German is a complicated language ...
Let me try to understand that. You can not translate the combined sentence "x has n1 grandson(s) and n2 granddaughter(s) recorded.", because you don't know if 2 <= n1+n2 <= 4 or n1+n2 > 4? Right?
Ok, then we have to make two sentences out of this as you have suggested: "x has n1 grandson(s) recorded. " and "He/She has n2 granddaughter(s) recorded." Ok? This ("He/She") sounds better that repeating the same sentence two times. OK?
I have never seen this sequence with three parts like '%s má %d vnuka. ' . I18N::PLURAL . '%s má %d vnuky. ' . I18N::PLURAL . '%s má %d vnuků. '. So I just learned a new thing. Thank you!
No, Hermann, you probably do not understand me yet. The 'combined' translation sentence you mention is OK. The issue is in case when the person has either only grandsons (2 and more) or only granddaughters (2 and more). Please give me some time to express my solution more clearly.
ok, then I got it. I will change the cases with only grandsons (2 and more) or only granddaughters (2 and more) from "translate" to I18N::PLURAL as proposed by you.
... done in Czech translation for 2 and more (only) grandsons and 2 and more (only) granddaughters. Modified in German and Dutch, too.
Can you check if it is ok now, please? Do we need this now in other parts, too?
I downloaded the latest 2.0.16.20 but cannot run it. Blank screen! Don't know why.
Sorry, forget it, it was my fault. Please wait with translations, I made a few changes in both tab.phtml and module.php. I will inform you asap.
I had this problem in the last weeks from time to time, too. But I do not know why. I didn't have it when I'm logged in, only when I'm logged out. Maybe try to logout and login again. If the reason is my module, I need help to find the reason.
Ok, I see that your problem is solved now. You have a lot of time because next week I don't have much time.
I suggest I will do all the changes regarding translations:
Go! Do it! Good idea! Thank you!
Here I am appending the final (hopefully) version as to Czech, German and Dutch translations discussed earlier in this issue. Based on 2.0.16.20. The .zip archive contains both module.php and tab.phtml. hh_extended_family-module-and-tab.zip
Thank you a lot! I only found in tab.phtml one "grandmotherss". I will integrate your contribution in the next release.
Within translations in each part there are pairs of phrases which cannot be properly translated into Czech as they are. These are e.g. in Grandchildren (and similar pairs in all other parts): '%s has %d female grandchildren recorded.' => ... '%s has %d male grandchildren recorded.' => ... They are plurals. In Czech each of them needs to be translated into two different plural phrases according to plural rule which is shown in webtrees script: /vendor/fisharebest/localization/src/PluralRule/PluralRule8.php In Czech one plural is for (%d>=2 && %d<=4) and the other plural for %d>4.
It means that it should look like this: '%s has %d male grandchild recorded. ' . I18N::PLURAL . '%s has %d male grandchildren recorded. ' => '%s má %d vnuka. ' . I18N::PLURAL . '%s má %d vnuky. ' . I18N::PLURAL . '%s má %d vnuků. ',
Then the corresponding code in '/views/tab.phtml' would be: ` <?php if ($extfam_obj->Grandchildren->femaleCount == 0): ?>
= I18N::plural('%s has %d male grandchild recorded.', '%s has %d male grandchildren recorded.', $extfam_obj->Grandchildren->maleCount, $extfam_obj->Self->niceName, $extfam_obj->Grandchildren->maleCount) ?>
`
The result is
The same change should be done to 'female grandchild' and to the pairs in all other parts of translation.