aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2014-08-08 15:20:29 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2014-08-08 15:20:29 -0700
commita4a6b6f28cefb26563b53d8fbf9195023bad2742 (patch)
tree9f398a758ed9affd4e52adb9d987cffa1c680064 /src
parentaae90a8671d4fdb46ede2669e6713a559b9d3fbb (diff)
downloadpandoc-a4a6b6f28cefb26563b53d8fbf9195023bad2742.tar.gz
Plain writer: Use ALL CAPS for level 1 headers.
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Writers/Markdown.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs
index 5c0476b7d..95d4db29b 100644
--- a/src/Text/Pandoc/Writers/Markdown.hs
+++ b/src/Text/Pandoc/Writers/Markdown.hs
@@ -357,7 +357,10 @@ blockToMarkdown opts (Header level attr inlines) = do
_ | isEnabled Ext_header_attributes opts ->
space <> attrsToMarkdown attr
| otherwise -> empty
- contents <- inlineListToMarkdown opts inlines
+ contents <- inlineListToMarkdown opts $
+ if level == 1 && plain
+ then capitalize inlines
+ else inlines
let setext = writerSetextHeaders opts
return $ nowrap
$ case level of