Added a settings file for use in integration tests.
Refactored diagram rendering a bit.
Continued adding support for multiple diagram output image formats.
Added simple utility method for disposing potentially null objects.