Added Markdown support an other bugfixes.