1
0
mirror of https://github.com/gdamore/tcell.git synced 2025-04-27 13:48:50 +08:00

fixes #238 views: BoxLayout.Draw does unnecessary filling

This commit is contained in:
Garrett D'Amore 2018-09-23 19:54:34 -07:00
parent 86147f14ef
commit a24b9b6b1c

View File

@ -204,13 +204,7 @@ func (b *BoxLayout) Draw() {
if b.changed { if b.changed {
b.layout() b.layout()
} }
b.view.Fill('*', b.style) b.view.Fill(' ', b.style)
w, h := b.view.Size()
for y := 0; y < h; y++ {
for x := 0; x < w; x++ {
b.view.SetContent(x, y, ' ', nil, b.style)
}
}
for i := range b.cells { for i := range b.cells {
b.cells[i].widget.Draw() b.cells[i].widget.Draw()
} }