[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Displaying characters in user's locale
From: |
Gavin Smith |
Subject: |
Re: Displaying characters in user's locale |
Date: |
Fri, 31 Jan 2014 21:33:39 +0000 |
On Fri, Jan 31, 2014 at 8:01 AM, Eli Zaretskii <address@hidden> wrote:
>
> It is true that characters which cannot be encoded in the terminal's
> encoding should be replaced with something that still leaves the text
> legible. However, many characters _can_ be encoded, and Info should
> use libiconv for those. Moreover, the mere fact that a character
> cannot be represented should be taken from libiconv's output, rather
> than hard-coded in advance in Info's sources. That way, we won't need
> any changes when/if there are terminals or encodings that don't exist
> today.
>
> IMO your UTF-8 related patch would be much more complete if it used
> libiconv as described above.
I've attached a patch which uses iconv as you suggested. I've tested
it with the two files attached under both utf-8 and iso8859-1 locales.
(I did this by, e.g. running "LANG=en_US.UTF8" to get a UTF-8
terminal.) I haven't been able to figure out how to get an ASCII-only
terminal yet.
character-encoding.patch
Description: Text Data
iso8859_1.info
Description: Binary data
utf8.info
Description: Binary data
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: Displaying characters in user's locale,
Gavin Smith <=