Replies: 4 comments 2 replies
-
VBox and HBox explicitly pack widgets in to their min size - if you don't want that behaviour then try a different container. |
Beta Was this translation helpful? Give feedback.
-
Thank you! I wonder if I can set min size of widgets, like label, entry, list ... ? |
Beta Was this translation helpful? Give feedback.
-
Use layout.NewSpacer to divide the size of a widget in a container taking the max space. use the last arg to Border layout to take the whole space or grid layout to divide space equaly. Add a layout into a layout to fine tune the size and pos. don't forget spacer. |
Beta Was this translation helpful? Give feedback.
-
I will often put items that need a minimum size inside a scroll container which can be set... This is a bit simplistic, but I have several apps that do not load data until it is requested.
|
Beta Was this translation helpful? Give feedback.
-
Hello,
The entry/button/list are small in the GUI although I have explicitly set their size (fyne 2.3.0). What did I miss? The snapshot is https://drive.google.com/file/d/1ouXwUTXt4NQa1yXTi-HlBX1lrlAbUQA0/view?usp=drive_link
Here is the code:
`
package main
import (
"fyne.io/fyne/v2"
"fyne.io/fyne/v2/app"
"fyne.io/fyne/v2/container"
"fyne.io/fyne/v2/widget"
)
func main() {
myApp := app.New()
myWindow := myApp.NewWindow("VBox layout example")
myWindow.Resize(fyne.Size{Width: 800, Height: 600})
}
`
Beta Was this translation helpful? Give feedback.
All reactions