diff options
Diffstat (limited to 'place.go')
| -rw-r--r-- | place.go | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -39,6 +39,8 @@ func (w *guiWidget) placeBox(startW int, startH int) { return } + w.full.w0 = startW + w.full.h0 = startH newW := startW newH := startH @@ -84,9 +86,14 @@ func (tk *guiWidget) placeWidgets(startW int, startH int) (int, int) { return startW, startH case widget.Tab: case widget.Grid: - return tk.placeGrid(startW, startH) + newW, newH := tk.placeGrid(startW, startH) + tk.full.w0 = newW + tk.full.h0 = newH + return newW, newH case widget.Box: tk.placeBox(startW, startH) + tk.full.w0 = startW + tk.full.h0 = startH return 0, 0 case widget.Stdout: tk.setStdoutWH(startW, startH) @@ -94,6 +101,8 @@ func (tk *guiWidget) placeWidgets(startW int, startH int) (int, int) { case widget.Group: // move the group to the parent's next location tk.gocuiSetWH(startW, startH) + tk.full.w0 = startW + tk.full.h0 = startH newW := startW + me.GroupPadW newH := startH + 1 // normal hight of the group label @@ -126,6 +135,9 @@ func (w *guiWidget) placeGrid(startW int, startH int) (int, int) { return 0, 0 } + w.full.w0 = startW + w.full.h0 = startH + // first compute the max sizes of the rows and columns for _, child := range w.children { childW, childH := child.placeWidgets(child.startW, child.startH) |
