+ // 2.7) And a test of wxGridSizer
+ wxGridSizer *gridsizer = new wxGridSizer(2, 5, 5);
+ gridsizer->Add(new wxStaticText(this, -1, "Label"), 0,
+ wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
+ gridsizer->Add(new wxTextCtrl(this, -1, "Grid sizer demo"), 1,
+ wxGROW | wxALIGN_CENTER_VERTICAL);
+ gridsizer->Add(new wxStaticText(this, -1, "Another label"), 0,
+ wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
+ gridsizer->Add(new wxTextCtrl(this, -1, "More text"), 1,
+ wxGROW | wxALIGN_CENTER_VERTICAL);
+ gridsizer->Add(new wxStaticText(this, -1, "Final label"), 0,
+ wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
+ gridsizer->Add(new wxTextCtrl(this, -1, "And yet more text"), 1,
+ wxGROW | wxALIGN_CENTER_VERTICAL);
+ topsizer->Add(gridsizer, 1, wxGROW | wxALL, 10);
+