Skip to content

Commit

Permalink
Actually move the invisible spacers
Browse files Browse the repository at this point in the history
  • Loading branch information
andydotxyz committed Dec 27, 2024
1 parent da388dd commit c0a8fc3
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions layout/boxlayout.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,8 @@ func (v vBoxLayout) Layout(objects []fyne.CanvasObject, size fyne.Size) {
}

if isVerticalSpacer(child) {
child.Move(fyne.NewPos(x, y))
child.Resize(fyne.NewSize(size.Width, spacerSize))
y += spacerSize
continue
}
Expand Down Expand Up @@ -177,6 +179,9 @@ func (g hBoxLayout) Layout(objects []fyne.CanvasObject, size fyne.Size) {
}

if isHorizontalSpacer(child) {
child.Move(fyne.NewPos(x, y))
child.Resize(fyne.NewSize(spacerSize, size.Height))

x += spacerSize
continue
}
Expand Down

0 comments on commit c0a8fc3

Please sign in to comment.