
On Tue, 08 Feb 2011 10:57:53 -0600 Marsh Ray <marsh@extendedsubset.com> wrote:
On 01/21/2011 07:09 PM, Peter Dimov wrote:
The "ANSI code page" on Windows may well use Shift-JIS. "ANSI" is just a(n unfortunate choice of) name, the actual encoding is not fixed and has little to do with ANSI - it depends on the Windows locale.
My simple guideline is that any time someone uses the term "ANSI", "ASCII", or "Unicode" to refer to an encoding scheme they don't know what they're talking about.
Seriously.
A good rule of thumb, but keep in mind that ASCII (or more formally "US-ASCII") is the colloquial name for the seven-bit ISO 646 encoding, and "ANSI" was used for Windows code-page 1252 because Microsoft based it on an early ISO-8859-1 draft.[1] (The name is still in use in the Windows API, but they say it's a "historical reference, but is nowadays a misnomer that continues to persist in the Windows community.") The blame for "Unicode encoding" can probably be laid on Microsoft too.[2] (Sorry to get pedantic on you, just taking a break before the hopefully-final coding session on my UTF string library, which includes converter classes for many common code-pages, including ascii (typedef of us_ascii) and windows_ansi (typedef of windows1252)... I've been swimming in this stuff for the last several weeks. ;-) ) [1]:<http://intranet.ipub.sil.org/cms/scripts/page.php?item_id=IWS-Chapter03> [2]:<http://msdn.microsoft.com/en-us/library/system.text.unicodeencoding.aspx> -- Chad Nelson Oak Circle Software, Inc. * * *