summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2023-03-16 14:36:18 +0000
committerCaolán McNamara <caolanm@redhat.com>2023-03-16 20:19:31 +0000
commitaa252a2d019c350d90b7c4a090246451a6006b87 (patch)
treed61e2e78a981d0dc177ed33cd6e17fa473fce756
parent0c9fafe07df10d541251f494b28fcb89e5387cda (diff)
Resolves: tdf#152704 old image remains underneath when new image drawn
in this dialog preview widget Change-Id: Id33995d9a9557d235178be0d12cc6b44e146ff4c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148997 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--sw/source/ui/frmdlg/frmpage.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/sw/source/ui/frmdlg/frmpage.cxx b/sw/source/ui/frmdlg/frmpage.cxx
index e9cf9974d0ed..94c86e95df5e 100644
--- a/sw/source/ui/frmdlg/frmpage.cxx
+++ b/sw/source/ui/frmdlg/frmpage.cxx
@@ -2658,7 +2658,8 @@ void BmpWindow::SetDrawingArea(weld::DrawingArea* pDrawingArea)
void BmpWindow::Paint(vcl::RenderContext& rRenderContext, const tools::Rectangle&)
{
// Setup
- rRenderContext.SetBackground();
+ rRenderContext.SetBackground(Wallpaper(Application::GetSettings().GetStyleSettings().GetDialogColor()));
+ rRenderContext.Erase();
// #i119307# the graphic might have transparency, set up white as the color
// to use when drawing a rectangle under the image
rRenderContext.SetLineColor(COL_WHITE);