diff --git a/src/Text/Pandoc/Readers/Docx/Parse/Styles.hs b/src/Text/Pandoc/Readers/Docx/Parse/Styles.hs index bb28b3009..df942579a 100644 --- a/src/Text/Pandoc/Readers/Docx/Parse/Styles.hs +++ b/src/Text/Pandoc/Readers/Docx/Parse/Styles.hs @@ -310,9 +310,8 @@ getIndentation ns el = do , rightParIndent = findAttrByName ns "w" "right" indElement <|> findAttrByName ns "w" "end" indElement >>= stringToInteger - , hangingParIndent = (findAttrByName ns "w" "hanging" indElement >>= stringToInteger) <|> - fmap negate - (findAttrByName ns "w" "firstLine" indElement >>= stringToInteger) + , hangingParIndent = findAttrByName ns "w" "hanging" indElement >>= + stringToInteger } getElementStyleName :: Coercible T.Text a => NameSpaces -> Element -> Maybe a diff --git a/test/docx/relative_indentation_blockquotes.docx b/test/docx/relative_indentation_blockquotes.docx index f318a8509..fe252280e 100644 Binary files a/test/docx/relative_indentation_blockquotes.docx and b/test/docx/relative_indentation_blockquotes.docx differ diff --git a/test/docx/relative_indentation_blockquotes.native b/test/docx/relative_indentation_blockquotes.native index 37806f289..6a70aece8 100644 --- a/test/docx/relative_indentation_blockquotes.native +++ b/test/docx/relative_indentation_blockquotes.native @@ -1,4 +1,6 @@ [Header 1 ("indentation-blockquotes",[],[]) [Str "Indentation",Space,Str "blockquotes"] +,Para [Str "Foobar"] +,Para [Str "First",Space,Str "line",Space,Str "indented."] ,Para [Str "Normal",Space,Str "list",Space,Str "paragraph"] ,Para [Str "List",Space,Str "paragraph",Space,Str "with",Space,Str "less",Space,Str "indent"] ,BlockQuote [Para [Str "List",Space,Str "paragraph",Space,Str "with",Space,Str "more",Space,Str "indent"]]]