Emacs Reads CHM documents
Viewing HTML documents in Emacs can be done through my w3m view of HTML document articles. However, the CHM document is a compiled version of an HTML document that cannot be opened in Emacs.
So, to see the CHM in Emacs, first understand what the CHM document really is. We open a TCL CHM document, click on any of the pages, right-view the "Properties", you can see that there is one:
Address: mk: @MSITStore: c:\tcl8.6\doc\activetclhelp8.6.chm::/tdom/dom.html
This address can be opened with the system's own hh.exe:
HH mk: @MSITStore: c:\tcl8.6\doc\activetclhelp8.6.chm::/tdom/dom.html
However, this is not a standard URL and cannot be opened with a browser. Also, we don't know which HTML page to open.
To solve this problem, we have several ways here:
Use Keyhh.exe to open:
keyhh-myhelp-#klink "ActiveX Control Wizard" Htmlhelp.chm
This is the use of a more advanced hh.exe program to open the CHM document, as long as the ID is configured identically, will only open a CHM document. Keyhh.exe has stopped updating, the official website has been closed, from here can also download:
Http://api.256file.com/download/66010_keyhh.exe
However, there seems to be a bug, that is, when the first search, if you need to choose, it will be stuck. The default option "-#klink" is changed to "-#alink".
(Defun Chm-help--lookup-chm (File-path keyword) "Open A window showing the documentation for the word under the" (Interactive "Fchm File: \nskeyword:") (Start-process"Keyhh"Nil"Keyhh.exe" (Concat"-"Mode-name) ;; Use Mode name as ID "-#alink" (Format"'%s '"Keyword)File-path))(Chm-help--lookup-chm"C:/tcl/doc/activetclhelp8.5.chm" "Dom")
- Use Archmage + Chmview This can only be used on Linux, Archmage no Windows version.
The first anti-compilation is used to decompile the HTML file with the hh.exe command, and then it is viewed with w3m.
Hh-decompile x:\a Y:\B.chm
Date:2017-01-14 17:11
Created:2017-01-14 Saturday 23:13
Validate
Emacs Reads CHM documents