From 29e1c9529f4b9f6cd02f89a477a1bc57943e6f26 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Mon, 29 Sep 2014 21:48:59 -0700 Subject: Don't wrap lines in rST line blocks. Closes #1656. Fixing pandoc to wrap the lines but insert spaces would be much more complicated. This at least makes the output semantically correct. --- src/Text/Pandoc/Writers/RST.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Text/Pandoc/Writers/RST.hs b/src/Text/Pandoc/Writers/RST.hs index 57ebfc360..a32d3ebac 100644 --- a/src/Text/Pandoc/Writers/RST.hs +++ b/src/Text/Pandoc/Writers/RST.hs @@ -177,7 +177,7 @@ blockToRST (Para [Image txt (src,'f':'i':'g':':':tit)]) = do blockToRST (Para inlines) | LineBreak `elem` inlines = do -- use line block if LineBreaks lns <- mapM inlineListToRST $ splitBy (==LineBreak) inlines - return $ (vcat $ map (text "| " <>) lns) <> blankline + return $ (vcat $ map (nowrap . (text "| " <>)) lns) <> blankline | otherwise = do contents <- inlineListToRST inlines return $ contents <> blankline -- cgit v1.2.3