aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Readers/LaTeX.hs6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs
index 1a5c37e7a..72549a293 100644
--- a/src/Text/Pandoc/Readers/LaTeX.hs
+++ b/src/Text/Pandoc/Readers/LaTeX.hs
@@ -448,6 +448,7 @@ inline = choice [ str
, footnote
, linebreak
, accentedChar
+ , nonbreakingSpace
, specialChar
, rawLaTeXInline
, escapedChar
@@ -671,7 +672,10 @@ strong = try (string "\\textbf{") >> manyTill inline (char '}') >>=
return . Strong
whitespace :: GenParser Char st Inline
-whitespace = many1 (oneOf "~ \t") >> return Space
+whitespace = many1 (oneOf " \t") >> return Space
+
+nonbreakingSpace :: GenParser Char st Inline
+nonbreakingSpace = char '~' >> return (Str "\160")
-- hard line break
linebreak :: GenParser Char st Inline