summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-06-23 16:17:29 +0100
committerEike Rathke <erack@redhat.com>2017-06-28 00:45:43 +0200
commit92921cfec5a41bffe16426cbf0511accddda6f2c (patch)
tree43cd5ce4bced07f599d5bcad4dc9909ee2762581
parent830feb5ecfd041c52a118d51f56b26f65a77712e (diff)
Resolves: tdf#108708 set a min width for calc dropdown combobox button
Change-Id: I002350170cf30a3347ed0c4e4885109ef194458e Reviewed-on: https://gerrit.libreoffice.org/39179 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
-rw-r--r--sc/source/ui/cctrl/cbuttonw.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/sc/source/ui/cctrl/cbuttonw.cxx b/sc/source/ui/cctrl/cbuttonw.cxx
index e559ea185f25..f922e545d71a 100644
--- a/sc/source/ui/cctrl/cbuttonw.cxx
+++ b/sc/source/ui/cctrl/cbuttonw.cxx
@@ -43,9 +43,8 @@ void ScDDComboBoxButton::SetOutputDevice( OutputDevice* pOutputDevice )
void ScDDComboBoxButton::SetOptSizePixel()
{
- aBtnSize = pOut->LogicToPixel( Size(0,11), MapUnit::MapAppFont );
- //aBtnSize.Width() = GetSystemMetrics( SM_CXVSCROLL ) - 1; // Win SDK function
- aBtnSize.Width() = pOut->GetSettings().GetStyleSettings().GetScrollBarSize();
+ aBtnSize = pOut->LogicToPixel(Size(8, 11), MapUnit::MapAppFont);
+ aBtnSize.Width() = std::max(aBtnSize.Width(), pOut->GetSettings().GetStyleSettings().GetScrollBarSize());
}
void ScDDComboBoxButton::Draw( const Point& rAt,