diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-07-12 10:13:22 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-07-21 10:22:09 +0200 |
commit | 85f84f4a12812d23ee4cac88c3892128548fa718 (patch) | |
tree | 737135fc16d2ff11f38f6f0aba07f8a9a8973c74 /vcl | |
parent | 931af50553379d08c61457261cd9dcdda3ecb0ca (diff) |
tdf#100600 sfx2 classification: never replace the control with label
Thanks to Caolán McNamara for pointing out where is the condition of the
replacement in VCL.
Change-Id: I7e1ef4a016a37b25e084c4c6467a42ca557069a4
Reviewed-on: https://gerrit.libreoffice.org/27133
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins <ci@libreoffice.org>
(cherry picked from commit 8192da8e4de7a058ef95253f992f4143f83fa0f1)
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/window/toolbox2.cxx | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/vcl/source/window/toolbox2.cxx b/vcl/source/window/toolbox2.cxx index c3d11735e9bf..8b08e941e4f0 100644 --- a/vcl/source/window/toolbox2.cxx +++ b/vcl/source/window/toolbox2.cxx @@ -215,6 +215,12 @@ Size ImplToolItem::GetSize( bool bHorz, bool bCheckMaxWidth, long maxWidth, cons // get size of item window and check if it fits // no windows in vertical toolbars (the default is mbShowWindow=false) Size aWinSize = mpWindow->GetSizePixel(); + + if (mpWindow->GetStyle() & WB_NOLABEL) + // Window wants no label? Then don't check width, it'll be just + // clipped. + bCheckMaxWidth = false; + if ( !bCheckMaxWidth || (aWinSize.Width() <= maxWidth) ) { aSize.Width() = aWinSize.Width(); |