diff options
Diffstat (limited to 'termui/table.go')
-rw-r--r-- | termui/table.go | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/termui/table.go b/termui/table.go index e587839..a879489 100644 --- a/termui/table.go +++ b/termui/table.go @@ -5,8 +5,10 @@ import ( "image" "log" "strings" + "strconv" . "github.com/gizak/termui/v3" + "github.com/jdkeke142/lingo-toml" ) type Table struct { @@ -30,6 +32,8 @@ type Table struct { TopRow int // used to indicate where in the table we are scrolled at ColResizer func() + + Tr lingo.Translations } // NewTable returns a new Table instance @@ -79,7 +83,8 @@ func (self *Table) Draw(buf *Buffer) { } if self.TopRow < 0 { - log.Printf("table widget TopRow value less than 0. TopRow: %v", self.TopRow) + r := strconv.Itoa(self.TopRow) + log.Printf(self.Tr.Value("error.table", r)) return } |