Thanks. The keyword index is quick and dirty, based on the filename, which happens to also be the name of the class described inside the file. I also injected a little CSS into the files so they’re formatted a little better.
Eventually, I’d like to add in all of the methods listed in methods.html as keywords also, so it has some finer granularity. All told, on my 1.8Ghz system, it takes about 44 seconds to process the HTML files, generate the index, table of contents, project file, and then do the compilation. Not too bad.
If the project is interested, is there a more official place I can put this besides one of my servers?
I looked at your work and made a fully-automatic script based on that. Not only does it create the necessary .hhp, .hhc and .hhk files and invoke hhc.exe, but it also can parse the HTML structure of the Main page of the manual to get the tree of the Manual chm right.
The only bug is: in the manual CHM, pages with special characters in them (such as double-quotes or colons) don’t work (Page Not Found error). If didn’t manage to fix it – but I’d be happy to accept patches.
At first glance, I’d say the problem with special characters might be character encoding. Might want to try applying an encoding so the special characters parse correctly during compilation or use the unicode() function.
Since the script uses the xml.dom module, it might not be recognizing them as correct entities and error out. XML parsers can be quite touchy about those things from my own experience. Usually the strings have to undergo either some encoding or transcoding to get the parser to recognize them.
If it’s only a small set of known character entities (like &lquo; and &rquo;) then a quick dictionary mapping to the acceptable entities might suffice as well.
This is great though. More than I had imagined it being and hopefully will be useful to many people.
Hmmm… I downloaded both and opened them. Every page in both .chm files displays a “The Address is not valid” error page. None of the Panda3D info is displayed…
Yeah, it’s weird. I have several other .chm files, including dklon’s original P3D .chm and they open fine. I’m running XP SP3 currently. I’ll try copying them to my laptop running Vista Home Premium and see if the issue resolves there.
Another note: When I first click on the .chm file to open it, the “Main Page” menu item at the top of the tree is highlighted and the error “Navigation to the webpage was cancelled” appears.
Yet another note: Following up on my note above: evidently, XP “security” is the issue. When I examine the properties of the .chm file, the popup window informs me “This file came from another computer and might be blocked to help protect this computer.” Clicking the “unblock” button allows the .chm files to operate properly. I’ve never seen this kind of behavior before…
BTW, now that I can see the contents, I must say these files will be very useful and I appreciate the efforts of all involved.
Now this is good for the times when panda3d goes down. When even it went down i went looking for the documentation and never really found a good way to view it by using make docs and Firefox. But this really simplifies stuff.
That’s a new “feature” of SP3. I noticed my XP laptop started behaving that way after I installed the service pack. I’m looking around to see if there is a way to turn that off or at least mitigate it so it doesn’t come up all of the time.
not only this - chm way (to me) is the best to read documentation onto a PC so far and I’m 100% sure I won’t use the online website anymore to find help (AFA I’m not in need of skilled forum ppl of course ) and this is good to save banwidth (and maybe money) to P3D project!