about summary refs log tree commit diff stats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/ui/fill.go11
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/ui/fill.go b/lib/ui/fill.go
index 0ab4f74..13ad286 100644
--- a/lib/ui/fill.go
+++ b/lib/ui/fill.go
@@ -4,16 +4,19 @@ import (
 	"github.com/gdamore/tcell/v2"
 )
 
-type Fill rune
+type Fill struct {
+	Rune  rune
+	Style tcell.Style
+}
 
-func NewFill(f rune) Fill {
-	return Fill(f)
+func NewFill(f rune, s tcell.Style) Fill {
+	return Fill{f, s}
 }
 
 func (f Fill) Draw(ctx *Context) {
 	for x := 0; x < ctx.Width(); x += 1 {
 		for y := 0; y < ctx.Height(); y += 1 {
-			ctx.SetCell(x, y, rune(f), tcell.StyleDefault)
+			ctx.SetCell(x, y, f.Rune, f.Style)
 		}
 	}
 }