You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
lntop/ui/views/help.go

25 lines
354 B
Go

package views
import (
"fmt"
"github.com/jroimartin/gocui"
)
const (
HELP = "help"
)
func SetHelp(g *gocui.Gui, x0, y0, x1, y1 int) error {
v, err := g.SetView(HELP, x0-1, y0, x1, y1)
if err != nil {
if err != gocui.ErrUnknownView {
return err
}
}
v.Frame = false
fmt.Fprintln(v, "HELP")
_, err = g.SetCurrentView(HELP)
return err
}