[GRASS-dev] Re: [bug #5195] (grass) ps.map sets encoding to
glynn at gclements.plus.com
Tue Oct 10 09:03:18 EDT 2006
Moritz Lennert wrote:
> >> So, maybe we should at least add a hint to the ps.map man page that
> >> utf-8-based users who want non-ascii characters should translate their
> >> utf-8 instruction files to unibyte before using them.
> > yes that would be good, with an example.
> >> I imagine there is no way of automatically identifying the encoding of a
> >> file ?
> > file $filename
> Could this be integrated into ps.map (i.e. is there a C equivalent) ?
> Would this be a good idea ?
I'm not sure whether it's precise enough to be useful. E.g. it won't
attempt to distinguish different ISO-8859-* encodings (it just reports
"ISO-8859 text"). Also, it can occasionally misidentify ISO-8859-* as
UTF-8; AFAICT, anything which is text, isn't ASCII, and is legal as
UTF-8 is assumed to be UTF-8, even if it is also legal as ISO-8859-*.
Glynn Clements <glynn at gclements.plus.com>
More information about the grass-dev