3 Commits

Author SHA1 Message Date
884148f006 Fix ScrollContainer layout again 2024-07-26 17:56:29 -04:00
3e382da688 Fix ScrollContainer layout 2024-07-26 17:54:32 -04:00
18b8898644 Fix dialog alignment 2024-07-26 00:34:05 -04:00
2 changed files with 6 additions and 2 deletions

View File

@@ -63,7 +63,7 @@ func NewDialog (kind DialogKind, parent tomo.Window, title, message string, opti
}
}
dialog.controlRow = NewInnerContainer(layouts.ContractHorizontal, options...)
messageText.SetAttr(tomo.AAlign(tomo.AlignEnd, tomo.AlignEnd))
dialog.controlRow.SetAttr(tomo.AAlign(tomo.AlignEnd, tomo.AlignEnd))
dialog.SetRoot(NewOuterContainer (
layouts.Column { true, false },

View File

@@ -73,7 +73,11 @@ func NewScrollContainer (sides ScrollSide) *ScrollContainer {
this.OnKeyUp(this.handleKeyUp)
this.SetRole(tomo.R("objects", "ScrollContainer"))
this.SetTag(sides.String(), true)
this.SetAttr(tomo.ALayout(layouts.NewGrid(true, false)(true, false)))
if sides == ScrollHorizontal {
this.SetAttr(tomo.ALayout(layouts.NewGrid(true)(true, false)))
} else {
this.SetAttr(tomo.ALayout(layouts.NewGrid(true, false)(true, false)))
}
return this
}