cppreference2mshelp icon indicating copy to clipboard operation
cppreference2mshelp copied to clipboard

Replacement for HTML Help Workshop

Open Wolf-SO opened this issue 9 months ago • 3 comments

In the prerequisites, you list HTML Help Workshop:

However there is no alternative for HTML Help Workshop from Microsoft (for chm based help).

But meanwhile the MS page responds with “Error 404 - Not found” and you have to go to archive.org for it. But you might be interested to learn that there is an alternative that I found in the Lazarus project. The free and open-source Lazarus IDE is delivered together with help in CHM format generated by a command line tool named chmcmd.exe, which can run independently, i.e., has no dependencies on other Lazarus libraries or tools.

In a Lazarus installation, the binary is located in [lazarus]\fpc\3.2.2\bin\x86_64-win64\chmcmd.exe, the source code can be found in [lazarus]\fpc\3.2.2\source\packages\chm\src\*.

See htmlhelp compiler - Lazarus wiki to find out more.

Of course, I can't give any guarantees, but I found that it does a better job in compiling my HPP projects to CHM files.

Wolf-SO avatar Mar 21 '25 12:03 Wolf-SO

Sorry, only now I see that I'd have better started a discussion for this.

Wolf-SO avatar Mar 21 '25 12:03 Wolf-SO

Glad to hear that found this open source alternative to the hhc.exe tool. After some experiments with the chmcmd, it emits a lot of warning, and completed with ~2.95x time compared to hhc. The compiled file and the chmcmd tool are attached below.

cppreference-zh-20240915.zip

chmcmd-lazarus-3.8-fpc-3.2.2-win64.zip

myfreeer avatar Mar 23 '25 02:03 myfreeer

Thanks @myfreeer for testing the replacement. I didn't compare the timing though, as my projects are very small compared to cppreference, but it I was happy to see that the output sizes are comparable. In my case, the warnings issued by chmcmd.exe were actually helpful in fixing bugs in the actual help projects. I therefore think it is possible that they could also prove useful for this project. I also received a return value from hhc.exe that was irritating for GNU Make.

Wolf-SO avatar Apr 04 '25 11:04 Wolf-SO