Add custom renderer for parsing markdown documents

@dab Please review this pull request