svx/source/svdraw/svdotextdecomposition.cxx |    5 +++++
 1 file changed, 5 insertions(+)

New commits:
commit f8983580f67b06461b23fa34dd1bfdefbb33012a
Author:     Caolán McNamara <caol...@redhat.com>
AuthorDate: Wed Oct 5 20:27:22 2022 +0100
Commit:     Caolán McNamara <caol...@redhat.com>
CommitDate: Thu Oct 6 09:54:10 2022 +0200

    Resolves: tdf#151053 Body text with dark bg not visible in Notes view
    
    this is a similar case to:
    
    commit 76a0b3170664b19c3eb66edc8fccb04dc5485387
    Author: Caolán McNamara <caol...@redhat.com>
    Date:   Fri Jan 10 16:49:19 2014 +0000
    
        Resolves: fdo#35779 set the bg color of the editeng from the text shape
    
    Change-Id: Ib7ca42426397346e5d7473b93e60f853e646a423
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140995
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caol...@redhat.com>

diff --git a/svx/source/svdraw/svdotextdecomposition.cxx 
b/svx/source/svdraw/svdotextdecomposition.cxx
index 220a8549bbaf..0c8928891231 100644
--- a/svx/source/svdraw/svdotextdecomposition.cxx
+++ b/svx/source/svdraw/svdotextdecomposition.cxx
@@ -759,6 +759,10 @@ void SdrTextObj::impDecomposeAutoFitTextPrimitive(
     rOutliner.SetMinAutoPaperSize(aNullSize);
     rOutliner.SetMaxAutoPaperSize(Size(1000000,1000000));
 
+    // That color needs to be restored on leaving this method
+    Color aOriginalBackColor(rOutliner.GetBackgroundColor());
+    setSuitableOutlinerBg(rOutliner);
+
     // add one to range sizes to get back to the old Rectangle and outliner 
measurements
     const sal_uInt32 nAnchorTextWidth(FRound(aAnchorTextRange.getWidth() + 1));
     const sal_uInt32 nAnchorTextHeight(FRound(aAnchorTextRange.getHeight() + 
1));
@@ -861,6 +865,7 @@ void SdrTextObj::impDecomposeAutoFitTextPrimitive(
     aConverter.decomposeBlockTextPrimitive(aNewTransformA, aNewTransformB, 
aClipRange);
 
     // cleanup outliner
+    rOutliner.SetBackgroundColor(aOriginalBackColor);
     rOutliner.Clear();
     rOutliner.setVisualizedPage(nullptr);
     rOutliner.SetControlWord(nOriginalControlWord);

Reply via email to