Created attachment 153304 [details] Screenshot wrong plural form hsb in Writer word count Hi, there is a bug in Upper Sorbian and Lower Sorbian Writer. In status bar, the wordcount is displayed. But, in Upper Sorbian and Lower Sorbian Writer the wrong plural rule is used, probably the English plural rule instead of the Sorbian rules. Both Sorbian languages have 4 plural forms, singular, dual, plural nominitive and plural genitive. Here are the forms for the word "character" in Upper Sorbian and Lower Sorbian: Upper Sorbian: 1, 101, 201, etc. znamješko 2, 102, 202, etc. znamješce 3, 103, 203, etc. - 4. 104, 204, etc. znamješka 5 - 100, 105 - 200, 205 - 300. etc. znamješkow The Lower Sorbian words are znamuško, znamušce, znamuška, znamuškow. LibreOffice uses 2 forms only, the singular form znamješko/znamuško and the dual form znamješce/znamušce. Please fix this. Please find attached a screenshot of Upper Sorbian Writer. In the screenshot, the word has 9 characters and the Sorbian form znamješkow should be used. But, it is used znamješce instead. That's wrong. Thanks
In addition to this, the last form znamješkow/znamuškow is used for 0 as well. With decimals, the last digit rules the plural form.
Hi, I'm already waiting for 2 months for a reply to this bug. Please try fix this bug. Thanks.
@Eike, I thought you might be interested in this issue...
Not my construction site. The resource strings to be translated are only singular and plural cases and combinations thereof, I guess likely the code doesn't handle anything else. See https://opengrok.libreoffice.org/xref/core/sw/inc/strings.hrc?r=ed200d9f#293
Xisco: I can change a translation on Weblate but I don't know how to add some translations so can't help here.
(In reply to Julien Nabet from comment #5) > Xisco: I can change a translation on Weblate but I don't know how to add > some translations so can't help here. Hi Julien, I don't know what you want to translate. The strings have been already translated, with the correct plural forms. It is about following strings: https://weblate.documentfoundation.org/translate/libo_ui-master/swmessages/hsb/?type=all&offset=375 https://weblate.documentfoundation.org/translate/libo_ui-master/swmessages/hsb/?type=all&offset=376 https://weblate.documentfoundation.org/translate/libo_ui-master/swmessages/hsb/?type=all&offset=378 https://weblate.documentfoundation.org/translate/libo_ui-master/swmessages/hsb/?type=all&offset=379 Even the plural equation is shown with each of these strings. this s for Upper Sorbian. The same applies to Lower Sorbian.
(In reply to milupo from comment #6) > (In reply to Julien Nabet from comment #5) > > Xisco: I can change a translation on Weblate but I don't know how to add > > some translations so can't help here. > > Hi Julien, > > I don't know what you want to translate. The strings have been already > translated, with the correct plural forms. It is about following strings: > ... So if everything is ok on Weblate, I don't know how I can help since it doesn't seem trivial -> uncc myself
The Sorbian plural rules are not correctly applied. Obviously, only 2 of the 4 Sorbian forms are used, singular and plural. That's the English rule.
(In reply to milupo from comment #8) > The Sorbian plural rules are not correctly applied. Obviously, only 2 of the > 4 Sorbian forms are used, singular and plural. That's the English rule. The thing is, the English rule is also the plurality rule for a lot of other languages. Sorbian is unique/special in the sense that very few languages share its rule of four singular/plural forms. The LibreOffice code most likely doesn't know how to handle 4-form nouns yet, that's what Julien meant by "doesn't seem trivial".
Looking at https://opengrok.libreoffice.org/xref/core/sw/inc/strings.hrc?r=0c1ab11c#296 it seems to me LO indeed assumes that "word" has at most two plurality forms for all languages. So not trivial indeed.
let's make it an enhancement then...
(In reply to zh_CN User Community Liaison from comment #9) > > The LibreOffice code most likely doesn't know how to handle 4-form nouns > yet, that's what Julien meant by "doesn't seem trivial". That's not true. Slovenian has a similar plural rule with 4 forms and for Slovenian the rule works here. So, this bug is not a problem for LibreOffice, it is simply a bug which can be fixed.
(In reply to milupo from comment #12) > (In reply to zh_CN User Community Liaison from comment #9) > > > The LibreOffice code most likely doesn't know how to handle 4-form nouns > > yet, that's what Julien meant by "doesn't seem trivial". > > That's not true. Slovenian has a similar plural rule with 4 forms and for > Slovenian the rule works here. So, this bug is not a problem for > LibreOffice, it is simply a bug which can be fixed. I stand corrected. Comparing the Slovenian PO file https://opengrok.libreoffice.org/xref/translations/source/sl/sw/messages.po?r=4960b59e#1916 and the Upper Sorbian one https://opengrok.libreoffice.org/xref/translations/source/hsb/sw/messages.po?r=708eb821#2290 the format of the translations seem identical to me. The "Plural-Forms:" line are slightly different but both seem legit. Someone with more expertise in gettext than I is needed here.
I think I have some more findings to share. The Upper Sorbian PO file on libreoffice-6-3-3 branch (and I assume libreoffice-6-3 branch as well) doesn't have a proper "Plural-Forms:" line: https://gerrit.libreoffice.org/plugins/gitiles/translations/+/libreoffice-6-3-3/source/hsb/sw/messages.po @milupo: What is the LibreOffice verion of your screenshot? If it's 6.3.x, can you test with master? I guess perhaps the 6.3 branches still use Pootle and Pootle doesn't support 4-form nouns?
I have LO 6.3.3.1 and the issue still exists.
I've just installed LO 6.3.3.2 and the issue still exists, too.
(In reply to milupo from comment #16) > I've just installed LO 6.3.3.2 and the issue still exists, too. By "test with master", I mean testing one of those daily builds for master branch: https://wiki.documentfoundation.org/QA/Testing_Daily_Builds or maybe the recently released 6.4.0 alpha1: https://www.libreoffice.org/download/download/?version=6.4.0 This bug should be fixed there. Testing 6.3.3.1 and 6.3.3.2 are not particulary useful since your initial report was against 6.3.0 release.
> By "test with master", I mean testing one of those daily builds for master > branch: > https://wiki.documentfoundation.org/QA/Testing_Daily_Builds > or maybe the recently released 6.4.0 alpha1: > https://www.libreoffice.org/download/download/?version=6.4.0 > This bug should be fixed there. > Hm, AFAIK Daily builds contain English only. But I will test.
(In reply to milupo from comment #18) > Hm, AFAIK Daily builds contain English only That's probably right, I've never used them myself. But 6.4.0 alpha1 definitely has all the languages, so please start with that one.
Hi, the bug is fixed, both for hsb and dsb. You can mark it as resolved. Thank you to all for their help.
(In reply to milupo from comment #20) > Hi, > > the bug is fixed, both for hsb and dsb. You can mark it as resolved. > > Thank you to all for their help. Hello, Could you please share the link where it got fixed ?
Hi Xisco, I wanted to download it from the Preleases directory but the download time was very low when I wanted to do that. Therefore I downloaded it from the Testing directory: http://download.documentfoundation.org/libreoffice/testing/6.4.0/win/x86_64/ I tested Win x86_64 only.
Just re reading all this, it seems ok from 6.4.0 6.4.2 can be downloaded from https://www.libreoffice.org/download/download/ Let's put this one to WFM then. milupo: don't hesitate to reopen this tracker if you still reproduce this.
Hi Julien, yes, the issue is resolved since 6.4.0, see my comment #20. I currently use version 6.4.3.1 and all is OK.
(In reply to Xisco Faulí from comment #21) > (In reply to milupo from comment #20) > > Hi, > > > > the bug is fixed, both for hsb and dsb. You can mark it as resolved. > > > > Thank you to all for their help. > > Hello, > Could you please share the link where it got fixed ? @Xisco, I assume you were asking this because you want to point at a commit/change that fixes this bug. As far as I understand, this bug was fixed not because of a specific code change, but because of the transition from Pootle to Weblate by the l10n team, which happened between 6-3 branch and 6-4 branch. The old Pootle platform and workflow doesn't put the needed correct "Plural-Forms:" field in the PO files. The Slovenian team had to avoid Pootle and directly commit to git repo before this transition. Just FYI.