Re: Source code encoding detection modifications for intltool
Carlos Perelló Marín <[email protected]> 16 Jul 2003 10:42:29 +0200
| Newsgroups | gmane.comp.gnome.internationalization.general,gmane.comp.gnome.lib.xml.internationalization |
|---|---|
| Organization | GNOME Foundation |
| Message-ID | <[email protected]> |
--=-Ll3A18AQAgeTmkd2S2c1
Content-Type: text/plain; charset=ISO-8859-15
Content-Transfer-Encoding: quoted-printable
El mi=E9, 16-07-2003 a las 10:09, Abel Cheung escribi=F3:
> On 2003-07-15(Tue) 13:26:12 +0200, Carlos Perell=F3 Mar=EDn wrote:
> > > An unexpected failure -- currently escaped hex values (\x??) are not
> > > handled. Source code with such strings should most likely use
> > > --from-code=3DUTF-8 too, but "file" detects them as either ASCII or I=
SO-*
> > > files. (mlview/src/mlview-app.c for example)
> >=20
> > Well, if it's detected as an ASCII file, we can use without problems th=
e
> > UTF-8 encoding, the problem is if it detects it as an ISO-* because
> > there are characters that are not valid UTF-8 characters...
> >=20
> > Ideas to "fix" it?
> > Assume that all files are using UTF-8 is not the correct behavior...
>=20
> I've been thinking about something like this:
>=20
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> [deaddog@localhost CVS.GNOME.ORG]$ cat mlview/po/POTFILES.in
> {...... comment here .......}
> [encoding: UTF-8]
> {......}
> src/mlview-attribute-picker.c
> src/mlview-app.c
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
>=20
> That is, explicitly specify the encoding of source files in POTFILES.in,
> so that intltool can use this value to avoid autodetecting file
> encoding. Is there any better possible solution?
I was doing it this way, but xgettext gets only one encoding for all
files, so all files should use the same encoding, thus if you have one
file as UTF-8 all files should use UTF-8.
Cheers.
>=20
> Abel
--=20
Carlos Perell=F3 Mar=EDn
Debian GNU/Linux Sid (PowerPC)
Linux Registered User #121232
mailto:[email protected] || mailto:[email protected]
http://carlos.pemas.net
Valencia - Spain
--=-Ll3A18AQAgeTmkd2S2c1
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: Esta parte del mensaje =?ISO-8859-1?Q?est=E1?= firmada
digitalmente
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
iD8DBQA/FQ/1EuPMamD5V9cRAruhAJ92kQRPAbGjXLKUAfr1YKs8jv+zjQCeIAXK
VQMgLfRNuJBaqcIiGJqOYVM=
=mABk
-----END PGP SIGNATURE-----
--=-Ll3A18AQAgeTmkd2S2c1--