[Libreoffice-commits] core.git: sw/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Mar 5 13:46:52 UTC 2021


 sw/source/uibase/utlui/content.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 3b2efb70b65906a4a3c521f5cc387fc62cbef230
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Mar 5 10:04:16 2021 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Mar 5 14:46:07 2021 +0100

    don't use the vcl::Window parent to derive a treeview size
    
    Change-Id: Ib86c3eb25df390b5b4fba576abb3158728ff0a0e
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111994
    Tested-by: Caolán McNamara <caolanm at redhat.com>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx
index aa639d399055..885d63da164e 100644
--- a/sw/source/uibase/utlui/content.cxx
+++ b/sw/source/uibase/utlui/content.cxx
@@ -921,8 +921,8 @@ SwContentTree::SwContentTree(std::unique_ptr<weld::TreeView> xTreeView, SwNaviga
     , m_bIsOutlineMoveable(true)
     , m_bViewHasChanged(false)
 {
-    Size aSize(m_xDialog->LogicToPixel(Size(110, 112), MapMode(MapUnit::MapAppFont)));
-    m_xTreeView->set_size_request(aSize.Width(), aSize.Height());
+    m_xTreeView->set_size_request(m_xTreeView->get_approximate_digit_width() * 30,
+                                  m_xTreeView->get_text_height() * 14);
 
     m_xTreeView->set_help_id(HID_NAVIGATOR_TREELIST);
 


More information about the Libreoffice-commits mailing list