pad grid and group by default
Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
parent
a7640472cb
commit
ba2373fdf7
|
@ -52,11 +52,12 @@ func (n *Node) DebugFlags(makeWindow bool) {
|
|||
if (makeWindow) {
|
||||
w = me.rootNode.NewWindow("Debug Flags")
|
||||
w.Custom = w.StandardClose
|
||||
w = w.NewBox("hBox", true)
|
||||
} else {
|
||||
w = n.NewTab("Flags")
|
||||
}
|
||||
|
||||
g = w.NewGroup("Show")
|
||||
g = w.NewGroup("Show").Pad()
|
||||
|
||||
g.NewButton("log.SetTmp()", func () {
|
||||
newlog.SetTmp()
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
package gui
|
||||
|
||||
import (
|
||||
newlog "go.wit.com/log"
|
||||
)
|
||||
|
||||
// TODO: move all this shit into somewhere not global
|
||||
|
||||
// main debugging window
|
||||
|
@ -18,6 +22,9 @@ func DebugWindow() {
|
|||
bugWin = me.rootNode.NewWindow("go.wit.com/gui debug window").DebugTab("Debug Tab")
|
||||
bugWin.Custom = bugWin.StandardClose
|
||||
// bugWin.DebugTab("Debug Tab")
|
||||
if newlog.ArgDebug() {
|
||||
bugWin.DebugFlags(true)
|
||||
}
|
||||
}
|
||||
|
||||
func (n *Node) DebugTab(title string) *Node {
|
||||
|
|
3
grid.go
3
grid.go
|
@ -32,6 +32,9 @@ func (n *Node) NewGrid(name string, w int, h int) *Node {
|
|||
|
||||
a := newAction(newNode, toolkit.Add)
|
||||
sendAction(a)
|
||||
|
||||
// by default, always pad grids
|
||||
newNode.Pad()
|
||||
return newNode
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue