From a5eb02f6a7feb4b3dee913fd395c98736638c127 Mon Sep 17 00:00:00 2001 From: Albert Krewinkel Date: Mon, 20 Oct 2014 19:54:21 +0200 Subject: Org reader: parse LaTeX-style MathML entities MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Org supports special symbols which can be included using LaTeX syntax, but are actually MathML entities. Examples for this are `\nbsp` (non-breaking space), `\Aacute` (the letter A with accent acute) or `\copy` (the copyright sign ©). This fixes #1657. --- tests/Tests/Readers/Org.hs | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'tests/Tests') diff --git a/tests/Tests/Readers/Org.hs b/tests/Tests/Readers/Org.hs index ef2f2d1ae..392388ec0 100644 --- a/tests/Tests/Readers/Org.hs +++ b/tests/Tests/Readers/Org.hs @@ -276,6 +276,18 @@ tests = "\\notacommand{foo}" =?> para (rawInline "latex" "\\notacommand{foo}") + , "MathML symbol in LaTeX-style" =: + "There is a hackerspace in Lübeck, Germany, called nbsp (unicode symbol: '\\nbsp')." =?> + para ("There is a hackerspace in Lübeck, Germany, called nbsp (unicode symbol: ' ').") + + , "MathML symbol in LaTeX-style, including braces" =: + "\\Aacute{}stor" =?> + para "Ástor" + + , "MathML copy sign" =: + "\\copy" =?> + para "©" + , "LaTeX citation" =: "\\cite{Coffee}" =?> let citation = Citation -- cgit v1.2.3