Unreal Engine API documentation in Dash

Hi everyone,

I wrote a little python script that takes the CHM formatted API documentation and converts it into DocSet format that can be used by Dash. If you don’t know it already, Dash is an nice offline documentation browser on Mac, which integrates with pretty much any source editor and supports most standard language APIs out of the box.

The result is one click access to the documentation from Xcode and instant fuzzy search from everywhere:

If anyone from Epic is reading this, would you mind if I uploaded the resulting docset somewhere, GitHub maybe? Considering that the API docs are publicly available online, this shouldn’t be a big problem? If you don’t want it to be public, is there a way to only share it with subscribers?
Also, if I may recommend a small improvement to the documentation in the future:
Some HTML meta info in the documentation would make parsing more easy and reliable. At the very least, a category (class, struct, method, constant etc…) for each file. Right now, I have to guess the category with a regexp match on the content of the div with class=‘simplecode_api’.

Until then (or if I’m not allowed to share the documentation itself), I put the script onto on GitHub. Here is how you use it:

  1. Get the CHM documentation from:
  • Windows: C:\Program Files\Unreal Engine\4.x\Engine\Documentation

  • Mac: /Users/Shared/UnrealEngine/4.x/Engine/Documentation

  1. Extract the CHM file to HTML. You should get a folder that looks something like this:

There are lots of tools that can do this. I used CHM Decompiler. The script could probably be expanded to do this on its own using something like PyCHM, but for now, you have to do this manually.

  1. The script uses BeautifulSoup to parse the documentation. If you don’t have it already, install it:
    [FONT=Courier New]$ easy_install beautifulsoup4

  2. Run the python script to generate the Dash compatible DocSet from the extracted HTML documentation:
    [FONT=Courier New]$ python ue4docset.py -n “Unreal Engine” ~/Desktop/API ~/Desktop/UE4.docset
    The first path is the location of the extracted HTML documentation. The second path is the output DocSet file. You can define the name of the documentaion as it will appear in Dash, using the -n option.
    The process will take some time to parse the entire documentation. On my relatively fast machine it takes around 7 minutes to finish.

  3. Go to Dash > Preferences > Docsets. Click the + button and add select the generated .docset file.

Xcode’s own documentation browser is not (yet) supported, as it uses a slightly more complicated format and I’m using Dash personally. I don’t have a lot of time for that right now, but if anyone wants to tackle that, just submit a pull request and I’ll merge it, thanks! Here is some info on Xcode’s format.

Great work!

Thanks for your contribution!

Oh let me see… for the ones on Windows/Linux now exist Dash for macOS - API Documentation Browser, Snippet Manager - Kapeli well, the linked github repo is 2 years old… so lets see how it goes today.

And it will be nice that this where generated from epic games itself, I mean, there are lots of annotations they could do Docset Generation Guide - Kapeli like

  • guide
  • diagram
  • sample
  • framework
  • Sample
  • shortcut
  • extension
  • plugin
  • component

which will be grouped for example download the docset for rust, they use