include/svx/sidebar/ValueSetWithTextControl.hxx      |    1 -
 svx/source/sidebar/tools/ValueSetWithTextControl.cxx |    9 ---------
 sw/source/uibase/sidebar/PageSizeControl.cxx         |    1 -
 3 files changed, 11 deletions(-)

New commits:
commit 759c9ea8e66b5fc1a362cf914055ac498fbbd80a
Author:     Justin Luth <jl...@mail.com>
AuthorDate: Mon Feb 26 11:09:59 2024 -0500
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Tue Feb 27 09:27:32 2024 +0100

    tdf#159865 Revert "tdf#136905 NBB: let ValueSetWithTextControl set optimal"
    
    ...height
    
    This reverts my 24.2 commit 1876feb8a8805b2f80537e2828c152ccbdf67fe2.
    
    Change-Id: I70c3668393a13992f9ce489e86b07860218445b6
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163954
    Tested-by: Justin Luth <jl...@mail.com>
    Reviewed-by: Justin Luth <jl...@mail.com>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163961
    Tested-by: Jenkins

diff --git a/include/svx/sidebar/ValueSetWithTextControl.hxx 
b/include/svx/sidebar/ValueSetWithTextControl.hxx
index 407e9606757f..ac397f9fdab6 100644
--- a/include/svx/sidebar/ValueSetWithTextControl.hxx
+++ b/include/svx/sidebar/ValueSetWithTextControl.hxx
@@ -40,7 +40,6 @@ public:
 
     SVX_DLLPRIVATE virtual void SetDrawingArea(weld::DrawingArea* 
pDrawingArea) override;
 
-    void SetOptimalDrawingAreaHeight();
     void AddItem(const OUString& rItemText, const OUString& rItemText2);
 
     SVX_DLLPRIVATE virtual void UserDraw(const UserDrawEvent& rUDEvt) override;
diff --git a/svx/source/sidebar/tools/ValueSetWithTextControl.cxx 
b/svx/source/sidebar/tools/ValueSetWithTextControl.cxx
index 91cea51325e6..b5b1f2be3ce9 100644
--- a/svx/source/sidebar/tools/ValueSetWithTextControl.cxx
+++ b/svx/source/sidebar/tools/ValueSetWithTextControl.cxx
@@ -43,15 +43,6 @@ void 
ValueSetWithTextControl::SetDrawingArea(weld::DrawingArea* pDrawingArea)
     SetColCount();
 }
 
-void ValueSetWithTextControl::SetOptimalDrawingAreaHeight()
-{
-    const vcl::Font 
aFont(Application::GetSettings().GetStyleSettings().GetLabelFont());
-    const sal_Int32 nRowHeight = aFont.GetFontSize().Height() * 9 / 4; // see 
UserDraw()
-    const Size aSize(GetOutputSizePixel().Width(), nRowHeight * 
maItems.size());
-    GetDrawingArea()->set_size_request(aSize.Width(), aSize.Height());
-    SetOutputSizePixel(aSize);
-}
-
 void ValueSetWithTextControl::AddItem(
     const OUString& rItemText,
     const OUString& rItemText2 )
diff --git a/sw/source/uibase/sidebar/PageSizeControl.cxx 
b/sw/source/uibase/sidebar/PageSizeControl.cxx
index 4ea5995c098f..a2dbe406f335 100644
--- a/sw/source/uibase/sidebar/PageSizeControl.cxx
+++ b/sw/source/uibase/sidebar/PageSizeControl.cxx
@@ -168,7 +168,6 @@ PageSizeControl::PageSizeControl(PageSizePopup* pControl, 
weld::Widget* pParent)
     }
     mxSizeValueSet->SetNoSelection();
     mxSizeValueSet->SetSelectHdl( LINK(this, PageSizeControl, ImplSizeHdl ) );
-    mxSizeValueSet->SetOptimalDrawingAreaHeight();
     mxSizeValueSet->Show();
     mxSizeValueSet->Resize();
 

Reply via email to