diff options
author | Patrick Luby <guibmacdev@gmail.com> | 2024-07-17 08:41:30 -0400 |
---|---|---|
committer | Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> | 2024-07-23 14:00:27 +0200 |
commit | 69e84cd448e359bf63ead6ed647c380b6ddc2c6c (patch) | |
tree | d2dc09f67bc0403634db8400078d1b4245feead6 | |
parent | 02102816e18863cc249abb4a4d87ef3b0248d093 (diff) |
tdf#162062 only apply fix for tdf#161833 if there is a palette
Change-Id: I50d13ed336110eb5e65e99dd5d4a6c6defe6bc50
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170627
Tested-by: Jenkins
Reviewed-by: Patrick Luby <guibomacdev@gmail.com>
(cherry picked from commit ee76e5041c79843ef0942c6427d4cd3717820ff6)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170654
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
-rw-r--r-- | vcl/source/bitmap/BitmapEx.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vcl/source/bitmap/BitmapEx.cxx b/vcl/source/bitmap/BitmapEx.cxx index c541579744b0..89134e7647ff 100644 --- a/vcl/source/bitmap/BitmapEx.cxx +++ b/vcl/source/bitmap/BitmapEx.cxx @@ -1291,7 +1291,8 @@ tools::Polygon BitmapEx::GetContour( bool bContourEdgeDetect, // causes clipping of any shadows or other semi-transaprent // areas in the image. So, instead of testing for fully opaque // pixels, treat pixels that are not fully transparent as opaque. - const BitmapColor aTransparent = pAcc->GetBestMatchingColor( COL_ALPHA_TRANSPARENT ); + // tdf#162062 only apply fix for tdf#161833 if there is a palette + const BitmapColor aTransparent = pAcc->GetBestMatchingColor( pAcc->HasPalette() ? COL_ALPHA_TRANSPARENT : COL_ALPHA_OPAQUE ); pPoints1.reset(new Point[ nHeight ]); pPoints2.reset(new Point[ nHeight ]); |