class 2 fyne golang gui RESIZE Window
GUI based Applications are fun and easy to use.
Want to change size of your Fyne Gui App?
It is so simple..
fyne.NewSize(700, 200)
- where first value is width e.g 700
- and 2nd value is height e.g 200
both width and height are FLOAT.
Now It should look like below
w.Resize(fyne.NewSize(700, 200))
package main
// importing fyne v2
import (
"fyne.io/fyne/v2"
"fyne.io/fyne/v2/app"
)
func main() {
a := app.New()
w := a.NewWindow("My title for 2nd tutorial")
//Resizin our fyne app window
// first one is width
// 2nd value is height
w.Resize(fyne.NewSize(700, 200))
w.ShowAndRun() // Running our App
}
[easy_media_download url=”http://blogvali.com/wp-content/uploads/fyne-golang-downloads/main2.go” text=”Download Code” color=”red_darker”]
Fyne GoLang GUI Course