diff options
author | Luboš Luňák <l.lunak@collabora.com> | 2022-08-31 17:22:08 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2022-09-06 16:36:25 +0200 |
commit | 965a713387422d75c3b16ac666f123ca6faa9570 (patch) | |
tree | f0a086cb890218d5792f6db7bf97f119fa2f4db5 /drawinglayer | |
parent | b1d8f0be8cf1426102a103625ad5ca44226634cf (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( |