Include the whole document in dom.serializedSize, not just the body

`XMLSerializer::serializeToString` gets us what we want. For some reason it's not exactly equivalent to the actual file size, but it's within 10 bytes.