diff --git a/views/view_border.go b/views/view_border.go index 7c6d8c9..28f75f9 100644 --- a/views/view_border.go +++ b/views/view_border.go @@ -101,9 +101,9 @@ func (v *BorderView) Layout() (prefWidth, prefHeight int) { for side, border := range v.ShowBorder { if border { - if side.Horizontal() { + if side.Horizontal() && w >= 0 { w++ - } else if side.Vertical() { + } else if side.Vertical() && h >= 0 { h++ } }