summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorJustin Luth <justin_luth@sil.org>2021-11-22 19:33:48 +0200
committerXisco Fauli <xiscofauli@libreoffice.org>2021-11-23 11:50:17 +0100
commit1ed00f2ad9bbc6e920248ba3d39c227acb06e0e6 (patch)
treef18cd7410abeed1f887b07c19db907ce578d07cd /oox
parent13c0794e2040e3a29801a56c6eb9835f364f8f27 (diff)
tdf#138223 oox: don't set highlight color if it is transparent
Probably when this was first implemented in 6.4, it should have set a transparency threshold of when to accept the color as the background (perhaps at 50%). But since this has already been running for a while, I only cancel it if it is fully transparent. No existing unit tests matched this scenario. I'm not making a unit test because the color really ought to be set - it should just be transparent. LO doesn't seem to have a character highlight transparency capability, so this needs to be emulated. Change-Id: I7b295894e529f8345cadc9b30bc43598a9a02e2b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125670 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com> (cherry picked from commit 283586c89a0542efb2d57a36ee3aad7cc5153ed5) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125465 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Diffstat (limited to 'oox')
-rw-r--r--oox/source/drawingml/textcharacterproperties.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/oox/source/drawingml/textcharacterproperties.cxx b/oox/source/drawingml/textcharacterproperties.cxx
index 4eb5acaffb56..ca1d2af1360d 100644
--- a/oox/source/drawingml/textcharacterproperties.cxx
+++ b/oox/source/drawingml/textcharacterproperties.cxx
@@ -175,7 +175,7 @@ void TextCharacterProperties::pushToPropMap( PropertyMap& rPropMap, const XmlFil
}
// TODO If bUnderlineFillFollowText uFillTx (CT_TextUnderlineFillFollowText) is set, fill color of the underline should be the same color as the text
- if( maHighlightColor.isUsed() )
+ if (maHighlightColor.isUsed() && maHighlightColor.getTransparency() != 100)
rPropMap.setProperty( PROP_CharBackColor, maHighlightColor.getColor( rFilter.getGraphicHelper() ));
else
rPropMap.setProperty( PROP_CharBackColor, sal_Int32(-1));