Various fixes

I have made a couple of changes in order to make my xml-fo render a bit closer to what it was when it got rendered by FO.