From a282a12b81fb82dd7d7b9c2b04d8cf3933fde5d3 Mon Sep 17 00:00:00 2001 From: Pietro Gagliardi Date: Fri, 15 Aug 2014 19:50:00 -0400 Subject: Fixed up Grid and wrote a test. --- redo/zz_test.go | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'redo/zz_test.go') diff --git a/redo/zz_test.go b/redo/zz_test.go index b439b34..85c0b4a 100644 --- a/redo/zz_test.go +++ b/redo/zz_test.go @@ -32,6 +32,7 @@ var ddata = []dtype{ type testwin struct { t Tab w Window + grid Grid nt Tab a Area spw Stack @@ -68,6 +69,14 @@ func (tw *testwin) make(done chan struct{}) { done <- struct{}{} return true }) + tw.grid = NewGrid(3, + NewLabel("0,0"), NewTextField(), NewLabel("0,2"), + NewButton("1,0"), NewButton("1,1"), NewButton("1,2"), + NewLabel("2,0"), NewTextField(), NewStandaloneLabel("2,2")) + tw.grid.SetFilling(2, 1) + tw.grid.SetFilling(1, 2) + tw.grid.SetStretchy(1, 1) + tw.t.Append("Grid", tw.grid) tw.t.Append("Blank Tab", NewTab()) tw.nt = NewTab() tw.nt.Append("Tab 1", Space()) -- cgit v1.2.3