extract some sharable utils out of tracklist in prep for playqueuelist

This commit is contained in:
Drew Weymouth
2024-03-02 10:04:47 -08:00
parent cbbebf6eb5
commit 18d0580424
3 changed files with 139 additions and 120 deletions
+18
View File
@@ -212,6 +212,24 @@ func AddHeaderBackground(obj fyne.CanvasObject) *fyne.Container {
obj))
}
func NewTruncatingRichText() *widget.RichText {
rt := widget.NewRichTextWithText("")
rt.Truncation = fyne.TextTruncateEllipsis
return rt
}
func NewTruncatingLabel() *widget.Label {
rt := widget.NewLabel("")
rt.Truncation = fyne.TextTruncateEllipsis
return rt
}
func NewTrailingAlignLabel() *widget.Label {
rt := widget.NewLabel("")
rt.Alignment = fyne.TextAlignTrailing
return rt
}
type HSpace struct {
widget.BaseWidget