Lots of Acid2 stuff

This is not ready for merging, as I need to split it up into several commits and perform a little more cleanup, but I thought I would post it here to get some early feedback. I have surely regressed some table assign-heights functionality, as assign-heights for blocks got completely reworked and I didn't do a very thorough job of slotting the new table assign-heights code in with it.

Here is how Acid2 looks with this patch: http://i.imgur.com/YE7dSDj.png

All remaining issues are generated content and automatic table layout (assuming that I didn't just get lucky with the image-height-test).