Changes to keep html entities, set indent chars, improve pretty print