[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: feature request: expose message validation in libgettextpo
From: |
Bruno Haible |
Subject: |
Re: feature request: expose message validation in libgettextpo |
Date: |
Tue, 6 Sep 2005 12:53:41 +0200 |
User-agent: |
KMail/1.5 |
James Henstridge wrote:
> The libgettextpo library provides a po_message_check_format() function
> for performing format string checking on a po_message_t. However this
> is not the only message validity check that the gettext tools perform.
>
> The msgfmt program performs some other checks, such as consistent use of
> newlines at the beginning and end of strings.
>
> A po_message_validate() function that performed all these checks would
> be useful to programs that use libgettextpo to generate or edit PO
> files. As it is now, such applications either need to reimplement the
> checks or omit them and risk producing broken PO files (and
> reimplementing the checks is not ideal -- if gettext gets new checks,
> the application needs to be updated too).
The other checks are implementable in a few lines of code, whereas the
po_message_check_format() function is quite complex. As far as I know,
the applications for which libgettextpo is made - namely PO file editors -
also perform other checks - spell checking and such - that msgfmt doesn't
do. The current API is therefore more inviting for the addition of other
checks.
Bruno
- Re: feature request: expose message validation in libgettextpo,
Bruno Haible <=