Overhaul rst_parser and parsing in general

Got rid of preformat, postformat and a bunch of other things that
weren't well thought out. They will be replaced later with a better
transform chain.

Added tests for rst_parser.

Centralized all the entry parsing code for the classic Douglas entry
structure to one place with tests.