ppforge/flowlayout_test.go

25 lines
423 B
Go

package npc
import (
"fmt"
"testing"
"fyne.io/fyne/v2"
"fyne.io/fyne/v2/test"
"fyne.io/fyne/v2/widget"
)
func TestFlowLayout_Simple(t *testing.T) {
//padding := theme.Padding()
objs := []fyne.CanvasObject{
widget.NewLabel("Hello World"),
}
layout := NewFlowLayout(objs...)
win := test.NewWindow(layout)
defer win.Close()
win.Resize(fyne.NewSize(200, 200))
size := layout.Size()
fmt.Printf("%v", size)
}