CHM garbled Problem Analysis
Some help documents in chm format are often garbled and cannot be read, and the CHM document is not like a browser, right-click can select character encoding, very inconvenient. The main reason is that the CHM document does not specify proper character encoding on the page.
The essence of CHM is HTML files. Generally, CHM without character encoding is used to display the CHM File by calling the character encoding settings of Internet Explorer.
There are two key names autodetect and default_codepage in the Registry HKEY_CURRENT_USER \ Software \ Microsoft \ Internet Explorer \ International, which are the character encoding key of IE browser.
Autodetect indicates automatic detection of character encoding. It is the same as "automatic selection" in "encoding" in "view" menu of IE browser ". Set key value 1 to enable automatic detection. Generally, in the simplified Chinese operating system, the IE browser will use gb2312 to display pages without specified character encoding. If autodetect is set to 0, the browser will use default_codepage to display the page. Therefore, when the CHM document in simplified Chinese is garbled on the operating system of Simplified Chinese, autodetect can be properly displayed if it is set to 1; in the Simplified Chinese operating system, when the CHM document in Traditional Chinese is garbled, set autodetect to 0, and then set default_codepage to big5CodePage 950.
ANSI code page 936 is commonly used in simplified Chinese Windows, and the binary value in the registry is A8 03 00;
ANSI code page 950 is commonly used in traditional Chinese Windows, and the binary value in the registry is B6 03 00;
The ANSI code page 1252 is commonly used in windows in the Latin language. The binary value in the registry is E4 04 00.