diff options
author | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2007-07-22 16:08:19 +0000 |
---|---|---|
committer | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2007-07-22 16:08:19 +0000 |
commit | 2b3c2d43efc3552d3973d306fb3c2a57deadf166 (patch) | |
tree | 3e7cb7eacfa896480b58ace336125a53c65f156e /src/Text/Pandoc/Writers | |
parent | 6bb6dd2bfd526fff9a469fddd9515aec268bfe15 (diff) | |
download | pandoc-2b3c2d43efc3552d3973d306fb3c2a57deadf166.tar.gz |
Markdown writer: Substituted char for text for single characters.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@756 788f1e2b-df1e-0410-8736-df70ead52e1b
Diffstat (limited to 'src/Text/Pandoc/Writers')
-rw-r--r-- | src/Text/Pandoc/Writers/Markdown.hs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs index b55885509..707f2b346 100644 --- a/src/Text/Pandoc/Writers/Markdown.hs +++ b/src/Text/Pandoc/Writers/Markdown.hs @@ -236,7 +236,7 @@ definitionListItemToMarkdown :: WriterOptions definitionListItemToMarkdown opts (label, items) = do labelText <- inlineListToMarkdown opts label let tabStop = writerTabStop opts - let leader = text ":" + let leader = char ':' contents <- mapM (\item -> blockToMarkdown opts item >>= (\txt -> return (leader $$ nest tabStop txt))) items >>= (return . vcat) @@ -275,7 +275,7 @@ inlineListToMarkdown opts lst = mapM (inlineToMarkdown opts) lst >>= (return . h inlineToMarkdown :: WriterOptions -> Inline -> State WriterState Doc inlineToMarkdown opts (Emph lst) = do contents <- inlineListToMarkdown opts lst - return $ text "*" <> contents <> text "*" + return $ char '*' <> contents <> char '*' inlineToMarkdown opts (Strong lst) = do contents <- inlineListToMarkdown opts lst return $ text "**" <> contents <> text "**" @@ -285,11 +285,11 @@ inlineToMarkdown opts (Strikeout lst) = do inlineToMarkdown opts (Superscript lst) = do contents <- inlineListToMarkdown opts lst let contents' = text $ substitute " " "\\ " $ render contents - return $ text "^" <> contents' <> text "^" + return $ char '^' <> contents' <> char '^' inlineToMarkdown opts (Subscript lst) = do contents <- inlineListToMarkdown opts lst let contents' = text $ substitute " " "\\ " $ render contents - return $ text "~" <> contents' <> text "~" + return $ char '~' <> contents' <> char '~' inlineToMarkdown opts (Quoted SingleQuote lst) = do contents <- inlineListToMarkdown opts lst return $ char '\'' <> contents <> char '\'' |