aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Readers/Docx
diff options
context:
space:
mode:
authorOphir Lifshitz <hangfromthefloor@gmail.com>2015-10-04 06:07:23 -0400
committerOphir Lifshitz <hangfromthefloor@gmail.com>2015-10-04 06:11:07 -0400
commit0b899ce7efa80df700b17b7a4b9f6de1fb88ce8c (patch)
tree9b5c06fecb8bd394cb211d807fdacdb5662f1c38 /src/Text/Pandoc/Readers/Docx
parent6d0e586b2d5f71bbbfccb9978329e6fadfb85b7b (diff)
downloadpandoc-0b899ce7efa80df700b17b7a4b9f6de1fb88ce8c.tar.gz
Docx Reader: Parse soft, no-break hyphen elements
Diffstat (limited to 'src/Text/Pandoc/Readers/Docx')
-rw-r--r--src/Text/Pandoc/Readers/Docx/Parse.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/Docx/Parse.hs b/src/Text/Pandoc/Readers/Docx/Parse.hs
index cce80fb48..53af19dfd 100644
--- a/src/Text/Pandoc/Readers/Docx/Parse.hs
+++ b/src/Text/Pandoc/Readers/Docx/Parse.hs
@@ -208,7 +208,7 @@ data Run = Run RunStyle [RunElem]
| InlineDrawing FilePath B.ByteString
deriving Show
-data RunElem = TextRun String | LnBrk | Tab
+data RunElem = TextRun String | LnBrk | Tab | SoftHyphen | NoBreakHyphen
deriving Show
data VertAlign = BaseLn | SupScrpt | SubScrpt
@@ -877,6 +877,8 @@ elemToRunElem ns element
map (\x -> fromMaybe x . getUnicode f . lowerFromPrivate $ x) str
| isElem ns "w" "br" element = return LnBrk
| isElem ns "w" "tab" element = return Tab
+ | isElem ns "w" "softHyphen" element = return SoftHyphen
+ | isElem ns "w" "noBreakHyphen" element = return NoBreakHyphen
| isElem ns "w" "sym" element = return (getSymChar ns element)
| otherwise = throwError WrongElem
where