summaryrefslogtreecommitdiff
path: root/xmloff
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2015-03-08 21:32:39 +0100
committerCaolán McNamara <caolanm@redhat.com>2015-03-19 21:09:12 +0000
commit17f741678ea58841ba463465f22eeb6b83c40bc3 (patch)
tree07abfbf1d2b8ab012bab0893f99a3647a72c36e4 /xmloff
parentea1caeed5cc70f41957d56af0ccb4bfdbd01cb87 (diff)
Related tdf#50133: Wrong underlining in Reports
By running some tests, I noticed double wave didn't appear when opening report in non edit mode. First you must know that to indicate "double wave", xml contains these 2 information: style:text-underline-style="wave" style:text-underline-type="double" The problem is the reading order of the parser doesn't seem the same each time. So if it reads style then type, it's ok thanks to this part: 132 case awt::FontUnderline::DOUBLE: 133 // A double line style has priority over a bold line style, 134 // but not over the line style itself. 135 switch( eUnderline ) 136 { 137 case awt::FontUnderline::SINGLE: 138 case awt::FontUnderline::BOLD: 139 break; 140 case awt::FontUnderline::WAVE: 141 case awt::FontUnderline::BOLDWAVE: 142 eNewUnderline = awt::FontUnderline::DOUBLEWAVE; 143 break; but if the parser read type in the first place then style, the case FontUnderline "DOUBLEWAVE" wasn't managed Change-Id: Ie090507898e537827eebaae157dfac248baa43f1 Reviewed-on: https://gerrit.libreoffice.org/14801 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 61a3ace9f42a37640b1ec18fad776ba7c1f61714) Reviewed-on: https://gerrit.libreoffice.org/14914
Diffstat (limited to 'xmloff')
-rw-r--r--xmloff/source/style/undlihdl.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/xmloff/source/style/undlihdl.cxx b/xmloff/source/style/undlihdl.cxx
index 268d04239049..2832d113519a 100644
--- a/xmloff/source/style/undlihdl.cxx
+++ b/xmloff/source/style/undlihdl.cxx
@@ -233,7 +233,9 @@ bool XMLUnderlineStylePropHdl::importXML( const OUString& rStrImpValue, uno::Any
eNewUnderline = awt::FontUnderline::BOLDDASHDOTDOT;
break;
case awt::FontUnderline::WAVE:
- if( awt::FontUnderline::BOLD == eUnderline )
+ if( awt::FontUnderline::DOUBLE == eUnderline )
+ eNewUnderline = awt::FontUnderline::DOUBLEWAVE;
+ else if( awt::FontUnderline::BOLD == eUnderline )
eNewUnderline = awt::FontUnderline::BOLDWAVE;
break;
case awt::FontUnderline::SMALLWAVE: