Resolves: tdf#143443 size of comment box too tall after cut/paste
a problem since...
commit 69c546e1e7a697217f273baa7c1729ff823efd76
Author: Caolán McNamara <caolanm@redhat.com>
Date: Fri Dec 4 16:30:31 2020 +0000
weld annotation window
this sidebar case assumes that the papersize of the underlying
editengine is initially unlimited in size
Change-Id: I127f249158deecef3e2c6874982b4e7cc78e69fe
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124656
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
diff --git a/sw/source/uibase/docvw/SidebarTxtControl.cxx b/sw/source/uibase/docvw/SidebarTxtControl.cxx
index df1636e..eaeca21 100644
--- a/sw/source/uibase/docvw/SidebarTxtControl.cxx
+++ b/sw/source/uibase/docvw/SidebarTxtControl.cxx
@@ -112,7 +112,9 @@ void SidebarTextControl::SetDrawingArea(weld::DrawingArea* pDrawingArea)
pEditView->setEditViewCallbacks(this);
EditEngine* pEditEngine = GetEditEngine();
pEditEngine->SetPaperSize(aSize);
// tdf#143443 note we don't call SetPaperSize on pEditEngine unlike
// similar cases so that the Control defaults to the smallest possible
// height it might take, it can grow later
pEditEngine->SetRefDevice(&rDevice);
pEditView->SetOutputArea(tools::Rectangle(Point(0, 0), aOutputSize));