diff options
author | Luboš Luňák <l.lunak@collabora.com> | 2022-08-31 17:22:08 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2022-09-01 13:17:19 +0200 |
commit | 6a57652cfc2e46a271091246cd867804c39f845c (patch) | |
tree | 6b78ab2f0d8934e194fab612278ca31d98f0e503 /drawinglayer | |
parent | f5e3b0a7966d7d28817292adbb58fb43f28b7c6d (diff) |
fix limiting drawing of softedge effect (tdf#141981)
Apparently an empty viewport actually means everything should be drawn.
Change-Id: I55ae453a8f264d48222ade48a2953ab7d97c7f79
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138991
Tested-by: Jenkins
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'drawinglayer')
-rw-r--r-- | drawinglayer/source/processor2d/vclpixelprocessor2d.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx b/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx index 087f6bcedb37..9eb5a00410ac 100644 --- a/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx +++ b/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx @@ -1072,7 +1072,8 @@ void VclPixelProcessor2D::processGlowPrimitive2D(const primitive2d::GlowPrimitiv // Limit the bitmap size to the visible area. basegfx::B2DRange bitmapRange(aRange); - bitmapRange.intersect(aExpandedViewInfo.getDiscreteViewport()); + if (!aExpandedViewInfo.getDiscreteViewport().isEmpty()) + bitmapRange.intersect(aExpandedViewInfo.getDiscreteViewport()); if (!bitmapRange.isEmpty()) { const tools::Rectangle aRect( @@ -1133,7 +1134,8 @@ void VclPixelProcessor2D::processSoftEdgePrimitive2D( // Limit the bitmap size to the visible area. basegfx::B2DRange bitmapRange(aRange); - bitmapRange.intersect(aExpandedViewInfo.getDiscreteViewport()); + if (!aExpandedViewInfo.getDiscreteViewport().isEmpty()) + bitmapRange.intersect(aExpandedViewInfo.getDiscreteViewport()); if (!bitmapRange.isEmpty()) { const tools::Rectangle aRect( |