Add routine comments IDL Workbench 7.0.3 arrived today via the automatic software update mechanism in the Workbench. It provides HDF and netCDF library udpates, better path support, IDLdoc support (rst format only), and even faster code analysis when the Workbench starts. Everything seems to be working well for me during use this afternoon.

Since I’m most excited about the IDLdoc features, I will describe them in a bit more detail after the jump. IDLdoc 3.1 (download) is required to integrate with the Workbench.

One nice IDLdoc feature is the ability to insert IDLdoc headers easily. Right-click in an editor window, “Add Routine Comments” and “Add File Comments” should be choices in the context-menu that pops up. There is a section for IDLdoc in the Preferences to control the formatting and what appears in these inserted headers. The best part of this is that it parses the declaration line for the routine and adds the parameters and keywords it finds. In the example in the image above, I typed the code and the Workbench inserted all the comments as they appear.

Another IDLdoc feature is the ability to mouse over a routine call and see the properly formatted IDLdoc header as a tooltip. For example, mousing over the VIS_RGB2INDEX routine pops up it’s header, as shown below: IDLdoc formatted tooltip One thing that has bothered me before about this is that it uses projects to find the code and not my IDL !path. Because of this, the Workbench often finds multiple copies of my routines because my IDLdoc documentation is in the project (but not in the !path). At least they are all the same since the copies are generated from the original.