Windows-1252


Windows-1252 or CP-1252 is a single-byte character encoding of the Latin alphabet, used by default in the legacy components of Microsoft Windows for English and many European languages such as Spanish, French, and German.
It is the most-used single-byte character encoding in the world., 0.4% of all web sites declared use of Windows-1252, but at the same time 2.0% used ISO 8859-1, which by HTML5 standards should be considered the same encoding, so that 2.4% of web sites effectively use Windows-1252.

Details

This character encoding is a superset of ISO 8859-1 in terms of printable characters, but differs from the IANA's ISO-8859-1 by using displayable characters rather than control characters in the 80 to 9F range. Notable additional characters include curly quotation marks and all the printable characters that are in ISO 8859-15. It is known to Windows by the code page number 1252, and by the IANA-approved name "windows-1252".
It is very common to mislabel Windows-1252 text with the charset label ISO-8859-1. A common result was that all the quotes and apostrophes were replaced with question marks or boxes on non-Windows operating systems, making text difficult to read. Most modern web browsers and e-mail clients treat the media type charset ISO-8859-1 as Windows-1252 to accommodate such mislabeling. This is now standard behavior in the HTML5 specification, which requires that documents advertised as ISO-8859-1 actually be parsed with the Windows-1252 encoding.
Historically, the phrase "ANSI Code Page" was used in Windows to refer to non-DOS encodings; the intention was that most of these would be ANSI standards such as ISO-8859-1. Even though Windows-1252 was the first and by far most popular code page named so in Microsoft Windows parlance, the code page has never been an ANSI standard. Microsoft explains, "The term ANSI as used to signify Windows code pages is a historical reference, but is nowadays a misnomer that continues to persist in the Windows community."
In LaTeX packages, CP-1252 is referred to as "ansinew".
IBM uses code page 1252 for Windows-1252.

Character set

The following table shows Windows-1252. Each character is shown with its Unicode equivalent based on the Unicode.org mapping of Windows-1252 with "best fit". The decimal numbers are the Alt code that can be used to type these on Windows systems.
According to the information on Microsoft's and the Unicode Consortium's websites, positions 81, 8D, 8F, 90, and 9D are unused; however, the Windows API maps these to the corresponding C1 control codes. The "best fit" mapping documents this behavior, too.

History

The OS/2 operating system supports an encoding by the name of Code page 1004 or "Windows Extended". This mostly matches code page 1252, with the exception of certain C0 control characters being replaced by diacritic characters.

MSDOS extensions rare

There is a rarely used, but useful, graphics extended code page 1252 where codes 0x00 to 0x1f allow for box drawing as used in applications such as MSDOS Edit and Codeview. One of the applications to use this code page was an Intel Corporation Install/Recovery disk image utility from mid/late 1995. These programs were written for its P6 User Test Program machines. It was used exclusively in its then EMEA region. In time the programs were changed to use code page 850.