Added an option to forcibly set the latex output of thms/terms/types. Slightly generalised formating options. Improved documentation.
Better error reporting and hopefully fixes the problem building under mosml reported by Michael.