[Kbabel] Full Gettext support in KBabel
Nicolas Goutte
nicolasg at snafu.de
Thu Oct 20 20:09:10 CEST 2005
On Thursday 20 October 2005 15:26, Chusslove Illich wrote:
> >> [: Nicolas Goutte :]
> >> msgid_plural and msgstr_plural are not correctly handled
> >> (only loaded as far as I understand the code).
> >
> > [: Stanislav Visnovsky :]
> > They are fully supported. Try one, for example gettext.po ;-)
>
> So, like, there are no known problems at all?
>
> >> [: Nicolas Goutte :]
> >> As far as I had understood Stanislas, the problem is that those
> >> functions cannot recover from syntax errors in the file. KBabel's
> >> editor (not the catalog manager) tries to be error tolerant at load.
> >
> > [: Stanislav Visnovsky :]
> > Yes. And the library does not provide access to the comments.
>
> Might be of recent addition (I'm looking at Gettext CVS code), but there
> are some functions dealing with comments.
Yes, it would me surprise too that Gettext has two such functions: one
"public" and one private for its tools. (But may be it used to be so in the
past.)
>
> As for error recovery, perhaps it would be a better strategy to use
> libgettextpo by default, and try to salvage the file only if libgettextpo
> refuses to load it?
Another question is how the code handles bad files. If crashes often, it would
be not a good choice.
As for file recovery, indeed it could be a question if we should continue to
support bad files automatically. (As for XML files (Qt's and XLIFF), we will
have no recovery, as QDomDocument::setContent does not offer any.)
Have a nice day!
More information about the kbabel
mailing list