Use equally-sized buttons in wxMSW horizontal toolbars

Only use TBSTYLE_AUTOSIZE, adjusting each button to the size it really needs,
for the toolbars with wxTB_HORZ_LAYOUT style as they don't have any uniform
button size anyhow.
This commit is contained in:
Vadim Zeitlin
2016-06-26 18:51:50 +02:00
parent 98bb2b265a
commit 967bdbf994
2 changed files with 2 additions and 1 deletions

View File

@@ -108,6 +108,7 @@ wxMSW:
- Fix MDI menu display after failure to create a child frame (troelsk). - Fix MDI menu display after failure to create a child frame (troelsk).
- Fix wxScreenDC::GetSize() with multiple monitors (iwbnwif). - Fix wxScreenDC::GetSize() with multiple monitors (iwbnwif).
- Fix background colour returned by wxTextCtrl::GetStyle() (Andreas Falkenhahn). - Fix background colour returned by wxTextCtrl::GetStyle() (Andreas Falkenhahn).
- Revert to using equally-sized buttons in wxToolBar by default.
wxOSX: wxOSX:

View File

@@ -1095,7 +1095,7 @@ bool wxToolBar::Realize()
// automatically according to the size of their bitmap and text // automatically according to the size of their bitmap and text
// label, if present. They look hideously ugly without autosizing // label, if present. They look hideously ugly without autosizing
// when the labels have even slightly different lengths. // when the labels have even slightly different lengths.
if ( !IsVertical() ) if ( HasFlag(wxTB_HORZ_LAYOUT) )
{ {
button.fsStyle |= TBSTYLE_AUTOSIZE; button.fsStyle |= TBSTYLE_AUTOSIZE;
} }