[Libreoffice] [PUSHED] Re: minor problem with Insert -> indexes and tables dialog

Jan Holesovsky kendy at suse.cz
Tue Dec 27 06:50:26 PST 2011

Hi Ivan,

Ivan Timofeev píše v Út 27. 12. 2011 v 17:47 +0400:

> SwMultiTOXTabDialog is derived from TabDialog. TabDialog uses the weird 
> automatic arrangement code, see vcl/source/window/tabdlg.cxx, method 
> TabDialog::ImplPosControls(). After executing this method all controls 
> below a TabControl will have the same width! And this width is 
> calculated as max width of text of control plus some constant 
> IMPL_EXTRA_BUTTON_WIDTH. For buttons this works. For checkbox this fails.

Great catch! :-)

> So what to do?
> 1. dirty hack: increase IMPL_EXTRA_BUTTON_WIDTH :)
> 2. consider type of controls and use an appropriate method to determine 
> the width.
> 3. smth else?

Based on your nice analysis, I pushed this:


[both to master and libreoffice-3-5]

According to what I've tested, this should behave nicely even in the
case the text of the 'Preview' checkbox is actually longer in some
language; but please feel free to fix with something better if you are
not happy with this :-)


More information about the LibreOffice mailing list