summaryrefslogtreecommitdiff
path: root/src/Text/Pandoc
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2013-01-16 09:20:48 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2013-01-16 09:20:48 -0800
commit71941077337920132fef779df714e332089f47a0 (patch)
treeb762896ae0b253da1a8af9f21f17bd231163ad40 /src/Text/Pandoc
parent4926645578aecc08ea496860f1608fa3e8ffd572 (diff)
Implemented Ext_mmd_header_identifiers in markdown writer.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r--src/Text/Pandoc/Writers/Markdown.hs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs
index 54948a959..10d7d1ed2 100644
--- a/src/Text/Pandoc/Writers/Markdown.hs
+++ b/src/Text/Pandoc/Writers/Markdown.hs
@@ -285,6 +285,8 @@ blockToMarkdown opts (Header level attr inlines) = do
("",[],[]) -> empty
(id',[],[]) | isEnabled Ext_auto_identifiers opts
&& id' == autoId -> empty
+ (id',_,_) | isEnabled Ext_mmd_header_identifiers opts ->
+ space <> brackets (text id')
_ | isEnabled Ext_header_attributes opts ->
space <> attrsToMarkdown attr
| otherwise -> empty