~eliasnaur/gio-example

a005726325caf44529507b22c31031a91e1a033b — r3mb00 8 months ago d6ec266
tabs: respect system insets

Signed-off-by: r3mb00 <ipalamar4uck@gmail.com>
1 files changed, 9 insertions(+), 1 deletions(-)

M tabs/tabs.go
M tabs/tabs.go => tabs/tabs.go +9 -1
@@ 45,7 45,15 @@ func loop(w *app.Window) error {
			return e.Err
		case system.FrameEvent:
			gtx := layout.NewContext(&ops, e)
			drawTabs(gtx, th)
			layout.Inset{
   				Bottom: e.Insets.Bottom,
   				Left:   e.Insets.Left,
    				Right:  e.Insets.Right,
    				Top:    e.Insets.Top,
			}.Layout(gtx, func(gtx C) D {
   		 		return drawTabs(gtx, th)
		})
		
			e.Frame(gtx.Ops)
		}
	}