aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Tests/Old.hs6
-rw-r--r--src/Text/Pandoc/Highlighting.hs17
-rw-r--r--src/pandoc.hs7
3 files changed, 2 insertions, 28 deletions
diff --git a/src/Tests/Old.hs b/src/Tests/Old.hs
index 71a198ca1..1ec32a30d 100644
--- a/src/Tests/Old.hs
+++ b/src/Tests/Old.hs
@@ -13,7 +13,6 @@ import Data.Algorithm.Diff
import Text.Pandoc.Shared ( normalize, defaultWriterOptions )
import Text.Pandoc.Writers.Native ( writeNative )
import Text.Pandoc.Readers.Native ( readNative )
-import Text.Pandoc.Highlighting ( languages )
import Prelude hiding ( readFile )
import qualified Data.ByteString.Lazy as B
import Data.ByteString.Lazy.UTF8 (toString)
@@ -121,10 +120,7 @@ lhsWriterTests format
]
where
t n f = test n ["--columns=78", "-r", "native", "-s", "-w", f]
- "lhs-test.native" ("lhs-test" <.> ext f)
- ext f = if null languages && format == "html"
- then "nohl" <.> f
- else f
+ "lhs-test.native" ("lhs-test" <.> f)
lhsReaderTest :: String -> Test
lhsReaderTest format =
diff --git a/src/Text/Pandoc/Highlighting.hs b/src/Text/Pandoc/Highlighting.hs
index 282c13930..60e900333 100644
--- a/src/Text/Pandoc/Highlighting.hs
+++ b/src/Text/Pandoc/Highlighting.hs
@@ -36,7 +36,6 @@ module Text.Pandoc.Highlighting ( languages
) where
import Text.Blaze
import Text.Pandoc.Definition
-#ifdef _HIGHLIGHTING
import Text.Highlighting.Kate ( SourceLine, languages, highlightAs, formatAsHtml,
TokenType(..), formatAsLaTeX, FormatOption (..), defaultHighlightingCss, languagesByExtension )
import Data.List (find)
@@ -82,19 +81,3 @@ highlightLaTeX :: Bool -- ^ True if inline
-> Maybe String -- ^ Maybe formatted LaTeX
highlightLaTeX = highlight formatAsLaTeX
-#else
-defaultHighlightingCss :: String
-defaultHighlightingCss = ""
-
-languages :: [String]
-languages = []
-
-languagesByExtension :: String -> [String]
-languagesByExtension _ = []
-
-highlightHtml :: Bool -> Attr -> String -> Maybe Html
-highlightHtml _ _ _ = Left "Pandoc was not compiled with support for highlighting"
-
-highlightLaTeX :: Bool -> Attr -> String -> Maybe String
-highlightLaTeX _ _ _ = Left "Pandoc was not compiled with support for highlighting"
-#endif
diff --git a/src/pandoc.hs b/src/pandoc.hs
index f855e2d3f..3ef82accc 100644
--- a/src/pandoc.hs
+++ b/src/pandoc.hs
@@ -33,9 +33,7 @@ import Text.Pandoc
import Text.Pandoc.Shared ( tabFilter, ObfuscationMethod (..), readDataFile,
headerShift, findDataFile, normalize )
import Text.Pandoc.SelfContained ( makeSelfContained )
-#ifdef _HIGHLIGHTING
import Text.Pandoc.Highlighting ( languages )
-#endif
import System.Environment ( getArgs, getProgName )
import System.Exit ( exitWith, ExitCode (..) )
import System.FilePath
@@ -65,11 +63,8 @@ copyrightMessage = "\nCopyright (C) 2006-2011 John MacFarlane\n" ++
compileInfo :: String
compileInfo =
"\nCompiled with citeproc support." ++
-#ifdef _HIGHLIGHTING
"\nCompiled with syntax highlighting support for:\n" ++
- wrapWords 78 languages ++
-#endif
- ""
+ wrapWords 78 languages
-- | Converts a list of strings into a single string with the items printed as
-- comma separated words in lines with a maximum line length.