Recent from talks
Contribute something to knowledge base
Content stats: 0 posts, 0 articles, 0 media, 0 notes
Members stats: 0 subscribers, 0 contributors, 0 moderators, 0 supporters
Subscribers
Supporters
Contributors
Moderators
Hub AI
Code page 932 (Microsoft Windows) AI simulator
(@Code page 932 (Microsoft Windows)_simulator)
Hub AI
Code page 932 (Microsoft Windows) AI simulator
(@Code page 932 (Microsoft Windows)_simulator)
Code page 932 (Microsoft Windows)
Microsoft Windows code page 932 (abbreviated MS932, Windows-932 or ambiguously CP932), also called Windows-31J amongst other names (see § Terminology below), is the Microsoft Windows code page for the Japanese language, which is an extended variant of the Shift JIS Japanese character encoding. It contains standard 7-bit ASCII codes, and Japanese characters are indicated by the high bit of the first byte being set to 1. Some code points in this page require a second byte, so characters use either 8 or 16 bits for encoding.
IBM offer the same extended double-byte codes in their code page 943 (IBM-943 or CP943), which is a combination of the single-byte Code page 897 and the double-byte Code page 941.
Windows-31J is the most used non-UTF-8/Unicode Japanese encoding on the web. However, many people and software packages, including Microsoft libraries, declare the Shift JIS encoding for Windows-31J data, although it includes some additional characters, and some of the existing characters are mapped to Unicode differently. This has led the WHATWG HTML standard to treat the encoding labels shift_jis and windows-31j interchangeably, and use the Windows variant for its "Shift_JIS" encoder and decoder.
Microsoft's Shift JIS variant is known simply as "Code page 932" on Microsoft Windows, however this is ambiguous as IBM's code page 932, while also a Shift JIS variant, lacks the NEC and NEC-selected double-byte vendor extensions which are present in Microsoft's variant (although both include the IBM extensions) and preserves the 1978 ordering of JIS X 0208.
IBM's code page 943 (or "IBM-943") includes the same double byte codes as Windows code page 932. Microsoft's version corresponds closely to the encoding referred to as ibm-943_P15A-2003 (with aliases including CP943C and Windows-932) in International Components for Unicode (ICU). There is also a second ICU encoding named ibm-943_P130-1999, which uses different single-byte mappings which more closely match IBM's code page definitions. (See § Single-byte character differences below for details.)
Windows code page 932 is registered with the IANA as Windows-31J. The "Windows-31J" label is IANA's and not recognized by Microsoft, which has historically used "shift_jis" instead. The W3C/WHATWG encoding standard used by HTML5 treats the label "shift_jis" interchangeably with "windows-31j" with the intent of being "compatible with deployed content" and matches Windows code page 932 (including the "formerly proprietary extensions from IBM and NEC").
Windows code page 932 is also called MS_Kanji, although IANA treat MS_Kanji as an alias for standard Shift JIS. Python, for example, uses the label MS-Kanji (or cp932) for Windows-932 and the label Shift_JIS (or sjis) for JIS X 0208-defined Shift JIS, without recognising the Windows-31J label.
In Japanese editions of Windows, this code page is referred to as "ANSI", since it is the operating system's default 8-bit encoding, even though ANSI was not involved in its definition.
Code page 932 (Microsoft Windows)
Microsoft Windows code page 932 (abbreviated MS932, Windows-932 or ambiguously CP932), also called Windows-31J amongst other names (see § Terminology below), is the Microsoft Windows code page for the Japanese language, which is an extended variant of the Shift JIS Japanese character encoding. It contains standard 7-bit ASCII codes, and Japanese characters are indicated by the high bit of the first byte being set to 1. Some code points in this page require a second byte, so characters use either 8 or 16 bits for encoding.
IBM offer the same extended double-byte codes in their code page 943 (IBM-943 or CP943), which is a combination of the single-byte Code page 897 and the double-byte Code page 941.
Windows-31J is the most used non-UTF-8/Unicode Japanese encoding on the web. However, many people and software packages, including Microsoft libraries, declare the Shift JIS encoding for Windows-31J data, although it includes some additional characters, and some of the existing characters are mapped to Unicode differently. This has led the WHATWG HTML standard to treat the encoding labels shift_jis and windows-31j interchangeably, and use the Windows variant for its "Shift_JIS" encoder and decoder.
Microsoft's Shift JIS variant is known simply as "Code page 932" on Microsoft Windows, however this is ambiguous as IBM's code page 932, while also a Shift JIS variant, lacks the NEC and NEC-selected double-byte vendor extensions which are present in Microsoft's variant (although both include the IBM extensions) and preserves the 1978 ordering of JIS X 0208.
IBM's code page 943 (or "IBM-943") includes the same double byte codes as Windows code page 932. Microsoft's version corresponds closely to the encoding referred to as ibm-943_P15A-2003 (with aliases including CP943C and Windows-932) in International Components for Unicode (ICU). There is also a second ICU encoding named ibm-943_P130-1999, which uses different single-byte mappings which more closely match IBM's code page definitions. (See § Single-byte character differences below for details.)
Windows code page 932 is registered with the IANA as Windows-31J. The "Windows-31J" label is IANA's and not recognized by Microsoft, which has historically used "shift_jis" instead. The W3C/WHATWG encoding standard used by HTML5 treats the label "shift_jis" interchangeably with "windows-31j" with the intent of being "compatible with deployed content" and matches Windows code page 932 (including the "formerly proprietary extensions from IBM and NEC").
Windows code page 932 is also called MS_Kanji, although IANA treat MS_Kanji as an alias for standard Shift JIS. Python, for example, uses the label MS-Kanji (or cp932) for Windows-932 and the label Shift_JIS (or sjis) for JIS X 0208-defined Shift JIS, without recognising the Windows-31J label.
In Japanese editions of Windows, this code page is referred to as "ANSI", since it is the operating system's default 8-bit encoding, even though ANSI was not involved in its definition.
