diff options
author | John MacFarlane <jgm@berkeley.edu> | 2018-04-26 12:29:06 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2018-04-26 12:29:06 -0700 |
commit | 619aaf29aa0bee2c8683fa5b73dcd23a8695b9e7 (patch) | |
tree | 2a9e5cd496201a7e4aff5b5e97e7a17fe7acfecb /src/Text/Pandoc/Writers | |
parent | a96c762a10f9b6e97a5660664750ad6e3ef7f5b7 (diff) | |
parent | f224567d52096fd6219a2a4a4d2b9cbcc5219e7a (diff) | |
download | pandoc-619aaf29aa0bee2c8683fa5b73dcd23a8695b9e7.tar.gz |
Merge branch 'fb2-hrblankline' of https://github.com/labdsf/pandoc into labdsf-fb2-hrblankline
Diffstat (limited to 'src/Text/Pandoc/Writers')
-rw-r--r-- | src/Text/Pandoc/Writers/FB2.hs | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/Text/Pandoc/Writers/FB2.hs b/src/Text/Pandoc/Writers/FB2.hs index e1fa7f474..a46011a8f 100644 --- a/src/Text/Pandoc/Writers/FB2.hs +++ b/src/Text/Pandoc/Writers/FB2.hs @@ -365,10 +365,7 @@ blockToXml h@Header{} = do -- should not occur after hierarchicalize, except inside lists/blockquotes report $ BlockNotRendered h return [] -blockToXml HorizontalRule = return - [ el "empty-line" () - , el "p" (txt (replicate 10 '—')) - , el "empty-line" () ] +blockToXml HorizontalRule = return [ el "empty-line" () ] blockToXml (Table caption aligns _ headers rows) = do hd <- mkrow "th" headers aligns bd <- mapM (\r -> mkrow "td" r aligns) rows @@ -398,7 +395,7 @@ plainToPara [] = [] plainToPara (Plain inlines : rest) = Para inlines : plainToPara rest plainToPara (Para inlines : rest) = - Para inlines : Plain [LineBreak] : plainToPara rest + Para inlines : HorizontalRule : plainToPara rest -- HorizontalRule will be converted to <empty-line /> plainToPara (p:rest) = p : plainToPara rest -- Simulate increased indentation level. Will not really work @@ -449,8 +446,8 @@ toXml (Quoted DoubleQuote ss) = do toXml (Cite _ ss) = cMapM toXml ss -- FIXME: support citation styles toXml (Code _ s) = return [el "code" s] toXml Space = return [txt " "] -toXml SoftBreak = return [txt " "] -toXml LineBreak = return [el "empty-line" ()] +toXml SoftBreak = return [txt "\n"] +toXml LineBreak = return [txt "\n"] toXml (Math _ formula) = insertMath InlineImage formula toXml il@(RawInline _ _) = do report $ InlineNotRendered il |