summaryrefslogtreecommitdiff
path: root/src/tui/tcell.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/tui/tcell.go')
-rw-r--r--src/tui/tcell.go25
1 files changed, 6 insertions, 19 deletions
diff --git a/src/tui/tcell.go b/src/tui/tcell.go
index bf7b57cb..38641f7a 100644
--- a/src/tui/tcell.go
+++ b/src/tui/tcell.go
@@ -98,22 +98,9 @@ const (
AttrClear = Attr(1 << 8)
)
-func (r *FullscreenRenderer) PassThrough(y int, x int, data string) {
- tty, _ := _screen.Tty()
- ti, err := tcell.LookupTerminfo(os.Getenv("TERM"))
- if err != nil {
- return
- }
- ti.TPuts(tty, ti.TGoto(x, y))
- ti.TPuts(tty, data)
-}
-
-func (r *FullscreenRenderer) Sync(hard bool) {
- if hard {
- _screen.Sync()
- } else {
- _screen.Show()
- }
+func (r *FullscreenRenderer) PassThrough(str string) {
+ // No-op
+ // https://github.com/gdamore/tcell/issues/363#issuecomment-680665073
}
func (r *FullscreenRenderer) Resize(maxHeightFunc func(int) int) {}
@@ -220,10 +207,10 @@ func (r *FullscreenRenderer) Refresh() {
// noop
}
+// TODO: Pixel width and height not implemented
func (r *FullscreenRenderer) Size() TermSize {
- tty, _ := _screen.Tty()
- ws, _ := tty.WindowSize()
- return TermSize{ws.Height, ws.Width, ws.PixelWidth, ws.PixelHeight}
+ cols, lines := _screen.Size()
+ return TermSize{lines, cols, 0, 0}
}
func (r *FullscreenRenderer) GetChar() Event {