From 270eb7bed422ea5e742937fcd24933ffe8033fb4 Mon Sep 17 00:00:00 2001 From: fiddlosopher Date: Sun, 24 Feb 2008 05:48:31 +0000 Subject: Moved BlockWrapper and wrappedBlocksToDoc from ConTeXt writer to Shared. git-svn-id: https://pandoc.googlecode.com/svn/trunk@1242 788f1e2b-df1e-0410-8736-df70ead52e1b --- Text/Pandoc/Writers/ConTeXt.hs | 8 -------- 1 file changed, 8 deletions(-) (limited to 'Text/Pandoc/Writers') diff --git a/Text/Pandoc/Writers/ConTeXt.hs b/Text/Pandoc/Writers/ConTeXt.hs index cd1d09e0c..1695d70e7 100644 --- a/Text/Pandoc/Writers/ConTeXt.hs +++ b/Text/Pandoc/Writers/ConTeXt.hs @@ -41,8 +41,6 @@ data WriterState = , stOptions :: WriterOptions -- writer options } -data BlockWrapper = Pad Doc | Reg Doc - orderedListStyles = cycle ["[n]","[a]", "[r]", "[g]"] -- | Convert Pandoc to ConTeXt. @@ -229,12 +227,6 @@ defListItemToConTeXt (term, def) = do def' <- blockListToConTeXt def return $ Pad $ text "\\startdescr{" <> term' <> char '}' $$ def' $$ text "\\stopdescr" -wrappedBlocksToDoc :: [BlockWrapper] -> Doc -wrappedBlocksToDoc = foldr addBlock empty - where addBlock (Pad d) accum | isEmpty accum = d - addBlock (Pad d) accum = d $$ text "" $$ accum - addBlock (Reg d) accum = d $$ accum - -- | Convert list of block elements to ConTeXt. blockListToConTeXt :: [Block] -> State WriterState Doc blockListToConTeXt lst = mapM blockToConTeXt lst >>= return . wrappedBlocksToDoc -- cgit v1.2.3