mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-05 03:20:08 +01:00
Add test for wx.FlexGridSizer.GetColWidths and GetRowHeights
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@75583 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -22,6 +22,24 @@ class sizer_Tests(wtc.WidgetTestCase):
|
||||
fgs1 = wx.FlexGridSizer(4, 5, 6)
|
||||
fgs2 = wx.FlexGridSizer(4, (5,6))
|
||||
fgs3 = wx.FlexGridSizer(cols=4, hgap=5, vgap=6)
|
||||
|
||||
def test_sizerFlexGrid2(self):
|
||||
fgs = wx.FlexGridSizer(cols=4, hgap=5, vgap=6)
|
||||
for x in range(20):
|
||||
fgs.Add(wx.StaticText(self.frame, -1, str(x)))
|
||||
fgs.AddGrowableCol(1, 1)
|
||||
fgs.AddGrowableCol(3, 2)
|
||||
fgs.AddGrowableRow(2)
|
||||
fgs.RemoveGrowableRow(2)
|
||||
|
||||
self.frame.SetSizer(fgs)
|
||||
self.frame.Layout()
|
||||
|
||||
widths = fgs.GetColWidths()
|
||||
heights = fgs.GetRowHeights()
|
||||
self.assertEqual(4, len(widths))
|
||||
self.assertEqual(5, len(heights))
|
||||
|
||||
|
||||
def test_sizer2(self):
|
||||
s = wx.BoxSizer(wx.VERTICAL)
|
||||
|
||||
Reference in New Issue
Block a user