While playing around with getting the QLColorCode QuickLook plugin to get quick previews of IDL code from the Finder on my Mac, I discovered Highlight, which is the underlying engine which produces the syntax highlighted output for QLColorCode. But Highlight can be installed as in independent command line utility and it can produce output in various formats such as HTML, LaTeX, XML, etc.

For example, run the command line utility from a system prompt like:

$ hightlight --syntax=pro mg_options__define.pro

This should produce reasonable output.

I have been messing around with the IDL language definition file a bit to try to get better results.