diff --git a/default/theme/default.go b/default/theme/default.go index 096d2df..c18c88c 100644 --- a/default/theme/default.go +++ b/default/theme/default.go @@ -276,6 +276,8 @@ func (Default) Padding (id tomo.Pattern, c tomo.Case) artist.Inset { case tomo.PatternSunken: if c.Match("tomo", "progressBar", "") { return artist.I(2, 1, 1, 2) + } else if c.Match("tomo", "list", "") { + return artist.I(2) } else { return artist.I(8) } diff --git a/elements/list.go b/elements/list.go index ac94eba..b7a6b3f 100644 --- a/elements/list.go +++ b/elements/list.go @@ -284,7 +284,7 @@ func (element *List) selectNone () { func (element *List) scrollToSelected () { if element.selected < 0 { return } target := element.entity.Child(element.selected).Entity().Bounds() - padding := element.theme.Padding(tomo.PatternBackground) + padding := element.theme.Padding(tomo.PatternSunken) bounds := padding.Apply(element.entity.Bounds()) if target.Min.Y < bounds.Min.Y { element.scroll.Y -= bounds.Min.Y - target.Min.Y