Another compilation fix after wxFlexGridSizer ctors change.
wxFlexGridSizer ctor was even used incorrectly even in layout sample itself, once again the code was supposed to create 3*3 sizer, not 3-column sizer with 3 pixel vertical gap. Changed ctors to be more explicit and to use a 5 pixel gap in both directions. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61643 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
2b2c1044f9
commit
90666795d4
@ -337,24 +337,24 @@ MyFlexSizerFrame::MyFlexSizerFrame(const wxString &title, int x, int y )
|
|||||||
// consttuct the first column
|
// consttuct the first column
|
||||||
wxSizer *sizerCol1 = new wxBoxSizer(wxVERTICAL);
|
wxSizer *sizerCol1 = new wxBoxSizer(wxVERTICAL);
|
||||||
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("Ungrowable:")), 0, wxCENTER | wxTOP, 20);
|
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("Ungrowable:")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerCol1->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
sizerCol1->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
||||||
|
|
||||||
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("Growable middle column:")), 0, wxCENTER | wxTOP, 20);
|
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("Growable middle column:")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerFlex->AddGrowableCol(1);
|
sizerFlex->AddGrowableCol(1);
|
||||||
sizerCol1->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
sizerCol1->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
||||||
|
|
||||||
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("Growable middle row:")), 0, wxCENTER | wxTOP, 20);
|
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("Growable middle row:")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerFlex->AddGrowableRow(1);
|
sizerFlex->AddGrowableRow(1);
|
||||||
sizerCol1->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
sizerCol1->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
||||||
|
|
||||||
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("All growable columns:")), 0, wxCENTER | wxTOP, 20);
|
sizerCol1->Add(new wxStaticText(p, wxID_ANY, wxT("All growable columns:")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerFlex->AddGrowableCol(0, 1);
|
sizerFlex->AddGrowableCol(0, 1);
|
||||||
sizerFlex->AddGrowableCol(1, 2);
|
sizerFlex->AddGrowableCol(1, 2);
|
||||||
@ -364,14 +364,14 @@ MyFlexSizerFrame::MyFlexSizerFrame(const wxString &title, int x, int y )
|
|||||||
// the second one
|
// the second one
|
||||||
wxSizer *sizerCol2 = new wxBoxSizer(wxVERTICAL);
|
wxSizer *sizerCol2 = new wxBoxSizer(wxVERTICAL);
|
||||||
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Growable middle row and column:")), 0, wxCENTER | wxTOP, 20);
|
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Growable middle row and column:")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerFlex->AddGrowableCol(1);
|
sizerFlex->AddGrowableCol(1);
|
||||||
sizerFlex->AddGrowableRow(1);
|
sizerFlex->AddGrowableRow(1);
|
||||||
sizerCol2->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
sizerCol2->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
||||||
|
|
||||||
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Same with horz flex direction")), 0, wxCENTER | wxTOP, 20);
|
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Same with horz flex direction")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerFlex->AddGrowableCol(1);
|
sizerFlex->AddGrowableCol(1);
|
||||||
sizerFlex->AddGrowableRow(1);
|
sizerFlex->AddGrowableRow(1);
|
||||||
@ -379,7 +379,7 @@ MyFlexSizerFrame::MyFlexSizerFrame(const wxString &title, int x, int y )
|
|||||||
sizerCol2->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
sizerCol2->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
||||||
|
|
||||||
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Same with grow mode == \"none\"")), 0, wxCENTER | wxTOP, 20);
|
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Same with grow mode == \"none\"")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerFlex->AddGrowableCol(1);
|
sizerFlex->AddGrowableCol(1);
|
||||||
sizerFlex->AddGrowableRow(1);
|
sizerFlex->AddGrowableRow(1);
|
||||||
@ -388,7 +388,7 @@ MyFlexSizerFrame::MyFlexSizerFrame(const wxString &title, int x, int y )
|
|||||||
sizerCol2->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
sizerCol2->Add(sizerFlex, 1, wxALL | wxEXPAND, 10);
|
||||||
|
|
||||||
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Same with grow mode == \"all\"")), 0, wxCENTER | wxTOP, 20);
|
sizerCol2->Add(new wxStaticText(p, wxID_ANY, wxT("Same with grow mode == \"all\"")), 0, wxCENTER | wxTOP, 20);
|
||||||
sizerFlex = new wxFlexGridSizer(3, 3);
|
sizerFlex = new wxFlexGridSizer(3, 3, wxSize(5, 5));
|
||||||
InitFlexSizer(sizerFlex, p);
|
InitFlexSizer(sizerFlex, p);
|
||||||
sizerFlex->AddGrowableCol(1);
|
sizerFlex->AddGrowableCol(1);
|
||||||
sizerFlex->AddGrowableRow(1);
|
sizerFlex->AddGrowableRow(1);
|
||||||
|
Loading…
Reference in New Issue
Block a user