diff options
-rw-r--r-- | vcl/source/window/toolbox.cxx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx index 4d203c6b9186..9533784c0dab 100644 --- a/vcl/source/window/toolbox.cxx +++ b/vcl/source/window/toolbox.cxx @@ -2492,9 +2492,12 @@ static void ImplDrawDropdownArrow(vcl::RenderContext& rRenderContext, const tool float fScaleFactor = rRenderContext.GetDPIScaleFactor(); tools::Polygon aPoly(4); + int iTBHeight = rRenderContext.GetOutputSize().Height(); //scale triangle depending on theme/toolbar height - long width = 7 * fScaleFactor; - long height = 4 * fScaleFactor; + long width = round(iTBHeight/5.5) * fScaleFactor; // 7 for gtk, 5 for gen + long height = round(iTBHeight/9.5) * fScaleFactor; // 4 for gtk, 3 for gen + if (width < 4) width = 4; + if (height < 3) height = 3; long x = rDropDownRect.Left() + (rDropDownRect.getWidth() - width)/2; long y = rDropDownRect.Top() + (rDropDownRect.getHeight() - height)/2; |