Implement anchor generation in markdown headers

Implements the feature discussed in #185. Disabled by default. Feedback welcome!