added HTML5 support and some merges from tidy lib (publishing internal code)