From 1cd99f98807fdc656b4fc6518ee5c6642ac9626c Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Wed, 7 Jul 2010 10:28:25 -0700 Subject: Addendum to the fix to issue #242. The previous fix resulted in bird tracks being included in both html and html+lhs renderings of literate haskell sections when pandoc was compiled without highlighting support. This change make pandoc without highlighting behave like pandoc with highlighting: the bird tracks are used only if html+lhs output is specified. --- src/Text/Pandoc/Writers/HTML.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Text/Pandoc') diff --git a/src/Text/Pandoc/Writers/HTML.hs b/src/Text/Pandoc/Writers/HTML.hs index e62a06b4f..08cd18ad0 100644 --- a/src/Text/Pandoc/Writers/HTML.hs +++ b/src/Text/Pandoc/Writers/HTML.hs @@ -285,7 +285,7 @@ blockToHtml opts (CodeBlock (id',classes,keyvals) rawCode) = do attrs = [theclass (unwords classes') | not (null classes')] ++ [prefixedId opts id' | not (null id')] ++ map (\(x,y) -> strAttr x y) keyvals - addBird = if "literate" `elem` classes + addBird = if "literate" `elem` classes' then unlines . map ("> " ++) . lines else unlines . lines in return $ pre ! attrs $ thecode << -- cgit v1.2.3