[Libreoffice-commits] core.git: Branch 'libreoffice-7-0-1' - vcl/source
Mike Kaganski (via logerrit)
logerrit at kemper.freedesktop.org
Thu Aug 20 13:45:25 UTC 2020
vcl/source/outdev/polygon.cxx | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
New commits:
commit 597a095ecb0cf74c613ec2ee19ec253b9fdf9c0d
Author: Mike Kaganski <mike.kaganski at collabora.com>
AuthorDate: Fri Aug 14 02:01:05 2020 +0300
Commit: Adolfo Jayme Barrientos <fitojb at ubuntu.com>
CommitDate: Thu Aug 20 15:44:51 2020 +0200
tdf#134968: don't forget to draw on mpAlphaVDev in fallback case
Change-Id: I6ab8cc8907943c3bb7fd717624ea4ac7c9d4fd5e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100711
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski at collabora.com>
(cherry picked from commit 18fd4437077f1e51ae54cfd1a160866cca015c2d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100692
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
(cherry picked from commit 76b93688505c0ab2b0e1876d5461a36d8ea22414)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100699
Reviewed-by: Xisco Fauli <xiscofauli at libreoffice.org>
Reviewed-by: Adolfo Jayme Barrientos <fitojb at ubuntu.com>
Tested-by: Adolfo Jayme Barrientos <fitojb at ubuntu.com>
diff --git a/vcl/source/outdev/polygon.cxx b/vcl/source/outdev/polygon.cxx
index 77e0564ba16f..e031fb05990c 100644
--- a/vcl/source/outdev/polygon.cxx
+++ b/vcl/source/outdev/polygon.cxx
@@ -290,6 +290,8 @@ void OutputDevice::ImplDrawPolyPolygonWithB2DPolyPolygon(const basegfx::B2DPolyP
if( mbInitFillColor )
InitFillColor();
+ bool bSuccess(false);
+
if((mnAntialiasing & AntialiasingFlags::EnableB2dDraw) &&
mpGraphics->supportsOperation(OutDevSupportType::B2DDraw) &&
RasterOp::OverPaint == GetRasterOp() &&
@@ -297,7 +299,7 @@ void OutputDevice::ImplDrawPolyPolygonWithB2DPolyPolygon(const basegfx::B2DPolyP
{
const basegfx::B2DHomMatrix aTransform(ImplGetDeviceTransformation());
basegfx::B2DPolyPolygon aB2DPolyPolygon(rB2DPolyPoly);
- bool bSuccess(true);
+ bSuccess = true;
// ensure closed - maybe assert, hinders buffering
if(!aB2DPolyPolygon.isClosed())
@@ -335,20 +337,18 @@ void OutputDevice::ImplDrawPolyPolygonWithB2DPolyPolygon(const basegfx::B2DPolyP
break;
}
}
+ }
- if(bSuccess)
- {
- if (mpAlphaVDev)
- mpAlphaVDev->ImplDrawPolyPolygonWithB2DPolyPolygon(rB2DPolyPoly);
-
- return;
- }
+ if (!bSuccess)
+ {
+ // fallback to old polygon drawing if needed
+ const tools::PolyPolygon aToolsPolyPolygon(rB2DPolyPoly);
+ const tools::PolyPolygon aPixelPolyPolygon = ImplLogicToDevicePixel(aToolsPolyPolygon);
+ ImplDrawPolyPolygon(aPixelPolyPolygon.Count(), aPixelPolyPolygon);
}
- // fallback to old polygon drawing if needed
- const tools::PolyPolygon aToolsPolyPolygon( rB2DPolyPoly );
- const tools::PolyPolygon aPixelPolyPolygon = ImplLogicToDevicePixel( aToolsPolyPolygon );
- ImplDrawPolyPolygon( aPixelPolyPolygon.Count(), aPixelPolyPolygon );
+ if (mpAlphaVDev)
+ mpAlphaVDev->ImplDrawPolyPolygonWithB2DPolyPolygon(rB2DPolyPoly);
}
// #100127# Extracted from OutputDevice::DrawPolyPolygon()
More information about the Libreoffice-commits
mailing list