Add support for post formats; lots of tweaks