From kde-i18n-doc Thu Oct 19 10:43:27 2023 From: Yaron Shahrabani Date: Thu, 19 Oct 2023 10:43:27 +0000 To: kde-i18n-doc Subject: Re: Hebrew plural forms Message-Id: X-MARC-Message: https://marc.info/?l=kde-i18n-doc&m=169771206224237 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--000000000000ac897906080f6ebe" --000000000000ac897906080f6ebe Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sounds reasonable, you said it's possible to apply only on KF6, if so I don't think it should be a problem. Thank you :) Yaron Shahrabani On Thu, Oct 19, 2023 at 8:56=E2=80=AFAM Johnny Jazeix wr= ote: > Hi Yaron, > depending on your need, there is polib in python > (https://polib.readthedocs.io/en/latest/quickstart.html) which should > allow you to browse the files and find which ones have plurals, and > update them if needed. There are probably other tools but that is the > one I know :). > > The fuzzy should keep the values for 1 and 2, so copying it the second > translation to the fourth form should be doable (it would still need > review but should lessen the work). > > Cheers, > > Johnny > > Le mer. 18 oct. 2023 =C3=A0 23:57, Albert Astals Cid a = =C3=A9crit : > > > > El dimecres, 18 d=E2=80=99octubre de 2023, a les 22:17:01 (CEST), Yaron > Shahrabani va > > escriure: > > > I bet there is :) > > > The new plural form will require some string modifications in additio= n > to > > > the header. > > > > > > The current formula is as follows: > > > [1 - 1] %d house > > > [2 - !1] %d houses > > > > > > The new formula is a bit more complex: > > > [1 - 1] %d house > > > [2 - 2] %d/two houses > > > [3 - X%10 =3D=3D 0 when X is larger than 10] %d house > > > [4 - !1/!2] %d houses (matches the second form in the current formula= ) > > > > > > So one option would be just breaking all the plural strings, > > > > Not breaking, but marking them as fuzzy, yes, that's what the script > does. > > > > Cheers, > > Albert > > > > > the second > > > would be copying the 2nd form to the 3rd and 4th (won't break the > string > > > but I'll need to fix it manually). > > > I can try and think of a way to handle this completely automatically > but I > > > don't think it's worth the trouble. > > > > > > So merely changing the form is not enough. > > > Thanks :) > > > Yaron Shahrabani > > > > > > > > > > > > On Wed, Oct 18, 2023 at 11:08=E2=80=AFPM Albert Astals Cid > wrote: > > > > El dissabte, 14 d=E2=80=99octubre de 2023, a les 22:37:21 (CEST), Y= aron > Shahrabani > > > > va > > > > > > > > escriure: > > > > > I'm really hoping we can find a way to pull this off, it'll requi= re > > > > > human > > > > > resources beyond our reach. > > > > > > > > > > I can try and think about a way to do this automatically but I'm > afraid > > > > > > > > it > > > > > > > > > won't be perfect. > > > > > > > > Do what automatically? > > > > > > > > Change the plural definition for all files? > > > > > > > > We have a script to do that. > > > > > > > > Cheers, > > > > > > > > Albert > > > > > > > > > Are there any examples of other languages that switched plural > forms in > > > > > > > > KDE > > > > > > > > > along their history? > > > > > > > > > > Thanks. > > > > > Yaron Shahrabani > > > > > > > > > > > > > > > > > > > > On Tue, Oct 10, 2023 at 10:44=E2=80=AFAM Johnny Jazeix > wrote: > > > > > > Le mar. 10 oct. 2023 =C3=A0 09:38, Yaron Shahrabani < > sh.yaron@gmail.com> a > > > > > > > > > > > > =C3=A9crit : > > > > > > > So what about my first question, it only applies to new > submissions? > > > > > > > > > > > > Hi, > > > > > > It is for all the files or none. We cannot change the plural > forms for > > > > > > only some files. > > > > > > > > > > > > Cheers > > > > > > Johnny > > > > > > > > > > > > > On Sat, Oct 7, 2023, 01:35 Albert Astals Cid > wrote: > > > > > > >> El divendres, 6 d=E2=80=99octubre de 2023, a les 22:33:21 (C= EST), > Yaron > > > > > > > > > > > > Shahrabani va > > > > > > > > > > > > >> escriure: > > > > > > >> > Hey, if it's only relevant for new submissions that's fine= , > > > > > > > > applying > > > > > > > > > > that > > > > > > > > > > > > >> > to all current files will be very cumbersome. > > > > > > >> > Is there a way to accept both? > > > > > > >> > > > > > > >> All KDE files for a given language must have the same plural > > > > > > >> definition. > > > > > > >> > > > > > > >> Cheers, > > > > > > >> > > > > > > >> Albert > > > > > > >> > > > > > > >> > Yaron Shahrabani > > > > > > >> > > > > > > > >> > > > > > > > >> > > > > > > > >> > On Fri, Oct 6, 2023 at 11:17=E2=80=AFPM Albert Astals Cid = < > aacid@kde.org> > > > > > > > > > > > > wrote: > > > > > > >> > > El dijous, 5 d=E2=80=99octubre de 2023, a les 20:27:44 (= CEST), > Yaron > > > > > > > > > > > > Shahrabani va > > > > > > > > > > > > >> > > escriure: > > > > > > >> > > > Over the last couple of days I ran into a problem wher= e > the > > > > > > > > > > > > gettext > > > > > > > > > > > > >> > > > files > > > > > > >> > > > I've submitted caused all sorts of issues with Scripty= . > > > > > > >> > > > > > > > > > >> > > > KDE is still using the old plural form for Hebrew (2 > cases): > > > > > > >> > > > "Plural-Forms: nplurals=3D2; plural=3Dn !=3D 1;\n" > > > > > > >> > > > > > > > > > >> > > > Several years ago this formula was changed to reflect > some > > > > > > > > rare > > > > > > > > > > cases in > > > > > > > > > > > > >> > > > Hebrew. > > > > > > >> > > > The new official formula is: > > > > > > >> > > > > > > > > > >> > > > "Plural-Forms: nplurals=3D4; plural=3D(n =3D=3D 1) ? 0= : ((n =3D=3D > 2) ? > > > > > > > > 1 : > > > > > > ((n > > > > > > > > > > > > > >> > > > 10 > > > > > > >> > > > && n % 10 =3D=3D 0) ? 2 : 3));\n" > > > > > > > > > > >> > > > This is documented here: > > > > > http://www.unicode.org/cldr/cldr-aux/charts/22/supplemental/language_plur= a > > > > > > > > > > >> > > l_> > > > > > > >> > > > > > > > > >> > > > rules.html > > > > > > >> > > > > > > > > > >> > > > I've been using this formula for several years now. > > > > > > >> > > > Some other projects implementing it: > > > > > > >> > > > Weblate, Transifex, Crowding, Poedit and many others. > > > > > > >> > > > > > > > > > >> > > > Since the actual cases for using this formula are rare > (time > > > > > > > > > > > > related > > > > > > > > > > > > >> > > terms > > > > > > >> > > > > > > > > >> > > > - hours, days, months, years, times) it's not always > > > > > > > > necessary to > > > > > > > > > > use it > > > > > > > > > > > > >> > > so > > > > > > >> > > > > > > > > >> > > > supporting the older formula in addition to the new on= e > is > > > > > > > > > > > > definitely a > > > > > > > > > > > > >> > > > good option for now. > > > > > > >> > > > > > > > > >> > > We can change to the new formula, but that means > invalidating > > > > > > > > all > > > > > > > > > > plurals > > > > > > > > > > > > >> > > that > > > > > > >> > > use the nplurals=3D2 formula, is that ok for you? > > > > > > >> > > > > > > > > >> > > Cheers, > > > > > > >> > > > > > > > > >> > > Albert > > > > > > >> > > > > > > > > >> > > > Thank you, > > > > > > >> > > > Yaron Shahrabani > > > > > > >> > > > > > > > > > >> > > > > > > > > > > > > --000000000000ac897906080f6ebe Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Sounds reasonable, you said it's possible to=C2=A0 apply onl= y on KF6, if so I don't think it should be a problem.

Thank you :)=
Yaron Shahrabani=
<DevOps - Heb= rew translator>
=


On Thu, Oct 19, 2023 at 8:56=E2=80=AFAM Johnn= y Jazeix <jazeix@gmail.com> w= rote:
Hi Yaron,<= br> depending on your need, there is polib in python
(https://polib.readthedocs.io/en/latest/quicks= tart.html) which should
allow you to browse the files and find which ones have plurals, and
update them if needed. There are probably other tools but that is the
one I know :).

The fuzzy should keep the values for 1 and 2, so copying it the second
translation to the fourth form should be doable (it would still need
review but should lessen the work).

Cheers,

Johnny

Le mer. 18 oct. 2023 =C3=A0 23:57, Albert Astals Cid <aacid@kde.org> a =C3=A9crit :
>
> El dimecres, 18 d=E2=80=99octubre de 2023, a les 22:17:01 (CEST), Yaro= n Shahrabani va
> escriure:
> > I bet there is :)
> > The new plural form will require some string modifications in add= ition to
> > the header.
> >
> > The current formula is as follows:
> > [1 - 1] %d house
> > [2 - !1] %d houses
> >
> > The new formula is a bit more complex:
> > [1 - 1] %d house
> > [2 - 2] %d/two houses
> > [3 - X%10 =3D=3D 0 when X is larger than 10] %d house
> > [4 - !1/!2] %d houses (matches the second form in the current for= mula)
> >
> > So one option would be just breaking all the plural strings,
>
> Not breaking, but marking them as fuzzy, yes, that's what the scri= pt does.
>
> Cheers,
>=C2=A0 =C2=A0Albert
>
> > the second
> > would be copying the 2nd form to the 3rd and 4th (won't break= the string
> > but I'll need to fix it manually).
> > I can try and think of a way to handle this completely automatica= lly but I
> > don't think it's worth the trouble.
> >
> > So merely changing the form is not enough.
> > Thanks :)
> > Yaron Shahrabani
> >
> > <DevOps - Hebrew translator>
> >
> > On Wed, Oct 18, 2023 at 11:08=E2=80=AFPM Albert Astals Cid <aacid@kde.org> wrot= e:
> > > El dissabte, 14 d=E2=80=99octubre de 2023, a les 22:37:21 (C= EST), Yaron Shahrabani
> > > va
> > >
> > > escriure:
> > > > I'm really hoping we can find a way to pull this of= f, it'll require
> > > > human
> > > > resources beyond our reach.
> > > >
> > > > I can try and think about a way to do this automaticall= y but I'm afraid
> > >
> > > it
> > >
> > > > won't be perfect.
> > >
> > > Do what automatically?
> > >
> > > Change the plural definition for all files?
> > >
> > > We have a script to do that.
> > >
> > > Cheers,
> > >
> > >=C2=A0 =C2=A0Albert
> > >
> > > > Are there any examples of other languages that switched= plural forms in
> > >
> > > KDE
> > >
> > > > along their history?
> > > >
> > > > Thanks.
> > > > Yaron Shahrabani
> > > >
> > > > <DevOps - Hebrew translator>
> > > >
> > > > On Tue, Oct 10, 2023 at 10:44=E2=80=AFAM Johnny Jazeix = <jazeix@gmail.com<= /a>> wrote:
> > > > > Le mar. 10 oct. 2023 =C3=A0 09:38, Yaron Shahraban= i <
sh.yaron@gmai= l.com> a
> > > > >
> > > > > =C3=A9crit :
> > > > > > So what about my first question, it only appl= ies to new submissions?
> > > > >
> > > > > Hi,
> > > > > It is for all the files or none. We cannot change = the plural forms for
> > > > > only some files.
> > > > >
> > > > > Cheers
> > > > > Johnny
> > > > >
> > > > > > On Sat, Oct 7, 2023, 01:35 Albert Astals Cid = <aacid@kde.org>= ; wrote:
> > > > > >> El divendres, 6 d=E2=80=99octubre de 2023= , a les 22:33:21 (CEST), Yaron
> > > > >
> > > > > Shahrabani va
> > > > >
> > > > > >> escriure:
> > > > > >> > Hey, if it's only relevant for n= ew submissions that's fine,
> > >
> > > applying
> > >
> > > > > that
> > > > >
> > > > > >> > to all current files will be very cu= mbersome.
> > > > > >> > Is there a way to accept both?
> > > > > >>
> > > > > >> All KDE files for a given language must h= ave the same plural
> > > > > >> definition.
> > > > > >>
> > > > > >> Cheers,
> > > > > >>
> > > > > >>=C2=A0 =C2=A0Albert
> > > > > >>
> > > > > >> > Yaron Shahrabani
> > > > > >> >
> > > > > >> > <DevOps - Hebrew translator> > > > > > >> >
> > > > > >> > On Fri, Oct 6, 2023 at 11:17=E2=80= =AFPM Albert Astals Cid <aacid@kde.org>
> > > > >
> > > > > wrote:
> > > > > >> > > El dijous, 5 d=E2=80=99octubre = de 2023, a les 20:27:44 (CEST), Yaron
> > > > >
> > > > > Shahrabani va
> > > > >
> > > > > >> > > escriure:
> > > > > >> > > > Over the last couple of da= ys I ran into a problem where the
> > > > >
> > > > > gettext
> > > > >
> > > > > >> > > > files
> > > > > >> > > > I've submitted caused = all sorts of issues with Scripty.
> > > > > >> > > >
> > > > > >> > > > KDE is still using the old= plural form for Hebrew (2 cases):
> > > > > >> > > > "Plural-Forms: nplura= ls=3D2; plural=3Dn !=3D 1;\n"
> > > > > >> > > >
> > > > > >> > > > Several years ago this for= mula was changed to reflect some
> > >
> > > rare
> > >
> > > > > cases in
> > > > >
> > > > > >> > > > Hebrew.
> > > > > >> > > > The new official formula i= s:
> > > > > >> > > >
> > > > > >> > > > "Plural-Forms: nplura= ls=3D4; plural=3D(n =3D=3D 1) ? 0 : ((n =3D=3D 2) ?
> > >
> > > 1 :
> > > > > ((n >
> > > > >
> > > > > >> > > > 10
> > > > > >> > > > && n % 10 =3D=3D 0= ) ? 2 : 3));\n"
> > >
> > > > > >> > > > This is documented here: > > > http://www.= unicode.org/cldr/cldr-aux/charts/22/supplemental/language_plura
> > >
> > > > > >> > > l_>
> > > > > >> > >
> > > > > >> > > > rules.html
> > > > > >> > > >
> > > > > >> > > > I've been using this f= ormula for several years now.
> > > > > >> > > > Some other projects implem= enting it:
> > > > > >> > > > Weblate, Transifex, Crowdi= ng, Poedit and many others.
> > > > > >> > > >
> > > > > >> > > > Since the actual cases for= using this formula are rare (time
> > > > >
> > > > > related
> > > > >
> > > > > >> > > terms
> > > > > >> > >
> > > > > >> > > > - hours, days, months, yea= rs, times) it's not always
> > >
> > > necessary to
> > >
> > > > > use it
> > > > >
> > > > > >> > > so
> > > > > >> > >
> > > > > >> > > > supporting the older formu= la in addition to the new one is
> > > > >
> > > > > definitely a
> > > > >
> > > > > >> > > > good option for now.
> > > > > >> > >
> > > > > >> > > We can change to the new formul= a, but that means invalidating
> > >
> > > all
> > >
> > > > > plurals
> > > > >
> > > > > >> > > that
> > > > > >> > > use the nplurals=3D2 formula, i= s that ok for you?
> > > > > >> > >
> > > > > >> > > Cheers,
> > > > > >> > >
> > > > > >> > >=C2=A0 =C2=A0Albert
> > > > > >> > >
> > > > > >> > > > Thank you,
> > > > > >> > > > Yaron Shahrabani
> > > > > >> > > >
> > > > > >> > > > <DevOps - Hebrew transl= ator>
>
>
>
>
--000000000000ac897906080f6ebe--