oox/source/drawingml/textcharacterproperties.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
New commits: commit 283586c89a0542efb2d57a36ee3aad7cc5153ed5 Author: Justin Luth <justin_l...@sil.org> AuthorDate: Mon Nov 22 19:33:48 2021 +0200 Commit: Justin Luth <jl...@mail.com> CommitDate: Tue Nov 23 06:57:23 2021 +0100 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 <jl...@mail.com> diff --git a/oox/source/drawingml/textcharacterproperties.cxx b/oox/source/drawingml/textcharacterproperties.cxx index a34cb14af639..93d642324782 100644 --- a/oox/source/drawingml/textcharacterproperties.cxx +++ b/oox/source/drawingml/textcharacterproperties.cxx @@ -195,7 +195,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));