You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ok, I see - context is nil because it is created in NewMasterWindow. THe problem is that init font stuff happens there as well. Need to add extra logic in SetDefaultFontSize.
What happend?
g.Context is nil
panic: runtime error: invalid memory address or nil pointer dereference
Code example
main.go
package main
import (
g "github.com/AllenDang/giu"
)
func loop() {
g.SingleWindow().Layout(
g.Style().To(
g.Label("test"),
),
)
}
func main() {
g.Context.FontAtlas.SetDefaultFontSize(12)
wnd := g.NewMasterWindow("test", 1024, 768, g.MasterWindowFlagsMaximized)
wnd.Run(loop)
}
To Reproduce
Version
master
OS
windows
The text was updated successfully, but these errors were encountered: