diff options
author | John MacFarlane <jgm@berkeley.edu> | 2018-10-24 09:12:28 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2018-10-24 09:12:28 -0700 |
commit | f1c476fe3c98a8fd0fd9005ddf24fa1b0172a917 (patch) | |
tree | 3d712a86eefadd0ce8aac73ec037d737502e6d80 /src/Text | |
parent | 3a9f807052f0f8af6e281a9a8dbd0bf809ea55db (diff) | |
download | pandoc-f1c476fe3c98a8fd0fd9005ddf24fa1b0172a917.tar.gz |
Ms writer - removed old escapeBar.
We don't need this now that we use @ for delim.
Diffstat (limited to 'src/Text')
-rw-r--r-- | src/Text/Pandoc/Writers/Ms.hs | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/Text/Pandoc/Writers/Ms.hs b/src/Text/Pandoc/Writers/Ms.hs index 2fb949cb9..46ddc4c59 100644 --- a/src/Text/Pandoc/Writers/Ms.hs +++ b/src/Text/Pandoc/Writers/Ms.hs @@ -112,12 +112,6 @@ escapeStr opts = escapeUri :: String -> String escapeUri = escapeURIString (\c -> c /= '@' && isAllowedInURI c) --- | Escape | character, used to mark inline math, inside math. -escapeBar :: String -> String -escapeBar = concatMap go - where go '|' = "\\[ba]" - go c = [c] - toSmallCaps :: WriterOptions -> String -> String toSmallCaps _ [] = [] toSmallCaps opts (c:cs) @@ -416,7 +410,7 @@ inlineToMs opts (Math InlineMath str) = do res <- convertMath writeEqn InlineMath str case res of Left il -> inlineToMs opts il - Right r -> return $ text "@" <> text (escapeBar r) <> text "@" + Right r -> return $ text "@" <> text r <> text "@" inlineToMs opts (Math DisplayMath str) = do res <- convertMath writeEqn InlineMath str case res of @@ -424,7 +418,7 @@ inlineToMs opts (Math DisplayMath str) = do contents <- inlineToMs opts il return $ cr <> text ".RS" $$ contents $$ text ".RE" Right r -> return $ - cr <> text ".EQ" $$ text (escapeBar r) $$ text ".EN" + cr <> text ".EQ" $$ text r $$ text ".EN" inlineToMs _ il@(RawInline f str) | f == Format "ms" = return $ text str | otherwise = do |