bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

libgettextpo: Ability to work with non-ASCII without a header


From: Dwayne Bailey
Subject: libgettextpo: Ability to work with non-ASCII without a header
Date: Thu, 18 Oct 2007 23:51:41 +0200

In some of our tools in the Translate Toolkit e.g. pogrep we only pull
out bits of a file and create a PO file without a header.  Of course if
these contain non-ASCII chars then libgettextpo complains about invalid
multibyte sequences since it has no header and thus no information about
what encoding to use.  

A solution of course is to put in a header, but it would be nice to be
able to specify the encoding of the file/text even when it has no
header.  So a function that allows you to set the encoding independent
of the header, of course if there is a header then the same function
would update the encoding information and change the current data.  That
would take care of writing/processing the file, IIRC we wouldn't need to
worry about reading the file.

-- 
Dwayne Bailey
Translate.org.za

+27-12-460-1095 (w)
+27-83-443-7114 (cell)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]