Docx reader: Fix bug in character styles.
Style handling has been cleaned up, but introduced a bug here. There wasn't previously a test to catch it.
This commit is contained in:
parent
0ff9ec2f4e
commit
9969b2ebee
1 changed files with 2 additions and 2 deletions
|
@ -242,14 +242,14 @@ runStyleToTransform rPr
|
||||||
, s `elem` emphStyles =
|
, s `elem` emphStyles =
|
||||||
let rPr' = rPr{rStyle = Nothing, isItalic = Nothing}
|
let rPr' = rPr{rStyle = Nothing, isItalic = Nothing}
|
||||||
in
|
in
|
||||||
case isItalic rPr' of
|
case isItalic rPr of
|
||||||
Just False -> runStyleToTransform rPr'
|
Just False -> runStyleToTransform rPr'
|
||||||
_ -> emph . (runStyleToTransform rPr')
|
_ -> emph . (runStyleToTransform rPr')
|
||||||
| Just s <- rStyle rPr
|
| Just s <- rStyle rPr
|
||||||
, s `elem` strongStyles =
|
, s `elem` strongStyles =
|
||||||
let rPr' = rPr{rStyle = Nothing, isBold = Nothing}
|
let rPr' = rPr{rStyle = Nothing, isBold = Nothing}
|
||||||
in
|
in
|
||||||
case isItalic rPr' of
|
case isBold rPr of
|
||||||
Just False -> runStyleToTransform rPr'
|
Just False -> runStyleToTransform rPr'
|
||||||
_ -> strong . (runStyleToTransform rPr')
|
_ -> strong . (runStyleToTransform rPr')
|
||||||
| Just True <- isItalic rPr =
|
| Just True <- isItalic rPr =
|
||||||
|
|
Loading…
Add table
Reference in a new issue