[Kbabel] Default behaviors (header-wise) in KBabel

Nicolas Goutte nicolasg at snafu.de
Fri Oct 28 16:57:09 CEST 2005


On Friday 28 October 2005 15:49, Daichi Kawahata wrote:
> On Fri, 28 Oct 2005 14:58:07 +0200
>
> Nicolas Goutte wrote:

Here a quick answer. I have not checked directly with KBabel yet. (I will try 
to do so in a few hours.)

> > >   o It replaces given proper header string at `Project-Id-Version'
> > >     with ISO 639 language code.
> >
> > In fact it is the filename that it places there.
> >
> > (In KDE, PO files are not named by the language but like the
> > corresponding POT file. And the directories are ordered by language, not
> > by POT file.)
>
> Probably so, but I've seen many times the following case from KBabel:
>
>     -"Project-Id-Version: Mousepad 0.2.2\n"
>     +"Project-Id-Version: ca\n"

Yes, because in your project, the PO files are named like the language code: 
ca.po . KBabel drops the .po extension and uses the basename as project name.

That is convenient in KDE, apparently not at all for you.

>
> This clearly discarded proper give information.

Because by default KBabel is told to do so.

> When KBabel appears
> in the header, modified files tend to sound a discord like below:
>
>     $ grep Project-Id-Version *.po
>     ca.po:"Project-Id-Version: ca\n"
>     cs.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     de.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     el.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     es.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     eu.po:"Project-Id-Version: Mosuepad\n"
>     fr.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     gu.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     hu.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     it.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     ja.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     lt.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     pl.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     pt_BR.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     ru.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     sk.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     sv.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     ta.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     zh_CN.po:"Project-Id-Version: Mousepad 0.2.2\n"
>     zh_TW.po:"Project-Id-Version: Mousepad 0.2.2\n"
>
> Yeah, Basque translator also uses KBabel (typo in project name...),
> and next part,
>
>      "Report-Msgid-Bugs-To: \n"
>      "POT-Creation-Date: 2005-10-21 17:30+0900\n"
>     -"PO-Revision-Date: 2005-10-07 18:36+0900\n"
>     -"Last-Translator: David Rosal <davidrr at users.sourceforge.net>\n"
>     -"Language-Team: Catalan <ca at dodds.net>\n"
>     +"PO-Revision-Date: 2005-10-27 22:30+0200\n"
>     +"Last-Translator: paurullan <paurullan at bulma.net>\n"
>     +"Language-Team: catala`\n"
>
> also given language team information is discarded,
> translator name is given by Unix-like user name too.

The user name is the one given to KBabel. I am not sure if KBabel tries to use 
the system user name by default but anyway that can be changed too.

>
> My point was why KBabel discards given values every per file
> saving? 

Because it is the default setting.

> Is there any option `Disable force over writing at save'?

Yes, there is an option to leave the header unmodified. (There is even more 
finer control if I remember well.)

> I really hope KBabel honors proper give strings.
>
> > >   o It keeps leaving strange comments at initial comment part.
> >
> > I have tried to limit the impact of the "strange comments" in
> > the KBabel version for KDE 3.5 by trying to remove all old strings
> > of the kind.
> >
> > However in your case, it seems that your name has been given in 2
> > different forms, so that KBabel cannot find that it is the same
> > name.
>
> That's not my name,

Sorry!

> I manage them for the release, and that's right,
> it seemed to be caused by different given forms but why? 

Because the data in KBabel was different?

> Usually
> translator only have to fill the contact (translator) form once at
> startup Wizard (from my poEdit experience). 

Well, that is where it does not work cleanly with KBabel. If you use only the 
wizard, the are missing important settings. So you have to use the "project 
settings" afterward. (To avoid a misunderstanding, for KBabel a project, like 
in "project setting" does not mean a PO file but more the whole tranlsation 
in a language, so all PO files.)

> What strange comments
> (for me at least) are, the following comment part tends to get added
> per save,
>

>   # translation of ca.po to catala`   <- added string by KBabel

Yes, this line is added by KBabel. There is a template in the "project 
setting" that you can change (probably to an empty string too).

>   # Catalan translation of Mousepad.  <- given string by me
>   # Copyright (C) 2005 Erik Harrison. <- (ditto)
>   # This file is distributed under the same license as the \
>     Mousepad package. <- (ditto)
>
> can be
>
>   # translation of ca.po to
>   # translation of ca.po to catala`
>   # translation of Mousepad.po to catala`
>   # translation of ca.po to catala`

Yes, that is one bug in KBabel to repeat the lines as it cannot find (and 
remove) the older ones. This is supposed to be fixed in KBabel 1.11 (to be 
released with KDE 3.5).

>   # Catalan translation of Mousepad.
>   # Copyright (C) 2005 Erik Harrison.
>   # This file is distributed under the same license as the Mousepad
> package.
>
> > It is for simplification of the translator's tasks.
>
> Sorry, but discarding given proper strings doesn't sound simplification
> for me.

The philosophy behind KBabel is probably another that the one that you expect.
You fill the project setting with the correct data and then it modifies the 
header comment and the header automatically.

(KDE has more than 900 POT files to translate, so you really want some 
automatisation. Of course the automatisation can only work correctly with the 
correct data entered in KBabel.)

>
> > > as I've never
> > > used KDE, it's hard to figure the problem out, but I smelled there's
> > > some bad design at giving values to the PO header, at least Kbabel
> > > should warn at blank form (project name, contact address) if it exists
> > > but Kbabel shouldn't fill these forms with invalid values at the same
> > > time (there needs some guidance/tooltips for the translators),
> >
> > Normally with the project setting you can set nearly everything (but the
> > "project name" of a PO file).
> >
> > (The only bigger problem that I know is that the project wizard fails to
> > ask some questions, like the language team email. So you have always to
> > check the project setting (which is annoying as the wizard is supposed
> > to avoid that.))
>
> Probably, a language team should be given across the modules, 

The "project setting" is not linked to one PO file, but to each PO file that 
you modifiy with KBabel under this project setting.

As written above, "project" in this case as another meaning than "project" 
like Gettext means it.

> but each
> project name shouldn't be replaced by the single strings (e.g. soon, I'll
> have see `ca' at the `Project-Id-Version' in the every ca.po files.)


>
> > > to be more detailed, please read my post in the Xfce i18n ML also,
> > >
> > >  
> > > http://foo-projects.org/pipermail/xfce-i18n/2005-September/003277.html
> >
> > I am not really understanding your critic about the language team that
> > you have in that email,
> >
> > The language team can be set correctly by KBabel, it is done often in
> > KDE.
>
> It's nothing to do with KBabel, I only pointed out that
>
>   -"Language-Team: Catalan <ca at dodds.net>\n"
>   +"Language-Team: catala`\n"
>
> isn't welcomed.

Ah, sorry, I misunderstood you. (So probably you meant to check to correctly 
set KBabel to avoid that.)

>
> > > I'm bit tired with KBabel users, and thanks for your considerations.
> >
> > I am sorry about that you are tired to use KBabel.
> >
> > As far as I know, return of experience of non-KDE users is sparse,
> > so it is difficult to know what is needed.
> >
> > You can also uses KDE Bugs: http://bugs.kde.org to report bugs and wishes
> > that you would have for non-KDE projects.
> >
> > For the KDE 3.5 branch we cannot do much anymore, as we are already in
> > message freeze for weeks. So major changes will only be in KDE 4
> > unfortunately.
>
> I'd like to say again, if PO file gets given proper strings, please
> honor that, don't overwrite (except time stamp, last translator name)

So set it that way in the "project setting" of KBabel. (As written, KBabel's 
defaults are meant for KDE.)

>
> > If you want an example how PO files look in KDE, you can look at:
> >
> > http://websvn.kde.org/trunk/l10n/ca/messages/kdebase/
> > kwin.po?rev=468433&view=markup
>
> Okay, I'll see that later.
>
> > Have a nice day!
>
> Really thanks for your replying.
>
> Regards,

Have a nice day!



More information about the kbabel mailing list