diff options
| author | Pietro Gagliardi <[email protected]> | 2014-06-26 10:36:59 -0400 |
|---|---|---|
| committer | Pietro Gagliardi <[email protected]> | 2014-06-26 10:36:59 -0400 |
| commit | 214467bb939db60ae6080fc83f7009f14c84982a (patch) | |
| tree | fc07da4b230b0d97d04a12010f7449f4c5db478d /grid.go | |
| parent | 131809fc625e56abda3ce381920bb1021de9c793 (diff) | |
Implemented window margins for Grids and Stacks.
Diffstat (limited to 'grid.go')
| -rw-r--r-- | grid.go | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -139,8 +139,11 @@ func (g *Grid) allocate(x int, y int, width int, height int, d *sysSizeData) (al ymargin := d.ymargin d.xmargin = 0 d.ymargin = 0 -_=xmargin -_=ymargin + // 0) inset the available rect by the margins + x += xmargin + y += ymargin + width -= xmargin * 2 + height -= ymargin * 2 // 1) clear data structures for i := range g.rowheights { g.rowheights[i] = 0 |
