A load of fixes and enhancements.